diff --git a/dist/main.js b/dist/main.js index 85e90621e..ab8f42349 100644 --- a/dist/main.js +++ b/dist/main.js @@ -6,5 +6,5 @@ var t,e,n=require("crypto"),r=require("module"),i=require("events"),o=require("a * Copyright(c) 2015 Tiancheng "Timothy" Gu * MIT Licensed */ -var Q=/["'&<>]/,Z=function(t){var e,n=""+t,r=Q.exec(n);if(!r)return n;var i="",o=0,s=0;for(o=r.index;o{const i={stdout:r.stdout?[]:null,stderr:r.stderr?[]:null};r.on("error",e),r.stdout&&r.stdout.on("data",(function(t){i.stdout.push(t),n.handleStdout&&n.handleStdout(t)})),r.stderr&&r.stderr.on("data",(function(t){i.stderr.push(t),n.handleStderr&&n.handleStderr(t)})),r.on("close",(e=>{let r=null;null!=i.stdout&&(r=null===n.encoding||"buffer"===n.encoding?Buffer.concat(i.stdout):i.stdout.join(""));let o=null;null!=i.stderr&&(o=null===n.encoding||"buffer"===n.encoding?Buffer.concat(i.stderr):i.stderr.join("")),t({exitCode:e,stdout:r,stderr:o})}))}));return n.handleChildProcess(r),i}(t,e,{...n,handleChildProcess(t){r=t}});return i.kill=function(t){return r.kill(t)},i}async function Y(t){if(G){const e=await async function(t){var e;const n=atom.packages.getLoadedPackage(t.name);return null==n?null:null!==(e=n.metadata.version)&&void 0!==e?e:null}(t);if(e)return e}return async function(t){var e,n;const{directory:r}=t;if(null==r)return null;let i=null;try{i=JSON.parse(await D.default.promises.readFile(F.default.join(r,"package.json"),"utf8"))}catch(t){return null}return null!==(e=null===(n=i)||void 0===n?void 0:n.version)&&void 0!==e?e:null}(t)}const X=G?async function(t){return atom.packages.resolvePackagePath(t)}:async function(t){var e;const n=F.default.join(null!==(e=process.env.ATOM_HOME)&&void 0!==e?e:F.default.join(N.default.homedir(),".atom"),"packages",t);try{return await D.default.promises.access(n,D.default.constants.R_OK),n}catch(t){return null}};function tt(t,e){if(!t)throw new Error(null!=e?e:"Invariant violation")}async function et(t){const e=await(G?async function(t){const e=atom.packages.getLoadedPackage(t),n=e&&e.metadata["package-deps"];return Array.isArray(n)?n:[]}(t):async function(t){let e=null;try{e=await D.default.promises.stat(t)}catch(t){}if(null==e||!e.isDirectory())throw new Error("[Package-Deps] Expected packageName to be a readable directory in Node.js invocation");let n=null;try{const e=await D.default.promises.readFile(F.default.join(t,"package.json"),"utf8");n=JSON.parse(e)}catch(t){}const r=null==n||"object"!=typeof n?[]:n["package-deps"];return Array.isArray(r)?r:[]}(t));return K&&(tt(Array.isArray(e),`Dependencies for ${t} are not a valid array`),e.forEach(((e,n)=>{if(Array.isArray(e))e.forEach(((e,r)=>{const i=`Dependency#${n}#${r} for ${t} is invalid`;tt("string"==typeof e.name&&e.name.length>0,i),tt(null==e.minimumVersion||"string"==typeof e.minimumVersion&&e.minimumVersion.length>0,i)})),tt(e.length>0,`Dependency#${n} for ${t} has no group items`);else{const r=`Dependency#${n} for ${t} is invalid`;tt("string"==typeof e.name&&e.name.length>0,r),tt(null==e.minimumVersion||"string"==typeof e.minimumVersion&&e.minimumVersion.length>0,r)}}))),e}async function nt(t){if(null==t.directory)return!0;if(null==t.minimumVersion)return!1;const e=await Y(t);return null==e||1===function(t,e){for(var n=t.split("."),r=e.split("."),i=0;i<3;i++){var o=Number(n[i]),s=Number(r[i]);if(o>s)return 1;if(s>o)return-1;if(!isNaN(o)&&isNaN(s))return 1;if(isNaN(o)&&!isNaN(s))return-1}return 0}(t.minimumVersion,e)}const rt=new Set(["✓","done"]),it=/(?:Installing|Moving) (.*?) to .* (.*)/;let ot=!0;const st=G?function({packageName:t,dependencies:e}){const n=[],r=atom.notifications.addInfo(`Installing ${t} dependencies`,{detail:"Installing "+e.map((t=>t.name)).join(", "),dismissable:!0}),i=document.createElement("progress");i.max=e.length,i.style.width="100%";try{var o;const t=atom.views.getView(r),e=null!==(o=null==t?void 0:t.element)&&void 0!==o?o:null;if(null==e)throw new Error("Unable to get notification element from view");const n=e.querySelector(".detail-content");if(null==n)throw new Error("Content detail container not found inside the notification");n.appendChild(i)}catch(t){console.error("[Package-Deps] Error during showing installation progress to user",t)}return{handleFailure({dependency:t,error:e}){var r;n.push(t.name),i.value+=1,console.error(`[Package-Deps] Unable to install ${t.name}, Error:`,null!==(r=null==e?void 0:e.stack)&&void 0!==r?r:e)},handleDependencyInstalled(t){i.value+=1},handleComplete(){r.dismiss(),n.length>0?atom.notifications.addWarning(`Failed to install ${t} dependencies`,{detail:"These packages were not installed, check your console\nfor more info.\n"+n.join("\n"),dismissable:!0}):atom.notifications.addSuccess(`Installed ${t} dependencies`,{detail:"Installed "+e.map((t=>t.name)).join(", ")}),Promise.all(e.map((t=>n.includes(t.name)?null:atom.packages.activatePackage(t.name)))).catch((e=>{console.error("[Package-Deps] Error activating installed packages for "+t,e)}))}}}:function({dependencies:t}){let e=!1;return console.log("Installing dependencies:\n"+t.map((t=>" - "+t.name)).join("\n")),{handleFailure({dependency:t,error:n}){var r;e=!0,console.error(`Unable to install ${t.name}, Error:`,null!==(r=null==n?void 0:n.stack)&&void 0!==r?r:n)},handleDependencyInstalled(t){console.log("Successfully installed",t.name)},handleComplete(){console.log("Installation complete"),e&&(process.exitCode=1)}}},at=G?function({packageName:t,dependencies:e}){return new Promise((n=>{const r=e.filter((t=>!Array.isArray(t))),i=e.filter((t=>Array.isArray(t))),o=0===i.length,s=o?r.map((t=>t.name)).join(", "):"Something went wrong. Check your developer console",a=i.map((t=>t[0]));atom.packages.isPackageDisabled("notifications")&&console.warn("Enable notifications to install dependencies for "+t);const c=atom.notifications.addInfo(t+" needs to install dependencies",{dismissable:!0,icon:"cloud-download",detail:s,description:`Install dependenc${1===e.length?"y":"ies"}?`,buttons:[{text:"Yes",onDidClick:()=>{n(o?[]:r.concat(a)),c.dismiss()}},{text:"No Thanks",onDidClick:()=>{c.dismiss()}},{text:"Never",onDidClick:()=>{!function(t){var e;if(!G)return;const n=new Set(null!==(e=atom.config.get("atom-package-deps.ignored"))&&void 0!==e?e:[]);n.add(t),atom.config.set("atom-package-deps.ignored",Array.from(n))}(t),ot&&(ot=!1,atom.notifications.addInfo("How to reset package-deps memory",{dismissable:!0,description:"To modify the list of ignored files invoke 'Application: Open Your Config' and change the 'atom-package-deps' section"})),c.dismiss()}}]});if(c.onDidDismiss((()=>n([]))),!o)try{var u;const t=atom.views.getView(c),e=null!==(u=null==t?void 0:t.element)&&void 0!==u?u:null;if(null==e)throw new Error("Unable to get notification element from view");const n=e.querySelector(".detail-content");if(null==n)throw new Error("Content detail container not found inside the notification");if(n.innerHTML="",r.length>0){const t=document.createElement("div");t.innerHTML=`Packages without choices:
`,n.appendChild(t)}const o=document.createElement("div");o.innerHTML="Packages with choices:",n.appendChild(o);const s=document.createElement("ul");i.forEach(((t,e)=>{const n=document.createElement("li"),r=document.createElement("select");r.innerHTML=t.map((t=>``)).join("\n"),r.addEventListener("change",(()=>{const n=t.find((t=>t.name===r.value));null!=n&&(a[e]=n)})),n.style.marginTop="5px",n.appendChild(r),s.appendChild(n)})),n.appendChild(s)}catch(t){console.error("[Package-Deps] Error during showing package choices to user",t)}}))}:async function({dependencies:t}){return t.map((t=>Array.isArray(t)?t[0]:t))};var ct=async function(t){if(tt("string"==typeof t&&t.length>0,"[Package-Deps] Package name is required"),e=t,G&&(null!==(n=atom.config.get("atom-package-deps.ignored"))&&void 0!==n?n:[]).includes(e))return;var e,n;const r=await et(t);if(0===r.length)return;const i=await Promise.all(r.map((async t=>Array.isArray(t)?Promise.all(t.map((async t=>({...t,directory:await X(t.name)})))):{...t,directory:await X(t.name)}))),o=await V(i,(async function(t){return Array.isArray(t)?(await Promise.all(t.map((t=>nt(t))))).every(Boolean):nt(t)}));if(0===o.length)return;const s=await at({packageName:t,dependencies:o});if(0===s.length)return;const a=st({packageName:t,dependencies:s});await(async(t,e,{concurrency:n=1/0,stopOnError:r=!0}={})=>new Promise(((i,o)=>{if("function"!=typeof e)throw new TypeError("Mapper function is required");if(!Number.isSafeInteger(n)&&n!==1/0||!(n>=1))throw new TypeError(`Expected \`concurrency\` to be an integer from 1 and up or \`Infinity\`, got \`${n}\` (${typeof n})`);const s=[],a=[],c=t[Symbol.iterator]();let u=!1,l=!1,f=0,p=0;const h=()=>{if(u)return;const t=c.next(),n=p;if(p++,t.done)return l=!0,void(0===f&&(r||0===a.length?i(s):o(new z(a))));f++,(async()=>{try{const r=await t.value;s[n]=await e(r,n),f--,h()}catch(t){r?(u=!0,o(t)):(a.push(t),f--,h())}})()};for(let t=0;tht(t,e,...n);for(const t of pt)ht[t]=(e,...n)=>ht(t,e,...n);ut=ht;var gt,mt={},vt={};vt=new Map([["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["className","class"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["panose1","panose-1"],["paintOrder","paint-order"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xHeight","x-height"]]);var yt;function wt(t,e,n,r,i){if(n)for(var o in n)"ref"!==o&&"on"!==o&&(o in lt||i&&o in i||("dataset"===o?wt(t.dataset,null,n&&n.dataset,null,null):"innerHTML"!==o&&e&&pt.has(e.tag)?t.removeAttribute(vt.get(o)||o):(t[o]="",delete t[o])));if(i)for(var o in i)if("ref"!==o&&"on"!==o&&!(o in lt)){var s=n&&n[o],a=i[o];"dataset"===o?bt(t.dataset,s,a,!1):"style"===o&&"string"!=typeof a?("string"==typeof s&&(t.style="",s=null),bt(t.style,s,a,!0)):"attributes"===o?_t(t,s,a):a!==s&&("innerHTML"!==o&&r&&pt.has(r.tag)?t.setAttribute(vt.get(o)||o,a):r&&"input"===r.tag&&"value"===o&&t[o]===a||(t[o]=a))}}function bt(t,e,n,r){if(e)for(var i in e)n&&i in n||(r?t[i]="":delete t[i]);if(n)for(var i in n){const r=e&&e[i],o=n[i];o!==r&&(t[i]=o)}}function _t(t,e,n){if(e)for(var r in e)n&&r in n||t.removeAttribute(r);if(n)for(var r in n){const i=e&&e[r],o=n[r];o!==i&&t.setAttribute(r,o)}}function xt(t,e){let n;if(null!=t.text)n=document.createTextNode(t.text);else{const{tag:r,children:i}=t;let{props:o,context:s}=t;if(s&&(e={refs:s.refs,listenerContext:s}),"function"==typeof r){let s;o&&o.ref&&(s=o.ref);const a=new r(o||{},i);t.component=a,n=a.element,"function"==typeof s?s(a):e&&e.refs&&s&&(e.refs[s]=a)}else pt.has(r)?(n=document.createElementNS("http://www.w3.org/2000/svg",r),i&&St(n,i,e),o&>(n,null,t,e)):(n=document.createElement(r),i&&St(n,i,e),o&>(n,null,t,e))}return t.domNode=n,n}function St(t,e,n){for(let r=0;r0?(i=Tt.pop()).clear():i=new Map,It(i,e,o,s));var h=Ot(f),d=h?i.get(h):null;if(null==d)t.insertBefore(mt(f,r),a.domNode),f=n[++u];else{var g=e[d];Ct(g,f,r),e[d]=void 0,t.insertBefore(g.domNode,a.domNode),f=n[++u]}}else c=e[--s];else a=e[++o];if(o>s){var m=n[l+1]?n[l+1].domNode:null;for(let e=u;e<=l;e++)t.insertBefore(mt(n[e],r),m)}else if(u>l)for(let t=o;t<=s;t++){var v=e[t];v&&At(v,r&&r.refs)}i&&Tt.push(i)}(r,t.children,e.children,n),gt(r,t,e,n),i=r),e.domNode=i,i!==r&&r.parentNode&&r.parentNode.replaceChild(i,r),i}{const i=r.parentNode,o=r.nextSibling;At(t,n&&n.refs);const s=mt(e,n);return i&&i.insertBefore(s,o),e.domNode=s,s}}let Tt=[new Map,new Map,new Map,new Map];function At(t,e,n=!0){const{domNode:r,props:i,children:o,component:s}=t,a=i&&i.ref;if(s)"function"==typeof a?a(null):e&&a&&e[a]===s&&delete e[a],s.destroy&&s.destroy();else if("function"==typeof a?a(null):e&&a&&e[a]===r&&delete e[a],o)for(let t=0;t{this.resolveNextUpdatePromise=t}))),this.nextUpdatePromise}performUpdates(){for(;this.updateRequests.length>0;)this.updateRequests.shift()();for(this.pendingAnimationFrame=null;this.readRequests.length>0;)this.readRequests.shift()();if(this.nextUpdatePromise){let t=this.resolveNextUpdatePromise;this.nextUpdatePromise=null,this.resolveNextUpdatePromise=null,t()}}};let Nt=null;var Dt=function(){return Nt||(Nt=new jt),Nt};const Ft=new WeakSet;let Lt=0,Mt=0;function Rt(t){return null!=t&&!1!==t}function Bt(t,e){e.context=t,e.ambiguous&&(e.ambiguous.forEach((e=>{e.context=t})),delete e.ambiguous)}function zt(t,e=!0){if(!Rt(t.virtualNode))throw new Error((t.constructor?t.constructor.name+" instance":t)+" is not associated with a valid virtualNode. Perhaps this component was never initialized?");if(null==t.element)throw new Error((t.constructor?t.constructor.name+" instance":t)+" is not associated with a DOM element. Perhaps this component was never initialized?");let n=t.render();if(!Rt(n)){const e=t.constructor&&t.constructor.name?" in "+t.constructor.name:"";throw new Error("invalid falsy value "+n+" returned from render()"+e)}Bt(t,n),Lt++;let r=t.virtualNode,i=t.element,o=Et(r,n,{refs:t.refs,listenerContext:t});if(t.virtualNode=n,o!==i&&!e)throw new Error("The root node type changed on update, but the update was performed with the replaceNode option set to false");t.element=o,"function"==typeof t.writeAfterUpdate&&t.writeAfterUpdate(),"function"==typeof t.readAfterUpdate&&Dt().readDocument((function(){t.readAfterUpdate()})),Lt--}function qt(t,e=!0){Mt++,Ht(t.virtualNode),1===Mt&&e&&t.element.remove(),Mt--}function Ht(t){t.component&&"function"==typeof t.component.destroy?t.component.destroy():t.children&&t.children.forEach(Ht)}kt={initialize:function(t){if("function"!=typeof t.update)throw new Error("Etch components must implement `update(props, children)`.");let e=t.render();if(!Rt(e)){let n=t.constructor&&t.constructor.name?" in "+t.constructor.name:"";throw new Error("invalid falsy value "+e+" returned from render()"+n)}Bt(t,e),t.refs={},t.virtualNode=e,t.element=mt(t.virtualNode,{refs:t.refs,listenerContext:t})},update:function(t,e=!0){if(Lt>0)return zt(t,e),Promise.resolve();let n=Dt();return Ft.has(t)||(Ft.add(t),n.updateDocument((function(){Ft.delete(t),zt(t,e)}))),n.getNextUpdatePromise()},updateSync:zt,destroy:function(t,e=!0){if(Lt>0||Mt>0)return qt(t,e),Promise.resolve();let n=Dt();return n.updateDocument((function(){qt(t,e)})),n.getNextUpdatePromise()},destroySync:qt};const{initialize:Ut,update:$t,updateSync:Vt,destroy:Wt,destroySync:Gt}=kt;function Kt(t){void 0!==t&&("function"==typeof t.catch?t.catch((t=>{atom.notifications.addFatalError("Atom-Typescript error: "+t.message,{detail:t.toString(),stack:t.stack,dismissable:!0})})):atom.notifications.addFatalError("Atom-Typescript: non-promise passed to handlePromise. Please report this.",{stack:(new Error).stack,dismissable:!0}))}ft={dom:ut,render:mt,initialize:Ut,update:$t,updateSync:Vt,destroy:Wt,destroySync:Gt,setScheduler:function(t){Nt=t},getScheduler:Dt};var Qt=function(){var t=this,e={exports:this};return function(){var n,r="Expected a function",i="__lodash_hash_undefined__",o="__lodash_placeholder__",s=16,a=32,c=64,u=128,l=256,f=1/0,p=9007199254740991,h=NaN,d=4294967295,g=[["ary",u],["bind",1],["bindKey",2],["curry",8],["curryRight",s],["flip",512],["partial",a],["partialRight",c],["rearg",l]],m="[object Arguments]",v="[object Array]",y="[object Boolean]",w="[object Date]",b="[object Error]",_="[object Function]",x="[object GeneratorFunction]",S="[object Map]",k="[object Number]",E="[object Object]",C="[object Promise]",A="[object RegExp]",P="[object Set]",O="[object String]",I="[object Symbol]",j="[object WeakMap]",N="[object ArrayBuffer]",D="[object DataView]",F="[object Float32Array]",L="[object Float64Array]",M="[object Int8Array]",R="[object Int16Array]",B="[object Int32Array]",z="[object Uint8Array]",q="[object Uint8ClampedArray]",H="[object Uint16Array]",U="[object Uint32Array]",$=/\b__p \+= '';/g,V=/\b(__p \+=) '' \+/g,W=/(__e\(.*?\)|\b__t\)) \+\n'';/g,G=/&(?:amp|lt|gt|quot|#39);/g,K=/[&<>"']/g,Q=RegExp(G.source),Z=RegExp(K.source),J=/<%-([\s\S]+?)%>/g,Y=/<%([\s\S]+?)%>/g,X=/<%=([\s\S]+?)%>/g,tt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,et=/^\w*$/,nt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,rt=/[\\^$.*+?()[\]{}|]/g,it=RegExp(rt.source),ot=/^\s+/,st=/\s/,at=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,ct=/\{\n\/\* \[wrapped with (.+)\] \*/,ut=/,? & /,lt=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,ft=/[()=,{}\[\]\/\s]/,pt=/\\(\\)?/g,ht=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,dt=/\w*$/,gt=/^[-+]0x[0-9a-f]+$/i,mt=/^0b[01]+$/i,vt=/^\[object .+?Constructor\]$/,yt=/^0o[0-7]+$/i,wt=/^(?:0|[1-9]\d*)$/,bt=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,_t=/($^)/,xt=/['\n\r\u2028\u2029\\]/g,St="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",kt="\\u2700-\\u27bf",Et="a-z\\xdf-\\xf6\\xf8-\\xff",Ct="A-Z\\xc0-\\xd6\\xd8-\\xde",Tt="\\ufe0e\\ufe0f",At="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Pt="['’]",Ot="[\\ud800-\\udfff]",It="["+At+"]",jt="["+St+"]",Nt="\\d+",Dt="[\\u2700-\\u27bf]",Ft="["+Et+"]",Lt="[^\\ud800-\\udfff"+At+Nt+kt+Et+Ct+"]",Mt="\\ud83c[\\udffb-\\udfff]",Rt="[^\\ud800-\\udfff]",Bt="(?:\\ud83c[\\udde6-\\uddff]){2}",zt="[\\ud800-\\udbff][\\udc00-\\udfff]",qt="["+Ct+"]",Ht="(?:"+Ft+"|"+Lt+")",Ut="(?:"+qt+"|"+Lt+")",$t="(?:['’](?:d|ll|m|re|s|t|ve))?",Vt="(?:['’](?:D|LL|M|RE|S|T|VE))?",Wt="(?:"+jt+"|"+Mt+")"+"?",Gt="[\\ufe0e\\ufe0f]?",Kt=Gt+Wt+("(?:\\u200d(?:"+[Rt,Bt,zt].join("|")+")"+Gt+Wt+")*"),Qt="(?:"+[Dt,Bt,zt].join("|")+")"+Kt,Zt="(?:"+[Rt+jt+"?",jt,Bt,zt,Ot].join("|")+")",Jt=RegExp(Pt,"g"),Yt=RegExp(jt,"g"),Xt=RegExp(Mt+"(?="+Mt+")|"+Zt+Kt,"g"),te=RegExp([qt+"?"+Ft+"+"+$t+"(?="+[It,qt,"$"].join("|")+")",Ut+"+"+Vt+"(?="+[It,qt+Ht,"$"].join("|")+")",qt+"?"+Ht+"+"+$t,qt+"+"+Vt,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Nt,Qt].join("|"),"g"),ee=RegExp("[\\u200d\\ud800-\\udfff"+St+Tt+"]"),ne=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,re=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],ie=-1,oe={};oe[F]=oe[L]=oe[M]=oe[R]=oe[B]=oe[z]=oe[q]=oe[H]=oe[U]=!0,oe[m]=oe[v]=oe[N]=oe[y]=oe[D]=oe[w]=oe[b]=oe[_]=oe[S]=oe[k]=oe[E]=oe[A]=oe[P]=oe[O]=oe[j]=!1;var se={};se[m]=se[v]=se[N]=se[D]=se[y]=se[w]=se[F]=se[L]=se[M]=se[R]=se[B]=se[S]=se[k]=se[E]=se[A]=se[P]=se[O]=se[I]=se[z]=se[q]=se[H]=se[U]=!0,se[b]=se[_]=se[j]=!1;var ae={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},ce=parseFloat,ue=parseInt,le="object"==typeof T&&T&&T.Object===Object&&T,fe="object"==typeof self&&self&&self.Object===Object&&self,pe=le||fe||Function("return this")(),he="object"==typeof t&&t&&!t.nodeType&&t,de=he&&"object"==typeof e&&e&&!e.nodeType&&e,ge=de&&de.exports===he,me=ge&&le.process,ve=function(){try{var t=de&&de.require&&de.require("util").types;return t||me&&me.binding&&me.binding("util")}catch(t){}}(),ye=ve&&ve.isArrayBuffer,we=ve&&ve.isDate,be=ve&&ve.isMap,_e=ve&&ve.isRegExp,xe=ve&&ve.isSet,Se=ve&&ve.isTypedArray;function ke(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function Ee(t,e,n,r){for(var i=-1,o=null==t?0:t.length;++i-1}function Ie(t,e,n){for(var r=-1,i=null==t?0:t.length;++r-1;);return n}function tn(t,e){for(var n=t.length;n--&&ze(e,t[n],0)>-1;);return n}function en(t,e){for(var n=t.length,r=0;n--;)t[n]===e&&++r;return r}var nn=Ve({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),rn=Ve({"&":"&","<":"<",">":">",'"':""","'":"'"});function on(t){return"\\"+ae[t]}function sn(t){return ee.test(t)}function an(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function cn(t,e){return function(n){return t(e(n))}}function un(t,e){for(var n=-1,r=t.length,i=0,s=[];++n",""":'"',"'":"'"});var mn=function t(e){var T,st=(e=null==e?pe:mn.defaults(pe.Object(),e,mn.pick(pe,re))).Array,St=e.Date,kt=e.Error,Et=e.Function,Ct=e.Math,Tt=e.Object,At=e.RegExp,Pt=e.String,Ot=e.TypeError,It=st.prototype,jt=Et.prototype,Nt=Tt.prototype,Dt=e["__core-js_shared__"],Ft=jt.toString,Lt=Nt.hasOwnProperty,Mt=0,Rt=(T=/[^.]+$/.exec(Dt&&Dt.keys&&Dt.keys.IE_PROTO||""))?"Symbol(src)_1."+T:"",Bt=Nt.toString,zt=Ft.call(Tt),qt=pe._,Ht=At("^"+Ft.call(Lt).replace(rt,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ut=ge?e.Buffer:n,$t=e.Symbol,Vt=e.Uint8Array,Wt=Ut?Ut.allocUnsafe:n,Gt=cn(Tt.getPrototypeOf,Tt),Kt=Tt.create,Qt=Nt.propertyIsEnumerable,Zt=It.splice,Xt=$t?$t.isConcatSpreadable:n,ee=$t?$t.iterator:n,ae=$t?$t.toStringTag:n,le=function(){try{var t=ho(Tt,"defineProperty");return t({},"",{}),t}catch(t){}}(),fe=e.clearTimeout!==pe.clearTimeout&&e.clearTimeout,he=St&&St.now!==pe.Date.now&&St.now,de=e.setTimeout!==pe.setTimeout&&e.setTimeout,me=Ct.ceil,ve=Ct.floor,Me=Tt.getOwnPropertySymbols,Ve=Ut?Ut.isBuffer:n,vn=e.isFinite,yn=It.join,wn=cn(Tt.keys,Tt),bn=Ct.max,_n=Ct.min,xn=St.now,Sn=e.parseInt,kn=Ct.random,En=It.reverse,Cn=ho(e,"DataView"),Tn=ho(e,"Map"),An=ho(e,"Promise"),Pn=ho(e,"Set"),On=ho(e,"WeakMap"),In=ho(Tt,"create"),jn=On&&new On,Nn={},Dn=qo(Cn),Fn=qo(Tn),Ln=qo(An),Mn=qo(Pn),Rn=qo(On),Bn=$t?$t.prototype:n,zn=Bn?Bn.valueOf:n,qn=Bn?Bn.toString:n;function Hn(t){if(ia(t)&&!Gs(t)&&!(t instanceof Wn)){if(t instanceof Vn)return t;if(Lt.call(t,"__wrapped__"))return Ho(t)}return new Vn(t)}var Un=function(){function t(){}return function(e){if(!ra(e))return{};if(Kt)return Kt(e);t.prototype=e;var r=new t;return t.prototype=n,r}}();function $n(){}function Vn(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=n}function Wn(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=d,this.__views__=[]}function Gn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e=e?t:e)),t}function lr(t,e,r,i,o,s){var a,c=1&e,u=2&e,l=4&e;if(r&&(a=o?r(t,i,o,s):r(t)),a!==n)return a;if(!ra(t))return t;var f=Gs(t);if(f){if(a=function(t){var e=t.length,n=new t.constructor(e);e&&"string"==typeof t[0]&&Lt.call(t,"index")&&(n.index=t.index,n.input=t.input);return n}(t),!c)return Ii(t,a)}else{var p=vo(t),h=p==_||p==x;if(Js(t))return Ei(t,c);if(p==E||p==m||h&&!o){if(a=u||h?{}:wo(t),!c)return u?function(t,e){return ji(t,mo(t),e)}(t,function(t,e){return t&&ji(e,Fa(e),t)}(a,t)):function(t,e){return ji(t,go(t),e)}(t,sr(a,t))}else{if(!se[p])return o?t:{};a=function(t,e,n){var r=t.constructor;switch(e){case N:return Ci(t);case y:case w:return new r(+t);case D:return function(t,e){var n=e?Ci(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case F:case L:case M:case R:case B:case z:case q:case H:case U:return Ti(t,n);case S:return new r;case k:case O:return new r(t);case A:return function(t){var e=new t.constructor(t.source,dt.exec(t));return e.lastIndex=t.lastIndex,e}(t);case P:return new r;case I:return i=t,zn?Tt(zn.call(i)):{}}var i}(t,p,c)}}s||(s=new Jn);var d=s.get(t);if(d)return d;s.set(t,a),ua(t)?t.forEach((function(n){a.add(lr(n,e,r,n,t,s))})):oa(t)&&t.forEach((function(n,i){a.set(i,lr(n,e,r,i,t,s))}));var g=f?n:(l?u?so:oo:u?Fa:Da)(t);return Ce(g||t,(function(n,i){g&&(n=t[i=n]),rr(a,i,lr(n,e,r,i,t,s))})),a}function fr(t,e,r){var i=r.length;if(null==t)return!i;for(t=Tt(t);i--;){var o=r[i],s=e[o],a=t[o];if(a===n&&!(o in t)||!s(a))return!1}return!0}function pr(t,e,i){if("function"!=typeof t)throw new Ot(r);return Do((function(){t.apply(n,i)}),e)}function hr(t,e,n,r){var i=-1,o=Oe,s=!0,a=t.length,c=[],u=e.length;if(!a)return c;n&&(e=je(e,Ze(n))),r?(o=Ie,s=!1):e.length>=200&&(o=Ye,s=!1,e=new Zn(e));t:for(;++i-1},Kn.prototype.set=function(t,e){var n=this.__data__,r=ir(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this},Qn.prototype.clear=function(){this.size=0,this.__data__={hash:new Gn,map:new(Tn||Kn),string:new Gn}},Qn.prototype.delete=function(t){var e=fo(this,t).delete(t);return this.size-=e?1:0,e},Qn.prototype.get=function(t){return fo(this,t).get(t)},Qn.prototype.has=function(t){return fo(this,t).has(t)},Qn.prototype.set=function(t,e){var n=fo(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this},Zn.prototype.add=Zn.prototype.push=function(t){return this.__data__.set(t,i),this},Zn.prototype.has=function(t){return this.__data__.has(t)},Jn.prototype.clear=function(){this.__data__=new Kn,this.size=0},Jn.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},Jn.prototype.get=function(t){return this.__data__.get(t)},Jn.prototype.has=function(t){return this.__data__.has(t)},Jn.prototype.set=function(t,e){var n=this.__data__;if(n instanceof Kn){var r=n.__data__;if(!Tn||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new Qn(r)}return n.set(t,e),this.size=n.size,this};var dr=Fi(xr),gr=Fi(Sr,!0);function mr(t,e){var n=!0;return dr(t,(function(t,r,i){return n=!!e(t,r,i)})),n}function vr(t,e,r){for(var i=-1,o=t.length;++i0&&n(a)?e>1?wr(a,e-1,n,r,i):Ne(i,a):r||(i[i.length]=a)}return i}var br=Li(),_r=Li(!0);function xr(t,e){return t&&br(t,e,Da)}function Sr(t,e){return t&&_r(t,e,Da)}function kr(t,e){return Pe(e,(function(e){return ta(t[e])}))}function Er(t,e){for(var r=0,i=(e=_i(e,t)).length;null!=t&&re}function Pr(t,e){return null!=t&&Lt.call(t,e)}function Or(t,e){return null!=t&&e in Tt(t)}function Ir(t,e,r){for(var i=r?Ie:Oe,o=t[0].length,s=t.length,a=s,c=st(s),u=1/0,l=[];a--;){var f=t[a];a&&e&&(f=je(f,Ze(e))),u=_n(f.length,u),c[a]=!r&&(e||o>=120&&f.length>=120)?new Zn(a&&f):n}f=t[0];var p=-1,h=c[0];t:for(;++p=a?c:c*("desc"==n[r]?-1:1)}return t.index-e.index}(t,e,n)}))}function Gr(t,e,n){for(var r=-1,i=e.length,o={};++r-1;)a!==t&&Zt.call(a,c,1),Zt.call(t,c,1);return t}function Qr(t,e){for(var n=t?e.length:0,r=n-1;n--;){var i=e[n];if(n==r||i!==o){var o=i;_o(i)?Zt.call(t,i,1):hi(t,i)}}return t}function Zr(t,e){return t+ve(kn()*(e-t+1))}function Jr(t,e){var n="";if(!t||e<1||e>p)return n;do{e%2&&(n+=t),(e=ve(e/2))&&(t+=t)}while(e);return n}function Yr(t,e){return Fo(Po(t,e,sc),t+"")}function Xr(t){return Xn(Ua(t))}function ti(t,e){var n=Ua(t);return Ro(n,ur(e,0,n.length))}function ei(t,e,r,i){if(!ra(t))return t;for(var o=-1,s=(e=_i(e,t)).length,a=s-1,c=t;null!=c&&++oi?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var o=st(i);++r>>1,s=t[o];null!==s&&!fa(s)&&(n?s<=e:s=200){var u=e?null:Ji(t);if(u)return ln(u);s=!1,i=Ye,c=new Zn}else c=e?[]:a;t:for(;++r=i?t:oi(t,e,r)}var ki=fe||function(t){return pe.clearTimeout(t)};function Ei(t,e){if(e)return t.slice();var n=t.length,r=Wt?Wt(n):new t.constructor(n);return t.copy(r),r}function Ci(t){var e=new t.constructor(t.byteLength);return new Vt(e).set(new Vt(t)),e}function Ti(t,e){var n=e?Ci(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function Ai(t,e){if(t!==e){var r=t!==n,i=null===t,o=t==t,s=fa(t),a=e!==n,c=null===e,u=e==e,l=fa(e);if(!c&&!l&&!s&&t>e||s&&a&&u&&!c&&!l||i&&a&&u||!r&&u||!o)return 1;if(!i&&!s&&!l&&t1?r[o-1]:n,a=o>2?r[2]:n;for(s=t.length>3&&"function"==typeof s?(o--,s):n,a&&xo(r[0],r[1],a)&&(s=o<3?n:s,o=1),e=Tt(e);++i-1?o[s?e[a]:a]:n}}function qi(t){return io((function(e){var i=e.length,o=i,s=Vn.prototype.thru;for(t&&e.reverse();o--;){var a=e[o];if("function"!=typeof a)throw new Ot(r);if(s&&!c&&"wrapper"==co(a))var c=new Vn([],!0)}for(o=c?o:i;++o1&&y.reverse(),p&&lc))return!1;var l=s.get(t),f=s.get(e);if(l&&f)return l==e&&f==t;var p=-1,h=!0,d=2&r?new Zn:n;for(s.set(t,e),s.set(e,t);++p-1&&t%1==0&&t1?"& ":"")+e[r],e=e.join(n>2?", ":" "),t.replace(at,"{\n/* [wrapped with "+e+"] */\n")}(r,function(t,e){return Ce(g,(function(n){var r="_."+n[0];e&n[1]&&!Oe(t,r)&&t.push(r)})),t.sort()}(function(t){var e=t.match(ct);return e?e[1].split(ut):[]}(r),n)))}function Mo(t){var e=0,r=0;return function(){var i=xn(),o=16-(i-r);if(r=i,o>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(n,arguments)}}function Ro(t,e){var r=-1,i=t.length,o=i-1;for(e=e===n?i:e;++r1?t[e-1]:n;return r="function"==typeof r?(t.pop(),r):n,cs(t,r)}));function gs(t){var e=Hn(t);return e.__chain__=!0,e}function ms(t,e){return e(t)}var vs=io((function(t){var e=t.length,r=e?t[0]:0,i=this.__wrapped__,o=function(e){return cr(e,t)};return!(e>1||this.__actions__.length)&&i instanceof Wn&&_o(r)?((i=i.slice(r,+r+(e?1:0))).__actions__.push({func:ms,args:[o],thisArg:n}),new Vn(i,this.__chain__).thru((function(t){return e&&!t.length&&t.push(n),t}))):this.thru(o)}));var ys=Ni((function(t,e,n){Lt.call(t,n)?++t[n]:ar(t,n,1)}));var ws=zi(Wo),bs=zi(Go);function _s(t,e){return(Gs(t)?Ce:dr)(t,lo(e,3))}function xs(t,e){return(Gs(t)?Te:gr)(t,lo(e,3))}var Ss=Ni((function(t,e,n){Lt.call(t,n)?t[n].push(e):ar(t,n,[e])}));var ks=Yr((function(t,e,n){var r=-1,i="function"==typeof e,o=Qs(t)?st(t.length):[];return dr(t,(function(t){o[++r]=i?ke(e,t,n):jr(t,e,n)})),o})),Es=Ni((function(t,e,n){ar(t,n,e)}));function Cs(t,e){return(Gs(t)?je:qr)(t,lo(e,3))}var Ts=Ni((function(t,e,n){t[n?0:1].push(e)}),(function(){return[[],[]]}));var As=Yr((function(t,e){if(null==t)return[];var n=e.length;return n>1&&xo(t,e[0],e[1])?e=[]:n>2&&xo(e[0],e[1],e[2])&&(e=[e[0]]),Wr(t,wr(e,1),[])})),Ps=he||function(){return pe.Date.now()};function Os(t,e,r){return e=r?n:e,e=t&&null==e?t.length:e,Xi(t,u,n,n,n,n,e)}function Is(t,e){var i;if("function"!=typeof e)throw new Ot(r);return t=va(t),function(){return--t>0&&(i=e.apply(this,arguments)),t<=1&&(e=n),i}}var js=Yr((function(t,e,n){var r=1;if(n.length){var i=un(n,uo(js));r|=a}return Xi(t,r,e,n,i)})),Ns=Yr((function(t,e,n){var r=3;if(n.length){var i=un(n,uo(Ns));r|=a}return Xi(e,r,t,n,i)}));function Ds(t,e,i){var o,s,a,c,u,l,f=0,p=!1,h=!1,d=!0;if("function"!=typeof t)throw new Ot(r);function g(e){var r=o,i=s;return o=s=n,f=e,c=t.apply(i,r)}function m(t){return f=t,u=Do(y,e),p?g(t):c}function v(t){var r=t-l;return l===n||r>=e||r<0||h&&t-f>=a}function y(){var t=Ps();if(v(t))return w(t);u=Do(y,function(t){var n=e-(t-l);return h?_n(n,a-(t-f)):n}(t))}function w(t){return u=n,d&&o?g(t):(o=s=n,c)}function b(){var t=Ps(),r=v(t);if(o=arguments,s=this,l=t,r){if(u===n)return m(l);if(h)return ki(u),u=Do(y,e),g(l)}return u===n&&(u=Do(y,e)),c}return e=wa(e)||0,ra(i)&&(p=!!i.leading,a=(h="maxWait"in i)?bn(wa(i.maxWait)||0,e):a,d="trailing"in i?!!i.trailing:d),b.cancel=function(){u!==n&&ki(u),f=0,o=l=s=u=n},b.flush=function(){return u===n?c:w(Ps())},b}var Fs=Yr((function(t,e){return pr(t,1,e)})),Ls=Yr((function(t,e,n){return pr(t,wa(e)||0,n)}));function Ms(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new Ot(r);var n=function(){var r=arguments,i=e?e.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var s=t.apply(this,r);return n.cache=o.set(i,s)||o,s};return n.cache=new(Ms.Cache||Qn),n}function Rs(t){if("function"!=typeof t)throw new Ot(r);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}Ms.Cache=Qn;var Bs=xi((function(t,e){var n=(e=1==e.length&&Gs(e[0])?je(e[0],Ze(lo())):je(wr(e,1),Ze(lo()))).length;return Yr((function(r){for(var i=-1,o=_n(r.length,n);++i=e})),Ws=Nr(function(){return arguments}())?Nr:function(t){return ia(t)&&Lt.call(t,"callee")&&!Qt.call(t,"callee")},Gs=st.isArray,Ks=ye?Ze(ye):function(t){return ia(t)&&Tr(t)==N};function Qs(t){return null!=t&&na(t.length)&&!ta(t)}function Zs(t){return ia(t)&&Qs(t)}var Js=Ve||wc,Ys=we?Ze(we):function(t){return ia(t)&&Tr(t)==w};function Xs(t){if(!ia(t))return!1;var e=Tr(t);return e==b||"[object DOMException]"==e||"string"==typeof t.message&&"string"==typeof t.name&&!aa(t)}function ta(t){if(!ra(t))return!1;var e=Tr(t);return e==_||e==x||"[object AsyncFunction]"==e||"[object Proxy]"==e}function ea(t){return"number"==typeof t&&t==va(t)}function na(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=p}function ra(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function ia(t){return null!=t&&"object"==typeof t}var oa=be?Ze(be):function(t){return ia(t)&&vo(t)==S};function sa(t){return"number"==typeof t||ia(t)&&Tr(t)==k}function aa(t){if(!ia(t)||Tr(t)!=E)return!1;var e=Gt(t);if(null===e)return!0;var n=Lt.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&Ft.call(n)==zt}var ca=_e?Ze(_e):function(t){return ia(t)&&Tr(t)==A};var ua=xe?Ze(xe):function(t){return ia(t)&&vo(t)==P};function la(t){return"string"==typeof t||!Gs(t)&&ia(t)&&Tr(t)==O}function fa(t){return"symbol"==typeof t||ia(t)&&Tr(t)==I}var pa=Se?Ze(Se):function(t){return ia(t)&&na(t.length)&&!!oe[Tr(t)]};var ha=Ki(zr),da=Ki((function(t,e){return t<=e}));function ga(t){if(!t)return[];if(Qs(t))return la(t)?hn(t):Ii(t);if(ee&&t[ee])return function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}(t[ee]());var e=vo(t);return(e==S?an:e==P?ln:Ua)(t)}function ma(t){return t?(t=wa(t))===f||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function va(t){var e=ma(t),n=e%1;return e==e?n?e-n:e:0}function ya(t){return t?ur(va(t),0,d):0}function wa(t){if("number"==typeof t)return t;if(fa(t))return h;if(ra(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=ra(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Qe(t);var n=mt.test(t);return n||yt.test(t)?ue(t.slice(2),n?2:8):gt.test(t)?h:+t}function ba(t){return ji(t,Fa(t))}function _a(t){return null==t?"":fi(t)}var xa=Di((function(t,e){if(Co(e)||Qs(e))ji(e,Da(e),t);else for(var n in e)Lt.call(e,n)&&rr(t,n,e[n])})),Sa=Di((function(t,e){ji(e,Fa(e),t)})),ka=Di((function(t,e,n,r){ji(e,Fa(e),t,r)})),Ea=Di((function(t,e,n,r){ji(e,Da(e),t,r)})),Ca=io(cr);var Ta=Yr((function(t,e){t=Tt(t);var r=-1,i=e.length,o=i>2?e[2]:n;for(o&&xo(e[0],e[1],o)&&(i=1);++r1),e})),ji(t,so(t),n),r&&(n=lr(n,7,no));for(var i=e.length;i--;)hi(n,e[i]);return n}));var Ba=io((function(t,e){return null==t?{}:function(t,e){return Gr(t,e,(function(e,n){return Oa(t,n)}))}(t,e)}));function za(t,e){if(null==t)return{};var n=je(so(t),(function(t){return[t]}));return e=lo(e),Gr(t,n,(function(t,n){return e(t,n[0])}))}var qa=Yi(Da),Ha=Yi(Fa);function Ua(t){return null==t?[]:Je(t,Da(t))}var $a=Ri((function(t,e,n){return e=e.toLowerCase(),t+(n?Va(e):e)}));function Va(t){return Xa(_a(t).toLowerCase())}function Wa(t){return(t=_a(t))&&t.replace(bt,nn).replace(Yt,"")}var Ga=Ri((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Ka=Ri((function(t,e,n){return t+(n?" ":"")+e.toLowerCase()})),Qa=Mi("toLowerCase");var Za=Ri((function(t,e,n){return t+(n?"_":"")+e.toLowerCase()}));var Ja=Ri((function(t,e,n){return t+(n?" ":"")+Xa(e)}));var Ya=Ri((function(t,e,n){return t+(n?" ":"")+e.toUpperCase()})),Xa=Mi("toUpperCase");function tc(t,e,r){return t=_a(t),(e=r?n:e)===n?function(t){return ne.test(t)}(t)?function(t){return t.match(te)||[]}(t):function(t){return t.match(lt)||[]}(t):t.match(e)||[]}var ec=Yr((function(t,e){try{return ke(t,n,e)}catch(t){return Xs(t)?t:new kt(t)}})),nc=io((function(t,e){return Ce(e,(function(e){e=zo(e),ar(t,e,js(t[e],t))})),t}));function rc(t){return function(){return t}}var ic=qi(),oc=qi(!0);function sc(t){return t}function ac(t){return Mr("function"==typeof t?t:lr(t,1))}var cc=Yr((function(t,e){return function(n){return jr(n,t,e)}})),uc=Yr((function(t,e){return function(n){return jr(t,n,e)}}));function lc(t,e,n){var r=Da(e),i=kr(e,r);null!=n||ra(e)&&(i.length||!r.length)||(n=e,e=t,t=this,i=kr(e,Da(e)));var o=!(ra(n)&&"chain"in n&&!n.chain),s=ta(t);return Ce(i,(function(n){var r=e[n];t[n]=r,s&&(t.prototype[n]=function(){var e=this.__chain__;if(o||e){var n=t(this.__wrapped__),i=n.__actions__=Ii(this.__actions__);return i.push({func:r,args:arguments,thisArg:t}),n.__chain__=e,n}return r.apply(t,Ne([this.value()],arguments))})})),t}function fc(){}var pc=Vi(je),hc=Vi(Ae),dc=Vi(Le);function gc(t){return So(t)?$e(zo(t)):function(t){return function(e){return Er(e,t)}}(t)}var mc=Gi(),vc=Gi(!0);function yc(){return[]}function wc(){return!1}var bc=$i((function(t,e){return t+e}),0),_c=Zi("ceil"),xc=$i((function(t,e){return t/e}),1),Sc=Zi("floor");var kc=$i((function(t,e){return t*e}),1),Ec=Zi("round"),Cc=$i((function(t,e){return t-e}),0);return Hn.after=function(t,e){if("function"!=typeof e)throw new Ot(r);return t=va(t),function(){if(--t<1)return e.apply(this,arguments)}},Hn.ary=Os,Hn.assign=xa,Hn.assignIn=Sa,Hn.assignInWith=ka,Hn.assignWith=Ea,Hn.at=Ca,Hn.before=Is,Hn.bind=js,Hn.bindAll=nc,Hn.bindKey=Ns,Hn.castArray=function(){if(!arguments.length)return[];var t=arguments[0];return Gs(t)?t:[t]},Hn.chain=gs,Hn.chunk=function(t,e,r){e=(r?xo(t,e,r):e===n)?1:bn(va(e),0);var i=null==t?0:t.length;if(!i||e<1)return[];for(var o=0,s=0,a=st(me(i/e));oo?0:o+r),(i=i===n||i>o?o:va(i))<0&&(i+=o),i=r>i?0:ya(i);r>>0)?(t=_a(t))&&("string"==typeof e||null!=e&&!ca(e))&&!(e=fi(e))&&sn(t)?Si(hn(t),0,r):t.split(e,r):[]},Hn.spread=function(t,e){if("function"!=typeof t)throw new Ot(r);return e=null==e?0:bn(va(e),0),Yr((function(n){var r=n[e],i=Si(n,0,e);return r&&Ne(i,r),ke(t,this,i)}))},Hn.tail=function(t){var e=null==t?0:t.length;return e?oi(t,1,e):[]},Hn.take=function(t,e,r){return t&&t.length?oi(t,0,(e=r||e===n?1:va(e))<0?0:e):[]},Hn.takeRight=function(t,e,r){var i=null==t?0:t.length;return i?oi(t,(e=i-(e=r||e===n?1:va(e)))<0?0:e,i):[]},Hn.takeRightWhile=function(t,e){return t&&t.length?gi(t,lo(e,3),!1,!0):[]},Hn.takeWhile=function(t,e){return t&&t.length?gi(t,lo(e,3)):[]},Hn.tap=function(t,e){return e(t),t},Hn.throttle=function(t,e,n){var i=!0,o=!0;if("function"!=typeof t)throw new Ot(r);return ra(n)&&(i="leading"in n?!!n.leading:i,o="trailing"in n?!!n.trailing:o),Ds(t,e,{leading:i,maxWait:e,trailing:o})},Hn.thru=ms,Hn.toArray=ga,Hn.toPairs=qa,Hn.toPairsIn=Ha,Hn.toPath=function(t){return Gs(t)?je(t,zo):fa(t)?[t]:Ii(Bo(_a(t)))},Hn.toPlainObject=ba,Hn.transform=function(t,e,n){var r=Gs(t),i=r||Js(t)||pa(t);if(e=lo(e,4),null==n){var o=t&&t.constructor;n=i?r?new o:[]:ra(t)&&ta(o)?Un(Gt(t)):{}}return(i?Ce:xr)(t,(function(t,r,i){return e(n,t,r,i)})),n},Hn.unary=function(t){return Os(t,1)},Hn.union=is,Hn.unionBy=os,Hn.unionWith=ss,Hn.uniq=function(t){return t&&t.length?pi(t):[]},Hn.uniqBy=function(t,e){return t&&t.length?pi(t,lo(e,2)):[]},Hn.uniqWith=function(t,e){return e="function"==typeof e?e:n,t&&t.length?pi(t,n,e):[]},Hn.unset=function(t,e){return null==t||hi(t,e)},Hn.unzip=as,Hn.unzipWith=cs,Hn.update=function(t,e,n){return null==t?t:di(t,e,bi(n))},Hn.updateWith=function(t,e,r,i){return i="function"==typeof i?i:n,null==t?t:di(t,e,bi(r),i)},Hn.values=Ua,Hn.valuesIn=function(t){return null==t?[]:Je(t,Fa(t))},Hn.without=us,Hn.words=tc,Hn.wrap=function(t,e){return zs(bi(e),t)},Hn.xor=ls,Hn.xorBy=fs,Hn.xorWith=ps,Hn.zip=hs,Hn.zipObject=function(t,e){return yi(t||[],e||[],rr)},Hn.zipObjectDeep=function(t,e){return yi(t||[],e||[],ei)},Hn.zipWith=ds,Hn.entries=qa,Hn.entriesIn=Ha,Hn.extend=Sa,Hn.extendWith=ka,lc(Hn,Hn),Hn.add=bc,Hn.attempt=ec,Hn.camelCase=$a,Hn.capitalize=Va,Hn.ceil=_c,Hn.clamp=function(t,e,r){return r===n&&(r=e,e=n),r!==n&&(r=(r=wa(r))==r?r:0),e!==n&&(e=(e=wa(e))==e?e:0),ur(wa(t),e,r)},Hn.clone=function(t){return lr(t,4)},Hn.cloneDeep=function(t){return lr(t,5)},Hn.cloneDeepWith=function(t,e){return lr(t,5,e="function"==typeof e?e:n)},Hn.cloneWith=function(t,e){return lr(t,4,e="function"==typeof e?e:n)},Hn.conformsTo=function(t,e){return null==e||fr(t,e,Da(e))},Hn.deburr=Wa,Hn.defaultTo=function(t,e){return null==t||t!=t?e:t},Hn.divide=xc,Hn.endsWith=function(t,e,r){t=_a(t),e=fi(e);var i=t.length,o=r=r===n?i:ur(va(r),0,i);return(r-=e.length)>=0&&t.slice(r,o)==e},Hn.eq=Us,Hn.escape=function(t){return(t=_a(t))&&Z.test(t)?t.replace(K,rn):t},Hn.escapeRegExp=function(t){return(t=_a(t))&&it.test(t)?t.replace(rt,"\\$&"):t},Hn.every=function(t,e,r){var i=Gs(t)?Ae:mr;return r&&xo(t,e,r)&&(e=n),i(t,lo(e,3))},Hn.find=ws,Hn.findIndex=Wo,Hn.findKey=function(t,e){return Re(t,lo(e,3),xr)},Hn.findLast=bs,Hn.findLastIndex=Go,Hn.findLastKey=function(t,e){return Re(t,lo(e,3),Sr)},Hn.floor=Sc,Hn.forEach=_s,Hn.forEachRight=xs,Hn.forIn=function(t,e){return null==t?t:br(t,lo(e,3),Fa)},Hn.forInRight=function(t,e){return null==t?t:_r(t,lo(e,3),Fa)},Hn.forOwn=function(t,e){return t&&xr(t,lo(e,3))},Hn.forOwnRight=function(t,e){return t&&Sr(t,lo(e,3))},Hn.get=Pa,Hn.gt=$s,Hn.gte=Vs,Hn.has=function(t,e){return null!=t&&yo(t,e,Pr)},Hn.hasIn=Oa,Hn.head=Qo,Hn.identity=sc,Hn.includes=function(t,e,n,r){t=Qs(t)?t:Ua(t),n=n&&!r?va(n):0;var i=t.length;return n<0&&(n=bn(i+n,0)),la(t)?n<=i&&t.indexOf(e,n)>-1:!!i&&ze(t,e,n)>-1},Hn.indexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=null==n?0:va(n);return i<0&&(i=bn(r+i,0)),ze(t,e,i)},Hn.inRange=function(t,e,r){return e=ma(e),r===n?(r=e,e=0):r=ma(r),function(t,e,n){return t>=_n(e,n)&&t=-9007199254740991&&t<=p},Hn.isSet=ua,Hn.isString=la,Hn.isSymbol=fa,Hn.isTypedArray=pa,Hn.isUndefined=function(t){return t===n},Hn.isWeakMap=function(t){return ia(t)&&vo(t)==j},Hn.isWeakSet=function(t){return ia(t)&&"[object WeakSet]"==Tr(t)},Hn.join=function(t,e){return null==t?"":yn.call(t,e)},Hn.kebabCase=Ga,Hn.last=Xo,Hn.lastIndexOf=function(t,e,r){var i=null==t?0:t.length;if(!i)return-1;var o=i;return r!==n&&(o=(o=va(r))<0?bn(i+o,0):_n(o,i-1)),e==e?function(t,e,n){for(var r=n+1;r--;)if(t[r]===e)return r;return r}(t,e,o):Be(t,He,o,!0)},Hn.lowerCase=Ka,Hn.lowerFirst=Qa,Hn.lt=ha,Hn.lte=da,Hn.max=function(t){return t&&t.length?vr(t,sc,Ar):n},Hn.maxBy=function(t,e){return t&&t.length?vr(t,lo(e,2),Ar):n},Hn.mean=function(t){return Ue(t,sc)},Hn.meanBy=function(t,e){return Ue(t,lo(e,2))},Hn.min=function(t){return t&&t.length?vr(t,sc,zr):n},Hn.minBy=function(t,e){return t&&t.length?vr(t,lo(e,2),zr):n},Hn.stubArray=yc,Hn.stubFalse=wc,Hn.stubObject=function(){return{}},Hn.stubString=function(){return""},Hn.stubTrue=function(){return!0},Hn.multiply=kc,Hn.nth=function(t,e){return t&&t.length?Vr(t,va(e)):n},Hn.noConflict=function(){return pe._===this&&(pe._=qt),this},Hn.noop=fc,Hn.now=Ps,Hn.pad=function(t,e,n){t=_a(t);var r=(e=va(e))?pn(t):0;if(!e||r>=e)return t;var i=(e-r)/2;return Wi(ve(i),n)+t+Wi(me(i),n)},Hn.padEnd=function(t,e,n){t=_a(t);var r=(e=va(e))?pn(t):0;return e&&re){var i=t;t=e,e=i}if(r||t%1||e%1){var o=kn();return _n(t+o*(e-t+ce("1e-"+((o+"").length-1))),e)}return Zr(t,e)},Hn.reduce=function(t,e,n){var r=Gs(t)?De:We,i=arguments.length<3;return r(t,lo(e,4),n,i,dr)},Hn.reduceRight=function(t,e,n){var r=Gs(t)?Fe:We,i=arguments.length<3;return r(t,lo(e,4),n,i,gr)},Hn.repeat=function(t,e,r){return e=(r?xo(t,e,r):e===n)?1:va(e),Jr(_a(t),e)},Hn.replace=function(){var t=arguments,e=_a(t[0]);return t.length<3?e:e.replace(t[1],t[2])},Hn.result=function(t,e,r){var i=-1,o=(e=_i(e,t)).length;for(o||(o=1,t=n);++ip)return[];var n=d,r=_n(t,d);e=lo(e),t-=d;for(var i=Ke(r,e);++n=s)return t;var c=r-pn(i);if(c<1)return i;var u=a?Si(a,0,c).join(""):t.slice(0,c);if(o===n)return u+i;if(a&&(c+=u.length-c),ca(o)){if(t.slice(c).search(o)){var l,f=u;for(o.global||(o=At(o.source,_a(dt.exec(o))+"g")),o.lastIndex=0;l=o.exec(f);)var p=l.index;u=u.slice(0,p===n?c:p)}}else if(t.indexOf(fi(o),c)!=c){var h=u.lastIndexOf(o);h>-1&&(u=u.slice(0,h))}return u+i},Hn.unescape=function(t){return(t=_a(t))&&Q.test(t)?t.replace(G,gn):t},Hn.uniqueId=function(t){var e=++Mt;return _a(t)+e},Hn.upperCase=Ya,Hn.upperFirst=Xa,Hn.each=_s,Hn.eachRight=xs,Hn.first=Qo,lc(Hn,function(){var t={};return xr(Hn,(function(e,n){Lt.call(Hn.prototype,n)||(t[n]=e)})),t}(),{chain:!1}),Hn.VERSION="4.17.21",Ce(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(t){Hn[t].placeholder=Hn})),Ce(["drop","take"],(function(t,e){Wn.prototype[t]=function(r){r=r===n?1:bn(va(r),0);var i=this.__filtered__&&!e?new Wn(this):this.clone();return i.__filtered__?i.__takeCount__=_n(r,i.__takeCount__):i.__views__.push({size:_n(r,d),type:t+(i.__dir__<0?"Right":"")}),i},Wn.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}})),Ce(["filter","map","takeWhile"],(function(t,e){var n=e+1,r=1==n||3==n;Wn.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:lo(t,3),type:n}),e.__filtered__=e.__filtered__||r,e}})),Ce(["head","last"],(function(t,e){var n="take"+(e?"Right":"");Wn.prototype[t]=function(){return this[n](1).value()[0]}})),Ce(["initial","tail"],(function(t,e){var n="drop"+(e?"":"Right");Wn.prototype[t]=function(){return this.__filtered__?new Wn(this):this[n](1)}})),Wn.prototype.compact=function(){return this.filter(sc)},Wn.prototype.find=function(t){return this.filter(t).head()},Wn.prototype.findLast=function(t){return this.reverse().find(t)},Wn.prototype.invokeMap=Yr((function(t,e){return"function"==typeof t?new Wn(this):this.map((function(n){return jr(n,t,e)}))})),Wn.prototype.reject=function(t){return this.filter(Rs(lo(t)))},Wn.prototype.slice=function(t,e){t=va(t);var r=this;return r.__filtered__&&(t>0||e<0)?new Wn(r):(t<0?r=r.takeRight(-t):t&&(r=r.drop(t)),e!==n&&(r=(e=va(e))<0?r.dropRight(-e):r.take(e-t)),r)},Wn.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},Wn.prototype.toArray=function(){return this.take(d)},xr(Wn.prototype,(function(t,e){var r=/^(?:filter|find|map|reject)|While$/.test(e),i=/^(?:head|last)$/.test(e),o=Hn[i?"take"+("last"==e?"Right":""):e],s=i||/^find/.test(e);o&&(Hn.prototype[e]=function(){var e=this.__wrapped__,a=i?[1]:arguments,c=e instanceof Wn,u=a[0],l=c||Gs(e),f=function(t){var e=o.apply(Hn,Ne([t],a));return i&&p?e[0]:e};l&&r&&"function"==typeof u&&1!=u.length&&(c=l=!1);var p=this.__chain__,h=!!this.__actions__.length,d=s&&!p,g=c&&!h;if(!s&&l){e=g?e:new Wn(this);var m=t.apply(e,a);return m.__actions__.push({func:ms,args:[f],thisArg:n}),new Vn(m,p)}return d&&g?t.apply(this,a):(m=this.thru(f),d?i?m.value()[0]:m.value():m)})})),Ce(["pop","push","shift","sort","splice","unshift"],(function(t){var e=It[t],n=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",r=/^(?:pop|shift)$/.test(t);Hn.prototype[t]=function(){var t=arguments;if(r&&!this.__chain__){var i=this.value();return e.apply(Gs(i)?i:[],t)}return this[n]((function(n){return e.apply(Gs(n)?n:[],t)}))}})),xr(Wn.prototype,(function(t,e){var n=Hn[e];if(n){var r=n.name+"";Lt.call(Nn,r)||(Nn[r]=[]),Nn[r].push({name:e,func:n})}})),Nn[Hi(n,2).name]=[{name:"wrapper",func:n}],Wn.prototype.clone=function(){var t=new Wn(this.__wrapped__);return t.__actions__=Ii(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Ii(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Ii(this.__views__),t},Wn.prototype.reverse=function(){if(this.__filtered__){var t=new Wn(this);t.__dir__=-1,t.__filtered__=!0}else(t=this.clone()).__dir__*=-1;return t},Wn.prototype.value=function(){var t=this.__wrapped__.value(),e=this.__dir__,n=Gs(t),r=e<0,i=n?t.length:0,o=function(t,e,n){var r=-1,i=n.length;for(;++r=this.__values__.length;return{done:t,value:t?n:this.__values__[this.__index__++]}},Hn.prototype.plant=function(t){for(var e,r=this;r instanceof $n;){var i=Ho(r);i.__index__=0,i.__values__=n,e?o.__wrapped__=i:e=i;var o=i;r=r.__wrapped__}return o.__wrapped__=t,e},Hn.prototype.reverse=function(){var t=this.__wrapped__;if(t instanceof Wn){var e=t;return this.__actions__.length&&(e=new Wn(this)),(e=e.reverse()).__actions__.push({func:ms,args:[rs],thisArg:n}),new Vn(e,this.__chain__)}return this.thru(rs)},Hn.prototype.toJSON=Hn.prototype.valueOf=Hn.prototype.value=function(){return mi(this.__wrapped__,this.__actions__)},Hn.prototype.first=Hn.prototype.head,ee&&(Hn.prototype[ee]=function(){return this}),Hn}();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(pe._=mn,define((function(){return mn}))):de?((de.exports=mn)._=mn,he._=mn):pe._=mn}.call(this),e.exports}.call({});const Zt=f.DiagnosticCategory;function Jt(t){return{line:t.row+1,offset:t.column+1}}function Yt(t){return new h.Point(t.line-1,t.offset-1)}function Xt(t){return te(t.start,t.end)}function te(t,e){return new h.Range(Yt(t),Yt(e))}function ee(t){const e=ne(t),n=e.formatCodeOptions;return{formatCodeOptions:{indentSize:atom.config.get("editor.tabLength"),tabSize:atom.config.get("editor.tabLength"),...n},compileOnSave:!!e.compileOnSave,preferences:e.preferences?e.preferences:{}}}function ne(t){".json"!==w.extname(t)&&(t+=".json");let{config:e}=f.readConfigFile(t,(t=>f.sys.readFile(t)));if(void 0===e)return{};if("string"==typeof e.extends){const n=ne(w.join(w.dirname(t),e.extends));e=Object.assign({},n,e)}return e}function re(t){return{label:oe(t.prefixDisplayParts)+t.parameters.map((t=>oe(t.displayParts))).join(oe(t.separatorDisplayParts))+oe(t.suffixDisplayParts),documentation:oe(t.documentation),parameters:t.parameters.map(ie)}}function ie(t){return{label:oe(t.displayParts),documentation:oe(t.documentation)}}function oe(t){return t.map((t=>t.text)).join("")}const se=function(){let t;return function(e,n){if(void 0===e)return!0;void 0===t&&(t=new Map(Object.values(f.Diagnostics).map((t=>[t.code,t.category]))));const r=t.get(e);return void 0===r||r===n}}();function ae(t){return void 0!==t&&function(t){const e=atom.config.get("atom-typescript").tsFileExtensions;atom.config.get("atom-typescript").allowJS&&e.push(...atom.config.get("atom-typescript").jsFileExtensions);return e.includes(t)}(w.extname(t))}function ce(){const t=atom.config.get("atom-typescript").tsSyntaxScopes;return atom.config.get("atom-typescript").allowJS&&t.push(...atom.config.get("atom-typescript").jsSyntaxScopes),t}function ue(t){return ae(t.getPath())&&le(t)}function le(t){const[e]=t.getRootScopeDescriptor().getScopesArray();return ce().includes(e)}function fe(t,e){const n=t.getPath();if(void 0!==n){return{file:n,...e?Jt(e):function(t){const e=t.getCursorBufferPosition();return{line:e.row+1,offset:e.column+1}}(t)}}}async function pe(t,e){const n=new h.TextEditor({readonly:!0,keyboardInputEnabled:!1,showInvisibles:!1,tabLength:atom.config.get("editor.tabLength")}),r=atom.views.getView(n);try{return r.setUpdatedSynchronously(!0),r.style.pointerEvents="none",r.style.position="absolute",r.style.top="100vh",r.style.width="100vw",atom.grammars.assignLanguageMode(n.getBuffer(),e),n.setText(t),n.scrollToBufferPosition(n.getBuffer().getEndPosition()),atom.views.getView(atom.workspace).appendChild(r),await async function(t){return new Promise((e=>{const n=t.getBuffer().getLanguageMode(),r=t.component.getNextUpdatePromise();if(n.fullyTokenized||n.tree)e(r);else{const n=t.onDidTokenize((()=>{n.dispose(),e(r)}))}}))}(n),Array.from(r.querySelectorAll(".line:not(.dummy)")).map((t=>t.innerHTML))}finally{r.remove()}}function he(t){const e=t.dataset.startLine;return void 0!==e?parseInt(e,10)-1:0}function de(t){const e=t.dataset.endLine;return void 0!==e?parseInt(e,10)-1:0}function ge(t,e,n){const r=n.querySelectorAll(":scope > ol > li.node");if(0===r.length)return;for(const n of Array.from(r)){const r=he(n),i=de(n);if(isFinite(r)&&isFinite(i)){if(t>=r&&e<=i){const r=ge(t,e,n);return r||n}if(isFinite(i)&&e=i&&e<=o?n:void 0}function me(t){return t.spans.length>0?t.spans[0].start.line-1:0}function ve(t,e){if(!t||!e)return t===e;if(t.text===e.text){if(e.collapsed&&(t.collapsed=!0),t.childItems&&e.childItems){let n,r;for(let i=0,o=t.childItems.length;ime(t)-me(e)));for(const e of t.childItems)ye(e)}}class we{constructor(t){this.props=t,ft.initialize(this)}async update(t){this.props={...this.props,...t},await ft.update(this)}async destroy(){await ft.destroy(this)}render(){var t,e,n,r;const i=this.props.navTree,{ctrl:o}=this.props,s=(i.childItems?"nested-":"")+"item"+(i.collapsed?" collapsed":" expanded"),a=this.getStyles();return ft.dom("li",{className:"node entry exanded list-"+s,dataset:{startLine:null===(t=this.props.navTree.spans[0])||void 0===t||null===(e=t.start)||void 0===e?void 0:e.line,endLine:null===(n=this.props.navTree.spans[0])||void 0===n||null===(r=n.end)||void 0===r?void 0:r.line}},ft.dom("div",{className:"header list-item",on:{click:t=>this.entryClicked(t,i)}},ft.dom("span",{className:a},i.text)),ft.dom("ol",{className:"entries list-tree"},i.childItems?i.childItems.map((t=>ft.dom(we,{navTree:t,ctrl:o}))):null))}getStyles(){const{kind:t}=this.props.navTree;let e="icon icon-"+t;const{kindModifiers:n}=this.props.navTree;return n&&(e+=" "+n.split(/[, ]/).map((t=>"modifier-"+t.trim())).join(" ")),e}entryClicked(t,e){t.stopPropagation();(function(t,e){return!!t.childItems&&e.target===e.currentTarget})(e,t)?(e.collapsed=!e.collapsed,Kt(ft.update(this))):this.props.ctrl.gotoNode(e)}}class be{constructor(t){this.props=t,this.subscriptions=new d,this.loadNavTree=async()=>{if(!this.editor)return;if(!this.getClient)return;const t=this.editor.getPath();if(void 0!==t)try{const e=await this.getClient(t),n=(await e.execute("navtree",{file:t})).body;n&&(this.setNavTree(n),await ft.update(this))}catch(e){console.error(e,t)}},this.selectAtCursorLine=({newBufferPosition:t})=>{var e,n;const r=this.firstNode();if(!r)return;const i=t.row,o=null!==(e=null===(n=ge(i,i,r))||void 0===n?void 0:n.querySelector(".header"))&&void 0!==e?e:void 0,s=this.getSelectedNode();o!==s&&(s&&s.classList.remove("selected"),o&&o.classList.add("selected"))},this.subscribeToEditor=async t=>{if(this.editorScrolling&&this.editorScrolling.dispose(),this.editorChanging&&this.editorChanging.dispose(),!t||!ue(t))return this.update({navTree:null});this.editor=t,await this.loadNavTree(),this.editorScrolling=t.onDidChangeCursorPosition(this.selectAtCursorLine),this.editorChanging=t.onDidStopChanging(this.loadNavTree)},ye(t.navTree),ft.initialize(this),this.subscriptions.add(atom.workspace.observeActiveTextEditor(this.subscribeToEditor))}async update(t){void 0!==t.navTree&&this.setNavTree(t.navTree),this.props={...this.props,...t},await ft.update(this)}async destroy(){this.editorScrolling&&this.editorScrolling.dispose(),this.editorChanging&&this.editorChanging.dispose(),this.editorScrolling=void 0,this.editorChanging=void 0,this.subscriptions.dispose(),await ft.destroy(this)}async setGetClient(t){this.getClient=t,await this.loadNavTree()}getSelectedNode(){var t;return null!==(t=this.element.querySelector(".header.selected"))&&void 0!==t?t:void 0}clearSelection(){const t=this.element.querySelectorAll(".header.selected");for(let e=0;e0?t.spans[0].start.offset-1:0}(t);this.editor.setCursorBufferPosition([e,n])}getCursorLine(){return this.editor?this.editor.getLastCursor().getBufferRow():void 0}setNavTree(t){if(ye(t),Qt.isEqual(t,this.props.navTree))return;ve(t,this.props.navTree),this.props.navTree=t;const e=this.firstNode();if(e){const t=this.getCursorLine();void 0!==t&&this.markSelection(ge(t,t,e))}}scrollTo(t){const e=t;"function"==typeof e.scrollIntoViewIfNeeded?e.scrollIntoViewIfNeeded():e.scrollIntoView()}}class _e{constructor(t){this.comp=new be({navTree:t.navTree})}static create(t){return _e.instance||(_e.instance=new _e(t)),_e.instance}get element(){return this.comp.element}async setGetClient(t){await this.comp.setGetClient(t),await this.comp.update({})}getTitle(){return"TypeScript"}getURI(){return"atom-typescript://semantic-view"}async destroy(){_e.instance=null,await this.comp.destroy()}getDefaultLocation(){return"right"}getAllowedLocations(){return["left","right"]}serialize(){return{deserializer:"atomts-semantic-view/SemanticView",data:{navTree:this.comp.props.navTree}}}}_e.instance=null;var xe,Se=u,ke=a,Ee=s;xe=function(t,e){return Ce(t,e)};var Ce=function(t,e){return t?Te(t,e):new Ae(e)};xe.createStream=Ce;function Te(t,e){if(!t)throw new Error("expected readStream");if(!t.readable)throw new Error("readStream must be readable");var n=new Ae(e);return t.pipe(n),n}function Ae(t){Se.Transform.call(this,t),t=t||{},this._readableState.objectMode=!0,this._lineBuffer=[],this._keepEmptyLines=t.keepEmptyLines||!1,this._lastChunkEndedWithCR=!1;var e=this;this.on("pipe",(function(t){e.encoding||t instanceof Se.Readable&&(e.encoding=t._readableState.encoding)}))}xe.createLineStream=function(t){return console.log("WARNING: byline#createLineStream is deprecated and will be removed soon"),Te(t)},xe.LineStream=Ae,ke.inherits(Ae,Se.Transform),Ae.prototype._transform=function(t,e,n){e=e||"utf8",Buffer.isBuffer(t)&&("buffer"==e?(t=t.toString(),e="utf8"):t=t.toString(e)),this._chunkEncoding=e;var r=t.split(/\r\n|[\n\v\f\r\x85\u2028\u2029]/g);this._lastChunkEndedWithCR&&"\n"==t[0]&&r.shift(),this._lineBuffer.length>0&&(this._lineBuffer[this._lineBuffer.length-1]+=r[0],r.shift()),this._lastChunkEndedWithCR="\r"==t[t.length-1],this._lineBuffer=this._lineBuffer.concat(r),this._pushBuffer(e,1,n)},Ae.prototype._pushBuffer=function(t,e,n){for(;this._lineBuffer.length>e;){var r=this._lineBuffer.shift();if((this._keepEmptyLines||r.length>0)&&!this.push(this._reencode(r,t))){var i=this;return void Ee.setImmediate((function(){i._pushBuffer(t,e,n)}))}}n()},Ae.prototype._flush=function(t){this._pushBuffer(this._chunkEncoding,0,t)},Ae.prototype._reencode=function(t,e){return this.encoding&&this.encoding!=e?new Buffer(t,e).toString(this.encoding):this.encoding?t:new Buffer(t,e)};class Pe{constructor(t){this.reportBusyWhile=t,this.callbacks=new Map,this.interval=0}async add(t,e){try{const n=new Promise(((n,r)=>{this.callbacks.set(t,{command:e,resolve:n,reject:r,started:Date.now()})}));return 0===this.interval&&(this.interval=window.setInterval((()=>{process.activateUvLoop()}),100)),await this.reportBusyWhile(e,(()=>n))}finally{this.callbacks.delete(t),0!==this.interval&&0===this.callbacks.size&&(clearInterval(this.interval),this.interval=0)}}rejectAll(t){for(const{reject:e}of this.callbacks.values())e(t);this.callbacks.clear()}resolve(t){const e=this.callbacks.get(t.request_seq);e?(window.atom_typescript_debug&&console.log("received response for",t.command,"in",Date.now()-e.started,"ms","with data",t.body),t.success?e.resolve(t):e.reject(new Error(t.message))):console.warn("unexpected response:",t)}resolveMS(t){const e=this.callbacks.get(t.request_seq);e?(window.atom_typescript_debug&&console.log(`received requestCompleted event for multistep command ${e.command} in ${Date.now()-e.started} ms`),e.resolve(void 0)):console.warn("unexpected requestCompleted event:",t)}error(t,e){const n=this.callbacks.get(t);n?n.reject(e):console.error(e)}}const Oe=new Set(Object.keys({compileOnSaveAffectedFileList:!0,compileOnSaveEmitFile:!0,completionEntryDetails:!0,completions:!0,completionInfo:!0,configure:!0,definition:!0,format:!0,getCodeFixes:!0,getSupportedCodeFixes:!0,documentHighlights:!0,projectInfo:!0,quickinfo:!0,references:!0,reload:!0,rename:!0,navtree:!0,navto:!0,getApplicableRefactors:!0,getEditsForRefactor:!0,organizeImports:!0,signatureHelp:!0,getEditsForFileRename:!0,applyCodeActionCommand:!0})),Ie=new Set(Object.keys({geterr:!0,geterrForProject:!0})),je=new Set(Object.keys({configFileDiag:!0,semanticDiag:!0,suggestionDiag:!0,syntaxDiag:!0}));class Ne{constructor(t,e,n){this.tsServerPath=t,this.version=e,this.reportBusyWhile=n,this.emitter=new g,this.seq=0,this.lastStderrOutput="",this.on=this.emitter.on.bind(this.emitter),this.exitHandler=(t,e=!0)=>{if(this.callbacks.rejectAll(t),e&&console.error("tsserver: ",t),this.server=void 0,this.emitter.emit("terminated"),e){let e=t.message;this.lastStderrOutput&&(e=`Last output from tsserver:\n${this.lastStderrOutput}\n\n${e}`),atom.notifications.addError("TypeScript server quit unexpectedly",{detail:e,stack:t.stack,dismissable:!0})}},this.onMessage=t=>{"response"===t.type?this.callbacks.resolve(t):this.onEvent(t)};const[r,i]=e.split(".").slice(0,2).map((t=>parseInt(t,10)));this.multistepSupported=r>2||2===r&&i>=2,this.callbacks=new Pe(this.reportBusyWhile),this.server=this.startServer()}async execute(t,...e){this.server||(this.server=this.startServer(),this.emitter.emit("restarted"));const n={seq:this.seq++,command:t,arguments:e[0]};window.atom_typescript_debug&&console.log("sending request",n);let r=void 0;(function(t){return Oe.has(t)}(t)||this.multistepSupported&&function(t){return Ie.has(t)}(t))&&(r=this.callbacks.add(n.seq,t));try{if(!this.server.stdin)throw new Error("Server stdin is missing");this.server.stdin.write(JSON.stringify(n)+"\n")}catch(t){this.callbacks.error(n.seq,t)}return r}async restartServer(){if(this.server){const t=this.server,e=setTimeout((()=>t.kill()),1e4);await Promise.all([this.execute("exit"),new Promise((t=>{const e=this.emitter.once("terminated",(()=>{e.dispose(),t()}))}))]),clearTimeout(e)}this.server||(this.server=this.startServer(),this.emitter.emit("restarted"))}startServer(){window.atom_typescript_debug&&console.log("starting",this.tsServerPath);const t=function(t){const e=atom.config.get("atom-typescript").locale,n=e?["--locale",e]:[];return new m({command:t,args:n}).process}(this.tsServerPath);if(!t)throw new Error("ChildProcess failed to start");const e=this.exitHandler;if(t.once("error",e),t.once("exit",((t,n)=>{0===t?e(new Error("Server stopped normally"),!1):null!==t?e(new Error("exited with code: "+t)):null!==n&&e(new Error("terminated on signal: "+n))})),!t.stdout)throw new Error("ChildProcess stdout missing");if(!t.stderr)throw new Error("ChildProcess stderr missing");var n;return(n=t.stdout,n.pipe(Fe()).pipe(new Le)).on("data",this.onMessage),t.stderr.on("data",(t=>{console.warn("tsserver stderr:",this.lastStderrOutput=t.toString())})),t}onEvent(t){var e;window.atom_typescript_debug&&console.log("received event",t),t.body&&(e=t.event,je.has(e)?this.emitter.emit(t.event,t.body):"requestCompleted"===t.event&&this.callbacks.resolveMS(t.body))}}var De,Fe=C(xe);class Le extends l{constructor(){super({objectMode:!0})}_transform(t,e,n){const r=t.toString();try{r.startsWith("{")?this.push(JSON.parse(r)):r.startsWith("Content-Length:")||console.warn(r)}catch(t){console.error("client: failed to parse: ",r)}finally{n(void 0)}}}function Me(t,e){void 0===e&&(e=!1);var n=t.length,r=0,i="",o=0,s=16,a=0,c=0,u=0,l=0,f=0;function p(e,n){for(var i=0,o=0;i=48&&s<=57)o=16*o+s-48;else if(s>=65&&s<=70)o=16*o+s-65+10;else{if(!(s>=97&&s<=102))break;o=16*o+s-97+10}r++,i++}return i=n)return o=n,s=17;var e=t.charCodeAt(r);if(Re(e)){do{r++,i+=String.fromCharCode(e),e=t.charCodeAt(r)}while(Re(e));return s=15}if(Be(e))return r++,i+=String.fromCharCode(e),13===e&&10===t.charCodeAt(r)&&(r++,i+="\n"),a++,u=r,s=14;switch(e){case 123:return r++,s=1;case 125:return r++,s=2;case 91:return r++,s=3;case 93:return r++,s=4;case 58:return r++,s=6;case 44:return r++,s=5;case 34:return r++,i=function(){for(var e="",i=r;;){if(r>=n){e+=t.substring(i,r),f=2;break}var o=t.charCodeAt(r);if(34===o){e+=t.substring(i,r),r++;break}if(92!==o){if(o>=0&&o<=31){if(Be(o)){e+=t.substring(i,r),f=2;break}f=6}r++}else{if(e+=t.substring(i,r),++r>=n){f=2;break}switch(t.charCodeAt(r++)){case 34:e+='"';break;case 92:e+="\\";break;case 47:e+="/";break;case 98:e+="\b";break;case 102:e+="\f";break;case 110:e+="\n";break;case 114:e+="\r";break;case 116:e+="\t";break;case 117:var s=p(4,!0);s>=0?e+=String.fromCharCode(s):f=4;break;default:f=5}i=r}}return e}(),s=10;case 47:var h=r-1;if(47===t.charCodeAt(r+1)){for(r+=2;r=12&&t<=15);return t}:h,getToken:function(){return s},getTokenValue:function(){return i},getTokenOffset:function(){return o},getTokenLength:function(){return r-o},getTokenStartLine:function(){return c},getTokenStartCharacter:function(){return o-l},getTokenError:function(){return f}}}function Re(t){return 32===t||9===t||11===t||12===t||160===t||5760===t||t>=8192&&t<=8203||8239===t||8287===t||12288===t||65279===t}function Be(t){return 10===t||13===t||8232===t||8233===t}function ze(t){return t>=48&&t<=57}(De||(De={})).DEFAULT={allowTrailingComma:!1};var qe,He,Ue=function(t,e,n){void 0===e&&(e=[]),void 0===n&&(n=De.DEFAULT);var r=null,i=[],o=[];function s(t){Array.isArray(i)?i.push(t):null!==r&&(i[r]=t)}return function(t,e,n){void 0===n&&(n=De.DEFAULT);var r=Me(t,!1);function i(t){return t?function(){return t(r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter())}:function(){return!0}}function o(t){return t?function(e){return t(e,r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter())}:function(){return!0}}var s=i(e.onObjectBegin),a=o(e.onObjectProperty),c=i(e.onObjectEnd),u=i(e.onArrayBegin),l=i(e.onArrayEnd),f=o(e.onLiteralValue),p=o(e.onSeparator),h=i(e.onComment),d=o(e.onError),g=n&&n.disallowComments,m=n&&n.allowTrailingComma;function v(){for(;;){var t=r.scan();switch(r.getTokenError()){case 4:y(14);break;case 5:y(15);break;case 3:y(13);break;case 1:g||y(11);break;case 2:y(12);break;case 6:y(16)}switch(t){case 12:case 13:g?y(10):h();break;case 16:y(1);break;case 15:case 14:break;default:return t}}}function y(t,e,n){if(void 0===e&&(e=[]),void 0===n&&(n=[]),d(t),e.length+n.length>0)for(var i=r.getToken();17!==i;){if(-1!==e.indexOf(i)){v();break}if(-1!==n.indexOf(i))break;i=v()}}function w(t){var e=r.getTokenValue();return t?f(e):a(e),v(),!0}function b(){switch(r.getToken()){case 11:var t=r.getTokenValue(),e=Number(t);isNaN(e)&&(y(2),e=0),f(e);break;case 7:f(null);break;case 8:f(!0);break;case 9:f(!1);break;default:return!1}return v(),!0}function _(){return 10!==r.getToken()?(y(3,[],[2,5]),!1):(w(!1),6===r.getToken()?(p(":"),v(),k()||y(4,[],[2,5])):y(5,[],[2,5]),!0)}function x(){s(),v();for(var t=!1;2!==r.getToken()&&17!==r.getToken();){if(5===r.getToken()){if(t||y(4,[],[]),p(","),v(),2===r.getToken()&&m)break}else t&&y(6,[],[]);_()||y(4,[],[2,5]),t=!0}return c(),2!==r.getToken()?y(7,[2],[]):v(),!0}function S(){u(),v();for(var t=!1;4!==r.getToken()&&17!==r.getToken();){if(5===r.getToken()){if(t||y(4,[],[]),p(","),v(),4===r.getToken()&&m)break}else t&&y(6,[],[]);k()||y(4,[],[4,5]),t=!0}return l(),4!==r.getToken()?y(8,[4],[]):v(),!0}function k(){switch(r.getToken()){case 3:return S();case 1:return x();case 10:return w(!0);default:return b()}}if(v(),17===r.getToken())return!!n.allowEmptyContent||(y(4,[],[]),!1);if(!k())return y(4,[],[]),!1;17!==r.getToken()&&y(9,[],[])}(t,{onObjectBegin:function(){var t={};s(t),o.push(i),i=t,r=null},onObjectProperty:function(t){r=t},onObjectEnd:function(){i=o.pop()},onArrayBegin:function(){var t=[];s(t),o.push(i),i=t,r=null},onArrayEnd:function(){i=o.pop()},onLiteralValue:s,onError:function(t,n,r){e.push({error:t,offset:n,length:r})}},n),i[0]},$e=x,Ve=w;He=function(){var t=Error.prepareStackTrace;Error.prepareStackTrace=function(t,e){return e};var e=(new Error).stack;return Error.prepareStackTrace=t,e[2].getFileName()};var We,Ge,Ke,Qe,Ze,Je,Ye,Xe,tn,en,nn=w,rn=!1;function on(){Ge={},Ke="win32"===process.platform,Qe=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/,Ze=/^([\s\S]*?)((?:\.{1,2}|[^\\\/]+?|)(\.[^.\/\\]*|))(?:[\\\/]*)$/,(Je={}).parse=function(t){if("string"!=typeof t)throw new TypeError("Parameter 'pathString' must be a string, not "+typeof t);var e,n,r,i,o,s=(e=t,n=Qe.exec(e),r=(n[1]||"")+(n[2]||""),i=n[3]||"",o=Ze.exec(i),[r,o[1],o[2],o[3]]);if(!s||4!==s.length)throw new TypeError("Invalid path '"+t+"'");return{root:s[0],dir:s[0]+s[1].slice(0,-1),base:s[2],ext:s[3],name:s[2].slice(0,s[2].length-s[3].length)}},Ye=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,(Xe={}).parse=function(t){if("string"!=typeof t)throw new TypeError("Parameter 'pathString' must be a string, not "+typeof t);var e,n=(e=t,Ye.exec(e).slice(1));if(!n||4!==n.length)throw new TypeError("Invalid path '"+t+"'");return n[1]=n[1]||"",n[2]=n[2]||"",n[3]=n[3]||"",{root:n[0],dir:n[0]+n[1].slice(0,-1),base:n[2],ext:n[3],name:n[2].slice(0,n[2].length-n[3].length)}},Ge=Ke?Je.parse:Xe.parse,tn=Xe.parse,Ge.posix=tn,en=Je.parse,Ge.win32=en}var sn=nn.parse||(rn||(rn=!0,on()),Ge),an=function(t,e){var n="/";/^([A-Za-z]:)/.test(t)?n="":/^\\\\/.test(t)&&(n="\\\\");for(var r=[t],i=sn(t);i.dir!==r[r.length-1];)r.push(i.dir),i=sn(i.dir);return r.reduce((function(t,r){return t.concat(e.map((function(t){return nn.resolve(n,r,t)})))}),[])};We=function(t,e,n){var r=e&&e.moduleDirectory?[].concat(e.moduleDirectory):["node_modules"];if(e&&"function"==typeof e.paths)return e.paths(n,t,(function(){return an(t,r)}),e);var i=an(t,r);return e&&e.paths?i.concat(e.paths):i};var cn;cn=function(t,e){return e||{}};var un,ln,fn={},pn={},hn=Array.prototype.slice,dn=Object.prototype.toString;function gn(t,e){for(var n=t.split("."),r=e.split(" "),i=r.length>1?r[0]:"=",o=(r.length>1?r[1]:r[0]).split("."),s=0;s<3;++s){var a=parseInt(n[s]||0,10),c=parseInt(o[s]||0,10);if(a!==c)return"<"===i?a="===i&&a>=c}return">="===i}function mn(t,e){var n=e.split(/ ?&& ?/);if(0===n.length)return!1;for(var r=0;r= 15","async_hooks":">= 8","buffer_ieee754":"< 0.9.7","buffer":true,"child_process":true,"cluster":true,"console":true,"constants":true,"crypto":true,"_debug_agent":">= 1 && < 8","_debugger":"< 8","dgram":true,"diagnostics_channel":">= 15.1","dns":true,"dns/promises":">= 15","domain":">= 0.7.12","events":true,"freelist":"< 6","fs":true,"fs/promises":[">= 10 && < 10.1",">= 14"],"_http_agent":">= 0.11.1","_http_client":">= 0.11.1","_http_common":">= 0.11.1","_http_incoming":">= 0.11.1","_http_outgoing":">= 0.11.1","_http_server":">= 0.11.1","http":true,"http2":">= 8.8","https":true,"inspector":">= 8.0.0","_linklist":"< 8","module":true,"net":true,"node-inspect/lib/_inspect":">= 7.6.0 && < 12","node-inspect/lib/internal/inspect_client":">= 7.6.0 && < 12","node-inspect/lib/internal/inspect_repl":">= 7.6.0 && < 12","os":true,"path":true,"path/posix":">= 15.3","path/win32":">= 15.3","perf_hooks":">= 8.5","process":">= 1","punycode":true,"querystring":true,"readline":true,"repl":true,"smalloc":">= 0.11.5 && < 3","_stream_duplex":">= 0.9.4","_stream_transform":">= 0.9.4","_stream_wrap":">= 1.4.1","_stream_passthrough":">= 0.9.4","_stream_readable":">= 0.9.4","_stream_writable":">= 0.9.4","stream":true,"stream/promises":">= 15","string_decoder":true,"sys":[">= 0.6 && < 0.7",">= 0.8"],"timers":true,"timers/promises":">= 15","_tls_common":">= 0.11.13","_tls_legacy":">= 0.11.3 && < 10","_tls_wrap":">= 0.11.3","tls":true,"trace_events":">= 10","tty":true,"url":true,"util":true,"util/types":">= 15.3","v8/tools/arguments":">= 10 && < 12","v8/tools/codemap":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/consarray":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/csvparser":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/logreader":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/profile_view":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/splaytree":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8":">= 1","vm":true,"wasi":">= 13.4 && < 13.5","worker_threads":">= 11.7","zlib":true}'),un=function(t,e){return fn(vn,t)&&function(t,e){if("boolean"==typeof e)return e;var n=void 0===t?process.versions&&process.versions.node&&process.versions.node:t;if("string"!=typeof n)throw new TypeError(void 0===t?"Unable to determine current node version":"If provided, a valid node version is required");if(e&&"object"==typeof e){for(var r=0;r1?e[0]:"=",r=(e.length>1?e[1]:e[0]).split("."),i=0;i<3;++i){var o=parseInt(kn[i]||0,10),s=parseInt(r[i]||0,10);if(o!==s)return"<"===n?o="===n&&o>=s}return">="===n}function Cn(t){var e=t.split(/ ?&& ?/);if(0===e.length)return!1;for(var n=0;n= 15","async_hooks":">= 8","buffer_ieee754":"< 0.9.7","buffer":true,"child_process":true,"cluster":true,"console":true,"constants":true,"crypto":true,"_debug_agent":">= 1 && < 8","_debugger":"< 8","dgram":true,"diagnostics_channel":">= 15.1","dns":true,"dns/promises":">= 15","domain":">= 0.7.12","events":true,"freelist":"< 6","fs":true,"fs/promises":[">= 10 && < 10.1",">= 14"],"_http_agent":">= 0.11.1","_http_client":">= 0.11.1","_http_common":">= 0.11.1","_http_incoming":">= 0.11.1","_http_outgoing":">= 0.11.1","_http_server":">= 0.11.1","http":true,"http2":">= 8.8","https":true,"inspector":">= 8.0.0","_linklist":"< 8","module":true,"net":true,"node-inspect/lib/_inspect":">= 7.6.0 && < 12","node-inspect/lib/internal/inspect_client":">= 7.6.0 && < 12","node-inspect/lib/internal/inspect_repl":">= 7.6.0 && < 12","os":true,"path":true,"path/posix":">= 15.3","path/win32":">= 15.3","perf_hooks":">= 8.5","process":">= 1","punycode":true,"querystring":true,"readline":true,"repl":true,"smalloc":">= 0.11.5 && < 3","_stream_duplex":">= 0.9.4","_stream_transform":">= 0.9.4","_stream_wrap":">= 1.4.1","_stream_passthrough":">= 0.9.4","_stream_readable":">= 0.9.4","_stream_writable":">= 0.9.4","stream":true,"stream/promises":">= 15","string_decoder":true,"sys":[">= 0.6 && < 0.7",">= 0.8"],"timers":true,"timers/promises":">= 15","_tls_common":">= 0.11.13","_tls_legacy":">= 0.11.3 && < 10","_tls_wrap":">= 0.11.3","tls":true,"trace_events":">= 10","tty":true,"url":true,"util":true,"util/types":">= 15.3","v8/tools/arguments":">= 10 && < 12","v8/tools/codemap":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/consarray":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/csvparser":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/logreader":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/profile_view":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/splaytree":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8":">= 1","vm":true,"wasi":">= 13.4 && < 13.5","worker_threads":">= 11.7","zlib":true}');var Pn={};for(var On in An)Object.prototype.hasOwnProperty.call(An,On)&&(Pn[On]=Tn(An[On]));qe.core=Pn;qe.isCore=function(t){return un(t)};var In=x,jn=w,Nn=In.realpathSync&&"function"==typeof In.realpathSync.native?In.realpathSync.native:In.realpathSync,Dn=function(t){try{var e=In.statSync(t)}catch(t){if(t&&("ENOENT"===t.code||"ENOTDIR"===t.code))return!1;throw t}return e.isFile()||e.isFIFO()},Fn=function(t){try{var e=In.statSync(t)}catch(t){if(t&&("ENOENT"===t.code||"ENOTDIR"===t.code))return!1;throw t}return e.isDirectory()},Ln=function(t){try{return Nn(t)}catch(t){if("ENOENT"!==t.code)throw t}return t},Mn=function(t,e,n){return n&&!1===n.preserveSymlinks?t(e):e},Rn=function(t,e){var n=t(e);try{return JSON.parse(n)}catch(t){}};async function Bn(t,e){const{NODE_PATH:n}=process.env,r=e+".js",i=await async function(t,e){return new Promise(((n,r)=>zn(t,e,((t,e)=>{t?r(t):void 0===e?r(new Error("Module path is undefined")):n(e)}))))}("typescript/lib/"+r,{basedir:w.dirname(t),paths:void 0!==n?n.split(w.delimiter):void 0}).catch((async()=>{const e=await async function(t){const e=await async function(t){let e=t,n=w.dirname(e);for(;e!==n;){const t=await Hn(e,[[".atom-typescript.json"],[".atom","atom-typescript.json"],[".vscode","settings.json"]]);if(void 0!==t)return{basedir:e,configFile:t};e=n,n=w.dirname(e)}}(t);if(e)try{const t=Ue(await async function(t){return new Promise(((e,n)=>x.readFile(t,((t,r)=>{t?n(t):e(r.toString("utf-8"))}))))}(e.configFile));let r;if("object"==typeof(n=t)&&null!==n&&"string"==typeof n.tsdkPath)r=t.tsdkPath;else{if(!function(t){return"object"==typeof t&&null!==t&&"string"==typeof t["typescript.tsdk"]}(t))return;r=w.dirname(t["typescript.tsdk"])}return w.isAbsolute(r)?r:w.join(e.basedir,r)}catch(t){console.warn(t)}var n}(w.dirname(t));if(void 0!==e){const t=w.join(e,"lib",r);if(await qn(t))return t}const n=atom.config.get("atom-typescript.tsdkPath");if(n){const t=w.join(n,"lib",r);if(await qn(t))return t}return require.resolve("typescript/lib/"+r)})),o=w.resolve(i,"../../package.json");return{version:require(o).version,pathToBin:i}}qe.sync=function(t,e){if("string"!=typeof t)throw new TypeError("Path must be a string.");var n=cn(0,e),r=n.isFile||Dn,i=n.readFileSync||In.readFileSync,o=n.isDirectory||Fn,s=n.realpathSync||Ln,a=n.readPackageSync||Rn;if(n.readFileSync&&n.readPackageSync)throw new TypeError("`readFileSync` and `readPackageSync` are mutually exclusive.");var c=n.packageIterator,u=n.extensions||[".js"],l=!1!==n.includeCoreModules,f=n.basedir||jn.dirname(He()),p=n.filename||f;n.paths=n.paths||[];var h=Mn(s,jn.resolve(f),n);if(/^(?:\.\.?(?:\/|$)|\/|([A-Za-z]:)?[/\\])/.test(t)){var d=jn.resolve(h,t);"."!==t&&".."!==t&&"/"!==t.slice(-1)||(d+="/");var g=y(d)||b(d);if(g)return Mn(s,g,n)}else{if(l&&un(t))return t;var m=function(t,e){for(var r=function(){return function(t,e,n){for(var r=We(e,n,t),i=0;ix.access(t,x.constants.F_OK,(t=>{e(!t)}))))}async function Hn(t,e){for(const n of e){const e=w.join(t,...n);if(await qn(e))return e}}class Un{constructor(t){this.reportBusyWhile=t,this.clients=new Map,this.memoizedClients=new Map,this.emitter=new g,this.subscriptions=new d,this.tsserverInstancePerTsconfig=atom.config.get("atom-typescript").tsserverInstancePerTsconfig,this.on=this.emitter.on.bind(this.emitter),this.diagnosticHandler=(t,e)=>n=>{const r=(i=n)&&i.triggerFile&&i.configFile?n.configFile:n.file;var i;r&&this.emitter.emit("diagnostics",{type:e,serverPath:t,filePath:r,diagnostics:n.diagnostics})}}async restartAllServers(){await this.reportBusyWhile("Restarting servers",(()=>Promise.all(Array.from(this.getAllClients()).map((t=>t.restartServer())))))}async get(t){const e=this.memoizedClients.get(t);if(e)return e;const n=this._get(t);this.memoizedClients.set(t,n);try{return await n}catch(e){throw this.memoizedClients.delete(t),e}}dispose(){this.emitter.dispose(),this.subscriptions.dispose(),this.memoizedClients.clear(),this.clients.clear()}async _get(t){const{pathToBin:e,version:n}=await Bn(t,"tsserver"),r=this.tsserverInstancePerTsconfig?f.findConfigFile(t,(t=>f.sys.fileExists(t))):void 0;let i=this.clients.get(e);i||(i=new Map,this.clients.set(e,i));const o=i.get(r);if(o)return o;const s=new Ne(e,n,this.reportBusyWhile);return i.set(r,s),this.subscriptions.add(s.on("configFileDiag",this.diagnosticHandler(e,"configFileDiag")),s.on("semanticDiag",this.diagnosticHandler(e,"semanticDiag")),s.on("syntaxDiag",this.diagnosticHandler(e,"syntaxDiag")),s.on("suggestionDiag",this.diagnosticHandler(e,"suggestionDiag"))),s}*getAllClients(){for(const t of this.clients.values())yield*t.values()}}function $n(t){return{grammarScopes:ce(),priority:100,async highlight(e,n){if(!ue(e))return;const r=fe(e,n);if(!r)return;const i=await t(r.file),o=await i.execute("documentHighlights",{...r,filesToSearch:[r.file]});return o.body?Array.from(function*(t,e){for(const n of e)n.file===t&&(yield*n.highlightSpans.map(Xt))}(r.file,o.body)):void 0}}}async function Vn(t,e,n){if(void 0===t)return null;const r=e.dom("div",{className:"atom-typescript-datatip-tooltip-kind"},t.kind,function(t,e){return void 0===e?null:t.dom("span",{className:"atom-typescript-datatip-tooltip-kind-modifiers"},e)}(t.kindModifiers)),i=t.tags?t.tags.map((t=>{const n="atom-typescript-datatip-tooltip-doc-tag atom-typescript-datatip-tooltip-doc-tag-name-"+t.name;return e.dom("div",{className:n},e.dom("span",{className:"atom-typescript-datatip-tooltip-doc-tag-name"},t.name),function(t,e){if(void 0===e)return null;const[,n,r]=/^\s*(\S*)([^]*)$/.exec(e);return t.dom("span",{className:"atom-typescript-datatip-tooltip-doc-tag-text"},t.dom("span",{className:"atom-typescript-datatip-tooltip-doc-tag-text-first-word"},n),r)}(e,t.text))})):null,o=e.dom("div",{className:"atom-typescript-datatip-tooltip-doc"},t.documentation,i),s=t.displayString.replace(/^\(.+?\)\s+/,"");return[await n(s),r,o]}const Wn=Symbol.for("react.element"),Gn={dom:(t,e,...n)=>n.length>0?{$$typeof:Wn,type:t,ref:null,props:{...e,children:n}}:{$$typeof:Wn,type:t,ref:null,props:{...e}}};class Kn{constructor(t){this.getClient=t,this.providerName="TypeScript type tooltips",this.priority=100,this.grammarScopes=ce()}async datatip(t,e){try{const n=t.getPath();if(void 0===n)return;const r=await this.getClient(n),i=(await r.execute("quickinfo",{file:n,line:e.row+1,offset:e.column+1})).body,o=await Vn(i,Gn,Qn);return{component:()=>Gn.dom("div",{className:"atom-typescript-datatip-tooltip"},o),range:h.Range.fromObject([Yt(i.start),Yt(i.end)])}}catch(t){return}}}async function Qn(t){const e=atom.config.get("editor.fontFamily"),n=await pe(t.replace(/\r?\n$/,""),"source.ts");return Gn.dom("div",{style:{fontFamily:e},className:"atom-typescript-datatip-tooltip-code",dangerouslySetInnerHTML:{__html:n.join("\n")}})}function Zn(t){const e=Xt(t);return{path:t.file,position:e.start,range:e,language:"TypeScript"}}function Jn(t){return{uri:t.file,range:te(t.start,t.end),name:void 0}}class Yn{constructor(t){this.props=t,ft.initialize(this)}async update(t){return this.props={...this.props,...t},ft.update(this)}render(){const t={fontFamily:atom.config.get("editor.fontFamily")};return ft.dom("div",{className:"editor editor-colors",style:t,innerHTML:this.props.highlightedText})}}var Xn,tr,er,nr={},rr=!1;function ir(){return rr||(rr=!0,function(){var t,e;t=w.sep,Xn=function(e,n,r){var i,o,s,a,c;for(o=e.length-1;e[o]===t;)o--;for(c=0,s=o,i=null;o>=0;)e[o]===t?(c++,null==i&&(i=e.substring(o+1,s+1))):0===o&&(s0&&f.push({candidate:a,score:l}));f.sort(n),r=f.map(t)}return null!=u&&(r=r.slice(0,u)),r}}.call(or={})),or}var cr,ur,lr,fr=!1;function pr(){return fr||(fr=!0,function(){var t;t=w.sep,cr=function(e,n){var r,i,o;for(i=e.length-1;e[i]===t;)i--;for(o=i,r=null;i>=0;)e[i]===t?null==r&&(r=e.substring(i+1,o+1)):0===i&&(or;n<=r?e++:e--)p.push(e);return p}.apply(this);for(u=e.length,l=t.length,i=0,o=0,a=[];ie;0<=e?t++:t--)l.push(t);return l}.apply(this);if(c=-1!==i.indexOf(t),i=i.replace(e,""),a=r.match(n,i),!c)for(o=r.basenameMatch(n,i),a=a.concat(o).sort((function(t,e){return t-e})),u=null,s=0;sft.dom("span",{className:t.type},t.text))))}match(t){return t.query?function(t,e){let n=0,r=[];const i=[],o=nr.match(t,e);let s;for(s of o){if(s<0)continue;const e=t.substring(n,s);e&&(r.length>0&&i.push({text:r.join(""),type:"character-match"}),r=[],i.push({text:e})),r.push(t[s]),n=s+1}r.length>0&&i.push({text:r.join(""),type:"character-match"});return i.push({text:t.substring(n)}),i}(t.label,t.query):[{text:t.label}]}}var dr={},gr=dr&&dr.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(dr,"__esModule",{value:!0});const mr=h,vr=gr(ft),yr=vr.default.dom,wr=gr(nr);dr=class{constructor(t){this.props=t,this.props.hasOwnProperty("initialSelectionIndex")||(this.props.initialSelectionIndex=0),t.initiallyVisibleItemCount&&this.initializeVisibilityObserver(),this.computeItems(!1),this.disposables=new mr.CompositeDisposable,vr.default.initialize(this),this.element.classList.add("select-list"),this.disposables.add(this.refs.queryEditor.onDidChange(this.didChangeQuery.bind(this))),t.skipCommandsRegistration||this.disposables.add(this.registerAtomCommands());const e=this.refs.queryEditor.element,n=this.didLoseFocus.bind(this);e.addEventListener("blur",n),this.didClickItemsList=!1,this.element.addEventListener("mousedown",(t=>{t.target===this.refs.items&&(this.didClickItemsList=!0)})),this.disposables.add(new mr.Disposable((()=>{e.removeEventListener("blur",n)})))}static setScheduler(t){vr.default.setScheduler(t)}static getScheduler(){return vr.default.getScheduler()}initializeVisibilityObserver(){this.visibilityObserver=new IntersectionObserver((t=>{for(const e of t)if(e.intersectionRatio>0){const t=e.target;this.visibilityObserver.unobserve(t);const n=Array.from(this.refs.items.children).indexOf(t);n>=0&&this.renderItemAtIndex(n)}}))}focus(){this.refs.queryEditor.element.focus()}didLoseFocus(t){this.didClickItemsList||this.element.contains(t.relatedTarget)?(this.didClickItemsList=!1,this.refs.queryEditor.element.focus()):document.hasFocus()&&this.cancelSelection()}reset(){this.refs.queryEditor.setText("")}destroy(){return this.disposables.dispose(),this.visibilityObserver&&this.visibilityObserver.disconnect(),vr.default.destroy(this)}registerAtomCommands(){return atom.commands.add(this.element,{"core:move-up":t=>{this.selectPrevious(),t.stopPropagation()},"core:move-down":t=>{this.selectNext(),t.stopPropagation()},"core:move-to-top":t=>{this.selectFirst(),t.stopPropagation()},"core:move-to-bottom":t=>{this.selectLast(),t.stopPropagation()},"core:confirm":t=>{this.confirmSelection(),t.stopPropagation()},"core:cancel":t=>{this.cancelSelection(),t.stopPropagation()}})}update(t){let e=!1;return"items"in t&&(this.props.items=t.items,e=!0),"maxResults"in t&&(this.props.maxResults=t.maxResults,e=!0),"filter"in t&&(this.props.filter=t.filter,e=!0),"filterQuery"in t&&(this.props.filterQuery=t.filterQuery,e=!0),"query"in t&&(this.refs.queryEditor.setText(t.query),e=!1),"selectQuery"in t&&(t.selectQuery?this.refs.queryEditor.selectAll():this.refs.queryEditor.clearSelections()),"order"in t&&(this.props.order=t.order),"emptyMessage"in t&&(this.props.emptyMessage=t.emptyMessage),"errorMessage"in t&&(this.props.errorMessage=t.errorMessage),"infoMessage"in t&&(this.props.infoMessage=t.infoMessage),"loadingMessage"in t&&(this.props.loadingMessage=t.loadingMessage),"loadingBadge"in t&&(this.props.loadingBadge=t.loadingBadge),"itemsClassList"in t&&(this.props.itemsClassList=t.itemsClassList),"initialSelectionIndex"in t&&(this.props.initialSelectionIndex=t.initialSelectionIndex),e&&this.computeItems(),vr.default.update(this)}render(){return yr.div({},yr(mr.TextEditor,{ref:"queryEditor",mini:!0}),this.renderLoadingMessage(),this.renderInfoMessage(),this.renderErrorMessage(),this.renderItems())}renderItems(){if(this.items.length>0){const t=["list-group"].concat(this.props.itemsClassList||[]).join(" ");return this.visibilityObserver&&vr.default.getScheduler().updateDocument((()=>{Array.from(this.refs.items.children).slice(this.props.initiallyVisibleItemCount).forEach((t=>{this.visibilityObserver.observe(t)}))})),this.listItems=this.items.map(((t,e)=>{const n=this.getSelectedItem()===t,r=!this.props.initiallyVisibleItemCount||ethis.didClickItem(e)})})),yr.ol({className:t,ref:"items"},...this.listItems)}return!this.props.loadingMessage&&this.props.emptyMessage?yr.span({ref:"emptyMessage"},this.props.emptyMessage):""}renderErrorMessage(){return this.props.errorMessage?yr.span({ref:"errorMessage"},this.props.errorMessage):""}renderInfoMessage(){return this.props.infoMessage?yr.span({ref:"infoMessage"},this.props.infoMessage):""}renderLoadingMessage(){return this.props.loadingMessage?yr.div({className:"loading"},yr.span({ref:"loadingMessage",className:"loading-message"},this.props.loadingMessage),this.props.loadingBadge?yr.span({ref:"loadingBadge",className:"badge"},this.props.loadingBadge):""):""}getQuery(){return this.refs&&this.refs.queryEditor?this.refs.queryEditor.getText():""}getFilterQuery(){return this.props.filterQuery?this.props.filterQuery(this.getQuery()):this.getQuery()}didChangeQuery(){this.props.didChangeQuery&&this.props.didChangeQuery(this.getFilterQuery()),this.computeItems()}didClickItem(t){this.selectIndex(t),this.confirmSelection()}computeItems(t){this.listItems=null,this.visibilityObserver&&this.visibilityObserver.disconnect();const e=this.props.filter||this.fuzzyFilter.bind(this);this.items=e(this.props.items.slice(),this.getFilterQuery()),this.props.order&&this.items.sort(this.props.order),this.props.maxResults&&(this.items=this.items.slice(0,this.props.maxResults)),this.selectIndex(this.props.initialSelectionIndex,t)}fuzzyFilter(t,e){if(0===e.length)return t;{const n=[];for(const r of t){const t=this.props.filterKeyForItem?this.props.filterKeyForItem(r):r,i=wr.default.score(t,e);i>0&&n.push({item:r,score:i})}return n.sort(((t,e)=>e.score-t.score)),n.map((t=>t.item))}}getSelectedItem(){return void 0===this.selectionIndex?null:this.items[this.selectionIndex]}renderItemAtIndex(t){const e=this.items[t],n=this.getSelectedItem()===e,r=this.listItems[t].component;this.visibilityObserver&&this.visibilityObserver.unobserve(r.element),r.update({element:this.props.elementForItem(e,{selected:n,index:t,visible:!0}),selected:n,onclick:()=>this.didClickItem(t)})}selectPrevious(){return void 0===this.selectionIndex?this.selectLast():this.selectIndex(this.selectionIndex-1)}selectNext(){return void 0===this.selectionIndex?this.selectFirst():this.selectIndex(this.selectionIndex+1)}selectFirst(){return this.selectIndex(0)}selectLast(){return this.selectIndex(this.items.length-1)}selectNone(){return this.selectIndex(void 0)}selectIndex(t,e=!0){t>=this.items.length?t=0:t<0&&(t=this.items.length-1);const n=this.selectionIndex;return this.selectionIndex=t,void 0!==t&&this.props.didChangeSelection&&this.props.didChangeSelection(this.getSelectedItem()),e?this.listItems?(n>=0&&this.renderItemAtIndex(n),t>=0&&this.renderItemAtIndex(t),vr.default.getScheduler().getNextUpdatePromise()):vr.default.update(this):Promise.resolve()}selectItem(t){const e=this.items.indexOf(t);if(-1===e)throw new Error("Cannot select the specified item because it does not exist.");return this.selectIndex(e)}confirmSelection(){const t=this.getSelectedItem();null!=t?this.props.didConfirmSelection&&this.props.didConfirmSelection(t):this.props.didConfirmEmptySelection&&this.props.didConfirmEmptySelection()}cancelSelection(){this.props.didCancelSelection&&this.props.didCancelSelection()}};class br{constructor(t){this.mouseDown=this.mouseDown.bind(this),this.mouseUp=this.mouseUp.bind(this),this.didClick=this.didClick.bind(this),this.selected=t.selected,this.onclick=t.onclick,this.element=t.element,this.element.addEventListener("mousedown",this.mouseDown),this.element.addEventListener("mouseup",this.mouseUp),this.element.addEventListener("click",this.didClick),this.selected&&this.element.classList.add("selected"),this.domEventsDisposable=new mr.Disposable((()=>{this.element.removeEventListener("mousedown",this.mouseDown),this.element.removeEventListener("mouseup",this.mouseUp),this.element.removeEventListener("click",this.didClick)})),vr.default.getScheduler().updateDocument(this.scrollIntoViewIfNeeded.bind(this))}mouseDown(t){t.preventDefault()}mouseUp(t){t.preventDefault()}didClick(t){t.preventDefault(),this.onclick()}destroy(){this.element.remove(),this.domEventsDisposable.dispose()}update(t){this.element.removeEventListener("mousedown",this.mouseDown),this.element.removeEventListener("mouseup",this.mouseUp),this.element.removeEventListener("click",this.didClick),this.element.parentNode.replaceChild(t.element,this.element),this.element=t.element,this.element.addEventListener("mousedown",this.mouseDown),this.element.addEventListener("mouseup",this.mouseUp),this.element.addEventListener("click",this.didClick),t.selected&&this.element.classList.add("selected"),this.selected=t.selected,this.onclick=t.onclick,vr.default.getScheduler().updateDocument(this.scrollIntoViewIfNeeded.bind(this))}scrollIntoViewIfNeeded(){this.selected&&this.element.scrollIntoViewIfNeeded(!1)}}var _r=C(dr);async function xr({items:t,itemTemplate:e,itemFilterKey:n,didChangeSelection:r}){let i;const o=document.activeElement;try{return await new Promise((o=>{let s,a,c="Loading...",u=!1;const l=t=>{u||Kt(f.update(t))};"function"==typeof t&&(s=async e=>{const n=setTimeout((()=>l({loadingMessage:"Loading..."})),300),r=await t(e);clearTimeout(n),l({items:r,emptyMessage:"Nothing matches the search value",loadingMessage:void 0})},c=void 0,a="Please enter a search value");const f=new _r({items:[],elementForItem:t=>ft.render(e(t,f)),filterKeyForItem:t=>""+t[n],didChangeSelection:r,didCancelSelection:()=>{u=!0,o(void 0)},didConfirmSelection:t=>{u=!0,o(t)},loadingMessage:c,didChangeQuery:s,emptyMessage:a,itemsClassList:["atom-typescript"]});"function"!=typeof t&&Kt(Promise.resolve(t).then((t=>{l({items:t,loadingMessage:void 0})}))),i=atom.workspace.addModalPanel({item:f,visible:!0}),f.focus()}))}finally{i&&i.destroy(),o&&o.focus()}}const Sr=[];function kr(t,e,n){Sr.push({selector:t,command:e,desc:n})}async function Er(t,e,n){const r=Promise.all(t.body.refs.map((async t=>{var e;const n=(await new Promise(((e,n)=>x.readFile(t.file,((t,r)=>{t?n(t):e(r.toString("utf-8"))}))))).split(/\r?\n/g),r=void 0!==t.contextStart&&void 0!==t.contextEnd?n.slice(t.contextStart.line-1,t.contextEnd.line):n,i=(await pe(r.join("\n"),"source.tsx"))[t.start.line-((null===(e=t.contextStart)||void 0===e?void 0:e.line)||1)];return{...t,hlText:i}}))),i=await xr({items:r,itemTemplate:(t,e)=>ft.dom("li",null,ft.dom(hr,{label:atom.project.relativize(t.file),query:e.getFilterQuery()}),ft.dom("div",{className:"pull-right"},"line: ",t.start.line),ft.dom(Yn,{highlightedText:t.hlText})),itemFilterKey:"file"});i&&await n(e,i)}async function Cr(t,e,n){if(t.body)if(t.body.length>1){const r=await xr({items:t.body,itemTemplate:(t,e)=>ft.dom("li",null,ft.dom(hr,{label:t.file,query:e.getFilterQuery()}),ft.dom("div",{className:"pull-right"},"line: ",t.start.line)),itemFilterKey:"file"});r&&await n(e,r)}else t.body.length>0&&await n(e,t.body[0])}function Tr(t){const e=t.spans.map(Xt).reduce(((t,e)=>e.union(t)));return{kind:Pr[t.kind],plainText:t.text,startPosition:e.start,endPosition:e.end,landingPosition:t.nameSpan?Xt(t.nameSpan).start:void 0,children:t.childItems?t.childItems.map(Tr).sort(Ar):[]}}function Ar(t,e){const n=t.landingPosition?t.landingPosition:t.startPosition,r=e.landingPosition?e.landingPosition:e.startPosition;return n.compare(r)}kr("atom-text-editor","typescript:find-references",(t=>({description:"Find where symbol under text cursor is referenced",async didDispatch(e){const n=fe(e);if(!n)return;const r=await t.getClient(n.file),i=await r.execute("references",n);await Er(i,e,t.histGoForward)}}))),kr("atom-text-editor","typescript:go-to-declaration",(t=>({description:"Go to declaration of symbol under text cursor",async didDispatch(e){const n=fe(e);if(!n)return;const r=await t.getClient(n.file),i=await r.execute("definition",n);await Cr(i,e,t.histGoForward)}})));const Pr={directory:"file",module:"module","external module name":"module",class:"class","local class":"class",method:"method",property:"property",getter:"property",setter:"property","JSX attribute":"field",constructor:"constructor",enum:"enum",interface:"interface",type:"interface",function:"function","local function":"function",label:"variable",alias:"variable",var:"variable",let:"variable","local var":"variable",parameter:"variable","enum member":"constant",const:"constant",string:"string","":void 0,warning:void 0,keyword:void 0,script:void 0,call:void 0,index:void 0,construct:void 0,"type parameter":void 0,"primitive type":void 0};class Or{constructor(t){this.getClient=t,this.triggerCharacters=new Set([]),this.grammarScopes=ce(),this.priority=100,this.disposables=new d;const e=new Set(["<","(",","]),n=new Set([]);this.disposables.add(atom.config.observe("atom-typescript.sigHelpDisplayOnChange",(t=>{this.triggerCharacters=t?e:n})))}dispose(){this.disposables.dispose()}async getSignatureHelp(t,e){try{const n=t.getPath();if(void 0===n)return;const r=await this.getClient(n),i=(await r.execute("signatureHelp",{file:n,line:e.row+1,offset:e.column+1})).body;return{signatures:i.items.map(re),activeParameter:i.argumentIndex,activeSignature:i.selectedItemIndex}}catch(t){return}}}function Ir(t){return ft.dom("li",null,t.description)}class jr{constructor(t,e){this.getClient=t,this.applyEdits=e,this.selector=ce().map((t=>t.includes(".")?"."+t:t)).join(", "),this.inclusionPriority=3,this.suggestionPriority=atom.config.get("atom-typescript").autocompletionSuggestionPriority,this.excludeLowerPriority=!1}async getSuggestions(t){const e=function(t){const e=t.editor.getPath();if(void 0===e)return;return{file:e,line:t.bufferPosition.row+1,offset:t.bufferPosition.column+1}}(t),n=function(t){const e=t.editor.getBuffer().getTextInRange([[t.bufferPosition.row,0],t.bufferPosition]).match(Nr);return e?e[0]:""}(t);if(!e)return[];const r=function(t){if(void 0===t)return;if(!t)return;const e=t.slice(-1);if(Br.has(e))return e;return}(function(t,e){let n;const r=new h.Range([0,0],e);return t.backwardsScanInRange(/\S/,r,(({matchText:t,stop:e})=>{n=t,e()})),n}(t.editor.getBuffer(),t.bufferPosition));if(!n&&!t.activatedManually&&!r)return[];if(Fr(t.scopeDescriptor.getScopesArray(),"string.template.")&&!Fr(t.scopeDescriptor.getScopesArray(),"template.expression."))return[];try{let i=await this.getSuggestionsWithCache({prefix:n,location:e,triggerCharacter:r,activatedManually:t.activatedManually});return i=nr.filter(i,n,{key:"displayText"}),i.map((r=>({replacementPrefix:r.replacementRange?t.editor.getTextInBufferRange(r.replacementRange):n,location:e,...this.getDetailsFromCache(r),...Mr(t,r)})))}catch(t){return[]}}async getSuggestionDetailsOnSelect(t){return"text"in t&&!("rightLabel"in t)?this.getAdditionalDetails(t):null}onDidInsertSuggestion(t){const e=t.suggestion;if(!e.hasAction)return;if(!this.lastSuggestions)return;const n=this.lastSuggestions.client;let r=this.getDetailsFromCache(e);Kt((async()=>{var t;if(r||(r=await this.getAdditionalDetails(e)),!(null===(t=r)||void 0===t?void 0:t.details.codeActions))return;let i;i=1===r.details.codeActions.length?r.details.codeActions[0]:await xr({items:r.details.codeActions,itemTemplate:Ir,itemFilterKey:"description"}),i&&(await this.applyEdits(i.changes),i.commands&&await Promise.all(i.commands.map((t=>n.execute("applyCodeActionCommand",{command:t})))))})())}async getAdditionalDetails(t){var e;if(void 0===t.identifier)return null;if(!this.lastSuggestions)return null;const n=await this.lastSuggestions.client.execute("completionEntryDetails",{entryNames:[t.identifier],...this.lastSuggestions.location});if(!n.body)return null;const[r]=n.body;if(!r)return null;let i=r.displayParts;i.length>=3&&"("===i[0].text&&i[1].text===t.leftLabel&&")"===i[2].text&&(i=i.slice(3));let o=i.map((t=>t.text)).join("");const s=t.hasAction&&1===(null===(e=r.codeActions)||void 0===e?void 0:e.length)?r.codeActions[0].description+"\n\n":"";s&&(o=s);const a=s+r.displayParts.map((t=>t.text)).join("")+(r.documentation?"\n\n"+r.documentation.map((t=>t.text)).join(" "):"");return this.lastSuggestions.details.set(t.displayText,{details:r,rightLabel:o,description:a}),{...t,details:r,rightLabel:o,description:a}}getDetailsFromCache(t){if(!this.lastSuggestions)return null;const e=this.lastSuggestions.details.get(t.displayText);return e||null}async getSuggestionsWithCache({prefix:t,location:e,triggerCharacter:n,activatedManually:r}){if(this.lastSuggestions&&!r){const n=this.lastSuggestions.location,r=Dr(this.lastSuggestions.prefix,n.offset),i=Dr(t,e.offset);if(n.file===e.file&&n.line===e.line&&r===i&&0!==this.lastSuggestions.suggestions.length)return this.lastSuggestions.suggestions}const i=await this.getClient(e.file),o=await async function({client:t,location:e,triggerCharacter:n}){if(parseInt(t.version.split(".")[0],10)>=3){var r;const i=await t.execute("completionInfo",{includeExternalModuleExports:!1,includeInsertTextCompletions:!0,triggerCharacter:n,...e});return i.body.entries.map(Lr.bind(null,null===(r=i.body)||void 0===r?void 0:r.isMemberCompletion))}return(await t.execute("completions",{includeExternalModuleExports:!1,includeInsertTextCompletions:!0,...e})).body.map(Lr.bind(null,void 0))}({client:i,location:e,triggerCharacter:r?void 0:n});return this.lastSuggestions={client:i,location:e,prefix:t,suggestions:o,details:new Map},o}}const Nr=/(?:(?![\u{10000}-\u{10FFFF}])[\$_\p{Lu}\p{Ll}\p{Lt}\p{Lm}\p{Lo}\p{Nl}])(?:(?![\u{10000}-\u{10FFFF}])[\$_\p{Lu}\p{Ll}\p{Lt}\p{Lm}\p{Lo}\p{Nl}\u200C\u200D\p{Mn}\p{Mc}\p{Nd}\p{Pc}])*$/u;function Dr(t,e){return e-("."===t?0:t.length)}function Fr(t,e){for(const n of t)if(n.includes(e))return!0;return!1}function Lr(t,e){return{displayText:e.name,text:void 0!==e.insertText?e.insertText:e.name,leftLabel:e.kind,replacementRange:e.replacementSpan?Xt(e.replacementSpan):void 0,type:Rr[e.kind],isMemberCompletion:t,identifier:void 0!==e.source?{name:e.name,source:e.source}:e.name,hasAction:e.hasAction}}function Mr(t,e){return atom.config.get("atom-typescript.autocompleteParens")&&["function","method"].includes(e.leftLabel)&&!function(t){const e=t.editor.getBuffer(),n=t.bufferPosition;return!!e.getTextInRange([n,[n.row,e.lineLengthForRow(n.row)]]).match(/\s*\(/)}(t)?{...e,snippet:e.text+"($1)",text:void 0}:e}const Rr={directory:"require",module:"import","external module name":"import",class:"class","local class":"class",method:"method",property:"property",getter:"property",setter:"property","JSX attribute":"property",constructor:"method",enum:"type",interface:"type",type:"type","type parameter":"type","primitive type":"type",function:"function","local function":"function",label:"variable",alias:"import",var:"variable",let:"variable","local var":"variable",parameter:"variable","enum member":"constant",const:"constant",string:"value",keyword:"keyword","":void 0,warning:void 0,script:void 0,call:void 0,index:void 0,construct:void 0},Br=new Set(Object.keys({".":null,'"':null,"'":null,"`":null,"/":null,"@":null,"<":null,"#":null}));async function zr(t,e){const n=await async function(t,e){try{return await t.execute("getApplicableRefactors",{triggerReason:"invoked",...e})}catch{return}}(t,e);if(!n)return[];if(void 0===n.body||0===n.body.length)return[];const r=[];for(const t of n.body)for(const n of t.actions)r.push({refactorName:t.name,refactorDescription:t.description,refactorRange:e,actionName:n.name,actionDescription:n.description,inlineable:void 0===t.inlineable||t.inlineable});return r}async function qr(t,e,n){const r=await e.execute("getEditsForRefactor",{...t.refactorRange,refactor:t.refactorName,action:t.actionName});if(void 0===r.body)return;const{edits:i,renameFilename:o,renameLocation:s}=r.body;if(await n.applyEdits(i),void 0===o||void 0===s)return;const a=await atom.workspace.open(o,{searchAllPanes:!0,initialLine:s.line-1,initialColumn:s.offset-1});await atom.commands.dispatch(atom.views.getView(a),"typescript:rename-refactor")}kr("atom-text-editor","typescript:refactor-selection",(t=>({description:"Get a list of applicable refactors to selected code",async didDispatch(e){const n=fe(e);if(!n)return;const r=e.getSelectedBufferRange(),i=await t.getClient(n.file),o=r.isEmpty()?n:{file:n.file,startLine:r.start.row+1,startOffset:r.start.column+1,endLine:r.end.row+1,endOffset:r.end.column+1},s=await zr(i,o);if(0===s.length)return void atom.notifications.addInfo("AtomTS: No applicable refactors for the selection");const a=await xr({items:s,itemTemplate:(t,e)=>ft.dom("li",null,ft.dom(hr,{label:`${t.refactorDescription}: ${t.actionDescription}`,query:e.getFilterQuery()})),itemFilterKey:"actionDescription"});void 0!==a&&await qr(a,i,t)}})));class Hr{constructor(t,e,n){this.clientResolver=t,this.errorPusher=e,this.applyEdits=n,this.supportedFixes=new WeakMap}async getFixableRanges(t,e){const n=t.getPath();if(void 0===n)return[];const r=this.errorPusher.getErrorsInRange(n,e),i=await this.clientResolver.get(n),o=await this.getSupportedFixes(i);return Array.from(r).filter((t=>void 0!==t.code&&o.has(t.code))).map((t=>Xt(t)))}async runCodeFix(t,e){const n=t.getPath();if(void 0===n)return[];const r=await this.clientResolver.get(n),i=await this.getSupportedFixes(r),o=Array.from(this.errorPusher.getErrorsAt(n,e)).filter((t=>void 0!==t.code&&i.has(t.code))).map((t=>r.execute("getCodeFixes",{file:n,startLine:t.start.line,startOffset:t.start.offset,endLine:t.end.line,endOffset:t.end.offset,errorCodes:[t.code]}))),s=await Promise.all(o),a=[];for(const t of s)if(t.body)for(const e of t.body)a.push(e);const c=await zr(r,{file:n,...Jt(e)});return a.push(...c),a}async applyFix(t){if("changes"in t)return this.applyEdits(t.changes);return qr(t,await this.clientResolver.get(t.refactorRange.file),{applyEdits:this.applyEdits})}dispose(){}async getSupportedFixes(t){let e=this.supportedFixes.get(t);if(e)return e;const n=await t.execute("getSupportedCodeFixes");if(!n.body)throw new Error("No code fixes are supported");return e=new Set(n.body.map((t=>parseInt(t,10)))),this.supportedFixes.set(t,e),e}}async function Ur(t,e){let n;try{return await new Promise(((r,i)=>{try{const o=new m({command:t,args:["--init"],options:{cwd:e},exit:t=>{0===t?r():i(new Error("Tsc ended with nonzero exit code "+t))}});n=o.onWillThrowError(i)}catch(t){i(t)}}))}finally{n&&n.dispose()}}kr("atom-text-editor","typescript:build",(t=>({description:"Compile all files in project related to current active text editor",async didDispatch(e){const n=e.getPath();if(void 0===n)return;const r=await t.getClient(n);t.reportBuildStatus(void 0);const i=await r.execute("projectInfo",{file:n,needFileNameList:!0}),o=new Set(i.body.fileNames);o.delete(i.body.configFileName);let s=0;const a=[...o.values()].map((e=>{return n=r.execute("compileOnSaveEmitFile",{file:e,forced:!0}),i=()=>{s+=1,t.reportProgress({max:o.size,value:s})},n.then(i,i),n;var n,i}));try{if((await Promise.all(a)).some((t=>!1===t.body)))throw new Error("Emit failed");t.reportBuildStatus({success:!0})}catch(e){const n=e;console.error(n),t.reportBuildStatus({success:!1,message:n.message})}}}))),kr("atom-text-editor","typescript:check-all-files",(t=>({description:"Typecheck all files in project related to current active text editor",async didDispatch(e){var n;const r=e.getPath();if(void 0===r)return;const i=await t.getClient(r),o=await i.execute("projectInfo",{file:r,needFileNameList:!0}),s=new Set(null===(n=o.body.fileNames)||void 0===n?void 0:n.filter((t=>!t.endsWith("tsconfig.json")&&!t.includes(`${w.sep}node_modules${w.sep}`)))),a=s.size;if(i.multistepSupported){const e=i.on("syntaxDiag",(e=>{"file"in e&&s.delete(e.file),t.reportProgress({max:a,value:a-s.size})}));t.reportProgress({max:a,value:0}),await i.execute("geterrForProject",{file:r,delay:0}),e.dispose()}else{let e;const n=i.on("syntaxDiag",(r=>{void 0!==e&&window.clearTimeout(e),e=window.setTimeout((()=>{s.clear(),n.dispose(),t.reportProgress({max:a,value:a})}),2e3),"file"in r&&s.delete(r.file),0===s.size&&(n.dispose(),window.clearTimeout(e)),t.reportProgress({max:a,value:a-s.size})}));t.reportProgress({max:a,value:0}),await i.execute("geterrForProject",{file:r,delay:0})}}}))),kr("atom-workspace","typescript:clear-errors",(t=>({description:"Clear error messages",didDispatch(){t.clearErrors()}}))),kr("atom-text-editor","typescript:format-code",(t=>({description:"Format code in currently active text editor",async didDispatch(e){const n=e.getPath();if(void 0===n)return;const r=[];for(const t of e.getSelectedBufferRanges())t.isEmpty()||r.push({line:(i=t).start.row+1,offset:i.start.column+1,endLine:i.end.row+1,endOffset:i.end.column+1});var i;if(0===r.length){const t=e.getBuffer().getEndPosition();r.push({line:1,offset:1,endLine:t.row+1,endOffset:t.column+1})}const o=await t.getClient(n),s=[];for(const t of r){const e=await o.execute("format",{...t,file:n});e.body&&s.push(...e.body)}s.length>0&&e.transact((()=>{!function(t,e){for(let n=e.length-1;n>=0;n--)t.setTextInBufferRange(Xt(e[n]),e[n].newText)}(e,s)}))}}))),kr("atom-text-editor","typescript:initialize-config",(()=>({description:"Create tsconfig.json in the project related to currently-active text edtior",async didDispatch(t,e){const n=atom.project.getDirectories();if(0===n.length)return e();const r=t.getPath();if(void 0===r)return;const i=(await Bn(r,"tsc")).pathToBin;for(const t of n)t.contains(r)&&(await Ur(i,t.getPath()),atom.notifications.addSuccess("Successfully created tsconfig.json in "+t.getPath()))}}))),kr("atom-text-editor","typescript:organize-imports",(t=>({description:"Organize module imports",async didDispatch(e){const n=e.getPath();if(void 0===n)return;const r=await t.getClient(n),i=await r.execute("organizeImports",{scope:{type:"file",args:{file:n}}});i.body.length>0&&await t.applyEdits(i.body)}}))),kr("atom-text-editor","typescript:reload-projects",(t=>({description:"Reload projects",async didDispatch(e){const n=e.getPath();if(void 0===n)return;const r=await t.getClient(n);await r.execute("reloadProjects")}})));var $r,Vr,Wr={},Gr=!1;function Kr(){return Gr||(Gr=!0,$r={},function(){var t="object"==typeof self&&self.self===self&&self||"object"==typeof T&&T.global===T&&T||this||{},e=t._,n=Array.prototype,r=Object.prototype,i="undefined"!=typeof Symbol?Symbol.prototype:null,o=n.push,s=n.slice,a=r.toString,c=r.hasOwnProperty,u=Array.isArray,l=Object.keys,f=Object.create,p=function(){},h=function(t){return t instanceof h?t:this instanceof h?void(this._wrapped=t):new h(t)};void 0===$r||$r.nodeType?t._=h:(!module.nodeType&&$r&&($r=h),Vr=h,$r._=Vr),h.VERSION="1.9.1";var d,g=function(t,e,n){if(void 0===e)return t;switch(null==n?3:n){case 1:return function(n){return t.call(e,n)};case 3:return function(n,r,i){return t.call(e,n,r,i)};case 4:return function(n,r,i,o){return t.call(e,n,r,i,o)}}return function(){return t.apply(e,arguments)}},m=function(t,e,n){return h.iteratee!==d?h.iteratee(t,e):null==t?h.identity:h.isFunction(t)?g(t,e,n):h.isObject(t)&&!h.isArray(t)?h.matcher(t):h.property(t)};h.iteratee=d=function(t,e){return m(t,e,1/0)};var v=function(t,e){return e=null==e?t.length-1:+e,function(){for(var n=Math.max(arguments.length-e,0),r=Array(n),i=0;i=0&&e<=x};h.each=h.forEach=function(t,e,n){var r,i;if(e=g(e,n),k(t))for(r=0,i=t.length;r0?0:s-1;for(i||(r=e[o?o[a]:a],a+=t);a>=0&&a=3;return e(t,g(n,i,4),r,o)}};h.reduce=h.foldl=h.inject=E(1),h.reduceRight=h.foldr=E(-1),h.find=h.detect=function(t,e,n){var r=(k(t)?h.findIndex:h.findKey)(t,e,n);if(void 0!==r&&-1!==r)return t[r]},h.filter=h.select=function(t,e,n){var r=[];return e=m(e,n),h.each(t,(function(t,n,i){e(t,n,i)&&r.push(t)})),r},h.reject=function(t,e,n){return h.filter(t,h.negate(m(e)),n)},h.every=h.all=function(t,e,n){e=m(e,n);for(var r=!k(t)&&h.keys(t),i=(r||t).length,o=0;o=0},h.invoke=v((function(t,e,n){var r,i;return h.isFunction(e)?i=e:h.isArray(e)&&(r=e.slice(0,-1),e=e[e.length-1]),h.map(t,(function(t){var o=i;if(!o){if(r&&r.length&&(t=_(t,r)),null==t)return;o=t[e]}return null==o?o:o.apply(t,n)}))})),h.pluck=function(t,e){return h.map(t,h.property(e))},h.where=function(t,e){return h.filter(t,h.matcher(e))},h.findWhere=function(t,e){return h.find(t,h.matcher(e))},h.max=function(t,e,n){var r,i,o=-1/0,s=-1/0;if(null==e||"number"==typeof e&&"object"!=typeof t[0]&&null!=t)for(var a=0,c=(t=k(t)?t:h.values(t)).length;ao&&(o=r);else e=m(e,n),h.each(t,(function(t,n,r){((i=e(t,n,r))>s||i===-1/0&&o===-1/0)&&(o=t,s=i)}));return o},h.min=function(t,e,n){var r,i,o=1/0,s=1/0;if(null==e||"number"==typeof e&&"object"!=typeof t[0]&&null!=t)for(var a=0,c=(t=k(t)?t:h.values(t)).length;ar||void 0===n)return 1;if(n0?0:i-1;o>=0&&o0?a=o>=0?o:Math.max(o+c,a):c=o>=0?Math.min(o+1,c):o+c+1;else if(n&&o&&c)return r[o=n(r,i)]===i?o:-1;if(i!=i)return(o=e(s.call(r,a,c),h.isNaN))>=0?o+a:-1;for(o=t>0?a:c-1;o>=0&&oe?(r&&(clearTimeout(r),r=null),a=u,s=t.apply(i,o),r||(i=o=null)):r||!1===n.trailing||(r=setTimeout(c,l)),s};return u.cancel=function(){clearTimeout(r),a=0,r=i=o=null},u},h.debounce=function(t,e,n){var r,i,o=function(e,n){r=null,n&&(i=t.apply(e,n))},s=v((function(s){if(r&&clearTimeout(r),n){var a=!r;r=setTimeout(o,e),a&&(i=t.apply(this,s))}else r=h.delay(o,e,this,s);return i}));return s.cancel=function(){clearTimeout(r),r=null},s},h.wrap=function(t,e){return h.partial(e,t)},h.negate=function(t){return function(){return!t.apply(this,arguments)}},h.compose=function(){var t=arguments,e=t.length-1;return function(){for(var n=e,r=t[e].apply(this,arguments);n--;)r=t[n].call(this,r);return r}},h.after=function(t,e){return function(){if(--t<1)return e.apply(this,arguments)}},h.before=function(t,e){var n;return function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=null),n}},h.once=h.partial(h.before,2),h.restArguments=v;var N=!{toString:null}.propertyIsEnumerable("toString"),D=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],F=function(t,e){var n=D.length,i=t.constructor,o=h.isFunction(i)&&i.prototype||r,s="constructor";for(b(t,s)&&!h.contains(e,s)&&e.push(s);n--;)(s=D[n])in t&&t[s]!==o[s]&&!h.contains(e,s)&&e.push(s)};h.keys=function(t){if(!h.isObject(t))return[];if(l)return l(t);var e=[];for(var n in t)b(t,n)&&e.push(n);return N&&F(t,e),e},h.allKeys=function(t){if(!h.isObject(t))return[];var e=[];for(var n in t)e.push(n);return N&&F(t,e),e},h.values=function(t){for(var e=h.keys(t),n=e.length,r=Array(n),i=0;i1&&(r=g(r,e[1])),e=h.allKeys(t)):(r=B,e=P(e,!1,!1),t=Object(t));for(var i=0,o=e.length;i1&&(n=e[1])):(e=h.map(P(e,!1,!1),String),r=function(t,n){return!h.contains(e,n)}),h.pick(t,r,n)})),h.defaults=L(h.allKeys,!0),h.create=function(t,e){var n=y(t);return e&&h.extendOwn(n,e),n},h.clone=function(t){return h.isObject(t)?h.isArray(t)?t.slice():h.extend({},t):t},h.tap=function(t,e){return e(t),t},h.isMatch=function(t,e){var n=h.keys(e),r=n.length;if(null==t)return!r;for(var i=Object(t),o=0;o":">",'"':""","'":"'","`":"`"},H=h.invert(q),U=function(t){var e=function(e){return t[e]},n="(?:"+h.keys(t).join("|")+")",r=RegExp(n),i=RegExp(n,"g");return function(t){return t=null==t?"":""+t,r.test(t)?t.replace(i,e):t}};h.escape=U(q),h.unescape=U(H),h.result=function(t,e,n){h.isArray(e)||(e=[e]);var r=e.length;if(!r)return h.isFunction(n)?n.call(t):n;for(var i=0;i/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var V=/(.)^/,W={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},G=/\\|'|\r|\n|\u2028|\u2029/g,K=function(t){return"\\"+W[t]};h.template=function(t,e,n){!e&&n&&(e=n),e=h.defaults({},e,h.templateSettings);var r,i=RegExp([(e.escape||V).source,(e.interpolate||V).source,(e.evaluate||V).source].join("|")+"|$","g"),o=0,s="__p+='";t.replace(i,(function(e,n,r,i,a){return s+=t.slice(o,a).replace(G,K),o=a+e.length,n?s+="'+\n((__t=("+n+"))==null?'':_.escape(__t))+\n'":r?s+="'+\n((__t=("+r+"))==null?'':__t)+\n'":i&&(s+="';\n"+i+"\n__p+='"),e})),s+="';\n",e.variable||(s="with(obj||{}){\n"+s+"}\n"),s="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+s+"return __p;\n";try{r=new Function(e.variable||"obj","_",s)}catch(t){throw t.source=s,t}var a=function(t){return r.call(this,t,h)},c=e.variable||"obj";return a.source="function("+c+"){\n"+s+"}",a},h.chain=function(t){var e=h(t);return e._chain=!0,e};var Q=function(t,e){return t._chain?h(e).chain():e};h.mixin=function(t){return h.each(h.functions(t),(function(e){var n=h[e]=t[e];h.prototype[e]=function(){var t=[this._wrapped];return o.apply(t,arguments),Q(this,n.apply(h,t))}})),h},h.mixin(h),h.each(["pop","push","reverse","shift","sort","splice","unshift"],(function(t){var e=n[t];h.prototype[t]=function(){var n=this._wrapped;return e.apply(n,arguments),"shift"!==t&&"splice"!==t||0!==n.length||delete n[0],Q(this,n)}})),h.each(["concat","join","slice"],(function(t){var e=n[t];h.prototype[t]=function(){return Q(this,e.apply(this._wrapped,arguments))}})),h.prototype.value=function(){return this._wrapped},h.prototype.valueOf=h.prototype.toJSON=h.prototype.value,h.prototype.toString=function(){return String(this._wrapped)},"function"==typeof define&&define.amd&&define("underscore",[],(function(){return h}))}()),$r}var Qr,Zr=!1;function Jr(){return Zr||(Zr=!0,function(){var t,e,n,r,i,o,s,a,c=[].slice;a=Kr(),n={cmd:"⌘",ctrl:"⌃",alt:"⌥",option:"⌥",shift:"⇧",enter:"⏎",left:"←",right:"→",up:"↑",down:"↓"},r={cmd:"Cmd",ctrl:"Ctrl",alt:"Alt",option:"Alt",shift:"Shift",enter:"Enter",left:"Left",right:"Right",up:"Up",down:"Down"},o={"~":"`",_:"-","+":"=","|":"\\","{":"[","}":"]",":":";",'"':"'","<":",",">":".","?":"/"},s=function(t){var e,n,r,i,o;if(r=0,n=[],null==t)return n;for(e=i=0,o=t.length;i=0&&t.splice(n,1),t},setValueForKeyPath:function(t,e,n){var r,i;for(i=s(e);i.length>1;)null==t[r=i.shift()]&&(t[r]={}),t=t[r];return null!=n?t[i.shift()]=n:delete t[i.shift()]},hasKeyPath:function(t,e){var n,r,i,o;for(i=0,o=(r=s(e)).length;i0?s<=a:s>=a;o=s+=i)u.push(t.splice.apply(t,[e+o,0].concat(c.call(r.slice(o,o+i)))));return u},sum:function(t){var e,n,r;for(e=0,n=0,r=t.length;n=0&&t.length%1==0}function p(t,e){for(var n=-1,r=t.length;++n3?t(r,i,c,a):(s=o,o=i,t(r,c,a))}}function N(t,e){return e}function D(t,e,r){r=r||n;var i=f(e)?[]:{};t(e,(function(t,e,n){t(b((function(t,r){r.length<=1&&(r=r[0]),i[e]=r,n(t)})))}),(function(t){r(t,i)}))}function F(t,e,n,r){var i=[];t(e,(function(t,e,r){n(t,(function(t,e){i=i.concat(e||[]),r(t)}))}),(function(t){r(t,i)}))}function L(t,r,i){if(null==r)r=1;else if(0===r)throw new Error("Concurrency must not be zero");function o(t,r,i,o){if(null!=o&&"function"!=typeof o)throw new Error("task callback must be a function");if(t.started=!0,l(r)||(r=[r]),0===r.length&&t.idle())return e.setImmediate((function(){t.drain()}));p(r,(function(e){var r={data:e,callback:o||n};i?t.tasks.unshift(r):t.tasks.push(r),t.tasks.length===t.concurrency&&t.saturated()})),e.setImmediate(t.process)}function s(t,e){return function(){c-=1;var n=!1,r=arguments;p(e,(function(t){p(u,(function(e,r){e!==t||n||(u.splice(r,1),n=!0)})),t.callback.apply(t,r)})),t.tasks.length+c===0&&t.drain(),t.process()}}var c=0,u=[],f={tasks:[],concurrency:r,payload:i,saturated:n,empty:n,drain:n,started:!1,paused:!1,push:function(t,e){o(f,t,!1,e)},kill:function(){f.drain=n,f.tasks=[]},unshift:function(t,e){o(f,t,!0,e)},process:function(){for(;!f.paused&&cr?1:0}e.map(t,(function(t,e){n(t,(function(n,r){n?e(n):e(null,{value:t,criteria:r})}))}),(function(t,e){if(t)return r(t);r(null,h(e.sort(i),(function(t){return t.value})))}))},e.auto=function(t,r,i){"function"==typeof arguments[1]&&(i=r,r=null),i=c(i||n);var o=y(t),s=o.length;if(!s)return i(null);r||(r=s);var a={},u=0,f=!1,h=[];function d(t){h.unshift(t)}function w(t){var e=v(h,t);e>=0&&h.splice(e,1)}function _(){s--,p(h.slice(0),(function(t){t()}))}d((function(){s||i(null,a)})),p(o,(function(n){if(!f){for(var o,s=l(t[n])?t[n]:[t[n]],c=b((function(t,r){if(u--,r.length<=1&&(r=r[0]),t){var o={};m(a,(function(t,e){o[e]=t})),o[n]=r,f=!0,i(t,o)}else a[n]=r,e.setImmediate(_)})),p=s.slice(0,s.length-1),h=p.length;h--;){if(!(o=t[p[h]]))throw new Error("Has nonexistent dependency in "+p.join(", "));if(l(o)&&v(o,n)>=0)throw new Error("Has cyclic dependencies")}y()?(u++,s[s.length-1](c,a)):d((function t(){y()&&(u++,w(t),s[s.length-1](c,a))}))}function y(){return u3)throw new Error("Invalid arguments - must be either (task), (task, callback), (times, task) or (times, task, callback)");function l(t,n){function r(t,e){return function(r){t((function(t,n){r(!t||e,{err:t,result:n})}),n)}}function i(t){return function(e){setTimeout((function(){e(null)}),t)}}for(;a.times;){var o=!(a.times-=1);s.push(r(a.task,o)),!o&&a.interval>0&&s.push(i(a.interval))}e.series(s,(function(e,n){n=n[n.length-1],(t||a.callback)(n.err,n.result)}))}return u<=2&&"function"==typeof t&&(r=n,n=t),"function"!=typeof t&&c(a,t),a.callback=r,a.task=n,a.callback?l():l},e.waterfall=function(t,r){if(r=c(r||n),!l(t)){var i=new Error("First argument to waterfall must be an array of functions");return r(i)}if(!t.length)return r();!function t(e){return b((function(n,i){if(n)r.apply(null,[n].concat(i));else{var o=e.next();o?i.push(t(o)):i.push(r),z(e).apply(null,i)}}))}(e.iterator(t))()},e.parallel=function(t,n){D(e.eachOf,t,n)},e.parallelLimit=function(t,e,n){D(k(e),t,n)},e.series=function(t,n){D(e.eachOfSeries,t,n)},e.iterator=function(t){return function e(n){function r(){return t.length&&t[n].apply(null,arguments),r.next()}return r.next=function(){return n>>1);n(e,t[o])>=0?r=o:i=o-1}return r}(t.tasks,a,i)+1,0,a),t.tasks.length===t.concurrency&&t.saturated(),e.setImmediate(t.process)}))}(o,t,r,s)},delete o.unshift,o},e.cargo=function(t,e){return L(t,1,e)},e.log=M("log"),e.dir=M("dir"),e.memoize=function(t,n){var i={},o={},s=Object.prototype.hasOwnProperty;n=n||r;var a=b((function(r){var a=r.pop(),c=n.apply(null,r);s.call(i,c)?e.setImmediate((function(){a.apply(null,i[c])})):s.call(o,c)?o[c].push(a):(o[c]=[a],t.apply(null,r.concat([b((function(t){i[c]=t;var e=o[c];delete o[c];for(var n=0,r=e.length;n=t.length)return e&&(e[a]=t),n(null,t);hi.lastIndex=r;var c=hi.exec(t);return s=i,i+=c[0],o=s+c[1],r=hi.lastIndex,u[o]||e&&e[o]===o?process.nextTick(f):e&&Object.prototype.hasOwnProperty.call(e,o)?d(e[o]):fi.lstat(o,p)}function p(t,r){if(t)return n(t);if(!r.isSymbolicLink())return u[o]=!0,e&&(e[o]=o),process.nextTick(f);if(!li){var i=r.dev.toString(32)+":"+r.ino.toString(32);if(c.hasOwnProperty(i))return h(null,c[i],o)}fi.stat(o,(function(t){if(t)return n(t);fi.readlink(o,(function(t,e){li||(c[i]=e),h(t,e)}))}))}function h(t,r,i){if(t)return n(t);var o=ui.resolve(s,r);e&&(e[i]=o),d(o)}function d(e){t=ui.resolve(e,t.slice(r)),l()}l()},ci.realpath=mi),ci}var bi,_i,xi,Si,ki,Ei,Ci,Ti=!1;function Ai(t){return t&&"realpath"===t.syscall&&("ELOOP"===t.code||"ENOMEM"===t.code||"ENAMETOOLONG"===t.code)}function Pi(t,e,n){if(Ei)return xi(t,e,n);"function"==typeof e&&(n=e,e=null),xi(t,e,(function(r,i){Ai(r)?Ci.realpath(t,e,n):n(r,i)}))}function Oi(t,e){if(Ei)return Si(t,e);try{return Si(t,e)}catch(n){if(Ai(n))return Ci.realpathSync(t,e);throw n}}function Ii(){_i.realpath=Pi,_i.realpathSync=Oi}function ji(){_i.realpath=xi,_i.realpathSync=Si}function Ni(){return Ti||(Ti=!0,bi={},bi=Pi,Pi.realpath=Pi,Pi.sync=Oi,Pi.realpathSync=Oi,Pi.monkeypatch=Ii,Pi.unmonkeypatch=ji,xi=(_i=x).realpath,Si=_i.realpathSync,ki=process.version,Ei=/^v[0-5]\./.test(ki),Ci=wi()),bi}var Di,Fi,Li=!1;function Mi(){return Li||(Li=!0,Di={},Di=function(t,e){for(var n=[],r=0;r=0&&u>0){for(r=[],o=n.length;l>=0&&!a;)l==c?(r.push(l),c=n.indexOf(t,l+1)):1==r.length?a=[r.pop(),u]:((i=r.pop())=0?c:u;r.length&&(a=[o,s])}return a}function Ui(){return Bi||(Bi=!0,Ri={},Ri=zi,zi.range=Hi),Ri}var $i,Vi,Wi,Gi,Ki,Qi,Zi,Ji,Yi=!1;function Xi(t){return parseInt(t,10)==t?parseInt(t,10):t.charCodeAt(0)}function to(t){return t.split(Gi).join("\\").split(Ki).join("{").split(Qi).join("}").split(Zi).join(",").split(Ji).join(".")}function eo(t){if(!t)return[""];var e=[],n=Wi("{","}",t);if(!n)return t.split(",");var r=n.pre,i=n.body,o=n.post,s=r.split(",");s[s.length-1]+="{"+i+"}";var a=eo(o);return o.length&&(s[s.length-1]+=a.shift(),s.push.apply(s,a)),e.push.apply(e,s),e}function no(t){return t?("{}"===t.substr(0,2)&&(t="\\{\\}"+t.substr(2)),ao(function(t){return t.split("\\\\").join(Gi).split("\\{").join(Ki).split("\\}").join(Qi).split("\\,").join(Zi).split("\\.").join(Ji)}(t),!0).map(to)):[]}function ro(t){return"{"+t+"}"}function io(t){return/^-?0\d/.test(t)}function oo(t,e){return t<=e}function so(t,e){return t>=e}function ao(t,e){var n=[],r=Wi("{","}",t);if(!r||/\$$/.test(r.pre))return[t];var i,o=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(r.body),s=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(r.body),a=o||s,c=r.body.indexOf(",")>=0;if(!a&&!c)return r.post.match(/,.*\}/)?ao(t=r.pre+"{"+r.body+Qi+r.post):[t];if(a)i=r.body.split(/\.\./);else if(1===(i=eo(r.body)).length&&1===(i=ao(i[0],!1).map(ro)).length)return(f=r.post.length?ao(r.post,!1):[""]).map((function(t){return r.pre+i[0]+t}));var u,l=r.pre,f=r.post.length?ao(r.post,!1):[""];if(a){var p=Xi(i[0]),h=Xi(i[1]),d=Math.max(i[0].length,i[1].length),g=3==i.length?Math.abs(Xi(i[2])):1,m=oo;h0){var _=new Array(b+1).join("0");w=y<0?"-"+_+w.slice(1):_+w}}u.push(w)}}else u=Vi(i,(function(t){return ao(t,!1)}));for(var x=0;x65536)throw new TypeError("pattern is too long");var n=this.options;if(!n.noglobstar&&"**"===t)return fo;if(""===t)return"";var r,i="",o=!!n.nocase,s=!1,a=[],c=[],u=!1,l=-1,f=-1,p="."===t.charAt(0)?"":n.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)",h=this;function d(){if(r){switch(r){case"*":i+=mo,o=!0;break;case"?":i+=go,o=!0;break;default:i+="\\"+r}h.debug("clearStateChar %j %j",r,i),r=!1}}for(var g,m=0,v=t.length;m-1;k--){var E=c[k],C=i.slice(0,E.reStart),T=i.slice(E.reStart,E.reEnd-8),A=i.slice(E.reEnd-8,E.reEnd),P=i.slice(E.reEnd);A+=P;var O=C.split("(").length-1,I=P;for(m=0;m=0&&!(r=t[i]);i--);for(i=0;i>> no match, partial?",t,f,e,p),f!==s))}if("string"==typeof u?(c=r.nocase?l.toLowerCase()===u.toLowerCase():l===u,this.debug("string match",u,l,c)):(c=l.match(u),this.debug("pattern match",u,l,c)),!c)return!1}if(i===s&&o===a)return!0;if(i===s)return n;if(o===a)return i===s-1&&""===t[i];throw new Error("wtf?")}}function Do(){return xo||(xo=!0,No()),uo}var Fo,Lo=!1;function Mo(){return Lo||(Lo=!0,Fo={},Fo="function"==typeof Object.create?function(t,e){t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}})}:function(t,e){t.super_=e;var n=function(){};n.prototype=e.prototype,t.prototype=new n,t.prototype.constructor=t}),Fo}var Ro,Bo,zo,qo=!1;function Ho(t){return"/"===t.charAt(0)}function Uo(t){var e=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/.exec(t),n=e[1]||"",r=Boolean(n&&":"!==n.charAt(1));return Boolean(e[2]||r)}function $o(){return qo||(qo=!0,Ro={},Ro="win32"===process.platform?Uo:Ho,Bo=Ho,Ro.posix=Bo,zo=Uo,Ro.win32=zo),Ro}var Vo,Wo,Go,Ko,Qo,Zo,Jo,Yo,Xo,ts,es,ns,rs,is=!1;function os(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function ss(t,e){return t.toLowerCase().localeCompare(e.toLowerCase())}function as(t,e){return t.localeCompare(e)}function cs(t){var e=null;if("/**"===t.slice(-3)){var n=t.replace(/(\/\*\*)+$/,"");e=new rs(n,{dot:!0})}return{matcher:new rs(t,{dot:!0}),gmatcher:e}}function us(t,e,n){if(n||(n={}),n.matchBase&&-1===e.indexOf("/")){if(n.noglobstar)throw new Error("base matching requires globstar");e="**/"+e}t.silent=!!n.silent,t.pattern=e,t.strict=!1!==n.strict,t.realpath=!!n.realpath,t.realpathCache=n.realpathCache||Object.create(null),t.follow=!!n.follow,t.dot=!!n.dot,t.mark=!!n.mark,t.nodir=!!n.nodir,t.nodir&&(t.mark=!0),t.sync=!!n.sync,t.nounique=!!n.nounique,t.nonull=!!n.nonull,t.nosort=!!n.nosort,t.nocase=!!n.nocase,t.stat=!!n.stat,t.noprocess=!!n.noprocess,t.absolute=!!n.absolute,t.maxLength=n.maxLength||1/0,t.cache=n.cache||Object.create(null),t.statCache=n.statCache||Object.create(null),t.symlinks=n.symlinks||Object.create(null),function(t,e){t.ignore=e.ignore||[],Array.isArray(t.ignore)||(t.ignore=[t.ignore]),t.ignore.length&&(t.ignore=t.ignore.map(cs))}(t,n),t.changedCwd=!1;var r=process.cwd();os(n,"cwd")?(t.cwd=ts.resolve(n.cwd),t.changedCwd=t.cwd!==r):t.cwd=r,t.root=n.root||ts.resolve(t.cwd,"/"),t.root=ts.resolve(t.root),"win32"===process.platform&&(t.root=t.root.replace(/\\/g,"/")),t.cwdAbs=ns(t.cwd)?t.cwd:ps(t,t.cwd),"win32"===process.platform&&(t.cwdAbs=t.cwdAbs.replace(/\\/g,"/")),t.nomount=!!n.nomount,n.nonegate=!0,n.nocomment=!0,t.minimatch=new rs(e,n),t.options=t.minimatch.options}function ls(t){for(var e=t.nounique,n=e?[]:Object.create(null),r=0,i=t.matches.length;rthis.maxLength)return!1;if(!this.stat&&Es(this.cache,e)){var r=this.cache[e];if(Array.isArray(r)&&(r="DIR"),!n||"DIR"===r)return r;if(n&&"FILE"===r)return!1}var i=this.statCache[e];if(!i){var o;try{o=vs.lstatSync(e)}catch(t){if(t&&("ENOENT"===t.code||"ENOTDIR"===t.code))return this.statCache[e]=!1,!1}if(o&&o.isSymbolicLink())try{i=vs.statSync(e)}catch(t){i=o}else i=o}return this.statCache[e]=i,r=!0,i&&(r=i.isDirectory()?"DIR":"FILE"),this.cache[e]=this.cache[e]||r,(!n||"FILE"!==r)&&r},Os.prototype._mark=function(t){return Ss.mark(this,t)},Os.prototype._makeAbs=function(t){return Ss.makeAbs(this,t)}),ms}var js,Ns=!1;function Ds(t,e){if(t&&e)return Ds(t)(e);if("function"!=typeof t)throw new TypeError("need wrapper function");return Object.keys(t).forEach((function(e){n[e]=t[e]})),n;function n(){for(var e=new Array(arguments.length),n=0;nr?(n.splice(0,r),process.nextTick((function(){e.apply(null,i)}))):delete Vs[t]}}))}(t))}function Qs(t){for(var e=t.length,n=[],r=0;r1)return!0;for(var i=0;ithis.maxLength)return e();if(!this.stat&&ua(this.cache,n)){var i=this.cache[n];if(Array.isArray(i)&&(i="DIR"),!r||"DIR"===i)return e(null,i);if(r&&"FILE"===i)return e()}var o=this.statCache[n];if(void 0!==o){if(!1===o)return e(null,o);var s=o.isDirectory()?"DIR":"FILE";return r&&"FILE"===s?e():e(null,s,o)}var a=this,c=la("stat\0"+n,(function(r,i){if(i&&i.isSymbolicLink())return Ys.stat(n,(function(r,o){r?a._stat2(t,n,null,i,e):a._stat2(t,n,r,o,e)}));a._stat2(t,n,r,i,e)}));c&&Ys.lstat(n,c)},va.prototype._stat2=function(t,e,n,r,i){if(n&&("ENOENT"===n.code||"ENOTDIR"===n.code))return this.statCache[e]=!1,i();var o="/"===t.slice(-1);if(this.statCache[e]=r,"/"===e.slice(-1)&&r&&!r.isDirectory())return i(null,!1,r);var s=!0;return r&&(s=r.isDirectory()?"DIR":"FILE"),this.cache[e]=this.cache[e]||s,o&&"FILE"===s?i():i(null,s,r)}}function wa(){return ga||(ga=!0,ya()),Js}var ba,_a,xa,Sa,ka,Ea,Ca,Ta,Aa,Pa=!1;function Oa(t){["unlink","chmod","stat","lstat","rmdir","readdir"].forEach((function(e){t[e]=t[e]||Sa[e],t[e+="Sync"]=t[e]||Sa[e]})),t.maxBusyTries=t.maxBusyTries||3,t.emfileWait=t.emfileWait||1e3,!1===t.glob&&(t.disableGlob=!0),t.disableGlob=t.disableGlob||!1,t.glob=t.glob||Ca}function Ia(t,e,n){"function"==typeof e&&(n=e,e={}),_a(t,"rimraf: missing path"),_a.equal(typeof t,"string","rimraf: path should be a string"),_a.equal(typeof n,"function","rimraf: callback function required"),_a(e,"rimraf: invalid options argument provided"),_a.equal(typeof e,"object","rimraf: options should be object"),Oa(e);var r=0,i=null,o=0;if(e.disableGlob||!ka.hasMagic(t))return s(null,[t]);function s(t,s){return t?n(t):0===(o=s.length)?n():void s.forEach((function(t){ja(t,e,(function s(a){if(a){if(("EBUSY"===a.code||"ENOTEMPTY"===a.code||"EPERM"===a.code)&&r1&&(e=n.shift()),t=n.shift(),u.readdir(r,(function(n,i){return null!=n?t(n):(e&&(i=l.filterExtensions(i,e)),i=(i=i.sort((function(t,e){return t.toLowerCase().localeCompare(e.toLowerCase())}))).map((function(t){return v.join(r,t)})),t(null,i))}))},filterExtensions:function(t,e){return e=e.map((function(t){return""===t?t:"."+t.replace(/^\./,"")})),t.filter((function(t){return _.include(e,v.extname(t))}))},listTreeSync:function(t){var e,n;return n=[],e=function(t){return n.push(t),!0},l.traverseTreeSync(t,e,e),n},move:function(t,e,n){return p(t,e,(function(r,i){var o,s;if(!r)return i?(s=v.dirname(e),u.exists(s,(function(r){if(!r)return l.makeTree(s,(function(r){if(!r)return u.rename(t,e,n);n(r)}));u.rename(t,e,n)}))):((o=new Error("'"+e+"' already exists.")).code="EEXIST",void n(o));n(r)}))},moveSync:function(t,e){var n,r;if(!h(t,e))throw(n=new Error("'"+e+"' already exists.")).code="EEXIST",n;return r=v.dirname(e),u.existsSync(r)||l.makeTreeSync(r),u.renameSync(t,e)},removeSync:function(t){return y.sync(t)},remove:function(t,e){return y(t,e)},writeFileSync:function(t,e,n){return m.sync(v.dirname(t)),u.writeFileSync(t,e,n)},writeFile:function(t,e,n,r){return r=_.last(arguments),m(v.dirname(t),(function(i){return null!=i?"function"==typeof r?r(i):void 0:u.writeFile(t,e,n,r)}))},copy:function(t,e,n){return m(v.dirname(e),(function(r){var i,o;if(null==r)return(o=u.createReadStream(t)).on("error",(function(t){return"function"==typeof n&&n(t),n=null})),(i=u.createWriteStream(e)).on("error",(function(t){return"function"==typeof n&&n(t),n=null})),i.on("close",(function(){return"function"==typeof n&&n(),n=null})),o.pipe(i);"function"==typeof n&&n(r)}))},copySync:function(t,e){var n,r,i,o,s,a,c;for(o=u.readdirSync(t),m.sync(e),c=[],s=0,a=o.length;s0;)r=new Buffer(n),i=u.readSync(s,r,0,r.length,o),u.writeSync(a,r,0,i,o),c.push(o+=i);return c}finally{null!=s&&u.closeSync(s),null!=a&&u.closeSync(a)}},makeTreeSync:function(t){if(!l.isDirectorySync(t))return m.sync(t)},makeTree:function(t,e){return l.isDirectory(t,(function(n){return n?"function"==typeof e?e():void 0:m(t,(function(t){return"function"==typeof e?e(t):void 0}))}))},traverseTreeSync:function(t,e,n){var r;if(null==n&&(n=e),l.isDirectorySync(t))return(r=function(t,e,n){var i,o,s,a,c,l,f;for(c=0,l=(f=u.readdirSync(t)).length;c0},p=function(t,e,n){return u.stat(t,(function(r,i){if(!r)return u.stat(e,(function(r,o){if(!r||"ENOENT"!==r.code)return n(void 0,t.toLowerCase()===e.toLowerCase()&&i.dev===o.dev&&i.ino===o.ino);n(void 0,!0)}));n(r)}))},h=function(t,e){var n,r;return r=b(t),n=b(e),!r||!n||t.toLowerCase()===e.toLowerCase()&&r.dev===n.dev&&r.ino===n.ino},Wr=new Proxy({},{get:function(t,e){var n;return null!=(n=l[e])?n:u[e]},set:function(t,e,n){return l[e]=n}})}).call(Wr);class Ba{constructor(t){this.props=t,this.model=atom.workspace.buildTextEditor({mini:!0,softWrapped:!0,lineNumberGutterVisible:!1}),this.element=atom.views.getView(this.model),this.model.setText(t.initialText),t.selectAll?this.model.selectAll():this.model.getLastCursor().moveToEndOfScreenLine(),this.setReadOnly(),this.setGrammar(),this.model.scrollToBufferPosition([0,0])}async update(t){this.element=atom.views.getView(this.model),this.props={...this.props,...t},this.setReadOnly(),this.setGrammar()}focus(){this.element.focus()}getModel(){return this.model}setReadOnly(){this.model.setReadOnly(!!this.props.readOnly)}setGrammar(){void 0!==this.props.grammar?atom.textEditors.setGrammarOverride(this.model,this.props.grammar):atom.textEditors.clearGrammarOverride(this.model)}}class za{constructor(t){this.props=t,ft.initialize(this)}async update(t){this.props={...this.props,...t},await ft.update(this)}render(){return ft.dom("div",{className:"atomts-rename-view",ref:"main"},ft.dom("div",{className:"block"},ft.dom("div",null,ft.dom("span",{ref:"title"},this.props.title),ft.dom("span",{className:"subtle-info-message"},ft.dom("span",null,"Close this panel with "),ft.dom("span",{className:"highlight"},"esc"),ft.dom("span",null," key. And commit with the "),ft.dom("span",{className:"highlight"},"enter"),ft.dom("span",null," key."))),ft.dom("div",{className:"find-container block"},ft.dom("div",{className:"editor-container"},ft.dom(Ba,{ref:"editor",initialText:this.props.initialText,selectAll:this.props.selectAll}))),this.renderValidationMessage()))}async destroy(){await ft.destroy(this)}focus(){return this.refs.editor.focus()}getText(){return this.refs.editor.getModel().getText()}renderValidationMessage(){return void 0!==this.props.validationMessage?ft.dom("div",{className:"highlight-error"},this.props.validationMessage):null}}async function qa(t){const e=new za({title:t.title,initialText:t.text,selectAll:t.autoSelect}),n=atom.workspace.addModalPanel({item:e,priority:1e3}),r=document.activeElement;e.focus();const i=new d;try{return await new Promise((n=>{i.add(atom.commands.add(e.refs.main,{"core:cancel":()=>{n(void 0)},"core:confirm":()=>{const r=e.getText(),i=t.onValidate(r);i?Kt(e.update({validationMessage:i})):n(r)}}))}))}finally{n.destroy(),i.dispose(),r&&r.focus()}}function Ha(t){const e=new d;for(const n of Sr)if("atom-text-editor"===n.selector){const r=n.desc(t);e.add(atom.commands.add(n.selector,n.command,{...r,async didDispatch(t){try{const e=t.currentTarget.getModel();ue(e)?await r.didDispatch(e,(()=>t.abortKeyBinding())):(t.abortKeyBinding(),le(e)&&atom.notifications.addWarning("Atom-TypeScript cancelled last command: Current editor has no file path",{description:`Atom-TypeScript needs to determine the file path of the current editor to execute \`${n.command}\`, which it failed to do. You probably just need to save the current file somewhere.`,dismissable:!0}))}catch(t){Ua(t)}}}))}else{const r=n.desc(t);e.add(atom.commands.add(n.selector,n.command,{...r,async didDispatch(){try{await r.didDispatch()}catch(t){Ua(t)}}}))}return e}function Ua(t){atom.notifications.addFatalError("Something went wrong, see details below.",{detail:t.message,dismissable:!0,stack:t.stack})}kr("atom-text-editor","typescript:rename-file",(t=>({description:"Rename current file",async didDispatch(e){const n=e.getPath();if(!n)return;const r=await qa({autoSelect:!0,title:"Rename File",text:n,onValidate:t=>t.trim()?"":"If you want to abort : Press esc to exit"});if(!r)return;const i=await t.getClient(n),o=await i.execute("getEditsForFileRename",{oldFilePath:n,newFilePath:r});await t.applyEdits(o.body),await new Promise(((t,i)=>{Wr.move(n,r,(n=>{n?i(n):(e.getBuffer().setPath(r),t())}))}))}}))),kr("atom-text-editor","typescript:rename-refactor",(t=>({description:"Rename symbol under text cursor everywhere it is used",async didDispatch(e){const n=fe(e);if(!n)return;const r=await t.getClient(n.file),i=await r.execute("rename",n),{info:o,locs:s}=i.body;if(!o.canRename)return void atom.notifications.addInfo("AtomTS: Rename not available at cursor location");const a=await qa({autoSelect:!0,title:"Rename Variable",text:o.displayName,onValidate:t=>t.replace(/\s/g,"")!==t.trim()?"The new variable must not contain a space":t.trim()?"":"If you want to abort : Press esc to exit"});void 0!==a&&await t.applyEdits(s.map((t=>({fileName:t.file,textChanges:t.locs.map((t=>({...t,newText:a})))}))))}}))),kr("atom-workspace","typescript:restart-all-servers",(t=>({description:"Kill all tsserver instances. They will be auto-restarted",async didDispatch(){t.killAllServers()}}))),kr("atom-workspace","typescript:return-from-declaration",(t=>({description:"If used `go-to-declaration`, return to previous text cursor position",async didDispatch(){await t.histGoBack()}}))),kr("atom-workspace","typescript:show-editor-position-history",(t=>({description:"If used `go-to-declaration`, return to previous text cursor position",async didDispatch(){await t.histShowHistory()}}))),kr("atom-text-editor","typescript:toggle-semantic-view",(t=>({description:"Toggle semantic view outline",didDispatch(){t.toggleSemanticViewController()}}))),kr("atom-text-editor","typescript:show-tooltip",(t=>({description:"Show type tooltip at current text cursor position",didDispatch:async e=>t.showTooltipAt(e)}))),kr("atom-text-editor","typescript:show-signature-help",(t=>({description:"Show signature help tooltip at current text cursor position",didDispatch:async e=>t.showSigHelpAt(e)}))),kr("atom-text-editor","typescript:hide-signature-help",(t=>({description:"Hide the currently visible signature help",async didDispatch(e,n){t.hideSigHelpAt(e)||n()}}))),kr("atom-text-editor","typescript:signature-help-next",(t=>({description:"Show next signature help if available",async didDispatch(e,n){t.rotateSigHelp(e,1)||n()}}))),kr("atom-text-editor","typescript:signature-help-prev",(t=>({description:"Show previous signature help if available",async didDispatch(e,n){t.rotateSigHelp(e,-1)||n()}}))),kr("atom-text-editor","typescript:toggle-file-symbols",(t=>({description:"Toggle view for finding file symbols",async didDispatch(e){t.toggleFileSymbolsView(e)}}))),kr("atom-text-editor","typescript:toggle-project-symbols",(t=>({description:"Toggle view for finding file symbols",async didDispatch(e){t.toggleProjectSymbolsView(e)}})));class $a{constructor(t,e){this.children=e,this.props={...t,delay:{show:0,hide:0}},ft.initialize(this),this.tooltipDisposable=atom.tooltips.add(this.element,this.props)}async update(t,e){this.props={...this.props,...t},this.children=e,await ft.update(this),this.tooltipDisposable.dispose(),this.tooltipDisposable=atom.tooltips.add(this.element,this.props)}render(){return ft.dom("div",{className:"inline-block"},this.children?this.children:null)}async destroy(){await ft.destroy(this),this.tooltipDisposable.dispose()}}class Va{constructor(t){this.hiddenBuildStatus=!1,this.disposables=new d,this.buildStatusClicked=()=>{this.props.buildStatus.success||atom.notifications.addError("Build failed",{detail:this.props.buildStatus.message,dismissable:!0})},this.props={...t},this.setHideBuildStatus(atom.config.get("atom-typescript").buildStatusTimeout),this.resetBuildStatusTimeout(),ft.initialize(this),this.disposables.add(atom.config.onDidChange("atom-typescript.buildStatusTimeout",(({newValue:t})=>{this.setHideBuildStatus(t),Kt(this.update({}))})))}async update(t){const e=void 0!==t.buildStatus&&t.buildStatus.success!==this.props.buildStatus.success;this.props={...this.props,...t},e&&this.resetBuildStatusTimeout(),await ft.update(this)}render(){if(this.hiddenBuildStatus)return ft.dom("span",null);let t,e;return this.props.buildStatus.success?(t="highlight-success",e="Emit Success"):(t="highlight-error",e="Emit Failed"),ft.dom($a,{title:this.props.buildStatus.success?"Build was successful":"Build failed; click to show error message"},ft.dom("span",{className:t,on:{click:this.buildStatusClicked}},e))}async destroy(){await ft.destroy(this)}resetBuildStatusTimeout(){this.hiddenBuildStatus=!1,this.props.buildStatus.success&&this.hideBuildStatus()}setHideBuildStatus(t){this.hideBuildStatus=t>0?Qt.debounce((()=>{this.hiddenBuildStatus=!0,Kt(ft.update(this))}),1e3*t):0===t?()=>{this.hiddenBuildStatus=!0}:()=>{}}}class Wa{constructor(t){this.props={...t},ft.initialize(this)}async update(t){this.props={...this.props,...t},await ft.update(this)}render(){return ft.dom($a,{title:()=>this.props.tsConfigPath.startsWith("/dev/null")?"No tsconfig.json":"Click to open "+atom.project.relativize(this.props.tsConfigPath)},ft.dom("a",{className:"inline-block",href:"",on:{click:t=>{t.preventDefault(),this.openConfigPath()}}},this.props.tsConfigPath.startsWith("/dev/null")?"No project":b((t=this.props.tsConfigPath,"~"+atom.project.relativize(t)))));var t}async destroy(){await ft.destroy(this)}openConfigPath(){this.props.tsConfigPath.startsWith("/dev/null")?atom.notifications.addInfo("No tsconfig for current file"):Kt(atom.workspace.open(this.props.tsConfigPath))}}class Ga{constructor(t={}){this.props={visible:!0,pending:[],progress:{max:0,value:0},...t},ft.initialize(this)}async update(t){this.props={...this.props,...t},await ft.update(this)}render(){return ft.dom("ts-status-panel",{className:this.props.visible?"":"hide"},this.renderVersion(),this.renderPending(),this.renderConfigPath(),this.renderStatus(),this.renderProgress())}async destroy(){await ft.destroy(this)}dispose(){Kt(this.destroy())}async show(){await this.update({visible:!0})}async hide(){await this.update({visible:!1})}renderVersion(){return void 0!==this.props.clientVersion?ft.dom($a,{title:"Active TypeScript version"},this.props.clientVersion):null}renderPending(){return this.props.pending.length>0?ft.dom($a,{title:`Pending Requests:
    ${this.props.pending.map((({title:t})=>`
  • ${t}
  • `)).join("")}
`,html:!0},ft.dom("span",{ref:"pendingCounter"},this.props.pending.length.toString()),ft.dom("span",{ref:"pendingSpinner",className:"loading loading-spinner-tiny inline-block",style:{marginLeft:"5px",opacity:"0.5",verticalAlign:"sub"}})):null}renderConfigPath(){return void 0!==this.props.tsConfigPath?ft.dom(Wa,{tsConfigPath:this.props.tsConfigPath}):null}renderStatus(){return this.props.buildStatus?ft.dom(Va,{buildStatus:this.props.buildStatus}):null}renderProgress(){return this.props.progress.value0;)e=this.prevCursorPositions.pop();if(e)return this.open({file:e.file,start:{line:e.line,offset:e.offset}});atom.notifications.addInfo("AtomTS: Previous position not found.")}async goForward(t,e){const n=fe(t);if(n){this.prevCursorPositions.push(n);const t=100;this.prevCursorPositions.length>t&&this.prevCursorPositions.splice(0,this.prevCursorPositions.length-t)}return this.open(e)}async showHistory(){const t=await xr({items:this.getHistory().slice().reverse().map(((t,e)=>({...t,idx:e}))),itemTemplate:(t,e)=>ft.dom("li",{className:"two-lines"},ft.dom("div",{className:"primary-line"},ft.dom(hr,{label:t.file,query:e.getFilterQuery()})),ft.dom("div",{className:"secondary-line"},"Line: ",t.line,", column: ",t.offset)),itemFilterKey:"file"});t&&await this.goHistory(t.idx+1)}getHistory(){return this.prevCursorPositions}dispose(){}serialize(){return this.prevCursorPositions}async open(t){const e=await atom.workspace.open(t.file,{initialLine:t.start.line-1,initialColumn:t.start.offset-1,searchAllPanes:!0});return atom.workspace.isTextEditor(e)&&e.scrollToCursorPosition({center:!0}),e}}class Qa{constructor(t,e){let n,r,i;this.getClient=t,this.editor=e,this.disposables=new d,this.occurrenceMarkers=[],this.disposed=!1;let o=!1;this.disposables.add(atom.config.observe("atom-typescript.occurrenceHighlightDebounceTimeout",(t=>{n=Qt.debounce((()=>{Kt(this.update())}),t),i=3.5*t})),e.onDidChangeCursorPosition((()=>{void 0===r?n():o=!0})),e.onDidChangePath((()=>n())),e.onDidChangeGrammar((()=>n())),e.onDidChange((()=>{void 0!==r&&clearTimeout(r),r=window.setTimeout((()=>{o&&(n(),o=!1),r=void 0}),i)})))}dispose(){this.disposed||(this.disposed=!0,this.disposables.dispose(),this.clearMarkers())}clearMarkers(){for(const t of this.occurrenceMarkers)t.destroy();this.occurrenceMarkers=[]}async update(){if(this.disposed)return;if(!ue(this.editor))return void this.clearMarkers();const t=this.editor.getPath();if(void 0===t)return;const e=await this.getClient(t);if(this.disposed)return;const n=this.editor.getLastCursor().getBufferPosition();try{const r=await e.execute("documentHighlights",{file:t,line:n.row+1,offset:n.column+1,filesToSearch:[t]});if(this.disposed)return;const i=Array.from(this.getNewOccurrenceMarkers(r.body));for(const t of this.occurrenceMarkers)i.includes(t)||t.destroy();this.occurrenceMarkers=i}catch(t){window.atom_typescript_debug&&console.error(t)}}*getNewOccurrenceMarkers(t){for(const e of t)if(e.file===this.editor.getPath())for(const t of e.highlightSpans){const e=Xt(t),n=this.occurrenceMarkers.find((t=>t.getBufferRange().isEqual(e)));if(n)yield n;else{const t=this.editor.markBufferRange(e);this.editor.decorateMarker(t,{type:"highlight",class:"atom-typescript-occurrence"}),yield t}}}}class Za{constructor(t){this.disposables=new d,this.disposables.add(atom.workspace.observeTextEditors((e=>{const n=new Qa(t,e);this.disposables.add(n,e.onDidDestroy((()=>{this.disposables.remove(n),n.dispose()})))})))}dispose(){this.disposables.dispose()}}function Ja(t,e,n,r){let i,o=n.right,s=!1,a="";t.style.left="",t.style.top="",t.style.right="",t.style.bottom="";const c=e.clientWidth,u=getComputedStyle(t),l=parseInt(u.width,10),f=parseInt(u.height,10);if(o+l>=c&&(o=c-l-10),o<0&&(a="pre-wrap",o=10,s=10),"bottom"===r){const t=e.clientHeight;i=n.bottom,i+f>=t&&(i=n.top-f)}else"top"===r&&(i=n.top-f,i<0&&(i=n.bottom));t.style.left=o+"px",t.style.top=i+"px",!1!==s&&(t.style.right=s+"px"),a&&(t.style.whiteSpace=a)}class Ya{constructor(t){this.parent=t,this.props={left:0,right:0,top:0,bottom:0},ft.initialize(this)}async destroy(){return ft.destroy(this)}async update(t){var e,n,r;void 0!==(null===(e=t.sigHelp)||void 0===e?void 0:e.selectedItemIndex)&&(null===(n=t.sigHelp)||void 0===n?void 0:n.selectedItemIndex)!==(null===(r=this.props.sigHelp)||void 0===r?void 0:r.selectedItemIndex)&&(this.props.visibleItem=void 0),this.props={...this.props,...t},void 0===this.props.sigHelp?this.props.visibleItem=void 0:void 0!==this.props.visibleItem&&(this.props.visibleItem=this.props.visibleItem%this.props.sigHelp.items.length,this.props.visibleItem<0&&(this.props.visibleItem+=this.props.sigHelp.items.length)),await ft.update(this)}writeAfterUpdate(){Ja(this.element,this.parent,this.props,atom.config.get("atom-typescript").sigHelpPosition)}render(){return ft.dom("div",{className:"atom-typescript-tooltip tooltip",key:this.sigHelpHash()},ft.dom("div",{className:"tooltip-inner"},this.tooltipContents()))}sigHelpHash(){if(!this.props.sigHelp)return;const{start:t,end:e}=this.props.sigHelp.applicableSpan;return`${t.line}:${t.offset}-${e.line}:${e.offset}`}tooltipContents(){if(!this.props.sigHelp)return"…";const{sigHelp:t}=this.props,e=void 0!==this.props.visibleItem?this.props.visibleItem:t.selectedItemIndex,n=t.items.length,r=["atom-typescript-tooltip-signature-help"];function i(n){const i=[];return n===t.selectedItemIndex&&i.push("atom-typescript-tooltip-signature-help-selected"),n===e&&i.push("atom-typescript-tooltip-signature-help-visible"),[...r,...i].join(" ")}return n>1&&r.push("atom-typescript-tooltip-signature-help-changable"),t.items.map(((e,n)=>ft.dom("div",{className:i(n)},ft.dom("div",null,oe(e.prefixDisplayParts),this.renderSigHelpParams(e.parameters,t.argumentIndex),oe(e.suffixDisplayParts),ft.dom("div",{className:"atom-typescript-tooltip-signature-help-documentation"},oe(e.documentation))))))}renderSigHelpParams(t,e){return t.map(((t,n)=>ft.dom("span",{className:"atom-typescript-tooltip-signature-help-parameter"},n>0?", ":null,ft.dom("span",{className:n===e?"atom-typescript-tooltip-signature-help-selected":void 0},oe(t.displayParts)))))}}class Xa{constructor(t,e,n){this.deps=t,this.editor=e,this.cancelled=!1,this.disposables=new h.CompositeDisposable;const r=atom.views.getView(this.editor);this.view=new Ya(r),r.appendChild(this.view.element);const i=Qt.debounce(this.updateTooltip.bind(this),100,{leading:!0});this.disposables.add(this.editor.onDidChangeCursorPosition((t=>{n=t.newBufferPosition,Kt(i(n))})),r.onDidChangeScrollTop((()=>{setImmediate((()=>this.updateTooltipPosition(n)))})),r.onDidChangeScrollLeft((()=>{setImmediate((()=>this.updateTooltipPosition(n)))}))),Kt(this.updateTooltip(n))}isDisposed(){return this.cancelled}dispose(){this.cancelled||(this.cancelled=!0,this.disposables.dispose(),Kt(this.view.destroy()))}async rotateSigHelp(t){const{visibleItem:e,sigHelp:n}=this.view.props,r=void 0!==e?e:void 0!==(null==n?void 0:n.selectedItemIndex)?null==n?void 0:n.selectedItemIndex:0;await this.view.update({visibleItem:r+t})}async updateTooltip(t){if(this.cancelled)return;let e;try{e=this.computeTooltipPosition(t)}catch(t){return void console.warn(t)}const n=await this.getMessage(t);this.cancelled||(n?await this.view.update({...e,sigHelp:n}):this.dispose())}updateTooltipPosition(t){if(this.cancelled)return;const e=this.computeTooltipPosition(t);Kt(this.view.update({...e}))}computeTooltipPosition(t){const e=atom.views.getView(this.editor),n=e.pixelPositionForBufferPosition(t),r=e.querySelector(".lines").getBoundingClientRect(),i=this.editor.getLineHeightInPixels(),o=e.getBoundingClientRect(),s=n.top+r.top-o.top+i/2,a=n.left+r.left-o.left,c=.7*i;return{left:a,right:a,top:s-c,bottom:s+c}}async getMessage(t){if(!ue(this.editor))return;const e=this.editor.getPath();if(void 0===e)return;const n=await this.deps.getClient(e);try{return(await n.execute("signatureHelp",{file:e,line:t.row+1,offset:t.column+1})).body}catch(t){return}}}class tc{constructor(t){this.deps=t,this.subscriptions=new h.CompositeDisposable,this.editorMap=new WeakMap,this.stoppedChanging=t=>e=>{if(!atom.config.get("atom-typescript.sigHelpDisplayOnChange"))return;if(void 0===t.getPath())return;const n=t.getLastCursor().getBufferPosition(),[r]=e.changes.filter((t=>t.newRange.containsPoint(n)));r&&null!==r.newText.match(/[<(,]/)&&Kt(this.showTooltip(t,n))},this.subscriptions.add(atom.workspace.observeTextEditors((t=>{const e=new h.CompositeDisposable;e.add(t.onDidDestroy((()=>{e.dispose(),this.subscriptions.remove(e);const n=this.editorMap.get(t);n&&n.dispose()})),t.onDidStopChanging(this.stoppedChanging(t))),this.subscriptions.add(e)})))}dispose(){this.subscriptions.dispose();for(const t of atom.workspace.getTextEditors()){const e=this.editorMap.get(t);e&&e.dispose()}}async showTooltipAt(t){const e=t.getLastCursor().getBufferPosition();return this.showTooltip(t,e)}rotateSigHelp(t,e){const n=this.editorMap.get(t);return!(!n||n.isDisposed())&&(Kt(n.rotateSigHelp(e)),!0)}hideTooltipAt(t){const e=this.editorMap.get(t);return!(!e||e.isDisposed())&&(e.dispose(),!0)}async showTooltip(t,e){const n=this.editorMap.get(t);n&&!n.isDisposed()||this.editorMap.set(t,new Xa(this.deps,t,e))}}function ec(t,e,n,r){const i=e=>{const i=e.target.closest(n);i&&t.contains(i)&&r(e)};return t.addEventListener(e,i),new v((()=>{t.removeEventListener(e,i)}))}class nc{constructor(){this.tooltip=null,this.props={left:0,right:0,top:0,bottom:0},ft.initialize(this)}async destroy(){return ft.destroy(this)}async update(t){this.props={...this.props,...t},this.tooltip=await Vn(this.props.info,ft,(t=>ft.dom("div",{className:"atom-typescript-tooltip-tooltip-code"},t))),await ft.update(this)}writeAfterUpdate(){Ja(this.element,document.body,this.props,atom.config.get("atom-typescript").tooltipPosition)}render(){return ft.dom("div",{className:"atom-typescript-tooltip tooltip"},ft.dom("div",{className:"tooltip-inner"},this.tooltip))}}class rc{constructor(t,e,n,r){this.getClient=t,this.cancelled=!1,Kt(this.initialize(e,n,r))}dispose(){this.cancelled=!0,this.view&&(Kt(this.view.destroy()),this.view=void 0)}async initialize(t,e,n){const r=atom.views.getView(t);let i,o;try{i=r.pixelPositionForBufferPosition(n),o=r.pixelPositionForBufferPosition(n.traverse([0,1]))}catch(e){return void console.warn(e)}if(i.left>=o.left)return;const s=.7*t.getLineHeightInPixels(),a={left:e.clientX,right:e.clientX,top:e.clientY-s,bottom:e.clientY+s},c=await this.getMessage(t,n);this.cancelled||void 0!==c&&await this.showTooltip(a,c)}async getMessage(t,e){let n;const r=await this.getClient(t);if(!r)return;const i=t.getPath();try{if(void 0===i)return;n=await r.execute("quickinfo",{file:i,line:e.row+1,offset:e.column+1})}catch(t){return}return n.body}async showTooltip(t,e){this.view=new nc,document.body.appendChild(this.view.element),await this.view.update({...t,info:e})}}class ic{constructor(t){this.getClientInternal=t,this.subscriptions=new h.CompositeDisposable,this.editorMap=new WeakMap,this.getClient=async t=>{const e=t.getPath();if(void 0!==e&&ue(t)&&S.existsSync(e))return this.getClientInternal(e)},this.clearExprTypeTimeout=()=>{void 0!==this.exprTypeTimeout&&(clearTimeout(this.exprTypeTimeout),this.exprTypeTimeout=void 0),this.hideExpressionType()},this.trackMouseMovement=t=>{let e;return n=>{const r=function(t,e){const n=atom.views.getView(t).getComponent().screenPositionForMouseEvent(e);if(!isNaN(n.row)&&!isNaN(n.column))return t.bufferPositionForScreenPosition(n)}(t,n);r&&(e&&e.isEqual(r)&&this.pendingTooltip||(e=r,this.clearExprTypeTimeout(),this.exprTypeTimeout=window.setTimeout((()=>this.showExpressionType(t,n,r)),atom.config.get("atom-typescript").tooltipDelay)))}},this.subscriptions.add(atom.workspace.observeTextEditors((t=>{const e=atom.views.getView(t),n=e.querySelector(".lines");this.editorMap.set(t,{rawView:e,lines:n});const r=new h.CompositeDisposable;r.add(ec(e,"mousemove",".scroll-view",this.trackMouseMovement(t)),ec(e,"mouseout",".scroll-view",this.clearExprTypeTimeout),ec(e,"keydown",".scroll-view",this.clearExprTypeTimeout),e.onDidChangeScrollTop(this.clearExprTypeTimeout),e.onDidChangeScrollLeft(this.clearExprTypeTimeout),t.onDidDestroy((()=>{r.dispose(),this.subscriptions.remove(r),this.clearExprTypeTimeout()}))),this.subscriptions.add(r)})))}dispose(){this.subscriptions.dispose(),this.clearExprTypeTimeout()}showExpressionAt(t){const e=t.getLastCursor().getBufferPosition(),n=atom.views.getView(t);let r;try{r=n.pixelPositionForBufferPosition(e)}catch(t){return void console.warn(t)}this.showExpressionType(t,this.mousePositionForPixelPosition(t,r),e)}mousePositionForPixelPosition(t,e){const n=atom.views.getView(t).querySelector(".lines").getBoundingClientRect();return{clientY:e.top+n.top+t.getLineHeightInPixels()/2,clientX:e.left+n.left}}showExpressionType(t,e,n){this.pendingTooltip&&this.pendingTooltip.dispose(),this.pendingTooltip=new rc(this.getClient,t,e,n)}hideExpressionType(){this.pendingTooltip&&(this.pendingTooltip.dispose(),this.pendingTooltip=void 0)}}class oc{constructor(t){this.getClient=t,this.subscriptions=new d;const e=atom.workspace.paneForURI("atom-typescript://semantic-view");e&&(this.view=e.itemForURI("atom-typescript://semantic-view")),this.view&&Kt(this.view.setGetClient(this.getClient)),this.subscriptions.add(new v((()=>{this.view&&(atom.workspace.hide(this.view),Kt(this.view.destroy()))})),atom.config.observe("atom-typescript.showSemanticView",(t=>{t?Kt(this.show()):this.hide()})))}dispose(){this.subscriptions.dispose()}async toggle(){this.view?await atom.workspace.toggle(this.view):await this.show()}async show(){this.view||(this.view=_e.create({navTree:null}),await this.view.setGetClient(this.getClient)),await atom.workspace.open(this.view,{searchAllPanes:!0})}hide(){return!!this.view&&atom.workspace.hide(this.view)}}class sc{constructor(t){this.position=t.position,this.name=t.name,this.type=t.type,this.parent=t.parent,this.file=t.file}static fromNavTree(t,e){const n=t.spans[0].start;return new sc({name:t.text,type:t.kind,position:{row:n.line-1,column:n.offset-1},parent:null!=e?e:null})}static fromNavto(t,e){const n=t.start;return new sc({name:t.name,type:t.kind,position:{row:n.line-1,column:n.offset-1},parent:null!=e?e:null,file:t.file})}}async function ac(t,e){const n=await async function(t,e){try{const n=await e.getClient(t);return(await n.execute("navtree",{file:t})).body}catch(e){console.error(t,e)}}(t,e);return n&&n.childItems?Array.from(uc(n.childItems)):[]}async function cc(t,e,n){const r=await async function(t,e,n){try{const r=await n.getClient(t);return(await r.execute("navto",{file:t,currentFileOnly:!1,searchValue:e,maxResultCount:1e3})).body}catch(e){console.error(t,e)}}(t,e,n);return r?Array.from(function*(t,e){for(const n of t)yield sc.fromNavto(n,e)}(r)):[]}function*uc(t,e){t.sort(((t,e)=>t.spans[0].start.line-e.spans[0].start.line));for(const n of t){const t=sc.fromNavTree(n,e);yield t,n.childItems&&(yield*uc(n.childItems,t))}}async function lc(t,e,n){if(void 0!==t.file)return n(e,{file:t.file,start:{line:t.position.row+1,offset:t.position.column+1}})}async function fc(t,e){const n=t.getPath();if(void 0!==n){let r;atom.config.get("symbols-view.quickJumpToFileSymbol")&&(r=function(t){const e=atom.views.getView(t).getScrollTop();return{bufferRanges:t.getSelectedBufferRanges(),scrollTop:e}}(t));const i=await xr({items:ac(n,e),itemTemplate:({name:t,position:e},n)=>ft.dom("li",{className:"two-lines"},ft.dom("div",{className:"primary-line"},ft.dom(hr,{label:t,query:n.getFilterQuery()})),ft.dom("div",{className:"secondary-line"},"Line "+(e.row+1))),didChangeSelection(e){atom.config.get("symbols-view.quickJumpToFileSymbol")&&e&&t.setCursorBufferPosition(e.position)},itemFilterKey:"name"});i?await lc(i,t,e.histGoForward):r&&function(t,{bufferRanges:e,scrollTop:n}){const r=atom.views.getView(t);t.setSelectedBufferRanges(e),r.setScrollTop(n)}(t,r)}}class pc{constructor(t){this.deps=t}toggleFileView(t){Kt(fc(t,this.deps))}toggleProjectView(t){Kt(async function(t,e){const n=t.getPath();if(void 0!==n){const r=await xr({items:t=>cc(n,t,e),itemTemplate({name:t,position:e,file:n},r){const i=atom.project.relativize(n);return ft.dom("li",{className:"two-lines"},ft.dom("div",{className:"primary-line"},ft.dom(hr,{label:t,query:r.getFilterQuery()})),ft.dom("div",{className:"secondary-line"},`File ${i} line ${e.row+1}`))},itemFilterKey:"name"});r&&await lc(r,t,e.histGoForward)}}(t,this.deps))}dispose(){}}class hc{constructor(){this.errors=new Map,this.fileGrammars=new Map,this.pushErrors=Qt.debounce(this.pushErrors.bind(this),100)}*getErrorsInRange(t,e){for(const n of this.errors.values()){const r=n.get(w.normalize(t));r&&(yield*r.filter((t=>Xt(t).intersectsWith(e))))}}*getErrorsAt(t,e){for(const n of this.errors.values()){const r=n.get(w.normalize(t));r&&(yield*r.filter((t=>Xt(t).containsPoint(e))))}}setErrors(t,e,n){let r=this.errors.get(t);r||(r=new Map,this.errors.set(t,r)),r.set(w.normalize(e),n),this.pushErrors()}clearFileErrors(t){for(const e of this.errors.values())e.delete(t);this.pushErrors()}clear(){this.linter&&this.linter.clearMessages()}setLinter(t){this.linter=t,this.pushErrors()}dispose(){this.clear(),this.linter&&this.linter.dispose(),this.linter=void 0}pushErrors(){this.linter&&this.linter.setAllMessages(this.getLinterErrors())}getLinterErrors(){if(atom.config.get("atom-typescript.suppressAllDiagnostics"))return[];const t=[];for(const e of this.errors.values())for(const[n,r]of e){const e=atom.workspace.getTextEditors().find((t=>t.getPath()===n)),i=e?e.getGrammar().scopeName:this.selectGrammar(n);if(!dc("suppressAllDiagnostics",i))for(const e of r){if(dc("ignoredDiagnosticCodes",i).includes(""+e.code))continue;if(dc("ignoreUnusedSuggestionDiagnostics",i)&&e.reportsUnnecessary)continue;if("suggestion"===e.category&&dc("ignoredSuggestionDiagnostics",i).includes(""+e.code))continue;if(dc("ignoreNonSuggestionSuggestionDiagnostics",i)&&"suggestion"===e.category&&!se(e.code,Zt.Suggestion))continue;let{start:r,end:o}=e;r&&o||(r=o={line:1,offset:1}),t.push({severity:this.getSeverity(dc("unusedAsInfo",i),e),excerpt:e.text,location:{file:n,position:te(r,o)}})}}return t}selectGrammar(t){const e=this.fileGrammars.get(t);if(void 0!==e)return e;const n=atom.grammars.selectGrammar(t,"").scopeName;return this.fileGrammars.set(t,n),n}getSeverity(t,e){if(t&&6133===e.code)return"info";switch(e.category){case"error":return"error";case"warning":return"warning";default:return"info"}}}function dc(t,e){return atom.config.get("atom-typescript."+t,{scope:[e]})}class gc{constructor(t,e){let n;this.buffer=t,this.deps=e,this.events=new h.Emitter,this.compileOnSave=!1,this.subscriptions=new h.CompositeDisposable,this.on=this.events.on.bind(this.events),this.dispose=()=>{this.subscriptions.dispose(),Kt(this.close())},this.init=async()=>{this.state&&(await this.state.client.execute("open",{file:this.state.filePath,fileContent:this.buffer.getText()}),Kt(this.getErr({allFiles:!1,delay:0})))},this.close=async()=>{if(await this.openPromise,this.state){const t=this.state.client,e=this.state.filePath;this.deps.clearFileErrors(e),this.state.subscriptions.dispose(),this.state=void 0,await t.execute("close",{file:e})}},this.onDidChangePath=t=>{Kt(this.close().then((()=>{this.openPromise=this.open(t)})))},this.onDidSave=async()=>{await Promise.all([this.getErr({allFiles:!0,delay:100}),this.doCompileOnSave()])},this.onDidChangeText=async({changes:t})=>{if(0===t.length||!this.state)return;const{client:e,filePath:n}=this.state;await Promise.all(t.reduceRight(((t,{oldRange:r,newText:i})=>(t.push(e.execute("change",{file:n,line:r.start.row+1,offset:r.start.column+1,endLine:r.end.row+1,endOffset:r.end.column+1,insertString:i})),t)),[]))},this.subscriptions.add(atom.config.observe("atom-typescript.getErrDebounceTimeout",(t=>{n=Qt.debounce((()=>{Kt(this.getErr({allFiles:!1,delay:0}))}),t)})),t.onDidChangePath(this.onDidChangePath),t.onDidDestroy(this.dispose),t.onDidSave((()=>{Kt(this.onDidSave())})),t.onDidStopChanging((({changes:t})=>{t.length>0&&this.deps.reportBuildStatus(void 0)})),t.onDidChangeText((t=>{Kt(this.onDidChangeText(t)),n()}))),this.openPromise=this.open(this.buffer.getPath())}static create(t,e){const n=gc.bufferMap.get(t);if(n)return n;{const n=new gc(t,e);return gc.bufferMap.set(t,n),n}}getPath(){return this.state&&this.state.filePath}getInfo(){if(this.state)return{clientVersion:this.state.client.version,tsConfigPath:this.state.configFile&&this.state.configFile.getPath()}}async getErr(t){if(!this.state)return;const e=t.allFiles?Array.from(function*(){for(const t of atom.workspace.getTextEditors())ue(t)&&(yield t.getPath())}()):[this.state.filePath];await this.state.client.execute("geterr",{files:e,delay:t.delay})}async compile(){if(!this.state)return;const{client:t,filePath:e}=this.state,n=await t.execute("compileOnSaveAffectedFileList",{file:e}),r=Qt.flatten(n.body.map((t=>t.fileNames)));if(0===r.length)return;const i=r.map((e=>t.execute("compileOnSaveEmitFile",{file:e})));if(!(await Promise.all(i)).every((t=>!!t.body)))throw new Error("Some files failed to emit")}async doCompileOnSave(){if(this.compileOnSave){this.deps.reportBuildStatus(void 0);try{await this.compile(),this.deps.reportBuildStatus({success:!0})}catch(t){const e=t;console.error("Save failed with error",e),this.deps.reportBuildStatus({success:!1,message:e.message})}}}async open(t){if(void 0===t||!ae(t))return this.close();{const e=await this.deps.getClient(t);this.state={client:e,filePath:t,configFile:void 0,subscriptions:new h.CompositeDisposable},this.state.subscriptions.add(e.on("restarted",(()=>Kt(this.init())))),await this.init();const n=await e.execute("projectInfo",{needFileNameList:!1,file:t});void 0!==n.body.configFileName&&(this.state.configFile=new h.File(n.body.configFileName),await this.readConfigFile(),this.state.subscriptions.add(this.state.configFile.onDidChange((()=>Kt(this.readConfigFile()))))),this.events.emit("opened")}}async readConfigFile(){if(!this.state||!this.state.configFile)return;const t=ee(this.state.configFile.getPath());this.compileOnSave=t.compileOnSave;const e=atom.config.get("atom-typescript");await this.state.client.execute("configure",{file:this.state.filePath,formatOptions:t.formatCodeOptions,preferences:{includeCompletionsWithInsertText:!0,includeCompletionsForModuleExports:e.includeCompletionsForModuleExports,quotePreference:e.quotePreference,importModuleSpecifierEnding:e.importModuleSpecifierEnding,importModuleSpecifierPreference:"auto"===e.importModuleSpecifierPreference?void 0:e.importModuleSpecifierPreference,...t.preferences}})}}gc.bufferMap=new WeakMap;class mc{constructor(t,e){this.editor=t,this.opts=e,this.subscriptions=new d,this.isTypescript=!1,this.destroy=()=>{atom.views.getView(this.editor).classList.remove("typescript-editor"),this.subscriptions.dispose()},this.didActivate=()=>{this.isTypescript&&this.reportInfo()},this.onOpened=()=>{atom.workspace.getActiveTextEditor()===this.editor&&this.reportInfo()},this.checkIfTypescript=()=>{this.isTypescript=ue(this.editor),this.isTypescript?atom.views.getView(this.editor).classList.add("typescript-editor"):atom.views.getView(this.editor).classList.remove("typescript-editor")},this.buffer=gc.create(t.getBuffer(),e),this.subscriptions.add(this.buffer.on("opened",this.onOpened)),this.checkIfTypescript(),this.subscriptions.add(t.onDidChangePath(this.checkIfTypescript),t.onDidChangeGrammar(this.checkIfTypescript),t.onDidDestroy(this.destroy),t.onDidSave((()=>{atom.config.get("atom-typescript.checkAllFilesOnSave")&&atom.commands.dispatch(atom.views.getView(t),"typescript:check-all-files")})))}static createFactory(t){return e=>{let n=mc.editorMap.get(e);return n||(n=new mc(e,t),mc.editorMap.set(e,n)),n}}static lookupPane(t){return mc.editorMap.get(t)}reportInfo(){const t=this.buffer.getInfo();t&&this.opts.reportClientInfo(t)}}mc.editorMap=new WeakMap;class vc{constructor(t){this.usingBuiltinTooltipManager=!0,this.usingBuiltinSigHelpManager=!0,this.pending=new Set,this.clearErrors=()=>{this.errorPusher.clear()},this.clearFileErrors=t=>{this.errorPusher.clearFileErrors(t)},this.getClient=async t=>this.clientResolver.get(t),this.killAllServers=()=>{Kt(this.clientResolver.restartAllServers())},this.withBuffer=async(t,e)=>{const n=w.normalize(t),r=atom.workspace.getTextEditors().find((t=>t.getPath()===n));if(r)return e(r.getBuffer());const i=await h.TextBuffer.load(n);try{return await e(i)}finally{i.isModified()&&await i.save(),i.destroy()}},this.reportBusyWhile=async(t,e)=>{if(this.busySignalService)return this.busySignalService.reportBusyWhile(t,e);{const n={title:t};try{return this.pending.add(n),this.drawPending(Array.from(this.pending)),await e()}finally{this.pending.delete(n),this.drawPending(Array.from(this.pending))}}},this.reportProgress=t=>{Kt(this.statusPanel.update({progress:t}))},this.reportBuildStatus=t=>{Kt(this.statusPanel.update({buildStatus:t}))},this.reportClientInfo=t=>{Kt(this.statusPanel.update(t))},this.applyEdits=async t=>{Promise.all(t.map((t=>this.withBuffer(t.fileName,(async e=>{e.transact((()=>{const n=t.textChanges.map((t=>({range:Xt(t),newText:t.newText}))).reverse().sort(((t,e)=>e.range.compare(t.range)));for(const t of n)e.setTextInRange(t.range,t.newText)}))})))))},this.showTooltipAt=async t=>{this.usingBuiltinTooltipManager?this.tooltipManager.showExpressionAt(t):await atom.commands.dispatch(atom.views.getView(t),"datatip:toggle")},this.showSigHelpAt=async t=>{this.usingBuiltinSigHelpManager?await this.sigHelpManager.showTooltipAt(t):await atom.commands.dispatch(atom.views.getView(t),"signature-help:show")},this.hideSigHelpAt=t=>!!this.usingBuiltinSigHelpManager&&this.sigHelpManager.hideTooltipAt(t),this.rotateSigHelp=(t,e)=>!!this.usingBuiltinSigHelpManager&&this.sigHelpManager.rotateSigHelp(t,e),this.histGoForward=(t,e)=>this.editorPosHist.goForward(t,e),this.drawPending=Qt.throttle((t=>Kt(this.statusPanel.update({pending:t}))),100,{leading:!1}),this.subscriptions=new d,this.clientResolver=new Un(this.reportBusyWhile),this.subscriptions.add(this.clientResolver),this.statusPanel=new Ga,this.subscriptions.add(this.statusPanel),this.errorPusher=new hc,this.subscriptions.add(this.errorPusher),this.codefixProvider=new Hr(this.clientResolver,this.errorPusher,this.applyEdits),this.subscriptions.add(this.codefixProvider),this.semanticViewController=new oc(this.getClient),this.subscriptions.add(this.semanticViewController),this.editorPosHist=new Ka(t&&t.editorPosHistState),this.subscriptions.add(this.editorPosHist),this.symbolsViewController=new pc({histGoForward:this.histGoForward,getClient:this.getClient}),this.subscriptions.add(this.symbolsViewController),this.tooltipManager=new ic(this.getClient),this.subscriptions.add(this.tooltipManager),this.sigHelpManager=new tc({getClient:this.getClient}),this.subscriptions.add(this.sigHelpManager),this.occurrenceManager=new Za(this.getClient),this.subscriptions.add(this.occurrenceManager),this.typescriptPaneFactory=mc.createFactory({clearFileErrors:this.clearFileErrors,getClient:this.getClient,reportBuildStatus:this.reportBuildStatus,reportClientInfo:this.reportClientInfo}),this.subscribeEditors(),this.subscriptions.add(Ha({getClient:this.getClient,applyEdits:this.applyEdits,clearErrors:this.clearErrors,killAllServers:this.killAllServers,reportProgress:this.reportProgress,reportBuildStatus:this.reportBuildStatus,toggleSemanticViewController:()=>{Kt(this.semanticViewController.toggle())},toggleFileSymbolsView:t=>{this.symbolsViewController.toggleFileView(t)},toggleProjectSymbolsView:t=>{this.symbolsViewController.toggleProjectView(t)},histGoForward:this.histGoForward,histGoBack:()=>this.editorPosHist.goBack(),histShowHistory:()=>this.editorPosHist.showHistory(),showTooltipAt:this.showTooltipAt,showSigHelpAt:this.showSigHelpAt,hideSigHelpAt:this.hideSigHelpAt,rotateSigHelp:this.rotateSigHelp}))}destroy(){this.subscriptions.dispose();for(const t of atom.workspace.getTextEditors()){const e=mc.lookupPane(t);e&&e.destroy()}}serialize(){return{version:"0.1",editorPosHistState:this.editorPosHist.serialize()}}consumeLinter(t){const e=t({name:"TypeScript"});this.errorPusher.setLinter(e),this.subscriptions.add(this.clientResolver.on("diagnostics",(({type:t,filePath:e,diagnostics:n})=>{this.errorPusher.setErrors(t,e,n)})))}consumeStatusBar(t){let e=100;for(const n of t.getRightTiles())"GRAMMAR-SELECTOR-STATUS"===atom.views.getView(n.getItem()).tagName&&(e=n.getPriority()-1);const n=t.addRightTile({item:this.statusPanel,priority:e}),r=new h.Disposable((()=>{n.destroy()}));return this.subscriptions.add(r),r}consumeDatatipService(t){if(atom.config.get("atom-typescript").preferBuiltinTooltips)return;const e=t.addProvider(new Kn(this.getClient));return this.subscriptions.add(e),this.tooltipManager.dispose(),this.usingBuiltinTooltipManager=!1,e}consumeSigHelpService(t){if(atom.config.get("atom-typescript").preferBuiltinSigHelp)return;const e=new Or(this.getClient),n=t(e);return this.subscriptions.add(n,e),this.sigHelpManager.dispose(),this.usingBuiltinSigHelpManager=!1,n}consumeBusySignal(t){if(atom.config.get("atom-typescript").preferBuiltinBusySignal)return;this.busySignalService=t;const e={dispose:()=>{this.busySignalService&&this.busySignalService.dispose(),this.busySignalService=void 0}};return this.subscriptions.add(e),e}provideAutocomplete(){return[new jr(this.getClient,this.applyEdits)]}provideIntentions(){return t=this.codefixProvider,{grammarScopes:["*"],getIntentions:async({bufferPosition:e,textEditor:n})=>(await t.runCodeFix(n,e)).map((e=>({priority:100,title:"description"in e?e.description:e.actionDescription,selected:()=>{Kt(t.applyFix(e))}})))};var t}provideIntentionsHighlight(){return t=this.codefixProvider,{grammarScopes:["*"],getIntentions:async({visibleRange:e,textEditor:n})=>(await t.getFixableRanges(n,e)).map((t=>({range:t,created:t=>{}})))};var t}provideCodeActions(){return t=this.codefixProvider,{grammarScopes:ce(),priority:0,getCodeActions:async(e,n)=>(await t.runCodeFix(e,n.start)).map((e=>({getTitle:async()=>"description"in e?e.description:e.actionDescription,dispose:()=>{},apply:async()=>{await t.applyFix(e)}})))};var t}provideHyperclick(){return t=this.getClient,e=this.histGoForward,{priority:0,providerName:"typescript-hyperclick-provider",wordRegExp:/([A-Za-z0-9_])+|['"`](\\.|[^'"`\\\\])*['"`]/g,async getSuggestionForWord(n,r,i){if(!ue(n))return;const o=n.getPath();return void 0!==o?{range:i,callback:async()=>{var r;const s={file:o,line:i.start.row+1,offset:i.start.column+1},a=await t(s.file),c=await a.execute("definition",s),u=c.body?c.body[0]:void 0;if(1===(null===(r=c.body)||void 0===r?void 0:r.length)&&(null==u?void 0:u.start.line)===s.line&&(null==u?void 0:u.start.offset)===s.offset){const t=await a.execute("references",s);await Er(t,n,e)}else await Cr(c,n,e)}}:void 0}};var t,e}provideReferences(){return t=this.getClient,{isEditorSupported:async t=>ue(t),async findReferences(e,n){const r=fe(e,n);if(!r)return;const i=await t(r.file),o=await i.execute("references",r);return o.body?{type:"data",baseUri:r.file,referencedSymbolName:o.body.symbolDisplayString,references:o.body.refs.map(Jn)}:void 0}};var t}provideOutlines(){return t=this.getClient,{name:"Atom-TypeScript",grammarScopes:ce(),priority:100,updateOnEdit:!0,async getOutline(e){const n=e.getPath();if(void 0===n)return;const r=await t(n),i=(await r.execute("navtree",{file:n})).body;return i?{outlineTrees:[Tr(i)]}:void 0}};var t}provideDefinitions(){var t;if(!atom.config.get("atom-typescript").disableAtomIdeDefinitions)return t=this.getClient,{name:"atom-typescript",priority:0,grammarScopes:ce(),wordRegExp:/([A-Za-z0-9_])+|['"`](\\.|[^'"`\\\\])*['"`]/g,async getDefinition(e,n){if(!ue(e))return;const r=fe(e,n);if(!r)return;const i=await t(r.file),o=await i.execute("definition",r);return o.body&&0!==o.body.length?{queryRange:void 0,definitions:o.body.map(Zn)}:void 0}}}provideCodeHighlight(){if(!atom.config.get("atom-typescript").preferBuiltinOccurrenceHighlight)return this.occurrenceManager.dispose(),$n(this.getClient)}subscribeEditors(){this.subscriptions.add(atom.workspace.observeTextEditors((t=>{this.typescriptPaneFactory(t)})),atom.workspace.onDidChangeActiveTextEditor((t=>{if(t&&ue(t)){Kt(this.statusPanel.show());const e=mc.lookupPane(t);e&&e.didActivate()}else Kt(this.statusPanel.hide())})))}}let yc;var wc=C(ft);exports.activate=function(t){wc.setScheduler(atom.views),yc=new vc(t),setImmediate((()=>Kt(async function(){["atom-ide-ui","linter","nuclide"].some((t=>atom.packages.isPackageLoaded(t)))||await A.install("atom-typescript",!0)}())))},exports.deactivate=function(){yc&&yc.destroy(),yc=void 0},exports.serialize=function(){return yc?yc.serialize():void 0},exports.deserializeSemanticView=function(t){return _e.create(t.data)},exports.consumeLinter=function(t){if(yc)return yc.consumeLinter(t)},exports.consumeStatusBar=function(t){if(yc)return yc.consumeStatusBar(t)},exports.consumeDatatipService=function(t){if(yc)return yc.consumeDatatipService(t)},exports.consumeSignatureHelp=function(t){if(yc)return yc.consumeSigHelpService(t)},exports.consumeBusySignal=function(t){if(yc)return yc.consumeBusySignal(t)},exports.provideAutocomplete=function(){if(yc)return yc.provideAutocomplete()},exports.provideIntentions=function(){if(yc)return yc.provideIntentions()},exports.provideIntentionsHighlight=function(){if(yc)return yc.provideIntentionsHighlight()},exports.provideCodeActions=function(){if(yc)return yc.provideCodeActions()},exports.provideHyperclick=function(){if(yc)return yc.provideHyperclick()},exports.provideReferences=function(){if(yc)return yc.provideReferences()},exports.provideOutlines=function(){if(yc)return yc.provideOutlines()},exports.provideDefinitions=function(){if(yc)return yc.provideDefinitions()},exports.provideCodeHighlight=function(){if(yc)return yc.provideCodeHighlight()}; +var Q=/["'&<>]/,Z=function(t){var e,n=""+t,r=Q.exec(n);if(!r)return n;var i="",o=0,s=0;for(o=r.index;o{const i={stdout:r.stdout?[]:null,stderr:r.stderr?[]:null};r.on("error",e),r.stdout&&r.stdout.on("data",(function(t){i.stdout.push(t),n.handleStdout&&n.handleStdout(t)})),r.stderr&&r.stderr.on("data",(function(t){i.stderr.push(t),n.handleStderr&&n.handleStderr(t)})),r.on("close",(e=>{let r=null;null!=i.stdout&&(r=null===n.encoding||"buffer"===n.encoding?Buffer.concat(i.stdout):i.stdout.join(""));let o=null;null!=i.stderr&&(o=null===n.encoding||"buffer"===n.encoding?Buffer.concat(i.stderr):i.stderr.join("")),t({exitCode:e,stdout:r,stderr:o})}))}));return n.handleChildProcess(r),i}(t,e,{...n,handleChildProcess(t){r=t}});return i.kill=function(t){return r.kill(t)},i}async function Y(t){if(G){const e=await async function(t){var e;const n=atom.packages.getLoadedPackage(t.name);return null==n?null:null!==(e=n.metadata.version)&&void 0!==e?e:null}(t);if(e)return e}return async function(t){var e,n;const{directory:r}=t;if(null==r)return null;let i=null;try{i=JSON.parse(await D.default.promises.readFile(F.default.join(r,"package.json"),"utf8"))}catch(t){return null}return null!==(e=null===(n=i)||void 0===n?void 0:n.version)&&void 0!==e?e:null}(t)}const X=G?async function(t){return atom.packages.resolvePackagePath(t)}:async function(t){var e;const n=F.default.join(null!==(e=process.env.ATOM_HOME)&&void 0!==e?e:F.default.join(N.default.homedir(),".atom"),"packages",t);try{return await D.default.promises.access(n,D.default.constants.R_OK),n}catch(t){return null}};function tt(t,e){if(!t)throw new Error(null!=e?e:"Invariant violation")}async function et(t){const e=await(G?async function(t){const e=atom.packages.getLoadedPackage(t),n=e&&e.metadata["package-deps"];return Array.isArray(n)?n:[]}(t):async function(t){let e=null;try{e=await D.default.promises.stat(t)}catch(t){}if(null==e||!e.isDirectory())throw new Error("[Package-Deps] Expected packageName to be a readable directory in Node.js invocation");let n=null;try{const e=await D.default.promises.readFile(F.default.join(t,"package.json"),"utf8");n=JSON.parse(e)}catch(t){}const r=null==n||"object"!=typeof n?[]:n["package-deps"];return Array.isArray(r)?r:[]}(t));return K&&(tt(Array.isArray(e),`Dependencies for ${t} are not a valid array`),e.forEach(((e,n)=>{if(Array.isArray(e))e.forEach(((e,r)=>{const i=`Dependency#${n}#${r} for ${t} is invalid`;tt("string"==typeof e.name&&e.name.length>0,i),tt(null==e.minimumVersion||"string"==typeof e.minimumVersion&&e.minimumVersion.length>0,i)})),tt(e.length>0,`Dependency#${n} for ${t} has no group items`);else{const r=`Dependency#${n} for ${t} is invalid`;tt("string"==typeof e.name&&e.name.length>0,r),tt(null==e.minimumVersion||"string"==typeof e.minimumVersion&&e.minimumVersion.length>0,r)}}))),e}async function nt(t){if(null==t.directory)return!0;if(null==t.minimumVersion)return!1;const e=await Y(t);return null==e||1===function(t,e){for(var n=t.split("."),r=e.split("."),i=0;i<3;i++){var o=Number(n[i]),s=Number(r[i]);if(o>s)return 1;if(s>o)return-1;if(!isNaN(o)&&isNaN(s))return 1;if(isNaN(o)&&!isNaN(s))return-1}return 0}(t.minimumVersion,e)}const rt=new Set(["✓","done"]),it=/(?:Installing|Moving) (.*?) to .* (.*)/;let ot=!0;const st=G?function({packageName:t,dependencies:e}){const n=[],r=atom.notifications.addInfo(`Installing ${t} dependencies`,{detail:"Installing "+e.map((t=>t.name)).join(", "),dismissable:!0}),i=document.createElement("progress");i.max=e.length,i.style.width="100%";try{var o;const t=atom.views.getView(r),e=null!==(o=null==t?void 0:t.element)&&void 0!==o?o:null;if(null==e)throw new Error("Unable to get notification element from view");const n=e.querySelector(".detail-content");if(null==n)throw new Error("Content detail container not found inside the notification");n.appendChild(i)}catch(t){console.error("[Package-Deps] Error during showing installation progress to user",t)}return{handleFailure({dependency:t,error:e}){var r;n.push(t.name),i.value+=1,console.error(`[Package-Deps] Unable to install ${t.name}, Error:`,null!==(r=null==e?void 0:e.stack)&&void 0!==r?r:e)},handleDependencyInstalled(t){i.value+=1},handleComplete(){r.dismiss(),n.length>0?atom.notifications.addWarning(`Failed to install ${t} dependencies`,{detail:"These packages were not installed, check your console\nfor more info.\n"+n.join("\n"),dismissable:!0}):atom.notifications.addSuccess(`Installed ${t} dependencies`,{detail:"Installed "+e.map((t=>t.name)).join(", ")}),Promise.all(e.map((t=>n.includes(t.name)?null:atom.packages.activatePackage(t.name)))).catch((e=>{console.error("[Package-Deps] Error activating installed packages for "+t,e)}))}}}:function({dependencies:t}){let e=!1;return console.log("Installing dependencies:\n"+t.map((t=>" - "+t.name)).join("\n")),{handleFailure({dependency:t,error:n}){var r;e=!0,console.error(`Unable to install ${t.name}, Error:`,null!==(r=null==n?void 0:n.stack)&&void 0!==r?r:n)},handleDependencyInstalled(t){console.log("Successfully installed",t.name)},handleComplete(){console.log("Installation complete"),e&&(process.exitCode=1)}}},at=G?function({packageName:t,dependencies:e}){return new Promise((n=>{const r=e.filter((t=>!Array.isArray(t))),i=e.filter((t=>Array.isArray(t))),o=0===i.length,s=o?r.map((t=>t.name)).join(", "):"Something went wrong. Check your developer console",a=i.map((t=>t[0]));atom.packages.isPackageDisabled("notifications")&&console.warn("Enable notifications to install dependencies for "+t);const c=atom.notifications.addInfo(t+" needs to install dependencies",{dismissable:!0,icon:"cloud-download",detail:s,description:`Install dependenc${1===e.length?"y":"ies"}?`,buttons:[{text:"Yes",onDidClick:()=>{n(o?[]:r.concat(a)),c.dismiss()}},{text:"No Thanks",onDidClick:()=>{c.dismiss()}},{text:"Never",onDidClick:()=>{!function(t){var e;if(!G)return;const n=new Set(null!==(e=atom.config.get("atom-package-deps.ignored"))&&void 0!==e?e:[]);n.add(t),atom.config.set("atom-package-deps.ignored",Array.from(n))}(t),ot&&(ot=!1,atom.notifications.addInfo("How to reset package-deps memory",{dismissable:!0,description:"To modify the list of ignored files invoke 'Application: Open Your Config' and change the 'atom-package-deps' section"})),c.dismiss()}}]});if(c.onDidDismiss((()=>n([]))),!o)try{var u;const t=atom.views.getView(c),e=null!==(u=null==t?void 0:t.element)&&void 0!==u?u:null;if(null==e)throw new Error("Unable to get notification element from view");const n=e.querySelector(".detail-content");if(null==n)throw new Error("Content detail container not found inside the notification");if(n.innerHTML="",r.length>0){const t=document.createElement("div");t.innerHTML=`Packages without choices:
  • ${r.map((t=>Z(t.name))).join("
  • ")}
`,n.appendChild(t)}const o=document.createElement("div");o.innerHTML="Packages with choices:",n.appendChild(o);const s=document.createElement("ul");i.forEach(((t,e)=>{const n=document.createElement("li"),r=document.createElement("select");r.innerHTML=t.map((t=>``)).join("\n"),r.addEventListener("change",(()=>{const n=t.find((t=>t.name===r.value));null!=n&&(a[e]=n)})),n.style.marginTop="5px",n.appendChild(r),s.appendChild(n)})),n.appendChild(s)}catch(t){console.error("[Package-Deps] Error during showing package choices to user",t)}}))}:async function({dependencies:t}){return t.map((t=>Array.isArray(t)?t[0]:t))};var ct=async function(t){if(tt("string"==typeof t&&t.length>0,"[Package-Deps] Package name is required"),e=t,G&&(null!==(n=atom.config.get("atom-package-deps.ignored"))&&void 0!==n?n:[]).includes(e))return;var e,n;const r=await et(t);if(0===r.length)return;const i=await Promise.all(r.map((async t=>Array.isArray(t)?Promise.all(t.map((async t=>({...t,directory:await X(t.name)})))):{...t,directory:await X(t.name)}))),o=await V(i,(async function(t){return Array.isArray(t)?(await Promise.all(t.map((t=>nt(t))))).every(Boolean):nt(t)}));if(0===o.length)return;const s=await at({packageName:t,dependencies:o});if(0===s.length)return;const a=st({packageName:t,dependencies:s});await(async(t,e,{concurrency:n=1/0,stopOnError:r=!0}={})=>new Promise(((i,o)=>{if("function"!=typeof e)throw new TypeError("Mapper function is required");if(!Number.isSafeInteger(n)&&n!==1/0||!(n>=1))throw new TypeError(`Expected \`concurrency\` to be an integer from 1 and up or \`Infinity\`, got \`${n}\` (${typeof n})`);const s=[],a=[],c=t[Symbol.iterator]();let u=!1,l=!1,f=0,p=0;const h=()=>{if(u)return;const t=c.next(),n=p;if(p++,t.done)return l=!0,void(0===f&&(r||0===a.length?i(s):o(new z(a))));f++,(async()=>{try{const r=await t.value;s[n]=await e(r,n),f--,h()}catch(t){r?(u=!0,o(t)):(a.push(t),f--,h())}})()};for(let t=0;tht(t,e,...n);for(const t of pt)ht[t]=(e,...n)=>ht(t,e,...n);ut=ht;var gt,mt={},vt={};vt=new Map([["accentHeight","accent-height"],["alignmentBaseline","alignment-baseline"],["arabicForm","arabic-form"],["baselineShift","baseline-shift"],["capHeight","cap-height"],["className","class"],["clipPath","clip-path"],["clipRule","clip-rule"],["colorInterpolation","color-interpolation"],["colorInterpolationFilters","color-interpolation-filters"],["colorProfile","color-profile"],["colorRendering","color-rendering"],["dominantBaseline","dominant-baseline"],["enableBackground","enable-background"],["fillOpacity","fill-opacity"],["fillRule","fill-rule"],["floodColor","flood-color"],["floodOpacity","flood-opacity"],["fontFamily","font-family"],["fontSize","font-size"],["fontSizeAdjust","font-size-adjust"],["fontStretch","font-stretch"],["fontStyle","font-style"],["fontVariant","font-variant"],["fontWeight","font-weight"],["glyphName","glyph-name"],["glyphOrientationHorizontal","glyph-orientation-horizontal"],["glyphOrientationVertical","glyph-orientation-vertical"],["horizAdvX","horiz-adv-x"],["horizOriginX","horiz-origin-x"],["letterSpacing","letter-spacing"],["lightingColor","lighting-color"],["markerEnd","marker-end"],["markerMid","marker-mid"],["markerStart","marker-start"],["overlinePosition","overline-position"],["overlineThickness","overline-thickness"],["panose1","panose-1"],["paintOrder","paint-order"],["pointerEvents","pointer-events"],["renderingIntent","rendering-intent"],["shapeRendering","shape-rendering"],["stopColor","stop-color"],["stopOpacity","stop-opacity"],["strikethroughPosition","strikethrough-position"],["strikethroughThickness","strikethrough-thickness"],["strokeDasharray","stroke-dasharray"],["strokeDashoffset","stroke-dashoffset"],["strokeLinecap","stroke-linecap"],["strokeLinejoin","stroke-linejoin"],["strokeMiterlimit","stroke-miterlimit"],["strokeOpacity","stroke-opacity"],["strokeWidth","stroke-width"],["textAnchor","text-anchor"],["textDecoration","text-decoration"],["textRendering","text-rendering"],["underlinePosition","underline-position"],["underlineThickness","underline-thickness"],["unicodeBidi","unicode-bidi"],["unicodeRange","unicode-range"],["unitsPerEm","units-per-em"],["vAlphabetic","v-alphabetic"],["vHanging","v-hanging"],["vIdeographic","v-ideographic"],["vMathematical","v-mathematical"],["vertAdvY","vert-adv-y"],["vertOriginX","vert-origin-x"],["vertOriginY","vert-origin-y"],["wordSpacing","word-spacing"],["writingMode","writing-mode"],["xHeight","x-height"]]);var yt;function wt(t,e,n,r,i){if(n)for(var o in n)"ref"!==o&&"on"!==o&&(o in lt||i&&o in i||("dataset"===o?wt(t.dataset,null,n&&n.dataset,null,null):"innerHTML"!==o&&e&&pt.has(e.tag)?t.removeAttribute(vt.get(o)||o):(t[o]="",delete t[o])));if(i)for(var o in i)if("ref"!==o&&"on"!==o&&!(o in lt)){var s=n&&n[o],a=i[o];"dataset"===o?bt(t.dataset,s,a,!1):"style"===o&&"string"!=typeof a?("string"==typeof s&&(t.style="",s=null),bt(t.style,s,a,!0)):"attributes"===o?_t(t,s,a):a!==s&&("innerHTML"!==o&&r&&pt.has(r.tag)?t.setAttribute(vt.get(o)||o,a):r&&"input"===r.tag&&"value"===o&&t[o]===a||(t[o]=a))}}function bt(t,e,n,r){if(e)for(var i in e)n&&i in n||(r?t[i]="":delete t[i]);if(n)for(var i in n){const r=e&&e[i],o=n[i];o!==r&&(t[i]=o)}}function _t(t,e,n){if(e)for(var r in e)n&&r in n||t.removeAttribute(r);if(n)for(var r in n){const i=e&&e[r],o=n[r];o!==i&&t.setAttribute(r,o)}}function xt(t,e){let n;if(null!=t.text)n=document.createTextNode(t.text);else{const{tag:r,children:i}=t;let{props:o,context:s}=t;if(s&&(e={refs:s.refs,listenerContext:s}),"function"==typeof r){let s;o&&o.ref&&(s=o.ref);const a=new r(o||{},i);t.component=a,n=a.element,"function"==typeof s?s(a):e&&e.refs&&s&&(e.refs[s]=a)}else pt.has(r)?(n=document.createElementNS("http://www.w3.org/2000/svg",r),i&&St(n,i,e),o&>(n,null,t,e)):(n=document.createElement(r),i&&St(n,i,e),o&>(n,null,t,e))}return t.domNode=n,n}function St(t,e,n){for(let r=0;r0?(i=Tt.pop()).clear():i=new Map,It(i,e,o,s));var h=Ot(f),d=h?i.get(h):null;if(null==d)t.insertBefore(mt(f,r),a.domNode),f=n[++u];else{var g=e[d];Ct(g,f,r),e[d]=void 0,t.insertBefore(g.domNode,a.domNode),f=n[++u]}}else c=e[--s];else a=e[++o];if(o>s){var m=n[l+1]?n[l+1].domNode:null;for(let e=u;e<=l;e++)t.insertBefore(mt(n[e],r),m)}else if(u>l)for(let t=o;t<=s;t++){var v=e[t];v&&At(v,r&&r.refs)}i&&Tt.push(i)}(r,t.children,e.children,n),gt(r,t,e,n),i=r),e.domNode=i,i!==r&&r.parentNode&&r.parentNode.replaceChild(i,r),i}{const i=r.parentNode,o=r.nextSibling;At(t,n&&n.refs);const s=mt(e,n);return i&&i.insertBefore(s,o),e.domNode=s,s}}let Tt=[new Map,new Map,new Map,new Map];function At(t,e,n=!0){const{domNode:r,props:i,children:o,component:s}=t,a=i&&i.ref;if(s)"function"==typeof a?a(null):e&&a&&e[a]===s&&delete e[a],s.destroy&&s.destroy();else if("function"==typeof a?a(null):e&&a&&e[a]===r&&delete e[a],o)for(let t=0;t{this.resolveNextUpdatePromise=t}))),this.nextUpdatePromise}performUpdates(){for(;this.updateRequests.length>0;)this.updateRequests.shift()();for(this.pendingAnimationFrame=null;this.readRequests.length>0;)this.readRequests.shift()();if(this.nextUpdatePromise){let t=this.resolveNextUpdatePromise;this.nextUpdatePromise=null,this.resolveNextUpdatePromise=null,t()}}};let Nt=null;var Dt=function(){return Nt||(Nt=new jt),Nt};const Ft=new WeakSet;let Lt=0,Mt=0;function Rt(t){return null!=t&&!1!==t}function Bt(t,e){e.context=t,e.ambiguous&&(e.ambiguous.forEach((e=>{e.context=t})),delete e.ambiguous)}function zt(t,e=!0){if(!Rt(t.virtualNode))throw new Error((t.constructor?t.constructor.name+" instance":t)+" is not associated with a valid virtualNode. Perhaps this component was never initialized?");if(null==t.element)throw new Error((t.constructor?t.constructor.name+" instance":t)+" is not associated with a DOM element. Perhaps this component was never initialized?");let n=t.render();if(!Rt(n)){const e=t.constructor&&t.constructor.name?" in "+t.constructor.name:"";throw new Error("invalid falsy value "+n+" returned from render()"+e)}Bt(t,n),Lt++;let r=t.virtualNode,i=t.element,o=Et(r,n,{refs:t.refs,listenerContext:t});if(t.virtualNode=n,o!==i&&!e)throw new Error("The root node type changed on update, but the update was performed with the replaceNode option set to false");t.element=o,"function"==typeof t.writeAfterUpdate&&t.writeAfterUpdate(),"function"==typeof t.readAfterUpdate&&Dt().readDocument((function(){t.readAfterUpdate()})),Lt--}function qt(t,e=!0){Mt++,Ht(t.virtualNode),1===Mt&&e&&t.element.remove(),Mt--}function Ht(t){t.component&&"function"==typeof t.component.destroy?t.component.destroy():t.children&&t.children.forEach(Ht)}kt={initialize:function(t){if("function"!=typeof t.update)throw new Error("Etch components must implement `update(props, children)`.");let e=t.render();if(!Rt(e)){let n=t.constructor&&t.constructor.name?" in "+t.constructor.name:"";throw new Error("invalid falsy value "+e+" returned from render()"+n)}Bt(t,e),t.refs={},t.virtualNode=e,t.element=mt(t.virtualNode,{refs:t.refs,listenerContext:t})},update:function(t,e=!0){if(Lt>0)return zt(t,e),Promise.resolve();let n=Dt();return Ft.has(t)||(Ft.add(t),n.updateDocument((function(){Ft.delete(t),zt(t,e)}))),n.getNextUpdatePromise()},updateSync:zt,destroy:function(t,e=!0){if(Lt>0||Mt>0)return qt(t,e),Promise.resolve();let n=Dt();return n.updateDocument((function(){qt(t,e)})),n.getNextUpdatePromise()},destroySync:qt};const{initialize:Ut,update:$t,updateSync:Vt,destroy:Wt,destroySync:Gt}=kt;function Kt(t){void 0!==t&&("function"==typeof t.catch?t.catch((t=>{atom.notifications.addFatalError("Atom-Typescript error: "+t.message,{detail:t.toString(),stack:t.stack,dismissable:!0})})):atom.notifications.addFatalError("Atom-Typescript: non-promise passed to handlePromise. Please report this.",{stack:(new Error).stack,dismissable:!0}))}ft={dom:ut,render:mt,initialize:Ut,update:$t,updateSync:Vt,destroy:Wt,destroySync:Gt,setScheduler:function(t){Nt=t},getScheduler:Dt};var Qt=function(){var t=this,e={exports:this};return function(){var n,r="Expected a function",i="__lodash_hash_undefined__",o="__lodash_placeholder__",s=16,a=32,c=64,u=128,l=256,f=1/0,p=9007199254740991,h=NaN,d=4294967295,g=[["ary",u],["bind",1],["bindKey",2],["curry",8],["curryRight",s],["flip",512],["partial",a],["partialRight",c],["rearg",l]],m="[object Arguments]",v="[object Array]",y="[object Boolean]",w="[object Date]",b="[object Error]",_="[object Function]",x="[object GeneratorFunction]",S="[object Map]",k="[object Number]",E="[object Object]",C="[object Promise]",A="[object RegExp]",P="[object Set]",O="[object String]",I="[object Symbol]",j="[object WeakMap]",N="[object ArrayBuffer]",D="[object DataView]",F="[object Float32Array]",L="[object Float64Array]",M="[object Int8Array]",R="[object Int16Array]",B="[object Int32Array]",z="[object Uint8Array]",q="[object Uint8ClampedArray]",H="[object Uint16Array]",U="[object Uint32Array]",$=/\b__p \+= '';/g,V=/\b(__p \+=) '' \+/g,W=/(__e\(.*?\)|\b__t\)) \+\n'';/g,G=/&(?:amp|lt|gt|quot|#39);/g,K=/[&<>"']/g,Q=RegExp(G.source),Z=RegExp(K.source),J=/<%-([\s\S]+?)%>/g,Y=/<%([\s\S]+?)%>/g,X=/<%=([\s\S]+?)%>/g,tt=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,et=/^\w*$/,nt=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,rt=/[\\^$.*+?()[\]{}|]/g,it=RegExp(rt.source),ot=/^\s+/,st=/\s/,at=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,ct=/\{\n\/\* \[wrapped with (.+)\] \*/,ut=/,? & /,lt=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,ft=/[()=,{}\[\]\/\s]/,pt=/\\(\\)?/g,ht=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,dt=/\w*$/,gt=/^[-+]0x[0-9a-f]+$/i,mt=/^0b[01]+$/i,vt=/^\[object .+?Constructor\]$/,yt=/^0o[0-7]+$/i,wt=/^(?:0|[1-9]\d*)$/,bt=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,_t=/($^)/,xt=/['\n\r\u2028\u2029\\]/g,St="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",kt="\\u2700-\\u27bf",Et="a-z\\xdf-\\xf6\\xf8-\\xff",Ct="A-Z\\xc0-\\xd6\\xd8-\\xde",Tt="\\ufe0e\\ufe0f",At="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Pt="['’]",Ot="[\\ud800-\\udfff]",It="["+At+"]",jt="["+St+"]",Nt="\\d+",Dt="[\\u2700-\\u27bf]",Ft="["+Et+"]",Lt="[^\\ud800-\\udfff"+At+Nt+kt+Et+Ct+"]",Mt="\\ud83c[\\udffb-\\udfff]",Rt="[^\\ud800-\\udfff]",Bt="(?:\\ud83c[\\udde6-\\uddff]){2}",zt="[\\ud800-\\udbff][\\udc00-\\udfff]",qt="["+Ct+"]",Ht="(?:"+Ft+"|"+Lt+")",Ut="(?:"+qt+"|"+Lt+")",$t="(?:['’](?:d|ll|m|re|s|t|ve))?",Vt="(?:['’](?:D|LL|M|RE|S|T|VE))?",Wt="(?:"+jt+"|"+Mt+")"+"?",Gt="[\\ufe0e\\ufe0f]?",Kt=Gt+Wt+("(?:\\u200d(?:"+[Rt,Bt,zt].join("|")+")"+Gt+Wt+")*"),Qt="(?:"+[Dt,Bt,zt].join("|")+")"+Kt,Zt="(?:"+[Rt+jt+"?",jt,Bt,zt,Ot].join("|")+")",Jt=RegExp(Pt,"g"),Yt=RegExp(jt,"g"),Xt=RegExp(Mt+"(?="+Mt+")|"+Zt+Kt,"g"),te=RegExp([qt+"?"+Ft+"+"+$t+"(?="+[It,qt,"$"].join("|")+")",Ut+"+"+Vt+"(?="+[It,qt+Ht,"$"].join("|")+")",qt+"?"+Ht+"+"+$t,qt+"+"+Vt,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",Nt,Qt].join("|"),"g"),ee=RegExp("[\\u200d\\ud800-\\udfff"+St+Tt+"]"),ne=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,re=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],ie=-1,oe={};oe[F]=oe[L]=oe[M]=oe[R]=oe[B]=oe[z]=oe[q]=oe[H]=oe[U]=!0,oe[m]=oe[v]=oe[N]=oe[y]=oe[D]=oe[w]=oe[b]=oe[_]=oe[S]=oe[k]=oe[E]=oe[A]=oe[P]=oe[O]=oe[j]=!1;var se={};se[m]=se[v]=se[N]=se[D]=se[y]=se[w]=se[F]=se[L]=se[M]=se[R]=se[B]=se[S]=se[k]=se[E]=se[A]=se[P]=se[O]=se[I]=se[z]=se[q]=se[H]=se[U]=!0,se[b]=se[_]=se[j]=!1;var ae={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},ce=parseFloat,ue=parseInt,le="object"==typeof T&&T&&T.Object===Object&&T,fe="object"==typeof self&&self&&self.Object===Object&&self,pe=le||fe||Function("return this")(),he="object"==typeof t&&t&&!t.nodeType&&t,de=he&&"object"==typeof e&&e&&!e.nodeType&&e,ge=de&&de.exports===he,me=ge&&le.process,ve=function(){try{var t=de&&de.require&&de.require("util").types;return t||me&&me.binding&&me.binding("util")}catch(t){}}(),ye=ve&&ve.isArrayBuffer,we=ve&&ve.isDate,be=ve&&ve.isMap,_e=ve&&ve.isRegExp,xe=ve&&ve.isSet,Se=ve&&ve.isTypedArray;function ke(t,e,n){switch(n.length){case 0:return t.call(e);case 1:return t.call(e,n[0]);case 2:return t.call(e,n[0],n[1]);case 3:return t.call(e,n[0],n[1],n[2])}return t.apply(e,n)}function Ee(t,e,n,r){for(var i=-1,o=null==t?0:t.length;++i-1}function Ie(t,e,n){for(var r=-1,i=null==t?0:t.length;++r-1;);return n}function tn(t,e){for(var n=t.length;n--&&ze(e,t[n],0)>-1;);return n}function en(t,e){for(var n=t.length,r=0;n--;)t[n]===e&&++r;return r}var nn=Ve({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),rn=Ve({"&":"&","<":"<",">":">",'"':""","'":"'"});function on(t){return"\\"+ae[t]}function sn(t){return ee.test(t)}function an(t){var e=-1,n=Array(t.size);return t.forEach((function(t,r){n[++e]=[r,t]})),n}function cn(t,e){return function(n){return t(e(n))}}function un(t,e){for(var n=-1,r=t.length,i=0,s=[];++n",""":'"',"'":"'"});var mn=function t(e){var T,st=(e=null==e?pe:mn.defaults(pe.Object(),e,mn.pick(pe,re))).Array,St=e.Date,kt=e.Error,Et=e.Function,Ct=e.Math,Tt=e.Object,At=e.RegExp,Pt=e.String,Ot=e.TypeError,It=st.prototype,jt=Et.prototype,Nt=Tt.prototype,Dt=e["__core-js_shared__"],Ft=jt.toString,Lt=Nt.hasOwnProperty,Mt=0,Rt=(T=/[^.]+$/.exec(Dt&&Dt.keys&&Dt.keys.IE_PROTO||""))?"Symbol(src)_1."+T:"",Bt=Nt.toString,zt=Ft.call(Tt),qt=pe._,Ht=At("^"+Ft.call(Lt).replace(rt,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Ut=ge?e.Buffer:n,$t=e.Symbol,Vt=e.Uint8Array,Wt=Ut?Ut.allocUnsafe:n,Gt=cn(Tt.getPrototypeOf,Tt),Kt=Tt.create,Qt=Nt.propertyIsEnumerable,Zt=It.splice,Xt=$t?$t.isConcatSpreadable:n,ee=$t?$t.iterator:n,ae=$t?$t.toStringTag:n,le=function(){try{var t=ho(Tt,"defineProperty");return t({},"",{}),t}catch(t){}}(),fe=e.clearTimeout!==pe.clearTimeout&&e.clearTimeout,he=St&&St.now!==pe.Date.now&&St.now,de=e.setTimeout!==pe.setTimeout&&e.setTimeout,me=Ct.ceil,ve=Ct.floor,Me=Tt.getOwnPropertySymbols,Ve=Ut?Ut.isBuffer:n,vn=e.isFinite,yn=It.join,wn=cn(Tt.keys,Tt),bn=Ct.max,_n=Ct.min,xn=St.now,Sn=e.parseInt,kn=Ct.random,En=It.reverse,Cn=ho(e,"DataView"),Tn=ho(e,"Map"),An=ho(e,"Promise"),Pn=ho(e,"Set"),On=ho(e,"WeakMap"),In=ho(Tt,"create"),jn=On&&new On,Nn={},Dn=qo(Cn),Fn=qo(Tn),Ln=qo(An),Mn=qo(Pn),Rn=qo(On),Bn=$t?$t.prototype:n,zn=Bn?Bn.valueOf:n,qn=Bn?Bn.toString:n;function Hn(t){if(ia(t)&&!Gs(t)&&!(t instanceof Wn)){if(t instanceof Vn)return t;if(Lt.call(t,"__wrapped__"))return Ho(t)}return new Vn(t)}var Un=function(){function t(){}return function(e){if(!ra(e))return{};if(Kt)return Kt(e);t.prototype=e;var r=new t;return t.prototype=n,r}}();function $n(){}function Vn(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=n}function Wn(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=d,this.__views__=[]}function Gn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e=e?t:e)),t}function lr(t,e,r,i,o,s){var a,c=1&e,u=2&e,l=4&e;if(r&&(a=o?r(t,i,o,s):r(t)),a!==n)return a;if(!ra(t))return t;var f=Gs(t);if(f){if(a=function(t){var e=t.length,n=new t.constructor(e);e&&"string"==typeof t[0]&&Lt.call(t,"index")&&(n.index=t.index,n.input=t.input);return n}(t),!c)return Ii(t,a)}else{var p=vo(t),h=p==_||p==x;if(Js(t))return Ei(t,c);if(p==E||p==m||h&&!o){if(a=u||h?{}:wo(t),!c)return u?function(t,e){return ji(t,mo(t),e)}(t,function(t,e){return t&&ji(e,Fa(e),t)}(a,t)):function(t,e){return ji(t,go(t),e)}(t,sr(a,t))}else{if(!se[p])return o?t:{};a=function(t,e,n){var r=t.constructor;switch(e){case N:return Ci(t);case y:case w:return new r(+t);case D:return function(t,e){var n=e?Ci(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}(t,n);case F:case L:case M:case R:case B:case z:case q:case H:case U:return Ti(t,n);case S:return new r;case k:case O:return new r(t);case A:return function(t){var e=new t.constructor(t.source,dt.exec(t));return e.lastIndex=t.lastIndex,e}(t);case P:return new r;case I:return i=t,zn?Tt(zn.call(i)):{}}var i}(t,p,c)}}s||(s=new Jn);var d=s.get(t);if(d)return d;s.set(t,a),ua(t)?t.forEach((function(n){a.add(lr(n,e,r,n,t,s))})):oa(t)&&t.forEach((function(n,i){a.set(i,lr(n,e,r,i,t,s))}));var g=f?n:(l?u?so:oo:u?Fa:Da)(t);return Ce(g||t,(function(n,i){g&&(n=t[i=n]),rr(a,i,lr(n,e,r,i,t,s))})),a}function fr(t,e,r){var i=r.length;if(null==t)return!i;for(t=Tt(t);i--;){var o=r[i],s=e[o],a=t[o];if(a===n&&!(o in t)||!s(a))return!1}return!0}function pr(t,e,i){if("function"!=typeof t)throw new Ot(r);return Do((function(){t.apply(n,i)}),e)}function hr(t,e,n,r){var i=-1,o=Oe,s=!0,a=t.length,c=[],u=e.length;if(!a)return c;n&&(e=je(e,Ze(n))),r?(o=Ie,s=!1):e.length>=200&&(o=Ye,s=!1,e=new Zn(e));t:for(;++i-1},Kn.prototype.set=function(t,e){var n=this.__data__,r=ir(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this},Qn.prototype.clear=function(){this.size=0,this.__data__={hash:new Gn,map:new(Tn||Kn),string:new Gn}},Qn.prototype.delete=function(t){var e=fo(this,t).delete(t);return this.size-=e?1:0,e},Qn.prototype.get=function(t){return fo(this,t).get(t)},Qn.prototype.has=function(t){return fo(this,t).has(t)},Qn.prototype.set=function(t,e){var n=fo(this,t),r=n.size;return n.set(t,e),this.size+=n.size==r?0:1,this},Zn.prototype.add=Zn.prototype.push=function(t){return this.__data__.set(t,i),this},Zn.prototype.has=function(t){return this.__data__.has(t)},Jn.prototype.clear=function(){this.__data__=new Kn,this.size=0},Jn.prototype.delete=function(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n},Jn.prototype.get=function(t){return this.__data__.get(t)},Jn.prototype.has=function(t){return this.__data__.has(t)},Jn.prototype.set=function(t,e){var n=this.__data__;if(n instanceof Kn){var r=n.__data__;if(!Tn||r.length<199)return r.push([t,e]),this.size=++n.size,this;n=this.__data__=new Qn(r)}return n.set(t,e),this.size=n.size,this};var dr=Fi(xr),gr=Fi(Sr,!0);function mr(t,e){var n=!0;return dr(t,(function(t,r,i){return n=!!e(t,r,i)})),n}function vr(t,e,r){for(var i=-1,o=t.length;++i0&&n(a)?e>1?wr(a,e-1,n,r,i):Ne(i,a):r||(i[i.length]=a)}return i}var br=Li(),_r=Li(!0);function xr(t,e){return t&&br(t,e,Da)}function Sr(t,e){return t&&_r(t,e,Da)}function kr(t,e){return Pe(e,(function(e){return ta(t[e])}))}function Er(t,e){for(var r=0,i=(e=_i(e,t)).length;null!=t&&re}function Pr(t,e){return null!=t&&Lt.call(t,e)}function Or(t,e){return null!=t&&e in Tt(t)}function Ir(t,e,r){for(var i=r?Ie:Oe,o=t[0].length,s=t.length,a=s,c=st(s),u=1/0,l=[];a--;){var f=t[a];a&&e&&(f=je(f,Ze(e))),u=_n(f.length,u),c[a]=!r&&(e||o>=120&&f.length>=120)?new Zn(a&&f):n}f=t[0];var p=-1,h=c[0];t:for(;++p=a?c:c*("desc"==n[r]?-1:1)}return t.index-e.index}(t,e,n)}))}function Gr(t,e,n){for(var r=-1,i=e.length,o={};++r-1;)a!==t&&Zt.call(a,c,1),Zt.call(t,c,1);return t}function Qr(t,e){for(var n=t?e.length:0,r=n-1;n--;){var i=e[n];if(n==r||i!==o){var o=i;_o(i)?Zt.call(t,i,1):hi(t,i)}}return t}function Zr(t,e){return t+ve(kn()*(e-t+1))}function Jr(t,e){var n="";if(!t||e<1||e>p)return n;do{e%2&&(n+=t),(e=ve(e/2))&&(t+=t)}while(e);return n}function Yr(t,e){return Fo(Po(t,e,sc),t+"")}function Xr(t){return Xn(Ua(t))}function ti(t,e){var n=Ua(t);return Ro(n,ur(e,0,n.length))}function ei(t,e,r,i){if(!ra(t))return t;for(var o=-1,s=(e=_i(e,t)).length,a=s-1,c=t;null!=c&&++oi?0:i+e),(n=n>i?i:n)<0&&(n+=i),i=e>n?0:n-e>>>0,e>>>=0;for(var o=st(i);++r>>1,s=t[o];null!==s&&!fa(s)&&(n?s<=e:s=200){var u=e?null:Ji(t);if(u)return ln(u);s=!1,i=Ye,c=new Zn}else c=e?[]:a;t:for(;++r=i?t:oi(t,e,r)}var ki=fe||function(t){return pe.clearTimeout(t)};function Ei(t,e){if(e)return t.slice();var n=t.length,r=Wt?Wt(n):new t.constructor(n);return t.copy(r),r}function Ci(t){var e=new t.constructor(t.byteLength);return new Vt(e).set(new Vt(t)),e}function Ti(t,e){var n=e?Ci(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function Ai(t,e){if(t!==e){var r=t!==n,i=null===t,o=t==t,s=fa(t),a=e!==n,c=null===e,u=e==e,l=fa(e);if(!c&&!l&&!s&&t>e||s&&a&&u&&!c&&!l||i&&a&&u||!r&&u||!o)return 1;if(!i&&!s&&!l&&t1?r[o-1]:n,a=o>2?r[2]:n;for(s=t.length>3&&"function"==typeof s?(o--,s):n,a&&xo(r[0],r[1],a)&&(s=o<3?n:s,o=1),e=Tt(e);++i-1?o[s?e[a]:a]:n}}function qi(t){return io((function(e){var i=e.length,o=i,s=Vn.prototype.thru;for(t&&e.reverse();o--;){var a=e[o];if("function"!=typeof a)throw new Ot(r);if(s&&!c&&"wrapper"==co(a))var c=new Vn([],!0)}for(o=c?o:i;++o1&&y.reverse(),p&&lc))return!1;var l=s.get(t),f=s.get(e);if(l&&f)return l==e&&f==t;var p=-1,h=!0,d=2&r?new Zn:n;for(s.set(t,e),s.set(e,t);++p-1&&t%1==0&&t1?"& ":"")+e[r],e=e.join(n>2?", ":" "),t.replace(at,"{\n/* [wrapped with "+e+"] */\n")}(r,function(t,e){return Ce(g,(function(n){var r="_."+n[0];e&n[1]&&!Oe(t,r)&&t.push(r)})),t.sort()}(function(t){var e=t.match(ct);return e?e[1].split(ut):[]}(r),n)))}function Mo(t){var e=0,r=0;return function(){var i=xn(),o=16-(i-r);if(r=i,o>0){if(++e>=800)return arguments[0]}else e=0;return t.apply(n,arguments)}}function Ro(t,e){var r=-1,i=t.length,o=i-1;for(e=e===n?i:e;++r1?t[e-1]:n;return r="function"==typeof r?(t.pop(),r):n,cs(t,r)}));function gs(t){var e=Hn(t);return e.__chain__=!0,e}function ms(t,e){return e(t)}var vs=io((function(t){var e=t.length,r=e?t[0]:0,i=this.__wrapped__,o=function(e){return cr(e,t)};return!(e>1||this.__actions__.length)&&i instanceof Wn&&_o(r)?((i=i.slice(r,+r+(e?1:0))).__actions__.push({func:ms,args:[o],thisArg:n}),new Vn(i,this.__chain__).thru((function(t){return e&&!t.length&&t.push(n),t}))):this.thru(o)}));var ys=Ni((function(t,e,n){Lt.call(t,n)?++t[n]:ar(t,n,1)}));var ws=zi(Wo),bs=zi(Go);function _s(t,e){return(Gs(t)?Ce:dr)(t,lo(e,3))}function xs(t,e){return(Gs(t)?Te:gr)(t,lo(e,3))}var Ss=Ni((function(t,e,n){Lt.call(t,n)?t[n].push(e):ar(t,n,[e])}));var ks=Yr((function(t,e,n){var r=-1,i="function"==typeof e,o=Qs(t)?st(t.length):[];return dr(t,(function(t){o[++r]=i?ke(e,t,n):jr(t,e,n)})),o})),Es=Ni((function(t,e,n){ar(t,n,e)}));function Cs(t,e){return(Gs(t)?je:qr)(t,lo(e,3))}var Ts=Ni((function(t,e,n){t[n?0:1].push(e)}),(function(){return[[],[]]}));var As=Yr((function(t,e){if(null==t)return[];var n=e.length;return n>1&&xo(t,e[0],e[1])?e=[]:n>2&&xo(e[0],e[1],e[2])&&(e=[e[0]]),Wr(t,wr(e,1),[])})),Ps=he||function(){return pe.Date.now()};function Os(t,e,r){return e=r?n:e,e=t&&null==e?t.length:e,Xi(t,u,n,n,n,n,e)}function Is(t,e){var i;if("function"!=typeof e)throw new Ot(r);return t=va(t),function(){return--t>0&&(i=e.apply(this,arguments)),t<=1&&(e=n),i}}var js=Yr((function(t,e,n){var r=1;if(n.length){var i=un(n,uo(js));r|=a}return Xi(t,r,e,n,i)})),Ns=Yr((function(t,e,n){var r=3;if(n.length){var i=un(n,uo(Ns));r|=a}return Xi(e,r,t,n,i)}));function Ds(t,e,i){var o,s,a,c,u,l,f=0,p=!1,h=!1,d=!0;if("function"!=typeof t)throw new Ot(r);function g(e){var r=o,i=s;return o=s=n,f=e,c=t.apply(i,r)}function m(t){return f=t,u=Do(y,e),p?g(t):c}function v(t){var r=t-l;return l===n||r>=e||r<0||h&&t-f>=a}function y(){var t=Ps();if(v(t))return w(t);u=Do(y,function(t){var n=e-(t-l);return h?_n(n,a-(t-f)):n}(t))}function w(t){return u=n,d&&o?g(t):(o=s=n,c)}function b(){var t=Ps(),r=v(t);if(o=arguments,s=this,l=t,r){if(u===n)return m(l);if(h)return ki(u),u=Do(y,e),g(l)}return u===n&&(u=Do(y,e)),c}return e=wa(e)||0,ra(i)&&(p=!!i.leading,a=(h="maxWait"in i)?bn(wa(i.maxWait)||0,e):a,d="trailing"in i?!!i.trailing:d),b.cancel=function(){u!==n&&ki(u),f=0,o=l=s=u=n},b.flush=function(){return u===n?c:w(Ps())},b}var Fs=Yr((function(t,e){return pr(t,1,e)})),Ls=Yr((function(t,e,n){return pr(t,wa(e)||0,n)}));function Ms(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new Ot(r);var n=function(){var r=arguments,i=e?e.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var s=t.apply(this,r);return n.cache=o.set(i,s)||o,s};return n.cache=new(Ms.Cache||Qn),n}function Rs(t){if("function"!=typeof t)throw new Ot(r);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}Ms.Cache=Qn;var Bs=xi((function(t,e){var n=(e=1==e.length&&Gs(e[0])?je(e[0],Ze(lo())):je(wr(e,1),Ze(lo()))).length;return Yr((function(r){for(var i=-1,o=_n(r.length,n);++i=e})),Ws=Nr(function(){return arguments}())?Nr:function(t){return ia(t)&&Lt.call(t,"callee")&&!Qt.call(t,"callee")},Gs=st.isArray,Ks=ye?Ze(ye):function(t){return ia(t)&&Tr(t)==N};function Qs(t){return null!=t&&na(t.length)&&!ta(t)}function Zs(t){return ia(t)&&Qs(t)}var Js=Ve||wc,Ys=we?Ze(we):function(t){return ia(t)&&Tr(t)==w};function Xs(t){if(!ia(t))return!1;var e=Tr(t);return e==b||"[object DOMException]"==e||"string"==typeof t.message&&"string"==typeof t.name&&!aa(t)}function ta(t){if(!ra(t))return!1;var e=Tr(t);return e==_||e==x||"[object AsyncFunction]"==e||"[object Proxy]"==e}function ea(t){return"number"==typeof t&&t==va(t)}function na(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=p}function ra(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function ia(t){return null!=t&&"object"==typeof t}var oa=be?Ze(be):function(t){return ia(t)&&vo(t)==S};function sa(t){return"number"==typeof t||ia(t)&&Tr(t)==k}function aa(t){if(!ia(t)||Tr(t)!=E)return!1;var e=Gt(t);if(null===e)return!0;var n=Lt.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&Ft.call(n)==zt}var ca=_e?Ze(_e):function(t){return ia(t)&&Tr(t)==A};var ua=xe?Ze(xe):function(t){return ia(t)&&vo(t)==P};function la(t){return"string"==typeof t||!Gs(t)&&ia(t)&&Tr(t)==O}function fa(t){return"symbol"==typeof t||ia(t)&&Tr(t)==I}var pa=Se?Ze(Se):function(t){return ia(t)&&na(t.length)&&!!oe[Tr(t)]};var ha=Ki(zr),da=Ki((function(t,e){return t<=e}));function ga(t){if(!t)return[];if(Qs(t))return la(t)?hn(t):Ii(t);if(ee&&t[ee])return function(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}(t[ee]());var e=vo(t);return(e==S?an:e==P?ln:Ua)(t)}function ma(t){return t?(t=wa(t))===f||t===-1/0?17976931348623157e292*(t<0?-1:1):t==t?t:0:0===t?t:0}function va(t){var e=ma(t),n=e%1;return e==e?n?e-n:e:0}function ya(t){return t?ur(va(t),0,d):0}function wa(t){if("number"==typeof t)return t;if(fa(t))return h;if(ra(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=ra(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=Qe(t);var n=mt.test(t);return n||yt.test(t)?ue(t.slice(2),n?2:8):gt.test(t)?h:+t}function ba(t){return ji(t,Fa(t))}function _a(t){return null==t?"":fi(t)}var xa=Di((function(t,e){if(Co(e)||Qs(e))ji(e,Da(e),t);else for(var n in e)Lt.call(e,n)&&rr(t,n,e[n])})),Sa=Di((function(t,e){ji(e,Fa(e),t)})),ka=Di((function(t,e,n,r){ji(e,Fa(e),t,r)})),Ea=Di((function(t,e,n,r){ji(e,Da(e),t,r)})),Ca=io(cr);var Ta=Yr((function(t,e){t=Tt(t);var r=-1,i=e.length,o=i>2?e[2]:n;for(o&&xo(e[0],e[1],o)&&(i=1);++r1),e})),ji(t,so(t),n),r&&(n=lr(n,7,no));for(var i=e.length;i--;)hi(n,e[i]);return n}));var Ba=io((function(t,e){return null==t?{}:function(t,e){return Gr(t,e,(function(e,n){return Oa(t,n)}))}(t,e)}));function za(t,e){if(null==t)return{};var n=je(so(t),(function(t){return[t]}));return e=lo(e),Gr(t,n,(function(t,n){return e(t,n[0])}))}var qa=Yi(Da),Ha=Yi(Fa);function Ua(t){return null==t?[]:Je(t,Da(t))}var $a=Ri((function(t,e,n){return e=e.toLowerCase(),t+(n?Va(e):e)}));function Va(t){return Xa(_a(t).toLowerCase())}function Wa(t){return(t=_a(t))&&t.replace(bt,nn).replace(Yt,"")}var Ga=Ri((function(t,e,n){return t+(n?"-":"")+e.toLowerCase()})),Ka=Ri((function(t,e,n){return t+(n?" ":"")+e.toLowerCase()})),Qa=Mi("toLowerCase");var Za=Ri((function(t,e,n){return t+(n?"_":"")+e.toLowerCase()}));var Ja=Ri((function(t,e,n){return t+(n?" ":"")+Xa(e)}));var Ya=Ri((function(t,e,n){return t+(n?" ":"")+e.toUpperCase()})),Xa=Mi("toUpperCase");function tc(t,e,r){return t=_a(t),(e=r?n:e)===n?function(t){return ne.test(t)}(t)?function(t){return t.match(te)||[]}(t):function(t){return t.match(lt)||[]}(t):t.match(e)||[]}var ec=Yr((function(t,e){try{return ke(t,n,e)}catch(t){return Xs(t)?t:new kt(t)}})),nc=io((function(t,e){return Ce(e,(function(e){e=zo(e),ar(t,e,js(t[e],t))})),t}));function rc(t){return function(){return t}}var ic=qi(),oc=qi(!0);function sc(t){return t}function ac(t){return Mr("function"==typeof t?t:lr(t,1))}var cc=Yr((function(t,e){return function(n){return jr(n,t,e)}})),uc=Yr((function(t,e){return function(n){return jr(t,n,e)}}));function lc(t,e,n){var r=Da(e),i=kr(e,r);null!=n||ra(e)&&(i.length||!r.length)||(n=e,e=t,t=this,i=kr(e,Da(e)));var o=!(ra(n)&&"chain"in n&&!n.chain),s=ta(t);return Ce(i,(function(n){var r=e[n];t[n]=r,s&&(t.prototype[n]=function(){var e=this.__chain__;if(o||e){var n=t(this.__wrapped__),i=n.__actions__=Ii(this.__actions__);return i.push({func:r,args:arguments,thisArg:t}),n.__chain__=e,n}return r.apply(t,Ne([this.value()],arguments))})})),t}function fc(){}var pc=Vi(je),hc=Vi(Ae),dc=Vi(Le);function gc(t){return So(t)?$e(zo(t)):function(t){return function(e){return Er(e,t)}}(t)}var mc=Gi(),vc=Gi(!0);function yc(){return[]}function wc(){return!1}var bc=$i((function(t,e){return t+e}),0),_c=Zi("ceil"),xc=$i((function(t,e){return t/e}),1),Sc=Zi("floor");var kc=$i((function(t,e){return t*e}),1),Ec=Zi("round"),Cc=$i((function(t,e){return t-e}),0);return Hn.after=function(t,e){if("function"!=typeof e)throw new Ot(r);return t=va(t),function(){if(--t<1)return e.apply(this,arguments)}},Hn.ary=Os,Hn.assign=xa,Hn.assignIn=Sa,Hn.assignInWith=ka,Hn.assignWith=Ea,Hn.at=Ca,Hn.before=Is,Hn.bind=js,Hn.bindAll=nc,Hn.bindKey=Ns,Hn.castArray=function(){if(!arguments.length)return[];var t=arguments[0];return Gs(t)?t:[t]},Hn.chain=gs,Hn.chunk=function(t,e,r){e=(r?xo(t,e,r):e===n)?1:bn(va(e),0);var i=null==t?0:t.length;if(!i||e<1)return[];for(var o=0,s=0,a=st(me(i/e));oo?0:o+r),(i=i===n||i>o?o:va(i))<0&&(i+=o),i=r>i?0:ya(i);r>>0)?(t=_a(t))&&("string"==typeof e||null!=e&&!ca(e))&&!(e=fi(e))&&sn(t)?Si(hn(t),0,r):t.split(e,r):[]},Hn.spread=function(t,e){if("function"!=typeof t)throw new Ot(r);return e=null==e?0:bn(va(e),0),Yr((function(n){var r=n[e],i=Si(n,0,e);return r&&Ne(i,r),ke(t,this,i)}))},Hn.tail=function(t){var e=null==t?0:t.length;return e?oi(t,1,e):[]},Hn.take=function(t,e,r){return t&&t.length?oi(t,0,(e=r||e===n?1:va(e))<0?0:e):[]},Hn.takeRight=function(t,e,r){var i=null==t?0:t.length;return i?oi(t,(e=i-(e=r||e===n?1:va(e)))<0?0:e,i):[]},Hn.takeRightWhile=function(t,e){return t&&t.length?gi(t,lo(e,3),!1,!0):[]},Hn.takeWhile=function(t,e){return t&&t.length?gi(t,lo(e,3)):[]},Hn.tap=function(t,e){return e(t),t},Hn.throttle=function(t,e,n){var i=!0,o=!0;if("function"!=typeof t)throw new Ot(r);return ra(n)&&(i="leading"in n?!!n.leading:i,o="trailing"in n?!!n.trailing:o),Ds(t,e,{leading:i,maxWait:e,trailing:o})},Hn.thru=ms,Hn.toArray=ga,Hn.toPairs=qa,Hn.toPairsIn=Ha,Hn.toPath=function(t){return Gs(t)?je(t,zo):fa(t)?[t]:Ii(Bo(_a(t)))},Hn.toPlainObject=ba,Hn.transform=function(t,e,n){var r=Gs(t),i=r||Js(t)||pa(t);if(e=lo(e,4),null==n){var o=t&&t.constructor;n=i?r?new o:[]:ra(t)&&ta(o)?Un(Gt(t)):{}}return(i?Ce:xr)(t,(function(t,r,i){return e(n,t,r,i)})),n},Hn.unary=function(t){return Os(t,1)},Hn.union=is,Hn.unionBy=os,Hn.unionWith=ss,Hn.uniq=function(t){return t&&t.length?pi(t):[]},Hn.uniqBy=function(t,e){return t&&t.length?pi(t,lo(e,2)):[]},Hn.uniqWith=function(t,e){return e="function"==typeof e?e:n,t&&t.length?pi(t,n,e):[]},Hn.unset=function(t,e){return null==t||hi(t,e)},Hn.unzip=as,Hn.unzipWith=cs,Hn.update=function(t,e,n){return null==t?t:di(t,e,bi(n))},Hn.updateWith=function(t,e,r,i){return i="function"==typeof i?i:n,null==t?t:di(t,e,bi(r),i)},Hn.values=Ua,Hn.valuesIn=function(t){return null==t?[]:Je(t,Fa(t))},Hn.without=us,Hn.words=tc,Hn.wrap=function(t,e){return zs(bi(e),t)},Hn.xor=ls,Hn.xorBy=fs,Hn.xorWith=ps,Hn.zip=hs,Hn.zipObject=function(t,e){return yi(t||[],e||[],rr)},Hn.zipObjectDeep=function(t,e){return yi(t||[],e||[],ei)},Hn.zipWith=ds,Hn.entries=qa,Hn.entriesIn=Ha,Hn.extend=Sa,Hn.extendWith=ka,lc(Hn,Hn),Hn.add=bc,Hn.attempt=ec,Hn.camelCase=$a,Hn.capitalize=Va,Hn.ceil=_c,Hn.clamp=function(t,e,r){return r===n&&(r=e,e=n),r!==n&&(r=(r=wa(r))==r?r:0),e!==n&&(e=(e=wa(e))==e?e:0),ur(wa(t),e,r)},Hn.clone=function(t){return lr(t,4)},Hn.cloneDeep=function(t){return lr(t,5)},Hn.cloneDeepWith=function(t,e){return lr(t,5,e="function"==typeof e?e:n)},Hn.cloneWith=function(t,e){return lr(t,4,e="function"==typeof e?e:n)},Hn.conformsTo=function(t,e){return null==e||fr(t,e,Da(e))},Hn.deburr=Wa,Hn.defaultTo=function(t,e){return null==t||t!=t?e:t},Hn.divide=xc,Hn.endsWith=function(t,e,r){t=_a(t),e=fi(e);var i=t.length,o=r=r===n?i:ur(va(r),0,i);return(r-=e.length)>=0&&t.slice(r,o)==e},Hn.eq=Us,Hn.escape=function(t){return(t=_a(t))&&Z.test(t)?t.replace(K,rn):t},Hn.escapeRegExp=function(t){return(t=_a(t))&&it.test(t)?t.replace(rt,"\\$&"):t},Hn.every=function(t,e,r){var i=Gs(t)?Ae:mr;return r&&xo(t,e,r)&&(e=n),i(t,lo(e,3))},Hn.find=ws,Hn.findIndex=Wo,Hn.findKey=function(t,e){return Re(t,lo(e,3),xr)},Hn.findLast=bs,Hn.findLastIndex=Go,Hn.findLastKey=function(t,e){return Re(t,lo(e,3),Sr)},Hn.floor=Sc,Hn.forEach=_s,Hn.forEachRight=xs,Hn.forIn=function(t,e){return null==t?t:br(t,lo(e,3),Fa)},Hn.forInRight=function(t,e){return null==t?t:_r(t,lo(e,3),Fa)},Hn.forOwn=function(t,e){return t&&xr(t,lo(e,3))},Hn.forOwnRight=function(t,e){return t&&Sr(t,lo(e,3))},Hn.get=Pa,Hn.gt=$s,Hn.gte=Vs,Hn.has=function(t,e){return null!=t&&yo(t,e,Pr)},Hn.hasIn=Oa,Hn.head=Qo,Hn.identity=sc,Hn.includes=function(t,e,n,r){t=Qs(t)?t:Ua(t),n=n&&!r?va(n):0;var i=t.length;return n<0&&(n=bn(i+n,0)),la(t)?n<=i&&t.indexOf(e,n)>-1:!!i&&ze(t,e,n)>-1},Hn.indexOf=function(t,e,n){var r=null==t?0:t.length;if(!r)return-1;var i=null==n?0:va(n);return i<0&&(i=bn(r+i,0)),ze(t,e,i)},Hn.inRange=function(t,e,r){return e=ma(e),r===n?(r=e,e=0):r=ma(r),function(t,e,n){return t>=_n(e,n)&&t=-9007199254740991&&t<=p},Hn.isSet=ua,Hn.isString=la,Hn.isSymbol=fa,Hn.isTypedArray=pa,Hn.isUndefined=function(t){return t===n},Hn.isWeakMap=function(t){return ia(t)&&vo(t)==j},Hn.isWeakSet=function(t){return ia(t)&&"[object WeakSet]"==Tr(t)},Hn.join=function(t,e){return null==t?"":yn.call(t,e)},Hn.kebabCase=Ga,Hn.last=Xo,Hn.lastIndexOf=function(t,e,r){var i=null==t?0:t.length;if(!i)return-1;var o=i;return r!==n&&(o=(o=va(r))<0?bn(i+o,0):_n(o,i-1)),e==e?function(t,e,n){for(var r=n+1;r--;)if(t[r]===e)return r;return r}(t,e,o):Be(t,He,o,!0)},Hn.lowerCase=Ka,Hn.lowerFirst=Qa,Hn.lt=ha,Hn.lte=da,Hn.max=function(t){return t&&t.length?vr(t,sc,Ar):n},Hn.maxBy=function(t,e){return t&&t.length?vr(t,lo(e,2),Ar):n},Hn.mean=function(t){return Ue(t,sc)},Hn.meanBy=function(t,e){return Ue(t,lo(e,2))},Hn.min=function(t){return t&&t.length?vr(t,sc,zr):n},Hn.minBy=function(t,e){return t&&t.length?vr(t,lo(e,2),zr):n},Hn.stubArray=yc,Hn.stubFalse=wc,Hn.stubObject=function(){return{}},Hn.stubString=function(){return""},Hn.stubTrue=function(){return!0},Hn.multiply=kc,Hn.nth=function(t,e){return t&&t.length?Vr(t,va(e)):n},Hn.noConflict=function(){return pe._===this&&(pe._=qt),this},Hn.noop=fc,Hn.now=Ps,Hn.pad=function(t,e,n){t=_a(t);var r=(e=va(e))?pn(t):0;if(!e||r>=e)return t;var i=(e-r)/2;return Wi(ve(i),n)+t+Wi(me(i),n)},Hn.padEnd=function(t,e,n){t=_a(t);var r=(e=va(e))?pn(t):0;return e&&re){var i=t;t=e,e=i}if(r||t%1||e%1){var o=kn();return _n(t+o*(e-t+ce("1e-"+((o+"").length-1))),e)}return Zr(t,e)},Hn.reduce=function(t,e,n){var r=Gs(t)?De:We,i=arguments.length<3;return r(t,lo(e,4),n,i,dr)},Hn.reduceRight=function(t,e,n){var r=Gs(t)?Fe:We,i=arguments.length<3;return r(t,lo(e,4),n,i,gr)},Hn.repeat=function(t,e,r){return e=(r?xo(t,e,r):e===n)?1:va(e),Jr(_a(t),e)},Hn.replace=function(){var t=arguments,e=_a(t[0]);return t.length<3?e:e.replace(t[1],t[2])},Hn.result=function(t,e,r){var i=-1,o=(e=_i(e,t)).length;for(o||(o=1,t=n);++ip)return[];var n=d,r=_n(t,d);e=lo(e),t-=d;for(var i=Ke(r,e);++n=s)return t;var c=r-pn(i);if(c<1)return i;var u=a?Si(a,0,c).join(""):t.slice(0,c);if(o===n)return u+i;if(a&&(c+=u.length-c),ca(o)){if(t.slice(c).search(o)){var l,f=u;for(o.global||(o=At(o.source,_a(dt.exec(o))+"g")),o.lastIndex=0;l=o.exec(f);)var p=l.index;u=u.slice(0,p===n?c:p)}}else if(t.indexOf(fi(o),c)!=c){var h=u.lastIndexOf(o);h>-1&&(u=u.slice(0,h))}return u+i},Hn.unescape=function(t){return(t=_a(t))&&Q.test(t)?t.replace(G,gn):t},Hn.uniqueId=function(t){var e=++Mt;return _a(t)+e},Hn.upperCase=Ya,Hn.upperFirst=Xa,Hn.each=_s,Hn.eachRight=xs,Hn.first=Qo,lc(Hn,function(){var t={};return xr(Hn,(function(e,n){Lt.call(Hn.prototype,n)||(t[n]=e)})),t}(),{chain:!1}),Hn.VERSION="4.17.21",Ce(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(t){Hn[t].placeholder=Hn})),Ce(["drop","take"],(function(t,e){Wn.prototype[t]=function(r){r=r===n?1:bn(va(r),0);var i=this.__filtered__&&!e?new Wn(this):this.clone();return i.__filtered__?i.__takeCount__=_n(r,i.__takeCount__):i.__views__.push({size:_n(r,d),type:t+(i.__dir__<0?"Right":"")}),i},Wn.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}})),Ce(["filter","map","takeWhile"],(function(t,e){var n=e+1,r=1==n||3==n;Wn.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:lo(t,3),type:n}),e.__filtered__=e.__filtered__||r,e}})),Ce(["head","last"],(function(t,e){var n="take"+(e?"Right":"");Wn.prototype[t]=function(){return this[n](1).value()[0]}})),Ce(["initial","tail"],(function(t,e){var n="drop"+(e?"":"Right");Wn.prototype[t]=function(){return this.__filtered__?new Wn(this):this[n](1)}})),Wn.prototype.compact=function(){return this.filter(sc)},Wn.prototype.find=function(t){return this.filter(t).head()},Wn.prototype.findLast=function(t){return this.reverse().find(t)},Wn.prototype.invokeMap=Yr((function(t,e){return"function"==typeof t?new Wn(this):this.map((function(n){return jr(n,t,e)}))})),Wn.prototype.reject=function(t){return this.filter(Rs(lo(t)))},Wn.prototype.slice=function(t,e){t=va(t);var r=this;return r.__filtered__&&(t>0||e<0)?new Wn(r):(t<0?r=r.takeRight(-t):t&&(r=r.drop(t)),e!==n&&(r=(e=va(e))<0?r.dropRight(-e):r.take(e-t)),r)},Wn.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},Wn.prototype.toArray=function(){return this.take(d)},xr(Wn.prototype,(function(t,e){var r=/^(?:filter|find|map|reject)|While$/.test(e),i=/^(?:head|last)$/.test(e),o=Hn[i?"take"+("last"==e?"Right":""):e],s=i||/^find/.test(e);o&&(Hn.prototype[e]=function(){var e=this.__wrapped__,a=i?[1]:arguments,c=e instanceof Wn,u=a[0],l=c||Gs(e),f=function(t){var e=o.apply(Hn,Ne([t],a));return i&&p?e[0]:e};l&&r&&"function"==typeof u&&1!=u.length&&(c=l=!1);var p=this.__chain__,h=!!this.__actions__.length,d=s&&!p,g=c&&!h;if(!s&&l){e=g?e:new Wn(this);var m=t.apply(e,a);return m.__actions__.push({func:ms,args:[f],thisArg:n}),new Vn(m,p)}return d&&g?t.apply(this,a):(m=this.thru(f),d?i?m.value()[0]:m.value():m)})})),Ce(["pop","push","shift","sort","splice","unshift"],(function(t){var e=It[t],n=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",r=/^(?:pop|shift)$/.test(t);Hn.prototype[t]=function(){var t=arguments;if(r&&!this.__chain__){var i=this.value();return e.apply(Gs(i)?i:[],t)}return this[n]((function(n){return e.apply(Gs(n)?n:[],t)}))}})),xr(Wn.prototype,(function(t,e){var n=Hn[e];if(n){var r=n.name+"";Lt.call(Nn,r)||(Nn[r]=[]),Nn[r].push({name:e,func:n})}})),Nn[Hi(n,2).name]=[{name:"wrapper",func:n}],Wn.prototype.clone=function(){var t=new Wn(this.__wrapped__);return t.__actions__=Ii(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Ii(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Ii(this.__views__),t},Wn.prototype.reverse=function(){if(this.__filtered__){var t=new Wn(this);t.__dir__=-1,t.__filtered__=!0}else(t=this.clone()).__dir__*=-1;return t},Wn.prototype.value=function(){var t=this.__wrapped__.value(),e=this.__dir__,n=Gs(t),r=e<0,i=n?t.length:0,o=function(t,e,n){var r=-1,i=n.length;for(;++r=this.__values__.length;return{done:t,value:t?n:this.__values__[this.__index__++]}},Hn.prototype.plant=function(t){for(var e,r=this;r instanceof $n;){var i=Ho(r);i.__index__=0,i.__values__=n,e?o.__wrapped__=i:e=i;var o=i;r=r.__wrapped__}return o.__wrapped__=t,e},Hn.prototype.reverse=function(){var t=this.__wrapped__;if(t instanceof Wn){var e=t;return this.__actions__.length&&(e=new Wn(this)),(e=e.reverse()).__actions__.push({func:ms,args:[rs],thisArg:n}),new Vn(e,this.__chain__)}return this.thru(rs)},Hn.prototype.toJSON=Hn.prototype.valueOf=Hn.prototype.value=function(){return mi(this.__wrapped__,this.__actions__)},Hn.prototype.first=Hn.prototype.head,ee&&(Hn.prototype[ee]=function(){return this}),Hn}();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(pe._=mn,define((function(){return mn}))):de?((de.exports=mn)._=mn,he._=mn):pe._=mn}.call(this),e.exports}.call({});const Zt=f.DiagnosticCategory;function Jt(t){return{line:t.row+1,offset:t.column+1}}function Yt(t){return new h.Point(t.line-1,t.offset-1)}function Xt(t){return te(t.start,t.end)}function te(t,e){return new h.Range(Yt(t),Yt(e))}function ee(t){const e=ne(t),n=e.formatCodeOptions;return{formatCodeOptions:{indentSize:atom.config.get("editor.tabLength"),tabSize:atom.config.get("editor.tabLength"),...n},compileOnSave:!!e.compileOnSave,preferences:e.preferences?e.preferences:{}}}function ne(t){".json"!==w.extname(t)&&(t+=".json");let{config:e}=f.readConfigFile(t,(t=>f.sys.readFile(t)));if(void 0===e)return{};if("string"==typeof e.extends){const n=ne(w.join(w.dirname(t),e.extends));e=Object.assign({},n,e)}return e}function re(t){return{label:oe(t.prefixDisplayParts)+t.parameters.map((t=>oe(t.displayParts))).join(oe(t.separatorDisplayParts))+oe(t.suffixDisplayParts),documentation:oe(t.documentation),parameters:t.parameters.map(ie)}}function ie(t){return{label:oe(t.displayParts),documentation:oe(t.documentation)}}function oe(t){return t.map((t=>t.text)).join("")}const se=function(){let t;return function(e,n){if(void 0===e)return!0;void 0===t&&(t=new Map(Object.values(f.Diagnostics).map((t=>[t.code,t.category]))));const r=t.get(e);return void 0===r||r===n}}();function ae(t){return void 0!==t&&pe(w.extname(t))}function ce(){const t=atom.config.get("atom-typescript"),e=t.tsSyntaxScopes;return t.allowJS&&e.push(...t.jsSyntaxScopes),e}function ue(t){return ae(t.getPath())&&le(t)}function le(t){const[e]=t.getRootScopeDescriptor().getScopesArray();return ce().includes(e)}function fe(t){return null!=t}const pe=function(t,e){const n=Qt.memoize((n=>Qt.throttle(t,e,{leading:!0})));return t=>n(t)(t)}((t=>{const e=atom.config.get("atom-typescript"),n=e.tsFileExtensions;if(e.allowJS&&n.push(...e.jsFileExtensions),e.extensionsFromGrammars){var r;const t=null!==(r=atom.config.get("core.customFileTypes"))&&void 0!==r?r:{},e=ce();n.push(...[].concat(...e.map((t=>{var e;return null===(e=atom.grammars.grammarForScopeName(t))||void 0===e?void 0:e.fileTypes})),...e.map((e=>t[e]))).filter(fe).map((t=>"."+t)))}return n.includes(t)}),5e3);function he(t,e){const n=t.getPath();if(void 0!==n){return{file:n,...e?Jt(e):function(t){const e=t.getCursorBufferPosition();return{line:e.row+1,offset:e.column+1}}(t)}}}async function de(t,e){const n=new h.TextEditor({readonly:!0,keyboardInputEnabled:!1,showInvisibles:!1,tabLength:atom.config.get("editor.tabLength")}),r=atom.views.getView(n);try{return r.setUpdatedSynchronously(!0),r.style.pointerEvents="none",r.style.position="absolute",r.style.top="100vh",r.style.width="100vw",atom.grammars.assignLanguageMode(n.getBuffer(),e),n.setText(t),n.scrollToBufferPosition(n.getBuffer().getEndPosition()),atom.views.getView(atom.workspace).appendChild(r),await async function(t){return new Promise((e=>{const n=t.getBuffer().getLanguageMode(),r=t.component.getNextUpdatePromise();if(n.fullyTokenized||n.tree)e(r);else{const n=t.onDidTokenize((()=>{n.dispose(),e(r)}))}}))}(n),Array.from(r.querySelectorAll(".line:not(.dummy)")).map((t=>t.innerHTML))}finally{r.remove()}}function ge(t){const e=t.dataset.startLine;return void 0!==e?parseInt(e,10)-1:0}function me(t){const e=t.dataset.endLine;return void 0!==e?parseInt(e,10)-1:0}function ve(t,e,n){const r=n.querySelectorAll(":scope > ol > li.node");if(0===r.length)return;for(const n of Array.from(r)){const r=ge(n),i=me(n);if(isFinite(r)&&isFinite(i)){if(t>=r&&e<=i){const r=ve(t,e,n);return r||n}if(isFinite(i)&&e=i&&e<=o?n:void 0}function ye(t){return t.spans.length>0?t.spans[0].start.line-1:0}function we(t,e){if(!t||!e)return t===e;if(t.text===e.text){if(e.collapsed&&(t.collapsed=!0),t.childItems&&e.childItems){let n,r;for(let i=0,o=t.childItems.length;iye(t)-ye(e)));for(const e of t.childItems)be(e)}}class _e{constructor(t){this.props=t,ft.initialize(this)}async update(t){this.props={...this.props,...t},await ft.update(this)}async destroy(){await ft.destroy(this)}render(){var t,e,n,r;const i=this.props.navTree,{ctrl:o}=this.props,s=(i.childItems?"nested-":"")+"item"+(i.collapsed?" collapsed":" expanded"),a=this.getStyles();return ft.dom("li",{className:"node entry exanded list-"+s,dataset:{startLine:null===(t=this.props.navTree.spans[0])||void 0===t||null===(e=t.start)||void 0===e?void 0:e.line,endLine:null===(n=this.props.navTree.spans[0])||void 0===n||null===(r=n.end)||void 0===r?void 0:r.line}},ft.dom("div",{className:"header list-item",on:{click:t=>this.entryClicked(t,i)}},ft.dom("span",{className:a},i.text)),ft.dom("ol",{className:"entries list-tree"},i.childItems?i.childItems.map((t=>ft.dom(_e,{navTree:t,ctrl:o}))):null))}getStyles(){const{kind:t}=this.props.navTree;let e="icon icon-"+t;const{kindModifiers:n}=this.props.navTree;return n&&(e+=" "+n.split(/[, ]/).map((t=>"modifier-"+t.trim())).join(" ")),e}entryClicked(t,e){t.stopPropagation();(function(t,e){return!!t.childItems&&e.target===e.currentTarget})(e,t)?(e.collapsed=!e.collapsed,Kt(ft.update(this))):this.props.ctrl.gotoNode(e)}}class xe{constructor(t){this.props=t,this.subscriptions=new d,this.loadNavTree=async()=>{if(!this.editor)return;if(!this.getClient)return;const t=this.editor.getPath();if(void 0!==t)try{const e=await this.getClient(t),n=(await e.execute("navtree",{file:t})).body;n&&(this.setNavTree(n),await ft.update(this))}catch(e){console.error(e,t)}},this.selectAtCursorLine=({newBufferPosition:t})=>{var e,n;const r=this.firstNode();if(!r)return;const i=t.row,o=null!==(e=null===(n=ve(i,i,r))||void 0===n?void 0:n.querySelector(".header"))&&void 0!==e?e:void 0,s=this.getSelectedNode();o!==s&&(s&&s.classList.remove("selected"),o&&o.classList.add("selected"))},this.subscribeToEditor=async t=>{if(this.editorScrolling&&this.editorScrolling.dispose(),this.editorChanging&&this.editorChanging.dispose(),!t||!ue(t))return this.update({navTree:null});this.editor=t,await this.loadNavTree(),this.editorScrolling=t.onDidChangeCursorPosition(this.selectAtCursorLine),this.editorChanging=t.onDidStopChanging(this.loadNavTree)},be(t.navTree),ft.initialize(this),this.subscriptions.add(atom.workspace.observeActiveTextEditor(this.subscribeToEditor))}async update(t){void 0!==t.navTree&&this.setNavTree(t.navTree),this.props={...this.props,...t},await ft.update(this)}async destroy(){this.editorScrolling&&this.editorScrolling.dispose(),this.editorChanging&&this.editorChanging.dispose(),this.editorScrolling=void 0,this.editorChanging=void 0,this.subscriptions.dispose(),await ft.destroy(this)}async setGetClient(t){this.getClient=t,await this.loadNavTree()}getSelectedNode(){var t;return null!==(t=this.element.querySelector(".header.selected"))&&void 0!==t?t:void 0}clearSelection(){const t=this.element.querySelectorAll(".header.selected");for(let e=0;e0?t.spans[0].start.offset-1:0}(t);this.editor.setCursorBufferPosition([e,n])}getCursorLine(){return this.editor?this.editor.getLastCursor().getBufferRow():void 0}setNavTree(t){if(be(t),Qt.isEqual(t,this.props.navTree))return;we(t,this.props.navTree),this.props.navTree=t;const e=this.firstNode();if(e){const t=this.getCursorLine();void 0!==t&&this.markSelection(ve(t,t,e))}}scrollTo(t){const e=t;"function"==typeof e.scrollIntoViewIfNeeded?e.scrollIntoViewIfNeeded():e.scrollIntoView()}}class Se{constructor(t){this.comp=new xe({navTree:t.navTree})}static create(t){return Se.instance||(Se.instance=new Se(t)),Se.instance}get element(){return this.comp.element}async setGetClient(t){await this.comp.setGetClient(t),await this.comp.update({})}getTitle(){return"TypeScript"}getURI(){return"atom-typescript://semantic-view"}async destroy(){Se.instance=null,await this.comp.destroy()}getDefaultLocation(){return"right"}getAllowedLocations(){return["left","right"]}serialize(){return{deserializer:"atomts-semantic-view/SemanticView",data:{navTree:this.comp.props.navTree}}}}Se.instance=null;var ke,Ee=u,Ce=a,Te=s;ke=function(t,e){return Ae(t,e)};var Ae=function(t,e){return t?Pe(t,e):new Oe(e)};ke.createStream=Ae;function Pe(t,e){if(!t)throw new Error("expected readStream");if(!t.readable)throw new Error("readStream must be readable");var n=new Oe(e);return t.pipe(n),n}function Oe(t){Ee.Transform.call(this,t),t=t||{},this._readableState.objectMode=!0,this._lineBuffer=[],this._keepEmptyLines=t.keepEmptyLines||!1,this._lastChunkEndedWithCR=!1;var e=this;this.on("pipe",(function(t){e.encoding||t instanceof Ee.Readable&&(e.encoding=t._readableState.encoding)}))}ke.createLineStream=function(t){return console.log("WARNING: byline#createLineStream is deprecated and will be removed soon"),Pe(t)},ke.LineStream=Oe,Ce.inherits(Oe,Ee.Transform),Oe.prototype._transform=function(t,e,n){e=e||"utf8",Buffer.isBuffer(t)&&("buffer"==e?(t=t.toString(),e="utf8"):t=t.toString(e)),this._chunkEncoding=e;var r=t.split(/\r\n|[\n\v\f\r\x85\u2028\u2029]/g);this._lastChunkEndedWithCR&&"\n"==t[0]&&r.shift(),this._lineBuffer.length>0&&(this._lineBuffer[this._lineBuffer.length-1]+=r[0],r.shift()),this._lastChunkEndedWithCR="\r"==t[t.length-1],this._lineBuffer=this._lineBuffer.concat(r),this._pushBuffer(e,1,n)},Oe.prototype._pushBuffer=function(t,e,n){for(;this._lineBuffer.length>e;){var r=this._lineBuffer.shift();if((this._keepEmptyLines||r.length>0)&&!this.push(this._reencode(r,t))){var i=this;return void Te.setImmediate((function(){i._pushBuffer(t,e,n)}))}}n()},Oe.prototype._flush=function(t){this._pushBuffer(this._chunkEncoding,0,t)},Oe.prototype._reencode=function(t,e){return this.encoding&&this.encoding!=e?new Buffer(t,e).toString(this.encoding):this.encoding?t:new Buffer(t,e)};class Ie{constructor(t){this.reportBusyWhile=t,this.callbacks=new Map,this.interval=0}async add(t,e){try{const n=new Promise(((n,r)=>{this.callbacks.set(t,{command:e,resolve:n,reject:r,started:Date.now()})}));return 0===this.interval&&(this.interval=window.setInterval((()=>{process.activateUvLoop()}),100)),await this.reportBusyWhile(e,(()=>n))}finally{this.callbacks.delete(t),0!==this.interval&&0===this.callbacks.size&&(clearInterval(this.interval),this.interval=0)}}rejectAll(t){for(const{reject:e}of this.callbacks.values())e(t);this.callbacks.clear()}resolve(t){const e=this.callbacks.get(t.request_seq);e?(window.atom_typescript_debug&&console.log("received response for",t.command,"in",Date.now()-e.started,"ms","with data",t.body),t.success?e.resolve(t):e.reject(new Error(t.message))):console.warn("unexpected response:",t)}resolveMS(t){const e=this.callbacks.get(t.request_seq);e?(window.atom_typescript_debug&&console.log(`received requestCompleted event for multistep command ${e.command} in ${Date.now()-e.started} ms`),e.resolve(void 0)):console.warn("unexpected requestCompleted event:",t)}error(t,e){const n=this.callbacks.get(t);n?n.reject(e):console.error(e)}}const je=new Set(Object.keys({compileOnSaveAffectedFileList:!0,compileOnSaveEmitFile:!0,completionEntryDetails:!0,completions:!0,completionInfo:!0,configure:!0,definition:!0,format:!0,getCodeFixes:!0,getSupportedCodeFixes:!0,documentHighlights:!0,projectInfo:!0,quickinfo:!0,references:!0,reload:!0,rename:!0,navtree:!0,navto:!0,getApplicableRefactors:!0,getEditsForRefactor:!0,organizeImports:!0,signatureHelp:!0,getEditsForFileRename:!0,applyCodeActionCommand:!0})),Ne=new Set(Object.keys({geterr:!0,geterrForProject:!0})),De=new Set(Object.keys({configFileDiag:!0,semanticDiag:!0,suggestionDiag:!0,syntaxDiag:!0}));class Fe{constructor(t,e,n){this.tsServerPath=t,this.version=e,this.reportBusyWhile=n,this.emitter=new g,this.seq=0,this.lastStderrOutput="",this.on=this.emitter.on.bind(this.emitter),this.exitHandler=(t,e=!0)=>{if(this.callbacks.rejectAll(t),e&&console.error("tsserver: ",t),this.server=void 0,this.emitter.emit("terminated"),e){let e=t.message;this.lastStderrOutput&&(e=`Last output from tsserver:\n${this.lastStderrOutput}\n\n${e}`),atom.notifications.addError("TypeScript server quit unexpectedly",{detail:e,stack:t.stack,dismissable:!0})}},this.onMessage=t=>{"response"===t.type?this.callbacks.resolve(t):this.onEvent(t)};const[r,i]=e.split(".").slice(0,2).map((t=>parseInt(t,10)));this.multistepSupported=r>2||2===r&&i>=2,this.callbacks=new Ie(this.reportBusyWhile),this.server=this.startServer()}async execute(t,...e){this.server||(this.server=this.startServer(),this.emitter.emit("restarted"));const n={seq:this.seq++,command:t,arguments:e[0]};window.atom_typescript_debug&&console.log("sending request",n);let r=void 0;(function(t){return je.has(t)}(t)||this.multistepSupported&&function(t){return Ne.has(t)}(t))&&(r=this.callbacks.add(n.seq,t));try{if(!this.server.stdin)throw new Error("Server stdin is missing");this.server.stdin.write(JSON.stringify(n)+"\n")}catch(t){this.callbacks.error(n.seq,t)}return r}async restartServer(){if(this.server){const t=this.server,e=setTimeout((()=>t.kill()),1e4);await Promise.all([this.execute("exit"),new Promise((t=>{const e=this.emitter.once("terminated",(()=>{e.dispose(),t()}))}))]),clearTimeout(e)}this.server||(this.server=this.startServer(),this.emitter.emit("restarted"))}startServer(){window.atom_typescript_debug&&console.log("starting",this.tsServerPath);const t=function(t){const e=atom.config.get("atom-typescript").locale,n=e?["--locale",e]:[];return new m({command:t,args:n}).process}(this.tsServerPath);if(!t)throw new Error("ChildProcess failed to start");const e=this.exitHandler;if(t.once("error",e),t.once("exit",((t,n)=>{0===t?e(new Error("Server stopped normally"),!1):null!==t?e(new Error("exited with code: "+t)):null!==n&&e(new Error("terminated on signal: "+n))})),!t.stdout)throw new Error("ChildProcess stdout missing");if(!t.stderr)throw new Error("ChildProcess stderr missing");var n;return(n=t.stdout,n.pipe(Me()).pipe(new Re)).on("data",this.onMessage),t.stderr.on("data",(t=>{console.warn("tsserver stderr:",this.lastStderrOutput=t.toString())})),t}onEvent(t){var e;window.atom_typescript_debug&&console.log("received event",t),t.body&&(e=t.event,De.has(e)?this.emitter.emit(t.event,t.body):"requestCompleted"===t.event&&this.callbacks.resolveMS(t.body))}}var Le,Me=C(ke);class Re extends l{constructor(){super({objectMode:!0})}_transform(t,e,n){const r=t.toString();try{r.startsWith("{")?this.push(JSON.parse(r)):r.startsWith("Content-Length:")||console.warn(r)}catch(t){console.error("client: failed to parse: ",r)}finally{n(void 0)}}}function Be(t,e){void 0===e&&(e=!1);var n=t.length,r=0,i="",o=0,s=16,a=0,c=0,u=0,l=0,f=0;function p(e,n){for(var i=0,o=0;i=48&&s<=57)o=16*o+s-48;else if(s>=65&&s<=70)o=16*o+s-65+10;else{if(!(s>=97&&s<=102))break;o=16*o+s-97+10}r++,i++}return i=n)return o=n,s=17;var e=t.charCodeAt(r);if(ze(e)){do{r++,i+=String.fromCharCode(e),e=t.charCodeAt(r)}while(ze(e));return s=15}if(qe(e))return r++,i+=String.fromCharCode(e),13===e&&10===t.charCodeAt(r)&&(r++,i+="\n"),a++,u=r,s=14;switch(e){case 123:return r++,s=1;case 125:return r++,s=2;case 91:return r++,s=3;case 93:return r++,s=4;case 58:return r++,s=6;case 44:return r++,s=5;case 34:return r++,i=function(){for(var e="",i=r;;){if(r>=n){e+=t.substring(i,r),f=2;break}var o=t.charCodeAt(r);if(34===o){e+=t.substring(i,r),r++;break}if(92!==o){if(o>=0&&o<=31){if(qe(o)){e+=t.substring(i,r),f=2;break}f=6}r++}else{if(e+=t.substring(i,r),++r>=n){f=2;break}switch(t.charCodeAt(r++)){case 34:e+='"';break;case 92:e+="\\";break;case 47:e+="/";break;case 98:e+="\b";break;case 102:e+="\f";break;case 110:e+="\n";break;case 114:e+="\r";break;case 116:e+="\t";break;case 117:var s=p(4,!0);s>=0?e+=String.fromCharCode(s):f=4;break;default:f=5}i=r}}return e}(),s=10;case 47:var h=r-1;if(47===t.charCodeAt(r+1)){for(r+=2;r=12&&t<=15);return t}:h,getToken:function(){return s},getTokenValue:function(){return i},getTokenOffset:function(){return o},getTokenLength:function(){return r-o},getTokenStartLine:function(){return c},getTokenStartCharacter:function(){return o-l},getTokenError:function(){return f}}}function ze(t){return 32===t||9===t||11===t||12===t||160===t||5760===t||t>=8192&&t<=8203||8239===t||8287===t||12288===t||65279===t}function qe(t){return 10===t||13===t||8232===t||8233===t}function He(t){return t>=48&&t<=57}(Le||(Le={})).DEFAULT={allowTrailingComma:!1};var Ue,$e,Ve=function(t,e,n){void 0===e&&(e=[]),void 0===n&&(n=Le.DEFAULT);var r=null,i=[],o=[];function s(t){Array.isArray(i)?i.push(t):null!==r&&(i[r]=t)}return function(t,e,n){void 0===n&&(n=Le.DEFAULT);var r=Be(t,!1);function i(t){return t?function(){return t(r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter())}:function(){return!0}}function o(t){return t?function(e){return t(e,r.getTokenOffset(),r.getTokenLength(),r.getTokenStartLine(),r.getTokenStartCharacter())}:function(){return!0}}var s=i(e.onObjectBegin),a=o(e.onObjectProperty),c=i(e.onObjectEnd),u=i(e.onArrayBegin),l=i(e.onArrayEnd),f=o(e.onLiteralValue),p=o(e.onSeparator),h=i(e.onComment),d=o(e.onError),g=n&&n.disallowComments,m=n&&n.allowTrailingComma;function v(){for(;;){var t=r.scan();switch(r.getTokenError()){case 4:y(14);break;case 5:y(15);break;case 3:y(13);break;case 1:g||y(11);break;case 2:y(12);break;case 6:y(16)}switch(t){case 12:case 13:g?y(10):h();break;case 16:y(1);break;case 15:case 14:break;default:return t}}}function y(t,e,n){if(void 0===e&&(e=[]),void 0===n&&(n=[]),d(t),e.length+n.length>0)for(var i=r.getToken();17!==i;){if(-1!==e.indexOf(i)){v();break}if(-1!==n.indexOf(i))break;i=v()}}function w(t){var e=r.getTokenValue();return t?f(e):a(e),v(),!0}function b(){switch(r.getToken()){case 11:var t=r.getTokenValue(),e=Number(t);isNaN(e)&&(y(2),e=0),f(e);break;case 7:f(null);break;case 8:f(!0);break;case 9:f(!1);break;default:return!1}return v(),!0}function _(){return 10!==r.getToken()?(y(3,[],[2,5]),!1):(w(!1),6===r.getToken()?(p(":"),v(),k()||y(4,[],[2,5])):y(5,[],[2,5]),!0)}function x(){s(),v();for(var t=!1;2!==r.getToken()&&17!==r.getToken();){if(5===r.getToken()){if(t||y(4,[],[]),p(","),v(),2===r.getToken()&&m)break}else t&&y(6,[],[]);_()||y(4,[],[2,5]),t=!0}return c(),2!==r.getToken()?y(7,[2],[]):v(),!0}function S(){u(),v();for(var t=!1;4!==r.getToken()&&17!==r.getToken();){if(5===r.getToken()){if(t||y(4,[],[]),p(","),v(),4===r.getToken()&&m)break}else t&&y(6,[],[]);k()||y(4,[],[4,5]),t=!0}return l(),4!==r.getToken()?y(8,[4],[]):v(),!0}function k(){switch(r.getToken()){case 3:return S();case 1:return x();case 10:return w(!0);default:return b()}}if(v(),17===r.getToken())return!!n.allowEmptyContent||(y(4,[],[]),!1);if(!k())return y(4,[],[]),!1;17!==r.getToken()&&y(9,[],[])}(t,{onObjectBegin:function(){var t={};s(t),o.push(i),i=t,r=null},onObjectProperty:function(t){r=t},onObjectEnd:function(){i=o.pop()},onArrayBegin:function(){var t=[];s(t),o.push(i),i=t,r=null},onArrayEnd:function(){i=o.pop()},onLiteralValue:s,onError:function(t,n,r){e.push({error:t,offset:n,length:r})}},n),i[0]},We=x,Ge=w;$e=function(){var t=Error.prepareStackTrace;Error.prepareStackTrace=function(t,e){return e};var e=(new Error).stack;return Error.prepareStackTrace=t,e[2].getFileName()};var Ke,Qe,Ze,Je,Ye,Xe,tn,en,nn,rn,on=w,sn=!1;function an(){Qe={},Ze="win32"===process.platform,Je=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/,Ye=/^([\s\S]*?)((?:\.{1,2}|[^\\\/]+?|)(\.[^.\/\\]*|))(?:[\\\/]*)$/,(Xe={}).parse=function(t){if("string"!=typeof t)throw new TypeError("Parameter 'pathString' must be a string, not "+typeof t);var e,n,r,i,o,s=(e=t,n=Je.exec(e),r=(n[1]||"")+(n[2]||""),i=n[3]||"",o=Ye.exec(i),[r,o[1],o[2],o[3]]);if(!s||4!==s.length)throw new TypeError("Invalid path '"+t+"'");return{root:s[0],dir:s[0]+s[1].slice(0,-1),base:s[2],ext:s[3],name:s[2].slice(0,s[2].length-s[3].length)}},tn=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,(en={}).parse=function(t){if("string"!=typeof t)throw new TypeError("Parameter 'pathString' must be a string, not "+typeof t);var e,n=(e=t,tn.exec(e).slice(1));if(!n||4!==n.length)throw new TypeError("Invalid path '"+t+"'");return n[1]=n[1]||"",n[2]=n[2]||"",n[3]=n[3]||"",{root:n[0],dir:n[0]+n[1].slice(0,-1),base:n[2],ext:n[3],name:n[2].slice(0,n[2].length-n[3].length)}},Qe=Ze?Xe.parse:en.parse,nn=en.parse,Qe.posix=nn,rn=Xe.parse,Qe.win32=rn}var cn=on.parse||(sn||(sn=!0,an()),Qe),un=function(t,e){var n="/";/^([A-Za-z]:)/.test(t)?n="":/^\\\\/.test(t)&&(n="\\\\");for(var r=[t],i=cn(t);i.dir!==r[r.length-1];)r.push(i.dir),i=cn(i.dir);return r.reduce((function(t,r){return t.concat(e.map((function(t){return on.resolve(n,r,t)})))}),[])};Ke=function(t,e,n){var r=e&&e.moduleDirectory?[].concat(e.moduleDirectory):["node_modules"];if(e&&"function"==typeof e.paths)return e.paths(n,t,(function(){return un(t,r)}),e);var i=un(t,r);return e&&e.paths?i.concat(e.paths):i};var ln;ln=function(t,e){return e||{}};var fn,pn,hn={},dn={},gn=Array.prototype.slice,mn=Object.prototype.toString;function vn(t,e){for(var n=t.split("."),r=e.split(" "),i=r.length>1?r[0]:"=",o=(r.length>1?r[1]:r[0]).split("."),s=0;s<3;++s){var a=parseInt(n[s]||0,10),c=parseInt(o[s]||0,10);if(a!==c)return"<"===i?a="===i&&a>=c}return">="===i}function yn(t,e){var n=e.split(/ ?&& ?/);if(0===n.length)return!1;for(var r=0;r= 15","async_hooks":">= 8","buffer_ieee754":"< 0.9.7","buffer":true,"child_process":true,"cluster":true,"console":true,"constants":true,"crypto":true,"_debug_agent":">= 1 && < 8","_debugger":"< 8","dgram":true,"diagnostics_channel":">= 15.1","dns":true,"dns/promises":">= 15","domain":">= 0.7.12","events":true,"freelist":"< 6","fs":true,"fs/promises":[">= 10 && < 10.1",">= 14"],"_http_agent":">= 0.11.1","_http_client":">= 0.11.1","_http_common":">= 0.11.1","_http_incoming":">= 0.11.1","_http_outgoing":">= 0.11.1","_http_server":">= 0.11.1","http":true,"http2":">= 8.8","https":true,"inspector":">= 8.0.0","_linklist":"< 8","module":true,"net":true,"node-inspect/lib/_inspect":">= 7.6.0 && < 12","node-inspect/lib/internal/inspect_client":">= 7.6.0 && < 12","node-inspect/lib/internal/inspect_repl":">= 7.6.0 && < 12","os":true,"path":true,"path/posix":">= 15.3","path/win32":">= 15.3","perf_hooks":">= 8.5","process":">= 1","punycode":true,"querystring":true,"readline":true,"repl":true,"smalloc":">= 0.11.5 && < 3","_stream_duplex":">= 0.9.4","_stream_transform":">= 0.9.4","_stream_wrap":">= 1.4.1","_stream_passthrough":">= 0.9.4","_stream_readable":">= 0.9.4","_stream_writable":">= 0.9.4","stream":true,"stream/promises":">= 15","string_decoder":true,"sys":[">= 0.6 && < 0.7",">= 0.8"],"timers":true,"timers/promises":">= 15","_tls_common":">= 0.11.13","_tls_legacy":">= 0.11.3 && < 10","_tls_wrap":">= 0.11.3","tls":true,"trace_events":">= 10","tty":true,"url":true,"util":true,"util/types":">= 15.3","v8/tools/arguments":">= 10 && < 12","v8/tools/codemap":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/consarray":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/csvparser":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/logreader":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/profile_view":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/splaytree":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8":">= 1","vm":true,"wasi":">= 13.4 && < 13.5","worker_threads":">= 11.7","zlib":true}'),fn=function(t,e){return hn(wn,t)&&function(t,e){if("boolean"==typeof e)return e;var n=void 0===t?process.versions&&process.versions.node&&process.versions.node:t;if("string"!=typeof n)throw new TypeError(void 0===t?"Unable to determine current node version":"If provided, a valid node version is required");if(e&&"object"==typeof e){for(var r=0;r1?e[0]:"=",r=(e.length>1?e[1]:e[0]).split("."),i=0;i<3;++i){var o=parseInt(Cn[i]||0,10),s=parseInt(r[i]||0,10);if(o!==s)return"<"===n?o="===n&&o>=s}return">="===n}function An(t){var e=t.split(/ ?&& ?/);if(0===e.length)return!1;for(var n=0;n= 15","async_hooks":">= 8","buffer_ieee754":"< 0.9.7","buffer":true,"child_process":true,"cluster":true,"console":true,"constants":true,"crypto":true,"_debug_agent":">= 1 && < 8","_debugger":"< 8","dgram":true,"diagnostics_channel":">= 15.1","dns":true,"dns/promises":">= 15","domain":">= 0.7.12","events":true,"freelist":"< 6","fs":true,"fs/promises":[">= 10 && < 10.1",">= 14"],"_http_agent":">= 0.11.1","_http_client":">= 0.11.1","_http_common":">= 0.11.1","_http_incoming":">= 0.11.1","_http_outgoing":">= 0.11.1","_http_server":">= 0.11.1","http":true,"http2":">= 8.8","https":true,"inspector":">= 8.0.0","_linklist":"< 8","module":true,"net":true,"node-inspect/lib/_inspect":">= 7.6.0 && < 12","node-inspect/lib/internal/inspect_client":">= 7.6.0 && < 12","node-inspect/lib/internal/inspect_repl":">= 7.6.0 && < 12","os":true,"path":true,"path/posix":">= 15.3","path/win32":">= 15.3","perf_hooks":">= 8.5","process":">= 1","punycode":true,"querystring":true,"readline":true,"repl":true,"smalloc":">= 0.11.5 && < 3","_stream_duplex":">= 0.9.4","_stream_transform":">= 0.9.4","_stream_wrap":">= 1.4.1","_stream_passthrough":">= 0.9.4","_stream_readable":">= 0.9.4","_stream_writable":">= 0.9.4","stream":true,"stream/promises":">= 15","string_decoder":true,"sys":[">= 0.6 && < 0.7",">= 0.8"],"timers":true,"timers/promises":">= 15","_tls_common":">= 0.11.13","_tls_legacy":">= 0.11.3 && < 10","_tls_wrap":">= 0.11.3","tls":true,"trace_events":">= 10","tty":true,"url":true,"util":true,"util/types":">= 15.3","v8/tools/arguments":">= 10 && < 12","v8/tools/codemap":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/consarray":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/csvparser":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/logreader":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/profile_view":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8/tools/splaytree":[">= 4.4.0 && < 5",">= 5.2.0 && < 12"],"v8":">= 1","vm":true,"wasi":">= 13.4 && < 13.5","worker_threads":">= 11.7","zlib":true}');var In={};for(var jn in On)Object.prototype.hasOwnProperty.call(On,jn)&&(In[jn]=Pn(On[jn]));Ue.core=In;Ue.isCore=function(t){return fn(t)};var Nn=x,Dn=w,Fn=Nn.realpathSync&&"function"==typeof Nn.realpathSync.native?Nn.realpathSync.native:Nn.realpathSync,Ln=function(t){try{var e=Nn.statSync(t)}catch(t){if(t&&("ENOENT"===t.code||"ENOTDIR"===t.code))return!1;throw t}return e.isFile()||e.isFIFO()},Mn=function(t){try{var e=Nn.statSync(t)}catch(t){if(t&&("ENOENT"===t.code||"ENOTDIR"===t.code))return!1;throw t}return e.isDirectory()},Rn=function(t){try{return Fn(t)}catch(t){if("ENOENT"!==t.code)throw t}return t},Bn=function(t,e,n){return n&&!1===n.preserveSymlinks?t(e):e},zn=function(t,e){var n=t(e);try{return JSON.parse(n)}catch(t){}};async function qn(t,e){const{NODE_PATH:n}=process.env,r=e+".js",i=await async function(t,e){return new Promise(((n,r)=>Hn(t,e,((t,e)=>{t?r(t):void 0===e?r(new Error("Module path is undefined")):n(e)}))))}("typescript/lib/"+r,{basedir:w.dirname(t),paths:void 0!==n?n.split(w.delimiter):void 0}).catch((async()=>{const e=await async function(t){const e=await async function(t){let e=t,n=w.dirname(e);for(;e!==n;){const t=await $n(e,[[".atom-typescript.json"],[".atom","atom-typescript.json"],[".vscode","settings.json"]]);if(void 0!==t)return{basedir:e,configFile:t};e=n,n=w.dirname(e)}}(t);if(e)try{const t=Ve(await async function(t){return new Promise(((e,n)=>x.readFile(t,((t,r)=>{t?n(t):e(r.toString("utf-8"))}))))}(e.configFile));let r;if("object"==typeof(n=t)&&null!==n&&"string"==typeof n.tsdkPath)r=t.tsdkPath;else{if(!function(t){return"object"==typeof t&&null!==t&&"string"==typeof t["typescript.tsdk"]}(t))return;r=w.dirname(t["typescript.tsdk"])}return w.isAbsolute(r)?r:w.join(e.basedir,r)}catch(t){console.warn(t)}var n}(w.dirname(t));if(void 0!==e){const t=w.join(e,"lib",r);if(await Un(t))return t}const n=atom.config.get("atom-typescript.tsdkPath");if(n){const t=w.join(n,"lib",r);if(await Un(t))return t}return require.resolve("typescript/lib/"+r)})),o=w.resolve(i,"../../package.json");return{version:require(o).version,pathToBin:i}}Ue.sync=function(t,e){if("string"!=typeof t)throw new TypeError("Path must be a string.");var n=ln(0,e),r=n.isFile||Ln,i=n.readFileSync||Nn.readFileSync,o=n.isDirectory||Mn,s=n.realpathSync||Rn,a=n.readPackageSync||zn;if(n.readFileSync&&n.readPackageSync)throw new TypeError("`readFileSync` and `readPackageSync` are mutually exclusive.");var c=n.packageIterator,u=n.extensions||[".js"],l=!1!==n.includeCoreModules,f=n.basedir||Dn.dirname($e()),p=n.filename||f;n.paths=n.paths||[];var h=Bn(s,Dn.resolve(f),n);if(/^(?:\.\.?(?:\/|$)|\/|([A-Za-z]:)?[/\\])/.test(t)){var d=Dn.resolve(h,t);"."!==t&&".."!==t&&"/"!==t.slice(-1)||(d+="/");var g=y(d)||b(d);if(g)return Bn(s,g,n)}else{if(l&&fn(t))return t;var m=function(t,e){for(var r=function(){return function(t,e,n){for(var r=Ke(e,n,t),i=0;ix.access(t,x.constants.F_OK,(t=>{e(!t)}))))}async function $n(t,e){for(const n of e){const e=w.join(t,...n);if(await Un(e))return e}}class Vn{constructor(t){this.reportBusyWhile=t,this.clients=new Map,this.memoizedClients=new Map,this.emitter=new g,this.subscriptions=new d,this.tsserverInstancePerTsconfig=atom.config.get("atom-typescript").tsserverInstancePerTsconfig,this.on=this.emitter.on.bind(this.emitter),this.diagnosticHandler=(t,e)=>n=>{const r=(i=n)&&i.triggerFile&&i.configFile?n.configFile:n.file;var i;r&&this.emitter.emit("diagnostics",{type:e,serverPath:t,filePath:r,diagnostics:n.diagnostics})}}async restartAllServers(){await this.reportBusyWhile("Restarting servers",(()=>Promise.all(Array.from(this.getAllClients()).map((t=>t.restartServer())))))}async get(t){const e=this.memoizedClients.get(t);if(e)return e;const n=this._get(t);this.memoizedClients.set(t,n);try{return await n}catch(e){throw this.memoizedClients.delete(t),e}}dispose(){this.emitter.dispose(),this.subscriptions.dispose(),this.memoizedClients.clear(),this.clients.clear()}async _get(t){const{pathToBin:e,version:n}=await qn(t,"tsserver"),r=this.tsserverInstancePerTsconfig?f.findConfigFile(t,(t=>f.sys.fileExists(t))):void 0;let i=this.clients.get(e);i||(i=new Map,this.clients.set(e,i));const o=i.get(r);if(o)return o;const s=new Fe(e,n,this.reportBusyWhile);return i.set(r,s),this.subscriptions.add(s.on("configFileDiag",this.diagnosticHandler(e,"configFileDiag")),s.on("semanticDiag",this.diagnosticHandler(e,"semanticDiag")),s.on("syntaxDiag",this.diagnosticHandler(e,"syntaxDiag")),s.on("suggestionDiag",this.diagnosticHandler(e,"suggestionDiag"))),s}*getAllClients(){for(const t of this.clients.values())yield*t.values()}}function Wn(t){return{grammarScopes:ce(),priority:100,async highlight(e,n){if(!ue(e))return;const r=he(e,n);if(!r)return;const i=await t(r.file),o=await i.execute("documentHighlights",{...r,filesToSearch:[r.file]});return o.body?Array.from(function*(t,e){for(const n of e)n.file===t&&(yield*n.highlightSpans.map(Xt))}(r.file,o.body)):void 0}}}async function Gn(t,e,n){if(void 0===t)return null;const r=e.dom("div",{className:"atom-typescript-datatip-tooltip-kind"},t.kind,function(t,e){return void 0===e?null:t.dom("span",{className:"atom-typescript-datatip-tooltip-kind-modifiers"},e)}(t.kindModifiers)),i=t.tags?t.tags.map((t=>{const n="atom-typescript-datatip-tooltip-doc-tag atom-typescript-datatip-tooltip-doc-tag-name-"+t.name;return e.dom("div",{className:n},e.dom("span",{className:"atom-typescript-datatip-tooltip-doc-tag-name"},t.name),function(t,e){if(void 0===e)return null;const[,n,r]=/^\s*(\S*)([^]*)$/.exec(e);return t.dom("span",{className:"atom-typescript-datatip-tooltip-doc-tag-text"},t.dom("span",{className:"atom-typescript-datatip-tooltip-doc-tag-text-first-word"},n),r)}(e,t.text))})):null,o=e.dom("div",{className:"atom-typescript-datatip-tooltip-doc"},t.documentation,i),s=t.displayString.replace(/^\(.+?\)\s+/,"");return[await n(s),r,o]}const Kn=Symbol.for("react.element"),Qn={dom:(t,e,...n)=>n.length>0?{$$typeof:Kn,type:t,ref:null,props:{...e,children:n}}:{$$typeof:Kn,type:t,ref:null,props:{...e}}};class Zn{constructor(t){this.getClient=t,this.providerName="TypeScript type tooltips",this.priority=100,this.grammarScopes=ce()}async datatip(t,e){try{const n=t.getPath();if(void 0===n)return;const r=await this.getClient(n),i=(await r.execute("quickinfo",{file:n,line:e.row+1,offset:e.column+1})).body,o=await Gn(i,Qn,Jn);return{component:()=>Qn.dom("div",{className:"atom-typescript-datatip-tooltip"},o),range:h.Range.fromObject([Yt(i.start),Yt(i.end)])}}catch(t){return}}}async function Jn(t){const e=atom.config.get("editor.fontFamily"),n=await de(t.replace(/\r?\n$/,""),"source.ts");return Qn.dom("div",{style:{fontFamily:e},className:"atom-typescript-datatip-tooltip-code",dangerouslySetInnerHTML:{__html:n.join("\n")}})}function Yn(t){const e=Xt(t);return{path:t.file,position:e.start,range:e,language:"TypeScript"}}function Xn(t){return{uri:t.file,range:te(t.start,t.end),name:void 0}}class tr{constructor(t){this.props=t,ft.initialize(this)}async update(t){return this.props={...this.props,...t},ft.update(this)}render(){const t={fontFamily:atom.config.get("editor.fontFamily")};return ft.dom("div",{className:"editor editor-colors",style:t,innerHTML:this.props.highlightedText})}}var er,nr,rr,ir={},or=!1;function sr(){return or||(or=!0,function(){var t,e;t=w.sep,er=function(e,n,r){var i,o,s,a,c;for(o=e.length-1;e[o]===t;)o--;for(c=0,s=o,i=null;o>=0;)e[o]===t?(c++,null==i&&(i=e.substring(o+1,s+1))):0===o&&(s0&&f.push({candidate:a,score:l}));f.sort(n),r=f.map(t)}return null!=u&&(r=r.slice(0,u)),r}}.call(ar={})),ar}var lr,fr,pr,hr=!1;function dr(){return hr||(hr=!0,function(){var t;t=w.sep,lr=function(e,n){var r,i,o;for(i=e.length-1;e[i]===t;)i--;for(o=i,r=null;i>=0;)e[i]===t?null==r&&(r=e.substring(i+1,o+1)):0===i&&(or;n<=r?e++:e--)p.push(e);return p}.apply(this);for(u=e.length,l=t.length,i=0,o=0,a=[];ie;0<=e?t++:t--)l.push(t);return l}.apply(this);if(c=-1!==i.indexOf(t),i=i.replace(e,""),a=r.match(n,i),!c)for(o=r.basenameMatch(n,i),a=a.concat(o).sort((function(t,e){return t-e})),u=null,s=0;sft.dom("span",{className:t.type},t.text))))}match(t){return t.query?function(t,e){let n=0,r=[];const i=[],o=ir.match(t,e);let s;for(s of o){if(s<0)continue;const e=t.substring(n,s);e&&(r.length>0&&i.push({text:r.join(""),type:"character-match"}),r=[],i.push({text:e})),r.push(t[s]),n=s+1}r.length>0&&i.push({text:r.join(""),type:"character-match"});return i.push({text:t.substring(n)}),i}(t.label,t.query):[{text:t.label}]}}var mr={},vr=mr&&mr.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(mr,"__esModule",{value:!0});const yr=h,wr=vr(ft),br=wr.default.dom,_r=vr(ir);mr=class{constructor(t){this.props=t,this.props.hasOwnProperty("initialSelectionIndex")||(this.props.initialSelectionIndex=0),t.initiallyVisibleItemCount&&this.initializeVisibilityObserver(),this.computeItems(!1),this.disposables=new yr.CompositeDisposable,wr.default.initialize(this),this.element.classList.add("select-list"),this.disposables.add(this.refs.queryEditor.onDidChange(this.didChangeQuery.bind(this))),t.skipCommandsRegistration||this.disposables.add(this.registerAtomCommands());const e=this.refs.queryEditor.element,n=this.didLoseFocus.bind(this);e.addEventListener("blur",n),this.didClickItemsList=!1,this.element.addEventListener("mousedown",(t=>{t.target===this.refs.items&&(this.didClickItemsList=!0)})),this.disposables.add(new yr.Disposable((()=>{e.removeEventListener("blur",n)})))}static setScheduler(t){wr.default.setScheduler(t)}static getScheduler(){return wr.default.getScheduler()}initializeVisibilityObserver(){this.visibilityObserver=new IntersectionObserver((t=>{for(const e of t)if(e.intersectionRatio>0){const t=e.target;this.visibilityObserver.unobserve(t);const n=Array.from(this.refs.items.children).indexOf(t);n>=0&&this.renderItemAtIndex(n)}}))}focus(){this.refs.queryEditor.element.focus()}didLoseFocus(t){this.didClickItemsList||this.element.contains(t.relatedTarget)?(this.didClickItemsList=!1,this.refs.queryEditor.element.focus()):document.hasFocus()&&this.cancelSelection()}reset(){this.refs.queryEditor.setText("")}destroy(){return this.disposables.dispose(),this.visibilityObserver&&this.visibilityObserver.disconnect(),wr.default.destroy(this)}registerAtomCommands(){return atom.commands.add(this.element,{"core:move-up":t=>{this.selectPrevious(),t.stopPropagation()},"core:move-down":t=>{this.selectNext(),t.stopPropagation()},"core:move-to-top":t=>{this.selectFirst(),t.stopPropagation()},"core:move-to-bottom":t=>{this.selectLast(),t.stopPropagation()},"core:confirm":t=>{this.confirmSelection(),t.stopPropagation()},"core:cancel":t=>{this.cancelSelection(),t.stopPropagation()}})}update(t){let e=!1;return"items"in t&&(this.props.items=t.items,e=!0),"maxResults"in t&&(this.props.maxResults=t.maxResults,e=!0),"filter"in t&&(this.props.filter=t.filter,e=!0),"filterQuery"in t&&(this.props.filterQuery=t.filterQuery,e=!0),"query"in t&&(this.refs.queryEditor.setText(t.query),e=!1),"selectQuery"in t&&(t.selectQuery?this.refs.queryEditor.selectAll():this.refs.queryEditor.clearSelections()),"order"in t&&(this.props.order=t.order),"emptyMessage"in t&&(this.props.emptyMessage=t.emptyMessage),"errorMessage"in t&&(this.props.errorMessage=t.errorMessage),"infoMessage"in t&&(this.props.infoMessage=t.infoMessage),"loadingMessage"in t&&(this.props.loadingMessage=t.loadingMessage),"loadingBadge"in t&&(this.props.loadingBadge=t.loadingBadge),"itemsClassList"in t&&(this.props.itemsClassList=t.itemsClassList),"initialSelectionIndex"in t&&(this.props.initialSelectionIndex=t.initialSelectionIndex),e&&this.computeItems(),wr.default.update(this)}render(){return br.div({},br(yr.TextEditor,{ref:"queryEditor",mini:!0}),this.renderLoadingMessage(),this.renderInfoMessage(),this.renderErrorMessage(),this.renderItems())}renderItems(){if(this.items.length>0){const t=["list-group"].concat(this.props.itemsClassList||[]).join(" ");return this.visibilityObserver&&wr.default.getScheduler().updateDocument((()=>{Array.from(this.refs.items.children).slice(this.props.initiallyVisibleItemCount).forEach((t=>{this.visibilityObserver.observe(t)}))})),this.listItems=this.items.map(((t,e)=>{const n=this.getSelectedItem()===t,r=!this.props.initiallyVisibleItemCount||ethis.didClickItem(e)})})),br.ol({className:t,ref:"items"},...this.listItems)}return!this.props.loadingMessage&&this.props.emptyMessage?br.span({ref:"emptyMessage"},this.props.emptyMessage):""}renderErrorMessage(){return this.props.errorMessage?br.span({ref:"errorMessage"},this.props.errorMessage):""}renderInfoMessage(){return this.props.infoMessage?br.span({ref:"infoMessage"},this.props.infoMessage):""}renderLoadingMessage(){return this.props.loadingMessage?br.div({className:"loading"},br.span({ref:"loadingMessage",className:"loading-message"},this.props.loadingMessage),this.props.loadingBadge?br.span({ref:"loadingBadge",className:"badge"},this.props.loadingBadge):""):""}getQuery(){return this.refs&&this.refs.queryEditor?this.refs.queryEditor.getText():""}getFilterQuery(){return this.props.filterQuery?this.props.filterQuery(this.getQuery()):this.getQuery()}didChangeQuery(){this.props.didChangeQuery&&this.props.didChangeQuery(this.getFilterQuery()),this.computeItems()}didClickItem(t){this.selectIndex(t),this.confirmSelection()}computeItems(t){this.listItems=null,this.visibilityObserver&&this.visibilityObserver.disconnect();const e=this.props.filter||this.fuzzyFilter.bind(this);this.items=e(this.props.items.slice(),this.getFilterQuery()),this.props.order&&this.items.sort(this.props.order),this.props.maxResults&&(this.items=this.items.slice(0,this.props.maxResults)),this.selectIndex(this.props.initialSelectionIndex,t)}fuzzyFilter(t,e){if(0===e.length)return t;{const n=[];for(const r of t){const t=this.props.filterKeyForItem?this.props.filterKeyForItem(r):r,i=_r.default.score(t,e);i>0&&n.push({item:r,score:i})}return n.sort(((t,e)=>e.score-t.score)),n.map((t=>t.item))}}getSelectedItem(){return void 0===this.selectionIndex?null:this.items[this.selectionIndex]}renderItemAtIndex(t){const e=this.items[t],n=this.getSelectedItem()===e,r=this.listItems[t].component;this.visibilityObserver&&this.visibilityObserver.unobserve(r.element),r.update({element:this.props.elementForItem(e,{selected:n,index:t,visible:!0}),selected:n,onclick:()=>this.didClickItem(t)})}selectPrevious(){return void 0===this.selectionIndex?this.selectLast():this.selectIndex(this.selectionIndex-1)}selectNext(){return void 0===this.selectionIndex?this.selectFirst():this.selectIndex(this.selectionIndex+1)}selectFirst(){return this.selectIndex(0)}selectLast(){return this.selectIndex(this.items.length-1)}selectNone(){return this.selectIndex(void 0)}selectIndex(t,e=!0){t>=this.items.length?t=0:t<0&&(t=this.items.length-1);const n=this.selectionIndex;return this.selectionIndex=t,void 0!==t&&this.props.didChangeSelection&&this.props.didChangeSelection(this.getSelectedItem()),e?this.listItems?(n>=0&&this.renderItemAtIndex(n),t>=0&&this.renderItemAtIndex(t),wr.default.getScheduler().getNextUpdatePromise()):wr.default.update(this):Promise.resolve()}selectItem(t){const e=this.items.indexOf(t);if(-1===e)throw new Error("Cannot select the specified item because it does not exist.");return this.selectIndex(e)}confirmSelection(){const t=this.getSelectedItem();null!=t?this.props.didConfirmSelection&&this.props.didConfirmSelection(t):this.props.didConfirmEmptySelection&&this.props.didConfirmEmptySelection()}cancelSelection(){this.props.didCancelSelection&&this.props.didCancelSelection()}};class xr{constructor(t){this.mouseDown=this.mouseDown.bind(this),this.mouseUp=this.mouseUp.bind(this),this.didClick=this.didClick.bind(this),this.selected=t.selected,this.onclick=t.onclick,this.element=t.element,this.element.addEventListener("mousedown",this.mouseDown),this.element.addEventListener("mouseup",this.mouseUp),this.element.addEventListener("click",this.didClick),this.selected&&this.element.classList.add("selected"),this.domEventsDisposable=new yr.Disposable((()=>{this.element.removeEventListener("mousedown",this.mouseDown),this.element.removeEventListener("mouseup",this.mouseUp),this.element.removeEventListener("click",this.didClick)})),wr.default.getScheduler().updateDocument(this.scrollIntoViewIfNeeded.bind(this))}mouseDown(t){t.preventDefault()}mouseUp(t){t.preventDefault()}didClick(t){t.preventDefault(),this.onclick()}destroy(){this.element.remove(),this.domEventsDisposable.dispose()}update(t){this.element.removeEventListener("mousedown",this.mouseDown),this.element.removeEventListener("mouseup",this.mouseUp),this.element.removeEventListener("click",this.didClick),this.element.parentNode.replaceChild(t.element,this.element),this.element=t.element,this.element.addEventListener("mousedown",this.mouseDown),this.element.addEventListener("mouseup",this.mouseUp),this.element.addEventListener("click",this.didClick),t.selected&&this.element.classList.add("selected"),this.selected=t.selected,this.onclick=t.onclick,wr.default.getScheduler().updateDocument(this.scrollIntoViewIfNeeded.bind(this))}scrollIntoViewIfNeeded(){this.selected&&this.element.scrollIntoViewIfNeeded(!1)}}var Sr=C(mr);async function kr({items:t,itemTemplate:e,itemFilterKey:n,didChangeSelection:r}){let i;const o=document.activeElement;try{return await new Promise((o=>{let s,a,c="Loading...",u=!1;const l=t=>{u||Kt(f.update(t))};"function"==typeof t&&(s=async e=>{const n=setTimeout((()=>l({loadingMessage:"Loading..."})),300),r=await t(e);clearTimeout(n),l({items:r,emptyMessage:"Nothing matches the search value",loadingMessage:void 0})},c=void 0,a="Please enter a search value");const f=new Sr({items:[],elementForItem:t=>ft.render(e(t,f)),filterKeyForItem:t=>""+t[n],didChangeSelection:r,didCancelSelection:()=>{u=!0,o(void 0)},didConfirmSelection:t=>{u=!0,o(t)},loadingMessage:c,didChangeQuery:s,emptyMessage:a,itemsClassList:["atom-typescript"]});"function"!=typeof t&&Kt(Promise.resolve(t).then((t=>{l({items:t,loadingMessage:void 0})}))),i=atom.workspace.addModalPanel({item:f,visible:!0}),f.focus()}))}finally{i&&i.destroy(),o&&o.focus()}}const Er=[];function Cr(t,e,n){Er.push({selector:t,command:e,desc:n})}async function Tr(t,e,n){const r=Promise.all(t.body.refs.map((async t=>{var e;const n=(await new Promise(((e,n)=>x.readFile(t.file,((t,r)=>{t?n(t):e(r.toString("utf-8"))}))))).split(/\r?\n/g),r=void 0!==t.contextStart&&void 0!==t.contextEnd?n.slice(t.contextStart.line-1,t.contextEnd.line):n,i=(await de(r.join("\n"),"source.tsx"))[t.start.line-((null===(e=t.contextStart)||void 0===e?void 0:e.line)||1)];return{...t,hlText:i}}))),i=await kr({items:r,itemTemplate:(t,e)=>ft.dom("li",null,ft.dom(gr,{label:atom.project.relativize(t.file),query:e.getFilterQuery()}),ft.dom("div",{className:"pull-right"},"line: ",t.start.line),ft.dom(tr,{highlightedText:t.hlText})),itemFilterKey:"file"});i&&await n(e,i)}async function Ar(t,e,n){if(t.body)if(t.body.length>1){const r=await kr({items:t.body,itemTemplate:(t,e)=>ft.dom("li",null,ft.dom(gr,{label:t.file,query:e.getFilterQuery()}),ft.dom("div",{className:"pull-right"},"line: ",t.start.line)),itemFilterKey:"file"});r&&await n(e,r)}else t.body.length>0&&await n(e,t.body[0])}function Pr(t){const e=t.spans.map(Xt).reduce(((t,e)=>e.union(t)));return{kind:Ir[t.kind],plainText:t.text,startPosition:e.start,endPosition:e.end,landingPosition:t.nameSpan?Xt(t.nameSpan).start:void 0,children:t.childItems?t.childItems.map(Pr).sort(Or):[]}}function Or(t,e){const n=t.landingPosition?t.landingPosition:t.startPosition,r=e.landingPosition?e.landingPosition:e.startPosition;return n.compare(r)}Cr("atom-text-editor","typescript:find-references",(t=>({description:"Find where symbol under text cursor is referenced",async didDispatch(e){const n=he(e);if(!n)return;const r=await t.getClient(n.file),i=await r.execute("references",n);await Tr(i,e,t.histGoForward)}}))),Cr("atom-text-editor","typescript:go-to-declaration",(t=>({description:"Go to declaration of symbol under text cursor",async didDispatch(e){const n=he(e);if(!n)return;const r=await t.getClient(n.file),i=await r.execute("definition",n);await Ar(i,e,t.histGoForward)}})));const Ir={directory:"file",module:"module","external module name":"module",class:"class","local class":"class",method:"method",property:"property",getter:"property",setter:"property","JSX attribute":"field",constructor:"constructor",enum:"enum",interface:"interface",type:"interface",function:"function","local function":"function",label:"variable",alias:"variable",var:"variable",let:"variable","local var":"variable",parameter:"variable","enum member":"constant",const:"constant",string:"string","":void 0,warning:void 0,keyword:void 0,script:void 0,call:void 0,index:void 0,construct:void 0,"type parameter":void 0,"primitive type":void 0};class jr{constructor(t){this.getClient=t,this.triggerCharacters=new Set([]),this.grammarScopes=ce(),this.priority=100,this.disposables=new d;const e=new Set(["<","(",","]),n=new Set([]);this.disposables.add(atom.config.observe("atom-typescript.sigHelpDisplayOnChange",(t=>{this.triggerCharacters=t?e:n})))}dispose(){this.disposables.dispose()}async getSignatureHelp(t,e){try{const n=t.getPath();if(void 0===n)return;const r=await this.getClient(n),i=(await r.execute("signatureHelp",{file:n,line:e.row+1,offset:e.column+1})).body;return{signatures:i.items.map(re),activeParameter:i.argumentIndex,activeSignature:i.selectedItemIndex}}catch(t){return}}}function Nr(t){return ft.dom("li",null,t.description)}class Dr{constructor(t,e){this.getClient=t,this.applyEdits=e,this.selector=ce().map((t=>t.includes(".")?"."+t:t)).join(", "),this.inclusionPriority=3,this.suggestionPriority=atom.config.get("atom-typescript").autocompletionSuggestionPriority,this.excludeLowerPriority=!1}async getSuggestions(t){const e=function(t){const e=t.editor.getPath();if(void 0===e)return;return{file:e,line:t.bufferPosition.row+1,offset:t.bufferPosition.column+1}}(t),n=function(t){const e=t.editor.getBuffer().getTextInRange([[t.bufferPosition.row,0],t.bufferPosition]).match(Fr);return e?e[0]:""}(t);if(!e)return[];const r=function(t){if(void 0===t)return;if(!t)return;const e=t.slice(-1);if(qr.has(e))return e;return}(function(t,e){let n;const r=new h.Range([0,0],e);return t.backwardsScanInRange(/\S/,r,(({matchText:t,stop:e})=>{n=t,e()})),n}(t.editor.getBuffer(),t.bufferPosition));if(!n&&!t.activatedManually&&!r)return[];if(Mr(t.scopeDescriptor.getScopesArray(),"string.template.")&&!Mr(t.scopeDescriptor.getScopesArray(),"template.expression."))return[];try{let i=await this.getSuggestionsWithCache({prefix:n,location:e,triggerCharacter:r,activatedManually:t.activatedManually});return i=ir.filter(i,n,{key:"displayText"}),i.map((r=>({replacementPrefix:r.replacementRange?t.editor.getTextInBufferRange(r.replacementRange):n,location:e,...this.getDetailsFromCache(r),...Br(t,r)})))}catch(t){return[]}}async getSuggestionDetailsOnSelect(t){return"text"in t&&!("rightLabel"in t)?this.getAdditionalDetails(t):null}onDidInsertSuggestion(t){const e=t.suggestion;if(!e.hasAction)return;if(!this.lastSuggestions)return;const n=this.lastSuggestions.client;let r=this.getDetailsFromCache(e);Kt((async()=>{var t;if(r||(r=await this.getAdditionalDetails(e)),!(null===(t=r)||void 0===t?void 0:t.details.codeActions))return;let i;i=1===r.details.codeActions.length?r.details.codeActions[0]:await kr({items:r.details.codeActions,itemTemplate:Nr,itemFilterKey:"description"}),i&&(await this.applyEdits(i.changes),i.commands&&await Promise.all(i.commands.map((t=>n.execute("applyCodeActionCommand",{command:t})))))})())}async getAdditionalDetails(t){var e;if(void 0===t.identifier)return null;if(!this.lastSuggestions)return null;const n=await this.lastSuggestions.client.execute("completionEntryDetails",{entryNames:[t.identifier],...this.lastSuggestions.location});if(!n.body)return null;const[r]=n.body;if(!r)return null;let i=r.displayParts;i.length>=3&&"("===i[0].text&&i[1].text===t.leftLabel&&")"===i[2].text&&(i=i.slice(3));let o=i.map((t=>t.text)).join("");const s=t.hasAction&&1===(null===(e=r.codeActions)||void 0===e?void 0:e.length)?r.codeActions[0].description+"\n\n":"";s&&(o=s);const a=s+r.displayParts.map((t=>t.text)).join("")+(r.documentation?"\n\n"+r.documentation.map((t=>t.text)).join(" "):"");return this.lastSuggestions.details.set(t.displayText,{details:r,rightLabel:o,description:a}),{...t,details:r,rightLabel:o,description:a}}getDetailsFromCache(t){if(!this.lastSuggestions)return null;const e=this.lastSuggestions.details.get(t.displayText);return e||null}async getSuggestionsWithCache({prefix:t,location:e,triggerCharacter:n,activatedManually:r}){if(this.lastSuggestions&&!r){const n=this.lastSuggestions.location,r=Lr(this.lastSuggestions.prefix,n.offset),i=Lr(t,e.offset);if(n.file===e.file&&n.line===e.line&&r===i&&0!==this.lastSuggestions.suggestions.length)return this.lastSuggestions.suggestions}const i=await this.getClient(e.file),o=await async function({client:t,location:e,triggerCharacter:n}){if(parseInt(t.version.split(".")[0],10)>=3){var r;const i=await t.execute("completionInfo",{includeExternalModuleExports:!1,includeInsertTextCompletions:!0,triggerCharacter:n,...e});return i.body.entries.map(Rr.bind(null,null===(r=i.body)||void 0===r?void 0:r.isMemberCompletion))}return(await t.execute("completions",{includeExternalModuleExports:!1,includeInsertTextCompletions:!0,...e})).body.map(Rr.bind(null,void 0))}({client:i,location:e,triggerCharacter:r?void 0:n});return this.lastSuggestions={client:i,location:e,prefix:t,suggestions:o,details:new Map},o}}const Fr=/(?:(?![\u{10000}-\u{10FFFF}])[\$_\p{Lu}\p{Ll}\p{Lt}\p{Lm}\p{Lo}\p{Nl}])(?:(?![\u{10000}-\u{10FFFF}])[\$_\p{Lu}\p{Ll}\p{Lt}\p{Lm}\p{Lo}\p{Nl}\u200C\u200D\p{Mn}\p{Mc}\p{Nd}\p{Pc}])*$/u;function Lr(t,e){return e-("."===t?0:t.length)}function Mr(t,e){for(const n of t)if(n.includes(e))return!0;return!1}function Rr(t,e){return{displayText:e.name,text:void 0!==e.insertText?e.insertText:e.name,leftLabel:e.kind,replacementRange:e.replacementSpan?Xt(e.replacementSpan):void 0,type:zr[e.kind],isMemberCompletion:t,identifier:void 0!==e.source?{name:e.name,source:e.source}:e.name,hasAction:e.hasAction}}function Br(t,e){return atom.config.get("atom-typescript.autocompleteParens")&&["function","method"].includes(e.leftLabel)&&!function(t){const e=t.editor.getBuffer(),n=t.bufferPosition;return!!e.getTextInRange([n,[n.row,e.lineLengthForRow(n.row)]]).match(/\s*\(/)}(t)?{...e,snippet:e.text+"($1)",text:void 0}:e}const zr={directory:"require",module:"import","external module name":"import",class:"class","local class":"class",method:"method",property:"property",getter:"property",setter:"property","JSX attribute":"property",constructor:"method",enum:"type",interface:"type",type:"type","type parameter":"type","primitive type":"type",function:"function","local function":"function",label:"variable",alias:"import",var:"variable",let:"variable","local var":"variable",parameter:"variable","enum member":"constant",const:"constant",string:"value",keyword:"keyword","":void 0,warning:void 0,script:void 0,call:void 0,index:void 0,construct:void 0},qr=new Set(Object.keys({".":null,'"':null,"'":null,"`":null,"/":null,"@":null,"<":null,"#":null}));async function Hr(t,e){const n=await async function(t,e){try{return await t.execute("getApplicableRefactors",{triggerReason:"invoked",...e})}catch{return}}(t,e);if(!n)return[];if(void 0===n.body||0===n.body.length)return[];const r=[];for(const t of n.body)for(const n of t.actions)r.push({refactorName:t.name,refactorDescription:t.description,refactorRange:e,actionName:n.name,actionDescription:n.description,inlineable:void 0===t.inlineable||t.inlineable});return r}async function Ur(t,e,n){const r=await e.execute("getEditsForRefactor",{...t.refactorRange,refactor:t.refactorName,action:t.actionName});if(void 0===r.body)return;const{edits:i,renameFilename:o,renameLocation:s}=r.body;if(await n.applyEdits(i),void 0===o||void 0===s)return;const a=await atom.workspace.open(o,{searchAllPanes:!0,initialLine:s.line-1,initialColumn:s.offset-1});await atom.commands.dispatch(atom.views.getView(a),"typescript:rename-refactor")}Cr("atom-text-editor","typescript:refactor-selection",(t=>({description:"Get a list of applicable refactors to selected code",async didDispatch(e){const n=he(e);if(!n)return;const r=e.getSelectedBufferRange(),i=await t.getClient(n.file),o=r.isEmpty()?n:{file:n.file,startLine:r.start.row+1,startOffset:r.start.column+1,endLine:r.end.row+1,endOffset:r.end.column+1},s=await Hr(i,o);if(0===s.length)return void atom.notifications.addInfo("AtomTS: No applicable refactors for the selection");const a=await kr({items:s,itemTemplate:(t,e)=>ft.dom("li",null,ft.dom(gr,{label:`${t.refactorDescription}: ${t.actionDescription}`,query:e.getFilterQuery()})),itemFilterKey:"actionDescription"});void 0!==a&&await Ur(a,i,t)}})));class $r{constructor(t,e,n){this.clientResolver=t,this.errorPusher=e,this.applyEdits=n,this.supportedFixes=new WeakMap}async getFixableRanges(t,e){const n=t.getPath();if(void 0===n)return[];const r=this.errorPusher.getErrorsInRange(n,e),i=await this.clientResolver.get(n),o=await this.getSupportedFixes(i);return Array.from(r).filter((t=>void 0!==t.code&&o.has(t.code))).map((t=>Xt(t)))}async runCodeFix(t,e){const n=t.getPath();if(void 0===n)return[];const r=await this.clientResolver.get(n),i=await this.getSupportedFixes(r),o=Array.from(this.errorPusher.getErrorsAt(n,e)).filter((t=>void 0!==t.code&&i.has(t.code))).map((t=>r.execute("getCodeFixes",{file:n,startLine:t.start.line,startOffset:t.start.offset,endLine:t.end.line,endOffset:t.end.offset,errorCodes:[t.code]}))),s=await Promise.all(o),a=[];for(const t of s)if(t.body)for(const e of t.body)a.push(e);const c=await Hr(r,{file:n,...Jt(e)});return a.push(...c),a}async applyFix(t){if("changes"in t)return this.applyEdits(t.changes);return Ur(t,await this.clientResolver.get(t.refactorRange.file),{applyEdits:this.applyEdits})}dispose(){}async getSupportedFixes(t){let e=this.supportedFixes.get(t);if(e)return e;const n=await t.execute("getSupportedCodeFixes");if(!n.body)throw new Error("No code fixes are supported");return e=new Set(n.body.map((t=>parseInt(t,10)))),this.supportedFixes.set(t,e),e}}async function Vr(t,e){let n;try{return await new Promise(((r,i)=>{try{const o=new m({command:t,args:["--init"],options:{cwd:e},exit:t=>{0===t?r():i(new Error("Tsc ended with nonzero exit code "+t))}});n=o.onWillThrowError(i)}catch(t){i(t)}}))}finally{n&&n.dispose()}}Cr("atom-text-editor","typescript:build",(t=>({description:"Compile all files in project related to current active text editor",async didDispatch(e){const n=e.getPath();if(void 0===n)return;const r=await t.getClient(n);t.reportBuildStatus(void 0);const i=await r.execute("projectInfo",{file:n,needFileNameList:!0}),o=new Set(i.body.fileNames);o.delete(i.body.configFileName);let s=0;const a=[...o.values()].map((e=>{return n=r.execute("compileOnSaveEmitFile",{file:e,forced:!0}),i=()=>{s+=1,t.reportProgress({max:o.size,value:s})},n.then(i,i),n;var n,i}));try{if((await Promise.all(a)).some((t=>!1===t.body)))throw new Error("Emit failed");t.reportBuildStatus({success:!0})}catch(e){const n=e;console.error(n),t.reportBuildStatus({success:!1,message:n.message})}}}))),Cr("atom-text-editor","typescript:check-all-files",(t=>({description:"Typecheck all files in project related to current active text editor",async didDispatch(e){var n;const r=e.getPath();if(void 0===r)return;const i=await t.getClient(r),o=await i.execute("projectInfo",{file:r,needFileNameList:!0}),s=new Set(null===(n=o.body.fileNames)||void 0===n?void 0:n.filter((t=>!t.endsWith("tsconfig.json")&&!t.includes(`${w.sep}node_modules${w.sep}`)))),a=s.size;if(i.multistepSupported){const e=i.on("syntaxDiag",(e=>{"file"in e&&s.delete(e.file),t.reportProgress({max:a,value:a-s.size})}));t.reportProgress({max:a,value:0}),await i.execute("geterrForProject",{file:r,delay:0}),e.dispose()}else{let e;const n=i.on("syntaxDiag",(r=>{void 0!==e&&window.clearTimeout(e),e=window.setTimeout((()=>{s.clear(),n.dispose(),t.reportProgress({max:a,value:a})}),2e3),"file"in r&&s.delete(r.file),0===s.size&&(n.dispose(),window.clearTimeout(e)),t.reportProgress({max:a,value:a-s.size})}));t.reportProgress({max:a,value:0}),await i.execute("geterrForProject",{file:r,delay:0})}}}))),Cr("atom-workspace","typescript:clear-errors",(t=>({description:"Clear error messages",didDispatch(){t.clearErrors()}}))),Cr("atom-text-editor","typescript:format-code",(t=>({description:"Format code in currently active text editor",async didDispatch(e){const n=e.getPath();if(void 0===n)return;const r=[];for(const t of e.getSelectedBufferRanges())t.isEmpty()||r.push({line:(i=t).start.row+1,offset:i.start.column+1,endLine:i.end.row+1,endOffset:i.end.column+1});var i;if(0===r.length){const t=e.getBuffer().getEndPosition();r.push({line:1,offset:1,endLine:t.row+1,endOffset:t.column+1})}const o=await t.getClient(n),s=[];for(const t of r){const e=await o.execute("format",{...t,file:n});e.body&&s.push(...e.body)}s.length>0&&e.transact((()=>{!function(t,e){for(let n=e.length-1;n>=0;n--)t.setTextInBufferRange(Xt(e[n]),e[n].newText)}(e,s)}))}}))),Cr("atom-text-editor","typescript:initialize-config",(()=>({description:"Create tsconfig.json in the project related to currently-active text edtior",async didDispatch(t,e){const n=atom.project.getDirectories();if(0===n.length)return e();const r=t.getPath();if(void 0===r)return;const i=(await qn(r,"tsc")).pathToBin;for(const t of n)t.contains(r)&&(await Vr(i,t.getPath()),atom.notifications.addSuccess("Successfully created tsconfig.json in "+t.getPath()))}}))),Cr("atom-text-editor","typescript:organize-imports",(t=>({description:"Organize module imports",async didDispatch(e){const n=e.getPath();if(void 0===n)return;const r=await t.getClient(n),i=await r.execute("organizeImports",{scope:{type:"file",args:{file:n}}});i.body.length>0&&await t.applyEdits(i.body)}}))),Cr("atom-text-editor","typescript:reload-projects",(t=>({description:"Reload projects",async didDispatch(e){const n=e.getPath();if(void 0===n)return;const r=await t.getClient(n);await r.execute("reloadProjects")}})));var Wr,Gr,Kr={},Qr=!1;function Zr(){return Qr||(Qr=!0,Wr={},function(){var t="object"==typeof self&&self.self===self&&self||"object"==typeof T&&T.global===T&&T||this||{},e=t._,n=Array.prototype,r=Object.prototype,i="undefined"!=typeof Symbol?Symbol.prototype:null,o=n.push,s=n.slice,a=r.toString,c=r.hasOwnProperty,u=Array.isArray,l=Object.keys,f=Object.create,p=function(){},h=function(t){return t instanceof h?t:this instanceof h?void(this._wrapped=t):new h(t)};void 0===Wr||Wr.nodeType?t._=h:(!module.nodeType&&Wr&&(Wr=h),Gr=h,Wr._=Gr),h.VERSION="1.9.1";var d,g=function(t,e,n){if(void 0===e)return t;switch(null==n?3:n){case 1:return function(n){return t.call(e,n)};case 3:return function(n,r,i){return t.call(e,n,r,i)};case 4:return function(n,r,i,o){return t.call(e,n,r,i,o)}}return function(){return t.apply(e,arguments)}},m=function(t,e,n){return h.iteratee!==d?h.iteratee(t,e):null==t?h.identity:h.isFunction(t)?g(t,e,n):h.isObject(t)&&!h.isArray(t)?h.matcher(t):h.property(t)};h.iteratee=d=function(t,e){return m(t,e,1/0)};var v=function(t,e){return e=null==e?t.length-1:+e,function(){for(var n=Math.max(arguments.length-e,0),r=Array(n),i=0;i=0&&e<=x};h.each=h.forEach=function(t,e,n){var r,i;if(e=g(e,n),k(t))for(r=0,i=t.length;r0?0:s-1;for(i||(r=e[o?o[a]:a],a+=t);a>=0&&a=3;return e(t,g(n,i,4),r,o)}};h.reduce=h.foldl=h.inject=E(1),h.reduceRight=h.foldr=E(-1),h.find=h.detect=function(t,e,n){var r=(k(t)?h.findIndex:h.findKey)(t,e,n);if(void 0!==r&&-1!==r)return t[r]},h.filter=h.select=function(t,e,n){var r=[];return e=m(e,n),h.each(t,(function(t,n,i){e(t,n,i)&&r.push(t)})),r},h.reject=function(t,e,n){return h.filter(t,h.negate(m(e)),n)},h.every=h.all=function(t,e,n){e=m(e,n);for(var r=!k(t)&&h.keys(t),i=(r||t).length,o=0;o=0},h.invoke=v((function(t,e,n){var r,i;return h.isFunction(e)?i=e:h.isArray(e)&&(r=e.slice(0,-1),e=e[e.length-1]),h.map(t,(function(t){var o=i;if(!o){if(r&&r.length&&(t=_(t,r)),null==t)return;o=t[e]}return null==o?o:o.apply(t,n)}))})),h.pluck=function(t,e){return h.map(t,h.property(e))},h.where=function(t,e){return h.filter(t,h.matcher(e))},h.findWhere=function(t,e){return h.find(t,h.matcher(e))},h.max=function(t,e,n){var r,i,o=-1/0,s=-1/0;if(null==e||"number"==typeof e&&"object"!=typeof t[0]&&null!=t)for(var a=0,c=(t=k(t)?t:h.values(t)).length;ao&&(o=r);else e=m(e,n),h.each(t,(function(t,n,r){((i=e(t,n,r))>s||i===-1/0&&o===-1/0)&&(o=t,s=i)}));return o},h.min=function(t,e,n){var r,i,o=1/0,s=1/0;if(null==e||"number"==typeof e&&"object"!=typeof t[0]&&null!=t)for(var a=0,c=(t=k(t)?t:h.values(t)).length;ar||void 0===n)return 1;if(n0?0:i-1;o>=0&&o0?a=o>=0?o:Math.max(o+c,a):c=o>=0?Math.min(o+1,c):o+c+1;else if(n&&o&&c)return r[o=n(r,i)]===i?o:-1;if(i!=i)return(o=e(s.call(r,a,c),h.isNaN))>=0?o+a:-1;for(o=t>0?a:c-1;o>=0&&oe?(r&&(clearTimeout(r),r=null),a=u,s=t.apply(i,o),r||(i=o=null)):r||!1===n.trailing||(r=setTimeout(c,l)),s};return u.cancel=function(){clearTimeout(r),a=0,r=i=o=null},u},h.debounce=function(t,e,n){var r,i,o=function(e,n){r=null,n&&(i=t.apply(e,n))},s=v((function(s){if(r&&clearTimeout(r),n){var a=!r;r=setTimeout(o,e),a&&(i=t.apply(this,s))}else r=h.delay(o,e,this,s);return i}));return s.cancel=function(){clearTimeout(r),r=null},s},h.wrap=function(t,e){return h.partial(e,t)},h.negate=function(t){return function(){return!t.apply(this,arguments)}},h.compose=function(){var t=arguments,e=t.length-1;return function(){for(var n=e,r=t[e].apply(this,arguments);n--;)r=t[n].call(this,r);return r}},h.after=function(t,e){return function(){if(--t<1)return e.apply(this,arguments)}},h.before=function(t,e){var n;return function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=null),n}},h.once=h.partial(h.before,2),h.restArguments=v;var N=!{toString:null}.propertyIsEnumerable("toString"),D=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],F=function(t,e){var n=D.length,i=t.constructor,o=h.isFunction(i)&&i.prototype||r,s="constructor";for(b(t,s)&&!h.contains(e,s)&&e.push(s);n--;)(s=D[n])in t&&t[s]!==o[s]&&!h.contains(e,s)&&e.push(s)};h.keys=function(t){if(!h.isObject(t))return[];if(l)return l(t);var e=[];for(var n in t)b(t,n)&&e.push(n);return N&&F(t,e),e},h.allKeys=function(t){if(!h.isObject(t))return[];var e=[];for(var n in t)e.push(n);return N&&F(t,e),e},h.values=function(t){for(var e=h.keys(t),n=e.length,r=Array(n),i=0;i1&&(r=g(r,e[1])),e=h.allKeys(t)):(r=B,e=P(e,!1,!1),t=Object(t));for(var i=0,o=e.length;i1&&(n=e[1])):(e=h.map(P(e,!1,!1),String),r=function(t,n){return!h.contains(e,n)}),h.pick(t,r,n)})),h.defaults=L(h.allKeys,!0),h.create=function(t,e){var n=y(t);return e&&h.extendOwn(n,e),n},h.clone=function(t){return h.isObject(t)?h.isArray(t)?t.slice():h.extend({},t):t},h.tap=function(t,e){return e(t),t},h.isMatch=function(t,e){var n=h.keys(e),r=n.length;if(null==t)return!r;for(var i=Object(t),o=0;o":">",'"':""","'":"'","`":"`"},H=h.invert(q),U=function(t){var e=function(e){return t[e]},n="(?:"+h.keys(t).join("|")+")",r=RegExp(n),i=RegExp(n,"g");return function(t){return t=null==t?"":""+t,r.test(t)?t.replace(i,e):t}};h.escape=U(q),h.unescape=U(H),h.result=function(t,e,n){h.isArray(e)||(e=[e]);var r=e.length;if(!r)return h.isFunction(n)?n.call(t):n;for(var i=0;i/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var V=/(.)^/,W={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},G=/\\|'|\r|\n|\u2028|\u2029/g,K=function(t){return"\\"+W[t]};h.template=function(t,e,n){!e&&n&&(e=n),e=h.defaults({},e,h.templateSettings);var r,i=RegExp([(e.escape||V).source,(e.interpolate||V).source,(e.evaluate||V).source].join("|")+"|$","g"),o=0,s="__p+='";t.replace(i,(function(e,n,r,i,a){return s+=t.slice(o,a).replace(G,K),o=a+e.length,n?s+="'+\n((__t=("+n+"))==null?'':_.escape(__t))+\n'":r?s+="'+\n((__t=("+r+"))==null?'':__t)+\n'":i&&(s+="';\n"+i+"\n__p+='"),e})),s+="';\n",e.variable||(s="with(obj||{}){\n"+s+"}\n"),s="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+s+"return __p;\n";try{r=new Function(e.variable||"obj","_",s)}catch(t){throw t.source=s,t}var a=function(t){return r.call(this,t,h)},c=e.variable||"obj";return a.source="function("+c+"){\n"+s+"}",a},h.chain=function(t){var e=h(t);return e._chain=!0,e};var Q=function(t,e){return t._chain?h(e).chain():e};h.mixin=function(t){return h.each(h.functions(t),(function(e){var n=h[e]=t[e];h.prototype[e]=function(){var t=[this._wrapped];return o.apply(t,arguments),Q(this,n.apply(h,t))}})),h},h.mixin(h),h.each(["pop","push","reverse","shift","sort","splice","unshift"],(function(t){var e=n[t];h.prototype[t]=function(){var n=this._wrapped;return e.apply(n,arguments),"shift"!==t&&"splice"!==t||0!==n.length||delete n[0],Q(this,n)}})),h.each(["concat","join","slice"],(function(t){var e=n[t];h.prototype[t]=function(){return Q(this,e.apply(this._wrapped,arguments))}})),h.prototype.value=function(){return this._wrapped},h.prototype.valueOf=h.prototype.toJSON=h.prototype.value,h.prototype.toString=function(){return String(this._wrapped)},"function"==typeof define&&define.amd&&define("underscore",[],(function(){return h}))}()),Wr}var Jr,Yr=!1;function Xr(){return Yr||(Yr=!0,function(){var t,e,n,r,i,o,s,a,c=[].slice;a=Zr(),n={cmd:"⌘",ctrl:"⌃",alt:"⌥",option:"⌥",shift:"⇧",enter:"⏎",left:"←",right:"→",up:"↑",down:"↓"},r={cmd:"Cmd",ctrl:"Ctrl",alt:"Alt",option:"Alt",shift:"Shift",enter:"Enter",left:"Left",right:"Right",up:"Up",down:"Down"},o={"~":"`",_:"-","+":"=","|":"\\","{":"[","}":"]",":":";",'"':"'","<":",",">":".","?":"/"},s=function(t){var e,n,r,i,o;if(r=0,n=[],null==t)return n;for(e=i=0,o=t.length;i=0&&t.splice(n,1),t},setValueForKeyPath:function(t,e,n){var r,i;for(i=s(e);i.length>1;)null==t[r=i.shift()]&&(t[r]={}),t=t[r];return null!=n?t[i.shift()]=n:delete t[i.shift()]},hasKeyPath:function(t,e){var n,r,i,o;for(i=0,o=(r=s(e)).length;i0?s<=a:s>=a;o=s+=i)u.push(t.splice.apply(t,[e+o,0].concat(c.call(r.slice(o,o+i)))));return u},sum:function(t){var e,n,r;for(e=0,n=0,r=t.length;n=0&&t.length%1==0}function p(t,e){for(var n=-1,r=t.length;++n3?t(r,i,c,a):(s=o,o=i,t(r,c,a))}}function N(t,e){return e}function D(t,e,r){r=r||n;var i=f(e)?[]:{};t(e,(function(t,e,n){t(b((function(t,r){r.length<=1&&(r=r[0]),i[e]=r,n(t)})))}),(function(t){r(t,i)}))}function F(t,e,n,r){var i=[];t(e,(function(t,e,r){n(t,(function(t,e){i=i.concat(e||[]),r(t)}))}),(function(t){r(t,i)}))}function L(t,r,i){if(null==r)r=1;else if(0===r)throw new Error("Concurrency must not be zero");function o(t,r,i,o){if(null!=o&&"function"!=typeof o)throw new Error("task callback must be a function");if(t.started=!0,l(r)||(r=[r]),0===r.length&&t.idle())return e.setImmediate((function(){t.drain()}));p(r,(function(e){var r={data:e,callback:o||n};i?t.tasks.unshift(r):t.tasks.push(r),t.tasks.length===t.concurrency&&t.saturated()})),e.setImmediate(t.process)}function s(t,e){return function(){c-=1;var n=!1,r=arguments;p(e,(function(t){p(u,(function(e,r){e!==t||n||(u.splice(r,1),n=!0)})),t.callback.apply(t,r)})),t.tasks.length+c===0&&t.drain(),t.process()}}var c=0,u=[],f={tasks:[],concurrency:r,payload:i,saturated:n,empty:n,drain:n,started:!1,paused:!1,push:function(t,e){o(f,t,!1,e)},kill:function(){f.drain=n,f.tasks=[]},unshift:function(t,e){o(f,t,!0,e)},process:function(){for(;!f.paused&&cr?1:0}e.map(t,(function(t,e){n(t,(function(n,r){n?e(n):e(null,{value:t,criteria:r})}))}),(function(t,e){if(t)return r(t);r(null,h(e.sort(i),(function(t){return t.value})))}))},e.auto=function(t,r,i){"function"==typeof arguments[1]&&(i=r,r=null),i=c(i||n);var o=y(t),s=o.length;if(!s)return i(null);r||(r=s);var a={},u=0,f=!1,h=[];function d(t){h.unshift(t)}function w(t){var e=v(h,t);e>=0&&h.splice(e,1)}function _(){s--,p(h.slice(0),(function(t){t()}))}d((function(){s||i(null,a)})),p(o,(function(n){if(!f){for(var o,s=l(t[n])?t[n]:[t[n]],c=b((function(t,r){if(u--,r.length<=1&&(r=r[0]),t){var o={};m(a,(function(t,e){o[e]=t})),o[n]=r,f=!0,i(t,o)}else a[n]=r,e.setImmediate(_)})),p=s.slice(0,s.length-1),h=p.length;h--;){if(!(o=t[p[h]]))throw new Error("Has nonexistent dependency in "+p.join(", "));if(l(o)&&v(o,n)>=0)throw new Error("Has cyclic dependencies")}y()?(u++,s[s.length-1](c,a)):d((function t(){y()&&(u++,w(t),s[s.length-1](c,a))}))}function y(){return u3)throw new Error("Invalid arguments - must be either (task), (task, callback), (times, task) or (times, task, callback)");function l(t,n){function r(t,e){return function(r){t((function(t,n){r(!t||e,{err:t,result:n})}),n)}}function i(t){return function(e){setTimeout((function(){e(null)}),t)}}for(;a.times;){var o=!(a.times-=1);s.push(r(a.task,o)),!o&&a.interval>0&&s.push(i(a.interval))}e.series(s,(function(e,n){n=n[n.length-1],(t||a.callback)(n.err,n.result)}))}return u<=2&&"function"==typeof t&&(r=n,n=t),"function"!=typeof t&&c(a,t),a.callback=r,a.task=n,a.callback?l():l},e.waterfall=function(t,r){if(r=c(r||n),!l(t)){var i=new Error("First argument to waterfall must be an array of functions");return r(i)}if(!t.length)return r();!function t(e){return b((function(n,i){if(n)r.apply(null,[n].concat(i));else{var o=e.next();o?i.push(t(o)):i.push(r),z(e).apply(null,i)}}))}(e.iterator(t))()},e.parallel=function(t,n){D(e.eachOf,t,n)},e.parallelLimit=function(t,e,n){D(k(e),t,n)},e.series=function(t,n){D(e.eachOfSeries,t,n)},e.iterator=function(t){return function e(n){function r(){return t.length&&t[n].apply(null,arguments),r.next()}return r.next=function(){return n>>1);n(e,t[o])>=0?r=o:i=o-1}return r}(t.tasks,a,i)+1,0,a),t.tasks.length===t.concurrency&&t.saturated(),e.setImmediate(t.process)}))}(o,t,r,s)},delete o.unshift,o},e.cargo=function(t,e){return L(t,1,e)},e.log=M("log"),e.dir=M("dir"),e.memoize=function(t,n){var i={},o={},s=Object.prototype.hasOwnProperty;n=n||r;var a=b((function(r){var a=r.pop(),c=n.apply(null,r);s.call(i,c)?e.setImmediate((function(){a.apply(null,i[c])})):s.call(o,c)?o[c].push(a):(o[c]=[a],t.apply(null,r.concat([b((function(t){i[c]=t;var e=o[c];delete o[c];for(var n=0,r=e.length;n=t.length)return e&&(e[a]=t),n(null,t);gi.lastIndex=r;var c=gi.exec(t);return s=i,i+=c[0],o=s+c[1],r=gi.lastIndex,u[o]||e&&e[o]===o?process.nextTick(f):e&&Object.prototype.hasOwnProperty.call(e,o)?d(e[o]):hi.lstat(o,p)}function p(t,r){if(t)return n(t);if(!r.isSymbolicLink())return u[o]=!0,e&&(e[o]=o),process.nextTick(f);if(!pi){var i=r.dev.toString(32)+":"+r.ino.toString(32);if(c.hasOwnProperty(i))return h(null,c[i],o)}hi.stat(o,(function(t){if(t)return n(t);hi.readlink(o,(function(t,e){pi||(c[i]=e),h(t,e)}))}))}function h(t,r,i){if(t)return n(t);var o=fi.resolve(s,r);e&&(e[i]=o),d(o)}function d(e){t=fi.resolve(e,t.slice(r)),l()}l()},li.realpath=yi),li}var xi,Si,ki,Ei,Ci,Ti,Ai,Pi=!1;function Oi(t){return t&&"realpath"===t.syscall&&("ELOOP"===t.code||"ENOMEM"===t.code||"ENAMETOOLONG"===t.code)}function Ii(t,e,n){if(Ti)return ki(t,e,n);"function"==typeof e&&(n=e,e=null),ki(t,e,(function(r,i){Oi(r)?Ai.realpath(t,e,n):n(r,i)}))}function ji(t,e){if(Ti)return Ei(t,e);try{return Ei(t,e)}catch(n){if(Oi(n))return Ai.realpathSync(t,e);throw n}}function Ni(){Si.realpath=Ii,Si.realpathSync=ji}function Di(){Si.realpath=ki,Si.realpathSync=Ei}function Fi(){return Pi||(Pi=!0,xi={},xi=Ii,Ii.realpath=Ii,Ii.sync=ji,Ii.realpathSync=ji,Ii.monkeypatch=Ni,Ii.unmonkeypatch=Di,ki=(Si=x).realpath,Ei=Si.realpathSync,Ci=process.version,Ti=/^v[0-5]\./.test(Ci),Ai=_i()),xi}var Li,Mi,Ri=!1;function Bi(){return Ri||(Ri=!0,Li={},Li=function(t,e){for(var n=[],r=0;r=0&&u>0){for(r=[],o=n.length;l>=0&&!a;)l==c?(r.push(l),c=n.indexOf(t,l+1)):1==r.length?a=[r.pop(),u]:((i=r.pop())=0?c:u;r.length&&(a=[o,s])}return a}function Vi(){return qi||(qi=!0,zi={},zi=Hi,Hi.range=$i),zi}var Wi,Gi,Ki,Qi,Zi,Ji,Yi,Xi,to=!1;function eo(t){return parseInt(t,10)==t?parseInt(t,10):t.charCodeAt(0)}function no(t){return t.split(Qi).join("\\").split(Zi).join("{").split(Ji).join("}").split(Yi).join(",").split(Xi).join(".")}function ro(t){if(!t)return[""];var e=[],n=Ki("{","}",t);if(!n)return t.split(",");var r=n.pre,i=n.body,o=n.post,s=r.split(",");s[s.length-1]+="{"+i+"}";var a=ro(o);return o.length&&(s[s.length-1]+=a.shift(),s.push.apply(s,a)),e.push.apply(e,s),e}function io(t){return t?("{}"===t.substr(0,2)&&(t="\\{\\}"+t.substr(2)),uo(function(t){return t.split("\\\\").join(Qi).split("\\{").join(Zi).split("\\}").join(Ji).split("\\,").join(Yi).split("\\.").join(Xi)}(t),!0).map(no)):[]}function oo(t){return"{"+t+"}"}function so(t){return/^-?0\d/.test(t)}function ao(t,e){return t<=e}function co(t,e){return t>=e}function uo(t,e){var n=[],r=Ki("{","}",t);if(!r||/\$$/.test(r.pre))return[t];var i,o=/^-?\d+\.\.-?\d+(?:\.\.-?\d+)?$/.test(r.body),s=/^[a-zA-Z]\.\.[a-zA-Z](?:\.\.-?\d+)?$/.test(r.body),a=o||s,c=r.body.indexOf(",")>=0;if(!a&&!c)return r.post.match(/,.*\}/)?uo(t=r.pre+"{"+r.body+Ji+r.post):[t];if(a)i=r.body.split(/\.\./);else if(1===(i=ro(r.body)).length&&1===(i=uo(i[0],!1).map(oo)).length)return(f=r.post.length?uo(r.post,!1):[""]).map((function(t){return r.pre+i[0]+t}));var u,l=r.pre,f=r.post.length?uo(r.post,!1):[""];if(a){var p=eo(i[0]),h=eo(i[1]),d=Math.max(i[0].length,i[1].length),g=3==i.length?Math.abs(eo(i[2])):1,m=ao;h0){var _=new Array(b+1).join("0");w=y<0?"-"+_+w.slice(1):_+w}}u.push(w)}}else u=Gi(i,(function(t){return uo(t,!1)}));for(var x=0;x65536)throw new TypeError("pattern is too long");var n=this.options;if(!n.noglobstar&&"**"===t)return ho;if(""===t)return"";var r,i="",o=!!n.nocase,s=!1,a=[],c=[],u=!1,l=-1,f=-1,p="."===t.charAt(0)?"":n.dot?"(?!(?:^|\\/)\\.{1,2}(?:$|\\/))":"(?!\\.)",h=this;function d(){if(r){switch(r){case"*":i+=yo,o=!0;break;case"?":i+=vo,o=!0;break;default:i+="\\"+r}h.debug("clearStateChar %j %j",r,i),r=!1}}for(var g,m=0,v=t.length;m-1;k--){var E=c[k],C=i.slice(0,E.reStart),T=i.slice(E.reStart,E.reEnd-8),A=i.slice(E.reEnd-8,E.reEnd),P=i.slice(E.reEnd);A+=P;var O=C.split("(").length-1,I=P;for(m=0;m=0&&!(r=t[i]);i--);for(i=0;i>> no match, partial?",t,f,e,p),f!==s))}if("string"==typeof u?(c=r.nocase?l.toLowerCase()===u.toLowerCase():l===u,this.debug("string match",u,l,c)):(c=l.match(u),this.debug("pattern match",u,l,c)),!c)return!1}if(i===s&&o===a)return!0;if(i===s)return n;if(o===a)return i===s-1&&""===t[i];throw new Error("wtf?")}}function Lo(){return ko||(ko=!0,Fo()),fo}var Mo,Ro=!1;function Bo(){return Ro||(Ro=!0,Mo={},Mo="function"==typeof Object.create?function(t,e){t.super_=e,t.prototype=Object.create(e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}})}:function(t,e){t.super_=e;var n=function(){};n.prototype=e.prototype,t.prototype=new n,t.prototype.constructor=t}),Mo}var zo,qo,Ho,Uo=!1;function $o(t){return"/"===t.charAt(0)}function Vo(t){var e=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/.exec(t),n=e[1]||"",r=Boolean(n&&":"!==n.charAt(1));return Boolean(e[2]||r)}function Wo(){return Uo||(Uo=!0,zo={},zo="win32"===process.platform?Vo:$o,qo=$o,zo.posix=qo,Ho=Vo,zo.win32=Ho),zo}var Go,Ko,Qo,Zo,Jo,Yo,Xo,ts,es,ns,rs,is,os,ss=!1;function as(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function cs(t,e){return t.toLowerCase().localeCompare(e.toLowerCase())}function us(t,e){return t.localeCompare(e)}function ls(t){var e=null;if("/**"===t.slice(-3)){var n=t.replace(/(\/\*\*)+$/,"");e=new os(n,{dot:!0})}return{matcher:new os(t,{dot:!0}),gmatcher:e}}function fs(t,e,n){if(n||(n={}),n.matchBase&&-1===e.indexOf("/")){if(n.noglobstar)throw new Error("base matching requires globstar");e="**/"+e}t.silent=!!n.silent,t.pattern=e,t.strict=!1!==n.strict,t.realpath=!!n.realpath,t.realpathCache=n.realpathCache||Object.create(null),t.follow=!!n.follow,t.dot=!!n.dot,t.mark=!!n.mark,t.nodir=!!n.nodir,t.nodir&&(t.mark=!0),t.sync=!!n.sync,t.nounique=!!n.nounique,t.nonull=!!n.nonull,t.nosort=!!n.nosort,t.nocase=!!n.nocase,t.stat=!!n.stat,t.noprocess=!!n.noprocess,t.absolute=!!n.absolute,t.maxLength=n.maxLength||1/0,t.cache=n.cache||Object.create(null),t.statCache=n.statCache||Object.create(null),t.symlinks=n.symlinks||Object.create(null),function(t,e){t.ignore=e.ignore||[],Array.isArray(t.ignore)||(t.ignore=[t.ignore]),t.ignore.length&&(t.ignore=t.ignore.map(ls))}(t,n),t.changedCwd=!1;var r=process.cwd();as(n,"cwd")?(t.cwd=ns.resolve(n.cwd),t.changedCwd=t.cwd!==r):t.cwd=r,t.root=n.root||ns.resolve(t.cwd,"/"),t.root=ns.resolve(t.root),"win32"===process.platform&&(t.root=t.root.replace(/\\/g,"/")),t.cwdAbs=is(t.cwd)?t.cwd:ds(t,t.cwd),"win32"===process.platform&&(t.cwdAbs=t.cwdAbs.replace(/\\/g,"/")),t.nomount=!!n.nomount,n.nonegate=!0,n.nocomment=!0,t.minimatch=new os(e,n),t.options=t.minimatch.options}function ps(t){for(var e=t.nounique,n=e?[]:Object.create(null),r=0,i=t.matches.length;rthis.maxLength)return!1;if(!this.stat&&Ts(this.cache,e)){var r=this.cache[e];if(Array.isArray(r)&&(r="DIR"),!n||"DIR"===r)return r;if(n&&"FILE"===r)return!1}var i=this.statCache[e];if(!i){var o;try{o=ws.lstatSync(e)}catch(t){if(t&&("ENOENT"===t.code||"ENOTDIR"===t.code))return this.statCache[e]=!1,!1}if(o&&o.isSymbolicLink())try{i=ws.statSync(e)}catch(t){i=o}else i=o}return this.statCache[e]=i,r=!0,i&&(r=i.isDirectory()?"DIR":"FILE"),this.cache[e]=this.cache[e]||r,(!n||"FILE"!==r)&&r},js.prototype._mark=function(t){return Es.mark(this,t)},js.prototype._makeAbs=function(t){return Es.makeAbs(this,t)}),ys}var Ds,Fs=!1;function Ls(t,e){if(t&&e)return Ls(t)(e);if("function"!=typeof t)throw new TypeError("need wrapper function");return Object.keys(t).forEach((function(e){n[e]=t[e]})),n;function n(){for(var e=new Array(arguments.length),n=0;nr?(n.splice(0,r),process.nextTick((function(){e.apply(null,i)}))):delete Gs[t]}}))}(t))}function Js(t){for(var e=t.length,n=[],r=0;r1)return!0;for(var i=0;ithis.maxLength)return e();if(!this.stat&&fa(this.cache,n)){var i=this.cache[n];if(Array.isArray(i)&&(i="DIR"),!r||"DIR"===i)return e(null,i);if(r&&"FILE"===i)return e()}var o=this.statCache[n];if(void 0!==o){if(!1===o)return e(null,o);var s=o.isDirectory()?"DIR":"FILE";return r&&"FILE"===s?e():e(null,s,o)}var a=this,c=pa("stat\0"+n,(function(r,i){if(i&&i.isSymbolicLink())return ta.stat(n,(function(r,o){r?a._stat2(t,n,null,i,e):a._stat2(t,n,r,o,e)}));a._stat2(t,n,r,i,e)}));c&&ta.lstat(n,c)},wa.prototype._stat2=function(t,e,n,r,i){if(n&&("ENOENT"===n.code||"ENOTDIR"===n.code))return this.statCache[e]=!1,i();var o="/"===t.slice(-1);if(this.statCache[e]=r,"/"===e.slice(-1)&&r&&!r.isDirectory())return i(null,!1,r);var s=!0;return r&&(s=r.isDirectory()?"DIR":"FILE"),this.cache[e]=this.cache[e]||s,o&&"FILE"===s?i():i(null,s,r)}}function _a(){return va||(va=!0,ba()),Xs}var xa,Sa,ka,Ea,Ca,Ta,Aa,Pa,Oa,Ia=!1;function ja(t){["unlink","chmod","stat","lstat","rmdir","readdir"].forEach((function(e){t[e]=t[e]||Ea[e],t[e+="Sync"]=t[e]||Ea[e]})),t.maxBusyTries=t.maxBusyTries||3,t.emfileWait=t.emfileWait||1e3,!1===t.glob&&(t.disableGlob=!0),t.disableGlob=t.disableGlob||!1,t.glob=t.glob||Aa}function Na(t,e,n){"function"==typeof e&&(n=e,e={}),Sa(t,"rimraf: missing path"),Sa.equal(typeof t,"string","rimraf: path should be a string"),Sa.equal(typeof n,"function","rimraf: callback function required"),Sa(e,"rimraf: invalid options argument provided"),Sa.equal(typeof e,"object","rimraf: options should be object"),ja(e);var r=0,i=null,o=0;if(e.disableGlob||!Ca.hasMagic(t))return s(null,[t]);function s(t,s){return t?n(t):0===(o=s.length)?n():void s.forEach((function(t){Da(t,e,(function s(a){if(a){if(("EBUSY"===a.code||"ENOTEMPTY"===a.code||"EPERM"===a.code)&&r1&&(e=n.shift()),t=n.shift(),u.readdir(r,(function(n,i){return null!=n?t(n):(e&&(i=l.filterExtensions(i,e)),i=(i=i.sort((function(t,e){return t.toLowerCase().localeCompare(e.toLowerCase())}))).map((function(t){return v.join(r,t)})),t(null,i))}))},filterExtensions:function(t,e){return e=e.map((function(t){return""===t?t:"."+t.replace(/^\./,"")})),t.filter((function(t){return _.include(e,v.extname(t))}))},listTreeSync:function(t){var e,n;return n=[],e=function(t){return n.push(t),!0},l.traverseTreeSync(t,e,e),n},move:function(t,e,n){return p(t,e,(function(r,i){var o,s;if(!r)return i?(s=v.dirname(e),u.exists(s,(function(r){if(!r)return l.makeTree(s,(function(r){if(!r)return u.rename(t,e,n);n(r)}));u.rename(t,e,n)}))):((o=new Error("'"+e+"' already exists.")).code="EEXIST",void n(o));n(r)}))},moveSync:function(t,e){var n,r;if(!h(t,e))throw(n=new Error("'"+e+"' already exists.")).code="EEXIST",n;return r=v.dirname(e),u.existsSync(r)||l.makeTreeSync(r),u.renameSync(t,e)},removeSync:function(t){return y.sync(t)},remove:function(t,e){return y(t,e)},writeFileSync:function(t,e,n){return m.sync(v.dirname(t)),u.writeFileSync(t,e,n)},writeFile:function(t,e,n,r){return r=_.last(arguments),m(v.dirname(t),(function(i){return null!=i?"function"==typeof r?r(i):void 0:u.writeFile(t,e,n,r)}))},copy:function(t,e,n){return m(v.dirname(e),(function(r){var i,o;if(null==r)return(o=u.createReadStream(t)).on("error",(function(t){return"function"==typeof n&&n(t),n=null})),(i=u.createWriteStream(e)).on("error",(function(t){return"function"==typeof n&&n(t),n=null})),i.on("close",(function(){return"function"==typeof n&&n(),n=null})),o.pipe(i);"function"==typeof n&&n(r)}))},copySync:function(t,e){var n,r,i,o,s,a,c;for(o=u.readdirSync(t),m.sync(e),c=[],s=0,a=o.length;s0;)r=new Buffer(n),i=u.readSync(s,r,0,r.length,o),u.writeSync(a,r,0,i,o),c.push(o+=i);return c}finally{null!=s&&u.closeSync(s),null!=a&&u.closeSync(a)}},makeTreeSync:function(t){if(!l.isDirectorySync(t))return m.sync(t)},makeTree:function(t,e){return l.isDirectory(t,(function(n){return n?"function"==typeof e?e():void 0:m(t,(function(t){return"function"==typeof e?e(t):void 0}))}))},traverseTreeSync:function(t,e,n){var r;if(null==n&&(n=e),l.isDirectorySync(t))return(r=function(t,e,n){var i,o,s,a,c,l,f;for(c=0,l=(f=u.readdirSync(t)).length;c0},p=function(t,e,n){return u.stat(t,(function(r,i){if(!r)return u.stat(e,(function(r,o){if(!r||"ENOENT"!==r.code)return n(void 0,t.toLowerCase()===e.toLowerCase()&&i.dev===o.dev&&i.ino===o.ino);n(void 0,!0)}));n(r)}))},h=function(t,e){var n,r;return r=b(t),n=b(e),!r||!n||t.toLowerCase()===e.toLowerCase()&&r.dev===n.dev&&r.ino===n.ino},Kr=new Proxy({},{get:function(t,e){var n;return null!=(n=l[e])?n:u[e]},set:function(t,e,n){return l[e]=n}})}).call(Kr);class qa{constructor(t){this.props=t,this.model=atom.workspace.buildTextEditor({mini:!0,softWrapped:!0,lineNumberGutterVisible:!1}),this.element=atom.views.getView(this.model),this.model.setText(t.initialText),t.selectAll?this.model.selectAll():this.model.getLastCursor().moveToEndOfScreenLine(),this.setReadOnly(),this.setGrammar(),this.model.scrollToBufferPosition([0,0])}async update(t){this.element=atom.views.getView(this.model),this.props={...this.props,...t},this.setReadOnly(),this.setGrammar()}focus(){this.element.focus()}getModel(){return this.model}setReadOnly(){this.model.setReadOnly(!!this.props.readOnly)}setGrammar(){void 0!==this.props.grammar?atom.textEditors.setGrammarOverride(this.model,this.props.grammar):atom.textEditors.clearGrammarOverride(this.model)}}class Ha{constructor(t){this.props=t,ft.initialize(this)}async update(t){this.props={...this.props,...t},await ft.update(this)}render(){return ft.dom("div",{className:"atomts-rename-view",ref:"main"},ft.dom("div",{className:"block"},ft.dom("div",null,ft.dom("span",{ref:"title"},this.props.title),ft.dom("span",{className:"subtle-info-message"},ft.dom("span",null,"Close this panel with "),ft.dom("span",{className:"highlight"},"esc"),ft.dom("span",null," key. And commit with the "),ft.dom("span",{className:"highlight"},"enter"),ft.dom("span",null," key."))),ft.dom("div",{className:"find-container block"},ft.dom("div",{className:"editor-container"},ft.dom(qa,{ref:"editor",initialText:this.props.initialText,selectAll:this.props.selectAll}))),this.renderValidationMessage()))}async destroy(){await ft.destroy(this)}focus(){return this.refs.editor.focus()}getText(){return this.refs.editor.getModel().getText()}renderValidationMessage(){return void 0!==this.props.validationMessage?ft.dom("div",{className:"highlight-error"},this.props.validationMessage):null}}async function Ua(t){const e=new Ha({title:t.title,initialText:t.text,selectAll:t.autoSelect}),n=atom.workspace.addModalPanel({item:e,priority:1e3}),r=document.activeElement;e.focus();const i=new d;try{return await new Promise((n=>{i.add(atom.commands.add(e.refs.main,{"core:cancel":()=>{n(void 0)},"core:confirm":()=>{const r=e.getText(),i=t.onValidate(r);i?Kt(e.update({validationMessage:i})):n(r)}}))}))}finally{n.destroy(),i.dispose(),r&&r.focus()}}function $a(t){const e=new d;for(const n of Er)if("atom-text-editor"===n.selector){const r=n.desc(t);e.add(atom.commands.add(n.selector,n.command,{...r,async didDispatch(t){try{const e=t.currentTarget.getModel();ue(e)?await r.didDispatch(e,(()=>t.abortKeyBinding())):(t.abortKeyBinding(),le(e)&&atom.notifications.addWarning("Atom-TypeScript cancelled last command: Current editor has no file path",{description:`Atom-TypeScript needs to determine the file path of the current editor to execute \`${n.command}\`, which it failed to do. You probably just need to save the current file somewhere.`,dismissable:!0}))}catch(t){Va(t)}}}))}else{const r=n.desc(t);e.add(atom.commands.add(n.selector,n.command,{...r,async didDispatch(){try{await r.didDispatch()}catch(t){Va(t)}}}))}return e}function Va(t){atom.notifications.addFatalError("Something went wrong, see details below.",{detail:t.message,dismissable:!0,stack:t.stack})}Cr("atom-text-editor","typescript:rename-file",(t=>({description:"Rename current file",async didDispatch(e){const n=e.getPath();if(!n)return;const r=await Ua({autoSelect:!0,title:"Rename File",text:n,onValidate:t=>t.trim()?"":"If you want to abort : Press esc to exit"});if(!r)return;const i=await t.getClient(n),o=await i.execute("getEditsForFileRename",{oldFilePath:n,newFilePath:r});await t.applyEdits(o.body),await new Promise(((t,i)=>{Kr.move(n,r,(n=>{n?i(n):(e.getBuffer().setPath(r),t())}))}))}}))),Cr("atom-text-editor","typescript:rename-refactor",(t=>({description:"Rename symbol under text cursor everywhere it is used",async didDispatch(e){const n=he(e);if(!n)return;const r=await t.getClient(n.file),i=await r.execute("rename",n),{info:o,locs:s}=i.body;if(!o.canRename)return void atom.notifications.addInfo("AtomTS: Rename not available at cursor location");const a=await Ua({autoSelect:!0,title:"Rename Variable",text:o.displayName,onValidate:t=>t.replace(/\s/g,"")!==t.trim()?"The new variable must not contain a space":t.trim()?"":"If you want to abort : Press esc to exit"});void 0!==a&&await t.applyEdits(s.map((t=>({fileName:t.file,textChanges:t.locs.map((t=>({...t,newText:a})))}))))}}))),Cr("atom-workspace","typescript:restart-all-servers",(t=>({description:"Kill all tsserver instances. They will be auto-restarted",async didDispatch(){t.killAllServers()}}))),Cr("atom-workspace","typescript:return-from-declaration",(t=>({description:"If used `go-to-declaration`, return to previous text cursor position",async didDispatch(){await t.histGoBack()}}))),Cr("atom-workspace","typescript:show-editor-position-history",(t=>({description:"If used `go-to-declaration`, return to previous text cursor position",async didDispatch(){await t.histShowHistory()}}))),Cr("atom-text-editor","typescript:toggle-semantic-view",(t=>({description:"Toggle semantic view outline",didDispatch(){t.toggleSemanticViewController()}}))),Cr("atom-text-editor","typescript:show-tooltip",(t=>({description:"Show type tooltip at current text cursor position",didDispatch:async e=>t.showTooltipAt(e)}))),Cr("atom-text-editor","typescript:show-signature-help",(t=>({description:"Show signature help tooltip at current text cursor position",didDispatch:async e=>t.showSigHelpAt(e)}))),Cr("atom-text-editor","typescript:hide-signature-help",(t=>({description:"Hide the currently visible signature help",async didDispatch(e,n){t.hideSigHelpAt(e)||n()}}))),Cr("atom-text-editor","typescript:signature-help-next",(t=>({description:"Show next signature help if available",async didDispatch(e,n){t.rotateSigHelp(e,1)||n()}}))),Cr("atom-text-editor","typescript:signature-help-prev",(t=>({description:"Show previous signature help if available",async didDispatch(e,n){t.rotateSigHelp(e,-1)||n()}}))),Cr("atom-text-editor","typescript:toggle-file-symbols",(t=>({description:"Toggle view for finding file symbols",async didDispatch(e){t.toggleFileSymbolsView(e)}}))),Cr("atom-text-editor","typescript:toggle-project-symbols",(t=>({description:"Toggle view for finding file symbols",async didDispatch(e){t.toggleProjectSymbolsView(e)}})));class Wa{constructor(t,e){this.children=e,this.props={...t,delay:{show:0,hide:0}},ft.initialize(this),this.tooltipDisposable=atom.tooltips.add(this.element,this.props)}async update(t,e){this.props={...this.props,...t},this.children=e,await ft.update(this),this.tooltipDisposable.dispose(),this.tooltipDisposable=atom.tooltips.add(this.element,this.props)}render(){return ft.dom("div",{className:"inline-block"},this.children?this.children:null)}async destroy(){await ft.destroy(this),this.tooltipDisposable.dispose()}}class Ga{constructor(t){this.hiddenBuildStatus=!1,this.disposables=new d,this.buildStatusClicked=()=>{this.props.buildStatus.success||atom.notifications.addError("Build failed",{detail:this.props.buildStatus.message,dismissable:!0})},this.props={...t},this.setHideBuildStatus(atom.config.get("atom-typescript").buildStatusTimeout),this.resetBuildStatusTimeout(),ft.initialize(this),this.disposables.add(atom.config.onDidChange("atom-typescript.buildStatusTimeout",(({newValue:t})=>{this.setHideBuildStatus(t),Kt(this.update({}))})))}async update(t){const e=void 0!==t.buildStatus&&t.buildStatus.success!==this.props.buildStatus.success;this.props={...this.props,...t},e&&this.resetBuildStatusTimeout(),await ft.update(this)}render(){if(this.hiddenBuildStatus)return ft.dom("span",null);let t,e;return this.props.buildStatus.success?(t="highlight-success",e="Emit Success"):(t="highlight-error",e="Emit Failed"),ft.dom(Wa,{title:this.props.buildStatus.success?"Build was successful":"Build failed; click to show error message"},ft.dom("span",{className:t,on:{click:this.buildStatusClicked}},e))}async destroy(){await ft.destroy(this)}resetBuildStatusTimeout(){this.hiddenBuildStatus=!1,this.props.buildStatus.success&&this.hideBuildStatus()}setHideBuildStatus(t){this.hideBuildStatus=t>0?Qt.debounce((()=>{this.hiddenBuildStatus=!0,Kt(ft.update(this))}),1e3*t):0===t?()=>{this.hiddenBuildStatus=!0}:()=>{}}}class Ka{constructor(t){this.props={...t},ft.initialize(this)}async update(t){this.props={...this.props,...t},await ft.update(this)}render(){return ft.dom(Wa,{title:()=>this.props.tsConfigPath.startsWith("/dev/null")?"No tsconfig.json":"Click to open "+atom.project.relativize(this.props.tsConfigPath)},ft.dom("a",{className:"inline-block",href:"",on:{click:t=>{t.preventDefault(),this.openConfigPath()}}},this.props.tsConfigPath.startsWith("/dev/null")?"No project":b((t=this.props.tsConfigPath,"~"+atom.project.relativize(t)))));var t}async destroy(){await ft.destroy(this)}openConfigPath(){this.props.tsConfigPath.startsWith("/dev/null")?atom.notifications.addInfo("No tsconfig for current file"):Kt(atom.workspace.open(this.props.tsConfigPath))}}class Qa{constructor(t={}){this.props={visible:!0,pending:[],progress:{max:0,value:0},...t},ft.initialize(this)}async update(t){this.props={...this.props,...t},await ft.update(this)}render(){return ft.dom("ts-status-panel",{className:this.props.visible?"":"hide"},this.renderVersion(),this.renderPending(),this.renderConfigPath(),this.renderStatus(),this.renderProgress())}async destroy(){await ft.destroy(this)}dispose(){Kt(this.destroy())}async show(){await this.update({visible:!0})}async hide(){await this.update({visible:!1})}renderVersion(){return void 0!==this.props.clientVersion?ft.dom(Wa,{title:"Active TypeScript version"},this.props.clientVersion):null}renderPending(){return this.props.pending.length>0?ft.dom(Wa,{title:`Pending Requests:
    ${this.props.pending.map((({title:t})=>`
  • ${t}
  • `)).join("")}
`,html:!0},ft.dom("span",{ref:"pendingCounter"},this.props.pending.length.toString()),ft.dom("span",{ref:"pendingSpinner",className:"loading loading-spinner-tiny inline-block",style:{marginLeft:"5px",opacity:"0.5",verticalAlign:"sub"}})):null}renderConfigPath(){return void 0!==this.props.tsConfigPath?ft.dom(Ka,{tsConfigPath:this.props.tsConfigPath}):null}renderStatus(){return this.props.buildStatus?ft.dom(Ga,{buildStatus:this.props.buildStatus}):null}renderProgress(){return this.props.progress.value0;)e=this.prevCursorPositions.pop();if(e)return this.open({file:e.file,start:{line:e.line,offset:e.offset}});atom.notifications.addInfo("AtomTS: Previous position not found.")}async goForward(t,e){const n=he(t);if(n){this.prevCursorPositions.push(n);const t=100;this.prevCursorPositions.length>t&&this.prevCursorPositions.splice(0,this.prevCursorPositions.length-t)}return this.open(e)}async showHistory(){const t=await kr({items:this.getHistory().slice().reverse().map(((t,e)=>({...t,idx:e}))),itemTemplate:(t,e)=>ft.dom("li",{className:"two-lines"},ft.dom("div",{className:"primary-line"},ft.dom(gr,{label:t.file,query:e.getFilterQuery()})),ft.dom("div",{className:"secondary-line"},"Line: ",t.line,", column: ",t.offset)),itemFilterKey:"file"});t&&await this.goHistory(t.idx+1)}getHistory(){return this.prevCursorPositions}dispose(){}serialize(){return this.prevCursorPositions}async open(t){const e=await atom.workspace.open(t.file,{initialLine:t.start.line-1,initialColumn:t.start.offset-1,searchAllPanes:!0});return atom.workspace.isTextEditor(e)&&e.scrollToCursorPosition({center:!0}),e}}class Ja{constructor(t,e){let n,r,i;this.getClient=t,this.editor=e,this.disposables=new d,this.occurrenceMarkers=[],this.disposed=!1;let o=!1;this.disposables.add(atom.config.observe("atom-typescript.occurrenceHighlightDebounceTimeout",(t=>{n=Qt.debounce((()=>{Kt(this.update())}),t),i=3.5*t})),e.onDidChangeCursorPosition((()=>{void 0===r?n():o=!0})),e.onDidChangePath((()=>n())),e.onDidChangeGrammar((()=>n())),e.onDidChange((()=>{void 0!==r&&clearTimeout(r),r=window.setTimeout((()=>{o&&(n(),o=!1),r=void 0}),i)})))}dispose(){this.disposed||(this.disposed=!0,this.disposables.dispose(),this.clearMarkers())}clearMarkers(){for(const t of this.occurrenceMarkers)t.destroy();this.occurrenceMarkers=[]}async update(){if(this.disposed)return;if(!ue(this.editor))return void this.clearMarkers();const t=this.editor.getPath();if(void 0===t)return;const e=await this.getClient(t);if(this.disposed)return;const n=this.editor.getLastCursor().getBufferPosition();try{const r=await e.execute("documentHighlights",{file:t,line:n.row+1,offset:n.column+1,filesToSearch:[t]});if(this.disposed)return;const i=Array.from(this.getNewOccurrenceMarkers(r.body));for(const t of this.occurrenceMarkers)i.includes(t)||t.destroy();this.occurrenceMarkers=i}catch(t){window.atom_typescript_debug&&console.error(t)}}*getNewOccurrenceMarkers(t){for(const e of t)if(e.file===this.editor.getPath())for(const t of e.highlightSpans){const e=Xt(t),n=this.occurrenceMarkers.find((t=>t.getBufferRange().isEqual(e)));if(n)yield n;else{const t=this.editor.markBufferRange(e);this.editor.decorateMarker(t,{type:"highlight",class:"atom-typescript-occurrence"}),yield t}}}}class Ya{constructor(t){this.disposables=new d,this.disposables.add(atom.workspace.observeTextEditors((e=>{const n=new Ja(t,e);this.disposables.add(n,e.onDidDestroy((()=>{this.disposables.remove(n),n.dispose()})))})))}dispose(){this.disposables.dispose()}}function Xa(t,e,n,r){let i,o=n.right,s=!1,a="";t.style.left="",t.style.top="",t.style.right="",t.style.bottom="";const c=e.clientWidth,u=getComputedStyle(t),l=parseInt(u.width,10),f=parseInt(u.height,10);if(o+l>=c&&(o=c-l-10),o<0&&(a="pre-wrap",o=10,s=10),"bottom"===r){const t=e.clientHeight;i=n.bottom,i+f>=t&&(i=n.top-f)}else"top"===r&&(i=n.top-f,i<0&&(i=n.bottom));t.style.left=o+"px",t.style.top=i+"px",!1!==s&&(t.style.right=s+"px"),a&&(t.style.whiteSpace=a)}class tc{constructor(t){this.parent=t,this.props={left:0,right:0,top:0,bottom:0},ft.initialize(this)}async destroy(){return ft.destroy(this)}async update(t){var e,n,r;void 0!==(null===(e=t.sigHelp)||void 0===e?void 0:e.selectedItemIndex)&&(null===(n=t.sigHelp)||void 0===n?void 0:n.selectedItemIndex)!==(null===(r=this.props.sigHelp)||void 0===r?void 0:r.selectedItemIndex)&&(this.props.visibleItem=void 0),this.props={...this.props,...t},void 0===this.props.sigHelp?this.props.visibleItem=void 0:void 0!==this.props.visibleItem&&(this.props.visibleItem=this.props.visibleItem%this.props.sigHelp.items.length,this.props.visibleItem<0&&(this.props.visibleItem+=this.props.sigHelp.items.length)),await ft.update(this)}writeAfterUpdate(){Xa(this.element,this.parent,this.props,atom.config.get("atom-typescript").sigHelpPosition)}render(){return ft.dom("div",{className:"atom-typescript-tooltip tooltip",key:this.sigHelpHash()},ft.dom("div",{className:"tooltip-inner"},this.tooltipContents()))}sigHelpHash(){if(!this.props.sigHelp)return;const{start:t,end:e}=this.props.sigHelp.applicableSpan;return`${t.line}:${t.offset}-${e.line}:${e.offset}`}tooltipContents(){if(!this.props.sigHelp)return"…";const{sigHelp:t}=this.props,e=void 0!==this.props.visibleItem?this.props.visibleItem:t.selectedItemIndex,n=t.items.length,r=["atom-typescript-tooltip-signature-help"];function i(n){const i=[];return n===t.selectedItemIndex&&i.push("atom-typescript-tooltip-signature-help-selected"),n===e&&i.push("atom-typescript-tooltip-signature-help-visible"),[...r,...i].join(" ")}return n>1&&r.push("atom-typescript-tooltip-signature-help-changable"),t.items.map(((e,n)=>ft.dom("div",{className:i(n)},ft.dom("div",null,oe(e.prefixDisplayParts),this.renderSigHelpParams(e.parameters,t.argumentIndex),oe(e.suffixDisplayParts),ft.dom("div",{className:"atom-typescript-tooltip-signature-help-documentation"},oe(e.documentation))))))}renderSigHelpParams(t,e){return t.map(((t,n)=>ft.dom("span",{className:"atom-typescript-tooltip-signature-help-parameter"},n>0?", ":null,ft.dom("span",{className:n===e?"atom-typescript-tooltip-signature-help-selected":void 0},oe(t.displayParts)))))}}class ec{constructor(t,e,n){this.deps=t,this.editor=e,this.cancelled=!1,this.disposables=new h.CompositeDisposable;const r=atom.views.getView(this.editor);this.view=new tc(r),r.appendChild(this.view.element);const i=Qt.debounce(this.updateTooltip.bind(this),100,{leading:!0});this.disposables.add(this.editor.onDidChangeCursorPosition((t=>{n=t.newBufferPosition,Kt(i(n))})),r.onDidChangeScrollTop((()=>{setImmediate((()=>this.updateTooltipPosition(n)))})),r.onDidChangeScrollLeft((()=>{setImmediate((()=>this.updateTooltipPosition(n)))}))),Kt(this.updateTooltip(n))}isDisposed(){return this.cancelled}dispose(){this.cancelled||(this.cancelled=!0,this.disposables.dispose(),Kt(this.view.destroy()))}async rotateSigHelp(t){const{visibleItem:e,sigHelp:n}=this.view.props,r=void 0!==e?e:void 0!==(null==n?void 0:n.selectedItemIndex)?null==n?void 0:n.selectedItemIndex:0;await this.view.update({visibleItem:r+t})}async updateTooltip(t){if(this.cancelled)return;let e;try{e=this.computeTooltipPosition(t)}catch(t){return void console.warn(t)}const n=await this.getMessage(t);this.cancelled||(n?await this.view.update({...e,sigHelp:n}):this.dispose())}updateTooltipPosition(t){if(this.cancelled)return;const e=this.computeTooltipPosition(t);Kt(this.view.update({...e}))}computeTooltipPosition(t){const e=atom.views.getView(this.editor),n=e.pixelPositionForBufferPosition(t),r=e.querySelector(".lines").getBoundingClientRect(),i=this.editor.getLineHeightInPixels(),o=e.getBoundingClientRect(),s=n.top+r.top-o.top+i/2,a=n.left+r.left-o.left,c=.7*i;return{left:a,right:a,top:s-c,bottom:s+c}}async getMessage(t){if(!ue(this.editor))return;const e=this.editor.getPath();if(void 0===e)return;const n=await this.deps.getClient(e);try{return(await n.execute("signatureHelp",{file:e,line:t.row+1,offset:t.column+1})).body}catch(t){return}}}class nc{constructor(t){this.deps=t,this.subscriptions=new h.CompositeDisposable,this.editorMap=new WeakMap,this.stoppedChanging=t=>e=>{if(!atom.config.get("atom-typescript.sigHelpDisplayOnChange"))return;if(void 0===t.getPath())return;const n=t.getLastCursor().getBufferPosition(),[r]=e.changes.filter((t=>t.newRange.containsPoint(n)));r&&null!==r.newText.match(/[<(,]/)&&Kt(this.showTooltip(t,n))},this.subscriptions.add(atom.workspace.observeTextEditors((t=>{const e=new h.CompositeDisposable;e.add(t.onDidDestroy((()=>{e.dispose(),this.subscriptions.remove(e);const n=this.editorMap.get(t);n&&n.dispose()})),t.onDidStopChanging(this.stoppedChanging(t))),this.subscriptions.add(e)})))}dispose(){this.subscriptions.dispose();for(const t of atom.workspace.getTextEditors()){const e=this.editorMap.get(t);e&&e.dispose()}}async showTooltipAt(t){const e=t.getLastCursor().getBufferPosition();return this.showTooltip(t,e)}rotateSigHelp(t,e){const n=this.editorMap.get(t);return!(!n||n.isDisposed())&&(Kt(n.rotateSigHelp(e)),!0)}hideTooltipAt(t){const e=this.editorMap.get(t);return!(!e||e.isDisposed())&&(e.dispose(),!0)}async showTooltip(t,e){const n=this.editorMap.get(t);n&&!n.isDisposed()||this.editorMap.set(t,new ec(this.deps,t,e))}}function rc(t,e,n,r){const i=e=>{const i=e.target.closest(n);i&&t.contains(i)&&r(e)};return t.addEventListener(e,i),new v((()=>{t.removeEventListener(e,i)}))}class ic{constructor(){this.tooltip=null,this.props={left:0,right:0,top:0,bottom:0},ft.initialize(this)}async destroy(){return ft.destroy(this)}async update(t){this.props={...this.props,...t},this.tooltip=await Gn(this.props.info,ft,(t=>ft.dom("div",{className:"atom-typescript-tooltip-tooltip-code"},t))),await ft.update(this)}writeAfterUpdate(){Xa(this.element,document.body,this.props,atom.config.get("atom-typescript").tooltipPosition)}render(){return ft.dom("div",{className:"atom-typescript-tooltip tooltip"},ft.dom("div",{className:"tooltip-inner"},this.tooltip))}}class oc{constructor(t,e,n,r){this.getClient=t,this.cancelled=!1,Kt(this.initialize(e,n,r))}dispose(){this.cancelled=!0,this.view&&(Kt(this.view.destroy()),this.view=void 0)}async initialize(t,e,n){const r=atom.views.getView(t);let i,o;try{i=r.pixelPositionForBufferPosition(n),o=r.pixelPositionForBufferPosition(n.traverse([0,1]))}catch(e){return void console.warn(e)}if(i.left>=o.left)return;const s=.7*t.getLineHeightInPixels(),a={left:e.clientX,right:e.clientX,top:e.clientY-s,bottom:e.clientY+s},c=await this.getMessage(t,n);this.cancelled||void 0!==c&&await this.showTooltip(a,c)}async getMessage(t,e){let n;const r=await this.getClient(t);if(!r)return;const i=t.getPath();try{if(void 0===i)return;n=await r.execute("quickinfo",{file:i,line:e.row+1,offset:e.column+1})}catch(t){return}return n.body}async showTooltip(t,e){this.view=new ic,document.body.appendChild(this.view.element),await this.view.update({...t,info:e})}}class sc{constructor(t){this.getClientInternal=t,this.subscriptions=new h.CompositeDisposable,this.editorMap=new WeakMap,this.getClient=async t=>{const e=t.getPath();if(void 0!==e&&ue(t)&&S.existsSync(e))return this.getClientInternal(e)},this.clearExprTypeTimeout=()=>{void 0!==this.exprTypeTimeout&&(clearTimeout(this.exprTypeTimeout),this.exprTypeTimeout=void 0),this.hideExpressionType()},this.trackMouseMovement=t=>{let e;return n=>{const r=function(t,e){const n=atom.views.getView(t).getComponent().screenPositionForMouseEvent(e);if(!isNaN(n.row)&&!isNaN(n.column))return t.bufferPositionForScreenPosition(n)}(t,n);r&&(e&&e.isEqual(r)&&this.pendingTooltip||(e=r,this.clearExprTypeTimeout(),this.exprTypeTimeout=window.setTimeout((()=>this.showExpressionType(t,n,r)),atom.config.get("atom-typescript").tooltipDelay)))}},this.subscriptions.add(atom.workspace.observeTextEditors((t=>{const e=atom.views.getView(t),n=e.querySelector(".lines");this.editorMap.set(t,{rawView:e,lines:n});const r=new h.CompositeDisposable;r.add(rc(e,"mousemove",".scroll-view",this.trackMouseMovement(t)),rc(e,"mouseout",".scroll-view",this.clearExprTypeTimeout),rc(e,"keydown",".scroll-view",this.clearExprTypeTimeout),e.onDidChangeScrollTop(this.clearExprTypeTimeout),e.onDidChangeScrollLeft(this.clearExprTypeTimeout),t.onDidDestroy((()=>{r.dispose(),this.subscriptions.remove(r),this.clearExprTypeTimeout()}))),this.subscriptions.add(r)})))}dispose(){this.subscriptions.dispose(),this.clearExprTypeTimeout()}showExpressionAt(t){const e=t.getLastCursor().getBufferPosition(),n=atom.views.getView(t);let r;try{r=n.pixelPositionForBufferPosition(e)}catch(t){return void console.warn(t)}this.showExpressionType(t,this.mousePositionForPixelPosition(t,r),e)}mousePositionForPixelPosition(t,e){const n=atom.views.getView(t).querySelector(".lines").getBoundingClientRect();return{clientY:e.top+n.top+t.getLineHeightInPixels()/2,clientX:e.left+n.left}}showExpressionType(t,e,n){this.pendingTooltip&&this.pendingTooltip.dispose(),this.pendingTooltip=new oc(this.getClient,t,e,n)}hideExpressionType(){this.pendingTooltip&&(this.pendingTooltip.dispose(),this.pendingTooltip=void 0)}}class ac{constructor(t){this.getClient=t,this.subscriptions=new d;const e=atom.workspace.paneForURI("atom-typescript://semantic-view");e&&(this.view=e.itemForURI("atom-typescript://semantic-view")),this.view&&Kt(this.view.setGetClient(this.getClient)),this.subscriptions.add(new v((()=>{this.view&&(atom.workspace.hide(this.view),Kt(this.view.destroy()))})),atom.config.observe("atom-typescript.showSemanticView",(t=>{t?Kt(this.show()):this.hide()})))}dispose(){this.subscriptions.dispose()}async toggle(){this.view?await atom.workspace.toggle(this.view):await this.show()}async show(){this.view||(this.view=Se.create({navTree:null}),await this.view.setGetClient(this.getClient)),await atom.workspace.open(this.view,{searchAllPanes:!0})}hide(){return!!this.view&&atom.workspace.hide(this.view)}}class cc{constructor(t){this.position=t.position,this.name=t.name,this.type=t.type,this.parent=t.parent,this.file=t.file}static fromNavTree(t,e){const n=t.spans[0].start;return new cc({name:t.text,type:t.kind,position:{row:n.line-1,column:n.offset-1},parent:null!=e?e:null})}static fromNavto(t,e){const n=t.start;return new cc({name:t.name,type:t.kind,position:{row:n.line-1,column:n.offset-1},parent:null!=e?e:null,file:t.file})}}async function uc(t,e){const n=await async function(t,e){try{const n=await e.getClient(t);return(await n.execute("navtree",{file:t})).body}catch(e){console.error(t,e)}}(t,e);return n&&n.childItems?Array.from(fc(n.childItems)):[]}async function lc(t,e,n){const r=await async function(t,e,n){try{const r=await n.getClient(t);return(await r.execute("navto",{file:t,currentFileOnly:!1,searchValue:e,maxResultCount:1e3})).body}catch(e){console.error(t,e)}}(t,e,n);return r?Array.from(function*(t,e){for(const n of t)yield cc.fromNavto(n,e)}(r)):[]}function*fc(t,e){t.sort(((t,e)=>t.spans[0].start.line-e.spans[0].start.line));for(const n of t){const t=cc.fromNavTree(n,e);yield t,n.childItems&&(yield*fc(n.childItems,t))}}async function pc(t,e,n){if(void 0!==t.file)return n(e,{file:t.file,start:{line:t.position.row+1,offset:t.position.column+1}})}async function hc(t,e){const n=t.getPath();if(void 0!==n){let r;atom.config.get("symbols-view.quickJumpToFileSymbol")&&(r=function(t){const e=atom.views.getView(t).getScrollTop();return{bufferRanges:t.getSelectedBufferRanges(),scrollTop:e}}(t));const i=await kr({items:uc(n,e),itemTemplate:({name:t,position:e},n)=>ft.dom("li",{className:"two-lines"},ft.dom("div",{className:"primary-line"},ft.dom(gr,{label:t,query:n.getFilterQuery()})),ft.dom("div",{className:"secondary-line"},"Line "+(e.row+1))),didChangeSelection(e){atom.config.get("symbols-view.quickJumpToFileSymbol")&&e&&t.setCursorBufferPosition(e.position)},itemFilterKey:"name"});i?await pc(i,t,e.histGoForward):r&&function(t,{bufferRanges:e,scrollTop:n}){const r=atom.views.getView(t);t.setSelectedBufferRanges(e),r.setScrollTop(n)}(t,r)}}class dc{constructor(t){this.deps=t}toggleFileView(t){Kt(hc(t,this.deps))}toggleProjectView(t){Kt(async function(t,e){const n=t.getPath();if(void 0!==n){const r=await kr({items:t=>lc(n,t,e),itemTemplate({name:t,position:e,file:n},r){const i=atom.project.relativize(n);return ft.dom("li",{className:"two-lines"},ft.dom("div",{className:"primary-line"},ft.dom(gr,{label:t,query:r.getFilterQuery()})),ft.dom("div",{className:"secondary-line"},`File ${i} line ${e.row+1}`))},itemFilterKey:"name"});r&&await pc(r,t,e.histGoForward)}}(t,this.deps))}dispose(){}}class gc{constructor(){this.errors=new Map,this.fileGrammars=new Map,this.pushErrors=Qt.debounce(this.pushErrors.bind(this),100)}*getErrorsInRange(t,e){for(const n of this.errors.values()){const r=n.get(w.normalize(t));r&&(yield*r.filter((t=>Xt(t).intersectsWith(e))))}}*getErrorsAt(t,e){for(const n of this.errors.values()){const r=n.get(w.normalize(t));r&&(yield*r.filter((t=>Xt(t).containsPoint(e))))}}setErrors(t,e,n){let r=this.errors.get(t);r||(r=new Map,this.errors.set(t,r)),r.set(w.normalize(e),n),this.pushErrors()}clearFileErrors(t){for(const e of this.errors.values())e.delete(t);this.pushErrors()}clear(){this.linter&&this.linter.clearMessages()}setLinter(t){this.linter=t,this.pushErrors()}dispose(){this.clear(),this.linter&&this.linter.dispose(),this.linter=void 0}pushErrors(){this.linter&&this.linter.setAllMessages(this.getLinterErrors())}getLinterErrors(){if(atom.config.get("atom-typescript.suppressAllDiagnostics"))return[];const t=[];for(const e of this.errors.values())for(const[n,r]of e){const e=atom.workspace.getTextEditors().find((t=>t.getPath()===n)),i=e?e.getGrammar().scopeName:this.selectGrammar(n);if(!mc("suppressAllDiagnostics",i))for(const e of r){if(mc("ignoredDiagnosticCodes",i).includes(""+e.code))continue;if(mc("ignoreUnusedSuggestionDiagnostics",i)&&e.reportsUnnecessary)continue;if("suggestion"===e.category&&mc("ignoredSuggestionDiagnostics",i).includes(""+e.code))continue;if(mc("ignoreNonSuggestionSuggestionDiagnostics",i)&&"suggestion"===e.category&&!se(e.code,Zt.Suggestion))continue;let{start:r,end:o}=e;r&&o||(r=o={line:1,offset:1}),t.push({severity:this.getSeverity(mc("unusedAsInfo",i),e),excerpt:e.text,location:{file:n,position:te(r,o)}})}}return t}selectGrammar(t){const e=this.fileGrammars.get(t);if(void 0!==e)return e;const n=atom.grammars.selectGrammar(t,"").scopeName;return this.fileGrammars.set(t,n),n}getSeverity(t,e){if(t&&6133===e.code)return"info";switch(e.category){case"error":return"error";case"warning":return"warning";default:return"info"}}}function mc(t,e){return atom.config.get("atom-typescript."+t,{scope:[e]})}class vc{constructor(t,e){let n;this.buffer=t,this.deps=e,this.events=new h.Emitter,this.compileOnSave=!1,this.subscriptions=new h.CompositeDisposable,this.on=this.events.on.bind(this.events),this.dispose=()=>{this.subscriptions.dispose(),Kt(this.close())},this.init=async()=>{this.state&&(await this.state.client.execute("open",{file:this.state.filePath,fileContent:this.buffer.getText()}),Kt(this.getErr({allFiles:!1,delay:0})))},this.close=async()=>{if(await this.openPromise,this.state){const t=this.state.client,e=this.state.filePath;this.deps.clearFileErrors(e),this.state.subscriptions.dispose(),this.state=void 0,await t.execute("close",{file:e})}},this.onDidChangePath=t=>{Kt(this.close().then((()=>{this.openPromise=this.open(t)})))},this.onDidSave=async()=>{await Promise.all([this.getErr({allFiles:!0,delay:100}),this.doCompileOnSave()])},this.onDidChangeText=async({changes:t})=>{if(0===t.length||!this.state)return;const{client:e,filePath:n}=this.state;await Promise.all(t.reduceRight(((t,{oldRange:r,newText:i})=>(t.push(e.execute("change",{file:n,line:r.start.row+1,offset:r.start.column+1,endLine:r.end.row+1,endOffset:r.end.column+1,insertString:i})),t)),[]))},this.subscriptions.add(atom.config.observe("atom-typescript.getErrDebounceTimeout",(t=>{n=Qt.debounce((()=>{Kt(this.getErr({allFiles:!1,delay:0}))}),t)})),t.onDidChangePath(this.onDidChangePath),t.onDidDestroy(this.dispose),t.onDidSave((()=>{Kt(this.onDidSave())})),t.onDidStopChanging((({changes:t})=>{t.length>0&&this.deps.reportBuildStatus(void 0)})),t.onDidChangeText((t=>{Kt(this.onDidChangeText(t)),n()}))),this.openPromise=this.open(this.buffer.getPath())}static create(t,e){const n=vc.bufferMap.get(t);if(n)return n;{const n=new vc(t,e);return vc.bufferMap.set(t,n),n}}getPath(){return this.state&&this.state.filePath}getInfo(){if(this.state)return{clientVersion:this.state.client.version,tsConfigPath:this.state.configFile&&this.state.configFile.getPath()}}async getErr(t){if(!this.state)return;const e=t.allFiles?Array.from(function*(){for(const t of atom.workspace.getTextEditors())ue(t)&&(yield t.getPath())}()):[this.state.filePath];await this.state.client.execute("geterr",{files:e,delay:t.delay})}async compile(){if(!this.state)return;const{client:t,filePath:e}=this.state,n=await t.execute("compileOnSaveAffectedFileList",{file:e}),r=Qt.flatten(n.body.map((t=>t.fileNames)));if(0===r.length)return;const i=r.map((e=>t.execute("compileOnSaveEmitFile",{file:e})));if(!(await Promise.all(i)).every((t=>!!t.body)))throw new Error("Some files failed to emit")}async doCompileOnSave(){if(this.compileOnSave){this.deps.reportBuildStatus(void 0);try{await this.compile(),this.deps.reportBuildStatus({success:!0})}catch(t){const e=t;console.error("Save failed with error",e),this.deps.reportBuildStatus({success:!1,message:e.message})}}}async open(t){if(void 0===t||!ae(t))return this.close();{const e=await this.deps.getClient(t);this.state={client:e,filePath:t,configFile:void 0,subscriptions:new h.CompositeDisposable},this.state.subscriptions.add(e.on("restarted",(()=>Kt(this.init())))),await this.init();const n=await e.execute("projectInfo",{needFileNameList:!1,file:t});void 0!==n.body.configFileName&&(this.state.configFile=new h.File(n.body.configFileName),await this.readConfigFile(),this.state.subscriptions.add(this.state.configFile.onDidChange((()=>Kt(this.readConfigFile()))))),this.events.emit("opened")}}async readConfigFile(){if(!this.state||!this.state.configFile)return;const t=ee(this.state.configFile.getPath());this.compileOnSave=t.compileOnSave;const e=atom.config.get("atom-typescript");await this.state.client.execute("configure",{file:this.state.filePath,formatOptions:t.formatCodeOptions,preferences:{includeCompletionsWithInsertText:!0,includeCompletionsForModuleExports:e.includeCompletionsForModuleExports,quotePreference:e.quotePreference,importModuleSpecifierEnding:e.importModuleSpecifierEnding,importModuleSpecifierPreference:"auto"===e.importModuleSpecifierPreference?void 0:e.importModuleSpecifierPreference,...t.preferences}})}}vc.bufferMap=new WeakMap;class yc{constructor(t,e){this.editor=t,this.opts=e,this.subscriptions=new d,this.isTypescript=!1,this.destroy=()=>{atom.views.getView(this.editor).classList.remove("typescript-editor"),this.subscriptions.dispose()},this.didActivate=()=>{this.isTypescript&&this.reportInfo()},this.onOpened=()=>{atom.workspace.getActiveTextEditor()===this.editor&&this.reportInfo()},this.checkIfTypescript=()=>{this.isTypescript=ue(this.editor),this.isTypescript?atom.views.getView(this.editor).classList.add("typescript-editor"):atom.views.getView(this.editor).classList.remove("typescript-editor")},this.buffer=vc.create(t.getBuffer(),e),this.subscriptions.add(this.buffer.on("opened",this.onOpened)),this.checkIfTypescript(),this.subscriptions.add(t.onDidChangePath(this.checkIfTypescript),t.onDidChangeGrammar(this.checkIfTypescript),t.onDidDestroy(this.destroy),t.onDidSave((()=>{atom.config.get("atom-typescript.checkAllFilesOnSave")&&atom.commands.dispatch(atom.views.getView(t),"typescript:check-all-files")})))}static createFactory(t){return e=>{let n=yc.editorMap.get(e);return n||(n=new yc(e,t),yc.editorMap.set(e,n)),n}}static lookupPane(t){return yc.editorMap.get(t)}reportInfo(){const t=this.buffer.getInfo();t&&this.opts.reportClientInfo(t)}}yc.editorMap=new WeakMap;class wc{constructor(t){this.usingBuiltinTooltipManager=!0,this.usingBuiltinSigHelpManager=!0,this.pending=new Set,this.clearErrors=()=>{this.errorPusher.clear()},this.clearFileErrors=t=>{this.errorPusher.clearFileErrors(t)},this.getClient=async t=>this.clientResolver.get(t),this.killAllServers=()=>{Kt(this.clientResolver.restartAllServers())},this.withBuffer=async(t,e)=>{const n=w.normalize(t),r=atom.workspace.getTextEditors().find((t=>t.getPath()===n));if(r)return e(r.getBuffer());const i=await h.TextBuffer.load(n);try{return await e(i)}finally{i.isModified()&&await i.save(),i.destroy()}},this.reportBusyWhile=async(t,e)=>{if(this.busySignalService)return this.busySignalService.reportBusyWhile(t,e);{const n={title:t};try{return this.pending.add(n),this.drawPending(Array.from(this.pending)),await e()}finally{this.pending.delete(n),this.drawPending(Array.from(this.pending))}}},this.reportProgress=t=>{Kt(this.statusPanel.update({progress:t}))},this.reportBuildStatus=t=>{Kt(this.statusPanel.update({buildStatus:t}))},this.reportClientInfo=t=>{Kt(this.statusPanel.update(t))},this.applyEdits=async t=>{Promise.all(t.map((t=>this.withBuffer(t.fileName,(async e=>{e.transact((()=>{const n=t.textChanges.map((t=>({range:Xt(t),newText:t.newText}))).reverse().sort(((t,e)=>e.range.compare(t.range)));for(const t of n)e.setTextInRange(t.range,t.newText)}))})))))},this.showTooltipAt=async t=>{this.usingBuiltinTooltipManager?this.tooltipManager.showExpressionAt(t):await atom.commands.dispatch(atom.views.getView(t),"datatip:toggle")},this.showSigHelpAt=async t=>{this.usingBuiltinSigHelpManager?await this.sigHelpManager.showTooltipAt(t):await atom.commands.dispatch(atom.views.getView(t),"signature-help:show")},this.hideSigHelpAt=t=>!!this.usingBuiltinSigHelpManager&&this.sigHelpManager.hideTooltipAt(t),this.rotateSigHelp=(t,e)=>!!this.usingBuiltinSigHelpManager&&this.sigHelpManager.rotateSigHelp(t,e),this.histGoForward=(t,e)=>this.editorPosHist.goForward(t,e),this.drawPending=Qt.throttle((t=>Kt(this.statusPanel.update({pending:t}))),100,{leading:!1}),this.subscriptions=new d,this.clientResolver=new Vn(this.reportBusyWhile),this.subscriptions.add(this.clientResolver),this.statusPanel=new Qa,this.subscriptions.add(this.statusPanel),this.errorPusher=new gc,this.subscriptions.add(this.errorPusher),this.codefixProvider=new $r(this.clientResolver,this.errorPusher,this.applyEdits),this.subscriptions.add(this.codefixProvider),this.semanticViewController=new ac(this.getClient),this.subscriptions.add(this.semanticViewController),this.editorPosHist=new Za(t&&t.editorPosHistState),this.subscriptions.add(this.editorPosHist),this.symbolsViewController=new dc({histGoForward:this.histGoForward,getClient:this.getClient}),this.subscriptions.add(this.symbolsViewController),this.tooltipManager=new sc(this.getClient),this.subscriptions.add(this.tooltipManager),this.sigHelpManager=new nc({getClient:this.getClient}),this.subscriptions.add(this.sigHelpManager),this.occurrenceManager=new Ya(this.getClient),this.subscriptions.add(this.occurrenceManager),this.typescriptPaneFactory=yc.createFactory({clearFileErrors:this.clearFileErrors,getClient:this.getClient,reportBuildStatus:this.reportBuildStatus,reportClientInfo:this.reportClientInfo}),this.subscribeEditors(),this.subscriptions.add($a({getClient:this.getClient,applyEdits:this.applyEdits,clearErrors:this.clearErrors,killAllServers:this.killAllServers,reportProgress:this.reportProgress,reportBuildStatus:this.reportBuildStatus,toggleSemanticViewController:()=>{Kt(this.semanticViewController.toggle())},toggleFileSymbolsView:t=>{this.symbolsViewController.toggleFileView(t)},toggleProjectSymbolsView:t=>{this.symbolsViewController.toggleProjectView(t)},histGoForward:this.histGoForward,histGoBack:()=>this.editorPosHist.goBack(),histShowHistory:()=>this.editorPosHist.showHistory(),showTooltipAt:this.showTooltipAt,showSigHelpAt:this.showSigHelpAt,hideSigHelpAt:this.hideSigHelpAt,rotateSigHelp:this.rotateSigHelp}))}destroy(){this.subscriptions.dispose();for(const t of atom.workspace.getTextEditors()){const e=yc.lookupPane(t);e&&e.destroy()}}serialize(){return{version:"0.1",editorPosHistState:this.editorPosHist.serialize()}}consumeLinter(t){const e=t({name:"TypeScript"});this.errorPusher.setLinter(e),this.subscriptions.add(this.clientResolver.on("diagnostics",(({type:t,filePath:e,diagnostics:n})=>{this.errorPusher.setErrors(t,e,n)})))}consumeStatusBar(t){let e=100;for(const n of t.getRightTiles())"GRAMMAR-SELECTOR-STATUS"===atom.views.getView(n.getItem()).tagName&&(e=n.getPriority()-1);const n=t.addRightTile({item:this.statusPanel,priority:e}),r=new h.Disposable((()=>{n.destroy()}));return this.subscriptions.add(r),r}consumeDatatipService(t){if(atom.config.get("atom-typescript").preferBuiltinTooltips)return;const e=t.addProvider(new Zn(this.getClient));return this.subscriptions.add(e),this.tooltipManager.dispose(),this.usingBuiltinTooltipManager=!1,e}consumeSigHelpService(t){if(atom.config.get("atom-typescript").preferBuiltinSigHelp)return;const e=new jr(this.getClient),n=t(e);return this.subscriptions.add(n,e),this.sigHelpManager.dispose(),this.usingBuiltinSigHelpManager=!1,n}consumeBusySignal(t){if(atom.config.get("atom-typescript").preferBuiltinBusySignal)return;this.busySignalService=t;const e={dispose:()=>{this.busySignalService&&this.busySignalService.dispose(),this.busySignalService=void 0}};return this.subscriptions.add(e),e}provideAutocomplete(){return[new Dr(this.getClient,this.applyEdits)]}provideIntentions(){return t=this.codefixProvider,{grammarScopes:["*"],getIntentions:async({bufferPosition:e,textEditor:n})=>(await t.runCodeFix(n,e)).map((e=>({priority:100,title:"description"in e?e.description:e.actionDescription,selected:()=>{Kt(t.applyFix(e))}})))};var t}provideIntentionsHighlight(){return t=this.codefixProvider,{grammarScopes:["*"],getIntentions:async({visibleRange:e,textEditor:n})=>(await t.getFixableRanges(n,e)).map((t=>({range:t,created:t=>{}})))};var t}provideCodeActions(){return t=this.codefixProvider,{grammarScopes:ce(),priority:0,getCodeActions:async(e,n)=>(await t.runCodeFix(e,n.start)).map((e=>({getTitle:async()=>"description"in e?e.description:e.actionDescription,dispose:()=>{},apply:async()=>{await t.applyFix(e)}})))};var t}provideHyperclick(){return t=this.getClient,e=this.histGoForward,{priority:0,providerName:"typescript-hyperclick-provider",wordRegExp:/([A-Za-z0-9_])+|['"`](\\.|[^'"`\\\\])*['"`]/g,async getSuggestionForWord(n,r,i){if(!ue(n))return;const o=n.getPath();return void 0!==o?{range:i,callback:async()=>{var r;const s={file:o,line:i.start.row+1,offset:i.start.column+1},a=await t(s.file),c=await a.execute("definition",s),u=c.body?c.body[0]:void 0;if(1===(null===(r=c.body)||void 0===r?void 0:r.length)&&(null==u?void 0:u.start.line)===s.line&&(null==u?void 0:u.start.offset)===s.offset){const t=await a.execute("references",s);await Tr(t,n,e)}else await Ar(c,n,e)}}:void 0}};var t,e}provideReferences(){return t=this.getClient,{isEditorSupported:async t=>ue(t),async findReferences(e,n){const r=he(e,n);if(!r)return;const i=await t(r.file),o=await i.execute("references",r);return o.body?{type:"data",baseUri:r.file,referencedSymbolName:o.body.symbolDisplayString,references:o.body.refs.map(Xn)}:void 0}};var t}provideOutlines(){return t=this.getClient,{name:"Atom-TypeScript",grammarScopes:ce(),priority:100,updateOnEdit:!0,async getOutline(e){const n=e.getPath();if(void 0===n)return;const r=await t(n),i=(await r.execute("navtree",{file:n})).body;return i?{outlineTrees:[Pr(i)]}:void 0}};var t}provideDefinitions(){var t;if(!atom.config.get("atom-typescript").disableAtomIdeDefinitions)return t=this.getClient,{name:"atom-typescript",priority:0,grammarScopes:ce(),wordRegExp:/([A-Za-z0-9_])+|['"`](\\.|[^'"`\\\\])*['"`]/g,async getDefinition(e,n){if(!ue(e))return;const r=he(e,n);if(!r)return;const i=await t(r.file),o=await i.execute("definition",r);return o.body&&0!==o.body.length?{queryRange:void 0,definitions:o.body.map(Yn)}:void 0}}}provideCodeHighlight(){if(!atom.config.get("atom-typescript").preferBuiltinOccurrenceHighlight)return this.occurrenceManager.dispose(),Wn(this.getClient)}subscribeEditors(){this.subscriptions.add(atom.workspace.observeTextEditors((t=>{this.typescriptPaneFactory(t)})),atom.workspace.onDidChangeActiveTextEditor((t=>{if(t&&ue(t)){Kt(this.statusPanel.show());const e=yc.lookupPane(t);e&&e.didActivate()}else Kt(this.statusPanel.hide())})))}}let bc;var _c=C(ft);exports.activate=function(t){_c.setScheduler(atom.views),bc=new wc(t),setImmediate((()=>Kt(async function(){["atom-ide-ui","linter","nuclide"].some((t=>atom.packages.isPackageLoaded(t)))||await A.install("atom-typescript",!0)}())))},exports.deactivate=function(){bc&&bc.destroy(),bc=void 0},exports.serialize=function(){return bc?bc.serialize():void 0},exports.deserializeSemanticView=function(t){return Se.create(t.data)},exports.consumeLinter=function(t){if(bc)return bc.consumeLinter(t)},exports.consumeStatusBar=function(t){if(bc)return bc.consumeStatusBar(t)},exports.consumeDatatipService=function(t){if(bc)return bc.consumeDatatipService(t)},exports.consumeSignatureHelp=function(t){if(bc)return bc.consumeSigHelpService(t)},exports.consumeBusySignal=function(t){if(bc)return bc.consumeBusySignal(t)},exports.provideAutocomplete=function(){if(bc)return bc.provideAutocomplete()},exports.provideIntentions=function(){if(bc)return bc.provideIntentions()},exports.provideIntentionsHighlight=function(){if(bc)return bc.provideIntentionsHighlight()},exports.provideCodeActions=function(){if(bc)return bc.provideCodeActions()},exports.provideHyperclick=function(){if(bc)return bc.provideHyperclick()},exports.provideReferences=function(){if(bc)return bc.provideReferences()},exports.provideOutlines=function(){if(bc)return bc.provideOutlines()},exports.provideDefinitions=function(){if(bc)return bc.provideDefinitions()},exports.provideCodeHighlight=function(){if(bc)return bc.provideCodeHighlight()}; //# sourceMappingURL=main.js.map diff --git a/dist/main.js.map b/dist/main.js.map index 27e58b1ad..6d16c5d3d 100644 --- a/dist/main.js.map +++ b/dist/main.js.map @@ -1 +1 @@ -{"mappings":"IAQgCA,EAAMC,8MAAND,KAAMC,IACpCC,OAAOC,KAAKF,GAAQG,SAAQ,SAASC,GACvB,YAARA,GAA6B,eAARA,GAIzBH,OAAOI,eAAeN,EAAMK,EAAK,CAC/BE,YAAY,EACZC,IAAK,WACH,OAAOP,EAAOI,SAKbL,0MAtBT,SAASS,EAAuBC,GAC9B,OAAOA,GAAKA,EAAEC,WAAaD,EAAEE,QAAUF,EA8BzC,IAAIG,EACoB,oBAAfC,WACHA,WACgB,oBAATC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ssH,GAAgB,IAAAE,GAAkBzI,GAClCl1D,cAAa,IAAM/F,GAEvBzwD,iBACwC,CAAC,cAAe,SAAU,WAC7BgkD,MAAMsG,GAAM9pD,KAAK4C,SAASgxH,gBAAgB9pE,YACjEzvD,EAAY6Q,QAAQ,mBAAmB,GALhB2oH,0BAQ9B,WACCJ,IACAA,GAAcl+G,UAClBk+G,QAAgBz+G,qBAEb,WACH,OAAIy+G,GACOA,GAAc1/D,iBAErB,mCAED,SAAiC+/D,GACpC,OAAO1M,GAAatyF,OAAOg/F,EAAWn6F,6BAGnC,SAAuBq2F,GAC1B,GAAIyD,GACA,OAAOA,GAAc1D,cAAcC,6BAEpC,SAA0BE,GAC7B,GAAIuD,GACA,OAAOA,GAAcxD,iBAAiBC,kCAEvC,SAA+B6D,GAClC,GAAIN,GACA,OAAOA,GAAchD,sBAAsBsD,iCAE5C,SAA8BhD,GACjC,GAAI0C,GACA,OAAOA,GAAc3C,sBAAsBC,8BAE5C,SAA2BhD,GAC9B,GAAI0F,GACA,OAAOA,GAActC,kBAAkBpD,gCAGxC,WACH,GAAI0F,GACA,OAAOA,GAAcpC,iDAEtB,WACH,GAAIoC,GACA,OAAOA,GAAclC,wDAEtB,WACH,GAAIkC,GACA,OAAOA,GAAc9B,yDAEtB,WACH,GAAI8B,GACA,OAAOA,GAAczB,gDAEtB,WACH,GAAIyB,GACA,OAAOA,GAAcvB,+CAEtB,WACH,GAAIuB,GACA,OAAOA,GAAchB,6CAEtB,WACH,GAAIgB,GACA,OAAOA,GAAcX,8CAEtB,WACH,GAAIW,GACA,OAAOA,GAAcR,mDAEtB,WACH,GAAIQ,GACA,OAAOA,GAAcJ","sources":["./node_modules/@parcel/scope-hoisting/lib/helpers.js","./node_modules/atom-package-deps/lib/index.js","./node_modules/etch/lib/event-listener-props.js","./node_modules/etch/lib/dom.js","./node_modules/etch/lib/svg-tags.js","./node_modules/etch/lib/svg-attribute-translations.js","./node_modules/etch/lib/update-props.js","./node_modules/etch/lib/render.js","./node_modules/etch/lib/update-ref.js","./node_modules/etch/lib/patch.js","./node_modules/etch/lib/default-scheduler.js","./node_modules/etch/lib/scheduler-assignment.js","./node_modules/etch/lib/component-helpers.js","./node_modules/etch/lib/index.js","./lib/utils.ts","./node_modules/lodash/lodash.js","./lib/main/atom/utils/ts.ts","./lib/main/atom/utils/atom.ts","./lib/main/atom/views/outline/navTreeUtils.ts","./lib/main/atom/views/outline/navigationNodeComponent.tsx","./lib/main/atom/views/outline/navigationTreeComponent.tsx","./lib/main/atom/views/outline/semanticView.ts","./node_modules/byline/lib/byline.js","./lib/client/callbacks.ts","./lib/client/client.ts","./node_modules/jsonc-parser/lib/esm/impl/parser.js","./node_modules/jsonc-parser/lib/esm/impl/scanner.js","./node_modules/jsonc-parser/lib/esm/main.js","./node_modules/resolve/lib/async.js","./node_modules/resolve/lib/caller.js","./node_modules/path-parse/index.js","./node_modules/resolve/lib/node-modules-paths.js","./node_modules/resolve/lib/normalize-options.js","./node_modules/function-bind/implementation.js","./node_modules/has/src/index.js","./node_modules/is-core-module/index.js","./node_modules/function-bind/index.js","./node_modules/is-core-module/core.json","./node_modules/resolve/lib/core.js","./node_modules/resolve/lib/core.json","./node_modules/resolve/index.js","./node_modules/resolve/lib/is-core.js","./node_modules/resolve/lib/sync.js","./lib/client/resolveBinary.ts","./lib/client/clientResolver.ts","./lib/main/atom-ide/codeHighlightProvider.ts","./lib/main/atom/tooltips/tooltipRenderer.tsx","./lib/main/atom-ide/datatipProvider.tsx","./lib/main/atom-ide/definitionsProvider.ts","./lib/main/atom-ide/findReferencesProvider.ts","./lib/main/atom/components/tsView.tsx","./node_modules/fuzzaldrin/lib/scorer.js","./node_modules/fuzzaldrin/lib/filter.js","./node_modules/fuzzaldrin/lib/matcher.js","./node_modules/fuzzaldrin/lib/fuzzaldrin.js","./lib/main/atom/views/highlightComponent.tsx","./node_modules/atom-select-list/lib/select-list-view.js","./lib/main/atom/views/simpleSelectionView.tsx","./lib/main/atom/commands/registry.ts","./lib/main/atom/commands/findReferences.tsx","./lib/main/atom/commands/goToDeclaration.tsx","./lib/main/atom-ide/outlineProvider.ts","./lib/main/atom-ide/sigHelpProvider.ts","./lib/main/atom/codeActionTemplate.tsx","./lib/main/atom/autoCompleteProvider.ts","./lib/main/atom/commands/refactorCode.tsx","./lib/main/atom/codefix/codefixProvider.ts","./lib/main/atom/commands/initializeConfig.ts","./lib/main/atom/commands/build.ts","./lib/main/atom/commands/checkAllFiles.ts","./lib/main/atom/commands/clearErrors.ts","./lib/main/atom/commands/formatCode.ts","./lib/main/atom/commands/organizeImports.ts","./lib/main/atom/commands/reloadProjects.ts","./node_modules/underscore-plus/node_modules/underscore/underscore.js","./node_modules/underscore-plus/lib/underscore-plus.js","./node_modules/async/lib/async.js","./node_modules/mkdirp/index.js","./node_modules/fs.realpath/old.js","./node_modules/fs.realpath/index.js","./node_modules/concat-map/index.js","./node_modules/balanced-match/index.js","./node_modules/brace-expansion/index.js","./node_modules/minimatch/minimatch.js","./node_modules/inherits/inherits_browser.js","./node_modules/path-is-absolute/index.js","./node_modules/rimraf/node_modules/glob/common.js","./node_modules/rimraf/node_modules/glob/sync.js","./node_modules/wrappy/wrappy.js","./node_modules/once/once.js","./node_modules/inflight/inflight.js","./node_modules/rimraf/node_modules/glob/glob.js","./node_modules/rimraf/rimraf.js","./node_modules/fs-plus/lib/fs-plus.js","./lib/main/atom/components/miniEditor.ts","./lib/main/atom/views/renameView.tsx","./lib/main/atom/commands/index.ts","./lib/main/atom/commands/renameFile.ts","./lib/main/atom/commands/renameRefactor.ts","./lib/main/atom/commands/restartAllServers.ts","./lib/main/atom/commands/returnFromDeclaration.tsx","./lib/main/atom/commands/semanticView.ts","./lib/main/atom/commands/showTooltip.ts","./lib/main/atom/commands/sigHelp.ts","./lib/main/atom/commands/symbolsView.ts","./lib/main/atom/components/statusPanel/tooltip.tsx","./lib/main/atom/components/statusPanel/buildStatus.tsx","./lib/main/atom/components/statusPanel/configPath.tsx","./lib/main/atom/components/statusPanel/index.tsx","./lib/main/atom/editorPositionHistoryManager.tsx","./lib/main/atom/occurrence/controller.ts","./lib/main/atom/occurrence/manager.ts","./lib/main/atom/tooltips/util.ts","./lib/main/atom/sigHelp/tooltipView.tsx","./lib/main/atom/sigHelp/controller.ts","./lib/main/atom/sigHelp/manager.ts","./lib/main/atom/utils/element-listener.ts","./lib/main/atom/tooltips/tooltipView.tsx","./lib/main/atom/tooltips/controller.ts","./lib/main/atom/tooltips/manager.ts","./lib/main/atom/views/outline/semanticViewController.ts","./lib/main/atom/views/symbols/symbolsTag.ts","./lib/main/atom/views/symbols/generator.ts","./lib/main/atom/views/symbols/utils.ts","./lib/main/atom/views/symbols/fileSymbolsView.tsx","./lib/main/atom/views/symbols/symbolsViewController.ts","./lib/main/atom/views/symbols/projectSymbolsView.tsx","./lib/main/errorPusher.ts","./lib/main/typescriptBuffer.ts","./lib/main/typescriptEditorPane.ts","./lib/main/pluginManager.ts","./lib/main/atom/codefix/intentionsProvider.ts","./lib/main/atom-ide/codeActionsProvider.ts","./lib/main/atom-ide/hyperclickProvider.ts","./lib/main/atomts.ts"],"sourcesContent":["function $parcel$interopDefault(a) {\n return a && a.__esModule ? a.default : a;\n}\n\nfunction $parcel$defineInteropFlag(a) {\n Object.defineProperty(a, '__esModule', {value: true});\n}\n\nfunction $parcel$exportWildcard(dest, source) {\n Object.keys(source).forEach(function(key) {\n if (key === 'default' || key === '__esModule') {\n return;\n }\n\n Object.defineProperty(dest, key, {\n enumerable: true,\n get: function get() {\n return source[key];\n },\n });\n });\n\n return dest;\n}\n\nfunction $parcel$missingModule(name) {\n var err = new Error(\"Cannot find module '\" + name + \"'\");\n err.code = 'MODULE_NOT_FOUND';\n throw err;\n}\n\nvar $parcel$global =\n typeof globalThis !== 'undefined'\n ? globalThis\n : typeof self !== 'undefined'\n ? self\n : typeof window !== 'undefined'\n ? window\n : typeof global !== 'undefined'\n ? global\n : {};\n","'use strict';\n\nObject.defineProperty(exports, '__esModule', { value: true });\n\nvar os = require('os');\nvar child_process = require('child_process');\nvar fs = require('fs');\nvar path = require('path');\n\nfunction _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }\n\nvar os__default = /*#__PURE__*/_interopDefaultLegacy(os);\nvar fs__default = /*#__PURE__*/_interopDefaultLegacy(fs);\nvar path__default = /*#__PURE__*/_interopDefaultLegacy(path);\n\nvar indentString = (string, count = 1, options) => {\n\toptions = {\n\t\tindent: ' ',\n\t\tincludeEmptyLines: false,\n\t\t...options\n\t};\n\n\tif (typeof string !== 'string') {\n\t\tthrow new TypeError(\n\t\t\t`Expected \\`input\\` to be a \\`string\\`, got \\`${typeof string}\\``\n\t\t);\n\t}\n\n\tif (typeof count !== 'number') {\n\t\tthrow new TypeError(\n\t\t\t`Expected \\`count\\` to be a \\`number\\`, got \\`${typeof count}\\``\n\t\t);\n\t}\n\n\tif (typeof options.indent !== 'string') {\n\t\tthrow new TypeError(\n\t\t\t`Expected \\`options.indent\\` to be a \\`string\\`, got \\`${typeof options.indent}\\``\n\t\t);\n\t}\n\n\tif (count === 0) {\n\t\treturn string;\n\t}\n\n\tconst regex = options.includeEmptyLines ? /^/gm : /^(?!\\s*$)/gm;\n\n\treturn string.replace(regex, options.indent.repeat(count));\n};\n\nconst extractPathRegex = /\\s+at.*(?:\\(|\\s)(.*)\\)?/;\nconst pathRegex = /^(?:(?:(?:node|(?:internal\\/[\\w/]*|.*node_modules\\/(?:babel-polyfill|pirates)\\/.*)?\\w+)\\.js:\\d+:\\d+)|native)/;\nconst homeDir = typeof os__default['default'].homedir === 'undefined' ? '' : os__default['default'].homedir();\n\nvar cleanStack = (stack, options) => {\n\toptions = Object.assign({pretty: false}, options);\n\n\treturn stack.replace(/\\\\/g, '/')\n\t\t.split('\\n')\n\t\t.filter(line => {\n\t\t\tconst pathMatches = line.match(extractPathRegex);\n\t\t\tif (pathMatches === null || !pathMatches[1]) {\n\t\t\t\treturn true;\n\t\t\t}\n\n\t\t\tconst match = pathMatches[1];\n\n\t\t\t// Electron\n\t\t\tif (\n\t\t\t\tmatch.includes('.app/Contents/Resources/electron.asar') ||\n\t\t\t\tmatch.includes('.app/Contents/Resources/default_app.asar')\n\t\t\t) {\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\treturn !pathRegex.test(match);\n\t\t})\n\t\t.filter(line => line.trim() !== '')\n\t\t.map(line => {\n\t\t\tif (options.pretty) {\n\t\t\t\treturn line.replace(extractPathRegex, (m, p1) => m.replace(p1, p1.replace(homeDir, '~')));\n\t\t\t}\n\n\t\t\treturn line;\n\t\t})\n\t\t.join('\\n');\n};\n\nconst cleanInternalStack = stack => stack.replace(/\\s+at .*aggregate-error\\/index.js:\\d+:\\d+\\)?/g, '');\n\nclass AggregateError extends Error {\n\tconstructor(errors) {\n\t\tif (!Array.isArray(errors)) {\n\t\t\tthrow new TypeError(`Expected input to be an Array, got ${typeof errors}`);\n\t\t}\n\n\t\terrors = [...errors].map(error => {\n\t\t\tif (error instanceof Error) {\n\t\t\t\treturn error;\n\t\t\t}\n\n\t\t\tif (error !== null && typeof error === 'object') {\n\t\t\t\t// Handle plain error objects with message property and/or possibly other metadata\n\t\t\t\treturn Object.assign(new Error(error.message), error);\n\t\t\t}\n\n\t\t\treturn new Error(error);\n\t\t});\n\n\t\tlet message = errors\n\t\t\t.map(error => {\n\t\t\t\t// The `stack` property is not standardized, so we can't assume it exists\n\t\t\t\treturn typeof error.stack === 'string' ? cleanInternalStack(cleanStack(error.stack)) : String(error);\n\t\t\t})\n\t\t\t.join('\\n');\n\t\tmessage = '\\n' + indentString(message, 4);\n\t\tsuper(message);\n\n\t\tthis.name = 'AggregateError';\n\n\t\tObject.defineProperty(this, '_errors', {value: errors});\n\t}\n\n\t* [Symbol.iterator]() {\n\t\tfor (const error of this._errors) {\n\t\t\tyield error;\n\t\t}\n\t}\n}\n\nvar aggregateError = AggregateError;\n\nvar pMap = async (\n\titerable,\n\tmapper,\n\t{\n\t\tconcurrency = Infinity,\n\t\tstopOnError = true\n\t} = {}\n) => {\n\treturn new Promise((resolve, reject) => {\n\t\tif (typeof mapper !== 'function') {\n\t\t\tthrow new TypeError('Mapper function is required');\n\t\t}\n\n\t\tif (!((Number.isSafeInteger(concurrency) || concurrency === Infinity) && concurrency >= 1)) {\n\t\t\tthrow new TypeError(`Expected \\`concurrency\\` to be an integer from 1 and up or \\`Infinity\\`, got \\`${concurrency}\\` (${typeof concurrency})`);\n\t\t}\n\n\t\tconst result = [];\n\t\tconst errors = [];\n\t\tconst iterator = iterable[Symbol.iterator]();\n\t\tlet isRejected = false;\n\t\tlet isIterableDone = false;\n\t\tlet resolvingCount = 0;\n\t\tlet currentIndex = 0;\n\n\t\tconst next = () => {\n\t\t\tif (isRejected) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tconst nextItem = iterator.next();\n\t\t\tconst index = currentIndex;\n\t\t\tcurrentIndex++;\n\n\t\t\tif (nextItem.done) {\n\t\t\t\tisIterableDone = true;\n\n\t\t\t\tif (resolvingCount === 0) {\n\t\t\t\t\tif (!stopOnError && errors.length !== 0) {\n\t\t\t\t\t\treject(new aggregateError(errors));\n\t\t\t\t\t} else {\n\t\t\t\t\t\tresolve(result);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tresolvingCount++;\n\n\t\t\t(async () => {\n\t\t\t\ttry {\n\t\t\t\t\tconst element = await nextItem.value;\n\t\t\t\t\tresult[index] = await mapper(element, index);\n\t\t\t\t\tresolvingCount--;\n\t\t\t\t\tnext();\n\t\t\t\t} catch (error) {\n\t\t\t\t\tif (stopOnError) {\n\t\t\t\t\t\tisRejected = true;\n\t\t\t\t\t\treject(error);\n\t\t\t\t\t} else {\n\t\t\t\t\t\terrors.push(error);\n\t\t\t\t\t\tresolvingCount--;\n\t\t\t\t\t\tnext();\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t})();\n\t\t};\n\n\t\tfor (let i = 0; i < concurrency; i++) {\n\t\t\tnext();\n\n\t\t\tif (isIterableDone) {\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\t});\n};\n\nconst pMap$1 = (iterable, mapper, options) => new Promise((resolve, reject) => {\n\toptions = Object.assign({\n\t\tconcurrency: Infinity\n\t}, options);\n\n\tif (typeof mapper !== 'function') {\n\t\tthrow new TypeError('Mapper function is required');\n\t}\n\n\tconst {concurrency} = options;\n\n\tif (!(typeof concurrency === 'number' && concurrency >= 1)) {\n\t\tthrow new TypeError(`Expected \\`concurrency\\` to be a number from 1 and up, got \\`${concurrency}\\` (${typeof concurrency})`);\n\t}\n\n\tconst ret = [];\n\tconst iterator = iterable[Symbol.iterator]();\n\tlet isRejected = false;\n\tlet isIterableDone = false;\n\tlet resolvingCount = 0;\n\tlet currentIndex = 0;\n\n\tconst next = () => {\n\t\tif (isRejected) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst nextItem = iterator.next();\n\t\tconst i = currentIndex;\n\t\tcurrentIndex++;\n\n\t\tif (nextItem.done) {\n\t\t\tisIterableDone = true;\n\n\t\t\tif (resolvingCount === 0) {\n\t\t\t\tresolve(ret);\n\t\t\t}\n\n\t\t\treturn;\n\t\t}\n\n\t\tresolvingCount++;\n\n\t\tPromise.resolve(nextItem.value)\n\t\t\t.then(element => mapper(element, i))\n\t\t\t.then(\n\t\t\t\tvalue => {\n\t\t\t\t\tret[i] = value;\n\t\t\t\t\tresolvingCount--;\n\t\t\t\t\tnext();\n\t\t\t\t},\n\t\t\t\terror => {\n\t\t\t\t\tisRejected = true;\n\t\t\t\t\treject(error);\n\t\t\t\t}\n\t\t\t);\n\t};\n\n\tfor (let i = 0; i < concurrency; i++) {\n\t\tnext();\n\n\t\tif (isIterableDone) {\n\t\t\tbreak;\n\t\t}\n\t}\n});\n\nvar pMap_1 = pMap$1;\n// TODO: Remove this for the next major release\nvar _default = pMap$1;\npMap_1.default = _default;\n\nconst pFilter = async (iterable, filterer, options) => {\n\tconst values = await pMap_1(\n\t\titerable,\n\t\t(element, index) => Promise.all([filterer(element, index), element]),\n\t\toptions\n\t);\n\treturn values.filter(value => Boolean(value[0])).map(value => value[1]);\n};\n\nvar pFilter_1 = pFilter;\n// TODO: Remove this for the next major release\nvar _default$1 = pFilter;\npFilter_1.default = _default$1;\n\nconst IS_ATOM = typeof atom !== 'undefined';\nconst IS_DEV = typeof atom !== 'undefined' && (atom.inDevMode() || atom.inSpecMode());\nconst IGNORED_CONFIG_NAME = 'atom-package-deps.ignored';\n\n/*!\n * escape-html\n * Copyright(c) 2012-2013 TJ Holowaychuk\n * Copyright(c) 2015 Andreas Lubbe\n * Copyright(c) 2015 Tiancheng \"Timothy\" Gu\n * MIT Licensed\n */\n\n/**\n * Module variables.\n * @private\n */\n\nvar matchHtmlRegExp = /[\"'&<>]/;\n\n/**\n * Module exports.\n * @public\n */\n\nvar escapeHtml_1 = escapeHtml;\n\n/**\n * Escape special characters in the given string of html.\n *\n * @param {string} string The string to escape for inserting into HTML\n * @return {string}\n * @public\n */\n\nfunction escapeHtml(string) {\n var str = '' + string;\n var match = matchHtmlRegExp.exec(str);\n\n if (!match) {\n return str;\n }\n\n var escape;\n var html = '';\n var index = 0;\n var lastIndex = 0;\n\n for (index = match.index; index < str.length; index++) {\n switch (str.charCodeAt(index)) {\n case 34: // \"\n escape = '"';\n break;\n case 38: // &\n escape = '&';\n break;\n case 39: // '\n escape = ''';\n break;\n case 60: // <\n escape = '<';\n break;\n case 62: // >\n escape = '>';\n break;\n default:\n continue;\n }\n\n if (lastIndex !== index) {\n html += str.substring(lastIndex, index);\n }\n\n lastIndex = index + 1;\n html += escape;\n }\n\n return lastIndex !== index\n ? html + str.substring(lastIndex, index)\n : html;\n}\n\nasync function spawnInternal(command, args, options) {\n const spawnedProcess = child_process.spawn(command, args, options);\n const promise = new Promise((resolve, reject) => {\n const output = {\n stdout: spawnedProcess.stdout ? [] : null,\n stderr: spawnedProcess.stderr ? [] : null,\n };\n spawnedProcess.on('error', reject);\n if (spawnedProcess.stdout) {\n spawnedProcess.stdout.on('data', function (chunk) {\n output.stdout.push(chunk);\n if (options.handleStdout) {\n options.handleStdout(chunk);\n }\n });\n }\n if (spawnedProcess.stderr) {\n spawnedProcess.stderr.on('data', function (chunk) {\n output.stderr.push(chunk);\n if (options.handleStderr) {\n options.handleStderr(chunk);\n }\n });\n }\n spawnedProcess.on('close', code => {\n let outputStdout = null;\n if (output.stdout != null) {\n outputStdout =\n options.encoding === null || options.encoding === 'buffer'\n ? Buffer.concat(output.stdout)\n : output.stdout.join('');\n }\n let outputStderr = null;\n if (output.stderr != null) {\n outputStderr =\n options.encoding === null || options.encoding === 'buffer'\n ? Buffer.concat(output.stderr)\n : output.stderr.join('');\n }\n resolve({\n exitCode: code,\n stdout: outputStdout,\n stderr: outputStderr,\n });\n });\n });\n options.handleChildProcess(spawnedProcess);\n return promise;\n}\nfunction spawn(command, args, options) {\n let spawnedProcess;\n const promise = spawnInternal(command, args, {\n ...options,\n handleChildProcess(_spawnedProcess) {\n spawnedProcess = _spawnedProcess;\n },\n });\n promise.kill = function (signal) {\n // TODO: kill all subprocesses on windows with wmic?\n return spawnedProcess.kill(signal);\n };\n return promise;\n}\n\nvar semverCompare = function cmp (a, b) {\n var pa = a.split('.');\n var pb = b.split('.');\n for (var i = 0; i < 3; i++) {\n var na = Number(pa[i]);\n var nb = Number(pb[i]);\n if (na > nb) return 1;\n if (nb > na) return -1;\n if (!isNaN(na) && isNaN(nb)) return 1;\n if (isNaN(na) && !isNaN(nb)) return -1;\n }\n return 0;\n};\n\nasync function getDependencies(packageName) {\n const packageModule = atom.packages.getLoadedPackage(packageName);\n const packageDependencies = packageModule && packageModule.metadata['package-deps'];\n return Array.isArray(packageDependencies) ? packageDependencies : [];\n}\nasync function resolveDependencyPath(packageName) {\n return atom.packages.resolvePackagePath(packageName);\n}\nasync function getInstalledDependencyVersion(dependency) {\n var _packageModule$metada;\n\n const packageModule = atom.packages.getLoadedPackage(dependency.name);\n return packageModule == null ? null : (_packageModule$metada = packageModule.metadata.version) !== null && _packageModule$metada !== void 0 ? _packageModule$metada : null;\n}\n\nasync function getDependencies$1(packageName) {\n let packageStats = null;\n\n try {\n packageStats = await fs__default['default'].promises.stat(packageName);\n } catch (_) {// No Op\n }\n\n if (packageStats == null || !packageStats.isDirectory()) {\n throw new Error(`[Package-Deps] Expected packageName to be a readable directory in Node.js invocation`);\n }\n\n let parsed = null;\n\n try {\n const contents = await fs__default['default'].promises.readFile(path__default['default'].join(packageName, 'package.json'), 'utf8');\n parsed = JSON.parse(contents);\n } catch (_) {// Ignore JSON read errors and such\n }\n\n const packageDependencies = parsed == null || typeof parsed !== 'object' ? [] : parsed['package-deps'];\n return Array.isArray(packageDependencies) ? packageDependencies : [];\n}\nasync function resolveDependencyPath$1(packageName) {\n var _process$env$ATOM_HOM;\n\n const packageDirectory = path__default['default'].join((_process$env$ATOM_HOM = process.env.ATOM_HOME) !== null && _process$env$ATOM_HOM !== void 0 ? _process$env$ATOM_HOM : path__default['default'].join(os__default['default'].homedir(), '.atom'), 'packages', packageName);\n\n try {\n await fs__default['default'].promises.access(packageDirectory, fs__default['default'].constants.R_OK);\n return packageDirectory;\n } catch (_) {\n return null;\n }\n}\nasync function getInstalledDependencyVersion$1(dependency) {\n var _manifest$version, _manifest;\n\n const {\n directory\n } = dependency;\n\n if (directory == null) {\n // Not possible to get version without resolved directory in Node.js version\n return null;\n }\n\n let manifest = null;\n\n try {\n manifest = JSON.parse(await fs__default['default'].promises.readFile(path__default['default'].join(directory, 'package.json'), 'utf8'));\n } catch (_) {\n return null;\n }\n\n return (_manifest$version = (_manifest = manifest) === null || _manifest === void 0 ? void 0 : _manifest.version) !== null && _manifest$version !== void 0 ? _manifest$version : null;\n}\n\n/**\n * Internal helpers\n */\n\nasync function getInstalledDependencyVersion$2(dependency) {\n if (IS_ATOM) {\n const atomPackageVersion = await getInstalledDependencyVersion(dependency);\n\n if (atomPackageVersion) {\n return atomPackageVersion;\n } // If the package isn't activated, it won't be loaded, so fallback to reading manifest file instead\n\n }\n\n return getInstalledDependencyVersion$1(dependency);\n}\n/**\n * Exported helpers\n */\n\n\nconst resolveDependencyPath$2 = IS_ATOM ? resolveDependencyPath : resolveDependencyPath$1;\nfunction invariant(condition, message) {\n if (!condition) {\n throw new Error(message !== null && message !== void 0 ? message : 'Invariant violation');\n }\n}\nasync function getDependencies$2(name) {\n const dependencies = await (IS_ATOM ? getDependencies(name) : getDependencies$1(name));\n\n if (IS_DEV) {\n invariant(Array.isArray(dependencies), `Dependencies for ${name} are not a valid array`);\n dependencies.forEach((item, index) => {\n if (Array.isArray(item)) {\n item.forEach((subitem, subindex) => {\n const invalidMessage = `Dependency#${index}#${subindex} for ${name} is invalid`;\n invariant(typeof subitem.name === 'string' && subitem.name.length > 0, invalidMessage);\n invariant(subitem.minimumVersion == null || typeof subitem.minimumVersion === 'string' && subitem.minimumVersion.length > 0, invalidMessage);\n });\n invariant(item.length > 0, `Dependency#${index} for ${name} has no group items`);\n } else {\n const invalidMessage = `Dependency#${index} for ${name} is invalid`;\n invariant(typeof item.name === 'string' && item.name.length > 0, invalidMessage);\n invariant(item.minimumVersion == null || typeof item.minimumVersion === 'string' && item.minimumVersion.length > 0, invalidMessage);\n }\n });\n }\n\n return dependencies;\n}\nasync function shouldInstallDependency(dependency) {\n if (dependency.directory == null) {\n // Not installed, so install\n return true;\n }\n\n if (dependency.minimumVersion == null) {\n // Already installed and no version defined, so skip\n return false;\n }\n\n const version = await getInstalledDependencyVersion$2(dependency);\n\n if (version == null) {\n // Unable to get current version, so install\n return true;\n }\n\n return semverCompare(dependency.minimumVersion, version) === 1;\n}\nfunction isPackageIgnored(name) {\n var _atom$config$get;\n\n if (!IS_ATOM) {\n // Never ignored in CLI\n return false;\n }\n\n const ignoredPackages = (_atom$config$get = atom.config.get(IGNORED_CONFIG_NAME)) !== null && _atom$config$get !== void 0 ? _atom$config$get : [];\n\n if (ignoredPackages.includes(name)) {\n return true;\n }\n\n return false;\n}\nfunction markPackageAsIgnored(name) {\n var _atom$config$get2;\n\n if (!IS_ATOM) {\n // No op in CLI\n return;\n }\n\n const ignoredPackages = new Set((_atom$config$get2 = atom.config.get(IGNORED_CONFIG_NAME)) !== null && _atom$config$get2 !== void 0 ? _atom$config$get2 : []);\n ignoredPackages.add(name);\n atom.config.set(IGNORED_CONFIG_NAME, Array.from(ignoredPackages));\n}\nconst INSTALL_VALID_TICKS = new Set(['✓', 'done']);\nconst INSTALL_VALIDATION_REGEXP = /(?:Installing|Moving) (.*?) to .* (.*)/; // Example success output: Uninstalling linter-ui-default ✓\n\nasync function installPackage(dependency) {\n const apmPath = IS_ATOM ? atom.packages.getApmPath() : 'apm';\n const {\n stdout,\n stderr\n } = await spawn(apmPath, ['install', dependency.name, '--production', '--color', 'false']);\n const match = INSTALL_VALIDATION_REGEXP.exec(stdout.trim());\n\n if (match != null && INSTALL_VALID_TICKS.has(match[2])) {\n // Installation complete and verified\n return;\n }\n\n const error = new Error(`Error installing dependency: ${dependency.name}`);\n error.stack = stderr.trim();\n throw error;\n}\n\nlet showResetInstruction = true;\nfunction confirmPackagesToInstall({\n packageName,\n dependencies\n}) {\n return new Promise(resolve => {\n const ungroupedDependencies = dependencies.filter(item => !Array.isArray(item));\n const groupedDependencies = dependencies.filter(item => Array.isArray(item));\n const skipGroups = groupedDependencies.length === 0;\n const detail = skipGroups ? ungroupedDependencies.map(item => item.name).join(', ') : 'Something went wrong. Check your developer console';\n const groupChoices = groupedDependencies.map(item => item[0]); // If Atom \"notifications\" package is disabled output a warning in case no other notifications package is installed.\n\n if (atom.packages.isPackageDisabled('notifications')) {\n console.warn(`Enable notifications to install dependencies for ${packageName}`);\n }\n\n const notification = atom.notifications.addInfo(`${packageName} needs to install dependencies`, {\n dismissable: true,\n icon: 'cloud-download',\n detail,\n description: `Install dependenc${dependencies.length === 1 ? 'y' : 'ies'}?`,\n buttons: [{\n text: 'Yes',\n onDidClick: () => {\n if (skipGroups) {\n resolve([]);\n } else {\n resolve(ungroupedDependencies.concat(groupChoices));\n }\n\n notification.dismiss();\n }\n }, {\n text: 'No Thanks',\n onDidClick: () => {\n notification.dismiss();\n }\n }, {\n text: 'Never',\n onDidClick: () => {\n markPackageAsIgnored(packageName);\n\n if (showResetInstruction) {\n showResetInstruction = false;\n atom.notifications.addInfo('How to reset package-deps memory', {\n dismissable: true,\n description: \"To modify the list of ignored files invoke 'Application: Open Your Config' and change the 'atom-package-deps' section\"\n });\n }\n\n notification.dismiss();\n }\n }]\n });\n notification.onDidDismiss(() => resolve([]));\n\n if (skipGroups) {\n return;\n } // Handle groups\n\n\n try {\n var _notificationView$ele;\n\n const notificationView = atom.views.getView(notification);\n const notificationElement = (_notificationView$ele = notificationView === null || notificationView === void 0 ? void 0 : notificationView.element) !== null && _notificationView$ele !== void 0 ? _notificationView$ele : null;\n\n if (notificationElement == null) {\n throw new Error('Unable to get notification element from view');\n }\n\n const notificationContent = notificationElement.querySelector('.detail-content');\n\n if (notificationContent == null) {\n throw new Error('Content detail container not found inside the notification');\n } // Clear the contents and add some skel\n\n\n notificationContent.innerHTML = ''; // Add list of ungroup dependencies to the top of the notification\n\n if (ungroupedDependencies.length > 0) {\n const ungroupedLine = document.createElement('div');\n ungroupedLine.innerHTML = `Packages without choices:
  • ${ungroupedDependencies.map(item => escapeHtml_1(item.name)).join('
  • ')}
`;\n notificationContent.appendChild(ungroupedLine);\n } // Create a label line for groups\n\n\n const groupLabelLine = document.createElement('div');\n groupLabelLine.innerHTML = `Packages with choices:`;\n notificationContent.appendChild(groupLabelLine); // Create one line per group with a select inside\n\n const groupedList = document.createElement('ul');\n groupedDependencies.forEach((item, index) => {\n const listItem = document.createElement('li');\n const select = document.createElement('select');\n select.innerHTML = item.map(subitem => ``).join('\\n');\n select.addEventListener('change', () => {\n // Change the selected value for this index for resolve to use\n const subitem = item.find(entry => entry.name === select.value);\n\n if (subitem != null) {\n groupChoices[index] = subitem;\n }\n });\n listItem.style.marginTop = '5px';\n listItem.appendChild(select);\n groupedList.appendChild(listItem);\n });\n notificationContent.appendChild(groupedList);\n } catch (err) {\n console.error('[Package-Deps] Error during showing package choices to user', err);\n }\n });\n}\nfunction getView({\n packageName,\n dependencies\n}) {\n const failed = [];\n const notification = atom.notifications.addInfo(`Installing ${packageName} dependencies`, {\n detail: `Installing ${dependencies.map(item => item.name).join(', ')}`,\n dismissable: true\n });\n const progress = document.createElement('progress');\n progress.max = dependencies.length;\n progress.style.width = '100%';\n\n try {\n var _notificationView$ele2;\n\n const notificationView = atom.views.getView(notification);\n const notificationElement = (_notificationView$ele2 = notificationView === null || notificationView === void 0 ? void 0 : notificationView.element) !== null && _notificationView$ele2 !== void 0 ? _notificationView$ele2 : null;\n\n if (notificationElement == null) {\n throw new Error('Unable to get notification element from view');\n }\n\n const notificationContent = notificationElement.querySelector('.detail-content');\n\n if (notificationContent == null) {\n throw new Error('Content detail container not found inside the notification');\n }\n\n notificationContent.appendChild(progress);\n } catch (err) {\n console.error('[Package-Deps] Error during showing installation progress to user', err);\n }\n\n return {\n handleFailure({\n dependency,\n error\n }) {\n var _error$stack;\n\n failed.push(dependency.name);\n progress.value += 1;\n console.error(`[Package-Deps] Unable to install ${dependency.name}, Error:`, (_error$stack = error === null || error === void 0 ? void 0 : error.stack) !== null && _error$stack !== void 0 ? _error$stack : error);\n },\n\n handleDependencyInstalled(dependency) {\n progress.value += 1;\n },\n\n handleComplete() {\n notification.dismiss();\n\n if (failed.length > 0) {\n atom.notifications.addWarning(`Failed to install ${packageName} dependencies`, {\n detail: `These packages were not installed, check your console\\nfor more info.\\n${failed.join('\\n')}`,\n dismissable: true\n });\n } else {\n atom.notifications.addSuccess(`Installed ${packageName} dependencies`, {\n detail: `Installed ${dependencies.map(item => item.name).join(', ')}`\n });\n }\n\n Promise.all(dependencies.map(item => {\n if (!failed.includes(item.name)) {\n return atom.packages.activatePackage(item.name);\n }\n\n return null;\n })).catch(err => {\n console.error(`[Package-Deps] Error activating installed packages for ${packageName}`, err);\n });\n }\n\n };\n}\n\nasync function confirmPackagesToInstall$1({\n dependencies\n}) {\n // No user interaction on the CLI. Install the first (aka \"default\" choice) package\n return dependencies.map(item => Array.isArray(item) ? item[0] : item);\n}\nfunction getView$1({\n dependencies\n}) {\n let failed = false;\n console.log(`Installing dependencies:\\n${dependencies.map(item => ` - ${item.name}`).join('\\n')}`);\n return {\n handleFailure({\n dependency,\n error\n }) {\n var _error$stack;\n\n failed = true;\n console.error(`Unable to install ${dependency.name}, Error:`, (_error$stack = error === null || error === void 0 ? void 0 : error.stack) !== null && _error$stack !== void 0 ? _error$stack : error);\n },\n\n handleDependencyInstalled(dependency) {\n console.log('Successfully installed', dependency.name);\n },\n\n handleComplete() {\n console.log('Installation complete');\n\n if (failed) {\n // Fail the invocation\n process.exitCode = 1;\n }\n }\n\n };\n}\n\nconst getView$2 = IS_ATOM ? getView : getView$1;\nconst confirmPackagesToInstall$2 = IS_ATOM ? confirmPackagesToInstall : confirmPackagesToInstall$1;\n\nasync function install(packageName) {\n invariant(typeof packageName === 'string' && packageName.length > 0, '[Package-Deps] Package name is required');\n\n if (isPackageIgnored(packageName)) {\n // User ignored this package\n return;\n } // Get list of relevant dependencies\n\n\n const dependencies = await getDependencies$2(packageName);\n\n if (dependencies.length === 0) {\n // Short-circuit\n return;\n } // Resolve directories of relevant dependencies\n\n\n const resolvedDependencies = await Promise.all(dependencies.map(async item => {\n if (Array.isArray(item)) {\n return Promise.all(item.map(async subitem => ({ ...subitem,\n directory: await resolveDependencyPath$2(subitem.name)\n })));\n }\n\n return { ...item,\n directory: await resolveDependencyPath$2(item.name)\n };\n })); // Filter out already installed, in range dependencies\n // If one dependency from a group is already installed, whole group is ignored\n\n const dependenciesToInstall = await pFilter_1(resolvedDependencies, async function (item) {\n if (Array.isArray(item)) {\n return (await Promise.all(item.map(subitem => shouldInstallDependency(subitem)))).every(Boolean);\n }\n\n return shouldInstallDependency(item);\n });\n\n if (dependenciesToInstall.length === 0) {\n // Short-circuit if all have been skipped\n return;\n }\n\n const chosenDependencies = await confirmPackagesToInstall$2({\n packageName,\n dependencies: dependenciesToInstall\n });\n\n if (chosenDependencies.length === 0) {\n // Short-circuit if user interaction cancelled all\n return;\n }\n\n const view = getView$2({\n packageName,\n dependencies: chosenDependencies\n });\n await pMap(chosenDependencies, async function (dependency) {\n try {\n await installPackage(dependency);\n view.handleDependencyInstalled(dependency);\n } catch (err) {\n view.handleFailure({\n dependency,\n error: err\n });\n }\n }, {\n concurrency: 2\n });\n view.handleComplete();\n}\n\nexports.install = install;\n","module.exports = {\n onCopy: 'copy',\n onCut: 'cut',\n onPaste: 'paste',\n onCompositionEnd: 'compositionend',\n onCompositionStart: 'compositionstart',\n onCompositionUpdate: 'compositionupdate',\n onKeyDown: 'keydown',\n onKeyPress: 'keypress',\n onKeyUp: 'keyup',\n onFocus: 'focus',\n onBlur: 'blur',\n onChange: 'change',\n onInput: 'input',\n onSubmit: 'submit',\n onClick: 'click',\n onContextMenu: 'contextmenu',\n onDoubleClick: 'dblclick',\n onDrag: 'drag',\n onDragEnd: 'dragend',\n onDragEnter: 'dragenter',\n onDragExit: 'dragexit',\n onDragLeave: 'dragleave',\n onDragOver: 'dragover',\n onDragStart: 'dragstart',\n onDrop: 'drop',\n onMouseDown: 'mousedown',\n onMouseEnter: 'mouseenter',\n onMouseLeave: 'mouseleave',\n onMouseMove: 'mousemove',\n onMouseOut: 'mouseout',\n onMouseOver: 'mouseover',\n onMouseUp: 'mouseup',\n onSelect: 'select',\n onTouchCancel: 'touchcancel',\n onTouchEnd: 'touchend',\n onTouchMove: 'touchmove',\n onTouchStart: 'touchstart',\n onScroll: 'scroll',\n onWheel: 'wheel',\n onAbort: 'abort',\n onCanPlay: 'canplay',\n onCanPlayThrough: 'canplaythrough',\n onDurationChange: 'durationchange',\n onEmptied: 'emptied',\n onEncrypted: 'encrypted',\n onEnded: 'ended',\n onError: 'error',\n onLoadedData: 'loadeddata',\n onLoadedMetadata: 'loadedmetadata',\n onLoadStart: 'loadstart',\n onPause: 'pause',\n onPlay: 'play',\n onPlaying: 'playing',\n onProgress: 'progress',\n onRateChange: 'ratechange',\n onSeeked: 'seeked',\n onSeeking: 'seeking',\n onStalled: 'stalled',\n onSuspend: 'suspend',\n onTimeUpdate: 'timeupdate',\n onVolumeChange: 'volumechange',\n onWaiting: 'waiting',\n onLoad: 'load',\n onAnimationStart: 'animationstart',\n onAnimationEnd: 'animationend',\n onAnimationIteration: 'animationiteration',\n onTransitionEnd: 'transitionend'\n}\n","const EVENT_LISTENER_PROPS = require('./event-listener-props')\nconst SVG_TAGS = require('./svg-tags')\n\nfunction dom (tag, props, ...children) {\n let ambiguous = []\n\n for (let i = 0; i < children.length;) {\n const child = children[i]\n switch (typeof child) {\n case 'string':\n case 'number':\n children[i] = {text: child}\n i++\n break;\n\n case 'object':\n if (Array.isArray(child)) {\n children.splice(i, 1, ...child)\n } else if (!child) {\n children.splice(i, 1)\n } else {\n if (!child.context) {\n ambiguous.push(child)\n if (child.ambiguous && child.ambiguous.length) {\n ambiguous = ambiguous.concat(child.ambiguous)\n }\n }\n i++\n }\n break;\n\n default:\n throw new Error(`Invalid child node: ${child}`)\n }\n }\n\n if (props) {\n for (const propName in props) {\n const eventName = EVENT_LISTENER_PROPS[propName]\n if (eventName) {\n if (!props.on) props.on = {}\n props.on[eventName] = props[propName]\n }\n }\n\n if (props.class) {\n props.className = props.class\n }\n }\n\n return {tag, props, children, ambiguous}\n}\n\nconst HTML_TAGS = [\n 'a', 'abbr', 'address', 'article', 'aside', 'audio', 'b', 'bdi', 'bdo',\n 'blockquote', 'body', 'button', 'canvas', 'caption', 'cite', 'code',\n 'colgroup', 'datalist', 'dd', 'del', 'details', 'dfn', 'dialog', 'div', 'dl',\n 'dt', 'em', 'fieldset', 'figcaption', 'figure', 'footer', 'form', 'h1', 'h2',\n 'h3', 'h4', 'h5', 'h6', 'head', 'header', 'html', 'i', 'iframe', 'ins', 'kbd',\n 'label', 'legend', 'li', 'main', 'map', 'mark', 'menu', 'meter', 'nav',\n 'noscript', 'object', 'ol', 'optgroup', 'option', 'output', 'p', 'pre',\n 'progress', 'q', 'rp', 'rt', 'ruby', 's', 'samp', 'script', 'section',\n 'select', 'small', 'span', 'strong', 'style', 'sub', 'summary', 'sup',\n 'table', 'tbody', 'td', 'textarea', 'tfoot', 'th', 'thead', 'time', 'title',\n 'tr', 'u', 'ul', 'var', 'video', 'area', 'base', 'br', 'col', 'command',\n 'embed', 'hr', 'img', 'input', 'keygen', 'link', 'meta', 'param', 'source',\n 'track', 'wbr'\n]\n\nfor (const tagName of HTML_TAGS) {\n dom[tagName] = (props, ...children) => {\n return dom(tagName, props, ...children)\n }\n}\n\nfor (const tagName of SVG_TAGS) {\n dom[tagName] = (props, ...children) => {\n return dom(tagName, props, ...children)\n }\n}\n\n\nmodule.exports = dom\n","// taken from https://github.com/facebook/react/blob/67f8524e88abbf1ac0fd86d38a0477d11fbc7b3e/src/isomorphic/classic/element/ReactDOMFactories.js#L153\nmodule.exports = new Set([\n 'circle',\n 'clipPath',\n 'defs',\n 'ellipse',\n 'g',\n 'image',\n 'line',\n 'linearGradient',\n 'mask',\n 'path',\n 'pattern',\n 'polygon',\n 'polyline',\n 'radialGradient',\n 'rect',\n 'stop',\n 'svg',\n 'text',\n 'tspan'\n])\n","// Based on https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute\nmodule.exports = new Map([\n ['accentHeight', 'accent-height'],\n ['alignmentBaseline', 'alignment-baseline'],\n ['arabicForm', 'arabic-form'],\n ['baselineShift', 'baseline-shift'],\n ['capHeight', 'cap-height'],\n ['className', 'class'],\n ['clipPath', 'clip-path'],\n ['clipRule', 'clip-rule'],\n ['colorInterpolation', 'color-interpolation'],\n ['colorInterpolationFilters', 'color-interpolation-filters'],\n ['colorProfile', 'color-profile'],\n ['colorRendering', 'color-rendering'],\n ['dominantBaseline', 'dominant-baseline'],\n ['enableBackground', 'enable-background'],\n ['fillOpacity', 'fill-opacity'],\n ['fillRule', 'fill-rule'],\n ['floodColor', 'flood-color'],\n ['floodOpacity', 'flood-opacity'],\n ['fontFamily', 'font-family'],\n ['fontSize', 'font-size'],\n ['fontSizeAdjust', 'font-size-adjust'],\n ['fontStretch', 'font-stretch'],\n ['fontStyle', 'font-style'],\n ['fontVariant', 'font-variant'],\n ['fontWeight', 'font-weight'],\n ['glyphName', 'glyph-name'],\n ['glyphOrientationHorizontal', 'glyph-orientation-horizontal'],\n ['glyphOrientationVertical', 'glyph-orientation-vertical'],\n ['horizAdvX', 'horiz-adv-x'],\n ['horizOriginX', 'horiz-origin-x'],\n ['letterSpacing', 'letter-spacing'],\n ['lightingColor', 'lighting-color'],\n ['markerEnd', 'marker-end'],\n ['markerMid', 'marker-mid'],\n ['markerStart', 'marker-start'],\n ['overlinePosition', 'overline-position'],\n ['overlineThickness', 'overline-thickness'],\n ['panose1', 'panose-1'],\n ['paintOrder', 'paint-order'],\n ['pointerEvents', 'pointer-events'],\n ['renderingIntent', 'rendering-intent'],\n ['shapeRendering', 'shape-rendering'],\n ['stopColor', 'stop-color'],\n ['stopOpacity', 'stop-opacity'],\n ['strikethroughPosition', 'strikethrough-position'],\n ['strikethroughThickness', 'strikethrough-thickness'],\n ['strokeDasharray', 'stroke-dasharray'],\n ['strokeDashoffset', 'stroke-dashoffset'],\n ['strokeLinecap', 'stroke-linecap'],\n ['strokeLinejoin', 'stroke-linejoin'],\n ['strokeMiterlimit', 'stroke-miterlimit'],\n ['strokeOpacity', 'stroke-opacity'],\n ['strokeWidth', 'stroke-width'],\n ['textAnchor', 'text-anchor'],\n ['textDecoration', 'text-decoration'],\n ['textRendering', 'text-rendering'],\n ['underlinePosition', 'underline-position'],\n ['underlineThickness', 'underline-thickness'],\n ['unicodeBidi', 'unicode-bidi'],\n ['unicodeRange', 'unicode-range'],\n ['unitsPerEm', 'units-per-em'],\n ['vAlphabetic', 'v-alphabetic'],\n ['vHanging', 'v-hanging'],\n ['vIdeographic', 'v-ideographic'],\n ['vMathematical', 'v-mathematical'],\n ['vertAdvY', 'vert-adv-y'],\n ['vertOriginX', 'vert-origin-x'],\n ['vertOriginY', 'vert-origin-y'],\n ['wordSpacing', 'word-spacing'],\n ['writingMode', 'writing-mode'],\n ['xHeight', 'x-height'],\n])\n","const EVENT_LISTENER_PROPS = require('./event-listener-props')\nconst SVG_TAGS = require('./svg-tags')\nconst SVG_ATTRIBUTE_TRANSLATIONS = require('./svg-attribute-translations')\nconst EMPTY = ''\n\nconst updateRef = require('./update-ref')\n\nmodule.exports = function (domNode, oldVirtualNode, newVirtualNode, options) {\n const oldProps = oldVirtualNode && oldVirtualNode.props\n const newProps = newVirtualNode.props\n\n let refs, listenerContext\n if (options) {\n refs = options.refs\n listenerContext = options.listenerContext\n }\n updateProps(domNode, oldVirtualNode, oldProps, newVirtualNode, newProps)\n if (refs) updateRef(domNode, oldProps && oldProps.ref, newProps && newProps.ref, refs)\n updateEventListeners(domNode, oldVirtualNode, newVirtualNode, listenerContext)\n}\n\n// Using var to avoid \"Unsupported phi use of variable\" deoptimization in Chrome 56\nfunction updateProps (domNode, oldVirtualNode, oldProps, newVirtualNode, newProps) {\n if (oldProps) {\n for (var name in oldProps) {\n if (name === 'ref' || name === 'on') continue\n if (name in EVENT_LISTENER_PROPS) continue\n if (!newProps || !(name in newProps)) {\n if (name === 'dataset') {\n updateProps(domNode.dataset, null, oldProps && oldProps.dataset, null, null)\n } else if (name !== 'innerHTML' && oldVirtualNode && SVG_TAGS.has(oldVirtualNode.tag)) {\n domNode.removeAttribute(SVG_ATTRIBUTE_TRANSLATIONS.get(name) || name)\n } else {\n // Clear property for objects that don't support deletion (e.g. style\n // or className). If we used null instead of an empty string, the DOM\n // could sometimes stringify the value and mistakenly assign 'null'.\n domNode[name] = EMPTY\n delete domNode[name]\n }\n }\n }\n }\n\n if (newProps) {\n for (var name in newProps) {\n if (name === 'ref' || name === 'on') continue\n if (name in EVENT_LISTENER_PROPS) continue\n var oldValue = oldProps && oldProps[name]\n var newValue = newProps[name]\n if (name === 'dataset') {\n updateNestedProps(domNode.dataset, oldValue, newValue, false)\n } else if (name === 'style' && typeof newValue !== 'string') {\n if (typeof oldValue === 'string') {\n domNode.style = ''\n oldValue = null\n }\n updateNestedProps(domNode.style, oldValue, newValue, true)\n } else if (name === 'attributes') {\n updateAttributes(domNode, oldValue, newValue)\n } else {\n if (newValue !== oldValue) {\n if (name !== 'innerHTML' && newVirtualNode && SVG_TAGS.has(newVirtualNode.tag)) {\n domNode.setAttribute(SVG_ATTRIBUTE_TRANSLATIONS.get(name) || name, newValue)\n } else if (newVirtualNode && newVirtualNode.tag === 'input'\n && name === 'value' && domNode[name] === newValue) {\n // Do not update `value` of an `input` unless it differs.\n // Every change will reset the cursor position.\n } else {\n domNode[name] = newValue\n }\n }\n }\n }\n }\n}\n\nfunction updateNestedProps (domProps, oldProps, newProps, isStyleObject) {\n if (oldProps) {\n for (var name in oldProps) {\n if (!newProps || !(name in newProps)) {\n if (isStyleObject) {\n domProps[name] = EMPTY\n } else {\n delete domProps[name]\n }\n }\n }\n }\n\n if (newProps) {\n for (var name in newProps) {\n const oldValue = oldProps && oldProps[name]\n const newValue = newProps[name]\n if (newValue !== oldValue) {\n domProps[name] = newValue\n }\n }\n }\n}\n\nfunction updateAttributes (domNode, oldAttributes, newAttributes) {\n if (oldAttributes) {\n for (var name in oldAttributes) {\n if (!newAttributes || !(name in newAttributes)) {\n domNode.removeAttribute(name)\n }\n }\n }\n\n if (newAttributes) {\n for (var name in newAttributes) {\n const oldValue = oldAttributes && oldAttributes[name]\n const newValue = newAttributes[name]\n if (newValue !== oldValue) {\n domNode.setAttribute(name, newValue)\n }\n }\n }\n}\n\nfunction updateEventListeners (domNode, oldVirtualNode, newVirtualNode, listenerContext) {\n const oldListeners = oldVirtualNode && oldVirtualNode.props && oldVirtualNode.props.on\n const newListeners = newVirtualNode.props && newVirtualNode.props.on\n\n for (const eventName in oldListeners) {\n if (!(newListeners && eventName in newListeners)) {\n let listenerToRemove\n if (oldVirtualNode && oldVirtualNode.boundListeners && oldVirtualNode.boundListeners[eventName]) {\n listenerToRemove = oldVirtualNode.boundListeners[eventName]\n } else {\n listenerToRemove = oldListeners[eventName]\n }\n domNode.removeEventListener(eventName, listenerToRemove)\n }\n }\n\n for (const eventName in newListeners) {\n const oldListener = oldListeners && oldListeners[eventName]\n const newListener = newListeners[eventName]\n\n if (newListener !== oldListener) {\n if (oldListener) {\n let listenerToRemove\n if (oldVirtualNode && oldVirtualNode.boundListeners && oldVirtualNode.boundListeners[eventName]) {\n listenerToRemove = oldVirtualNode.boundListeners[eventName]\n } else {\n listenerToRemove = oldListener\n }\n domNode.removeEventListener(eventName, listenerToRemove)\n }\n if (newListener) {\n let listenerToAdd\n if (listenerContext) {\n listenerToAdd = newListener.bind(listenerContext)\n if (!newVirtualNode.boundListeners) newVirtualNode.boundListeners = {}\n newVirtualNode.boundListeners[eventName] = listenerToAdd\n } else {\n listenerToAdd = newListener\n }\n domNode.addEventListener(eventName, listenerToAdd)\n }\n }\n }\n}\n","const updateProps = require('./update-props')\nconst SVG_TAGS = require('./svg-tags')\n\nfunction render (virtualNode, options) {\n let domNode\n if (virtualNode.text != null) {\n domNode = document.createTextNode(virtualNode.text)\n } else {\n const {tag, children} = virtualNode\n let {props, context} = virtualNode\n\n if (context) {\n options = {refs: context.refs, listenerContext: context}\n }\n\n if (typeof tag === 'function') {\n let ref\n if (props && props.ref) {\n ref = props.ref\n }\n const component = new tag(props || {}, children)\n virtualNode.component = component\n domNode = component.element\n if (typeof ref === \"function\") {\n ref(component)\n } else if (options && options.refs && ref) {\n options.refs[ref] = component\n }\n } else if (SVG_TAGS.has(tag)) {\n domNode = document.createElementNS(\"http://www.w3.org/2000/svg\", tag);\n if (children) addChildren(domNode, children, options)\n if (props) updateProps(domNode, null, virtualNode, options)\n } else {\n domNode = document.createElement(tag)\n if (children) addChildren(domNode, children, options)\n if (props) updateProps(domNode, null, virtualNode, options)\n }\n }\n virtualNode.domNode = domNode\n return domNode\n}\n\nfunction addChildren (parent, children, options) {\n for (let i = 0; i < children.length; i++) {\n parent.appendChild(render(children[i], options))\n }\n}\n\nmodule.exports = render\n","module.exports = function updateRef (domNode, oldRefName, newRefName, refs) {\n if (newRefName !== oldRefName) {\n if (typeof oldRefName === 'function') oldRefName(null)\n else if (oldRefName && refs[oldRefName] === domNode) delete refs[oldRefName]\n if (typeof newRefName === 'function') newRefName(domNode)\n else if (newRefName) refs[newRefName] = domNode\n }\n}\n","const render = require('./render')\nconst updateProps = require('./update-props')\nconst updateRef = require('./update-ref')\n\nfunction patch (oldVirtualNode, newVirtualNode, options) {\n const oldNode = oldVirtualNode.domNode\n\n if (newVirtualNode === oldVirtualNode) return oldNode\n\n if (virtualNodesAreEqual(oldVirtualNode, newVirtualNode)) {\n let newNode\n if (newVirtualNode.text != null) {\n oldNode.nodeValue = newVirtualNode.text\n newNode = oldNode\n } else {\n if (typeof newVirtualNode.tag === 'function') {\n newNode = updateComponent(oldVirtualNode, newVirtualNode, options)\n } else {\n updateChildren(oldNode, oldVirtualNode.children, newVirtualNode.children, options)\n updateProps(oldNode, oldVirtualNode, newVirtualNode, options)\n newNode = oldNode\n }\n }\n newVirtualNode.domNode = newNode\n if (newNode !== oldNode && oldNode.parentNode) {\n oldNode.parentNode.replaceChild(newNode, oldNode)\n }\n return newNode\n } else {\n const parentNode = oldNode.parentNode\n const nextSibling = oldNode.nextSibling\n removeVirtualNode(oldVirtualNode, options && options.refs)\n const newNode = render(newVirtualNode, options)\n if (parentNode) parentNode.insertBefore(newNode, nextSibling)\n newVirtualNode.domNode = newNode\n return newNode\n }\n}\n\nfunction updateComponent (oldVirtualNode, newVirtualNode, options) {\n const {component, props: oldProps} = oldVirtualNode\n let {props: newProps, children: newChildren} = newVirtualNode\n newVirtualNode.component = component\n const refs = options && options.refs\n if (refs) updateRef(component, oldProps && oldProps.ref, newProps && newProps.ref, refs)\n component.update(newProps || {}, newChildren)\n return component.element\n}\n\nlet mapPool = [new Map(), new Map(), new Map(), new Map()]\n\nfunction updateChildren (parentElement, oldChildren, newChildren, options) {\n var oldStartIndex = 0\n var oldEndIndex = oldChildren.length - 1\n var oldStartChild = oldChildren[0]\n var oldEndChild = oldChildren[oldEndIndex]\n\n var newStartIndex = 0\n var newEndIndex = newChildren.length - 1\n var newStartChild = newChildren[0]\n var newEndChild = newChildren[newEndIndex]\n\n var oldIndicesByKey\n\n while (oldStartIndex <= oldEndIndex && newStartIndex <= newEndIndex) {\n if (!oldStartChild) {\n oldStartChild = oldChildren[++oldStartIndex]\n } else if (!oldEndChild) {\n oldEndChild = oldChildren[--oldEndIndex]\n } else if (virtualNodesAreEqual(oldStartChild, newStartChild)) {\n patch(oldStartChild, newStartChild, options)\n oldStartChild = oldChildren[++oldStartIndex]\n newStartChild = newChildren[++newStartIndex]\n } else if (virtualNodesAreEqual(oldEndChild, newEndChild)) {\n patch(oldEndChild, newEndChild, options)\n oldEndChild = oldChildren[--oldEndIndex]\n newEndChild = newChildren[--newEndIndex]\n } else if (virtualNodesAreEqual(oldStartChild, newEndChild)) {\n patch(oldStartChild, newEndChild, options)\n parentElement.insertBefore(oldStartChild.domNode, oldEndChild.domNode.nextSibling)\n oldStartChild = oldChildren[++oldStartIndex]\n newEndChild = newChildren[--newEndIndex]\n } else if (virtualNodesAreEqual(oldEndChild, newStartChild)) {\n patch(oldEndChild, newStartChild, options)\n parentElement.insertBefore(oldEndChild.domNode, oldStartChild.domNode);\n oldEndChild = oldChildren[--oldEndIndex]\n newStartChild = newChildren[++newStartIndex]\n } else {\n if (!oldIndicesByKey) {\n if (mapPool.length > 0) {\n oldIndicesByKey = mapPool.pop()\n oldIndicesByKey.clear()\n } else {\n oldIndicesByKey = new Map()\n }\n mapOldKeysToIndices(oldIndicesByKey, oldChildren, oldStartIndex, oldEndIndex)\n }\n\n var key = getKey(newStartChild)\n var oldIndex = key ? oldIndicesByKey.get(key) : null\n if (oldIndex == null) {\n parentElement.insertBefore(render(newStartChild, options), oldStartChild.domNode)\n newStartChild = newChildren[++newStartIndex]\n } else {\n var oldChildToMove = oldChildren[oldIndex]\n patch(oldChildToMove, newStartChild, options)\n oldChildren[oldIndex] = undefined\n parentElement.insertBefore(oldChildToMove.domNode, oldStartChild.domNode)\n newStartChild = newChildren[++newStartIndex]\n }\n }\n }\n\n if (oldStartIndex > oldEndIndex) {\n var subsequentElement = newChildren[newEndIndex + 1] ? newChildren[newEndIndex + 1].domNode : null\n for (let i = newStartIndex; i <= newEndIndex; i++) {\n parentElement.insertBefore(render(newChildren[i], options), subsequentElement)\n }\n } else if (newStartIndex > newEndIndex) {\n for (let i = oldStartIndex; i <= oldEndIndex; i++) {\n var child = oldChildren[i]\n if (child) removeVirtualNode(child, options && options.refs)\n }\n }\n\n if (oldIndicesByKey) mapPool.push(oldIndicesByKey)\n}\n\nfunction removeVirtualNode (virtualNode, refs, removeDOMNode = true) {\n const {domNode, props, children, component} = virtualNode\n const ref = props && props.ref\n if (component) {\n if (typeof ref === 'function') ref(null)\n else if (refs && ref && refs[ref] === component) delete refs[ref]\n if (component.destroy) component.destroy()\n } else {\n if (typeof ref === 'function') ref(null)\n else if (refs && ref && refs[ref] === domNode) delete refs[ref]\n if (children) {\n for (let i = 0; i < children.length; i++) {\n removeVirtualNode(children[i], refs, false)\n }\n }\n }\n\n if (removeDOMNode) domNode.remove()\n}\n\nfunction virtualNodesAreEqual (oldVirtualNode, newVirtualNode) {\n return (\n getKey(oldVirtualNode) === getKey(newVirtualNode)\n && oldVirtualNode.tag === newVirtualNode.tag\n )\n}\n\nfunction getKey (virtualNode) {\n return virtualNode.props ? virtualNode.props.key : undefined\n}\n\nfunction mapOldKeysToIndices (oldIndicesByKey, children, startIndex, endIndex) {\n for (let i = startIndex; i <= endIndex; i++) {\n const key = getKey(children[i])\n if (key) oldIndicesByKey.set(key, i)\n }\n return oldIndicesByKey\n}\n\nmodule.exports = patch\n","// If the scheduler is not customized via `etch.setScheduler`, an instance of\n// this class will be used to schedule updates to the document. The\n// `updateDocument` method accepts functions to be run at some point in the\n// future, then runs them on the next animation frame.\nmodule.exports = class DefaultScheduler {\n constructor () {\n this.updateRequests = []\n this.readRequests = []\n this.pendingAnimationFrame = null\n this.performUpdates = this.performUpdates.bind(this)\n this.performingUpdates = false\n }\n\n // Enqueues functions that write to the DOM to be performed on the next\n // animation frame. Functions passed to this method should *never* read from\n // the DOM, because that could cause synchronous reflows.\n updateDocument (fn) {\n this.updateRequests.push(fn)\n if (!this.pendingAnimationFrame) {\n this.pendingAnimationFrame = window.requestAnimationFrame(this.performUpdates)\n }\n }\n\n readDocument (fn) {\n this.readRequests.push(fn)\n if (!this.pendingAnimationFrame) {\n this.pendingAnimationFrame = window.requestAnimationFrame(this.performUpdates)\n }\n }\n\n // Returns a promise that will resolve at the end of the next update cycle,\n // after all the functions passed to `updateDocument` and `updateDocumentSync`\n // have been run.\n getNextUpdatePromise () {\n if (!this.nextUpdatePromise) {\n this.nextUpdatePromise = new Promise(resolve => {\n this.resolveNextUpdatePromise = resolve\n })\n }\n return this.nextUpdatePromise\n }\n\n // Performs all the pending document updates. If running these update\n // functions causes *more* updates to be enqueued, they are run synchronously\n // in this update cycle without waiting for another frame.\n performUpdates () {\n while (this.updateRequests.length > 0) {\n this.updateRequests.shift()()\n }\n\n // We don't clear the pending frame until all update requests are processed.\n // This ensures updates requested within other updates are processed in the\n // current frame.\n this.pendingAnimationFrame = null\n\n // Now that updates are processed, we can perform all pending document reads\n // without the risk of interleaving them with writes and causing layout\n // thrashing.\n while (this.readRequests.length > 0) {\n this.readRequests.shift()()\n }\n\n if (this.nextUpdatePromise) {\n let resolveNextUpdatePromise = this.resolveNextUpdatePromise\n this.nextUpdatePromise = null\n this.resolveNextUpdatePromise = null\n resolveNextUpdatePromise()\n }\n }\n}\n","// This file implements getter and setter functions for a scheduler to be used\n// by this library when updating the DOM. The scheduler's job is to ensure that\n// DOM interaction is performed efficiently. When using `etch` in Atom, you\n// should tell `etch` to use Atom's scheduler by calling\n// `setScheduler(atom.views)`.\n//\n// Schedulers should support the following interface:\n// * `updateDocument(fn)` This method is asynchronous. It enqueues functions to\n// be executed later.\n// * `getNextUpdatePromise()` This function should return a promise that\n// resolves after all pending document update functions have been invoked.\n//\n// Schedulers could support the following optional methods, which are supported\n// by Atom's scheduler.\n//\n// * `readDocument` This method can be invoked by clients other than `etch` when\n// it is necessary to read from the DOM. Functions enqueued via this method\n// should not be run until all document update functions have been executed.\n// Batching updates and reads in this way will prevent forced synchronous\n// reflows.\n// * `pollDocument` This method is similar to `readDocument`, but it runs the\n// associated functions repeatedly. Again, they should be scheduled in such a\n// way so as to avoid synchronous reflows.\n\nconst DefaultScheduler = require('./default-scheduler')\n\nlet scheduler = null\n\nmodule.exports.setScheduler = function setScheduler (customScheduler) {\n scheduler = customScheduler\n}\n\nmodule.exports.getScheduler = function getScheduler () {\n if (!scheduler) {\n scheduler = new DefaultScheduler()\n }\n return scheduler\n}\n","const render = require('./render')\nconst patch = require('./patch')\nconst {getScheduler} = require('./scheduler-assignment')\n\nconst componentsWithPendingUpdates = new WeakSet()\nlet syncUpdatesInProgressCounter = 0\nlet syncDestructionsInProgressCounter = 0\n\nfunction isValidVirtualNode (virtualNode) {\n return virtualNode != null && virtualNode !== false\n}\n\nfunction applyContext (context, virtualNode) {\n virtualNode.context = context\n if (virtualNode.ambiguous) {\n virtualNode.ambiguous.forEach(node => {\n node.context = context\n })\n delete virtualNode.ambiguous\n }\n}\n\n// This function associates a component object with a DOM element by calling\n// the components `render` method, assigning an `.element` property on the\n// object and also returning the element.\n//\n// It also assigns a `virtualNode` property based on the return value of the\n// `render` method. This will be used later by `performElementUpdate` to diff\n// the new results of `render` with the previous results when updating the\n// component's element.\n//\n// Finally, this function also associates the component with a `refs` object,\n// which is populated with references to elements based on `ref` properties on\n// nodes of the `virtual-dom` tree. Before calling into `virtual-dom` to create\n// the DOM tree, it pushes this `refs` object to a shared stack so it can be\n// accessed by hooks during the creation of individual elements.\nfunction initialize(component) {\n if (typeof component.update !== 'function') {\n throw new Error('Etch components must implement `update(props, children)`.')\n }\n\n let virtualNode = component.render()\n if (!isValidVirtualNode(virtualNode)) {\n let namePart = component.constructor && component.constructor.name ? ' in ' + component.constructor.name : ''\n throw new Error('invalid falsy value ' + virtualNode + ' returned from render()' + namePart)\n }\n\n applyContext(component, virtualNode)\n\n component.refs = {}\n component.virtualNode = virtualNode\n component.element = render(component.virtualNode, {\n refs: component.refs, listenerContext: component\n })\n}\n\n// This function receives a component that has already been associated with an\n// element via a previous call to `initialize` and updates this element by\n// calling `render` on the component.\n//\n// When called in normal circumstances, it uses the scheduler to defer this\n// update until the next animation frame, and will only perform one update of a\n// given component in a given frame. This means you can call `update`\n// repeatedly in a given tick without causing redundant updates.\n//\n// If this function called during another synchronous update (for example, as a\n// result of a call to `update` on a child component), the update is performed\n// synchronously.\n//\n// Returns a promise that will resolve when the requested update has been\n// completed.\nfunction update (component, replaceNode=true) {\n if (syncUpdatesInProgressCounter > 0) {\n updateSync(component, replaceNode)\n return Promise.resolve()\n }\n\n let scheduler = getScheduler()\n\n if (!componentsWithPendingUpdates.has(component)) {\n componentsWithPendingUpdates.add(component)\n scheduler.updateDocument(function () {\n componentsWithPendingUpdates.delete(component)\n updateSync(component, replaceNode)\n })\n }\n\n return scheduler.getNextUpdatePromise()\n}\n\n// Synchronsly updates the DOM element associated with a component object. .\n// This method assumes the presence of `.element` and `.virtualNode`\n// properties on the component, which are assigned in the `initialize`\n// function.\n//\n// It calls `render` on the component to obtain the desired state of the DOM,\n// then `diff`s it with the previous state and `patch`es the element based on\n// the resulting diff. During the patch operation, it pushes the component's\n// `refs` object to a shared stack so that references to DOM elements can be\n// updated.\n//\n// If `update` is called during the invocation of `updateSync`,\n// the requests are processed synchronously as well. We track whether this is\n// the case by incrementing and decrementing `syncUpdatesInProgressCounter`\n// around the call.\n//\n// For now, etch does not allow the root tag of the `render` method to change\n// between invocations, because we want to preserve a one-to-one relationship\n// between component objects and DOM elements for simplicity.\nfunction updateSync (component, replaceNode=true) {\n if (!isValidVirtualNode(component.virtualNode)) {\n throw new Error(`${component.constructor ? component.constructor.name + ' instance' : component} is not associated with a valid virtualNode. Perhaps this component was never initialized?`)\n }\n\n if (component.element == null) {\n throw new Error(`${component.constructor ? component.constructor.name + ' instance' : component} is not associated with a DOM element. Perhaps this component was never initialized?`)\n }\n\n let newVirtualNode = component.render()\n if (!isValidVirtualNode(newVirtualNode)) {\n const namePart = component.constructor && component.constructor.name ? ' in ' + component.constructor.name : ''\n throw new Error('invalid falsy value ' + newVirtualNode + ' returned from render()' + namePart)\n }\n\n applyContext(component, newVirtualNode)\n\n syncUpdatesInProgressCounter++\n let oldVirtualNode = component.virtualNode\n let oldDomNode = component.element\n let newDomNode = patch(oldVirtualNode, newVirtualNode, {\n refs: component.refs,\n listenerContext: component\n })\n component.virtualNode = newVirtualNode\n if (newDomNode !== oldDomNode && !replaceNode) {\n throw new Error('The root node type changed on update, but the update was performed with the replaceNode option set to false')\n } else {\n component.element = newDomNode\n }\n\n // We can safely perform additional writes after a DOM update synchronously,\n // but any reads need to be deferred until all writes are completed to avoid\n // DOM thrashing. Requested reads occur at the end of the the current frame\n // if this method was invoked via the scheduler. Otherwise, if `updateSync`\n // was invoked outside of the scheduler, the default scheduler will defer\n // reads until the next animation frame.\n if (typeof component.writeAfterUpdate === 'function') {\n component.writeAfterUpdate()\n }\n if (typeof component.readAfterUpdate === 'function') {\n getScheduler().readDocument(function () {\n component.readAfterUpdate()\n })\n }\n\n syncUpdatesInProgressCounter--\n}\n\n// Removes the component's associated element and calls `destroy` on any child\n// components. Normally, this function is asynchronous and will perform the\n// destruction on the next animation frame. If called as the result of another\n// update or destruction, it calls `destroy` on child components synchronously.\n// If called as the result of destroying a component higher in the DOM, the\n// element is not removed to avoid redundant DOM manipulation. Returns a promise\n// that resolves when the destruction is completed.\nfunction destroy (component, removeNode=true) {\n if (syncUpdatesInProgressCounter > 0 || syncDestructionsInProgressCounter > 0) {\n destroySync(component, removeNode)\n return Promise.resolve()\n }\n\n let scheduler = getScheduler()\n scheduler.updateDocument(function () {\n destroySync(component, removeNode)\n })\n return scheduler.getNextUpdatePromise()\n}\n\n// A synchronous version of `destroy`.\n//\n// Note that we track whether `destroy` calls are in progress and only remove\n// the element if we are not a nested call.\nfunction destroySync (component, removeNode=true) {\n syncDestructionsInProgressCounter++\n destroyChildComponents(component.virtualNode)\n if (syncDestructionsInProgressCounter === 1 && removeNode) component.element.remove()\n syncDestructionsInProgressCounter--\n}\n\nfunction destroyChildComponents(virtualNode) {\n if (virtualNode.component && typeof virtualNode.component.destroy === 'function') {\n virtualNode.component.destroy()\n } else if (virtualNode.children) {\n virtualNode.children.forEach(destroyChildComponents)\n }\n}\n\nmodule.exports = {\n initialize,\n update, updateSync,\n destroy, destroySync\n}\n","const dom = require('./dom')\nconst render = require('./render')\nconst {initialize, update, updateSync, destroy, destroySync} = require('./component-helpers')\nconst {setScheduler, getScheduler} = require('./scheduler-assignment')\n\nmodule.exports = {\n dom, render,\n initialize, update, updateSync, destroy, destroySync,\n setScheduler, getScheduler\n}\n","export function handlePromise(promise: Promise | undefined): void {\n if (promise === undefined) return\n // tslint:disable-next-line:strict-type-predicates no-unbound-method\n if (typeof promise.catch !== \"function\") {\n atom.notifications.addFatalError(\n \"Atom-Typescript: non-promise passed to handlePromise. Please report this.\",\n {\n stack: new Error().stack,\n dismissable: true,\n },\n )\n return\n }\n promise.catch((err: Error) => {\n atom.notifications.addFatalError(`Atom-Typescript error: ${err.message}`, {\n detail: err.toString(),\n stack: err.stack,\n dismissable: true,\n })\n })\n}\n","/**\n * @license\n * Lodash \n * Copyright OpenJS Foundation and other contributors \n * Released under MIT license \n * Based on Underscore.js 1.8.3 \n * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors\n */\n;(function() {\n\n /** Used as a safe reference for `undefined` in pre-ES5 environments. */\n var undefined;\n\n /** Used as the semantic version number. */\n var VERSION = '4.17.21';\n\n /** Used as the size to enable large array optimizations. */\n var LARGE_ARRAY_SIZE = 200;\n\n /** Error message constants. */\n var CORE_ERROR_TEXT = 'Unsupported core-js use. Try https://npms.io/search?q=ponyfill.',\n FUNC_ERROR_TEXT = 'Expected a function',\n INVALID_TEMPL_VAR_ERROR_TEXT = 'Invalid `variable` option passed into `_.template`';\n\n /** Used to stand-in for `undefined` hash values. */\n var HASH_UNDEFINED = '__lodash_hash_undefined__';\n\n /** Used as the maximum memoize cache size. */\n var MAX_MEMOIZE_SIZE = 500;\n\n /** Used as the internal argument placeholder. */\n var PLACEHOLDER = '__lodash_placeholder__';\n\n /** Used to compose bitmasks for cloning. */\n var CLONE_DEEP_FLAG = 1,\n CLONE_FLAT_FLAG = 2,\n CLONE_SYMBOLS_FLAG = 4;\n\n /** Used to compose bitmasks for value comparisons. */\n var COMPARE_PARTIAL_FLAG = 1,\n COMPARE_UNORDERED_FLAG = 2;\n\n /** Used to compose bitmasks for function metadata. */\n var WRAP_BIND_FLAG = 1,\n WRAP_BIND_KEY_FLAG = 2,\n WRAP_CURRY_BOUND_FLAG = 4,\n WRAP_CURRY_FLAG = 8,\n WRAP_CURRY_RIGHT_FLAG = 16,\n WRAP_PARTIAL_FLAG = 32,\n WRAP_PARTIAL_RIGHT_FLAG = 64,\n WRAP_ARY_FLAG = 128,\n WRAP_REARG_FLAG = 256,\n WRAP_FLIP_FLAG = 512;\n\n /** Used as default options for `_.truncate`. */\n var DEFAULT_TRUNC_LENGTH = 30,\n DEFAULT_TRUNC_OMISSION = '...';\n\n /** Used to detect hot functions by number of calls within a span of milliseconds. */\n var HOT_COUNT = 800,\n HOT_SPAN = 16;\n\n /** Used to indicate the type of lazy iteratees. */\n var LAZY_FILTER_FLAG = 1,\n LAZY_MAP_FLAG = 2,\n LAZY_WHILE_FLAG = 3;\n\n /** Used as references for various `Number` constants. */\n var INFINITY = 1 / 0,\n MAX_SAFE_INTEGER = 9007199254740991,\n MAX_INTEGER = 1.7976931348623157e+308,\n NAN = 0 / 0;\n\n /** Used as references for the maximum length and index of an array. */\n var MAX_ARRAY_LENGTH = 4294967295,\n MAX_ARRAY_INDEX = MAX_ARRAY_LENGTH - 1,\n HALF_MAX_ARRAY_LENGTH = MAX_ARRAY_LENGTH >>> 1;\n\n /** Used to associate wrap methods with their bit flags. */\n var wrapFlags = [\n ['ary', WRAP_ARY_FLAG],\n ['bind', WRAP_BIND_FLAG],\n ['bindKey', WRAP_BIND_KEY_FLAG],\n ['curry', WRAP_CURRY_FLAG],\n ['curryRight', WRAP_CURRY_RIGHT_FLAG],\n ['flip', WRAP_FLIP_FLAG],\n ['partial', WRAP_PARTIAL_FLAG],\n ['partialRight', WRAP_PARTIAL_RIGHT_FLAG],\n ['rearg', WRAP_REARG_FLAG]\n ];\n\n /** `Object#toString` result references. */\n var argsTag = '[object Arguments]',\n arrayTag = '[object Array]',\n asyncTag = '[object AsyncFunction]',\n boolTag = '[object Boolean]',\n dateTag = '[object Date]',\n domExcTag = '[object DOMException]',\n errorTag = '[object Error]',\n funcTag = '[object Function]',\n genTag = '[object GeneratorFunction]',\n mapTag = '[object Map]',\n numberTag = '[object Number]',\n nullTag = '[object Null]',\n objectTag = '[object Object]',\n promiseTag = '[object Promise]',\n proxyTag = '[object Proxy]',\n regexpTag = '[object RegExp]',\n setTag = '[object Set]',\n stringTag = '[object String]',\n symbolTag = '[object Symbol]',\n undefinedTag = '[object Undefined]',\n weakMapTag = '[object WeakMap]',\n weakSetTag = '[object WeakSet]';\n\n var arrayBufferTag = '[object ArrayBuffer]',\n dataViewTag = '[object DataView]',\n float32Tag = '[object Float32Array]',\n float64Tag = '[object Float64Array]',\n int8Tag = '[object Int8Array]',\n int16Tag = '[object Int16Array]',\n int32Tag = '[object Int32Array]',\n uint8Tag = '[object Uint8Array]',\n uint8ClampedTag = '[object Uint8ClampedArray]',\n uint16Tag = '[object Uint16Array]',\n uint32Tag = '[object Uint32Array]';\n\n /** Used to match empty string literals in compiled template source. */\n var reEmptyStringLeading = /\\b__p \\+= '';/g,\n reEmptyStringMiddle = /\\b(__p \\+=) '' \\+/g,\n reEmptyStringTrailing = /(__e\\(.*?\\)|\\b__t\\)) \\+\\n'';/g;\n\n /** Used to match HTML entities and HTML characters. */\n var reEscapedHtml = /&(?:amp|lt|gt|quot|#39);/g,\n reUnescapedHtml = /[&<>\"']/g,\n reHasEscapedHtml = RegExp(reEscapedHtml.source),\n reHasUnescapedHtml = RegExp(reUnescapedHtml.source);\n\n /** Used to match template delimiters. */\n var reEscape = /<%-([\\s\\S]+?)%>/g,\n reEvaluate = /<%([\\s\\S]+?)%>/g,\n reInterpolate = /<%=([\\s\\S]+?)%>/g;\n\n /** Used to match property names within property paths. */\n var reIsDeepProp = /\\.|\\[(?:[^[\\]]*|([\"'])(?:(?!\\1)[^\\\\]|\\\\.)*?\\1)\\]/,\n reIsPlainProp = /^\\w*$/,\n rePropName = /[^.[\\]]+|\\[(?:(-?\\d+(?:\\.\\d+)?)|([\"'])((?:(?!\\2)[^\\\\]|\\\\.)*?)\\2)\\]|(?=(?:\\.|\\[\\])(?:\\.|\\[\\]|$))/g;\n\n /**\n * Used to match `RegExp`\n * [syntax characters](http://ecma-international.org/ecma-262/7.0/#sec-patterns).\n */\n var reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g,\n reHasRegExpChar = RegExp(reRegExpChar.source);\n\n /** Used to match leading whitespace. */\n var reTrimStart = /^\\s+/;\n\n /** Used to match a single whitespace character. */\n var reWhitespace = /\\s/;\n\n /** Used to match wrap detail comments. */\n var reWrapComment = /\\{(?:\\n\\/\\* \\[wrapped with .+\\] \\*\\/)?\\n?/,\n reWrapDetails = /\\{\\n\\/\\* \\[wrapped with (.+)\\] \\*/,\n reSplitDetails = /,? & /;\n\n /** Used to match words composed of alphanumeric characters. */\n var reAsciiWord = /[^\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\x7f]+/g;\n\n /**\n * Used to validate the `validate` option in `_.template` variable.\n *\n * Forbids characters which could potentially change the meaning of the function argument definition:\n * - \"(),\" (modification of function parameters)\n * - \"=\" (default value)\n * - \"[]{}\" (destructuring of function parameters)\n * - \"/\" (beginning of a comment)\n * - whitespace\n */\n var reForbiddenIdentifierChars = /[()=,{}\\[\\]\\/\\s]/;\n\n /** Used to match backslashes in property paths. */\n var reEscapeChar = /\\\\(\\\\)?/g;\n\n /**\n * Used to match\n * [ES template delimiters](http://ecma-international.org/ecma-262/7.0/#sec-template-literal-lexical-components).\n */\n var reEsTemplate = /\\$\\{([^\\\\}]*(?:\\\\.[^\\\\}]*)*)\\}/g;\n\n /** Used to match `RegExp` flags from their coerced string values. */\n var reFlags = /\\w*$/;\n\n /** Used to detect bad signed hexadecimal string values. */\n var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;\n\n /** Used to detect binary string values. */\n var reIsBinary = /^0b[01]+$/i;\n\n /** Used to detect host constructors (Safari). */\n var reIsHostCtor = /^\\[object .+?Constructor\\]$/;\n\n /** Used to detect octal string values. */\n var reIsOctal = /^0o[0-7]+$/i;\n\n /** Used to detect unsigned integer values. */\n var reIsUint = /^(?:0|[1-9]\\d*)$/;\n\n /** Used to match Latin Unicode letters (excluding mathematical operators). */\n var reLatin = /[\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\xff\\u0100-\\u017f]/g;\n\n /** Used to ensure capturing order of template delimiters. */\n var reNoMatch = /($^)/;\n\n /** Used to match unescaped characters in compiled string literals. */\n var reUnescapedString = /['\\n\\r\\u2028\\u2029\\\\]/g;\n\n /** Used to compose unicode character classes. */\n var rsAstralRange = '\\\\ud800-\\\\udfff',\n rsComboMarksRange = '\\\\u0300-\\\\u036f',\n reComboHalfMarksRange = '\\\\ufe20-\\\\ufe2f',\n rsComboSymbolsRange = '\\\\u20d0-\\\\u20ff',\n rsComboRange = rsComboMarksRange + reComboHalfMarksRange + rsComboSymbolsRange,\n rsDingbatRange = '\\\\u2700-\\\\u27bf',\n rsLowerRange = 'a-z\\\\xdf-\\\\xf6\\\\xf8-\\\\xff',\n rsMathOpRange = '\\\\xac\\\\xb1\\\\xd7\\\\xf7',\n rsNonCharRange = '\\\\x00-\\\\x2f\\\\x3a-\\\\x40\\\\x5b-\\\\x60\\\\x7b-\\\\xbf',\n rsPunctuationRange = '\\\\u2000-\\\\u206f',\n rsSpaceRange = ' \\\\t\\\\x0b\\\\f\\\\xa0\\\\ufeff\\\\n\\\\r\\\\u2028\\\\u2029\\\\u1680\\\\u180e\\\\u2000\\\\u2001\\\\u2002\\\\u2003\\\\u2004\\\\u2005\\\\u2006\\\\u2007\\\\u2008\\\\u2009\\\\u200a\\\\u202f\\\\u205f\\\\u3000',\n rsUpperRange = 'A-Z\\\\xc0-\\\\xd6\\\\xd8-\\\\xde',\n rsVarRange = '\\\\ufe0e\\\\ufe0f',\n rsBreakRange = rsMathOpRange + rsNonCharRange + rsPunctuationRange + rsSpaceRange;\n\n /** Used to compose unicode capture groups. */\n var rsApos = \"['\\u2019]\",\n rsAstral = '[' + rsAstralRange + ']',\n rsBreak = '[' + rsBreakRange + ']',\n rsCombo = '[' + rsComboRange + ']',\n rsDigits = '\\\\d+',\n rsDingbat = '[' + rsDingbatRange + ']',\n rsLower = '[' + rsLowerRange + ']',\n rsMisc = '[^' + rsAstralRange + rsBreakRange + rsDigits + rsDingbatRange + rsLowerRange + rsUpperRange + ']',\n rsFitz = '\\\\ud83c[\\\\udffb-\\\\udfff]',\n rsModifier = '(?:' + rsCombo + '|' + rsFitz + ')',\n rsNonAstral = '[^' + rsAstralRange + ']',\n rsRegional = '(?:\\\\ud83c[\\\\udde6-\\\\uddff]){2}',\n rsSurrPair = '[\\\\ud800-\\\\udbff][\\\\udc00-\\\\udfff]',\n rsUpper = '[' + rsUpperRange + ']',\n rsZWJ = '\\\\u200d';\n\n /** Used to compose unicode regexes. */\n var rsMiscLower = '(?:' + rsLower + '|' + rsMisc + ')',\n rsMiscUpper = '(?:' + rsUpper + '|' + rsMisc + ')',\n rsOptContrLower = '(?:' + rsApos + '(?:d|ll|m|re|s|t|ve))?',\n rsOptContrUpper = '(?:' + rsApos + '(?:D|LL|M|RE|S|T|VE))?',\n reOptMod = rsModifier + '?',\n rsOptVar = '[' + rsVarRange + ']?',\n rsOptJoin = '(?:' + rsZWJ + '(?:' + [rsNonAstral, rsRegional, rsSurrPair].join('|') + ')' + rsOptVar + reOptMod + ')*',\n rsOrdLower = '\\\\d*(?:1st|2nd|3rd|(?![123])\\\\dth)(?=\\\\b|[A-Z_])',\n rsOrdUpper = '\\\\d*(?:1ST|2ND|3RD|(?![123])\\\\dTH)(?=\\\\b|[a-z_])',\n rsSeq = rsOptVar + reOptMod + rsOptJoin,\n rsEmoji = '(?:' + [rsDingbat, rsRegional, rsSurrPair].join('|') + ')' + rsSeq,\n rsSymbol = '(?:' + [rsNonAstral + rsCombo + '?', rsCombo, rsRegional, rsSurrPair, rsAstral].join('|') + ')';\n\n /** Used to match apostrophes. */\n var reApos = RegExp(rsApos, 'g');\n\n /**\n * Used to match [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks) and\n * [combining diacritical marks for symbols](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks_for_Symbols).\n */\n var reComboMark = RegExp(rsCombo, 'g');\n\n /** Used to match [string symbols](https://mathiasbynens.be/notes/javascript-unicode). */\n var reUnicode = RegExp(rsFitz + '(?=' + rsFitz + ')|' + rsSymbol + rsSeq, 'g');\n\n /** Used to match complex or compound words. */\n var reUnicodeWord = RegExp([\n rsUpper + '?' + rsLower + '+' + rsOptContrLower + '(?=' + [rsBreak, rsUpper, '$'].join('|') + ')',\n rsMiscUpper + '+' + rsOptContrUpper + '(?=' + [rsBreak, rsUpper + rsMiscLower, '$'].join('|') + ')',\n rsUpper + '?' + rsMiscLower + '+' + rsOptContrLower,\n rsUpper + '+' + rsOptContrUpper,\n rsOrdUpper,\n rsOrdLower,\n rsDigits,\n rsEmoji\n ].join('|'), 'g');\n\n /** Used to detect strings with [zero-width joiners or code points from the astral planes](http://eev.ee/blog/2015/09/12/dark-corners-of-unicode/). */\n var reHasUnicode = RegExp('[' + rsZWJ + rsAstralRange + rsComboRange + rsVarRange + ']');\n\n /** Used to detect strings that need a more robust regexp to match words. */\n var reHasUnicodeWord = /[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;\n\n /** Used to assign default `context` object properties. */\n var contextProps = [\n 'Array', 'Buffer', 'DataView', 'Date', 'Error', 'Float32Array', 'Float64Array',\n 'Function', 'Int8Array', 'Int16Array', 'Int32Array', 'Map', 'Math', 'Object',\n 'Promise', 'RegExp', 'Set', 'String', 'Symbol', 'TypeError', 'Uint8Array',\n 'Uint8ClampedArray', 'Uint16Array', 'Uint32Array', 'WeakMap',\n '_', 'clearTimeout', 'isFinite', 'parseInt', 'setTimeout'\n ];\n\n /** Used to make template sourceURLs easier to identify. */\n var templateCounter = -1;\n\n /** Used to identify `toStringTag` values of typed arrays. */\n var typedArrayTags = {};\n typedArrayTags[float32Tag] = typedArrayTags[float64Tag] =\n typedArrayTags[int8Tag] = typedArrayTags[int16Tag] =\n typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] =\n typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] =\n typedArrayTags[uint32Tag] = true;\n typedArrayTags[argsTag] = typedArrayTags[arrayTag] =\n typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] =\n typedArrayTags[dataViewTag] = typedArrayTags[dateTag] =\n typedArrayTags[errorTag] = typedArrayTags[funcTag] =\n typedArrayTags[mapTag] = typedArrayTags[numberTag] =\n typedArrayTags[objectTag] = typedArrayTags[regexpTag] =\n typedArrayTags[setTag] = typedArrayTags[stringTag] =\n typedArrayTags[weakMapTag] = false;\n\n /** Used to identify `toStringTag` values supported by `_.clone`. */\n var cloneableTags = {};\n cloneableTags[argsTag] = cloneableTags[arrayTag] =\n cloneableTags[arrayBufferTag] = cloneableTags[dataViewTag] =\n cloneableTags[boolTag] = cloneableTags[dateTag] =\n cloneableTags[float32Tag] = cloneableTags[float64Tag] =\n cloneableTags[int8Tag] = cloneableTags[int16Tag] =\n cloneableTags[int32Tag] = cloneableTags[mapTag] =\n cloneableTags[numberTag] = cloneableTags[objectTag] =\n cloneableTags[regexpTag] = cloneableTags[setTag] =\n cloneableTags[stringTag] = cloneableTags[symbolTag] =\n cloneableTags[uint8Tag] = cloneableTags[uint8ClampedTag] =\n cloneableTags[uint16Tag] = cloneableTags[uint32Tag] = true;\n cloneableTags[errorTag] = cloneableTags[funcTag] =\n cloneableTags[weakMapTag] = false;\n\n /** Used to map Latin Unicode letters to basic Latin letters. */\n var deburredLetters = {\n // Latin-1 Supplement block.\n '\\xc0': 'A', '\\xc1': 'A', '\\xc2': 'A', '\\xc3': 'A', '\\xc4': 'A', '\\xc5': 'A',\n '\\xe0': 'a', '\\xe1': 'a', '\\xe2': 'a', '\\xe3': 'a', '\\xe4': 'a', '\\xe5': 'a',\n '\\xc7': 'C', '\\xe7': 'c',\n '\\xd0': 'D', '\\xf0': 'd',\n '\\xc8': 'E', '\\xc9': 'E', '\\xca': 'E', '\\xcb': 'E',\n '\\xe8': 'e', '\\xe9': 'e', '\\xea': 'e', '\\xeb': 'e',\n '\\xcc': 'I', '\\xcd': 'I', '\\xce': 'I', '\\xcf': 'I',\n '\\xec': 'i', '\\xed': 'i', '\\xee': 'i', '\\xef': 'i',\n '\\xd1': 'N', '\\xf1': 'n',\n '\\xd2': 'O', '\\xd3': 'O', '\\xd4': 'O', '\\xd5': 'O', '\\xd6': 'O', '\\xd8': 'O',\n '\\xf2': 'o', '\\xf3': 'o', '\\xf4': 'o', '\\xf5': 'o', '\\xf6': 'o', '\\xf8': 'o',\n '\\xd9': 'U', '\\xda': 'U', '\\xdb': 'U', '\\xdc': 'U',\n '\\xf9': 'u', '\\xfa': 'u', '\\xfb': 'u', '\\xfc': 'u',\n '\\xdd': 'Y', '\\xfd': 'y', '\\xff': 'y',\n '\\xc6': 'Ae', '\\xe6': 'ae',\n '\\xde': 'Th', '\\xfe': 'th',\n '\\xdf': 'ss',\n // Latin Extended-A block.\n '\\u0100': 'A', '\\u0102': 'A', '\\u0104': 'A',\n '\\u0101': 'a', '\\u0103': 'a', '\\u0105': 'a',\n '\\u0106': 'C', '\\u0108': 'C', '\\u010a': 'C', '\\u010c': 'C',\n '\\u0107': 'c', '\\u0109': 'c', '\\u010b': 'c', '\\u010d': 'c',\n '\\u010e': 'D', '\\u0110': 'D', '\\u010f': 'd', '\\u0111': 'd',\n '\\u0112': 'E', '\\u0114': 'E', '\\u0116': 'E', '\\u0118': 'E', '\\u011a': 'E',\n '\\u0113': 'e', '\\u0115': 'e', '\\u0117': 'e', '\\u0119': 'e', '\\u011b': 'e',\n '\\u011c': 'G', '\\u011e': 'G', '\\u0120': 'G', '\\u0122': 'G',\n '\\u011d': 'g', '\\u011f': 'g', '\\u0121': 'g', '\\u0123': 'g',\n '\\u0124': 'H', '\\u0126': 'H', '\\u0125': 'h', '\\u0127': 'h',\n '\\u0128': 'I', '\\u012a': 'I', '\\u012c': 'I', '\\u012e': 'I', '\\u0130': 'I',\n '\\u0129': 'i', '\\u012b': 'i', '\\u012d': 'i', '\\u012f': 'i', '\\u0131': 'i',\n '\\u0134': 'J', '\\u0135': 'j',\n '\\u0136': 'K', '\\u0137': 'k', '\\u0138': 'k',\n '\\u0139': 'L', '\\u013b': 'L', '\\u013d': 'L', '\\u013f': 'L', '\\u0141': 'L',\n '\\u013a': 'l', '\\u013c': 'l', '\\u013e': 'l', '\\u0140': 'l', '\\u0142': 'l',\n '\\u0143': 'N', '\\u0145': 'N', '\\u0147': 'N', '\\u014a': 'N',\n '\\u0144': 'n', '\\u0146': 'n', '\\u0148': 'n', '\\u014b': 'n',\n '\\u014c': 'O', '\\u014e': 'O', '\\u0150': 'O',\n '\\u014d': 'o', '\\u014f': 'o', '\\u0151': 'o',\n '\\u0154': 'R', '\\u0156': 'R', '\\u0158': 'R',\n '\\u0155': 'r', '\\u0157': 'r', '\\u0159': 'r',\n '\\u015a': 'S', '\\u015c': 'S', '\\u015e': 'S', '\\u0160': 'S',\n '\\u015b': 's', '\\u015d': 's', '\\u015f': 's', '\\u0161': 's',\n '\\u0162': 'T', '\\u0164': 'T', '\\u0166': 'T',\n '\\u0163': 't', '\\u0165': 't', '\\u0167': 't',\n '\\u0168': 'U', '\\u016a': 'U', '\\u016c': 'U', '\\u016e': 'U', '\\u0170': 'U', '\\u0172': 'U',\n '\\u0169': 'u', '\\u016b': 'u', '\\u016d': 'u', '\\u016f': 'u', '\\u0171': 'u', '\\u0173': 'u',\n '\\u0174': 'W', '\\u0175': 'w',\n '\\u0176': 'Y', '\\u0177': 'y', '\\u0178': 'Y',\n '\\u0179': 'Z', '\\u017b': 'Z', '\\u017d': 'Z',\n '\\u017a': 'z', '\\u017c': 'z', '\\u017e': 'z',\n '\\u0132': 'IJ', '\\u0133': 'ij',\n '\\u0152': 'Oe', '\\u0153': 'oe',\n '\\u0149': \"'n\", '\\u017f': 's'\n };\n\n /** Used to map characters to HTML entities. */\n var htmlEscapes = {\n '&': '&',\n '<': '<',\n '>': '>',\n '\"': '"',\n \"'\": '''\n };\n\n /** Used to map HTML entities to characters. */\n var htmlUnescapes = {\n '&': '&',\n '<': '<',\n '>': '>',\n '"': '\"',\n ''': \"'\"\n };\n\n /** Used to escape characters for inclusion in compiled string literals. */\n var stringEscapes = {\n '\\\\': '\\\\',\n \"'\": \"'\",\n '\\n': 'n',\n '\\r': 'r',\n '\\u2028': 'u2028',\n '\\u2029': 'u2029'\n };\n\n /** Built-in method references without a dependency on `root`. */\n var freeParseFloat = parseFloat,\n freeParseInt = parseInt;\n\n /** Detect free variable `global` from Node.js. */\n var freeGlobal = typeof global == 'object' && global && global.Object === Object && global;\n\n /** Detect free variable `self`. */\n var freeSelf = typeof self == 'object' && self && self.Object === Object && self;\n\n /** Used as a reference to the global object. */\n var root = freeGlobal || freeSelf || Function('return this')();\n\n /** Detect free variable `exports`. */\n var freeExports = typeof exports == 'object' && exports && !exports.nodeType && exports;\n\n /** Detect free variable `module`. */\n var freeModule = freeExports && typeof module == 'object' && module && !module.nodeType && module;\n\n /** Detect the popular CommonJS extension `module.exports`. */\n var moduleExports = freeModule && freeModule.exports === freeExports;\n\n /** Detect free variable `process` from Node.js. */\n var freeProcess = moduleExports && freeGlobal.process;\n\n /** Used to access faster Node.js helpers. */\n var nodeUtil = (function() {\n try {\n // Use `util.types` for Node.js 10+.\n var types = freeModule && freeModule.require && freeModule.require('util').types;\n\n if (types) {\n return types;\n }\n\n // Legacy `process.binding('util')` for Node.js < 10.\n return freeProcess && freeProcess.binding && freeProcess.binding('util');\n } catch (e) {}\n }());\n\n /* Node.js helper references. */\n var nodeIsArrayBuffer = nodeUtil && nodeUtil.isArrayBuffer,\n nodeIsDate = nodeUtil && nodeUtil.isDate,\n nodeIsMap = nodeUtil && nodeUtil.isMap,\n nodeIsRegExp = nodeUtil && nodeUtil.isRegExp,\n nodeIsSet = nodeUtil && nodeUtil.isSet,\n nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;\n\n /*--------------------------------------------------------------------------*/\n\n /**\n * A faster alternative to `Function#apply`, this function invokes `func`\n * with the `this` binding of `thisArg` and the arguments of `args`.\n *\n * @private\n * @param {Function} func The function to invoke.\n * @param {*} thisArg The `this` binding of `func`.\n * @param {Array} args The arguments to invoke `func` with.\n * @returns {*} Returns the result of `func`.\n */\n function apply(func, thisArg, args) {\n switch (args.length) {\n case 0: return func.call(thisArg);\n case 1: return func.call(thisArg, args[0]);\n case 2: return func.call(thisArg, args[0], args[1]);\n case 3: return func.call(thisArg, args[0], args[1], args[2]);\n }\n return func.apply(thisArg, args);\n }\n\n /**\n * A specialized version of `baseAggregator` for arrays.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} setter The function to set `accumulator` values.\n * @param {Function} iteratee The iteratee to transform keys.\n * @param {Object} accumulator The initial aggregated object.\n * @returns {Function} Returns `accumulator`.\n */\n function arrayAggregator(array, setter, iteratee, accumulator) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n var value = array[index];\n setter(accumulator, value, iteratee(value), array);\n }\n return accumulator;\n }\n\n /**\n * A specialized version of `_.forEach` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns `array`.\n */\n function arrayEach(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (iteratee(array[index], index, array) === false) {\n break;\n }\n }\n return array;\n }\n\n /**\n * A specialized version of `_.forEachRight` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns `array`.\n */\n function arrayEachRight(array, iteratee) {\n var length = array == null ? 0 : array.length;\n\n while (length--) {\n if (iteratee(array[length], length, array) === false) {\n break;\n }\n }\n return array;\n }\n\n /**\n * A specialized version of `_.every` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if all elements pass the predicate check,\n * else `false`.\n */\n function arrayEvery(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (!predicate(array[index], index, array)) {\n return false;\n }\n }\n return true;\n }\n\n /**\n * A specialized version of `_.filter` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\n function arrayFilter(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result[resIndex++] = value;\n }\n }\n return result;\n }\n\n /**\n * A specialized version of `_.includes` for arrays without support for\n * specifying an index to search from.\n *\n * @private\n * @param {Array} [array] The array to inspect.\n * @param {*} target The value to search for.\n * @returns {boolean} Returns `true` if `target` is found, else `false`.\n */\n function arrayIncludes(array, value) {\n var length = array == null ? 0 : array.length;\n return !!length && baseIndexOf(array, value, 0) > -1;\n }\n\n /**\n * This function is like `arrayIncludes` except that it accepts a comparator.\n *\n * @private\n * @param {Array} [array] The array to inspect.\n * @param {*} target The value to search for.\n * @param {Function} comparator The comparator invoked per element.\n * @returns {boolean} Returns `true` if `target` is found, else `false`.\n */\n function arrayIncludesWith(array, value, comparator) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (comparator(value, array[index])) {\n return true;\n }\n }\n return false;\n }\n\n /**\n * A specialized version of `_.map` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\n function arrayMap(array, iteratee) {\n var index = -1,\n length = array == null ? 0 : array.length,\n result = Array(length);\n\n while (++index < length) {\n result[index] = iteratee(array[index], index, array);\n }\n return result;\n }\n\n /**\n * Appends the elements of `values` to `array`.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to append.\n * @returns {Array} Returns `array`.\n */\n function arrayPush(array, values) {\n var index = -1,\n length = values.length,\n offset = array.length;\n\n while (++index < length) {\n array[offset + index] = values[index];\n }\n return array;\n }\n\n /**\n * A specialized version of `_.reduce` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {*} [accumulator] The initial value.\n * @param {boolean} [initAccum] Specify using the first element of `array` as\n * the initial value.\n * @returns {*} Returns the accumulated value.\n */\n function arrayReduce(array, iteratee, accumulator, initAccum) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n if (initAccum && length) {\n accumulator = array[++index];\n }\n while (++index < length) {\n accumulator = iteratee(accumulator, array[index], index, array);\n }\n return accumulator;\n }\n\n /**\n * A specialized version of `_.reduceRight` for arrays without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {*} [accumulator] The initial value.\n * @param {boolean} [initAccum] Specify using the last element of `array` as\n * the initial value.\n * @returns {*} Returns the accumulated value.\n */\n function arrayReduceRight(array, iteratee, accumulator, initAccum) {\n var length = array == null ? 0 : array.length;\n if (initAccum && length) {\n accumulator = array[--length];\n }\n while (length--) {\n accumulator = iteratee(accumulator, array[length], length, array);\n }\n return accumulator;\n }\n\n /**\n * A specialized version of `_.some` for arrays without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} [array] The array to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\n function arraySome(array, predicate) {\n var index = -1,\n length = array == null ? 0 : array.length;\n\n while (++index < length) {\n if (predicate(array[index], index, array)) {\n return true;\n }\n }\n return false;\n }\n\n /**\n * Gets the size of an ASCII `string`.\n *\n * @private\n * @param {string} string The string inspect.\n * @returns {number} Returns the string size.\n */\n var asciiSize = baseProperty('length');\n\n /**\n * Converts an ASCII `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\n function asciiToArray(string) {\n return string.split('');\n }\n\n /**\n * Splits an ASCII `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\n function asciiWords(string) {\n return string.match(reAsciiWord) || [];\n }\n\n /**\n * The base implementation of methods like `_.findKey` and `_.findLastKey`,\n * without support for iteratee shorthands, which iterates over `collection`\n * using `eachFunc`.\n *\n * @private\n * @param {Array|Object} collection The collection to inspect.\n * @param {Function} predicate The function invoked per iteration.\n * @param {Function} eachFunc The function to iterate over `collection`.\n * @returns {*} Returns the found element or its key, else `undefined`.\n */\n function baseFindKey(collection, predicate, eachFunc) {\n var result;\n eachFunc(collection, function(value, key, collection) {\n if (predicate(value, key, collection)) {\n result = key;\n return false;\n }\n });\n return result;\n }\n\n /**\n * The base implementation of `_.findIndex` and `_.findLastIndex` without\n * support for iteratee shorthands.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {Function} predicate The function invoked per iteration.\n * @param {number} fromIndex The index to search from.\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\n function baseFindIndex(array, predicate, fromIndex, fromRight) {\n var length = array.length,\n index = fromIndex + (fromRight ? 1 : -1);\n\n while ((fromRight ? index-- : ++index < length)) {\n if (predicate(array[index], index, array)) {\n return index;\n }\n }\n return -1;\n }\n\n /**\n * The base implementation of `_.indexOf` without `fromIndex` bounds checks.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} value The value to search for.\n * @param {number} fromIndex The index to search from.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\n function baseIndexOf(array, value, fromIndex) {\n return value === value\n ? strictIndexOf(array, value, fromIndex)\n : baseFindIndex(array, baseIsNaN, fromIndex);\n }\n\n /**\n * This function is like `baseIndexOf` except that it accepts a comparator.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} value The value to search for.\n * @param {number} fromIndex The index to search from.\n * @param {Function} comparator The comparator invoked per element.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\n function baseIndexOfWith(array, value, fromIndex, comparator) {\n var index = fromIndex - 1,\n length = array.length;\n\n while (++index < length) {\n if (comparator(array[index], value)) {\n return index;\n }\n }\n return -1;\n }\n\n /**\n * The base implementation of `_.isNaN` without support for number objects.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`.\n */\n function baseIsNaN(value) {\n return value !== value;\n }\n\n /**\n * The base implementation of `_.mean` and `_.meanBy` without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} array The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {number} Returns the mean.\n */\n function baseMean(array, iteratee) {\n var length = array == null ? 0 : array.length;\n return length ? (baseSum(array, iteratee) / length) : NAN;\n }\n\n /**\n * The base implementation of `_.property` without support for deep paths.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\n function baseProperty(key) {\n return function(object) {\n return object == null ? undefined : object[key];\n };\n }\n\n /**\n * The base implementation of `_.propertyOf` without support for deep paths.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Function} Returns the new accessor function.\n */\n function basePropertyOf(object) {\n return function(key) {\n return object == null ? undefined : object[key];\n };\n }\n\n /**\n * The base implementation of `_.reduce` and `_.reduceRight`, without support\n * for iteratee shorthands, which iterates over `collection` using `eachFunc`.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {*} accumulator The initial value.\n * @param {boolean} initAccum Specify using the first or last element of\n * `collection` as the initial value.\n * @param {Function} eachFunc The function to iterate over `collection`.\n * @returns {*} Returns the accumulated value.\n */\n function baseReduce(collection, iteratee, accumulator, initAccum, eachFunc) {\n eachFunc(collection, function(value, index, collection) {\n accumulator = initAccum\n ? (initAccum = false, value)\n : iteratee(accumulator, value, index, collection);\n });\n return accumulator;\n }\n\n /**\n * The base implementation of `_.sortBy` which uses `comparer` to define the\n * sort order of `array` and replaces criteria objects with their corresponding\n * values.\n *\n * @private\n * @param {Array} array The array to sort.\n * @param {Function} comparer The function to define sort order.\n * @returns {Array} Returns `array`.\n */\n function baseSortBy(array, comparer) {\n var length = array.length;\n\n array.sort(comparer);\n while (length--) {\n array[length] = array[length].value;\n }\n return array;\n }\n\n /**\n * The base implementation of `_.sum` and `_.sumBy` without support for\n * iteratee shorthands.\n *\n * @private\n * @param {Array} array The array to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {number} Returns the sum.\n */\n function baseSum(array, iteratee) {\n var result,\n index = -1,\n length = array.length;\n\n while (++index < length) {\n var current = iteratee(array[index]);\n if (current !== undefined) {\n result = result === undefined ? current : (result + current);\n }\n }\n return result;\n }\n\n /**\n * The base implementation of `_.times` without support for iteratee shorthands\n * or max array length checks.\n *\n * @private\n * @param {number} n The number of times to invoke `iteratee`.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the array of results.\n */\n function baseTimes(n, iteratee) {\n var index = -1,\n result = Array(n);\n\n while (++index < n) {\n result[index] = iteratee(index);\n }\n return result;\n }\n\n /**\n * The base implementation of `_.toPairs` and `_.toPairsIn` which creates an array\n * of key-value pairs for `object` corresponding to the property names of `props`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array} props The property names to get values for.\n * @returns {Object} Returns the key-value pairs.\n */\n function baseToPairs(object, props) {\n return arrayMap(props, function(key) {\n return [key, object[key]];\n });\n }\n\n /**\n * The base implementation of `_.trim`.\n *\n * @private\n * @param {string} string The string to trim.\n * @returns {string} Returns the trimmed string.\n */\n function baseTrim(string) {\n return string\n ? string.slice(0, trimmedEndIndex(string) + 1).replace(reTrimStart, '')\n : string;\n }\n\n /**\n * The base implementation of `_.unary` without support for storing metadata.\n *\n * @private\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n */\n function baseUnary(func) {\n return function(value) {\n return func(value);\n };\n }\n\n /**\n * The base implementation of `_.values` and `_.valuesIn` which creates an\n * array of `object` property values corresponding to the property names\n * of `props`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array} props The property names to get values for.\n * @returns {Object} Returns the array of property values.\n */\n function baseValues(object, props) {\n return arrayMap(props, function(key) {\n return object[key];\n });\n }\n\n /**\n * Checks if a `cache` value for `key` exists.\n *\n * @private\n * @param {Object} cache The cache to query.\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\n function cacheHas(cache, key) {\n return cache.has(key);\n }\n\n /**\n * Used by `_.trim` and `_.trimStart` to get the index of the first string symbol\n * that is not found in the character symbols.\n *\n * @private\n * @param {Array} strSymbols The string symbols to inspect.\n * @param {Array} chrSymbols The character symbols to find.\n * @returns {number} Returns the index of the first unmatched string symbol.\n */\n function charsStartIndex(strSymbols, chrSymbols) {\n var index = -1,\n length = strSymbols.length;\n\n while (++index < length && baseIndexOf(chrSymbols, strSymbols[index], 0) > -1) {}\n return index;\n }\n\n /**\n * Used by `_.trim` and `_.trimEnd` to get the index of the last string symbol\n * that is not found in the character symbols.\n *\n * @private\n * @param {Array} strSymbols The string symbols to inspect.\n * @param {Array} chrSymbols The character symbols to find.\n * @returns {number} Returns the index of the last unmatched string symbol.\n */\n function charsEndIndex(strSymbols, chrSymbols) {\n var index = strSymbols.length;\n\n while (index-- && baseIndexOf(chrSymbols, strSymbols[index], 0) > -1) {}\n return index;\n }\n\n /**\n * Gets the number of `placeholder` occurrences in `array`.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} placeholder The placeholder to search for.\n * @returns {number} Returns the placeholder count.\n */\n function countHolders(array, placeholder) {\n var length = array.length,\n result = 0;\n\n while (length--) {\n if (array[length] === placeholder) {\n ++result;\n }\n }\n return result;\n }\n\n /**\n * Used by `_.deburr` to convert Latin-1 Supplement and Latin Extended-A\n * letters to basic Latin letters.\n *\n * @private\n * @param {string} letter The matched letter to deburr.\n * @returns {string} Returns the deburred letter.\n */\n var deburrLetter = basePropertyOf(deburredLetters);\n\n /**\n * Used by `_.escape` to convert characters to HTML entities.\n *\n * @private\n * @param {string} chr The matched character to escape.\n * @returns {string} Returns the escaped character.\n */\n var escapeHtmlChar = basePropertyOf(htmlEscapes);\n\n /**\n * Used by `_.template` to escape characters for inclusion in compiled string literals.\n *\n * @private\n * @param {string} chr The matched character to escape.\n * @returns {string} Returns the escaped character.\n */\n function escapeStringChar(chr) {\n return '\\\\' + stringEscapes[chr];\n }\n\n /**\n * Gets the value at `key` of `object`.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\n function getValue(object, key) {\n return object == null ? undefined : object[key];\n }\n\n /**\n * Checks if `string` contains Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a symbol is found, else `false`.\n */\n function hasUnicode(string) {\n return reHasUnicode.test(string);\n }\n\n /**\n * Checks if `string` contains a word composed of Unicode symbols.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {boolean} Returns `true` if a word is found, else `false`.\n */\n function hasUnicodeWord(string) {\n return reHasUnicodeWord.test(string);\n }\n\n /**\n * Converts `iterator` to an array.\n *\n * @private\n * @param {Object} iterator The iterator to convert.\n * @returns {Array} Returns the converted array.\n */\n function iteratorToArray(iterator) {\n var data,\n result = [];\n\n while (!(data = iterator.next()).done) {\n result.push(data.value);\n }\n return result;\n }\n\n /**\n * Converts `map` to its key-value pairs.\n *\n * @private\n * @param {Object} map The map to convert.\n * @returns {Array} Returns the key-value pairs.\n */\n function mapToArray(map) {\n var index = -1,\n result = Array(map.size);\n\n map.forEach(function(value, key) {\n result[++index] = [key, value];\n });\n return result;\n }\n\n /**\n * Creates a unary function that invokes `func` with its argument transformed.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {Function} transform The argument transform.\n * @returns {Function} Returns the new function.\n */\n function overArg(func, transform) {\n return function(arg) {\n return func(transform(arg));\n };\n }\n\n /**\n * Replaces all `placeholder` elements in `array` with an internal placeholder\n * and returns an array of their indexes.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {*} placeholder The placeholder to replace.\n * @returns {Array} Returns the new array of placeholder indexes.\n */\n function replaceHolders(array, placeholder) {\n var index = -1,\n length = array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (value === placeholder || value === PLACEHOLDER) {\n array[index] = PLACEHOLDER;\n result[resIndex++] = index;\n }\n }\n return result;\n }\n\n /**\n * Converts `set` to an array of its values.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the values.\n */\n function setToArray(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = value;\n });\n return result;\n }\n\n /**\n * Converts `set` to its value-value pairs.\n *\n * @private\n * @param {Object} set The set to convert.\n * @returns {Array} Returns the value-value pairs.\n */\n function setToPairs(set) {\n var index = -1,\n result = Array(set.size);\n\n set.forEach(function(value) {\n result[++index] = [value, value];\n });\n return result;\n }\n\n /**\n * A specialized version of `_.indexOf` which performs strict equality\n * comparisons of values, i.e. `===`.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} value The value to search for.\n * @param {number} fromIndex The index to search from.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\n function strictIndexOf(array, value, fromIndex) {\n var index = fromIndex - 1,\n length = array.length;\n\n while (++index < length) {\n if (array[index] === value) {\n return index;\n }\n }\n return -1;\n }\n\n /**\n * A specialized version of `_.lastIndexOf` which performs strict equality\n * comparisons of values, i.e. `===`.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} value The value to search for.\n * @param {number} fromIndex The index to search from.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\n function strictLastIndexOf(array, value, fromIndex) {\n var index = fromIndex + 1;\n while (index--) {\n if (array[index] === value) {\n return index;\n }\n }\n return index;\n }\n\n /**\n * Gets the number of symbols in `string`.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {number} Returns the string size.\n */\n function stringSize(string) {\n return hasUnicode(string)\n ? unicodeSize(string)\n : asciiSize(string);\n }\n\n /**\n * Converts `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\n function stringToArray(string) {\n return hasUnicode(string)\n ? unicodeToArray(string)\n : asciiToArray(string);\n }\n\n /**\n * Used by `_.trim` and `_.trimEnd` to get the index of the last non-whitespace\n * character of `string`.\n *\n * @private\n * @param {string} string The string to inspect.\n * @returns {number} Returns the index of the last non-whitespace character.\n */\n function trimmedEndIndex(string) {\n var index = string.length;\n\n while (index-- && reWhitespace.test(string.charAt(index))) {}\n return index;\n }\n\n /**\n * Used by `_.unescape` to convert HTML entities to characters.\n *\n * @private\n * @param {string} chr The matched character to unescape.\n * @returns {string} Returns the unescaped character.\n */\n var unescapeHtmlChar = basePropertyOf(htmlUnescapes);\n\n /**\n * Gets the size of a Unicode `string`.\n *\n * @private\n * @param {string} string The string inspect.\n * @returns {number} Returns the string size.\n */\n function unicodeSize(string) {\n var result = reUnicode.lastIndex = 0;\n while (reUnicode.test(string)) {\n ++result;\n }\n return result;\n }\n\n /**\n * Converts a Unicode `string` to an array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the converted array.\n */\n function unicodeToArray(string) {\n return string.match(reUnicode) || [];\n }\n\n /**\n * Splits a Unicode `string` into an array of its words.\n *\n * @private\n * @param {string} The string to inspect.\n * @returns {Array} Returns the words of `string`.\n */\n function unicodeWords(string) {\n return string.match(reUnicodeWord) || [];\n }\n\n /*--------------------------------------------------------------------------*/\n\n /**\n * Create a new pristine `lodash` function using the `context` object.\n *\n * @static\n * @memberOf _\n * @since 1.1.0\n * @category Util\n * @param {Object} [context=root] The context object.\n * @returns {Function} Returns a new `lodash` function.\n * @example\n *\n * _.mixin({ 'foo': _.constant('foo') });\n *\n * var lodash = _.runInContext();\n * lodash.mixin({ 'bar': lodash.constant('bar') });\n *\n * _.isFunction(_.foo);\n * // => true\n * _.isFunction(_.bar);\n * // => false\n *\n * lodash.isFunction(lodash.foo);\n * // => false\n * lodash.isFunction(lodash.bar);\n * // => true\n *\n * // Create a suped-up `defer` in Node.js.\n * var defer = _.runInContext({ 'setTimeout': setImmediate }).defer;\n */\n var runInContext = (function runInContext(context) {\n context = context == null ? root : _.defaults(root.Object(), context, _.pick(root, contextProps));\n\n /** Built-in constructor references. */\n var Array = context.Array,\n Date = context.Date,\n Error = context.Error,\n Function = context.Function,\n Math = context.Math,\n Object = context.Object,\n RegExp = context.RegExp,\n String = context.String,\n TypeError = context.TypeError;\n\n /** Used for built-in method references. */\n var arrayProto = Array.prototype,\n funcProto = Function.prototype,\n objectProto = Object.prototype;\n\n /** Used to detect overreaching core-js shims. */\n var coreJsData = context['__core-js_shared__'];\n\n /** Used to resolve the decompiled source of functions. */\n var funcToString = funcProto.toString;\n\n /** Used to check objects for own properties. */\n var hasOwnProperty = objectProto.hasOwnProperty;\n\n /** Used to generate unique IDs. */\n var idCounter = 0;\n\n /** Used to detect methods masquerading as native. */\n var maskSrcKey = (function() {\n var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || '');\n return uid ? ('Symbol(src)_1.' + uid) : '';\n }());\n\n /**\n * Used to resolve the\n * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring)\n * of values.\n */\n var nativeObjectToString = objectProto.toString;\n\n /** Used to infer the `Object` constructor. */\n var objectCtorString = funcToString.call(Object);\n\n /** Used to restore the original `_` reference in `_.noConflict`. */\n var oldDash = root._;\n\n /** Used to detect if a method is native. */\n var reIsNative = RegExp('^' +\n funcToString.call(hasOwnProperty).replace(reRegExpChar, '\\\\$&')\n .replace(/hasOwnProperty|(function).*?(?=\\\\\\()| for .+?(?=\\\\\\])/g, '$1.*?') + '$'\n );\n\n /** Built-in value references. */\n var Buffer = moduleExports ? context.Buffer : undefined,\n Symbol = context.Symbol,\n Uint8Array = context.Uint8Array,\n allocUnsafe = Buffer ? Buffer.allocUnsafe : undefined,\n getPrototype = overArg(Object.getPrototypeOf, Object),\n objectCreate = Object.create,\n propertyIsEnumerable = objectProto.propertyIsEnumerable,\n splice = arrayProto.splice,\n spreadableSymbol = Symbol ? Symbol.isConcatSpreadable : undefined,\n symIterator = Symbol ? Symbol.iterator : undefined,\n symToStringTag = Symbol ? Symbol.toStringTag : undefined;\n\n var defineProperty = (function() {\n try {\n var func = getNative(Object, 'defineProperty');\n func({}, '', {});\n return func;\n } catch (e) {}\n }());\n\n /** Mocked built-ins. */\n var ctxClearTimeout = context.clearTimeout !== root.clearTimeout && context.clearTimeout,\n ctxNow = Date && Date.now !== root.Date.now && Date.now,\n ctxSetTimeout = context.setTimeout !== root.setTimeout && context.setTimeout;\n\n /* Built-in method references for those with the same name as other `lodash` methods. */\n var nativeCeil = Math.ceil,\n nativeFloor = Math.floor,\n nativeGetSymbols = Object.getOwnPropertySymbols,\n nativeIsBuffer = Buffer ? Buffer.isBuffer : undefined,\n nativeIsFinite = context.isFinite,\n nativeJoin = arrayProto.join,\n nativeKeys = overArg(Object.keys, Object),\n nativeMax = Math.max,\n nativeMin = Math.min,\n nativeNow = Date.now,\n nativeParseInt = context.parseInt,\n nativeRandom = Math.random,\n nativeReverse = arrayProto.reverse;\n\n /* Built-in method references that are verified to be native. */\n var DataView = getNative(context, 'DataView'),\n Map = getNative(context, 'Map'),\n Promise = getNative(context, 'Promise'),\n Set = getNative(context, 'Set'),\n WeakMap = getNative(context, 'WeakMap'),\n nativeCreate = getNative(Object, 'create');\n\n /** Used to store function metadata. */\n var metaMap = WeakMap && new WeakMap;\n\n /** Used to lookup unminified function names. */\n var realNames = {};\n\n /** Used to detect maps, sets, and weakmaps. */\n var dataViewCtorString = toSource(DataView),\n mapCtorString = toSource(Map),\n promiseCtorString = toSource(Promise),\n setCtorString = toSource(Set),\n weakMapCtorString = toSource(WeakMap);\n\n /** Used to convert symbols to primitives and strings. */\n var symbolProto = Symbol ? Symbol.prototype : undefined,\n symbolValueOf = symbolProto ? symbolProto.valueOf : undefined,\n symbolToString = symbolProto ? symbolProto.toString : undefined;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates a `lodash` object which wraps `value` to enable implicit method\n * chain sequences. Methods that operate on and return arrays, collections,\n * and functions can be chained together. Methods that retrieve a single value\n * or may return a primitive value will automatically end the chain sequence\n * and return the unwrapped value. Otherwise, the value must be unwrapped\n * with `_#value`.\n *\n * Explicit chain sequences, which must be unwrapped with `_#value`, may be\n * enabled using `_.chain`.\n *\n * The execution of chained methods is lazy, that is, it's deferred until\n * `_#value` is implicitly or explicitly called.\n *\n * Lazy evaluation allows several methods to support shortcut fusion.\n * Shortcut fusion is an optimization to merge iteratee calls; this avoids\n * the creation of intermediate arrays and can greatly reduce the number of\n * iteratee executions. Sections of a chain sequence qualify for shortcut\n * fusion if the section is applied to an array and iteratees accept only\n * one argument. The heuristic for whether a section qualifies for shortcut\n * fusion is subject to change.\n *\n * Chaining is supported in custom builds as long as the `_#value` method is\n * directly or indirectly included in the build.\n *\n * In addition to lodash methods, wrappers have `Array` and `String` methods.\n *\n * The wrapper `Array` methods are:\n * `concat`, `join`, `pop`, `push`, `shift`, `sort`, `splice`, and `unshift`\n *\n * The wrapper `String` methods are:\n * `replace` and `split`\n *\n * The wrapper methods that support shortcut fusion are:\n * `at`, `compact`, `drop`, `dropRight`, `dropWhile`, `filter`, `find`,\n * `findLast`, `head`, `initial`, `last`, `map`, `reject`, `reverse`, `slice`,\n * `tail`, `take`, `takeRight`, `takeRightWhile`, `takeWhile`, and `toArray`\n *\n * The chainable wrapper methods are:\n * `after`, `ary`, `assign`, `assignIn`, `assignInWith`, `assignWith`, `at`,\n * `before`, `bind`, `bindAll`, `bindKey`, `castArray`, `chain`, `chunk`,\n * `commit`, `compact`, `concat`, `conforms`, `constant`, `countBy`, `create`,\n * `curry`, `debounce`, `defaults`, `defaultsDeep`, `defer`, `delay`,\n * `difference`, `differenceBy`, `differenceWith`, `drop`, `dropRight`,\n * `dropRightWhile`, `dropWhile`, `extend`, `extendWith`, `fill`, `filter`,\n * `flatMap`, `flatMapDeep`, `flatMapDepth`, `flatten`, `flattenDeep`,\n * `flattenDepth`, `flip`, `flow`, `flowRight`, `fromPairs`, `functions`,\n * `functionsIn`, `groupBy`, `initial`, `intersection`, `intersectionBy`,\n * `intersectionWith`, `invert`, `invertBy`, `invokeMap`, `iteratee`, `keyBy`,\n * `keys`, `keysIn`, `map`, `mapKeys`, `mapValues`, `matches`, `matchesProperty`,\n * `memoize`, `merge`, `mergeWith`, `method`, `methodOf`, `mixin`, `negate`,\n * `nthArg`, `omit`, `omitBy`, `once`, `orderBy`, `over`, `overArgs`,\n * `overEvery`, `overSome`, `partial`, `partialRight`, `partition`, `pick`,\n * `pickBy`, `plant`, `property`, `propertyOf`, `pull`, `pullAll`, `pullAllBy`,\n * `pullAllWith`, `pullAt`, `push`, `range`, `rangeRight`, `rearg`, `reject`,\n * `remove`, `rest`, `reverse`, `sampleSize`, `set`, `setWith`, `shuffle`,\n * `slice`, `sort`, `sortBy`, `splice`, `spread`, `tail`, `take`, `takeRight`,\n * `takeRightWhile`, `takeWhile`, `tap`, `throttle`, `thru`, `toArray`,\n * `toPairs`, `toPairsIn`, `toPath`, `toPlainObject`, `transform`, `unary`,\n * `union`, `unionBy`, `unionWith`, `uniq`, `uniqBy`, `uniqWith`, `unset`,\n * `unshift`, `unzip`, `unzipWith`, `update`, `updateWith`, `values`,\n * `valuesIn`, `without`, `wrap`, `xor`, `xorBy`, `xorWith`, `zip`,\n * `zipObject`, `zipObjectDeep`, and `zipWith`\n *\n * The wrapper methods that are **not** chainable by default are:\n * `add`, `attempt`, `camelCase`, `capitalize`, `ceil`, `clamp`, `clone`,\n * `cloneDeep`, `cloneDeepWith`, `cloneWith`, `conformsTo`, `deburr`,\n * `defaultTo`, `divide`, `each`, `eachRight`, `endsWith`, `eq`, `escape`,\n * `escapeRegExp`, `every`, `find`, `findIndex`, `findKey`, `findLast`,\n * `findLastIndex`, `findLastKey`, `first`, `floor`, `forEach`, `forEachRight`,\n * `forIn`, `forInRight`, `forOwn`, `forOwnRight`, `get`, `gt`, `gte`, `has`,\n * `hasIn`, `head`, `identity`, `includes`, `indexOf`, `inRange`, `invoke`,\n * `isArguments`, `isArray`, `isArrayBuffer`, `isArrayLike`, `isArrayLikeObject`,\n * `isBoolean`, `isBuffer`, `isDate`, `isElement`, `isEmpty`, `isEqual`,\n * `isEqualWith`, `isError`, `isFinite`, `isFunction`, `isInteger`, `isLength`,\n * `isMap`, `isMatch`, `isMatchWith`, `isNaN`, `isNative`, `isNil`, `isNull`,\n * `isNumber`, `isObject`, `isObjectLike`, `isPlainObject`, `isRegExp`,\n * `isSafeInteger`, `isSet`, `isString`, `isUndefined`, `isTypedArray`,\n * `isWeakMap`, `isWeakSet`, `join`, `kebabCase`, `last`, `lastIndexOf`,\n * `lowerCase`, `lowerFirst`, `lt`, `lte`, `max`, `maxBy`, `mean`, `meanBy`,\n * `min`, `minBy`, `multiply`, `noConflict`, `noop`, `now`, `nth`, `pad`,\n * `padEnd`, `padStart`, `parseInt`, `pop`, `random`, `reduce`, `reduceRight`,\n * `repeat`, `result`, `round`, `runInContext`, `sample`, `shift`, `size`,\n * `snakeCase`, `some`, `sortedIndex`, `sortedIndexBy`, `sortedLastIndex`,\n * `sortedLastIndexBy`, `startCase`, `startsWith`, `stubArray`, `stubFalse`,\n * `stubObject`, `stubString`, `stubTrue`, `subtract`, `sum`, `sumBy`,\n * `template`, `times`, `toFinite`, `toInteger`, `toJSON`, `toLength`,\n * `toLower`, `toNumber`, `toSafeInteger`, `toString`, `toUpper`, `trim`,\n * `trimEnd`, `trimStart`, `truncate`, `unescape`, `uniqueId`, `upperCase`,\n * `upperFirst`, `value`, and `words`\n *\n * @name _\n * @constructor\n * @category Seq\n * @param {*} value The value to wrap in a `lodash` instance.\n * @returns {Object} Returns the new `lodash` wrapper instance.\n * @example\n *\n * function square(n) {\n * return n * n;\n * }\n *\n * var wrapped = _([1, 2, 3]);\n *\n * // Returns an unwrapped value.\n * wrapped.reduce(_.add);\n * // => 6\n *\n * // Returns a wrapped value.\n * var squares = wrapped.map(square);\n *\n * _.isArray(squares);\n * // => false\n *\n * _.isArray(squares.value());\n * // => true\n */\n function lodash(value) {\n if (isObjectLike(value) && !isArray(value) && !(value instanceof LazyWrapper)) {\n if (value instanceof LodashWrapper) {\n return value;\n }\n if (hasOwnProperty.call(value, '__wrapped__')) {\n return wrapperClone(value);\n }\n }\n return new LodashWrapper(value);\n }\n\n /**\n * The base implementation of `_.create` without support for assigning\n * properties to the created object.\n *\n * @private\n * @param {Object} proto The object to inherit from.\n * @returns {Object} Returns the new object.\n */\n var baseCreate = (function() {\n function object() {}\n return function(proto) {\n if (!isObject(proto)) {\n return {};\n }\n if (objectCreate) {\n return objectCreate(proto);\n }\n object.prototype = proto;\n var result = new object;\n object.prototype = undefined;\n return result;\n };\n }());\n\n /**\n * The function whose prototype chain sequence wrappers inherit from.\n *\n * @private\n */\n function baseLodash() {\n // No operation performed.\n }\n\n /**\n * The base constructor for creating `lodash` wrapper objects.\n *\n * @private\n * @param {*} value The value to wrap.\n * @param {boolean} [chainAll] Enable explicit method chain sequences.\n */\n function LodashWrapper(value, chainAll) {\n this.__wrapped__ = value;\n this.__actions__ = [];\n this.__chain__ = !!chainAll;\n this.__index__ = 0;\n this.__values__ = undefined;\n }\n\n /**\n * By default, the template delimiters used by lodash are like those in\n * embedded Ruby (ERB) as well as ES2015 template strings. Change the\n * following template settings to use alternative delimiters.\n *\n * @static\n * @memberOf _\n * @type {Object}\n */\n lodash.templateSettings = {\n\n /**\n * Used to detect `data` property values to be HTML-escaped.\n *\n * @memberOf _.templateSettings\n * @type {RegExp}\n */\n 'escape': reEscape,\n\n /**\n * Used to detect code to be evaluated.\n *\n * @memberOf _.templateSettings\n * @type {RegExp}\n */\n 'evaluate': reEvaluate,\n\n /**\n * Used to detect `data` property values to inject.\n *\n * @memberOf _.templateSettings\n * @type {RegExp}\n */\n 'interpolate': reInterpolate,\n\n /**\n * Used to reference the data object in the template text.\n *\n * @memberOf _.templateSettings\n * @type {string}\n */\n 'variable': '',\n\n /**\n * Used to import variables into the compiled template.\n *\n * @memberOf _.templateSettings\n * @type {Object}\n */\n 'imports': {\n\n /**\n * A reference to the `lodash` function.\n *\n * @memberOf _.templateSettings.imports\n * @type {Function}\n */\n '_': lodash\n }\n };\n\n // Ensure wrappers are instances of `baseLodash`.\n lodash.prototype = baseLodash.prototype;\n lodash.prototype.constructor = lodash;\n\n LodashWrapper.prototype = baseCreate(baseLodash.prototype);\n LodashWrapper.prototype.constructor = LodashWrapper;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates a lazy wrapper object which wraps `value` to enable lazy evaluation.\n *\n * @private\n * @constructor\n * @param {*} value The value to wrap.\n */\n function LazyWrapper(value) {\n this.__wrapped__ = value;\n this.__actions__ = [];\n this.__dir__ = 1;\n this.__filtered__ = false;\n this.__iteratees__ = [];\n this.__takeCount__ = MAX_ARRAY_LENGTH;\n this.__views__ = [];\n }\n\n /**\n * Creates a clone of the lazy wrapper object.\n *\n * @private\n * @name clone\n * @memberOf LazyWrapper\n * @returns {Object} Returns the cloned `LazyWrapper` object.\n */\n function lazyClone() {\n var result = new LazyWrapper(this.__wrapped__);\n result.__actions__ = copyArray(this.__actions__);\n result.__dir__ = this.__dir__;\n result.__filtered__ = this.__filtered__;\n result.__iteratees__ = copyArray(this.__iteratees__);\n result.__takeCount__ = this.__takeCount__;\n result.__views__ = copyArray(this.__views__);\n return result;\n }\n\n /**\n * Reverses the direction of lazy iteration.\n *\n * @private\n * @name reverse\n * @memberOf LazyWrapper\n * @returns {Object} Returns the new reversed `LazyWrapper` object.\n */\n function lazyReverse() {\n if (this.__filtered__) {\n var result = new LazyWrapper(this);\n result.__dir__ = -1;\n result.__filtered__ = true;\n } else {\n result = this.clone();\n result.__dir__ *= -1;\n }\n return result;\n }\n\n /**\n * Extracts the unwrapped value from its lazy wrapper.\n *\n * @private\n * @name value\n * @memberOf LazyWrapper\n * @returns {*} Returns the unwrapped value.\n */\n function lazyValue() {\n var array = this.__wrapped__.value(),\n dir = this.__dir__,\n isArr = isArray(array),\n isRight = dir < 0,\n arrLength = isArr ? array.length : 0,\n view = getView(0, arrLength, this.__views__),\n start = view.start,\n end = view.end,\n length = end - start,\n index = isRight ? end : (start - 1),\n iteratees = this.__iteratees__,\n iterLength = iteratees.length,\n resIndex = 0,\n takeCount = nativeMin(length, this.__takeCount__);\n\n if (!isArr || (!isRight && arrLength == length && takeCount == length)) {\n return baseWrapperValue(array, this.__actions__);\n }\n var result = [];\n\n outer:\n while (length-- && resIndex < takeCount) {\n index += dir;\n\n var iterIndex = -1,\n value = array[index];\n\n while (++iterIndex < iterLength) {\n var data = iteratees[iterIndex],\n iteratee = data.iteratee,\n type = data.type,\n computed = iteratee(value);\n\n if (type == LAZY_MAP_FLAG) {\n value = computed;\n } else if (!computed) {\n if (type == LAZY_FILTER_FLAG) {\n continue outer;\n } else {\n break outer;\n }\n }\n }\n result[resIndex++] = value;\n }\n return result;\n }\n\n // Ensure `LazyWrapper` is an instance of `baseLodash`.\n LazyWrapper.prototype = baseCreate(baseLodash.prototype);\n LazyWrapper.prototype.constructor = LazyWrapper;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates a hash object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\n function Hash(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n }\n\n /**\n * Removes all key-value entries from the hash.\n *\n * @private\n * @name clear\n * @memberOf Hash\n */\n function hashClear() {\n this.__data__ = nativeCreate ? nativeCreate(null) : {};\n this.size = 0;\n }\n\n /**\n * Removes `key` and its value from the hash.\n *\n * @private\n * @name delete\n * @memberOf Hash\n * @param {Object} hash The hash to modify.\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\n function hashDelete(key) {\n var result = this.has(key) && delete this.__data__[key];\n this.size -= result ? 1 : 0;\n return result;\n }\n\n /**\n * Gets the hash value for `key`.\n *\n * @private\n * @name get\n * @memberOf Hash\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\n function hashGet(key) {\n var data = this.__data__;\n if (nativeCreate) {\n var result = data[key];\n return result === HASH_UNDEFINED ? undefined : result;\n }\n return hasOwnProperty.call(data, key) ? data[key] : undefined;\n }\n\n /**\n * Checks if a hash value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Hash\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\n function hashHas(key) {\n var data = this.__data__;\n return nativeCreate ? (data[key] !== undefined) : hasOwnProperty.call(data, key);\n }\n\n /**\n * Sets the hash `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Hash\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the hash instance.\n */\n function hashSet(key, value) {\n var data = this.__data__;\n this.size += this.has(key) ? 0 : 1;\n data[key] = (nativeCreate && value === undefined) ? HASH_UNDEFINED : value;\n return this;\n }\n\n // Add methods to `Hash`.\n Hash.prototype.clear = hashClear;\n Hash.prototype['delete'] = hashDelete;\n Hash.prototype.get = hashGet;\n Hash.prototype.has = hashHas;\n Hash.prototype.set = hashSet;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates an list cache object.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\n function ListCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n }\n\n /**\n * Removes all key-value entries from the list cache.\n *\n * @private\n * @name clear\n * @memberOf ListCache\n */\n function listCacheClear() {\n this.__data__ = [];\n this.size = 0;\n }\n\n /**\n * Removes `key` and its value from the list cache.\n *\n * @private\n * @name delete\n * @memberOf ListCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\n function listCacheDelete(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n return false;\n }\n var lastIndex = data.length - 1;\n if (index == lastIndex) {\n data.pop();\n } else {\n splice.call(data, index, 1);\n }\n --this.size;\n return true;\n }\n\n /**\n * Gets the list cache value for `key`.\n *\n * @private\n * @name get\n * @memberOf ListCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\n function listCacheGet(key) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n return index < 0 ? undefined : data[index][1];\n }\n\n /**\n * Checks if a list cache value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf ListCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\n function listCacheHas(key) {\n return assocIndexOf(this.__data__, key) > -1;\n }\n\n /**\n * Sets the list cache `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf ListCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the list cache instance.\n */\n function listCacheSet(key, value) {\n var data = this.__data__,\n index = assocIndexOf(data, key);\n\n if (index < 0) {\n ++this.size;\n data.push([key, value]);\n } else {\n data[index][1] = value;\n }\n return this;\n }\n\n // Add methods to `ListCache`.\n ListCache.prototype.clear = listCacheClear;\n ListCache.prototype['delete'] = listCacheDelete;\n ListCache.prototype.get = listCacheGet;\n ListCache.prototype.has = listCacheHas;\n ListCache.prototype.set = listCacheSet;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates a map cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\n function MapCache(entries) {\n var index = -1,\n length = entries == null ? 0 : entries.length;\n\n this.clear();\n while (++index < length) {\n var entry = entries[index];\n this.set(entry[0], entry[1]);\n }\n }\n\n /**\n * Removes all key-value entries from the map.\n *\n * @private\n * @name clear\n * @memberOf MapCache\n */\n function mapCacheClear() {\n this.size = 0;\n this.__data__ = {\n 'hash': new Hash,\n 'map': new (Map || ListCache),\n 'string': new Hash\n };\n }\n\n /**\n * Removes `key` and its value from the map.\n *\n * @private\n * @name delete\n * @memberOf MapCache\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\n function mapCacheDelete(key) {\n var result = getMapData(this, key)['delete'](key);\n this.size -= result ? 1 : 0;\n return result;\n }\n\n /**\n * Gets the map value for `key`.\n *\n * @private\n * @name get\n * @memberOf MapCache\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\n function mapCacheGet(key) {\n return getMapData(this, key).get(key);\n }\n\n /**\n * Checks if a map value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf MapCache\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\n function mapCacheHas(key) {\n return getMapData(this, key).has(key);\n }\n\n /**\n * Sets the map `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf MapCache\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the map cache instance.\n */\n function mapCacheSet(key, value) {\n var data = getMapData(this, key),\n size = data.size;\n\n data.set(key, value);\n this.size += data.size == size ? 0 : 1;\n return this;\n }\n\n // Add methods to `MapCache`.\n MapCache.prototype.clear = mapCacheClear;\n MapCache.prototype['delete'] = mapCacheDelete;\n MapCache.prototype.get = mapCacheGet;\n MapCache.prototype.has = mapCacheHas;\n MapCache.prototype.set = mapCacheSet;\n\n /*------------------------------------------------------------------------*/\n\n /**\n *\n * Creates an array cache object to store unique values.\n *\n * @private\n * @constructor\n * @param {Array} [values] The values to cache.\n */\n function SetCache(values) {\n var index = -1,\n length = values == null ? 0 : values.length;\n\n this.__data__ = new MapCache;\n while (++index < length) {\n this.add(values[index]);\n }\n }\n\n /**\n * Adds `value` to the array cache.\n *\n * @private\n * @name add\n * @memberOf SetCache\n * @alias push\n * @param {*} value The value to cache.\n * @returns {Object} Returns the cache instance.\n */\n function setCacheAdd(value) {\n this.__data__.set(value, HASH_UNDEFINED);\n return this;\n }\n\n /**\n * Checks if `value` is in the array cache.\n *\n * @private\n * @name has\n * @memberOf SetCache\n * @param {*} value The value to search for.\n * @returns {number} Returns `true` if `value` is found, else `false`.\n */\n function setCacheHas(value) {\n return this.__data__.has(value);\n }\n\n // Add methods to `SetCache`.\n SetCache.prototype.add = SetCache.prototype.push = setCacheAdd;\n SetCache.prototype.has = setCacheHas;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates a stack cache object to store key-value pairs.\n *\n * @private\n * @constructor\n * @param {Array} [entries] The key-value pairs to cache.\n */\n function Stack(entries) {\n var data = this.__data__ = new ListCache(entries);\n this.size = data.size;\n }\n\n /**\n * Removes all key-value entries from the stack.\n *\n * @private\n * @name clear\n * @memberOf Stack\n */\n function stackClear() {\n this.__data__ = new ListCache;\n this.size = 0;\n }\n\n /**\n * Removes `key` and its value from the stack.\n *\n * @private\n * @name delete\n * @memberOf Stack\n * @param {string} key The key of the value to remove.\n * @returns {boolean} Returns `true` if the entry was removed, else `false`.\n */\n function stackDelete(key) {\n var data = this.__data__,\n result = data['delete'](key);\n\n this.size = data.size;\n return result;\n }\n\n /**\n * Gets the stack value for `key`.\n *\n * @private\n * @name get\n * @memberOf Stack\n * @param {string} key The key of the value to get.\n * @returns {*} Returns the entry value.\n */\n function stackGet(key) {\n return this.__data__.get(key);\n }\n\n /**\n * Checks if a stack value for `key` exists.\n *\n * @private\n * @name has\n * @memberOf Stack\n * @param {string} key The key of the entry to check.\n * @returns {boolean} Returns `true` if an entry for `key` exists, else `false`.\n */\n function stackHas(key) {\n return this.__data__.has(key);\n }\n\n /**\n * Sets the stack `key` to `value`.\n *\n * @private\n * @name set\n * @memberOf Stack\n * @param {string} key The key of the value to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns the stack cache instance.\n */\n function stackSet(key, value) {\n var data = this.__data__;\n if (data instanceof ListCache) {\n var pairs = data.__data__;\n if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {\n pairs.push([key, value]);\n this.size = ++data.size;\n return this;\n }\n data = this.__data__ = new MapCache(pairs);\n }\n data.set(key, value);\n this.size = data.size;\n return this;\n }\n\n // Add methods to `Stack`.\n Stack.prototype.clear = stackClear;\n Stack.prototype['delete'] = stackDelete;\n Stack.prototype.get = stackGet;\n Stack.prototype.has = stackHas;\n Stack.prototype.set = stackSet;\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates an array of the enumerable property names of the array-like `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @param {boolean} inherited Specify returning inherited property names.\n * @returns {Array} Returns the array of property names.\n */\n function arrayLikeKeys(value, inherited) {\n var isArr = isArray(value),\n isArg = !isArr && isArguments(value),\n isBuff = !isArr && !isArg && isBuffer(value),\n isType = !isArr && !isArg && !isBuff && isTypedArray(value),\n skipIndexes = isArr || isArg || isBuff || isType,\n result = skipIndexes ? baseTimes(value.length, String) : [],\n length = result.length;\n\n for (var key in value) {\n if ((inherited || hasOwnProperty.call(value, key)) &&\n !(skipIndexes && (\n // Safari 9 has enumerable `arguments.length` in strict mode.\n key == 'length' ||\n // Node.js 0.10 has enumerable non-index properties on buffers.\n (isBuff && (key == 'offset' || key == 'parent')) ||\n // PhantomJS 2 has enumerable non-index properties on typed arrays.\n (isType && (key == 'buffer' || key == 'byteLength' || key == 'byteOffset')) ||\n // Skip index properties.\n isIndex(key, length)\n ))) {\n result.push(key);\n }\n }\n return result;\n }\n\n /**\n * A specialized version of `_.sample` for arrays.\n *\n * @private\n * @param {Array} array The array to sample.\n * @returns {*} Returns the random element.\n */\n function arraySample(array) {\n var length = array.length;\n return length ? array[baseRandom(0, length - 1)] : undefined;\n }\n\n /**\n * A specialized version of `_.sampleSize` for arrays.\n *\n * @private\n * @param {Array} array The array to sample.\n * @param {number} n The number of elements to sample.\n * @returns {Array} Returns the random elements.\n */\n function arraySampleSize(array, n) {\n return shuffleSelf(copyArray(array), baseClamp(n, 0, array.length));\n }\n\n /**\n * A specialized version of `_.shuffle` for arrays.\n *\n * @private\n * @param {Array} array The array to shuffle.\n * @returns {Array} Returns the new shuffled array.\n */\n function arrayShuffle(array) {\n return shuffleSelf(copyArray(array));\n }\n\n /**\n * This function is like `assignValue` except that it doesn't assign\n * `undefined` values.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\n function assignMergeValue(object, key, value) {\n if ((value !== undefined && !eq(object[key], value)) ||\n (value === undefined && !(key in object))) {\n baseAssignValue(object, key, value);\n }\n }\n\n /**\n * Assigns `value` to `key` of `object` if the existing value is not equivalent\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\n function assignValue(object, key, value) {\n var objValue = object[key];\n if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) ||\n (value === undefined && !(key in object))) {\n baseAssignValue(object, key, value);\n }\n }\n\n /**\n * Gets the index at which the `key` is found in `array` of key-value pairs.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {*} key The key to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n */\n function assocIndexOf(array, key) {\n var length = array.length;\n while (length--) {\n if (eq(array[length][0], key)) {\n return length;\n }\n }\n return -1;\n }\n\n /**\n * Aggregates elements of `collection` on `accumulator` with keys transformed\n * by `iteratee` and values set by `setter`.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} setter The function to set `accumulator` values.\n * @param {Function} iteratee The iteratee to transform keys.\n * @param {Object} accumulator The initial aggregated object.\n * @returns {Function} Returns `accumulator`.\n */\n function baseAggregator(collection, setter, iteratee, accumulator) {\n baseEach(collection, function(value, key, collection) {\n setter(accumulator, value, iteratee(value), collection);\n });\n return accumulator;\n }\n\n /**\n * The base implementation of `_.assign` without support for multiple sources\n * or `customizer` functions.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @returns {Object} Returns `object`.\n */\n function baseAssign(object, source) {\n return object && copyObject(source, keys(source), object);\n }\n\n /**\n * The base implementation of `_.assignIn` without support for multiple sources\n * or `customizer` functions.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @returns {Object} Returns `object`.\n */\n function baseAssignIn(object, source) {\n return object && copyObject(source, keysIn(source), object);\n }\n\n /**\n * The base implementation of `assignValue` and `assignMergeValue` without\n * value checks.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {string} key The key of the property to assign.\n * @param {*} value The value to assign.\n */\n function baseAssignValue(object, key, value) {\n if (key == '__proto__' && defineProperty) {\n defineProperty(object, key, {\n 'configurable': true,\n 'enumerable': true,\n 'value': value,\n 'writable': true\n });\n } else {\n object[key] = value;\n }\n }\n\n /**\n * The base implementation of `_.at` without support for individual paths.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {string[]} paths The property paths to pick.\n * @returns {Array} Returns the picked elements.\n */\n function baseAt(object, paths) {\n var index = -1,\n length = paths.length,\n result = Array(length),\n skip = object == null;\n\n while (++index < length) {\n result[index] = skip ? undefined : get(object, paths[index]);\n }\n return result;\n }\n\n /**\n * The base implementation of `_.clamp` which doesn't coerce arguments.\n *\n * @private\n * @param {number} number The number to clamp.\n * @param {number} [lower] The lower bound.\n * @param {number} upper The upper bound.\n * @returns {number} Returns the clamped number.\n */\n function baseClamp(number, lower, upper) {\n if (number === number) {\n if (upper !== undefined) {\n number = number <= upper ? number : upper;\n }\n if (lower !== undefined) {\n number = number >= lower ? number : lower;\n }\n }\n return number;\n }\n\n /**\n * The base implementation of `_.clone` and `_.cloneDeep` which tracks\n * traversed objects.\n *\n * @private\n * @param {*} value The value to clone.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Deep clone\n * 2 - Flatten inherited properties\n * 4 - Clone symbols\n * @param {Function} [customizer] The function to customize cloning.\n * @param {string} [key] The key of `value`.\n * @param {Object} [object] The parent object of `value`.\n * @param {Object} [stack] Tracks traversed objects and their clone counterparts.\n * @returns {*} Returns the cloned value.\n */\n function baseClone(value, bitmask, customizer, key, object, stack) {\n var result,\n isDeep = bitmask & CLONE_DEEP_FLAG,\n isFlat = bitmask & CLONE_FLAT_FLAG,\n isFull = bitmask & CLONE_SYMBOLS_FLAG;\n\n if (customizer) {\n result = object ? customizer(value, key, object, stack) : customizer(value);\n }\n if (result !== undefined) {\n return result;\n }\n if (!isObject(value)) {\n return value;\n }\n var isArr = isArray(value);\n if (isArr) {\n result = initCloneArray(value);\n if (!isDeep) {\n return copyArray(value, result);\n }\n } else {\n var tag = getTag(value),\n isFunc = tag == funcTag || tag == genTag;\n\n if (isBuffer(value)) {\n return cloneBuffer(value, isDeep);\n }\n if (tag == objectTag || tag == argsTag || (isFunc && !object)) {\n result = (isFlat || isFunc) ? {} : initCloneObject(value);\n if (!isDeep) {\n return isFlat\n ? copySymbolsIn(value, baseAssignIn(result, value))\n : copySymbols(value, baseAssign(result, value));\n }\n } else {\n if (!cloneableTags[tag]) {\n return object ? value : {};\n }\n result = initCloneByTag(value, tag, isDeep);\n }\n }\n // Check for circular references and return its corresponding clone.\n stack || (stack = new Stack);\n var stacked = stack.get(value);\n if (stacked) {\n return stacked;\n }\n stack.set(value, result);\n\n if (isSet(value)) {\n value.forEach(function(subValue) {\n result.add(baseClone(subValue, bitmask, customizer, subValue, value, stack));\n });\n } else if (isMap(value)) {\n value.forEach(function(subValue, key) {\n result.set(key, baseClone(subValue, bitmask, customizer, key, value, stack));\n });\n }\n\n var keysFunc = isFull\n ? (isFlat ? getAllKeysIn : getAllKeys)\n : (isFlat ? keysIn : keys);\n\n var props = isArr ? undefined : keysFunc(value);\n arrayEach(props || value, function(subValue, key) {\n if (props) {\n key = subValue;\n subValue = value[key];\n }\n // Recursively populate clone (susceptible to call stack limits).\n assignValue(result, key, baseClone(subValue, bitmask, customizer, key, value, stack));\n });\n return result;\n }\n\n /**\n * The base implementation of `_.conforms` which doesn't clone `source`.\n *\n * @private\n * @param {Object} source The object of property predicates to conform to.\n * @returns {Function} Returns the new spec function.\n */\n function baseConforms(source) {\n var props = keys(source);\n return function(object) {\n return baseConformsTo(object, source, props);\n };\n }\n\n /**\n * The base implementation of `_.conformsTo` which accepts `props` to check.\n *\n * @private\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property predicates to conform to.\n * @returns {boolean} Returns `true` if `object` conforms, else `false`.\n */\n function baseConformsTo(object, source, props) {\n var length = props.length;\n if (object == null) {\n return !length;\n }\n object = Object(object);\n while (length--) {\n var key = props[length],\n predicate = source[key],\n value = object[key];\n\n if ((value === undefined && !(key in object)) || !predicate(value)) {\n return false;\n }\n }\n return true;\n }\n\n /**\n * The base implementation of `_.delay` and `_.defer` which accepts `args`\n * to provide to `func`.\n *\n * @private\n * @param {Function} func The function to delay.\n * @param {number} wait The number of milliseconds to delay invocation.\n * @param {Array} args The arguments to provide to `func`.\n * @returns {number|Object} Returns the timer id or timeout object.\n */\n function baseDelay(func, wait, args) {\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n return setTimeout(function() { func.apply(undefined, args); }, wait);\n }\n\n /**\n * The base implementation of methods like `_.difference` without support\n * for excluding multiple arrays or iteratee shorthands.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {Array} values The values to exclude.\n * @param {Function} [iteratee] The iteratee invoked per element.\n * @param {Function} [comparator] The comparator invoked per element.\n * @returns {Array} Returns the new array of filtered values.\n */\n function baseDifference(array, values, iteratee, comparator) {\n var index = -1,\n includes = arrayIncludes,\n isCommon = true,\n length = array.length,\n result = [],\n valuesLength = values.length;\n\n if (!length) {\n return result;\n }\n if (iteratee) {\n values = arrayMap(values, baseUnary(iteratee));\n }\n if (comparator) {\n includes = arrayIncludesWith;\n isCommon = false;\n }\n else if (values.length >= LARGE_ARRAY_SIZE) {\n includes = cacheHas;\n isCommon = false;\n values = new SetCache(values);\n }\n outer:\n while (++index < length) {\n var value = array[index],\n computed = iteratee == null ? value : iteratee(value);\n\n value = (comparator || value !== 0) ? value : 0;\n if (isCommon && computed === computed) {\n var valuesIndex = valuesLength;\n while (valuesIndex--) {\n if (values[valuesIndex] === computed) {\n continue outer;\n }\n }\n result.push(value);\n }\n else if (!includes(values, computed, comparator)) {\n result.push(value);\n }\n }\n return result;\n }\n\n /**\n * The base implementation of `_.forEach` without support for iteratee shorthands.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array|Object} Returns `collection`.\n */\n var baseEach = createBaseEach(baseForOwn);\n\n /**\n * The base implementation of `_.forEachRight` without support for iteratee shorthands.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array|Object} Returns `collection`.\n */\n var baseEachRight = createBaseEach(baseForOwnRight, true);\n\n /**\n * The base implementation of `_.every` without support for iteratee shorthands.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if all elements pass the predicate check,\n * else `false`\n */\n function baseEvery(collection, predicate) {\n var result = true;\n baseEach(collection, function(value, index, collection) {\n result = !!predicate(value, index, collection);\n return result;\n });\n return result;\n }\n\n /**\n * The base implementation of methods like `_.max` and `_.min` which accepts a\n * `comparator` to determine the extremum value.\n *\n * @private\n * @param {Array} array The array to iterate over.\n * @param {Function} iteratee The iteratee invoked per iteration.\n * @param {Function} comparator The comparator used to compare values.\n * @returns {*} Returns the extremum value.\n */\n function baseExtremum(array, iteratee, comparator) {\n var index = -1,\n length = array.length;\n\n while (++index < length) {\n var value = array[index],\n current = iteratee(value);\n\n if (current != null && (computed === undefined\n ? (current === current && !isSymbol(current))\n : comparator(current, computed)\n )) {\n var computed = current,\n result = value;\n }\n }\n return result;\n }\n\n /**\n * The base implementation of `_.fill` without an iteratee call guard.\n *\n * @private\n * @param {Array} array The array to fill.\n * @param {*} value The value to fill `array` with.\n * @param {number} [start=0] The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns `array`.\n */\n function baseFill(array, value, start, end) {\n var length = array.length;\n\n start = toInteger(start);\n if (start < 0) {\n start = -start > length ? 0 : (length + start);\n }\n end = (end === undefined || end > length) ? length : toInteger(end);\n if (end < 0) {\n end += length;\n }\n end = start > end ? 0 : toLength(end);\n while (start < end) {\n array[start++] = value;\n }\n return array;\n }\n\n /**\n * The base implementation of `_.filter` without support for iteratee shorthands.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n */\n function baseFilter(collection, predicate) {\n var result = [];\n baseEach(collection, function(value, index, collection) {\n if (predicate(value, index, collection)) {\n result.push(value);\n }\n });\n return result;\n }\n\n /**\n * The base implementation of `_.flatten` with support for restricting flattening.\n *\n * @private\n * @param {Array} array The array to flatten.\n * @param {number} depth The maximum recursion depth.\n * @param {boolean} [predicate=isFlattenable] The function invoked per iteration.\n * @param {boolean} [isStrict] Restrict to values that pass `predicate` checks.\n * @param {Array} [result=[]] The initial result value.\n * @returns {Array} Returns the new flattened array.\n */\n function baseFlatten(array, depth, predicate, isStrict, result) {\n var index = -1,\n length = array.length;\n\n predicate || (predicate = isFlattenable);\n result || (result = []);\n\n while (++index < length) {\n var value = array[index];\n if (depth > 0 && predicate(value)) {\n if (depth > 1) {\n // Recursively flatten arrays (susceptible to call stack limits).\n baseFlatten(value, depth - 1, predicate, isStrict, result);\n } else {\n arrayPush(result, value);\n }\n } else if (!isStrict) {\n result[result.length] = value;\n }\n }\n return result;\n }\n\n /**\n * The base implementation of `baseForOwn` which iterates over `object`\n * properties returned by `keysFunc` and invokes `iteratee` for each property.\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\n var baseFor = createBaseFor();\n\n /**\n * This function is like `baseFor` except that it iterates over properties\n * in the opposite order.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @returns {Object} Returns `object`.\n */\n var baseForRight = createBaseFor(true);\n\n /**\n * The base implementation of `_.forOwn` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Object} Returns `object`.\n */\n function baseForOwn(object, iteratee) {\n return object && baseFor(object, iteratee, keys);\n }\n\n /**\n * The base implementation of `_.forOwnRight` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Object} Returns `object`.\n */\n function baseForOwnRight(object, iteratee) {\n return object && baseForRight(object, iteratee, keys);\n }\n\n /**\n * The base implementation of `_.functions` which creates an array of\n * `object` function property names filtered from `props`.\n *\n * @private\n * @param {Object} object The object to inspect.\n * @param {Array} props The property names to filter.\n * @returns {Array} Returns the function names.\n */\n function baseFunctions(object, props) {\n return arrayFilter(props, function(key) {\n return isFunction(object[key]);\n });\n }\n\n /**\n * The base implementation of `_.get` without support for default values.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @returns {*} Returns the resolved value.\n */\n function baseGet(object, path) {\n path = castPath(path, object);\n\n var index = 0,\n length = path.length;\n\n while (object != null && index < length) {\n object = object[toKey(path[index++])];\n }\n return (index && index == length) ? object : undefined;\n }\n\n /**\n * The base implementation of `getAllKeys` and `getAllKeysIn` which uses\n * `keysFunc` and `symbolsFunc` to get the enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Function} keysFunc The function to get the keys of `object`.\n * @param {Function} symbolsFunc The function to get the symbols of `object`.\n * @returns {Array} Returns the array of property names and symbols.\n */\n function baseGetAllKeys(object, keysFunc, symbolsFunc) {\n var result = keysFunc(object);\n return isArray(object) ? result : arrayPush(result, symbolsFunc(object));\n }\n\n /**\n * The base implementation of `getTag` without fallbacks for buggy environments.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\n function baseGetTag(value) {\n if (value == null) {\n return value === undefined ? undefinedTag : nullTag;\n }\n return (symToStringTag && symToStringTag in Object(value))\n ? getRawTag(value)\n : objectToString(value);\n }\n\n /**\n * The base implementation of `_.gt` which doesn't coerce arguments.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if `value` is greater than `other`,\n * else `false`.\n */\n function baseGt(value, other) {\n return value > other;\n }\n\n /**\n * The base implementation of `_.has` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\n function baseHas(object, key) {\n return object != null && hasOwnProperty.call(object, key);\n }\n\n /**\n * The base implementation of `_.hasIn` without support for deep paths.\n *\n * @private\n * @param {Object} [object] The object to query.\n * @param {Array|string} key The key to check.\n * @returns {boolean} Returns `true` if `key` exists, else `false`.\n */\n function baseHasIn(object, key) {\n return object != null && key in Object(object);\n }\n\n /**\n * The base implementation of `_.inRange` which doesn't coerce arguments.\n *\n * @private\n * @param {number} number The number to check.\n * @param {number} start The start of the range.\n * @param {number} end The end of the range.\n * @returns {boolean} Returns `true` if `number` is in the range, else `false`.\n */\n function baseInRange(number, start, end) {\n return number >= nativeMin(start, end) && number < nativeMax(start, end);\n }\n\n /**\n * The base implementation of methods like `_.intersection`, without support\n * for iteratee shorthands, that accepts an array of arrays to inspect.\n *\n * @private\n * @param {Array} arrays The arrays to inspect.\n * @param {Function} [iteratee] The iteratee invoked per element.\n * @param {Function} [comparator] The comparator invoked per element.\n * @returns {Array} Returns the new array of shared values.\n */\n function baseIntersection(arrays, iteratee, comparator) {\n var includes = comparator ? arrayIncludesWith : arrayIncludes,\n length = arrays[0].length,\n othLength = arrays.length,\n othIndex = othLength,\n caches = Array(othLength),\n maxLength = Infinity,\n result = [];\n\n while (othIndex--) {\n var array = arrays[othIndex];\n if (othIndex && iteratee) {\n array = arrayMap(array, baseUnary(iteratee));\n }\n maxLength = nativeMin(array.length, maxLength);\n caches[othIndex] = !comparator && (iteratee || (length >= 120 && array.length >= 120))\n ? new SetCache(othIndex && array)\n : undefined;\n }\n array = arrays[0];\n\n var index = -1,\n seen = caches[0];\n\n outer:\n while (++index < length && result.length < maxLength) {\n var value = array[index],\n computed = iteratee ? iteratee(value) : value;\n\n value = (comparator || value !== 0) ? value : 0;\n if (!(seen\n ? cacheHas(seen, computed)\n : includes(result, computed, comparator)\n )) {\n othIndex = othLength;\n while (--othIndex) {\n var cache = caches[othIndex];\n if (!(cache\n ? cacheHas(cache, computed)\n : includes(arrays[othIndex], computed, comparator))\n ) {\n continue outer;\n }\n }\n if (seen) {\n seen.push(computed);\n }\n result.push(value);\n }\n }\n return result;\n }\n\n /**\n * The base implementation of `_.invert` and `_.invertBy` which inverts\n * `object` with values transformed by `iteratee` and set by `setter`.\n *\n * @private\n * @param {Object} object The object to iterate over.\n * @param {Function} setter The function to set `accumulator` values.\n * @param {Function} iteratee The iteratee to transform values.\n * @param {Object} accumulator The initial inverted object.\n * @returns {Function} Returns `accumulator`.\n */\n function baseInverter(object, setter, iteratee, accumulator) {\n baseForOwn(object, function(value, key, object) {\n setter(accumulator, iteratee(value), key, object);\n });\n return accumulator;\n }\n\n /**\n * The base implementation of `_.invoke` without support for individual\n * method arguments.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the method to invoke.\n * @param {Array} args The arguments to invoke the method with.\n * @returns {*} Returns the result of the invoked method.\n */\n function baseInvoke(object, path, args) {\n path = castPath(path, object);\n object = parent(object, path);\n var func = object == null ? object : object[toKey(last(path))];\n return func == null ? undefined : apply(func, object, args);\n }\n\n /**\n * The base implementation of `_.isArguments`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n */\n function baseIsArguments(value) {\n return isObjectLike(value) && baseGetTag(value) == argsTag;\n }\n\n /**\n * The base implementation of `_.isArrayBuffer` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array buffer, else `false`.\n */\n function baseIsArrayBuffer(value) {\n return isObjectLike(value) && baseGetTag(value) == arrayBufferTag;\n }\n\n /**\n * The base implementation of `_.isDate` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a date object, else `false`.\n */\n function baseIsDate(value) {\n return isObjectLike(value) && baseGetTag(value) == dateTag;\n }\n\n /**\n * The base implementation of `_.isEqual` which supports partial comparisons\n * and tracks traversed objects.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {boolean} bitmask The bitmask flags.\n * 1 - Unordered comparison\n * 2 - Partial comparison\n * @param {Function} [customizer] The function to customize comparisons.\n * @param {Object} [stack] Tracks traversed `value` and `other` objects.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n */\n function baseIsEqual(value, other, bitmask, customizer, stack) {\n if (value === other) {\n return true;\n }\n if (value == null || other == null || (!isObjectLike(value) && !isObjectLike(other))) {\n return value !== value && other !== other;\n }\n return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);\n }\n\n /**\n * A specialized version of `baseIsEqual` for arrays and objects which performs\n * deep comparisons and tracks traversed objects enabling objects with circular\n * references to be compared.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} [stack] Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\n function baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {\n var objIsArr = isArray(object),\n othIsArr = isArray(other),\n objTag = objIsArr ? arrayTag : getTag(object),\n othTag = othIsArr ? arrayTag : getTag(other);\n\n objTag = objTag == argsTag ? objectTag : objTag;\n othTag = othTag == argsTag ? objectTag : othTag;\n\n var objIsObj = objTag == objectTag,\n othIsObj = othTag == objectTag,\n isSameTag = objTag == othTag;\n\n if (isSameTag && isBuffer(object)) {\n if (!isBuffer(other)) {\n return false;\n }\n objIsArr = true;\n objIsObj = false;\n }\n if (isSameTag && !objIsObj) {\n stack || (stack = new Stack);\n return (objIsArr || isTypedArray(object))\n ? equalArrays(object, other, bitmask, customizer, equalFunc, stack)\n : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);\n }\n if (!(bitmask & COMPARE_PARTIAL_FLAG)) {\n var objIsWrapped = objIsObj && hasOwnProperty.call(object, '__wrapped__'),\n othIsWrapped = othIsObj && hasOwnProperty.call(other, '__wrapped__');\n\n if (objIsWrapped || othIsWrapped) {\n var objUnwrapped = objIsWrapped ? object.value() : object,\n othUnwrapped = othIsWrapped ? other.value() : other;\n\n stack || (stack = new Stack);\n return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);\n }\n }\n if (!isSameTag) {\n return false;\n }\n stack || (stack = new Stack);\n return equalObjects(object, other, bitmask, customizer, equalFunc, stack);\n }\n\n /**\n * The base implementation of `_.isMap` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a map, else `false`.\n */\n function baseIsMap(value) {\n return isObjectLike(value) && getTag(value) == mapTag;\n }\n\n /**\n * The base implementation of `_.isMatch` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property values to match.\n * @param {Array} matchData The property names, values, and compare flags to match.\n * @param {Function} [customizer] The function to customize comparisons.\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\n */\n function baseIsMatch(object, source, matchData, customizer) {\n var index = matchData.length,\n length = index,\n noCustomizer = !customizer;\n\n if (object == null) {\n return !length;\n }\n object = Object(object);\n while (index--) {\n var data = matchData[index];\n if ((noCustomizer && data[2])\n ? data[1] !== object[data[0]]\n : !(data[0] in object)\n ) {\n return false;\n }\n }\n while (++index < length) {\n data = matchData[index];\n var key = data[0],\n objValue = object[key],\n srcValue = data[1];\n\n if (noCustomizer && data[2]) {\n if (objValue === undefined && !(key in object)) {\n return false;\n }\n } else {\n var stack = new Stack;\n if (customizer) {\n var result = customizer(objValue, srcValue, key, object, source, stack);\n }\n if (!(result === undefined\n ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack)\n : result\n )) {\n return false;\n }\n }\n }\n return true;\n }\n\n /**\n * The base implementation of `_.isNative` without bad shim checks.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n */\n function baseIsNative(value) {\n if (!isObject(value) || isMasked(value)) {\n return false;\n }\n var pattern = isFunction(value) ? reIsNative : reIsHostCtor;\n return pattern.test(toSource(value));\n }\n\n /**\n * The base implementation of `_.isRegExp` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a regexp, else `false`.\n */\n function baseIsRegExp(value) {\n return isObjectLike(value) && baseGetTag(value) == regexpTag;\n }\n\n /**\n * The base implementation of `_.isSet` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a set, else `false`.\n */\n function baseIsSet(value) {\n return isObjectLike(value) && getTag(value) == setTag;\n }\n\n /**\n * The base implementation of `_.isTypedArray` without Node.js optimizations.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n */\n function baseIsTypedArray(value) {\n return isObjectLike(value) &&\n isLength(value.length) && !!typedArrayTags[baseGetTag(value)];\n }\n\n /**\n * The base implementation of `_.iteratee`.\n *\n * @private\n * @param {*} [value=_.identity] The value to convert to an iteratee.\n * @returns {Function} Returns the iteratee.\n */\n function baseIteratee(value) {\n // Don't store the `typeof` result in a variable to avoid a JIT bug in Safari 9.\n // See https://bugs.webkit.org/show_bug.cgi?id=156034 for more details.\n if (typeof value == 'function') {\n return value;\n }\n if (value == null) {\n return identity;\n }\n if (typeof value == 'object') {\n return isArray(value)\n ? baseMatchesProperty(value[0], value[1])\n : baseMatches(value);\n }\n return property(value);\n }\n\n /**\n * The base implementation of `_.keys` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\n function baseKeys(object) {\n if (!isPrototype(object)) {\n return nativeKeys(object);\n }\n var result = [];\n for (var key in Object(object)) {\n if (hasOwnProperty.call(object, key) && key != 'constructor') {\n result.push(key);\n }\n }\n return result;\n }\n\n /**\n * The base implementation of `_.keysIn` which doesn't treat sparse arrays as dense.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\n function baseKeysIn(object) {\n if (!isObject(object)) {\n return nativeKeysIn(object);\n }\n var isProto = isPrototype(object),\n result = [];\n\n for (var key in object) {\n if (!(key == 'constructor' && (isProto || !hasOwnProperty.call(object, key)))) {\n result.push(key);\n }\n }\n return result;\n }\n\n /**\n * The base implementation of `_.lt` which doesn't coerce arguments.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if `value` is less than `other`,\n * else `false`.\n */\n function baseLt(value, other) {\n return value < other;\n }\n\n /**\n * The base implementation of `_.map` without support for iteratee shorthands.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} iteratee The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n */\n function baseMap(collection, iteratee) {\n var index = -1,\n result = isArrayLike(collection) ? Array(collection.length) : [];\n\n baseEach(collection, function(value, key, collection) {\n result[++index] = iteratee(value, key, collection);\n });\n return result;\n }\n\n /**\n * The base implementation of `_.matches` which doesn't clone `source`.\n *\n * @private\n * @param {Object} source The object of property values to match.\n * @returns {Function} Returns the new spec function.\n */\n function baseMatches(source) {\n var matchData = getMatchData(source);\n if (matchData.length == 1 && matchData[0][2]) {\n return matchesStrictComparable(matchData[0][0], matchData[0][1]);\n }\n return function(object) {\n return object === source || baseIsMatch(object, source, matchData);\n };\n }\n\n /**\n * The base implementation of `_.matchesProperty` which doesn't clone `srcValue`.\n *\n * @private\n * @param {string} path The path of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\n function baseMatchesProperty(path, srcValue) {\n if (isKey(path) && isStrictComparable(srcValue)) {\n return matchesStrictComparable(toKey(path), srcValue);\n }\n return function(object) {\n var objValue = get(object, path);\n return (objValue === undefined && objValue === srcValue)\n ? hasIn(object, path)\n : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);\n };\n }\n\n /**\n * The base implementation of `_.merge` without support for multiple sources.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @param {number} srcIndex The index of `source`.\n * @param {Function} [customizer] The function to customize merged values.\n * @param {Object} [stack] Tracks traversed source values and their merged\n * counterparts.\n */\n function baseMerge(object, source, srcIndex, customizer, stack) {\n if (object === source) {\n return;\n }\n baseFor(source, function(srcValue, key) {\n stack || (stack = new Stack);\n if (isObject(srcValue)) {\n baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack);\n }\n else {\n var newValue = customizer\n ? customizer(safeGet(object, key), srcValue, (key + ''), object, source, stack)\n : undefined;\n\n if (newValue === undefined) {\n newValue = srcValue;\n }\n assignMergeValue(object, key, newValue);\n }\n }, keysIn);\n }\n\n /**\n * A specialized version of `baseMerge` for arrays and objects which performs\n * deep merges and tracks traversed objects enabling objects with circular\n * references to be merged.\n *\n * @private\n * @param {Object} object The destination object.\n * @param {Object} source The source object.\n * @param {string} key The key of the value to merge.\n * @param {number} srcIndex The index of `source`.\n * @param {Function} mergeFunc The function to merge values.\n * @param {Function} [customizer] The function to customize assigned values.\n * @param {Object} [stack] Tracks traversed source values and their merged\n * counterparts.\n */\n function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) {\n var objValue = safeGet(object, key),\n srcValue = safeGet(source, key),\n stacked = stack.get(srcValue);\n\n if (stacked) {\n assignMergeValue(object, key, stacked);\n return;\n }\n var newValue = customizer\n ? customizer(objValue, srcValue, (key + ''), object, source, stack)\n : undefined;\n\n var isCommon = newValue === undefined;\n\n if (isCommon) {\n var isArr = isArray(srcValue),\n isBuff = !isArr && isBuffer(srcValue),\n isTyped = !isArr && !isBuff && isTypedArray(srcValue);\n\n newValue = srcValue;\n if (isArr || isBuff || isTyped) {\n if (isArray(objValue)) {\n newValue = objValue;\n }\n else if (isArrayLikeObject(objValue)) {\n newValue = copyArray(objValue);\n }\n else if (isBuff) {\n isCommon = false;\n newValue = cloneBuffer(srcValue, true);\n }\n else if (isTyped) {\n isCommon = false;\n newValue = cloneTypedArray(srcValue, true);\n }\n else {\n newValue = [];\n }\n }\n else if (isPlainObject(srcValue) || isArguments(srcValue)) {\n newValue = objValue;\n if (isArguments(objValue)) {\n newValue = toPlainObject(objValue);\n }\n else if (!isObject(objValue) || isFunction(objValue)) {\n newValue = initCloneObject(srcValue);\n }\n }\n else {\n isCommon = false;\n }\n }\n if (isCommon) {\n // Recursively merge objects and arrays (susceptible to call stack limits).\n stack.set(srcValue, newValue);\n mergeFunc(newValue, srcValue, srcIndex, customizer, stack);\n stack['delete'](srcValue);\n }\n assignMergeValue(object, key, newValue);\n }\n\n /**\n * The base implementation of `_.nth` which doesn't coerce arguments.\n *\n * @private\n * @param {Array} array The array to query.\n * @param {number} n The index of the element to return.\n * @returns {*} Returns the nth element of `array`.\n */\n function baseNth(array, n) {\n var length = array.length;\n if (!length) {\n return;\n }\n n += n < 0 ? length : 0;\n return isIndex(n, length) ? array[n] : undefined;\n }\n\n /**\n * The base implementation of `_.orderBy` without param guards.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function[]|Object[]|string[]} iteratees The iteratees to sort by.\n * @param {string[]} orders The sort orders of `iteratees`.\n * @returns {Array} Returns the new sorted array.\n */\n function baseOrderBy(collection, iteratees, orders) {\n if (iteratees.length) {\n iteratees = arrayMap(iteratees, function(iteratee) {\n if (isArray(iteratee)) {\n return function(value) {\n return baseGet(value, iteratee.length === 1 ? iteratee[0] : iteratee);\n }\n }\n return iteratee;\n });\n } else {\n iteratees = [identity];\n }\n\n var index = -1;\n iteratees = arrayMap(iteratees, baseUnary(getIteratee()));\n\n var result = baseMap(collection, function(value, key, collection) {\n var criteria = arrayMap(iteratees, function(iteratee) {\n return iteratee(value);\n });\n return { 'criteria': criteria, 'index': ++index, 'value': value };\n });\n\n return baseSortBy(result, function(object, other) {\n return compareMultiple(object, other, orders);\n });\n }\n\n /**\n * The base implementation of `_.pick` without support for individual\n * property identifiers.\n *\n * @private\n * @param {Object} object The source object.\n * @param {string[]} paths The property paths to pick.\n * @returns {Object} Returns the new object.\n */\n function basePick(object, paths) {\n return basePickBy(object, paths, function(value, path) {\n return hasIn(object, path);\n });\n }\n\n /**\n * The base implementation of `_.pickBy` without support for iteratee shorthands.\n *\n * @private\n * @param {Object} object The source object.\n * @param {string[]} paths The property paths to pick.\n * @param {Function} predicate The function invoked per property.\n * @returns {Object} Returns the new object.\n */\n function basePickBy(object, paths, predicate) {\n var index = -1,\n length = paths.length,\n result = {};\n\n while (++index < length) {\n var path = paths[index],\n value = baseGet(object, path);\n\n if (predicate(value, path)) {\n baseSet(result, castPath(path, object), value);\n }\n }\n return result;\n }\n\n /**\n * A specialized version of `baseProperty` which supports deep paths.\n *\n * @private\n * @param {Array|string} path The path of the property to get.\n * @returns {Function} Returns the new accessor function.\n */\n function basePropertyDeep(path) {\n return function(object) {\n return baseGet(object, path);\n };\n }\n\n /**\n * The base implementation of `_.pullAllBy` without support for iteratee\n * shorthands.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {Array} values The values to remove.\n * @param {Function} [iteratee] The iteratee invoked per element.\n * @param {Function} [comparator] The comparator invoked per element.\n * @returns {Array} Returns `array`.\n */\n function basePullAll(array, values, iteratee, comparator) {\n var indexOf = comparator ? baseIndexOfWith : baseIndexOf,\n index = -1,\n length = values.length,\n seen = array;\n\n if (array === values) {\n values = copyArray(values);\n }\n if (iteratee) {\n seen = arrayMap(array, baseUnary(iteratee));\n }\n while (++index < length) {\n var fromIndex = 0,\n value = values[index],\n computed = iteratee ? iteratee(value) : value;\n\n while ((fromIndex = indexOf(seen, computed, fromIndex, comparator)) > -1) {\n if (seen !== array) {\n splice.call(seen, fromIndex, 1);\n }\n splice.call(array, fromIndex, 1);\n }\n }\n return array;\n }\n\n /**\n * The base implementation of `_.pullAt` without support for individual\n * indexes or capturing the removed elements.\n *\n * @private\n * @param {Array} array The array to modify.\n * @param {number[]} indexes The indexes of elements to remove.\n * @returns {Array} Returns `array`.\n */\n function basePullAt(array, indexes) {\n var length = array ? indexes.length : 0,\n lastIndex = length - 1;\n\n while (length--) {\n var index = indexes[length];\n if (length == lastIndex || index !== previous) {\n var previous = index;\n if (isIndex(index)) {\n splice.call(array, index, 1);\n } else {\n baseUnset(array, index);\n }\n }\n }\n return array;\n }\n\n /**\n * The base implementation of `_.random` without support for returning\n * floating-point numbers.\n *\n * @private\n * @param {number} lower The lower bound.\n * @param {number} upper The upper bound.\n * @returns {number} Returns the random number.\n */\n function baseRandom(lower, upper) {\n return lower + nativeFloor(nativeRandom() * (upper - lower + 1));\n }\n\n /**\n * The base implementation of `_.range` and `_.rangeRight` which doesn't\n * coerce arguments.\n *\n * @private\n * @param {number} start The start of the range.\n * @param {number} end The end of the range.\n * @param {number} step The value to increment or decrement by.\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Array} Returns the range of numbers.\n */\n function baseRange(start, end, step, fromRight) {\n var index = -1,\n length = nativeMax(nativeCeil((end - start) / (step || 1)), 0),\n result = Array(length);\n\n while (length--) {\n result[fromRight ? length : ++index] = start;\n start += step;\n }\n return result;\n }\n\n /**\n * The base implementation of `_.repeat` which doesn't coerce arguments.\n *\n * @private\n * @param {string} string The string to repeat.\n * @param {number} n The number of times to repeat the string.\n * @returns {string} Returns the repeated string.\n */\n function baseRepeat(string, n) {\n var result = '';\n if (!string || n < 1 || n > MAX_SAFE_INTEGER) {\n return result;\n }\n // Leverage the exponentiation by squaring algorithm for a faster repeat.\n // See https://en.wikipedia.org/wiki/Exponentiation_by_squaring for more details.\n do {\n if (n % 2) {\n result += string;\n }\n n = nativeFloor(n / 2);\n if (n) {\n string += string;\n }\n } while (n);\n\n return result;\n }\n\n /**\n * The base implementation of `_.rest` which doesn't validate or coerce arguments.\n *\n * @private\n * @param {Function} func The function to apply a rest parameter to.\n * @param {number} [start=func.length-1] The start position of the rest parameter.\n * @returns {Function} Returns the new function.\n */\n function baseRest(func, start) {\n return setToString(overRest(func, start, identity), func + '');\n }\n\n /**\n * The base implementation of `_.sample`.\n *\n * @private\n * @param {Array|Object} collection The collection to sample.\n * @returns {*} Returns the random element.\n */\n function baseSample(collection) {\n return arraySample(values(collection));\n }\n\n /**\n * The base implementation of `_.sampleSize` without param guards.\n *\n * @private\n * @param {Array|Object} collection The collection to sample.\n * @param {number} n The number of elements to sample.\n * @returns {Array} Returns the random elements.\n */\n function baseSampleSize(collection, n) {\n var array = values(collection);\n return shuffleSelf(array, baseClamp(n, 0, array.length));\n }\n\n /**\n * The base implementation of `_.set`.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {Array|string} path The path of the property to set.\n * @param {*} value The value to set.\n * @param {Function} [customizer] The function to customize path creation.\n * @returns {Object} Returns `object`.\n */\n function baseSet(object, path, value, customizer) {\n if (!isObject(object)) {\n return object;\n }\n path = castPath(path, object);\n\n var index = -1,\n length = path.length,\n lastIndex = length - 1,\n nested = object;\n\n while (nested != null && ++index < length) {\n var key = toKey(path[index]),\n newValue = value;\n\n if (key === '__proto__' || key === 'constructor' || key === 'prototype') {\n return object;\n }\n\n if (index != lastIndex) {\n var objValue = nested[key];\n newValue = customizer ? customizer(objValue, key, nested) : undefined;\n if (newValue === undefined) {\n newValue = isObject(objValue)\n ? objValue\n : (isIndex(path[index + 1]) ? [] : {});\n }\n }\n assignValue(nested, key, newValue);\n nested = nested[key];\n }\n return object;\n }\n\n /**\n * The base implementation of `setData` without support for hot loop shorting.\n *\n * @private\n * @param {Function} func The function to associate metadata with.\n * @param {*} data The metadata.\n * @returns {Function} Returns `func`.\n */\n var baseSetData = !metaMap ? identity : function(func, data) {\n metaMap.set(func, data);\n return func;\n };\n\n /**\n * The base implementation of `setToString` without support for hot loop shorting.\n *\n * @private\n * @param {Function} func The function to modify.\n * @param {Function} string The `toString` result.\n * @returns {Function} Returns `func`.\n */\n var baseSetToString = !defineProperty ? identity : function(func, string) {\n return defineProperty(func, 'toString', {\n 'configurable': true,\n 'enumerable': false,\n 'value': constant(string),\n 'writable': true\n });\n };\n\n /**\n * The base implementation of `_.shuffle`.\n *\n * @private\n * @param {Array|Object} collection The collection to shuffle.\n * @returns {Array} Returns the new shuffled array.\n */\n function baseShuffle(collection) {\n return shuffleSelf(values(collection));\n }\n\n /**\n * The base implementation of `_.slice` without an iteratee call guard.\n *\n * @private\n * @param {Array} array The array to slice.\n * @param {number} [start=0] The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the slice of `array`.\n */\n function baseSlice(array, start, end) {\n var index = -1,\n length = array.length;\n\n if (start < 0) {\n start = -start > length ? 0 : (length + start);\n }\n end = end > length ? length : end;\n if (end < 0) {\n end += length;\n }\n length = start > end ? 0 : ((end - start) >>> 0);\n start >>>= 0;\n\n var result = Array(length);\n while (++index < length) {\n result[index] = array[index + start];\n }\n return result;\n }\n\n /**\n * The base implementation of `_.some` without support for iteratee shorthands.\n *\n * @private\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} predicate The function invoked per iteration.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n */\n function baseSome(collection, predicate) {\n var result;\n\n baseEach(collection, function(value, index, collection) {\n result = predicate(value, index, collection);\n return !result;\n });\n return !!result;\n }\n\n /**\n * The base implementation of `_.sortedIndex` and `_.sortedLastIndex` which\n * performs a binary search of `array` to determine the index at which `value`\n * should be inserted into `array` in order to maintain its sort order.\n *\n * @private\n * @param {Array} array The sorted array to inspect.\n * @param {*} value The value to evaluate.\n * @param {boolean} [retHighest] Specify returning the highest qualified index.\n * @returns {number} Returns the index at which `value` should be inserted\n * into `array`.\n */\n function baseSortedIndex(array, value, retHighest) {\n var low = 0,\n high = array == null ? low : array.length;\n\n if (typeof value == 'number' && value === value && high <= HALF_MAX_ARRAY_LENGTH) {\n while (low < high) {\n var mid = (low + high) >>> 1,\n computed = array[mid];\n\n if (computed !== null && !isSymbol(computed) &&\n (retHighest ? (computed <= value) : (computed < value))) {\n low = mid + 1;\n } else {\n high = mid;\n }\n }\n return high;\n }\n return baseSortedIndexBy(array, value, identity, retHighest);\n }\n\n /**\n * The base implementation of `_.sortedIndexBy` and `_.sortedLastIndexBy`\n * which invokes `iteratee` for `value` and each element of `array` to compute\n * their sort ranking. The iteratee is invoked with one argument; (value).\n *\n * @private\n * @param {Array} array The sorted array to inspect.\n * @param {*} value The value to evaluate.\n * @param {Function} iteratee The iteratee invoked per element.\n * @param {boolean} [retHighest] Specify returning the highest qualified index.\n * @returns {number} Returns the index at which `value` should be inserted\n * into `array`.\n */\n function baseSortedIndexBy(array, value, iteratee, retHighest) {\n var low = 0,\n high = array == null ? 0 : array.length;\n if (high === 0) {\n return 0;\n }\n\n value = iteratee(value);\n var valIsNaN = value !== value,\n valIsNull = value === null,\n valIsSymbol = isSymbol(value),\n valIsUndefined = value === undefined;\n\n while (low < high) {\n var mid = nativeFloor((low + high) / 2),\n computed = iteratee(array[mid]),\n othIsDefined = computed !== undefined,\n othIsNull = computed === null,\n othIsReflexive = computed === computed,\n othIsSymbol = isSymbol(computed);\n\n if (valIsNaN) {\n var setLow = retHighest || othIsReflexive;\n } else if (valIsUndefined) {\n setLow = othIsReflexive && (retHighest || othIsDefined);\n } else if (valIsNull) {\n setLow = othIsReflexive && othIsDefined && (retHighest || !othIsNull);\n } else if (valIsSymbol) {\n setLow = othIsReflexive && othIsDefined && !othIsNull && (retHighest || !othIsSymbol);\n } else if (othIsNull || othIsSymbol) {\n setLow = false;\n } else {\n setLow = retHighest ? (computed <= value) : (computed < value);\n }\n if (setLow) {\n low = mid + 1;\n } else {\n high = mid;\n }\n }\n return nativeMin(high, MAX_ARRAY_INDEX);\n }\n\n /**\n * The base implementation of `_.sortedUniq` and `_.sortedUniqBy` without\n * support for iteratee shorthands.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {Function} [iteratee] The iteratee invoked per element.\n * @returns {Array} Returns the new duplicate free array.\n */\n function baseSortedUniq(array, iteratee) {\n var index = -1,\n length = array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index],\n computed = iteratee ? iteratee(value) : value;\n\n if (!index || !eq(computed, seen)) {\n var seen = computed;\n result[resIndex++] = value === 0 ? 0 : value;\n }\n }\n return result;\n }\n\n /**\n * The base implementation of `_.toNumber` which doesn't ensure correct\n * conversions of binary, hexadecimal, or octal string values.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {number} Returns the number.\n */\n function baseToNumber(value) {\n if (typeof value == 'number') {\n return value;\n }\n if (isSymbol(value)) {\n return NAN;\n }\n return +value;\n }\n\n /**\n * The base implementation of `_.toString` which doesn't convert nullish\n * values to empty strings.\n *\n * @private\n * @param {*} value The value to process.\n * @returns {string} Returns the string.\n */\n function baseToString(value) {\n // Exit early for strings to avoid a performance hit in some environments.\n if (typeof value == 'string') {\n return value;\n }\n if (isArray(value)) {\n // Recursively convert values (susceptible to call stack limits).\n return arrayMap(value, baseToString) + '';\n }\n if (isSymbol(value)) {\n return symbolToString ? symbolToString.call(value) : '';\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n }\n\n /**\n * The base implementation of `_.uniqBy` without support for iteratee shorthands.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {Function} [iteratee] The iteratee invoked per element.\n * @param {Function} [comparator] The comparator invoked per element.\n * @returns {Array} Returns the new duplicate free array.\n */\n function baseUniq(array, iteratee, comparator) {\n var index = -1,\n includes = arrayIncludes,\n length = array.length,\n isCommon = true,\n result = [],\n seen = result;\n\n if (comparator) {\n isCommon = false;\n includes = arrayIncludesWith;\n }\n else if (length >= LARGE_ARRAY_SIZE) {\n var set = iteratee ? null : createSet(array);\n if (set) {\n return setToArray(set);\n }\n isCommon = false;\n includes = cacheHas;\n seen = new SetCache;\n }\n else {\n seen = iteratee ? [] : result;\n }\n outer:\n while (++index < length) {\n var value = array[index],\n computed = iteratee ? iteratee(value) : value;\n\n value = (comparator || value !== 0) ? value : 0;\n if (isCommon && computed === computed) {\n var seenIndex = seen.length;\n while (seenIndex--) {\n if (seen[seenIndex] === computed) {\n continue outer;\n }\n }\n if (iteratee) {\n seen.push(computed);\n }\n result.push(value);\n }\n else if (!includes(seen, computed, comparator)) {\n if (seen !== result) {\n seen.push(computed);\n }\n result.push(value);\n }\n }\n return result;\n }\n\n /**\n * The base implementation of `_.unset`.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {Array|string} path The property path to unset.\n * @returns {boolean} Returns `true` if the property is deleted, else `false`.\n */\n function baseUnset(object, path) {\n path = castPath(path, object);\n object = parent(object, path);\n return object == null || delete object[toKey(last(path))];\n }\n\n /**\n * The base implementation of `_.update`.\n *\n * @private\n * @param {Object} object The object to modify.\n * @param {Array|string} path The path of the property to update.\n * @param {Function} updater The function to produce the updated value.\n * @param {Function} [customizer] The function to customize path creation.\n * @returns {Object} Returns `object`.\n */\n function baseUpdate(object, path, updater, customizer) {\n return baseSet(object, path, updater(baseGet(object, path)), customizer);\n }\n\n /**\n * The base implementation of methods like `_.dropWhile` and `_.takeWhile`\n * without support for iteratee shorthands.\n *\n * @private\n * @param {Array} array The array to query.\n * @param {Function} predicate The function invoked per iteration.\n * @param {boolean} [isDrop] Specify dropping elements instead of taking them.\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Array} Returns the slice of `array`.\n */\n function baseWhile(array, predicate, isDrop, fromRight) {\n var length = array.length,\n index = fromRight ? length : -1;\n\n while ((fromRight ? index-- : ++index < length) &&\n predicate(array[index], index, array)) {}\n\n return isDrop\n ? baseSlice(array, (fromRight ? 0 : index), (fromRight ? index + 1 : length))\n : baseSlice(array, (fromRight ? index + 1 : 0), (fromRight ? length : index));\n }\n\n /**\n * The base implementation of `wrapperValue` which returns the result of\n * performing a sequence of actions on the unwrapped `value`, where each\n * successive action is supplied the return value of the previous.\n *\n * @private\n * @param {*} value The unwrapped value.\n * @param {Array} actions Actions to perform to resolve the unwrapped value.\n * @returns {*} Returns the resolved value.\n */\n function baseWrapperValue(value, actions) {\n var result = value;\n if (result instanceof LazyWrapper) {\n result = result.value();\n }\n return arrayReduce(actions, function(result, action) {\n return action.func.apply(action.thisArg, arrayPush([result], action.args));\n }, result);\n }\n\n /**\n * The base implementation of methods like `_.xor`, without support for\n * iteratee shorthands, that accepts an array of arrays to inspect.\n *\n * @private\n * @param {Array} arrays The arrays to inspect.\n * @param {Function} [iteratee] The iteratee invoked per element.\n * @param {Function} [comparator] The comparator invoked per element.\n * @returns {Array} Returns the new array of values.\n */\n function baseXor(arrays, iteratee, comparator) {\n var length = arrays.length;\n if (length < 2) {\n return length ? baseUniq(arrays[0]) : [];\n }\n var index = -1,\n result = Array(length);\n\n while (++index < length) {\n var array = arrays[index],\n othIndex = -1;\n\n while (++othIndex < length) {\n if (othIndex != index) {\n result[index] = baseDifference(result[index] || array, arrays[othIndex], iteratee, comparator);\n }\n }\n }\n return baseUniq(baseFlatten(result, 1), iteratee, comparator);\n }\n\n /**\n * This base implementation of `_.zipObject` which assigns values using `assignFunc`.\n *\n * @private\n * @param {Array} props The property identifiers.\n * @param {Array} values The property values.\n * @param {Function} assignFunc The function to assign values.\n * @returns {Object} Returns the new object.\n */\n function baseZipObject(props, values, assignFunc) {\n var index = -1,\n length = props.length,\n valsLength = values.length,\n result = {};\n\n while (++index < length) {\n var value = index < valsLength ? values[index] : undefined;\n assignFunc(result, props[index], value);\n }\n return result;\n }\n\n /**\n * Casts `value` to an empty array if it's not an array like object.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {Array|Object} Returns the cast array-like object.\n */\n function castArrayLikeObject(value) {\n return isArrayLikeObject(value) ? value : [];\n }\n\n /**\n * Casts `value` to `identity` if it's not a function.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {Function} Returns cast function.\n */\n function castFunction(value) {\n return typeof value == 'function' ? value : identity;\n }\n\n /**\n * Casts `value` to a path array if it's not one.\n *\n * @private\n * @param {*} value The value to inspect.\n * @param {Object} [object] The object to query keys on.\n * @returns {Array} Returns the cast property path array.\n */\n function castPath(value, object) {\n if (isArray(value)) {\n return value;\n }\n return isKey(value, object) ? [value] : stringToPath(toString(value));\n }\n\n /**\n * A `baseRest` alias which can be replaced with `identity` by module\n * replacement plugins.\n *\n * @private\n * @type {Function}\n * @param {Function} func The function to apply a rest parameter to.\n * @returns {Function} Returns the new function.\n */\n var castRest = baseRest;\n\n /**\n * Casts `array` to a slice if it's needed.\n *\n * @private\n * @param {Array} array The array to inspect.\n * @param {number} start The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the cast slice.\n */\n function castSlice(array, start, end) {\n var length = array.length;\n end = end === undefined ? length : end;\n return (!start && end >= length) ? array : baseSlice(array, start, end);\n }\n\n /**\n * A simple wrapper around the global [`clearTimeout`](https://mdn.io/clearTimeout).\n *\n * @private\n * @param {number|Object} id The timer id or timeout object of the timer to clear.\n */\n var clearTimeout = ctxClearTimeout || function(id) {\n return root.clearTimeout(id);\n };\n\n /**\n * Creates a clone of `buffer`.\n *\n * @private\n * @param {Buffer} buffer The buffer to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Buffer} Returns the cloned buffer.\n */\n function cloneBuffer(buffer, isDeep) {\n if (isDeep) {\n return buffer.slice();\n }\n var length = buffer.length,\n result = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length);\n\n buffer.copy(result);\n return result;\n }\n\n /**\n * Creates a clone of `arrayBuffer`.\n *\n * @private\n * @param {ArrayBuffer} arrayBuffer The array buffer to clone.\n * @returns {ArrayBuffer} Returns the cloned array buffer.\n */\n function cloneArrayBuffer(arrayBuffer) {\n var result = new arrayBuffer.constructor(arrayBuffer.byteLength);\n new Uint8Array(result).set(new Uint8Array(arrayBuffer));\n return result;\n }\n\n /**\n * Creates a clone of `dataView`.\n *\n * @private\n * @param {Object} dataView The data view to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Object} Returns the cloned data view.\n */\n function cloneDataView(dataView, isDeep) {\n var buffer = isDeep ? cloneArrayBuffer(dataView.buffer) : dataView.buffer;\n return new dataView.constructor(buffer, dataView.byteOffset, dataView.byteLength);\n }\n\n /**\n * Creates a clone of `regexp`.\n *\n * @private\n * @param {Object} regexp The regexp to clone.\n * @returns {Object} Returns the cloned regexp.\n */\n function cloneRegExp(regexp) {\n var result = new regexp.constructor(regexp.source, reFlags.exec(regexp));\n result.lastIndex = regexp.lastIndex;\n return result;\n }\n\n /**\n * Creates a clone of the `symbol` object.\n *\n * @private\n * @param {Object} symbol The symbol object to clone.\n * @returns {Object} Returns the cloned symbol object.\n */\n function cloneSymbol(symbol) {\n return symbolValueOf ? Object(symbolValueOf.call(symbol)) : {};\n }\n\n /**\n * Creates a clone of `typedArray`.\n *\n * @private\n * @param {Object} typedArray The typed array to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Object} Returns the cloned typed array.\n */\n function cloneTypedArray(typedArray, isDeep) {\n var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer;\n return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);\n }\n\n /**\n * Compares values to sort them in ascending order.\n *\n * @private\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {number} Returns the sort order indicator for `value`.\n */\n function compareAscending(value, other) {\n if (value !== other) {\n var valIsDefined = value !== undefined,\n valIsNull = value === null,\n valIsReflexive = value === value,\n valIsSymbol = isSymbol(value);\n\n var othIsDefined = other !== undefined,\n othIsNull = other === null,\n othIsReflexive = other === other,\n othIsSymbol = isSymbol(other);\n\n if ((!othIsNull && !othIsSymbol && !valIsSymbol && value > other) ||\n (valIsSymbol && othIsDefined && othIsReflexive && !othIsNull && !othIsSymbol) ||\n (valIsNull && othIsDefined && othIsReflexive) ||\n (!valIsDefined && othIsReflexive) ||\n !valIsReflexive) {\n return 1;\n }\n if ((!valIsNull && !valIsSymbol && !othIsSymbol && value < other) ||\n (othIsSymbol && valIsDefined && valIsReflexive && !valIsNull && !valIsSymbol) ||\n (othIsNull && valIsDefined && valIsReflexive) ||\n (!othIsDefined && valIsReflexive) ||\n !othIsReflexive) {\n return -1;\n }\n }\n return 0;\n }\n\n /**\n * Used by `_.orderBy` to compare multiple properties of a value to another\n * and stable sort them.\n *\n * If `orders` is unspecified, all values are sorted in ascending order. Otherwise,\n * specify an order of \"desc\" for descending or \"asc\" for ascending sort order\n * of corresponding values.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {boolean[]|string[]} orders The order to sort by for each property.\n * @returns {number} Returns the sort order indicator for `object`.\n */\n function compareMultiple(object, other, orders) {\n var index = -1,\n objCriteria = object.criteria,\n othCriteria = other.criteria,\n length = objCriteria.length,\n ordersLength = orders.length;\n\n while (++index < length) {\n var result = compareAscending(objCriteria[index], othCriteria[index]);\n if (result) {\n if (index >= ordersLength) {\n return result;\n }\n var order = orders[index];\n return result * (order == 'desc' ? -1 : 1);\n }\n }\n // Fixes an `Array#sort` bug in the JS engine embedded in Adobe applications\n // that causes it, under certain circumstances, to provide the same value for\n // `object` and `other`. See https://github.com/jashkenas/underscore/pull/1247\n // for more details.\n //\n // This also ensures a stable sort in V8 and other engines.\n // See https://bugs.chromium.org/p/v8/issues/detail?id=90 for more details.\n return object.index - other.index;\n }\n\n /**\n * Creates an array that is the composition of partially applied arguments,\n * placeholders, and provided arguments into a single array of arguments.\n *\n * @private\n * @param {Array} args The provided arguments.\n * @param {Array} partials The arguments to prepend to those provided.\n * @param {Array} holders The `partials` placeholder indexes.\n * @params {boolean} [isCurried] Specify composing for a curried function.\n * @returns {Array} Returns the new array of composed arguments.\n */\n function composeArgs(args, partials, holders, isCurried) {\n var argsIndex = -1,\n argsLength = args.length,\n holdersLength = holders.length,\n leftIndex = -1,\n leftLength = partials.length,\n rangeLength = nativeMax(argsLength - holdersLength, 0),\n result = Array(leftLength + rangeLength),\n isUncurried = !isCurried;\n\n while (++leftIndex < leftLength) {\n result[leftIndex] = partials[leftIndex];\n }\n while (++argsIndex < holdersLength) {\n if (isUncurried || argsIndex < argsLength) {\n result[holders[argsIndex]] = args[argsIndex];\n }\n }\n while (rangeLength--) {\n result[leftIndex++] = args[argsIndex++];\n }\n return result;\n }\n\n /**\n * This function is like `composeArgs` except that the arguments composition\n * is tailored for `_.partialRight`.\n *\n * @private\n * @param {Array} args The provided arguments.\n * @param {Array} partials The arguments to append to those provided.\n * @param {Array} holders The `partials` placeholder indexes.\n * @params {boolean} [isCurried] Specify composing for a curried function.\n * @returns {Array} Returns the new array of composed arguments.\n */\n function composeArgsRight(args, partials, holders, isCurried) {\n var argsIndex = -1,\n argsLength = args.length,\n holdersIndex = -1,\n holdersLength = holders.length,\n rightIndex = -1,\n rightLength = partials.length,\n rangeLength = nativeMax(argsLength - holdersLength, 0),\n result = Array(rangeLength + rightLength),\n isUncurried = !isCurried;\n\n while (++argsIndex < rangeLength) {\n result[argsIndex] = args[argsIndex];\n }\n var offset = argsIndex;\n while (++rightIndex < rightLength) {\n result[offset + rightIndex] = partials[rightIndex];\n }\n while (++holdersIndex < holdersLength) {\n if (isUncurried || argsIndex < argsLength) {\n result[offset + holders[holdersIndex]] = args[argsIndex++];\n }\n }\n return result;\n }\n\n /**\n * Copies the values of `source` to `array`.\n *\n * @private\n * @param {Array} source The array to copy values from.\n * @param {Array} [array=[]] The array to copy values to.\n * @returns {Array} Returns `array`.\n */\n function copyArray(source, array) {\n var index = -1,\n length = source.length;\n\n array || (array = Array(length));\n while (++index < length) {\n array[index] = source[index];\n }\n return array;\n }\n\n /**\n * Copies properties of `source` to `object`.\n *\n * @private\n * @param {Object} source The object to copy properties from.\n * @param {Array} props The property identifiers to copy.\n * @param {Object} [object={}] The object to copy properties to.\n * @param {Function} [customizer] The function to customize copied values.\n * @returns {Object} Returns `object`.\n */\n function copyObject(source, props, object, customizer) {\n var isNew = !object;\n object || (object = {});\n\n var index = -1,\n length = props.length;\n\n while (++index < length) {\n var key = props[index];\n\n var newValue = customizer\n ? customizer(object[key], source[key], key, object, source)\n : undefined;\n\n if (newValue === undefined) {\n newValue = source[key];\n }\n if (isNew) {\n baseAssignValue(object, key, newValue);\n } else {\n assignValue(object, key, newValue);\n }\n }\n return object;\n }\n\n /**\n * Copies own symbols of `source` to `object`.\n *\n * @private\n * @param {Object} source The object to copy symbols from.\n * @param {Object} [object={}] The object to copy symbols to.\n * @returns {Object} Returns `object`.\n */\n function copySymbols(source, object) {\n return copyObject(source, getSymbols(source), object);\n }\n\n /**\n * Copies own and inherited symbols of `source` to `object`.\n *\n * @private\n * @param {Object} source The object to copy symbols from.\n * @param {Object} [object={}] The object to copy symbols to.\n * @returns {Object} Returns `object`.\n */\n function copySymbolsIn(source, object) {\n return copyObject(source, getSymbolsIn(source), object);\n }\n\n /**\n * Creates a function like `_.groupBy`.\n *\n * @private\n * @param {Function} setter The function to set accumulator values.\n * @param {Function} [initializer] The accumulator object initializer.\n * @returns {Function} Returns the new aggregator function.\n */\n function createAggregator(setter, initializer) {\n return function(collection, iteratee) {\n var func = isArray(collection) ? arrayAggregator : baseAggregator,\n accumulator = initializer ? initializer() : {};\n\n return func(collection, setter, getIteratee(iteratee, 2), accumulator);\n };\n }\n\n /**\n * Creates a function like `_.assign`.\n *\n * @private\n * @param {Function} assigner The function to assign values.\n * @returns {Function} Returns the new assigner function.\n */\n function createAssigner(assigner) {\n return baseRest(function(object, sources) {\n var index = -1,\n length = sources.length,\n customizer = length > 1 ? sources[length - 1] : undefined,\n guard = length > 2 ? sources[2] : undefined;\n\n customizer = (assigner.length > 3 && typeof customizer == 'function')\n ? (length--, customizer)\n : undefined;\n\n if (guard && isIterateeCall(sources[0], sources[1], guard)) {\n customizer = length < 3 ? undefined : customizer;\n length = 1;\n }\n object = Object(object);\n while (++index < length) {\n var source = sources[index];\n if (source) {\n assigner(object, source, index, customizer);\n }\n }\n return object;\n });\n }\n\n /**\n * Creates a `baseEach` or `baseEachRight` function.\n *\n * @private\n * @param {Function} eachFunc The function to iterate over a collection.\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\n function createBaseEach(eachFunc, fromRight) {\n return function(collection, iteratee) {\n if (collection == null) {\n return collection;\n }\n if (!isArrayLike(collection)) {\n return eachFunc(collection, iteratee);\n }\n var length = collection.length,\n index = fromRight ? length : -1,\n iterable = Object(collection);\n\n while ((fromRight ? index-- : ++index < length)) {\n if (iteratee(iterable[index], index, iterable) === false) {\n break;\n }\n }\n return collection;\n };\n }\n\n /**\n * Creates a base function for methods like `_.forIn` and `_.forOwn`.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new base function.\n */\n function createBaseFor(fromRight) {\n return function(object, iteratee, keysFunc) {\n var index = -1,\n iterable = Object(object),\n props = keysFunc(object),\n length = props.length;\n\n while (length--) {\n var key = props[fromRight ? length : ++index];\n if (iteratee(iterable[key], key, iterable) === false) {\n break;\n }\n }\n return object;\n };\n }\n\n /**\n * Creates a function that wraps `func` to invoke it with the optional `this`\n * binding of `thisArg`.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\n * @param {*} [thisArg] The `this` binding of `func`.\n * @returns {Function} Returns the new wrapped function.\n */\n function createBind(func, bitmask, thisArg) {\n var isBind = bitmask & WRAP_BIND_FLAG,\n Ctor = createCtor(func);\n\n function wrapper() {\n var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;\n return fn.apply(isBind ? thisArg : this, arguments);\n }\n return wrapper;\n }\n\n /**\n * Creates a function like `_.lowerFirst`.\n *\n * @private\n * @param {string} methodName The name of the `String` case method to use.\n * @returns {Function} Returns the new case function.\n */\n function createCaseFirst(methodName) {\n return function(string) {\n string = toString(string);\n\n var strSymbols = hasUnicode(string)\n ? stringToArray(string)\n : undefined;\n\n var chr = strSymbols\n ? strSymbols[0]\n : string.charAt(0);\n\n var trailing = strSymbols\n ? castSlice(strSymbols, 1).join('')\n : string.slice(1);\n\n return chr[methodName]() + trailing;\n };\n }\n\n /**\n * Creates a function like `_.camelCase`.\n *\n * @private\n * @param {Function} callback The function to combine each word.\n * @returns {Function} Returns the new compounder function.\n */\n function createCompounder(callback) {\n return function(string) {\n return arrayReduce(words(deburr(string).replace(reApos, '')), callback, '');\n };\n }\n\n /**\n * Creates a function that produces an instance of `Ctor` regardless of\n * whether it was invoked as part of a `new` expression or by `call` or `apply`.\n *\n * @private\n * @param {Function} Ctor The constructor to wrap.\n * @returns {Function} Returns the new wrapped function.\n */\n function createCtor(Ctor) {\n return function() {\n // Use a `switch` statement to work with class constructors. See\n // http://ecma-international.org/ecma-262/7.0/#sec-ecmascript-function-objects-call-thisargument-argumentslist\n // for more details.\n var args = arguments;\n switch (args.length) {\n case 0: return new Ctor;\n case 1: return new Ctor(args[0]);\n case 2: return new Ctor(args[0], args[1]);\n case 3: return new Ctor(args[0], args[1], args[2]);\n case 4: return new Ctor(args[0], args[1], args[2], args[3]);\n case 5: return new Ctor(args[0], args[1], args[2], args[3], args[4]);\n case 6: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5]);\n case 7: return new Ctor(args[0], args[1], args[2], args[3], args[4], args[5], args[6]);\n }\n var thisBinding = baseCreate(Ctor.prototype),\n result = Ctor.apply(thisBinding, args);\n\n // Mimic the constructor's `return` behavior.\n // See https://es5.github.io/#x13.2.2 for more details.\n return isObject(result) ? result : thisBinding;\n };\n }\n\n /**\n * Creates a function that wraps `func` to enable currying.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\n * @param {number} arity The arity of `func`.\n * @returns {Function} Returns the new wrapped function.\n */\n function createCurry(func, bitmask, arity) {\n var Ctor = createCtor(func);\n\n function wrapper() {\n var length = arguments.length,\n args = Array(length),\n index = length,\n placeholder = getHolder(wrapper);\n\n while (index--) {\n args[index] = arguments[index];\n }\n var holders = (length < 3 && args[0] !== placeholder && args[length - 1] !== placeholder)\n ? []\n : replaceHolders(args, placeholder);\n\n length -= holders.length;\n if (length < arity) {\n return createRecurry(\n func, bitmask, createHybrid, wrapper.placeholder, undefined,\n args, holders, undefined, undefined, arity - length);\n }\n var fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;\n return apply(fn, this, args);\n }\n return wrapper;\n }\n\n /**\n * Creates a `_.find` or `_.findLast` function.\n *\n * @private\n * @param {Function} findIndexFunc The function to find the collection index.\n * @returns {Function} Returns the new find function.\n */\n function createFind(findIndexFunc) {\n return function(collection, predicate, fromIndex) {\n var iterable = Object(collection);\n if (!isArrayLike(collection)) {\n var iteratee = getIteratee(predicate, 3);\n collection = keys(collection);\n predicate = function(key) { return iteratee(iterable[key], key, iterable); };\n }\n var index = findIndexFunc(collection, predicate, fromIndex);\n return index > -1 ? iterable[iteratee ? collection[index] : index] : undefined;\n };\n }\n\n /**\n * Creates a `_.flow` or `_.flowRight` function.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new flow function.\n */\n function createFlow(fromRight) {\n return flatRest(function(funcs) {\n var length = funcs.length,\n index = length,\n prereq = LodashWrapper.prototype.thru;\n\n if (fromRight) {\n funcs.reverse();\n }\n while (index--) {\n var func = funcs[index];\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n if (prereq && !wrapper && getFuncName(func) == 'wrapper') {\n var wrapper = new LodashWrapper([], true);\n }\n }\n index = wrapper ? index : length;\n while (++index < length) {\n func = funcs[index];\n\n var funcName = getFuncName(func),\n data = funcName == 'wrapper' ? getData(func) : undefined;\n\n if (data && isLaziable(data[0]) &&\n data[1] == (WRAP_ARY_FLAG | WRAP_CURRY_FLAG | WRAP_PARTIAL_FLAG | WRAP_REARG_FLAG) &&\n !data[4].length && data[9] == 1\n ) {\n wrapper = wrapper[getFuncName(data[0])].apply(wrapper, data[3]);\n } else {\n wrapper = (func.length == 1 && isLaziable(func))\n ? wrapper[funcName]()\n : wrapper.thru(func);\n }\n }\n return function() {\n var args = arguments,\n value = args[0];\n\n if (wrapper && args.length == 1 && isArray(value)) {\n return wrapper.plant(value).value();\n }\n var index = 0,\n result = length ? funcs[index].apply(this, args) : value;\n\n while (++index < length) {\n result = funcs[index].call(this, result);\n }\n return result;\n };\n });\n }\n\n /**\n * Creates a function that wraps `func` to invoke it with optional `this`\n * binding of `thisArg`, partial application, and currying.\n *\n * @private\n * @param {Function|string} func The function or method name to wrap.\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\n * @param {*} [thisArg] The `this` binding of `func`.\n * @param {Array} [partials] The arguments to prepend to those provided to\n * the new function.\n * @param {Array} [holders] The `partials` placeholder indexes.\n * @param {Array} [partialsRight] The arguments to append to those provided\n * to the new function.\n * @param {Array} [holdersRight] The `partialsRight` placeholder indexes.\n * @param {Array} [argPos] The argument positions of the new function.\n * @param {number} [ary] The arity cap of `func`.\n * @param {number} [arity] The arity of `func`.\n * @returns {Function} Returns the new wrapped function.\n */\n function createHybrid(func, bitmask, thisArg, partials, holders, partialsRight, holdersRight, argPos, ary, arity) {\n var isAry = bitmask & WRAP_ARY_FLAG,\n isBind = bitmask & WRAP_BIND_FLAG,\n isBindKey = bitmask & WRAP_BIND_KEY_FLAG,\n isCurried = bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG),\n isFlip = bitmask & WRAP_FLIP_FLAG,\n Ctor = isBindKey ? undefined : createCtor(func);\n\n function wrapper() {\n var length = arguments.length,\n args = Array(length),\n index = length;\n\n while (index--) {\n args[index] = arguments[index];\n }\n if (isCurried) {\n var placeholder = getHolder(wrapper),\n holdersCount = countHolders(args, placeholder);\n }\n if (partials) {\n args = composeArgs(args, partials, holders, isCurried);\n }\n if (partialsRight) {\n args = composeArgsRight(args, partialsRight, holdersRight, isCurried);\n }\n length -= holdersCount;\n if (isCurried && length < arity) {\n var newHolders = replaceHolders(args, placeholder);\n return createRecurry(\n func, bitmask, createHybrid, wrapper.placeholder, thisArg,\n args, newHolders, argPos, ary, arity - length\n );\n }\n var thisBinding = isBind ? thisArg : this,\n fn = isBindKey ? thisBinding[func] : func;\n\n length = args.length;\n if (argPos) {\n args = reorder(args, argPos);\n } else if (isFlip && length > 1) {\n args.reverse();\n }\n if (isAry && ary < length) {\n args.length = ary;\n }\n if (this && this !== root && this instanceof wrapper) {\n fn = Ctor || createCtor(fn);\n }\n return fn.apply(thisBinding, args);\n }\n return wrapper;\n }\n\n /**\n * Creates a function like `_.invertBy`.\n *\n * @private\n * @param {Function} setter The function to set accumulator values.\n * @param {Function} toIteratee The function to resolve iteratees.\n * @returns {Function} Returns the new inverter function.\n */\n function createInverter(setter, toIteratee) {\n return function(object, iteratee) {\n return baseInverter(object, setter, toIteratee(iteratee), {});\n };\n }\n\n /**\n * Creates a function that performs a mathematical operation on two values.\n *\n * @private\n * @param {Function} operator The function to perform the operation.\n * @param {number} [defaultValue] The value used for `undefined` arguments.\n * @returns {Function} Returns the new mathematical operation function.\n */\n function createMathOperation(operator, defaultValue) {\n return function(value, other) {\n var result;\n if (value === undefined && other === undefined) {\n return defaultValue;\n }\n if (value !== undefined) {\n result = value;\n }\n if (other !== undefined) {\n if (result === undefined) {\n return other;\n }\n if (typeof value == 'string' || typeof other == 'string') {\n value = baseToString(value);\n other = baseToString(other);\n } else {\n value = baseToNumber(value);\n other = baseToNumber(other);\n }\n result = operator(value, other);\n }\n return result;\n };\n }\n\n /**\n * Creates a function like `_.over`.\n *\n * @private\n * @param {Function} arrayFunc The function to iterate over iteratees.\n * @returns {Function} Returns the new over function.\n */\n function createOver(arrayFunc) {\n return flatRest(function(iteratees) {\n iteratees = arrayMap(iteratees, baseUnary(getIteratee()));\n return baseRest(function(args) {\n var thisArg = this;\n return arrayFunc(iteratees, function(iteratee) {\n return apply(iteratee, thisArg, args);\n });\n });\n });\n }\n\n /**\n * Creates the padding for `string` based on `length`. The `chars` string\n * is truncated if the number of characters exceeds `length`.\n *\n * @private\n * @param {number} length The padding length.\n * @param {string} [chars=' '] The string used as padding.\n * @returns {string} Returns the padding for `string`.\n */\n function createPadding(length, chars) {\n chars = chars === undefined ? ' ' : baseToString(chars);\n\n var charsLength = chars.length;\n if (charsLength < 2) {\n return charsLength ? baseRepeat(chars, length) : chars;\n }\n var result = baseRepeat(chars, nativeCeil(length / stringSize(chars)));\n return hasUnicode(chars)\n ? castSlice(stringToArray(result), 0, length).join('')\n : result.slice(0, length);\n }\n\n /**\n * Creates a function that wraps `func` to invoke it with the `this` binding\n * of `thisArg` and `partials` prepended to the arguments it receives.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\n * @param {*} thisArg The `this` binding of `func`.\n * @param {Array} partials The arguments to prepend to those provided to\n * the new function.\n * @returns {Function} Returns the new wrapped function.\n */\n function createPartial(func, bitmask, thisArg, partials) {\n var isBind = bitmask & WRAP_BIND_FLAG,\n Ctor = createCtor(func);\n\n function wrapper() {\n var argsIndex = -1,\n argsLength = arguments.length,\n leftIndex = -1,\n leftLength = partials.length,\n args = Array(leftLength + argsLength),\n fn = (this && this !== root && this instanceof wrapper) ? Ctor : func;\n\n while (++leftIndex < leftLength) {\n args[leftIndex] = partials[leftIndex];\n }\n while (argsLength--) {\n args[leftIndex++] = arguments[++argsIndex];\n }\n return apply(fn, isBind ? thisArg : this, args);\n }\n return wrapper;\n }\n\n /**\n * Creates a `_.range` or `_.rangeRight` function.\n *\n * @private\n * @param {boolean} [fromRight] Specify iterating from right to left.\n * @returns {Function} Returns the new range function.\n */\n function createRange(fromRight) {\n return function(start, end, step) {\n if (step && typeof step != 'number' && isIterateeCall(start, end, step)) {\n end = step = undefined;\n }\n // Ensure the sign of `-0` is preserved.\n start = toFinite(start);\n if (end === undefined) {\n end = start;\n start = 0;\n } else {\n end = toFinite(end);\n }\n step = step === undefined ? (start < end ? 1 : -1) : toFinite(step);\n return baseRange(start, end, step, fromRight);\n };\n }\n\n /**\n * Creates a function that performs a relational operation on two values.\n *\n * @private\n * @param {Function} operator The function to perform the operation.\n * @returns {Function} Returns the new relational operation function.\n */\n function createRelationalOperation(operator) {\n return function(value, other) {\n if (!(typeof value == 'string' && typeof other == 'string')) {\n value = toNumber(value);\n other = toNumber(other);\n }\n return operator(value, other);\n };\n }\n\n /**\n * Creates a function that wraps `func` to continue currying.\n *\n * @private\n * @param {Function} func The function to wrap.\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\n * @param {Function} wrapFunc The function to create the `func` wrapper.\n * @param {*} placeholder The placeholder value.\n * @param {*} [thisArg] The `this` binding of `func`.\n * @param {Array} [partials] The arguments to prepend to those provided to\n * the new function.\n * @param {Array} [holders] The `partials` placeholder indexes.\n * @param {Array} [argPos] The argument positions of the new function.\n * @param {number} [ary] The arity cap of `func`.\n * @param {number} [arity] The arity of `func`.\n * @returns {Function} Returns the new wrapped function.\n */\n function createRecurry(func, bitmask, wrapFunc, placeholder, thisArg, partials, holders, argPos, ary, arity) {\n var isCurry = bitmask & WRAP_CURRY_FLAG,\n newHolders = isCurry ? holders : undefined,\n newHoldersRight = isCurry ? undefined : holders,\n newPartials = isCurry ? partials : undefined,\n newPartialsRight = isCurry ? undefined : partials;\n\n bitmask |= (isCurry ? WRAP_PARTIAL_FLAG : WRAP_PARTIAL_RIGHT_FLAG);\n bitmask &= ~(isCurry ? WRAP_PARTIAL_RIGHT_FLAG : WRAP_PARTIAL_FLAG);\n\n if (!(bitmask & WRAP_CURRY_BOUND_FLAG)) {\n bitmask &= ~(WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG);\n }\n var newData = [\n func, bitmask, thisArg, newPartials, newHolders, newPartialsRight,\n newHoldersRight, argPos, ary, arity\n ];\n\n var result = wrapFunc.apply(undefined, newData);\n if (isLaziable(func)) {\n setData(result, newData);\n }\n result.placeholder = placeholder;\n return setWrapToString(result, func, bitmask);\n }\n\n /**\n * Creates a function like `_.round`.\n *\n * @private\n * @param {string} methodName The name of the `Math` method to use when rounding.\n * @returns {Function} Returns the new round function.\n */\n function createRound(methodName) {\n var func = Math[methodName];\n return function(number, precision) {\n number = toNumber(number);\n precision = precision == null ? 0 : nativeMin(toInteger(precision), 292);\n if (precision && nativeIsFinite(number)) {\n // Shift with exponential notation to avoid floating-point issues.\n // See [MDN](https://mdn.io/round#Examples) for more details.\n var pair = (toString(number) + 'e').split('e'),\n value = func(pair[0] + 'e' + (+pair[1] + precision));\n\n pair = (toString(value) + 'e').split('e');\n return +(pair[0] + 'e' + (+pair[1] - precision));\n }\n return func(number);\n };\n }\n\n /**\n * Creates a set object of `values`.\n *\n * @private\n * @param {Array} values The values to add to the set.\n * @returns {Object} Returns the new set.\n */\n var createSet = !(Set && (1 / setToArray(new Set([,-0]))[1]) == INFINITY) ? noop : function(values) {\n return new Set(values);\n };\n\n /**\n * Creates a `_.toPairs` or `_.toPairsIn` function.\n *\n * @private\n * @param {Function} keysFunc The function to get the keys of a given object.\n * @returns {Function} Returns the new pairs function.\n */\n function createToPairs(keysFunc) {\n return function(object) {\n var tag = getTag(object);\n if (tag == mapTag) {\n return mapToArray(object);\n }\n if (tag == setTag) {\n return setToPairs(object);\n }\n return baseToPairs(object, keysFunc(object));\n };\n }\n\n /**\n * Creates a function that either curries or invokes `func` with optional\n * `this` binding and partially applied arguments.\n *\n * @private\n * @param {Function|string} func The function or method name to wrap.\n * @param {number} bitmask The bitmask flags.\n * 1 - `_.bind`\n * 2 - `_.bindKey`\n * 4 - `_.curry` or `_.curryRight` of a bound function\n * 8 - `_.curry`\n * 16 - `_.curryRight`\n * 32 - `_.partial`\n * 64 - `_.partialRight`\n * 128 - `_.rearg`\n * 256 - `_.ary`\n * 512 - `_.flip`\n * @param {*} [thisArg] The `this` binding of `func`.\n * @param {Array} [partials] The arguments to be partially applied.\n * @param {Array} [holders] The `partials` placeholder indexes.\n * @param {Array} [argPos] The argument positions of the new function.\n * @param {number} [ary] The arity cap of `func`.\n * @param {number} [arity] The arity of `func`.\n * @returns {Function} Returns the new wrapped function.\n */\n function createWrap(func, bitmask, thisArg, partials, holders, argPos, ary, arity) {\n var isBindKey = bitmask & WRAP_BIND_KEY_FLAG;\n if (!isBindKey && typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var length = partials ? partials.length : 0;\n if (!length) {\n bitmask &= ~(WRAP_PARTIAL_FLAG | WRAP_PARTIAL_RIGHT_FLAG);\n partials = holders = undefined;\n }\n ary = ary === undefined ? ary : nativeMax(toInteger(ary), 0);\n arity = arity === undefined ? arity : toInteger(arity);\n length -= holders ? holders.length : 0;\n\n if (bitmask & WRAP_PARTIAL_RIGHT_FLAG) {\n var partialsRight = partials,\n holdersRight = holders;\n\n partials = holders = undefined;\n }\n var data = isBindKey ? undefined : getData(func);\n\n var newData = [\n func, bitmask, thisArg, partials, holders, partialsRight, holdersRight,\n argPos, ary, arity\n ];\n\n if (data) {\n mergeData(newData, data);\n }\n func = newData[0];\n bitmask = newData[1];\n thisArg = newData[2];\n partials = newData[3];\n holders = newData[4];\n arity = newData[9] = newData[9] === undefined\n ? (isBindKey ? 0 : func.length)\n : nativeMax(newData[9] - length, 0);\n\n if (!arity && bitmask & (WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG)) {\n bitmask &= ~(WRAP_CURRY_FLAG | WRAP_CURRY_RIGHT_FLAG);\n }\n if (!bitmask || bitmask == WRAP_BIND_FLAG) {\n var result = createBind(func, bitmask, thisArg);\n } else if (bitmask == WRAP_CURRY_FLAG || bitmask == WRAP_CURRY_RIGHT_FLAG) {\n result = createCurry(func, bitmask, arity);\n } else if ((bitmask == WRAP_PARTIAL_FLAG || bitmask == (WRAP_BIND_FLAG | WRAP_PARTIAL_FLAG)) && !holders.length) {\n result = createPartial(func, bitmask, thisArg, partials);\n } else {\n result = createHybrid.apply(undefined, newData);\n }\n var setter = data ? baseSetData : setData;\n return setWrapToString(setter(result, newData), func, bitmask);\n }\n\n /**\n * Used by `_.defaults` to customize its `_.assignIn` use to assign properties\n * of source objects to the destination object for all destination properties\n * that resolve to `undefined`.\n *\n * @private\n * @param {*} objValue The destination value.\n * @param {*} srcValue The source value.\n * @param {string} key The key of the property to assign.\n * @param {Object} object The parent object of `objValue`.\n * @returns {*} Returns the value to assign.\n */\n function customDefaultsAssignIn(objValue, srcValue, key, object) {\n if (objValue === undefined ||\n (eq(objValue, objectProto[key]) && !hasOwnProperty.call(object, key))) {\n return srcValue;\n }\n return objValue;\n }\n\n /**\n * Used by `_.defaultsDeep` to customize its `_.merge` use to merge source\n * objects into destination objects that are passed thru.\n *\n * @private\n * @param {*} objValue The destination value.\n * @param {*} srcValue The source value.\n * @param {string} key The key of the property to merge.\n * @param {Object} object The parent object of `objValue`.\n * @param {Object} source The parent object of `srcValue`.\n * @param {Object} [stack] Tracks traversed source values and their merged\n * counterparts.\n * @returns {*} Returns the value to assign.\n */\n function customDefaultsMerge(objValue, srcValue, key, object, source, stack) {\n if (isObject(objValue) && isObject(srcValue)) {\n // Recursively merge objects and arrays (susceptible to call stack limits).\n stack.set(srcValue, objValue);\n baseMerge(objValue, srcValue, undefined, customDefaultsMerge, stack);\n stack['delete'](srcValue);\n }\n return objValue;\n }\n\n /**\n * Used by `_.omit` to customize its `_.cloneDeep` use to only clone plain\n * objects.\n *\n * @private\n * @param {*} value The value to inspect.\n * @param {string} key The key of the property to inspect.\n * @returns {*} Returns the uncloned value or `undefined` to defer cloning to `_.cloneDeep`.\n */\n function customOmitClone(value) {\n return isPlainObject(value) ? undefined : value;\n }\n\n /**\n * A specialized version of `baseIsEqualDeep` for arrays with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Array} array The array to compare.\n * @param {Array} other The other array to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `array` and `other` objects.\n * @returns {boolean} Returns `true` if the arrays are equivalent, else `false`.\n */\n function equalArrays(array, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n arrLength = array.length,\n othLength = other.length;\n\n if (arrLength != othLength && !(isPartial && othLength > arrLength)) {\n return false;\n }\n // Check that cyclic values are equal.\n var arrStacked = stack.get(array);\n var othStacked = stack.get(other);\n if (arrStacked && othStacked) {\n return arrStacked == other && othStacked == array;\n }\n var index = -1,\n result = true,\n seen = (bitmask & COMPARE_UNORDERED_FLAG) ? new SetCache : undefined;\n\n stack.set(array, other);\n stack.set(other, array);\n\n // Ignore non-index properties.\n while (++index < arrLength) {\n var arrValue = array[index],\n othValue = other[index];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, arrValue, index, other, array, stack)\n : customizer(arrValue, othValue, index, array, other, stack);\n }\n if (compared !== undefined) {\n if (compared) {\n continue;\n }\n result = false;\n break;\n }\n // Recursively compare arrays (susceptible to call stack limits).\n if (seen) {\n if (!arraySome(other, function(othValue, othIndex) {\n if (!cacheHas(seen, othIndex) &&\n (arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {\n return seen.push(othIndex);\n }\n })) {\n result = false;\n break;\n }\n } else if (!(\n arrValue === othValue ||\n equalFunc(arrValue, othValue, bitmask, customizer, stack)\n )) {\n result = false;\n break;\n }\n }\n stack['delete'](array);\n stack['delete'](other);\n return result;\n }\n\n /**\n * A specialized version of `baseIsEqualDeep` for comparing objects of\n * the same `toStringTag`.\n *\n * **Note:** This function only supports comparing values with tags of\n * `Boolean`, `Date`, `Error`, `Number`, `RegExp`, or `String`.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {string} tag The `toStringTag` of the objects to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\n function equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {\n switch (tag) {\n case dataViewTag:\n if ((object.byteLength != other.byteLength) ||\n (object.byteOffset != other.byteOffset)) {\n return false;\n }\n object = object.buffer;\n other = other.buffer;\n\n case arrayBufferTag:\n if ((object.byteLength != other.byteLength) ||\n !equalFunc(new Uint8Array(object), new Uint8Array(other))) {\n return false;\n }\n return true;\n\n case boolTag:\n case dateTag:\n case numberTag:\n // Coerce booleans to `1` or `0` and dates to milliseconds.\n // Invalid dates are coerced to `NaN`.\n return eq(+object, +other);\n\n case errorTag:\n return object.name == other.name && object.message == other.message;\n\n case regexpTag:\n case stringTag:\n // Coerce regexes to strings and treat strings, primitives and objects,\n // as equal. See http://www.ecma-international.org/ecma-262/7.0/#sec-regexp.prototype.tostring\n // for more details.\n return object == (other + '');\n\n case mapTag:\n var convert = mapToArray;\n\n case setTag:\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG;\n convert || (convert = setToArray);\n\n if (object.size != other.size && !isPartial) {\n return false;\n }\n // Assume cyclic values are equal.\n var stacked = stack.get(object);\n if (stacked) {\n return stacked == other;\n }\n bitmask |= COMPARE_UNORDERED_FLAG;\n\n // Recursively compare objects (susceptible to call stack limits).\n stack.set(object, other);\n var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);\n stack['delete'](object);\n return result;\n\n case symbolTag:\n if (symbolValueOf) {\n return symbolValueOf.call(object) == symbolValueOf.call(other);\n }\n }\n return false;\n }\n\n /**\n * A specialized version of `baseIsEqualDeep` for objects with support for\n * partial deep comparisons.\n *\n * @private\n * @param {Object} object The object to compare.\n * @param {Object} other The other object to compare.\n * @param {number} bitmask The bitmask flags. See `baseIsEqual` for more details.\n * @param {Function} customizer The function to customize comparisons.\n * @param {Function} equalFunc The function to determine equivalents of values.\n * @param {Object} stack Tracks traversed `object` and `other` objects.\n * @returns {boolean} Returns `true` if the objects are equivalent, else `false`.\n */\n function equalObjects(object, other, bitmask, customizer, equalFunc, stack) {\n var isPartial = bitmask & COMPARE_PARTIAL_FLAG,\n objProps = getAllKeys(object),\n objLength = objProps.length,\n othProps = getAllKeys(other),\n othLength = othProps.length;\n\n if (objLength != othLength && !isPartial) {\n return false;\n }\n var index = objLength;\n while (index--) {\n var key = objProps[index];\n if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {\n return false;\n }\n }\n // Check that cyclic values are equal.\n var objStacked = stack.get(object);\n var othStacked = stack.get(other);\n if (objStacked && othStacked) {\n return objStacked == other && othStacked == object;\n }\n var result = true;\n stack.set(object, other);\n stack.set(other, object);\n\n var skipCtor = isPartial;\n while (++index < objLength) {\n key = objProps[index];\n var objValue = object[key],\n othValue = other[key];\n\n if (customizer) {\n var compared = isPartial\n ? customizer(othValue, objValue, key, other, object, stack)\n : customizer(objValue, othValue, key, object, other, stack);\n }\n // Recursively compare objects (susceptible to call stack limits).\n if (!(compared === undefined\n ? (objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack))\n : compared\n )) {\n result = false;\n break;\n }\n skipCtor || (skipCtor = key == 'constructor');\n }\n if (result && !skipCtor) {\n var objCtor = object.constructor,\n othCtor = other.constructor;\n\n // Non `Object` object instances with different constructors are not equal.\n if (objCtor != othCtor &&\n ('constructor' in object && 'constructor' in other) &&\n !(typeof objCtor == 'function' && objCtor instanceof objCtor &&\n typeof othCtor == 'function' && othCtor instanceof othCtor)) {\n result = false;\n }\n }\n stack['delete'](object);\n stack['delete'](other);\n return result;\n }\n\n /**\n * A specialized version of `baseRest` which flattens the rest array.\n *\n * @private\n * @param {Function} func The function to apply a rest parameter to.\n * @returns {Function} Returns the new function.\n */\n function flatRest(func) {\n return setToString(overRest(func, undefined, flatten), func + '');\n }\n\n /**\n * Creates an array of own enumerable property names and symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\n function getAllKeys(object) {\n return baseGetAllKeys(object, keys, getSymbols);\n }\n\n /**\n * Creates an array of own and inherited enumerable property names and\n * symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names and symbols.\n */\n function getAllKeysIn(object) {\n return baseGetAllKeys(object, keysIn, getSymbolsIn);\n }\n\n /**\n * Gets metadata for `func`.\n *\n * @private\n * @param {Function} func The function to query.\n * @returns {*} Returns the metadata for `func`.\n */\n var getData = !metaMap ? noop : function(func) {\n return metaMap.get(func);\n };\n\n /**\n * Gets the name of `func`.\n *\n * @private\n * @param {Function} func The function to query.\n * @returns {string} Returns the function name.\n */\n function getFuncName(func) {\n var result = (func.name + ''),\n array = realNames[result],\n length = hasOwnProperty.call(realNames, result) ? array.length : 0;\n\n while (length--) {\n var data = array[length],\n otherFunc = data.func;\n if (otherFunc == null || otherFunc == func) {\n return data.name;\n }\n }\n return result;\n }\n\n /**\n * Gets the argument placeholder value for `func`.\n *\n * @private\n * @param {Function} func The function to inspect.\n * @returns {*} Returns the placeholder value.\n */\n function getHolder(func) {\n var object = hasOwnProperty.call(lodash, 'placeholder') ? lodash : func;\n return object.placeholder;\n }\n\n /**\n * Gets the appropriate \"iteratee\" function. If `_.iteratee` is customized,\n * this function returns the custom method, otherwise it returns `baseIteratee`.\n * If arguments are provided, the chosen function is invoked with them and\n * its result is returned.\n *\n * @private\n * @param {*} [value] The value to convert to an iteratee.\n * @param {number} [arity] The arity of the created iteratee.\n * @returns {Function} Returns the chosen function or its result.\n */\n function getIteratee() {\n var result = lodash.iteratee || iteratee;\n result = result === iteratee ? baseIteratee : result;\n return arguments.length ? result(arguments[0], arguments[1]) : result;\n }\n\n /**\n * Gets the data for `map`.\n *\n * @private\n * @param {Object} map The map to query.\n * @param {string} key The reference key.\n * @returns {*} Returns the map data.\n */\n function getMapData(map, key) {\n var data = map.__data__;\n return isKeyable(key)\n ? data[typeof key == 'string' ? 'string' : 'hash']\n : data.map;\n }\n\n /**\n * Gets the property names, values, and compare flags of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the match data of `object`.\n */\n function getMatchData(object) {\n var result = keys(object),\n length = result.length;\n\n while (length--) {\n var key = result[length],\n value = object[key];\n\n result[length] = [key, value, isStrictComparable(value)];\n }\n return result;\n }\n\n /**\n * Gets the native function at `key` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the method to get.\n * @returns {*} Returns the function if it's native, else `undefined`.\n */\n function getNative(object, key) {\n var value = getValue(object, key);\n return baseIsNative(value) ? value : undefined;\n }\n\n /**\n * A specialized version of `baseGetTag` which ignores `Symbol.toStringTag` values.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the raw `toStringTag`.\n */\n function getRawTag(value) {\n var isOwn = hasOwnProperty.call(value, symToStringTag),\n tag = value[symToStringTag];\n\n try {\n value[symToStringTag] = undefined;\n var unmasked = true;\n } catch (e) {}\n\n var result = nativeObjectToString.call(value);\n if (unmasked) {\n if (isOwn) {\n value[symToStringTag] = tag;\n } else {\n delete value[symToStringTag];\n }\n }\n return result;\n }\n\n /**\n * Creates an array of the own enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\n var getSymbols = !nativeGetSymbols ? stubArray : function(object) {\n if (object == null) {\n return [];\n }\n object = Object(object);\n return arrayFilter(nativeGetSymbols(object), function(symbol) {\n return propertyIsEnumerable.call(object, symbol);\n });\n };\n\n /**\n * Creates an array of the own and inherited enumerable symbols of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of symbols.\n */\n var getSymbolsIn = !nativeGetSymbols ? stubArray : function(object) {\n var result = [];\n while (object) {\n arrayPush(result, getSymbols(object));\n object = getPrototype(object);\n }\n return result;\n };\n\n /**\n * Gets the `toStringTag` of `value`.\n *\n * @private\n * @param {*} value The value to query.\n * @returns {string} Returns the `toStringTag`.\n */\n var getTag = baseGetTag;\n\n // Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.\n if ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag) ||\n (Map && getTag(new Map) != mapTag) ||\n (Promise && getTag(Promise.resolve()) != promiseTag) ||\n (Set && getTag(new Set) != setTag) ||\n (WeakMap && getTag(new WeakMap) != weakMapTag)) {\n getTag = function(value) {\n var result = baseGetTag(value),\n Ctor = result == objectTag ? value.constructor : undefined,\n ctorString = Ctor ? toSource(Ctor) : '';\n\n if (ctorString) {\n switch (ctorString) {\n case dataViewCtorString: return dataViewTag;\n case mapCtorString: return mapTag;\n case promiseCtorString: return promiseTag;\n case setCtorString: return setTag;\n case weakMapCtorString: return weakMapTag;\n }\n }\n return result;\n };\n }\n\n /**\n * Gets the view, applying any `transforms` to the `start` and `end` positions.\n *\n * @private\n * @param {number} start The start of the view.\n * @param {number} end The end of the view.\n * @param {Array} transforms The transformations to apply to the view.\n * @returns {Object} Returns an object containing the `start` and `end`\n * positions of the view.\n */\n function getView(start, end, transforms) {\n var index = -1,\n length = transforms.length;\n\n while (++index < length) {\n var data = transforms[index],\n size = data.size;\n\n switch (data.type) {\n case 'drop': start += size; break;\n case 'dropRight': end -= size; break;\n case 'take': end = nativeMin(end, start + size); break;\n case 'takeRight': start = nativeMax(start, end - size); break;\n }\n }\n return { 'start': start, 'end': end };\n }\n\n /**\n * Extracts wrapper details from the `source` body comment.\n *\n * @private\n * @param {string} source The source to inspect.\n * @returns {Array} Returns the wrapper details.\n */\n function getWrapDetails(source) {\n var match = source.match(reWrapDetails);\n return match ? match[1].split(reSplitDetails) : [];\n }\n\n /**\n * Checks if `path` exists on `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @param {Function} hasFunc The function to check properties.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n */\n function hasPath(object, path, hasFunc) {\n path = castPath(path, object);\n\n var index = -1,\n length = path.length,\n result = false;\n\n while (++index < length) {\n var key = toKey(path[index]);\n if (!(result = object != null && hasFunc(object, key))) {\n break;\n }\n object = object[key];\n }\n if (result || ++index != length) {\n return result;\n }\n length = object == null ? 0 : object.length;\n return !!length && isLength(length) && isIndex(key, length) &&\n (isArray(object) || isArguments(object));\n }\n\n /**\n * Initializes an array clone.\n *\n * @private\n * @param {Array} array The array to clone.\n * @returns {Array} Returns the initialized clone.\n */\n function initCloneArray(array) {\n var length = array.length,\n result = new array.constructor(length);\n\n // Add properties assigned by `RegExp#exec`.\n if (length && typeof array[0] == 'string' && hasOwnProperty.call(array, 'index')) {\n result.index = array.index;\n result.input = array.input;\n }\n return result;\n }\n\n /**\n * Initializes an object clone.\n *\n * @private\n * @param {Object} object The object to clone.\n * @returns {Object} Returns the initialized clone.\n */\n function initCloneObject(object) {\n return (typeof object.constructor == 'function' && !isPrototype(object))\n ? baseCreate(getPrototype(object))\n : {};\n }\n\n /**\n * Initializes an object clone based on its `toStringTag`.\n *\n * **Note:** This function only supports cloning values with tags of\n * `Boolean`, `Date`, `Error`, `Map`, `Number`, `RegExp`, `Set`, or `String`.\n *\n * @private\n * @param {Object} object The object to clone.\n * @param {string} tag The `toStringTag` of the object to clone.\n * @param {boolean} [isDeep] Specify a deep clone.\n * @returns {Object} Returns the initialized clone.\n */\n function initCloneByTag(object, tag, isDeep) {\n var Ctor = object.constructor;\n switch (tag) {\n case arrayBufferTag:\n return cloneArrayBuffer(object);\n\n case boolTag:\n case dateTag:\n return new Ctor(+object);\n\n case dataViewTag:\n return cloneDataView(object, isDeep);\n\n case float32Tag: case float64Tag:\n case int8Tag: case int16Tag: case int32Tag:\n case uint8Tag: case uint8ClampedTag: case uint16Tag: case uint32Tag:\n return cloneTypedArray(object, isDeep);\n\n case mapTag:\n return new Ctor;\n\n case numberTag:\n case stringTag:\n return new Ctor(object);\n\n case regexpTag:\n return cloneRegExp(object);\n\n case setTag:\n return new Ctor;\n\n case symbolTag:\n return cloneSymbol(object);\n }\n }\n\n /**\n * Inserts wrapper `details` in a comment at the top of the `source` body.\n *\n * @private\n * @param {string} source The source to modify.\n * @returns {Array} details The details to insert.\n * @returns {string} Returns the modified source.\n */\n function insertWrapDetails(source, details) {\n var length = details.length;\n if (!length) {\n return source;\n }\n var lastIndex = length - 1;\n details[lastIndex] = (length > 1 ? '& ' : '') + details[lastIndex];\n details = details.join(length > 2 ? ', ' : ' ');\n return source.replace(reWrapComment, '{\\n/* [wrapped with ' + details + '] */\\n');\n }\n\n /**\n * Checks if `value` is a flattenable `arguments` object or array.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is flattenable, else `false`.\n */\n function isFlattenable(value) {\n return isArray(value) || isArguments(value) ||\n !!(spreadableSymbol && value && value[spreadableSymbol]);\n }\n\n /**\n * Checks if `value` is a valid array-like index.\n *\n * @private\n * @param {*} value The value to check.\n * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index.\n * @returns {boolean} Returns `true` if `value` is a valid index, else `false`.\n */\n function isIndex(value, length) {\n var type = typeof value;\n length = length == null ? MAX_SAFE_INTEGER : length;\n\n return !!length &&\n (type == 'number' ||\n (type != 'symbol' && reIsUint.test(value))) &&\n (value > -1 && value % 1 == 0 && value < length);\n }\n\n /**\n * Checks if the given arguments are from an iteratee call.\n *\n * @private\n * @param {*} value The potential iteratee value argument.\n * @param {*} index The potential iteratee index or key argument.\n * @param {*} object The potential iteratee object argument.\n * @returns {boolean} Returns `true` if the arguments are from an iteratee call,\n * else `false`.\n */\n function isIterateeCall(value, index, object) {\n if (!isObject(object)) {\n return false;\n }\n var type = typeof index;\n if (type == 'number'\n ? (isArrayLike(object) && isIndex(index, object.length))\n : (type == 'string' && index in object)\n ) {\n return eq(object[index], value);\n }\n return false;\n }\n\n /**\n * Checks if `value` is a property name and not a property path.\n *\n * @private\n * @param {*} value The value to check.\n * @param {Object} [object] The object to query keys on.\n * @returns {boolean} Returns `true` if `value` is a property name, else `false`.\n */\n function isKey(value, object) {\n if (isArray(value)) {\n return false;\n }\n var type = typeof value;\n if (type == 'number' || type == 'symbol' || type == 'boolean' ||\n value == null || isSymbol(value)) {\n return true;\n }\n return reIsPlainProp.test(value) || !reIsDeepProp.test(value) ||\n (object != null && value in Object(object));\n }\n\n /**\n * Checks if `value` is suitable for use as unique object key.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is suitable, else `false`.\n */\n function isKeyable(value) {\n var type = typeof value;\n return (type == 'string' || type == 'number' || type == 'symbol' || type == 'boolean')\n ? (value !== '__proto__')\n : (value === null);\n }\n\n /**\n * Checks if `func` has a lazy counterpart.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` has a lazy counterpart,\n * else `false`.\n */\n function isLaziable(func) {\n var funcName = getFuncName(func),\n other = lodash[funcName];\n\n if (typeof other != 'function' || !(funcName in LazyWrapper.prototype)) {\n return false;\n }\n if (func === other) {\n return true;\n }\n var data = getData(other);\n return !!data && func === data[0];\n }\n\n /**\n * Checks if `func` has its source masked.\n *\n * @private\n * @param {Function} func The function to check.\n * @returns {boolean} Returns `true` if `func` is masked, else `false`.\n */\n function isMasked(func) {\n return !!maskSrcKey && (maskSrcKey in func);\n }\n\n /**\n * Checks if `func` is capable of being masked.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `func` is maskable, else `false`.\n */\n var isMaskable = coreJsData ? isFunction : stubFalse;\n\n /**\n * Checks if `value` is likely a prototype object.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a prototype, else `false`.\n */\n function isPrototype(value) {\n var Ctor = value && value.constructor,\n proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto;\n\n return value === proto;\n }\n\n /**\n * Checks if `value` is suitable for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` if suitable for strict\n * equality comparisons, else `false`.\n */\n function isStrictComparable(value) {\n return value === value && !isObject(value);\n }\n\n /**\n * A specialized version of `matchesProperty` for source values suitable\n * for strict equality comparisons, i.e. `===`.\n *\n * @private\n * @param {string} key The key of the property to get.\n * @param {*} srcValue The value to match.\n * @returns {Function} Returns the new spec function.\n */\n function matchesStrictComparable(key, srcValue) {\n return function(object) {\n if (object == null) {\n return false;\n }\n return object[key] === srcValue &&\n (srcValue !== undefined || (key in Object(object)));\n };\n }\n\n /**\n * A specialized version of `_.memoize` which clears the memoized function's\n * cache when it exceeds `MAX_MEMOIZE_SIZE`.\n *\n * @private\n * @param {Function} func The function to have its output memoized.\n * @returns {Function} Returns the new memoized function.\n */\n function memoizeCapped(func) {\n var result = memoize(func, function(key) {\n if (cache.size === MAX_MEMOIZE_SIZE) {\n cache.clear();\n }\n return key;\n });\n\n var cache = result.cache;\n return result;\n }\n\n /**\n * Merges the function metadata of `source` into `data`.\n *\n * Merging metadata reduces the number of wrappers used to invoke a function.\n * This is possible because methods like `_.bind`, `_.curry`, and `_.partial`\n * may be applied regardless of execution order. Methods like `_.ary` and\n * `_.rearg` modify function arguments, making the order in which they are\n * executed important, preventing the merging of metadata. However, we make\n * an exception for a safe combined case where curried functions have `_.ary`\n * and or `_.rearg` applied.\n *\n * @private\n * @param {Array} data The destination metadata.\n * @param {Array} source The source metadata.\n * @returns {Array} Returns `data`.\n */\n function mergeData(data, source) {\n var bitmask = data[1],\n srcBitmask = source[1],\n newBitmask = bitmask | srcBitmask,\n isCommon = newBitmask < (WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG | WRAP_ARY_FLAG);\n\n var isCombo =\n ((srcBitmask == WRAP_ARY_FLAG) && (bitmask == WRAP_CURRY_FLAG)) ||\n ((srcBitmask == WRAP_ARY_FLAG) && (bitmask == WRAP_REARG_FLAG) && (data[7].length <= source[8])) ||\n ((srcBitmask == (WRAP_ARY_FLAG | WRAP_REARG_FLAG)) && (source[7].length <= source[8]) && (bitmask == WRAP_CURRY_FLAG));\n\n // Exit early if metadata can't be merged.\n if (!(isCommon || isCombo)) {\n return data;\n }\n // Use source `thisArg` if available.\n if (srcBitmask & WRAP_BIND_FLAG) {\n data[2] = source[2];\n // Set when currying a bound function.\n newBitmask |= bitmask & WRAP_BIND_FLAG ? 0 : WRAP_CURRY_BOUND_FLAG;\n }\n // Compose partial arguments.\n var value = source[3];\n if (value) {\n var partials = data[3];\n data[3] = partials ? composeArgs(partials, value, source[4]) : value;\n data[4] = partials ? replaceHolders(data[3], PLACEHOLDER) : source[4];\n }\n // Compose partial right arguments.\n value = source[5];\n if (value) {\n partials = data[5];\n data[5] = partials ? composeArgsRight(partials, value, source[6]) : value;\n data[6] = partials ? replaceHolders(data[5], PLACEHOLDER) : source[6];\n }\n // Use source `argPos` if available.\n value = source[7];\n if (value) {\n data[7] = value;\n }\n // Use source `ary` if it's smaller.\n if (srcBitmask & WRAP_ARY_FLAG) {\n data[8] = data[8] == null ? source[8] : nativeMin(data[8], source[8]);\n }\n // Use source `arity` if one is not provided.\n if (data[9] == null) {\n data[9] = source[9];\n }\n // Use source `func` and merge bitmasks.\n data[0] = source[0];\n data[1] = newBitmask;\n\n return data;\n }\n\n /**\n * This function is like\n * [`Object.keys`](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * except that it includes inherited enumerable properties.\n *\n * @private\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n */\n function nativeKeysIn(object) {\n var result = [];\n if (object != null) {\n for (var key in Object(object)) {\n result.push(key);\n }\n }\n return result;\n }\n\n /**\n * Converts `value` to a string using `Object.prototype.toString`.\n *\n * @private\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n */\n function objectToString(value) {\n return nativeObjectToString.call(value);\n }\n\n /**\n * A specialized version of `baseRest` which transforms the rest array.\n *\n * @private\n * @param {Function} func The function to apply a rest parameter to.\n * @param {number} [start=func.length-1] The start position of the rest parameter.\n * @param {Function} transform The rest array transform.\n * @returns {Function} Returns the new function.\n */\n function overRest(func, start, transform) {\n start = nativeMax(start === undefined ? (func.length - 1) : start, 0);\n return function() {\n var args = arguments,\n index = -1,\n length = nativeMax(args.length - start, 0),\n array = Array(length);\n\n while (++index < length) {\n array[index] = args[start + index];\n }\n index = -1;\n var otherArgs = Array(start + 1);\n while (++index < start) {\n otherArgs[index] = args[index];\n }\n otherArgs[start] = transform(array);\n return apply(func, this, otherArgs);\n };\n }\n\n /**\n * Gets the parent value at `path` of `object`.\n *\n * @private\n * @param {Object} object The object to query.\n * @param {Array} path The path to get the parent value of.\n * @returns {*} Returns the parent value.\n */\n function parent(object, path) {\n return path.length < 2 ? object : baseGet(object, baseSlice(path, 0, -1));\n }\n\n /**\n * Reorder `array` according to the specified indexes where the element at\n * the first index is assigned as the first element, the element at\n * the second index is assigned as the second element, and so on.\n *\n * @private\n * @param {Array} array The array to reorder.\n * @param {Array} indexes The arranged array indexes.\n * @returns {Array} Returns `array`.\n */\n function reorder(array, indexes) {\n var arrLength = array.length,\n length = nativeMin(indexes.length, arrLength),\n oldArray = copyArray(array);\n\n while (length--) {\n var index = indexes[length];\n array[length] = isIndex(index, arrLength) ? oldArray[index] : undefined;\n }\n return array;\n }\n\n /**\n * Gets the value at `key`, unless `key` is \"__proto__\" or \"constructor\".\n *\n * @private\n * @param {Object} object The object to query.\n * @param {string} key The key of the property to get.\n * @returns {*} Returns the property value.\n */\n function safeGet(object, key) {\n if (key === 'constructor' && typeof object[key] === 'function') {\n return;\n }\n\n if (key == '__proto__') {\n return;\n }\n\n return object[key];\n }\n\n /**\n * Sets metadata for `func`.\n *\n * **Note:** If this function becomes hot, i.e. is invoked a lot in a short\n * period of time, it will trip its breaker and transition to an identity\n * function to avoid garbage collection pauses in V8. See\n * [V8 issue 2070](https://bugs.chromium.org/p/v8/issues/detail?id=2070)\n * for more details.\n *\n * @private\n * @param {Function} func The function to associate metadata with.\n * @param {*} data The metadata.\n * @returns {Function} Returns `func`.\n */\n var setData = shortOut(baseSetData);\n\n /**\n * A simple wrapper around the global [`setTimeout`](https://mdn.io/setTimeout).\n *\n * @private\n * @param {Function} func The function to delay.\n * @param {number} wait The number of milliseconds to delay invocation.\n * @returns {number|Object} Returns the timer id or timeout object.\n */\n var setTimeout = ctxSetTimeout || function(func, wait) {\n return root.setTimeout(func, wait);\n };\n\n /**\n * Sets the `toString` method of `func` to return `string`.\n *\n * @private\n * @param {Function} func The function to modify.\n * @param {Function} string The `toString` result.\n * @returns {Function} Returns `func`.\n */\n var setToString = shortOut(baseSetToString);\n\n /**\n * Sets the `toString` method of `wrapper` to mimic the source of `reference`\n * with wrapper details in a comment at the top of the source body.\n *\n * @private\n * @param {Function} wrapper The function to modify.\n * @param {Function} reference The reference function.\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\n * @returns {Function} Returns `wrapper`.\n */\n function setWrapToString(wrapper, reference, bitmask) {\n var source = (reference + '');\n return setToString(wrapper, insertWrapDetails(source, updateWrapDetails(getWrapDetails(source), bitmask)));\n }\n\n /**\n * Creates a function that'll short out and invoke `identity` instead\n * of `func` when it's called `HOT_COUNT` or more times in `HOT_SPAN`\n * milliseconds.\n *\n * @private\n * @param {Function} func The function to restrict.\n * @returns {Function} Returns the new shortable function.\n */\n function shortOut(func) {\n var count = 0,\n lastCalled = 0;\n\n return function() {\n var stamp = nativeNow(),\n remaining = HOT_SPAN - (stamp - lastCalled);\n\n lastCalled = stamp;\n if (remaining > 0) {\n if (++count >= HOT_COUNT) {\n return arguments[0];\n }\n } else {\n count = 0;\n }\n return func.apply(undefined, arguments);\n };\n }\n\n /**\n * A specialized version of `_.shuffle` which mutates and sets the size of `array`.\n *\n * @private\n * @param {Array} array The array to shuffle.\n * @param {number} [size=array.length] The size of `array`.\n * @returns {Array} Returns `array`.\n */\n function shuffleSelf(array, size) {\n var index = -1,\n length = array.length,\n lastIndex = length - 1;\n\n size = size === undefined ? length : size;\n while (++index < size) {\n var rand = baseRandom(index, lastIndex),\n value = array[rand];\n\n array[rand] = array[index];\n array[index] = value;\n }\n array.length = size;\n return array;\n }\n\n /**\n * Converts `string` to a property path array.\n *\n * @private\n * @param {string} string The string to convert.\n * @returns {Array} Returns the property path array.\n */\n var stringToPath = memoizeCapped(function(string) {\n var result = [];\n if (string.charCodeAt(0) === 46 /* . */) {\n result.push('');\n }\n string.replace(rePropName, function(match, number, quote, subString) {\n result.push(quote ? subString.replace(reEscapeChar, '$1') : (number || match));\n });\n return result;\n });\n\n /**\n * Converts `value` to a string key if it's not a string or symbol.\n *\n * @private\n * @param {*} value The value to inspect.\n * @returns {string|symbol} Returns the key.\n */\n function toKey(value) {\n if (typeof value == 'string' || isSymbol(value)) {\n return value;\n }\n var result = (value + '');\n return (result == '0' && (1 / value) == -INFINITY) ? '-0' : result;\n }\n\n /**\n * Converts `func` to its source code.\n *\n * @private\n * @param {Function} func The function to convert.\n * @returns {string} Returns the source code.\n */\n function toSource(func) {\n if (func != null) {\n try {\n return funcToString.call(func);\n } catch (e) {}\n try {\n return (func + '');\n } catch (e) {}\n }\n return '';\n }\n\n /**\n * Updates wrapper `details` based on `bitmask` flags.\n *\n * @private\n * @returns {Array} details The details to modify.\n * @param {number} bitmask The bitmask flags. See `createWrap` for more details.\n * @returns {Array} Returns `details`.\n */\n function updateWrapDetails(details, bitmask) {\n arrayEach(wrapFlags, function(pair) {\n var value = '_.' + pair[0];\n if ((bitmask & pair[1]) && !arrayIncludes(details, value)) {\n details.push(value);\n }\n });\n return details.sort();\n }\n\n /**\n * Creates a clone of `wrapper`.\n *\n * @private\n * @param {Object} wrapper The wrapper to clone.\n * @returns {Object} Returns the cloned wrapper.\n */\n function wrapperClone(wrapper) {\n if (wrapper instanceof LazyWrapper) {\n return wrapper.clone();\n }\n var result = new LodashWrapper(wrapper.__wrapped__, wrapper.__chain__);\n result.__actions__ = copyArray(wrapper.__actions__);\n result.__index__ = wrapper.__index__;\n result.__values__ = wrapper.__values__;\n return result;\n }\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates an array of elements split into groups the length of `size`.\n * If `array` can't be split evenly, the final chunk will be the remaining\n * elements.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Array\n * @param {Array} array The array to process.\n * @param {number} [size=1] The length of each chunk\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the new array of chunks.\n * @example\n *\n * _.chunk(['a', 'b', 'c', 'd'], 2);\n * // => [['a', 'b'], ['c', 'd']]\n *\n * _.chunk(['a', 'b', 'c', 'd'], 3);\n * // => [['a', 'b', 'c'], ['d']]\n */\n function chunk(array, size, guard) {\n if ((guard ? isIterateeCall(array, size, guard) : size === undefined)) {\n size = 1;\n } else {\n size = nativeMax(toInteger(size), 0);\n }\n var length = array == null ? 0 : array.length;\n if (!length || size < 1) {\n return [];\n }\n var index = 0,\n resIndex = 0,\n result = Array(nativeCeil(length / size));\n\n while (index < length) {\n result[resIndex++] = baseSlice(array, index, (index += size));\n }\n return result;\n }\n\n /**\n * Creates an array with all falsey values removed. The values `false`, `null`,\n * `0`, `\"\"`, `undefined`, and `NaN` are falsey.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The array to compact.\n * @returns {Array} Returns the new array of filtered values.\n * @example\n *\n * _.compact([0, 1, false, 2, '', 3]);\n * // => [1, 2, 3]\n */\n function compact(array) {\n var index = -1,\n length = array == null ? 0 : array.length,\n resIndex = 0,\n result = [];\n\n while (++index < length) {\n var value = array[index];\n if (value) {\n result[resIndex++] = value;\n }\n }\n return result;\n }\n\n /**\n * Creates a new array concatenating `array` with any additional arrays\n * and/or values.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to concatenate.\n * @param {...*} [values] The values to concatenate.\n * @returns {Array} Returns the new concatenated array.\n * @example\n *\n * var array = [1];\n * var other = _.concat(array, 2, [3], [[4]]);\n *\n * console.log(other);\n * // => [1, 2, 3, [4]]\n *\n * console.log(array);\n * // => [1]\n */\n function concat() {\n var length = arguments.length;\n if (!length) {\n return [];\n }\n var args = Array(length - 1),\n array = arguments[0],\n index = length;\n\n while (index--) {\n args[index - 1] = arguments[index];\n }\n return arrayPush(isArray(array) ? copyArray(array) : [array], baseFlatten(args, 1));\n }\n\n /**\n * Creates an array of `array` values not included in the other given arrays\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons. The order and references of result values are\n * determined by the first array.\n *\n * **Note:** Unlike `_.pullAll`, this method returns a new array.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {...Array} [values] The values to exclude.\n * @returns {Array} Returns the new array of filtered values.\n * @see _.without, _.xor\n * @example\n *\n * _.difference([2, 1], [2, 3]);\n * // => [1]\n */\n var difference = baseRest(function(array, values) {\n return isArrayLikeObject(array)\n ? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true))\n : [];\n });\n\n /**\n * This method is like `_.difference` except that it accepts `iteratee` which\n * is invoked for each element of `array` and `values` to generate the criterion\n * by which they're compared. The order and references of result values are\n * determined by the first array. The iteratee is invoked with one argument:\n * (value).\n *\n * **Note:** Unlike `_.pullAllBy`, this method returns a new array.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {...Array} [values] The values to exclude.\n * @param {Function} [iteratee=_.identity] The iteratee invoked per element.\n * @returns {Array} Returns the new array of filtered values.\n * @example\n *\n * _.differenceBy([2.1, 1.2], [2.3, 3.4], Math.floor);\n * // => [1.2]\n *\n * // The `_.property` iteratee shorthand.\n * _.differenceBy([{ 'x': 2 }, { 'x': 1 }], [{ 'x': 1 }], 'x');\n * // => [{ 'x': 2 }]\n */\n var differenceBy = baseRest(function(array, values) {\n var iteratee = last(values);\n if (isArrayLikeObject(iteratee)) {\n iteratee = undefined;\n }\n return isArrayLikeObject(array)\n ? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true), getIteratee(iteratee, 2))\n : [];\n });\n\n /**\n * This method is like `_.difference` except that it accepts `comparator`\n * which is invoked to compare elements of `array` to `values`. The order and\n * references of result values are determined by the first array. The comparator\n * is invoked with two arguments: (arrVal, othVal).\n *\n * **Note:** Unlike `_.pullAllWith`, this method returns a new array.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {...Array} [values] The values to exclude.\n * @param {Function} [comparator] The comparator invoked per element.\n * @returns {Array} Returns the new array of filtered values.\n * @example\n *\n * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }];\n *\n * _.differenceWith(objects, [{ 'x': 1, 'y': 2 }], _.isEqual);\n * // => [{ 'x': 2, 'y': 1 }]\n */\n var differenceWith = baseRest(function(array, values) {\n var comparator = last(values);\n if (isArrayLikeObject(comparator)) {\n comparator = undefined;\n }\n return isArrayLikeObject(array)\n ? baseDifference(array, baseFlatten(values, 1, isArrayLikeObject, true), undefined, comparator)\n : [];\n });\n\n /**\n * Creates a slice of `array` with `n` elements dropped from the beginning.\n *\n * @static\n * @memberOf _\n * @since 0.5.0\n * @category Array\n * @param {Array} array The array to query.\n * @param {number} [n=1] The number of elements to drop.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the slice of `array`.\n * @example\n *\n * _.drop([1, 2, 3]);\n * // => [2, 3]\n *\n * _.drop([1, 2, 3], 2);\n * // => [3]\n *\n * _.drop([1, 2, 3], 5);\n * // => []\n *\n * _.drop([1, 2, 3], 0);\n * // => [1, 2, 3]\n */\n function drop(array, n, guard) {\n var length = array == null ? 0 : array.length;\n if (!length) {\n return [];\n }\n n = (guard || n === undefined) ? 1 : toInteger(n);\n return baseSlice(array, n < 0 ? 0 : n, length);\n }\n\n /**\n * Creates a slice of `array` with `n` elements dropped from the end.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Array\n * @param {Array} array The array to query.\n * @param {number} [n=1] The number of elements to drop.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the slice of `array`.\n * @example\n *\n * _.dropRight([1, 2, 3]);\n * // => [1, 2]\n *\n * _.dropRight([1, 2, 3], 2);\n * // => [1]\n *\n * _.dropRight([1, 2, 3], 5);\n * // => []\n *\n * _.dropRight([1, 2, 3], 0);\n * // => [1, 2, 3]\n */\n function dropRight(array, n, guard) {\n var length = array == null ? 0 : array.length;\n if (!length) {\n return [];\n }\n n = (guard || n === undefined) ? 1 : toInteger(n);\n n = length - n;\n return baseSlice(array, 0, n < 0 ? 0 : n);\n }\n\n /**\n * Creates a slice of `array` excluding elements dropped from the end.\n * Elements are dropped until `predicate` returns falsey. The predicate is\n * invoked with three arguments: (value, index, array).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Array\n * @param {Array} array The array to query.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the slice of `array`.\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'active': true },\n * { 'user': 'fred', 'active': false },\n * { 'user': 'pebbles', 'active': false }\n * ];\n *\n * _.dropRightWhile(users, function(o) { return !o.active; });\n * // => objects for ['barney']\n *\n * // The `_.matches` iteratee shorthand.\n * _.dropRightWhile(users, { 'user': 'pebbles', 'active': false });\n * // => objects for ['barney', 'fred']\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.dropRightWhile(users, ['active', false]);\n * // => objects for ['barney']\n *\n * // The `_.property` iteratee shorthand.\n * _.dropRightWhile(users, 'active');\n * // => objects for ['barney', 'fred', 'pebbles']\n */\n function dropRightWhile(array, predicate) {\n return (array && array.length)\n ? baseWhile(array, getIteratee(predicate, 3), true, true)\n : [];\n }\n\n /**\n * Creates a slice of `array` excluding elements dropped from the beginning.\n * Elements are dropped until `predicate` returns falsey. The predicate is\n * invoked with three arguments: (value, index, array).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Array\n * @param {Array} array The array to query.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the slice of `array`.\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'active': false },\n * { 'user': 'fred', 'active': false },\n * { 'user': 'pebbles', 'active': true }\n * ];\n *\n * _.dropWhile(users, function(o) { return !o.active; });\n * // => objects for ['pebbles']\n *\n * // The `_.matches` iteratee shorthand.\n * _.dropWhile(users, { 'user': 'barney', 'active': false });\n * // => objects for ['fred', 'pebbles']\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.dropWhile(users, ['active', false]);\n * // => objects for ['pebbles']\n *\n * // The `_.property` iteratee shorthand.\n * _.dropWhile(users, 'active');\n * // => objects for ['barney', 'fred', 'pebbles']\n */\n function dropWhile(array, predicate) {\n return (array && array.length)\n ? baseWhile(array, getIteratee(predicate, 3), true)\n : [];\n }\n\n /**\n * Fills elements of `array` with `value` from `start` up to, but not\n * including, `end`.\n *\n * **Note:** This method mutates `array`.\n *\n * @static\n * @memberOf _\n * @since 3.2.0\n * @category Array\n * @param {Array} array The array to fill.\n * @param {*} value The value to fill `array` with.\n * @param {number} [start=0] The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns `array`.\n * @example\n *\n * var array = [1, 2, 3];\n *\n * _.fill(array, 'a');\n * console.log(array);\n * // => ['a', 'a', 'a']\n *\n * _.fill(Array(3), 2);\n * // => [2, 2, 2]\n *\n * _.fill([4, 6, 8, 10], '*', 1, 3);\n * // => [4, '*', '*', 10]\n */\n function fill(array, value, start, end) {\n var length = array == null ? 0 : array.length;\n if (!length) {\n return [];\n }\n if (start && typeof start != 'number' && isIterateeCall(array, value, start)) {\n start = 0;\n end = length;\n }\n return baseFill(array, value, start, end);\n }\n\n /**\n * This method is like `_.find` except that it returns the index of the first\n * element `predicate` returns truthy for instead of the element itself.\n *\n * @static\n * @memberOf _\n * @since 1.1.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @param {number} [fromIndex=0] The index to search from.\n * @returns {number} Returns the index of the found element, else `-1`.\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'active': false },\n * { 'user': 'fred', 'active': false },\n * { 'user': 'pebbles', 'active': true }\n * ];\n *\n * _.findIndex(users, function(o) { return o.user == 'barney'; });\n * // => 0\n *\n * // The `_.matches` iteratee shorthand.\n * _.findIndex(users, { 'user': 'fred', 'active': false });\n * // => 1\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.findIndex(users, ['active', false]);\n * // => 0\n *\n * // The `_.property` iteratee shorthand.\n * _.findIndex(users, 'active');\n * // => 2\n */\n function findIndex(array, predicate, fromIndex) {\n var length = array == null ? 0 : array.length;\n if (!length) {\n return -1;\n }\n var index = fromIndex == null ? 0 : toInteger(fromIndex);\n if (index < 0) {\n index = nativeMax(length + index, 0);\n }\n return baseFindIndex(array, getIteratee(predicate, 3), index);\n }\n\n /**\n * This method is like `_.findIndex` except that it iterates over elements\n * of `collection` from right to left.\n *\n * @static\n * @memberOf _\n * @since 2.0.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @param {number} [fromIndex=array.length-1] The index to search from.\n * @returns {number} Returns the index of the found element, else `-1`.\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'active': true },\n * { 'user': 'fred', 'active': false },\n * { 'user': 'pebbles', 'active': false }\n * ];\n *\n * _.findLastIndex(users, function(o) { return o.user == 'pebbles'; });\n * // => 2\n *\n * // The `_.matches` iteratee shorthand.\n * _.findLastIndex(users, { 'user': 'barney', 'active': true });\n * // => 0\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.findLastIndex(users, ['active', false]);\n * // => 2\n *\n * // The `_.property` iteratee shorthand.\n * _.findLastIndex(users, 'active');\n * // => 0\n */\n function findLastIndex(array, predicate, fromIndex) {\n var length = array == null ? 0 : array.length;\n if (!length) {\n return -1;\n }\n var index = length - 1;\n if (fromIndex !== undefined) {\n index = toInteger(fromIndex);\n index = fromIndex < 0\n ? nativeMax(length + index, 0)\n : nativeMin(index, length - 1);\n }\n return baseFindIndex(array, getIteratee(predicate, 3), index, true);\n }\n\n /**\n * Flattens `array` a single level deep.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The array to flatten.\n * @returns {Array} Returns the new flattened array.\n * @example\n *\n * _.flatten([1, [2, [3, [4]], 5]]);\n * // => [1, 2, [3, [4]], 5]\n */\n function flatten(array) {\n var length = array == null ? 0 : array.length;\n return length ? baseFlatten(array, 1) : [];\n }\n\n /**\n * Recursively flattens `array`.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Array\n * @param {Array} array The array to flatten.\n * @returns {Array} Returns the new flattened array.\n * @example\n *\n * _.flattenDeep([1, [2, [3, [4]], 5]]);\n * // => [1, 2, 3, 4, 5]\n */\n function flattenDeep(array) {\n var length = array == null ? 0 : array.length;\n return length ? baseFlatten(array, INFINITY) : [];\n }\n\n /**\n * Recursively flatten `array` up to `depth` times.\n *\n * @static\n * @memberOf _\n * @since 4.4.0\n * @category Array\n * @param {Array} array The array to flatten.\n * @param {number} [depth=1] The maximum recursion depth.\n * @returns {Array} Returns the new flattened array.\n * @example\n *\n * var array = [1, [2, [3, [4]], 5]];\n *\n * _.flattenDepth(array, 1);\n * // => [1, 2, [3, [4]], 5]\n *\n * _.flattenDepth(array, 2);\n * // => [1, 2, 3, [4], 5]\n */\n function flattenDepth(array, depth) {\n var length = array == null ? 0 : array.length;\n if (!length) {\n return [];\n }\n depth = depth === undefined ? 1 : toInteger(depth);\n return baseFlatten(array, depth);\n }\n\n /**\n * The inverse of `_.toPairs`; this method returns an object composed\n * from key-value `pairs`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} pairs The key-value pairs.\n * @returns {Object} Returns the new object.\n * @example\n *\n * _.fromPairs([['a', 1], ['b', 2]]);\n * // => { 'a': 1, 'b': 2 }\n */\n function fromPairs(pairs) {\n var index = -1,\n length = pairs == null ? 0 : pairs.length,\n result = {};\n\n while (++index < length) {\n var pair = pairs[index];\n result[pair[0]] = pair[1];\n }\n return result;\n }\n\n /**\n * Gets the first element of `array`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @alias first\n * @category Array\n * @param {Array} array The array to query.\n * @returns {*} Returns the first element of `array`.\n * @example\n *\n * _.head([1, 2, 3]);\n * // => 1\n *\n * _.head([]);\n * // => undefined\n */\n function head(array) {\n return (array && array.length) ? array[0] : undefined;\n }\n\n /**\n * Gets the index at which the first occurrence of `value` is found in `array`\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons. If `fromIndex` is negative, it's used as the\n * offset from the end of `array`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {*} value The value to search for.\n * @param {number} [fromIndex=0] The index to search from.\n * @returns {number} Returns the index of the matched value, else `-1`.\n * @example\n *\n * _.indexOf([1, 2, 1, 2], 2);\n * // => 1\n *\n * // Search from the `fromIndex`.\n * _.indexOf([1, 2, 1, 2], 2, 2);\n * // => 3\n */\n function indexOf(array, value, fromIndex) {\n var length = array == null ? 0 : array.length;\n if (!length) {\n return -1;\n }\n var index = fromIndex == null ? 0 : toInteger(fromIndex);\n if (index < 0) {\n index = nativeMax(length + index, 0);\n }\n return baseIndexOf(array, value, index);\n }\n\n /**\n * Gets all but the last element of `array`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The array to query.\n * @returns {Array} Returns the slice of `array`.\n * @example\n *\n * _.initial([1, 2, 3]);\n * // => [1, 2]\n */\n function initial(array) {\n var length = array == null ? 0 : array.length;\n return length ? baseSlice(array, 0, -1) : [];\n }\n\n /**\n * Creates an array of unique values that are included in all given arrays\n * using [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons. The order and references of result values are\n * determined by the first array.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {...Array} [arrays] The arrays to inspect.\n * @returns {Array} Returns the new array of intersecting values.\n * @example\n *\n * _.intersection([2, 1], [2, 3]);\n * // => [2]\n */\n var intersection = baseRest(function(arrays) {\n var mapped = arrayMap(arrays, castArrayLikeObject);\n return (mapped.length && mapped[0] === arrays[0])\n ? baseIntersection(mapped)\n : [];\n });\n\n /**\n * This method is like `_.intersection` except that it accepts `iteratee`\n * which is invoked for each element of each `arrays` to generate the criterion\n * by which they're compared. The order and references of result values are\n * determined by the first array. The iteratee is invoked with one argument:\n * (value).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {...Array} [arrays] The arrays to inspect.\n * @param {Function} [iteratee=_.identity] The iteratee invoked per element.\n * @returns {Array} Returns the new array of intersecting values.\n * @example\n *\n * _.intersectionBy([2.1, 1.2], [2.3, 3.4], Math.floor);\n * // => [2.1]\n *\n * // The `_.property` iteratee shorthand.\n * _.intersectionBy([{ 'x': 1 }], [{ 'x': 2 }, { 'x': 1 }], 'x');\n * // => [{ 'x': 1 }]\n */\n var intersectionBy = baseRest(function(arrays) {\n var iteratee = last(arrays),\n mapped = arrayMap(arrays, castArrayLikeObject);\n\n if (iteratee === last(mapped)) {\n iteratee = undefined;\n } else {\n mapped.pop();\n }\n return (mapped.length && mapped[0] === arrays[0])\n ? baseIntersection(mapped, getIteratee(iteratee, 2))\n : [];\n });\n\n /**\n * This method is like `_.intersection` except that it accepts `comparator`\n * which is invoked to compare elements of `arrays`. The order and references\n * of result values are determined by the first array. The comparator is\n * invoked with two arguments: (arrVal, othVal).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {...Array} [arrays] The arrays to inspect.\n * @param {Function} [comparator] The comparator invoked per element.\n * @returns {Array} Returns the new array of intersecting values.\n * @example\n *\n * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }];\n * var others = [{ 'x': 1, 'y': 1 }, { 'x': 1, 'y': 2 }];\n *\n * _.intersectionWith(objects, others, _.isEqual);\n * // => [{ 'x': 1, 'y': 2 }]\n */\n var intersectionWith = baseRest(function(arrays) {\n var comparator = last(arrays),\n mapped = arrayMap(arrays, castArrayLikeObject);\n\n comparator = typeof comparator == 'function' ? comparator : undefined;\n if (comparator) {\n mapped.pop();\n }\n return (mapped.length && mapped[0] === arrays[0])\n ? baseIntersection(mapped, undefined, comparator)\n : [];\n });\n\n /**\n * Converts all elements in `array` into a string separated by `separator`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to convert.\n * @param {string} [separator=','] The element separator.\n * @returns {string} Returns the joined string.\n * @example\n *\n * _.join(['a', 'b', 'c'], '~');\n * // => 'a~b~c'\n */\n function join(array, separator) {\n return array == null ? '' : nativeJoin.call(array, separator);\n }\n\n /**\n * Gets the last element of `array`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The array to query.\n * @returns {*} Returns the last element of `array`.\n * @example\n *\n * _.last([1, 2, 3]);\n * // => 3\n */\n function last(array) {\n var length = array == null ? 0 : array.length;\n return length ? array[length - 1] : undefined;\n }\n\n /**\n * This method is like `_.indexOf` except that it iterates over elements of\n * `array` from right to left.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {*} value The value to search for.\n * @param {number} [fromIndex=array.length-1] The index to search from.\n * @returns {number} Returns the index of the matched value, else `-1`.\n * @example\n *\n * _.lastIndexOf([1, 2, 1, 2], 2);\n * // => 3\n *\n * // Search from the `fromIndex`.\n * _.lastIndexOf([1, 2, 1, 2], 2, 2);\n * // => 1\n */\n function lastIndexOf(array, value, fromIndex) {\n var length = array == null ? 0 : array.length;\n if (!length) {\n return -1;\n }\n var index = length;\n if (fromIndex !== undefined) {\n index = toInteger(fromIndex);\n index = index < 0 ? nativeMax(length + index, 0) : nativeMin(index, length - 1);\n }\n return value === value\n ? strictLastIndexOf(array, value, index)\n : baseFindIndex(array, baseIsNaN, index, true);\n }\n\n /**\n * Gets the element at index `n` of `array`. If `n` is negative, the nth\n * element from the end is returned.\n *\n * @static\n * @memberOf _\n * @since 4.11.0\n * @category Array\n * @param {Array} array The array to query.\n * @param {number} [n=0] The index of the element to return.\n * @returns {*} Returns the nth element of `array`.\n * @example\n *\n * var array = ['a', 'b', 'c', 'd'];\n *\n * _.nth(array, 1);\n * // => 'b'\n *\n * _.nth(array, -2);\n * // => 'c';\n */\n function nth(array, n) {\n return (array && array.length) ? baseNth(array, toInteger(n)) : undefined;\n }\n\n /**\n * Removes all given values from `array` using\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons.\n *\n * **Note:** Unlike `_.without`, this method mutates `array`. Use `_.remove`\n * to remove elements from an array by predicate.\n *\n * @static\n * @memberOf _\n * @since 2.0.0\n * @category Array\n * @param {Array} array The array to modify.\n * @param {...*} [values] The values to remove.\n * @returns {Array} Returns `array`.\n * @example\n *\n * var array = ['a', 'b', 'c', 'a', 'b', 'c'];\n *\n * _.pull(array, 'a', 'c');\n * console.log(array);\n * // => ['b', 'b']\n */\n var pull = baseRest(pullAll);\n\n /**\n * This method is like `_.pull` except that it accepts an array of values to remove.\n *\n * **Note:** Unlike `_.difference`, this method mutates `array`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to modify.\n * @param {Array} values The values to remove.\n * @returns {Array} Returns `array`.\n * @example\n *\n * var array = ['a', 'b', 'c', 'a', 'b', 'c'];\n *\n * _.pullAll(array, ['a', 'c']);\n * console.log(array);\n * // => ['b', 'b']\n */\n function pullAll(array, values) {\n return (array && array.length && values && values.length)\n ? basePullAll(array, values)\n : array;\n }\n\n /**\n * This method is like `_.pullAll` except that it accepts `iteratee` which is\n * invoked for each element of `array` and `values` to generate the criterion\n * by which they're compared. The iteratee is invoked with one argument: (value).\n *\n * **Note:** Unlike `_.differenceBy`, this method mutates `array`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to modify.\n * @param {Array} values The values to remove.\n * @param {Function} [iteratee=_.identity] The iteratee invoked per element.\n * @returns {Array} Returns `array`.\n * @example\n *\n * var array = [{ 'x': 1 }, { 'x': 2 }, { 'x': 3 }, { 'x': 1 }];\n *\n * _.pullAllBy(array, [{ 'x': 1 }, { 'x': 3 }], 'x');\n * console.log(array);\n * // => [{ 'x': 2 }]\n */\n function pullAllBy(array, values, iteratee) {\n return (array && array.length && values && values.length)\n ? basePullAll(array, values, getIteratee(iteratee, 2))\n : array;\n }\n\n /**\n * This method is like `_.pullAll` except that it accepts `comparator` which\n * is invoked to compare elements of `array` to `values`. The comparator is\n * invoked with two arguments: (arrVal, othVal).\n *\n * **Note:** Unlike `_.differenceWith`, this method mutates `array`.\n *\n * @static\n * @memberOf _\n * @since 4.6.0\n * @category Array\n * @param {Array} array The array to modify.\n * @param {Array} values The values to remove.\n * @param {Function} [comparator] The comparator invoked per element.\n * @returns {Array} Returns `array`.\n * @example\n *\n * var array = [{ 'x': 1, 'y': 2 }, { 'x': 3, 'y': 4 }, { 'x': 5, 'y': 6 }];\n *\n * _.pullAllWith(array, [{ 'x': 3, 'y': 4 }], _.isEqual);\n * console.log(array);\n * // => [{ 'x': 1, 'y': 2 }, { 'x': 5, 'y': 6 }]\n */\n function pullAllWith(array, values, comparator) {\n return (array && array.length && values && values.length)\n ? basePullAll(array, values, undefined, comparator)\n : array;\n }\n\n /**\n * Removes elements from `array` corresponding to `indexes` and returns an\n * array of removed elements.\n *\n * **Note:** Unlike `_.at`, this method mutates `array`.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Array\n * @param {Array} array The array to modify.\n * @param {...(number|number[])} [indexes] The indexes of elements to remove.\n * @returns {Array} Returns the new array of removed elements.\n * @example\n *\n * var array = ['a', 'b', 'c', 'd'];\n * var pulled = _.pullAt(array, [1, 3]);\n *\n * console.log(array);\n * // => ['a', 'c']\n *\n * console.log(pulled);\n * // => ['b', 'd']\n */\n var pullAt = flatRest(function(array, indexes) {\n var length = array == null ? 0 : array.length,\n result = baseAt(array, indexes);\n\n basePullAt(array, arrayMap(indexes, function(index) {\n return isIndex(index, length) ? +index : index;\n }).sort(compareAscending));\n\n return result;\n });\n\n /**\n * Removes all elements from `array` that `predicate` returns truthy for\n * and returns an array of the removed elements. The predicate is invoked\n * with three arguments: (value, index, array).\n *\n * **Note:** Unlike `_.filter`, this method mutates `array`. Use `_.pull`\n * to pull elements from an array by value.\n *\n * @static\n * @memberOf _\n * @since 2.0.0\n * @category Array\n * @param {Array} array The array to modify.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the new array of removed elements.\n * @example\n *\n * var array = [1, 2, 3, 4];\n * var evens = _.remove(array, function(n) {\n * return n % 2 == 0;\n * });\n *\n * console.log(array);\n * // => [1, 3]\n *\n * console.log(evens);\n * // => [2, 4]\n */\n function remove(array, predicate) {\n var result = [];\n if (!(array && array.length)) {\n return result;\n }\n var index = -1,\n indexes = [],\n length = array.length;\n\n predicate = getIteratee(predicate, 3);\n while (++index < length) {\n var value = array[index];\n if (predicate(value, index, array)) {\n result.push(value);\n indexes.push(index);\n }\n }\n basePullAt(array, indexes);\n return result;\n }\n\n /**\n * Reverses `array` so that the first element becomes the last, the second\n * element becomes the second to last, and so on.\n *\n * **Note:** This method mutates `array` and is based on\n * [`Array#reverse`](https://mdn.io/Array/reverse).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to modify.\n * @returns {Array} Returns `array`.\n * @example\n *\n * var array = [1, 2, 3];\n *\n * _.reverse(array);\n * // => [3, 2, 1]\n *\n * console.log(array);\n * // => [3, 2, 1]\n */\n function reverse(array) {\n return array == null ? array : nativeReverse.call(array);\n }\n\n /**\n * Creates a slice of `array` from `start` up to, but not including, `end`.\n *\n * **Note:** This method is used instead of\n * [`Array#slice`](https://mdn.io/Array/slice) to ensure dense arrays are\n * returned.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Array\n * @param {Array} array The array to slice.\n * @param {number} [start=0] The start position.\n * @param {number} [end=array.length] The end position.\n * @returns {Array} Returns the slice of `array`.\n */\n function slice(array, start, end) {\n var length = array == null ? 0 : array.length;\n if (!length) {\n return [];\n }\n if (end && typeof end != 'number' && isIterateeCall(array, start, end)) {\n start = 0;\n end = length;\n }\n else {\n start = start == null ? 0 : toInteger(start);\n end = end === undefined ? length : toInteger(end);\n }\n return baseSlice(array, start, end);\n }\n\n /**\n * Uses a binary search to determine the lowest index at which `value`\n * should be inserted into `array` in order to maintain its sort order.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The sorted array to inspect.\n * @param {*} value The value to evaluate.\n * @returns {number} Returns the index at which `value` should be inserted\n * into `array`.\n * @example\n *\n * _.sortedIndex([30, 50], 40);\n * // => 1\n */\n function sortedIndex(array, value) {\n return baseSortedIndex(array, value);\n }\n\n /**\n * This method is like `_.sortedIndex` except that it accepts `iteratee`\n * which is invoked for `value` and each element of `array` to compute their\n * sort ranking. The iteratee is invoked with one argument: (value).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The sorted array to inspect.\n * @param {*} value The value to evaluate.\n * @param {Function} [iteratee=_.identity] The iteratee invoked per element.\n * @returns {number} Returns the index at which `value` should be inserted\n * into `array`.\n * @example\n *\n * var objects = [{ 'x': 4 }, { 'x': 5 }];\n *\n * _.sortedIndexBy(objects, { 'x': 4 }, function(o) { return o.x; });\n * // => 0\n *\n * // The `_.property` iteratee shorthand.\n * _.sortedIndexBy(objects, { 'x': 4 }, 'x');\n * // => 0\n */\n function sortedIndexBy(array, value, iteratee) {\n return baseSortedIndexBy(array, value, getIteratee(iteratee, 2));\n }\n\n /**\n * This method is like `_.indexOf` except that it performs a binary\n * search on a sorted `array`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {*} value The value to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n * @example\n *\n * _.sortedIndexOf([4, 5, 5, 5, 6], 5);\n * // => 1\n */\n function sortedIndexOf(array, value) {\n var length = array == null ? 0 : array.length;\n if (length) {\n var index = baseSortedIndex(array, value);\n if (index < length && eq(array[index], value)) {\n return index;\n }\n }\n return -1;\n }\n\n /**\n * This method is like `_.sortedIndex` except that it returns the highest\n * index at which `value` should be inserted into `array` in order to\n * maintain its sort order.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Array\n * @param {Array} array The sorted array to inspect.\n * @param {*} value The value to evaluate.\n * @returns {number} Returns the index at which `value` should be inserted\n * into `array`.\n * @example\n *\n * _.sortedLastIndex([4, 5, 5, 5, 6], 5);\n * // => 4\n */\n function sortedLastIndex(array, value) {\n return baseSortedIndex(array, value, true);\n }\n\n /**\n * This method is like `_.sortedLastIndex` except that it accepts `iteratee`\n * which is invoked for `value` and each element of `array` to compute their\n * sort ranking. The iteratee is invoked with one argument: (value).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The sorted array to inspect.\n * @param {*} value The value to evaluate.\n * @param {Function} [iteratee=_.identity] The iteratee invoked per element.\n * @returns {number} Returns the index at which `value` should be inserted\n * into `array`.\n * @example\n *\n * var objects = [{ 'x': 4 }, { 'x': 5 }];\n *\n * _.sortedLastIndexBy(objects, { 'x': 4 }, function(o) { return o.x; });\n * // => 1\n *\n * // The `_.property` iteratee shorthand.\n * _.sortedLastIndexBy(objects, { 'x': 4 }, 'x');\n * // => 1\n */\n function sortedLastIndexBy(array, value, iteratee) {\n return baseSortedIndexBy(array, value, getIteratee(iteratee, 2), true);\n }\n\n /**\n * This method is like `_.lastIndexOf` except that it performs a binary\n * search on a sorted `array`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {*} value The value to search for.\n * @returns {number} Returns the index of the matched value, else `-1`.\n * @example\n *\n * _.sortedLastIndexOf([4, 5, 5, 5, 6], 5);\n * // => 3\n */\n function sortedLastIndexOf(array, value) {\n var length = array == null ? 0 : array.length;\n if (length) {\n var index = baseSortedIndex(array, value, true) - 1;\n if (eq(array[index], value)) {\n return index;\n }\n }\n return -1;\n }\n\n /**\n * This method is like `_.uniq` except that it's designed and optimized\n * for sorted arrays.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @returns {Array} Returns the new duplicate free array.\n * @example\n *\n * _.sortedUniq([1, 1, 2]);\n * // => [1, 2]\n */\n function sortedUniq(array) {\n return (array && array.length)\n ? baseSortedUniq(array)\n : [];\n }\n\n /**\n * This method is like `_.uniqBy` except that it's designed and optimized\n * for sorted arrays.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {Function} [iteratee] The iteratee invoked per element.\n * @returns {Array} Returns the new duplicate free array.\n * @example\n *\n * _.sortedUniqBy([1.1, 1.2, 2.3, 2.4], Math.floor);\n * // => [1.1, 2.3]\n */\n function sortedUniqBy(array, iteratee) {\n return (array && array.length)\n ? baseSortedUniq(array, getIteratee(iteratee, 2))\n : [];\n }\n\n /**\n * Gets all but the first element of `array`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to query.\n * @returns {Array} Returns the slice of `array`.\n * @example\n *\n * _.tail([1, 2, 3]);\n * // => [2, 3]\n */\n function tail(array) {\n var length = array == null ? 0 : array.length;\n return length ? baseSlice(array, 1, length) : [];\n }\n\n /**\n * Creates a slice of `array` with `n` elements taken from the beginning.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The array to query.\n * @param {number} [n=1] The number of elements to take.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the slice of `array`.\n * @example\n *\n * _.take([1, 2, 3]);\n * // => [1]\n *\n * _.take([1, 2, 3], 2);\n * // => [1, 2]\n *\n * _.take([1, 2, 3], 5);\n * // => [1, 2, 3]\n *\n * _.take([1, 2, 3], 0);\n * // => []\n */\n function take(array, n, guard) {\n if (!(array && array.length)) {\n return [];\n }\n n = (guard || n === undefined) ? 1 : toInteger(n);\n return baseSlice(array, 0, n < 0 ? 0 : n);\n }\n\n /**\n * Creates a slice of `array` with `n` elements taken from the end.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Array\n * @param {Array} array The array to query.\n * @param {number} [n=1] The number of elements to take.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the slice of `array`.\n * @example\n *\n * _.takeRight([1, 2, 3]);\n * // => [3]\n *\n * _.takeRight([1, 2, 3], 2);\n * // => [2, 3]\n *\n * _.takeRight([1, 2, 3], 5);\n * // => [1, 2, 3]\n *\n * _.takeRight([1, 2, 3], 0);\n * // => []\n */\n function takeRight(array, n, guard) {\n var length = array == null ? 0 : array.length;\n if (!length) {\n return [];\n }\n n = (guard || n === undefined) ? 1 : toInteger(n);\n n = length - n;\n return baseSlice(array, n < 0 ? 0 : n, length);\n }\n\n /**\n * Creates a slice of `array` with elements taken from the end. Elements are\n * taken until `predicate` returns falsey. The predicate is invoked with\n * three arguments: (value, index, array).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Array\n * @param {Array} array The array to query.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the slice of `array`.\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'active': true },\n * { 'user': 'fred', 'active': false },\n * { 'user': 'pebbles', 'active': false }\n * ];\n *\n * _.takeRightWhile(users, function(o) { return !o.active; });\n * // => objects for ['fred', 'pebbles']\n *\n * // The `_.matches` iteratee shorthand.\n * _.takeRightWhile(users, { 'user': 'pebbles', 'active': false });\n * // => objects for ['pebbles']\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.takeRightWhile(users, ['active', false]);\n * // => objects for ['fred', 'pebbles']\n *\n * // The `_.property` iteratee shorthand.\n * _.takeRightWhile(users, 'active');\n * // => []\n */\n function takeRightWhile(array, predicate) {\n return (array && array.length)\n ? baseWhile(array, getIteratee(predicate, 3), false, true)\n : [];\n }\n\n /**\n * Creates a slice of `array` with elements taken from the beginning. Elements\n * are taken until `predicate` returns falsey. The predicate is invoked with\n * three arguments: (value, index, array).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Array\n * @param {Array} array The array to query.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the slice of `array`.\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'active': false },\n * { 'user': 'fred', 'active': false },\n * { 'user': 'pebbles', 'active': true }\n * ];\n *\n * _.takeWhile(users, function(o) { return !o.active; });\n * // => objects for ['barney', 'fred']\n *\n * // The `_.matches` iteratee shorthand.\n * _.takeWhile(users, { 'user': 'barney', 'active': false });\n * // => objects for ['barney']\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.takeWhile(users, ['active', false]);\n * // => objects for ['barney', 'fred']\n *\n * // The `_.property` iteratee shorthand.\n * _.takeWhile(users, 'active');\n * // => []\n */\n function takeWhile(array, predicate) {\n return (array && array.length)\n ? baseWhile(array, getIteratee(predicate, 3))\n : [];\n }\n\n /**\n * Creates an array of unique values, in order, from all given arrays using\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {...Array} [arrays] The arrays to inspect.\n * @returns {Array} Returns the new array of combined values.\n * @example\n *\n * _.union([2], [1, 2]);\n * // => [2, 1]\n */\n var union = baseRest(function(arrays) {\n return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true));\n });\n\n /**\n * This method is like `_.union` except that it accepts `iteratee` which is\n * invoked for each element of each `arrays` to generate the criterion by\n * which uniqueness is computed. Result values are chosen from the first\n * array in which the value occurs. The iteratee is invoked with one argument:\n * (value).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {...Array} [arrays] The arrays to inspect.\n * @param {Function} [iteratee=_.identity] The iteratee invoked per element.\n * @returns {Array} Returns the new array of combined values.\n * @example\n *\n * _.unionBy([2.1], [1.2, 2.3], Math.floor);\n * // => [2.1, 1.2]\n *\n * // The `_.property` iteratee shorthand.\n * _.unionBy([{ 'x': 1 }], [{ 'x': 2 }, { 'x': 1 }], 'x');\n * // => [{ 'x': 1 }, { 'x': 2 }]\n */\n var unionBy = baseRest(function(arrays) {\n var iteratee = last(arrays);\n if (isArrayLikeObject(iteratee)) {\n iteratee = undefined;\n }\n return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true), getIteratee(iteratee, 2));\n });\n\n /**\n * This method is like `_.union` except that it accepts `comparator` which\n * is invoked to compare elements of `arrays`. Result values are chosen from\n * the first array in which the value occurs. The comparator is invoked\n * with two arguments: (arrVal, othVal).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {...Array} [arrays] The arrays to inspect.\n * @param {Function} [comparator] The comparator invoked per element.\n * @returns {Array} Returns the new array of combined values.\n * @example\n *\n * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }];\n * var others = [{ 'x': 1, 'y': 1 }, { 'x': 1, 'y': 2 }];\n *\n * _.unionWith(objects, others, _.isEqual);\n * // => [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }, { 'x': 1, 'y': 1 }]\n */\n var unionWith = baseRest(function(arrays) {\n var comparator = last(arrays);\n comparator = typeof comparator == 'function' ? comparator : undefined;\n return baseUniq(baseFlatten(arrays, 1, isArrayLikeObject, true), undefined, comparator);\n });\n\n /**\n * Creates a duplicate-free version of an array, using\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons, in which only the first occurrence of each element\n * is kept. The order of result values is determined by the order they occur\n * in the array.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @returns {Array} Returns the new duplicate free array.\n * @example\n *\n * _.uniq([2, 1, 2]);\n * // => [2, 1]\n */\n function uniq(array) {\n return (array && array.length) ? baseUniq(array) : [];\n }\n\n /**\n * This method is like `_.uniq` except that it accepts `iteratee` which is\n * invoked for each element in `array` to generate the criterion by which\n * uniqueness is computed. The order of result values is determined by the\n * order they occur in the array. The iteratee is invoked with one argument:\n * (value).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {Function} [iteratee=_.identity] The iteratee invoked per element.\n * @returns {Array} Returns the new duplicate free array.\n * @example\n *\n * _.uniqBy([2.1, 1.2, 2.3], Math.floor);\n * // => [2.1, 1.2]\n *\n * // The `_.property` iteratee shorthand.\n * _.uniqBy([{ 'x': 1 }, { 'x': 2 }, { 'x': 1 }], 'x');\n * // => [{ 'x': 1 }, { 'x': 2 }]\n */\n function uniqBy(array, iteratee) {\n return (array && array.length) ? baseUniq(array, getIteratee(iteratee, 2)) : [];\n }\n\n /**\n * This method is like `_.uniq` except that it accepts `comparator` which\n * is invoked to compare elements of `array`. The order of result values is\n * determined by the order they occur in the array.The comparator is invoked\n * with two arguments: (arrVal, othVal).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {Function} [comparator] The comparator invoked per element.\n * @returns {Array} Returns the new duplicate free array.\n * @example\n *\n * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }, { 'x': 1, 'y': 2 }];\n *\n * _.uniqWith(objects, _.isEqual);\n * // => [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }]\n */\n function uniqWith(array, comparator) {\n comparator = typeof comparator == 'function' ? comparator : undefined;\n return (array && array.length) ? baseUniq(array, undefined, comparator) : [];\n }\n\n /**\n * This method is like `_.zip` except that it accepts an array of grouped\n * elements and creates an array regrouping the elements to their pre-zip\n * configuration.\n *\n * @static\n * @memberOf _\n * @since 1.2.0\n * @category Array\n * @param {Array} array The array of grouped elements to process.\n * @returns {Array} Returns the new array of regrouped elements.\n * @example\n *\n * var zipped = _.zip(['a', 'b'], [1, 2], [true, false]);\n * // => [['a', 1, true], ['b', 2, false]]\n *\n * _.unzip(zipped);\n * // => [['a', 'b'], [1, 2], [true, false]]\n */\n function unzip(array) {\n if (!(array && array.length)) {\n return [];\n }\n var length = 0;\n array = arrayFilter(array, function(group) {\n if (isArrayLikeObject(group)) {\n length = nativeMax(group.length, length);\n return true;\n }\n });\n return baseTimes(length, function(index) {\n return arrayMap(array, baseProperty(index));\n });\n }\n\n /**\n * This method is like `_.unzip` except that it accepts `iteratee` to specify\n * how regrouped values should be combined. The iteratee is invoked with the\n * elements of each group: (...group).\n *\n * @static\n * @memberOf _\n * @since 3.8.0\n * @category Array\n * @param {Array} array The array of grouped elements to process.\n * @param {Function} [iteratee=_.identity] The function to combine\n * regrouped values.\n * @returns {Array} Returns the new array of regrouped elements.\n * @example\n *\n * var zipped = _.zip([1, 2], [10, 20], [100, 200]);\n * // => [[1, 10, 100], [2, 20, 200]]\n *\n * _.unzipWith(zipped, _.add);\n * // => [3, 30, 300]\n */\n function unzipWith(array, iteratee) {\n if (!(array && array.length)) {\n return [];\n }\n var result = unzip(array);\n if (iteratee == null) {\n return result;\n }\n return arrayMap(result, function(group) {\n return apply(iteratee, undefined, group);\n });\n }\n\n /**\n * Creates an array excluding all given values using\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * for equality comparisons.\n *\n * **Note:** Unlike `_.pull`, this method returns a new array.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {Array} array The array to inspect.\n * @param {...*} [values] The values to exclude.\n * @returns {Array} Returns the new array of filtered values.\n * @see _.difference, _.xor\n * @example\n *\n * _.without([2, 1, 2, 3], 1, 2);\n * // => [3]\n */\n var without = baseRest(function(array, values) {\n return isArrayLikeObject(array)\n ? baseDifference(array, values)\n : [];\n });\n\n /**\n * Creates an array of unique values that is the\n * [symmetric difference](https://en.wikipedia.org/wiki/Symmetric_difference)\n * of the given arrays. The order of result values is determined by the order\n * they occur in the arrays.\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Array\n * @param {...Array} [arrays] The arrays to inspect.\n * @returns {Array} Returns the new array of filtered values.\n * @see _.difference, _.without\n * @example\n *\n * _.xor([2, 1], [2, 3]);\n * // => [1, 3]\n */\n var xor = baseRest(function(arrays) {\n return baseXor(arrayFilter(arrays, isArrayLikeObject));\n });\n\n /**\n * This method is like `_.xor` except that it accepts `iteratee` which is\n * invoked for each element of each `arrays` to generate the criterion by\n * which by which they're compared. The order of result values is determined\n * by the order they occur in the arrays. The iteratee is invoked with one\n * argument: (value).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {...Array} [arrays] The arrays to inspect.\n * @param {Function} [iteratee=_.identity] The iteratee invoked per element.\n * @returns {Array} Returns the new array of filtered values.\n * @example\n *\n * _.xorBy([2.1, 1.2], [2.3, 3.4], Math.floor);\n * // => [1.2, 3.4]\n *\n * // The `_.property` iteratee shorthand.\n * _.xorBy([{ 'x': 1 }], [{ 'x': 2 }, { 'x': 1 }], 'x');\n * // => [{ 'x': 2 }]\n */\n var xorBy = baseRest(function(arrays) {\n var iteratee = last(arrays);\n if (isArrayLikeObject(iteratee)) {\n iteratee = undefined;\n }\n return baseXor(arrayFilter(arrays, isArrayLikeObject), getIteratee(iteratee, 2));\n });\n\n /**\n * This method is like `_.xor` except that it accepts `comparator` which is\n * invoked to compare elements of `arrays`. The order of result values is\n * determined by the order they occur in the arrays. The comparator is invoked\n * with two arguments: (arrVal, othVal).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Array\n * @param {...Array} [arrays] The arrays to inspect.\n * @param {Function} [comparator] The comparator invoked per element.\n * @returns {Array} Returns the new array of filtered values.\n * @example\n *\n * var objects = [{ 'x': 1, 'y': 2 }, { 'x': 2, 'y': 1 }];\n * var others = [{ 'x': 1, 'y': 1 }, { 'x': 1, 'y': 2 }];\n *\n * _.xorWith(objects, others, _.isEqual);\n * // => [{ 'x': 2, 'y': 1 }, { 'x': 1, 'y': 1 }]\n */\n var xorWith = baseRest(function(arrays) {\n var comparator = last(arrays);\n comparator = typeof comparator == 'function' ? comparator : undefined;\n return baseXor(arrayFilter(arrays, isArrayLikeObject), undefined, comparator);\n });\n\n /**\n * Creates an array of grouped elements, the first of which contains the\n * first elements of the given arrays, the second of which contains the\n * second elements of the given arrays, and so on.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Array\n * @param {...Array} [arrays] The arrays to process.\n * @returns {Array} Returns the new array of grouped elements.\n * @example\n *\n * _.zip(['a', 'b'], [1, 2], [true, false]);\n * // => [['a', 1, true], ['b', 2, false]]\n */\n var zip = baseRest(unzip);\n\n /**\n * This method is like `_.fromPairs` except that it accepts two arrays,\n * one of property identifiers and one of corresponding values.\n *\n * @static\n * @memberOf _\n * @since 0.4.0\n * @category Array\n * @param {Array} [props=[]] The property identifiers.\n * @param {Array} [values=[]] The property values.\n * @returns {Object} Returns the new object.\n * @example\n *\n * _.zipObject(['a', 'b'], [1, 2]);\n * // => { 'a': 1, 'b': 2 }\n */\n function zipObject(props, values) {\n return baseZipObject(props || [], values || [], assignValue);\n }\n\n /**\n * This method is like `_.zipObject` except that it supports property paths.\n *\n * @static\n * @memberOf _\n * @since 4.1.0\n * @category Array\n * @param {Array} [props=[]] The property identifiers.\n * @param {Array} [values=[]] The property values.\n * @returns {Object} Returns the new object.\n * @example\n *\n * _.zipObjectDeep(['a.b[0].c', 'a.b[1].d'], [1, 2]);\n * // => { 'a': { 'b': [{ 'c': 1 }, { 'd': 2 }] } }\n */\n function zipObjectDeep(props, values) {\n return baseZipObject(props || [], values || [], baseSet);\n }\n\n /**\n * This method is like `_.zip` except that it accepts `iteratee` to specify\n * how grouped values should be combined. The iteratee is invoked with the\n * elements of each group: (...group).\n *\n * @static\n * @memberOf _\n * @since 3.8.0\n * @category Array\n * @param {...Array} [arrays] The arrays to process.\n * @param {Function} [iteratee=_.identity] The function to combine\n * grouped values.\n * @returns {Array} Returns the new array of grouped elements.\n * @example\n *\n * _.zipWith([1, 2], [10, 20], [100, 200], function(a, b, c) {\n * return a + b + c;\n * });\n * // => [111, 222]\n */\n var zipWith = baseRest(function(arrays) {\n var length = arrays.length,\n iteratee = length > 1 ? arrays[length - 1] : undefined;\n\n iteratee = typeof iteratee == 'function' ? (arrays.pop(), iteratee) : undefined;\n return unzipWith(arrays, iteratee);\n });\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates a `lodash` wrapper instance that wraps `value` with explicit method\n * chain sequences enabled. The result of such sequences must be unwrapped\n * with `_#value`.\n *\n * @static\n * @memberOf _\n * @since 1.3.0\n * @category Seq\n * @param {*} value The value to wrap.\n * @returns {Object} Returns the new `lodash` wrapper instance.\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'age': 36 },\n * { 'user': 'fred', 'age': 40 },\n * { 'user': 'pebbles', 'age': 1 }\n * ];\n *\n * var youngest = _\n * .chain(users)\n * .sortBy('age')\n * .map(function(o) {\n * return o.user + ' is ' + o.age;\n * })\n * .head()\n * .value();\n * // => 'pebbles is 1'\n */\n function chain(value) {\n var result = lodash(value);\n result.__chain__ = true;\n return result;\n }\n\n /**\n * This method invokes `interceptor` and returns `value`. The interceptor\n * is invoked with one argument; (value). The purpose of this method is to\n * \"tap into\" a method chain sequence in order to modify intermediate results.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Seq\n * @param {*} value The value to provide to `interceptor`.\n * @param {Function} interceptor The function to invoke.\n * @returns {*} Returns `value`.\n * @example\n *\n * _([1, 2, 3])\n * .tap(function(array) {\n * // Mutate input array.\n * array.pop();\n * })\n * .reverse()\n * .value();\n * // => [2, 1]\n */\n function tap(value, interceptor) {\n interceptor(value);\n return value;\n }\n\n /**\n * This method is like `_.tap` except that it returns the result of `interceptor`.\n * The purpose of this method is to \"pass thru\" values replacing intermediate\n * results in a method chain sequence.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Seq\n * @param {*} value The value to provide to `interceptor`.\n * @param {Function} interceptor The function to invoke.\n * @returns {*} Returns the result of `interceptor`.\n * @example\n *\n * _(' abc ')\n * .chain()\n * .trim()\n * .thru(function(value) {\n * return [value];\n * })\n * .value();\n * // => ['abc']\n */\n function thru(value, interceptor) {\n return interceptor(value);\n }\n\n /**\n * This method is the wrapper version of `_.at`.\n *\n * @name at\n * @memberOf _\n * @since 1.0.0\n * @category Seq\n * @param {...(string|string[])} [paths] The property paths to pick.\n * @returns {Object} Returns the new `lodash` wrapper instance.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }, 4] };\n *\n * _(object).at(['a[0].b.c', 'a[1]']).value();\n * // => [3, 4]\n */\n var wrapperAt = flatRest(function(paths) {\n var length = paths.length,\n start = length ? paths[0] : 0,\n value = this.__wrapped__,\n interceptor = function(object) { return baseAt(object, paths); };\n\n if (length > 1 || this.__actions__.length ||\n !(value instanceof LazyWrapper) || !isIndex(start)) {\n return this.thru(interceptor);\n }\n value = value.slice(start, +start + (length ? 1 : 0));\n value.__actions__.push({\n 'func': thru,\n 'args': [interceptor],\n 'thisArg': undefined\n });\n return new LodashWrapper(value, this.__chain__).thru(function(array) {\n if (length && !array.length) {\n array.push(undefined);\n }\n return array;\n });\n });\n\n /**\n * Creates a `lodash` wrapper instance with explicit method chain sequences enabled.\n *\n * @name chain\n * @memberOf _\n * @since 0.1.0\n * @category Seq\n * @returns {Object} Returns the new `lodash` wrapper instance.\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'age': 36 },\n * { 'user': 'fred', 'age': 40 }\n * ];\n *\n * // A sequence without explicit chaining.\n * _(users).head();\n * // => { 'user': 'barney', 'age': 36 }\n *\n * // A sequence with explicit chaining.\n * _(users)\n * .chain()\n * .head()\n * .pick('user')\n * .value();\n * // => { 'user': 'barney' }\n */\n function wrapperChain() {\n return chain(this);\n }\n\n /**\n * Executes the chain sequence and returns the wrapped result.\n *\n * @name commit\n * @memberOf _\n * @since 3.2.0\n * @category Seq\n * @returns {Object} Returns the new `lodash` wrapper instance.\n * @example\n *\n * var array = [1, 2];\n * var wrapped = _(array).push(3);\n *\n * console.log(array);\n * // => [1, 2]\n *\n * wrapped = wrapped.commit();\n * console.log(array);\n * // => [1, 2, 3]\n *\n * wrapped.last();\n * // => 3\n *\n * console.log(array);\n * // => [1, 2, 3]\n */\n function wrapperCommit() {\n return new LodashWrapper(this.value(), this.__chain__);\n }\n\n /**\n * Gets the next value on a wrapped object following the\n * [iterator protocol](https://mdn.io/iteration_protocols#iterator).\n *\n * @name next\n * @memberOf _\n * @since 4.0.0\n * @category Seq\n * @returns {Object} Returns the next iterator value.\n * @example\n *\n * var wrapped = _([1, 2]);\n *\n * wrapped.next();\n * // => { 'done': false, 'value': 1 }\n *\n * wrapped.next();\n * // => { 'done': false, 'value': 2 }\n *\n * wrapped.next();\n * // => { 'done': true, 'value': undefined }\n */\n function wrapperNext() {\n if (this.__values__ === undefined) {\n this.__values__ = toArray(this.value());\n }\n var done = this.__index__ >= this.__values__.length,\n value = done ? undefined : this.__values__[this.__index__++];\n\n return { 'done': done, 'value': value };\n }\n\n /**\n * Enables the wrapper to be iterable.\n *\n * @name Symbol.iterator\n * @memberOf _\n * @since 4.0.0\n * @category Seq\n * @returns {Object} Returns the wrapper object.\n * @example\n *\n * var wrapped = _([1, 2]);\n *\n * wrapped[Symbol.iterator]() === wrapped;\n * // => true\n *\n * Array.from(wrapped);\n * // => [1, 2]\n */\n function wrapperToIterator() {\n return this;\n }\n\n /**\n * Creates a clone of the chain sequence planting `value` as the wrapped value.\n *\n * @name plant\n * @memberOf _\n * @since 3.2.0\n * @category Seq\n * @param {*} value The value to plant.\n * @returns {Object} Returns the new `lodash` wrapper instance.\n * @example\n *\n * function square(n) {\n * return n * n;\n * }\n *\n * var wrapped = _([1, 2]).map(square);\n * var other = wrapped.plant([3, 4]);\n *\n * other.value();\n * // => [9, 16]\n *\n * wrapped.value();\n * // => [1, 4]\n */\n function wrapperPlant(value) {\n var result,\n parent = this;\n\n while (parent instanceof baseLodash) {\n var clone = wrapperClone(parent);\n clone.__index__ = 0;\n clone.__values__ = undefined;\n if (result) {\n previous.__wrapped__ = clone;\n } else {\n result = clone;\n }\n var previous = clone;\n parent = parent.__wrapped__;\n }\n previous.__wrapped__ = value;\n return result;\n }\n\n /**\n * This method is the wrapper version of `_.reverse`.\n *\n * **Note:** This method mutates the wrapped array.\n *\n * @name reverse\n * @memberOf _\n * @since 0.1.0\n * @category Seq\n * @returns {Object} Returns the new `lodash` wrapper instance.\n * @example\n *\n * var array = [1, 2, 3];\n *\n * _(array).reverse().value()\n * // => [3, 2, 1]\n *\n * console.log(array);\n * // => [3, 2, 1]\n */\n function wrapperReverse() {\n var value = this.__wrapped__;\n if (value instanceof LazyWrapper) {\n var wrapped = value;\n if (this.__actions__.length) {\n wrapped = new LazyWrapper(this);\n }\n wrapped = wrapped.reverse();\n wrapped.__actions__.push({\n 'func': thru,\n 'args': [reverse],\n 'thisArg': undefined\n });\n return new LodashWrapper(wrapped, this.__chain__);\n }\n return this.thru(reverse);\n }\n\n /**\n * Executes the chain sequence to resolve the unwrapped value.\n *\n * @name value\n * @memberOf _\n * @since 0.1.0\n * @alias toJSON, valueOf\n * @category Seq\n * @returns {*} Returns the resolved unwrapped value.\n * @example\n *\n * _([1, 2, 3]).value();\n * // => [1, 2, 3]\n */\n function wrapperValue() {\n return baseWrapperValue(this.__wrapped__, this.__actions__);\n }\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Creates an object composed of keys generated from the results of running\n * each element of `collection` thru `iteratee`. The corresponding value of\n * each key is the number of times the key was returned by `iteratee`. The\n * iteratee is invoked with one argument: (value).\n *\n * @static\n * @memberOf _\n * @since 0.5.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The iteratee to transform keys.\n * @returns {Object} Returns the composed aggregate object.\n * @example\n *\n * _.countBy([6.1, 4.2, 6.3], Math.floor);\n * // => { '4': 1, '6': 2 }\n *\n * // The `_.property` iteratee shorthand.\n * _.countBy(['one', 'two', 'three'], 'length');\n * // => { '3': 2, '5': 1 }\n */\n var countBy = createAggregator(function(result, value, key) {\n if (hasOwnProperty.call(result, key)) {\n ++result[key];\n } else {\n baseAssignValue(result, key, 1);\n }\n });\n\n /**\n * Checks if `predicate` returns truthy for **all** elements of `collection`.\n * Iteration is stopped once `predicate` returns falsey. The predicate is\n * invoked with three arguments: (value, index|key, collection).\n *\n * **Note:** This method returns `true` for\n * [empty collections](https://en.wikipedia.org/wiki/Empty_set) because\n * [everything is true](https://en.wikipedia.org/wiki/Vacuous_truth) of\n * elements of empty collections.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {boolean} Returns `true` if all elements pass the predicate check,\n * else `false`.\n * @example\n *\n * _.every([true, 1, null, 'yes'], Boolean);\n * // => false\n *\n * var users = [\n * { 'user': 'barney', 'age': 36, 'active': false },\n * { 'user': 'fred', 'age': 40, 'active': false }\n * ];\n *\n * // The `_.matches` iteratee shorthand.\n * _.every(users, { 'user': 'barney', 'active': false });\n * // => false\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.every(users, ['active', false]);\n * // => true\n *\n * // The `_.property` iteratee shorthand.\n * _.every(users, 'active');\n * // => false\n */\n function every(collection, predicate, guard) {\n var func = isArray(collection) ? arrayEvery : baseEvery;\n if (guard && isIterateeCall(collection, predicate, guard)) {\n predicate = undefined;\n }\n return func(collection, getIteratee(predicate, 3));\n }\n\n /**\n * Iterates over elements of `collection`, returning an array of all elements\n * `predicate` returns truthy for. The predicate is invoked with three\n * arguments: (value, index|key, collection).\n *\n * **Note:** Unlike `_.remove`, this method returns a new array.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n * @see _.reject\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'age': 36, 'active': true },\n * { 'user': 'fred', 'age': 40, 'active': false }\n * ];\n *\n * _.filter(users, function(o) { return !o.active; });\n * // => objects for ['fred']\n *\n * // The `_.matches` iteratee shorthand.\n * _.filter(users, { 'age': 36, 'active': true });\n * // => objects for ['barney']\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.filter(users, ['active', false]);\n * // => objects for ['fred']\n *\n * // The `_.property` iteratee shorthand.\n * _.filter(users, 'active');\n * // => objects for ['barney']\n *\n * // Combining several predicates using `_.overEvery` or `_.overSome`.\n * _.filter(users, _.overSome([{ 'age': 36 }, ['age', 40]]));\n * // => objects for ['fred', 'barney']\n */\n function filter(collection, predicate) {\n var func = isArray(collection) ? arrayFilter : baseFilter;\n return func(collection, getIteratee(predicate, 3));\n }\n\n /**\n * Iterates over elements of `collection`, returning the first element\n * `predicate` returns truthy for. The predicate is invoked with three\n * arguments: (value, index|key, collection).\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to inspect.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @param {number} [fromIndex=0] The index to search from.\n * @returns {*} Returns the matched element, else `undefined`.\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'age': 36, 'active': true },\n * { 'user': 'fred', 'age': 40, 'active': false },\n * { 'user': 'pebbles', 'age': 1, 'active': true }\n * ];\n *\n * _.find(users, function(o) { return o.age < 40; });\n * // => object for 'barney'\n *\n * // The `_.matches` iteratee shorthand.\n * _.find(users, { 'age': 1, 'active': true });\n * // => object for 'pebbles'\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.find(users, ['active', false]);\n * // => object for 'fred'\n *\n * // The `_.property` iteratee shorthand.\n * _.find(users, 'active');\n * // => object for 'barney'\n */\n var find = createFind(findIndex);\n\n /**\n * This method is like `_.find` except that it iterates over elements of\n * `collection` from right to left.\n *\n * @static\n * @memberOf _\n * @since 2.0.0\n * @category Collection\n * @param {Array|Object} collection The collection to inspect.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @param {number} [fromIndex=collection.length-1] The index to search from.\n * @returns {*} Returns the matched element, else `undefined`.\n * @example\n *\n * _.findLast([1, 2, 3, 4], function(n) {\n * return n % 2 == 1;\n * });\n * // => 3\n */\n var findLast = createFind(findLastIndex);\n\n /**\n * Creates a flattened array of values by running each element in `collection`\n * thru `iteratee` and flattening the mapped results. The iteratee is invoked\n * with three arguments: (value, index|key, collection).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the new flattened array.\n * @example\n *\n * function duplicate(n) {\n * return [n, n];\n * }\n *\n * _.flatMap([1, 2], duplicate);\n * // => [1, 1, 2, 2]\n */\n function flatMap(collection, iteratee) {\n return baseFlatten(map(collection, iteratee), 1);\n }\n\n /**\n * This method is like `_.flatMap` except that it recursively flattens the\n * mapped results.\n *\n * @static\n * @memberOf _\n * @since 4.7.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the new flattened array.\n * @example\n *\n * function duplicate(n) {\n * return [[[n, n]]];\n * }\n *\n * _.flatMapDeep([1, 2], duplicate);\n * // => [1, 1, 2, 2]\n */\n function flatMapDeep(collection, iteratee) {\n return baseFlatten(map(collection, iteratee), INFINITY);\n }\n\n /**\n * This method is like `_.flatMap` except that it recursively flattens the\n * mapped results up to `depth` times.\n *\n * @static\n * @memberOf _\n * @since 4.7.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @param {number} [depth=1] The maximum recursion depth.\n * @returns {Array} Returns the new flattened array.\n * @example\n *\n * function duplicate(n) {\n * return [[[n, n]]];\n * }\n *\n * _.flatMapDepth([1, 2], duplicate, 2);\n * // => [[1, 1], [2, 2]]\n */\n function flatMapDepth(collection, iteratee, depth) {\n depth = depth === undefined ? 1 : toInteger(depth);\n return baseFlatten(map(collection, iteratee), depth);\n }\n\n /**\n * Iterates over elements of `collection` and invokes `iteratee` for each element.\n * The iteratee is invoked with three arguments: (value, index|key, collection).\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * **Note:** As with other \"Collections\" methods, objects with a \"length\"\n * property are iterated like arrays. To avoid this behavior use `_.forIn`\n * or `_.forOwn` for object iteration.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @alias each\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Array|Object} Returns `collection`.\n * @see _.forEachRight\n * @example\n *\n * _.forEach([1, 2], function(value) {\n * console.log(value);\n * });\n * // => Logs `1` then `2`.\n *\n * _.forEach({ 'a': 1, 'b': 2 }, function(value, key) {\n * console.log(key);\n * });\n * // => Logs 'a' then 'b' (iteration order is not guaranteed).\n */\n function forEach(collection, iteratee) {\n var func = isArray(collection) ? arrayEach : baseEach;\n return func(collection, getIteratee(iteratee, 3));\n }\n\n /**\n * This method is like `_.forEach` except that it iterates over elements of\n * `collection` from right to left.\n *\n * @static\n * @memberOf _\n * @since 2.0.0\n * @alias eachRight\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Array|Object} Returns `collection`.\n * @see _.forEach\n * @example\n *\n * _.forEachRight([1, 2], function(value) {\n * console.log(value);\n * });\n * // => Logs `2` then `1`.\n */\n function forEachRight(collection, iteratee) {\n var func = isArray(collection) ? arrayEachRight : baseEachRight;\n return func(collection, getIteratee(iteratee, 3));\n }\n\n /**\n * Creates an object composed of keys generated from the results of running\n * each element of `collection` thru `iteratee`. The order of grouped values\n * is determined by the order they occur in `collection`. The corresponding\n * value of each key is an array of elements responsible for generating the\n * key. The iteratee is invoked with one argument: (value).\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The iteratee to transform keys.\n * @returns {Object} Returns the composed aggregate object.\n * @example\n *\n * _.groupBy([6.1, 4.2, 6.3], Math.floor);\n * // => { '4': [4.2], '6': [6.1, 6.3] }\n *\n * // The `_.property` iteratee shorthand.\n * _.groupBy(['one', 'two', 'three'], 'length');\n * // => { '3': ['one', 'two'], '5': ['three'] }\n */\n var groupBy = createAggregator(function(result, value, key) {\n if (hasOwnProperty.call(result, key)) {\n result[key].push(value);\n } else {\n baseAssignValue(result, key, [value]);\n }\n });\n\n /**\n * Checks if `value` is in `collection`. If `collection` is a string, it's\n * checked for a substring of `value`, otherwise\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * is used for equality comparisons. If `fromIndex` is negative, it's used as\n * the offset from the end of `collection`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object|string} collection The collection to inspect.\n * @param {*} value The value to search for.\n * @param {number} [fromIndex=0] The index to search from.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.reduce`.\n * @returns {boolean} Returns `true` if `value` is found, else `false`.\n * @example\n *\n * _.includes([1, 2, 3], 1);\n * // => true\n *\n * _.includes([1, 2, 3], 1, 2);\n * // => false\n *\n * _.includes({ 'a': 1, 'b': 2 }, 1);\n * // => true\n *\n * _.includes('abcd', 'bc');\n * // => true\n */\n function includes(collection, value, fromIndex, guard) {\n collection = isArrayLike(collection) ? collection : values(collection);\n fromIndex = (fromIndex && !guard) ? toInteger(fromIndex) : 0;\n\n var length = collection.length;\n if (fromIndex < 0) {\n fromIndex = nativeMax(length + fromIndex, 0);\n }\n return isString(collection)\n ? (fromIndex <= length && collection.indexOf(value, fromIndex) > -1)\n : (!!length && baseIndexOf(collection, value, fromIndex) > -1);\n }\n\n /**\n * Invokes the method at `path` of each element in `collection`, returning\n * an array of the results of each invoked method. Any additional arguments\n * are provided to each invoked method. If `path` is a function, it's invoked\n * for, and `this` bound to, each element in `collection`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Array|Function|string} path The path of the method to invoke or\n * the function invoked per iteration.\n * @param {...*} [args] The arguments to invoke each method with.\n * @returns {Array} Returns the array of results.\n * @example\n *\n * _.invokeMap([[5, 1, 7], [3, 2, 1]], 'sort');\n * // => [[1, 5, 7], [1, 2, 3]]\n *\n * _.invokeMap([123, 456], String.prototype.split, '');\n * // => [['1', '2', '3'], ['4', '5', '6']]\n */\n var invokeMap = baseRest(function(collection, path, args) {\n var index = -1,\n isFunc = typeof path == 'function',\n result = isArrayLike(collection) ? Array(collection.length) : [];\n\n baseEach(collection, function(value) {\n result[++index] = isFunc ? apply(path, value, args) : baseInvoke(value, path, args);\n });\n return result;\n });\n\n /**\n * Creates an object composed of keys generated from the results of running\n * each element of `collection` thru `iteratee`. The corresponding value of\n * each key is the last element responsible for generating the key. The\n * iteratee is invoked with one argument: (value).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The iteratee to transform keys.\n * @returns {Object} Returns the composed aggregate object.\n * @example\n *\n * var array = [\n * { 'dir': 'left', 'code': 97 },\n * { 'dir': 'right', 'code': 100 }\n * ];\n *\n * _.keyBy(array, function(o) {\n * return String.fromCharCode(o.code);\n * });\n * // => { 'a': { 'dir': 'left', 'code': 97 }, 'd': { 'dir': 'right', 'code': 100 } }\n *\n * _.keyBy(array, 'dir');\n * // => { 'left': { 'dir': 'left', 'code': 97 }, 'right': { 'dir': 'right', 'code': 100 } }\n */\n var keyBy = createAggregator(function(result, value, key) {\n baseAssignValue(result, key, value);\n });\n\n /**\n * Creates an array of values by running each element in `collection` thru\n * `iteratee`. The iteratee is invoked with three arguments:\n * (value, index|key, collection).\n *\n * Many lodash methods are guarded to work as iteratees for methods like\n * `_.every`, `_.filter`, `_.map`, `_.mapValues`, `_.reject`, and `_.some`.\n *\n * The guarded methods are:\n * `ary`, `chunk`, `curry`, `curryRight`, `drop`, `dropRight`, `every`,\n * `fill`, `invert`, `parseInt`, `random`, `range`, `rangeRight`, `repeat`,\n * `sampleSize`, `slice`, `some`, `sortBy`, `split`, `take`, `takeRight`,\n * `template`, `trim`, `trimEnd`, `trimStart`, and `words`\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the new mapped array.\n * @example\n *\n * function square(n) {\n * return n * n;\n * }\n *\n * _.map([4, 8], square);\n * // => [16, 64]\n *\n * _.map({ 'a': 4, 'b': 8 }, square);\n * // => [16, 64] (iteration order is not guaranteed)\n *\n * var users = [\n * { 'user': 'barney' },\n * { 'user': 'fred' }\n * ];\n *\n * // The `_.property` iteratee shorthand.\n * _.map(users, 'user');\n * // => ['barney', 'fred']\n */\n function map(collection, iteratee) {\n var func = isArray(collection) ? arrayMap : baseMap;\n return func(collection, getIteratee(iteratee, 3));\n }\n\n /**\n * This method is like `_.sortBy` except that it allows specifying the sort\n * orders of the iteratees to sort by. If `orders` is unspecified, all values\n * are sorted in ascending order. Otherwise, specify an order of \"desc\" for\n * descending or \"asc\" for ascending sort order of corresponding values.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Array[]|Function[]|Object[]|string[]} [iteratees=[_.identity]]\n * The iteratees to sort by.\n * @param {string[]} [orders] The sort orders of `iteratees`.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.reduce`.\n * @returns {Array} Returns the new sorted array.\n * @example\n *\n * var users = [\n * { 'user': 'fred', 'age': 48 },\n * { 'user': 'barney', 'age': 34 },\n * { 'user': 'fred', 'age': 40 },\n * { 'user': 'barney', 'age': 36 }\n * ];\n *\n * // Sort by `user` in ascending order and by `age` in descending order.\n * _.orderBy(users, ['user', 'age'], ['asc', 'desc']);\n * // => objects for [['barney', 36], ['barney', 34], ['fred', 48], ['fred', 40]]\n */\n function orderBy(collection, iteratees, orders, guard) {\n if (collection == null) {\n return [];\n }\n if (!isArray(iteratees)) {\n iteratees = iteratees == null ? [] : [iteratees];\n }\n orders = guard ? undefined : orders;\n if (!isArray(orders)) {\n orders = orders == null ? [] : [orders];\n }\n return baseOrderBy(collection, iteratees, orders);\n }\n\n /**\n * Creates an array of elements split into two groups, the first of which\n * contains elements `predicate` returns truthy for, the second of which\n * contains elements `predicate` returns falsey for. The predicate is\n * invoked with one argument: (value).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the array of grouped elements.\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'age': 36, 'active': false },\n * { 'user': 'fred', 'age': 40, 'active': true },\n * { 'user': 'pebbles', 'age': 1, 'active': false }\n * ];\n *\n * _.partition(users, function(o) { return o.active; });\n * // => objects for [['fred'], ['barney', 'pebbles']]\n *\n * // The `_.matches` iteratee shorthand.\n * _.partition(users, { 'age': 1, 'active': false });\n * // => objects for [['pebbles'], ['barney', 'fred']]\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.partition(users, ['active', false]);\n * // => objects for [['barney', 'pebbles'], ['fred']]\n *\n * // The `_.property` iteratee shorthand.\n * _.partition(users, 'active');\n * // => objects for [['fred'], ['barney', 'pebbles']]\n */\n var partition = createAggregator(function(result, value, key) {\n result[key ? 0 : 1].push(value);\n }, function() { return [[], []]; });\n\n /**\n * Reduces `collection` to a value which is the accumulated result of running\n * each element in `collection` thru `iteratee`, where each successive\n * invocation is supplied the return value of the previous. If `accumulator`\n * is not given, the first element of `collection` is used as the initial\n * value. The iteratee is invoked with four arguments:\n * (accumulator, value, index|key, collection).\n *\n * Many lodash methods are guarded to work as iteratees for methods like\n * `_.reduce`, `_.reduceRight`, and `_.transform`.\n *\n * The guarded methods are:\n * `assign`, `defaults`, `defaultsDeep`, `includes`, `merge`, `orderBy`,\n * and `sortBy`\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @param {*} [accumulator] The initial value.\n * @returns {*} Returns the accumulated value.\n * @see _.reduceRight\n * @example\n *\n * _.reduce([1, 2], function(sum, n) {\n * return sum + n;\n * }, 0);\n * // => 3\n *\n * _.reduce({ 'a': 1, 'b': 2, 'c': 1 }, function(result, value, key) {\n * (result[value] || (result[value] = [])).push(key);\n * return result;\n * }, {});\n * // => { '1': ['a', 'c'], '2': ['b'] } (iteration order is not guaranteed)\n */\n function reduce(collection, iteratee, accumulator) {\n var func = isArray(collection) ? arrayReduce : baseReduce,\n initAccum = arguments.length < 3;\n\n return func(collection, getIteratee(iteratee, 4), accumulator, initAccum, baseEach);\n }\n\n /**\n * This method is like `_.reduce` except that it iterates over elements of\n * `collection` from right to left.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @param {*} [accumulator] The initial value.\n * @returns {*} Returns the accumulated value.\n * @see _.reduce\n * @example\n *\n * var array = [[0, 1], [2, 3], [4, 5]];\n *\n * _.reduceRight(array, function(flattened, other) {\n * return flattened.concat(other);\n * }, []);\n * // => [4, 5, 2, 3, 0, 1]\n */\n function reduceRight(collection, iteratee, accumulator) {\n var func = isArray(collection) ? arrayReduceRight : baseReduce,\n initAccum = arguments.length < 3;\n\n return func(collection, getIteratee(iteratee, 4), accumulator, initAccum, baseEachRight);\n }\n\n /**\n * The opposite of `_.filter`; this method returns the elements of `collection`\n * that `predicate` does **not** return truthy for.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @returns {Array} Returns the new filtered array.\n * @see _.filter\n * @example\n *\n * var users = [\n * { 'user': 'barney', 'age': 36, 'active': false },\n * { 'user': 'fred', 'age': 40, 'active': true }\n * ];\n *\n * _.reject(users, function(o) { return !o.active; });\n * // => objects for ['fred']\n *\n * // The `_.matches` iteratee shorthand.\n * _.reject(users, { 'age': 40, 'active': true });\n * // => objects for ['barney']\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.reject(users, ['active', false]);\n * // => objects for ['fred']\n *\n * // The `_.property` iteratee shorthand.\n * _.reject(users, 'active');\n * // => objects for ['barney']\n */\n function reject(collection, predicate) {\n var func = isArray(collection) ? arrayFilter : baseFilter;\n return func(collection, negate(getIteratee(predicate, 3)));\n }\n\n /**\n * Gets a random element from `collection`.\n *\n * @static\n * @memberOf _\n * @since 2.0.0\n * @category Collection\n * @param {Array|Object} collection The collection to sample.\n * @returns {*} Returns the random element.\n * @example\n *\n * _.sample([1, 2, 3, 4]);\n * // => 2\n */\n function sample(collection) {\n var func = isArray(collection) ? arraySample : baseSample;\n return func(collection);\n }\n\n /**\n * Gets `n` random elements at unique keys from `collection` up to the\n * size of `collection`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Collection\n * @param {Array|Object} collection The collection to sample.\n * @param {number} [n=1] The number of elements to sample.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Array} Returns the random elements.\n * @example\n *\n * _.sampleSize([1, 2, 3], 2);\n * // => [3, 1]\n *\n * _.sampleSize([1, 2, 3], 4);\n * // => [2, 3, 1]\n */\n function sampleSize(collection, n, guard) {\n if ((guard ? isIterateeCall(collection, n, guard) : n === undefined)) {\n n = 1;\n } else {\n n = toInteger(n);\n }\n var func = isArray(collection) ? arraySampleSize : baseSampleSize;\n return func(collection, n);\n }\n\n /**\n * Creates an array of shuffled values, using a version of the\n * [Fisher-Yates shuffle](https://en.wikipedia.org/wiki/Fisher-Yates_shuffle).\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to shuffle.\n * @returns {Array} Returns the new shuffled array.\n * @example\n *\n * _.shuffle([1, 2, 3, 4]);\n * // => [4, 1, 3, 2]\n */\n function shuffle(collection) {\n var func = isArray(collection) ? arrayShuffle : baseShuffle;\n return func(collection);\n }\n\n /**\n * Gets the size of `collection` by returning its length for array-like\n * values or the number of own enumerable string keyed properties for objects.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object|string} collection The collection to inspect.\n * @returns {number} Returns the collection size.\n * @example\n *\n * _.size([1, 2, 3]);\n * // => 3\n *\n * _.size({ 'a': 1, 'b': 2 });\n * // => 2\n *\n * _.size('pebbles');\n * // => 7\n */\n function size(collection) {\n if (collection == null) {\n return 0;\n }\n if (isArrayLike(collection)) {\n return isString(collection) ? stringSize(collection) : collection.length;\n }\n var tag = getTag(collection);\n if (tag == mapTag || tag == setTag) {\n return collection.size;\n }\n return baseKeys(collection).length;\n }\n\n /**\n * Checks if `predicate` returns truthy for **any** element of `collection`.\n * Iteration is stopped once `predicate` returns truthy. The predicate is\n * invoked with three arguments: (value, index|key, collection).\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {boolean} Returns `true` if any element passes the predicate check,\n * else `false`.\n * @example\n *\n * _.some([null, 0, 'yes', false], Boolean);\n * // => true\n *\n * var users = [\n * { 'user': 'barney', 'active': true },\n * { 'user': 'fred', 'active': false }\n * ];\n *\n * // The `_.matches` iteratee shorthand.\n * _.some(users, { 'user': 'barney', 'active': false });\n * // => false\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.some(users, ['active', false]);\n * // => true\n *\n * // The `_.property` iteratee shorthand.\n * _.some(users, 'active');\n * // => true\n */\n function some(collection, predicate, guard) {\n var func = isArray(collection) ? arraySome : baseSome;\n if (guard && isIterateeCall(collection, predicate, guard)) {\n predicate = undefined;\n }\n return func(collection, getIteratee(predicate, 3));\n }\n\n /**\n * Creates an array of elements, sorted in ascending order by the results of\n * running each element in a collection thru each iteratee. This method\n * performs a stable sort, that is, it preserves the original sort order of\n * equal elements. The iteratees are invoked with one argument: (value).\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Collection\n * @param {Array|Object} collection The collection to iterate over.\n * @param {...(Function|Function[])} [iteratees=[_.identity]]\n * The iteratees to sort by.\n * @returns {Array} Returns the new sorted array.\n * @example\n *\n * var users = [\n * { 'user': 'fred', 'age': 48 },\n * { 'user': 'barney', 'age': 36 },\n * { 'user': 'fred', 'age': 30 },\n * { 'user': 'barney', 'age': 34 }\n * ];\n *\n * _.sortBy(users, [function(o) { return o.user; }]);\n * // => objects for [['barney', 36], ['barney', 34], ['fred', 48], ['fred', 30]]\n *\n * _.sortBy(users, ['user', 'age']);\n * // => objects for [['barney', 34], ['barney', 36], ['fred', 30], ['fred', 48]]\n */\n var sortBy = baseRest(function(collection, iteratees) {\n if (collection == null) {\n return [];\n }\n var length = iteratees.length;\n if (length > 1 && isIterateeCall(collection, iteratees[0], iteratees[1])) {\n iteratees = [];\n } else if (length > 2 && isIterateeCall(iteratees[0], iteratees[1], iteratees[2])) {\n iteratees = [iteratees[0]];\n }\n return baseOrderBy(collection, baseFlatten(iteratees, 1), []);\n });\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Gets the timestamp of the number of milliseconds that have elapsed since\n * the Unix epoch (1 January 1970 00:00:00 UTC).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Date\n * @returns {number} Returns the timestamp.\n * @example\n *\n * _.defer(function(stamp) {\n * console.log(_.now() - stamp);\n * }, _.now());\n * // => Logs the number of milliseconds it took for the deferred invocation.\n */\n var now = ctxNow || function() {\n return root.Date.now();\n };\n\n /*------------------------------------------------------------------------*/\n\n /**\n * The opposite of `_.before`; this method creates a function that invokes\n * `func` once it's called `n` or more times.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {number} n The number of calls before `func` is invoked.\n * @param {Function} func The function to restrict.\n * @returns {Function} Returns the new restricted function.\n * @example\n *\n * var saves = ['profile', 'settings'];\n *\n * var done = _.after(saves.length, function() {\n * console.log('done saving!');\n * });\n *\n * _.forEach(saves, function(type) {\n * asyncSave({ 'type': type, 'complete': done });\n * });\n * // => Logs 'done saving!' after the two async saves have completed.\n */\n function after(n, func) {\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n n = toInteger(n);\n return function() {\n if (--n < 1) {\n return func.apply(this, arguments);\n }\n };\n }\n\n /**\n * Creates a function that invokes `func`, with up to `n` arguments,\n * ignoring any additional arguments.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Function\n * @param {Function} func The function to cap arguments for.\n * @param {number} [n=func.length] The arity cap.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Function} Returns the new capped function.\n * @example\n *\n * _.map(['6', '8', '10'], _.ary(parseInt, 1));\n * // => [6, 8, 10]\n */\n function ary(func, n, guard) {\n n = guard ? undefined : n;\n n = (func && n == null) ? func.length : n;\n return createWrap(func, WRAP_ARY_FLAG, undefined, undefined, undefined, undefined, n);\n }\n\n /**\n * Creates a function that invokes `func`, with the `this` binding and arguments\n * of the created function, while it's called less than `n` times. Subsequent\n * calls to the created function return the result of the last `func` invocation.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Function\n * @param {number} n The number of calls at which `func` is no longer invoked.\n * @param {Function} func The function to restrict.\n * @returns {Function} Returns the new restricted function.\n * @example\n *\n * jQuery(element).on('click', _.before(5, addContactToList));\n * // => Allows adding up to 4 contacts to the list.\n */\n function before(n, func) {\n var result;\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n n = toInteger(n);\n return function() {\n if (--n > 0) {\n result = func.apply(this, arguments);\n }\n if (n <= 1) {\n func = undefined;\n }\n return result;\n };\n }\n\n /**\n * Creates a function that invokes `func` with the `this` binding of `thisArg`\n * and `partials` prepended to the arguments it receives.\n *\n * The `_.bind.placeholder` value, which defaults to `_` in monolithic builds,\n * may be used as a placeholder for partially applied arguments.\n *\n * **Note:** Unlike native `Function#bind`, this method doesn't set the \"length\"\n * property of bound functions.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to bind.\n * @param {*} thisArg The `this` binding of `func`.\n * @param {...*} [partials] The arguments to be partially applied.\n * @returns {Function} Returns the new bound function.\n * @example\n *\n * function greet(greeting, punctuation) {\n * return greeting + ' ' + this.user + punctuation;\n * }\n *\n * var object = { 'user': 'fred' };\n *\n * var bound = _.bind(greet, object, 'hi');\n * bound('!');\n * // => 'hi fred!'\n *\n * // Bound with placeholders.\n * var bound = _.bind(greet, object, _, '!');\n * bound('hi');\n * // => 'hi fred!'\n */\n var bind = baseRest(function(func, thisArg, partials) {\n var bitmask = WRAP_BIND_FLAG;\n if (partials.length) {\n var holders = replaceHolders(partials, getHolder(bind));\n bitmask |= WRAP_PARTIAL_FLAG;\n }\n return createWrap(func, bitmask, thisArg, partials, holders);\n });\n\n /**\n * Creates a function that invokes the method at `object[key]` with `partials`\n * prepended to the arguments it receives.\n *\n * This method differs from `_.bind` by allowing bound functions to reference\n * methods that may be redefined or don't yet exist. See\n * [Peter Michaux's article](http://peter.michaux.ca/articles/lazy-function-definition-pattern)\n * for more details.\n *\n * The `_.bindKey.placeholder` value, which defaults to `_` in monolithic\n * builds, may be used as a placeholder for partially applied arguments.\n *\n * @static\n * @memberOf _\n * @since 0.10.0\n * @category Function\n * @param {Object} object The object to invoke the method on.\n * @param {string} key The key of the method.\n * @param {...*} [partials] The arguments to be partially applied.\n * @returns {Function} Returns the new bound function.\n * @example\n *\n * var object = {\n * 'user': 'fred',\n * 'greet': function(greeting, punctuation) {\n * return greeting + ' ' + this.user + punctuation;\n * }\n * };\n *\n * var bound = _.bindKey(object, 'greet', 'hi');\n * bound('!');\n * // => 'hi fred!'\n *\n * object.greet = function(greeting, punctuation) {\n * return greeting + 'ya ' + this.user + punctuation;\n * };\n *\n * bound('!');\n * // => 'hiya fred!'\n *\n * // Bound with placeholders.\n * var bound = _.bindKey(object, 'greet', _, '!');\n * bound('hi');\n * // => 'hiya fred!'\n */\n var bindKey = baseRest(function(object, key, partials) {\n var bitmask = WRAP_BIND_FLAG | WRAP_BIND_KEY_FLAG;\n if (partials.length) {\n var holders = replaceHolders(partials, getHolder(bindKey));\n bitmask |= WRAP_PARTIAL_FLAG;\n }\n return createWrap(key, bitmask, object, partials, holders);\n });\n\n /**\n * Creates a function that accepts arguments of `func` and either invokes\n * `func` returning its result, if at least `arity` number of arguments have\n * been provided, or returns a function that accepts the remaining `func`\n * arguments, and so on. The arity of `func` may be specified if `func.length`\n * is not sufficient.\n *\n * The `_.curry.placeholder` value, which defaults to `_` in monolithic builds,\n * may be used as a placeholder for provided arguments.\n *\n * **Note:** This method doesn't set the \"length\" property of curried functions.\n *\n * @static\n * @memberOf _\n * @since 2.0.0\n * @category Function\n * @param {Function} func The function to curry.\n * @param {number} [arity=func.length] The arity of `func`.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Function} Returns the new curried function.\n * @example\n *\n * var abc = function(a, b, c) {\n * return [a, b, c];\n * };\n *\n * var curried = _.curry(abc);\n *\n * curried(1)(2)(3);\n * // => [1, 2, 3]\n *\n * curried(1, 2)(3);\n * // => [1, 2, 3]\n *\n * curried(1, 2, 3);\n * // => [1, 2, 3]\n *\n * // Curried with placeholders.\n * curried(1)(_, 3)(2);\n * // => [1, 2, 3]\n */\n function curry(func, arity, guard) {\n arity = guard ? undefined : arity;\n var result = createWrap(func, WRAP_CURRY_FLAG, undefined, undefined, undefined, undefined, undefined, arity);\n result.placeholder = curry.placeholder;\n return result;\n }\n\n /**\n * This method is like `_.curry` except that arguments are applied to `func`\n * in the manner of `_.partialRight` instead of `_.partial`.\n *\n * The `_.curryRight.placeholder` value, which defaults to `_` in monolithic\n * builds, may be used as a placeholder for provided arguments.\n *\n * **Note:** This method doesn't set the \"length\" property of curried functions.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Function\n * @param {Function} func The function to curry.\n * @param {number} [arity=func.length] The arity of `func`.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Function} Returns the new curried function.\n * @example\n *\n * var abc = function(a, b, c) {\n * return [a, b, c];\n * };\n *\n * var curried = _.curryRight(abc);\n *\n * curried(3)(2)(1);\n * // => [1, 2, 3]\n *\n * curried(2, 3)(1);\n * // => [1, 2, 3]\n *\n * curried(1, 2, 3);\n * // => [1, 2, 3]\n *\n * // Curried with placeholders.\n * curried(3)(1, _)(2);\n * // => [1, 2, 3]\n */\n function curryRight(func, arity, guard) {\n arity = guard ? undefined : arity;\n var result = createWrap(func, WRAP_CURRY_RIGHT_FLAG, undefined, undefined, undefined, undefined, undefined, arity);\n result.placeholder = curryRight.placeholder;\n return result;\n }\n\n /**\n * Creates a debounced function that delays invoking `func` until after `wait`\n * milliseconds have elapsed since the last time the debounced function was\n * invoked. The debounced function comes with a `cancel` method to cancel\n * delayed `func` invocations and a `flush` method to immediately invoke them.\n * Provide `options` to indicate whether `func` should be invoked on the\n * leading and/or trailing edge of the `wait` timeout. The `func` is invoked\n * with the last arguments provided to the debounced function. Subsequent\n * calls to the debounced function return the result of the last `func`\n * invocation.\n *\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\n * invoked on the trailing edge of the timeout only if the debounced function\n * is invoked more than once during the `wait` timeout.\n *\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\n *\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\n * for details over the differences between `_.debounce` and `_.throttle`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to debounce.\n * @param {number} [wait=0] The number of milliseconds to delay.\n * @param {Object} [options={}] The options object.\n * @param {boolean} [options.leading=false]\n * Specify invoking on the leading edge of the timeout.\n * @param {number} [options.maxWait]\n * The maximum time `func` is allowed to be delayed before it's invoked.\n * @param {boolean} [options.trailing=true]\n * Specify invoking on the trailing edge of the timeout.\n * @returns {Function} Returns the new debounced function.\n * @example\n *\n * // Avoid costly calculations while the window size is in flux.\n * jQuery(window).on('resize', _.debounce(calculateLayout, 150));\n *\n * // Invoke `sendMail` when clicked, debouncing subsequent calls.\n * jQuery(element).on('click', _.debounce(sendMail, 300, {\n * 'leading': true,\n * 'trailing': false\n * }));\n *\n * // Ensure `batchLog` is invoked once after 1 second of debounced calls.\n * var debounced = _.debounce(batchLog, 250, { 'maxWait': 1000 });\n * var source = new EventSource('/stream');\n * jQuery(source).on('message', debounced);\n *\n * // Cancel the trailing debounced invocation.\n * jQuery(window).on('popstate', debounced.cancel);\n */\n function debounce(func, wait, options) {\n var lastArgs,\n lastThis,\n maxWait,\n result,\n timerId,\n lastCallTime,\n lastInvokeTime = 0,\n leading = false,\n maxing = false,\n trailing = true;\n\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n wait = toNumber(wait) || 0;\n if (isObject(options)) {\n leading = !!options.leading;\n maxing = 'maxWait' in options;\n maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;\n trailing = 'trailing' in options ? !!options.trailing : trailing;\n }\n\n function invokeFunc(time) {\n var args = lastArgs,\n thisArg = lastThis;\n\n lastArgs = lastThis = undefined;\n lastInvokeTime = time;\n result = func.apply(thisArg, args);\n return result;\n }\n\n function leadingEdge(time) {\n // Reset any `maxWait` timer.\n lastInvokeTime = time;\n // Start the timer for the trailing edge.\n timerId = setTimeout(timerExpired, wait);\n // Invoke the leading edge.\n return leading ? invokeFunc(time) : result;\n }\n\n function remainingWait(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime,\n timeWaiting = wait - timeSinceLastCall;\n\n return maxing\n ? nativeMin(timeWaiting, maxWait - timeSinceLastInvoke)\n : timeWaiting;\n }\n\n function shouldInvoke(time) {\n var timeSinceLastCall = time - lastCallTime,\n timeSinceLastInvoke = time - lastInvokeTime;\n\n // Either this is the first call, activity has stopped and we're at the\n // trailing edge, the system time has gone backwards and we're treating\n // it as the trailing edge, or we've hit the `maxWait` limit.\n return (lastCallTime === undefined || (timeSinceLastCall >= wait) ||\n (timeSinceLastCall < 0) || (maxing && timeSinceLastInvoke >= maxWait));\n }\n\n function timerExpired() {\n var time = now();\n if (shouldInvoke(time)) {\n return trailingEdge(time);\n }\n // Restart the timer.\n timerId = setTimeout(timerExpired, remainingWait(time));\n }\n\n function trailingEdge(time) {\n timerId = undefined;\n\n // Only invoke if we have `lastArgs` which means `func` has been\n // debounced at least once.\n if (trailing && lastArgs) {\n return invokeFunc(time);\n }\n lastArgs = lastThis = undefined;\n return result;\n }\n\n function cancel() {\n if (timerId !== undefined) {\n clearTimeout(timerId);\n }\n lastInvokeTime = 0;\n lastArgs = lastCallTime = lastThis = timerId = undefined;\n }\n\n function flush() {\n return timerId === undefined ? result : trailingEdge(now());\n }\n\n function debounced() {\n var time = now(),\n isInvoking = shouldInvoke(time);\n\n lastArgs = arguments;\n lastThis = this;\n lastCallTime = time;\n\n if (isInvoking) {\n if (timerId === undefined) {\n return leadingEdge(lastCallTime);\n }\n if (maxing) {\n // Handle invocations in a tight loop.\n clearTimeout(timerId);\n timerId = setTimeout(timerExpired, wait);\n return invokeFunc(lastCallTime);\n }\n }\n if (timerId === undefined) {\n timerId = setTimeout(timerExpired, wait);\n }\n return result;\n }\n debounced.cancel = cancel;\n debounced.flush = flush;\n return debounced;\n }\n\n /**\n * Defers invoking the `func` until the current call stack has cleared. Any\n * additional arguments are provided to `func` when it's invoked.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to defer.\n * @param {...*} [args] The arguments to invoke `func` with.\n * @returns {number} Returns the timer id.\n * @example\n *\n * _.defer(function(text) {\n * console.log(text);\n * }, 'deferred');\n * // => Logs 'deferred' after one millisecond.\n */\n var defer = baseRest(function(func, args) {\n return baseDelay(func, 1, args);\n });\n\n /**\n * Invokes `func` after `wait` milliseconds. Any additional arguments are\n * provided to `func` when it's invoked.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to delay.\n * @param {number} wait The number of milliseconds to delay invocation.\n * @param {...*} [args] The arguments to invoke `func` with.\n * @returns {number} Returns the timer id.\n * @example\n *\n * _.delay(function(text) {\n * console.log(text);\n * }, 1000, 'later');\n * // => Logs 'later' after one second.\n */\n var delay = baseRest(function(func, wait, args) {\n return baseDelay(func, toNumber(wait) || 0, args);\n });\n\n /**\n * Creates a function that invokes `func` with arguments reversed.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Function\n * @param {Function} func The function to flip arguments for.\n * @returns {Function} Returns the new flipped function.\n * @example\n *\n * var flipped = _.flip(function() {\n * return _.toArray(arguments);\n * });\n *\n * flipped('a', 'b', 'c', 'd');\n * // => ['d', 'c', 'b', 'a']\n */\n function flip(func) {\n return createWrap(func, WRAP_FLIP_FLAG);\n }\n\n /**\n * Creates a function that memoizes the result of `func`. If `resolver` is\n * provided, it determines the cache key for storing the result based on the\n * arguments provided to the memoized function. By default, the first argument\n * provided to the memoized function is used as the map cache key. The `func`\n * is invoked with the `this` binding of the memoized function.\n *\n * **Note:** The cache is exposed as the `cache` property on the memoized\n * function. Its creation may be customized by replacing the `_.memoize.Cache`\n * constructor with one whose instances implement the\n * [`Map`](http://ecma-international.org/ecma-262/7.0/#sec-properties-of-the-map-prototype-object)\n * method interface of `clear`, `delete`, `get`, `has`, and `set`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to have its output memoized.\n * @param {Function} [resolver] The function to resolve the cache key.\n * @returns {Function} Returns the new memoized function.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n * var other = { 'c': 3, 'd': 4 };\n *\n * var values = _.memoize(_.values);\n * values(object);\n * // => [1, 2]\n *\n * values(other);\n * // => [3, 4]\n *\n * object.a = 2;\n * values(object);\n * // => [1, 2]\n *\n * // Modify the result cache.\n * values.cache.set(object, ['a', 'b']);\n * values(object);\n * // => ['a', 'b']\n *\n * // Replace `_.memoize.Cache`.\n * _.memoize.Cache = WeakMap;\n */\n function memoize(func, resolver) {\n if (typeof func != 'function' || (resolver != null && typeof resolver != 'function')) {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n var memoized = function() {\n var args = arguments,\n key = resolver ? resolver.apply(this, args) : args[0],\n cache = memoized.cache;\n\n if (cache.has(key)) {\n return cache.get(key);\n }\n var result = func.apply(this, args);\n memoized.cache = cache.set(key, result) || cache;\n return result;\n };\n memoized.cache = new (memoize.Cache || MapCache);\n return memoized;\n }\n\n // Expose `MapCache`.\n memoize.Cache = MapCache;\n\n /**\n * Creates a function that negates the result of the predicate `func`. The\n * `func` predicate is invoked with the `this` binding and arguments of the\n * created function.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Function\n * @param {Function} predicate The predicate to negate.\n * @returns {Function} Returns the new negated function.\n * @example\n *\n * function isEven(n) {\n * return n % 2 == 0;\n * }\n *\n * _.filter([1, 2, 3, 4, 5, 6], _.negate(isEven));\n * // => [1, 3, 5]\n */\n function negate(predicate) {\n if (typeof predicate != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n return function() {\n var args = arguments;\n switch (args.length) {\n case 0: return !predicate.call(this);\n case 1: return !predicate.call(this, args[0]);\n case 2: return !predicate.call(this, args[0], args[1]);\n case 3: return !predicate.call(this, args[0], args[1], args[2]);\n }\n return !predicate.apply(this, args);\n };\n }\n\n /**\n * Creates a function that is restricted to invoking `func` once. Repeat calls\n * to the function return the value of the first invocation. The `func` is\n * invoked with the `this` binding and arguments of the created function.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to restrict.\n * @returns {Function} Returns the new restricted function.\n * @example\n *\n * var initialize = _.once(createApplication);\n * initialize();\n * initialize();\n * // => `createApplication` is invoked once\n */\n function once(func) {\n return before(2, func);\n }\n\n /**\n * Creates a function that invokes `func` with its arguments transformed.\n *\n * @static\n * @since 4.0.0\n * @memberOf _\n * @category Function\n * @param {Function} func The function to wrap.\n * @param {...(Function|Function[])} [transforms=[_.identity]]\n * The argument transforms.\n * @returns {Function} Returns the new function.\n * @example\n *\n * function doubled(n) {\n * return n * 2;\n * }\n *\n * function square(n) {\n * return n * n;\n * }\n *\n * var func = _.overArgs(function(x, y) {\n * return [x, y];\n * }, [square, doubled]);\n *\n * func(9, 3);\n * // => [81, 6]\n *\n * func(10, 5);\n * // => [100, 10]\n */\n var overArgs = castRest(function(func, transforms) {\n transforms = (transforms.length == 1 && isArray(transforms[0]))\n ? arrayMap(transforms[0], baseUnary(getIteratee()))\n : arrayMap(baseFlatten(transforms, 1), baseUnary(getIteratee()));\n\n var funcsLength = transforms.length;\n return baseRest(function(args) {\n var index = -1,\n length = nativeMin(args.length, funcsLength);\n\n while (++index < length) {\n args[index] = transforms[index].call(this, args[index]);\n }\n return apply(func, this, args);\n });\n });\n\n /**\n * Creates a function that invokes `func` with `partials` prepended to the\n * arguments it receives. This method is like `_.bind` except it does **not**\n * alter the `this` binding.\n *\n * The `_.partial.placeholder` value, which defaults to `_` in monolithic\n * builds, may be used as a placeholder for partially applied arguments.\n *\n * **Note:** This method doesn't set the \"length\" property of partially\n * applied functions.\n *\n * @static\n * @memberOf _\n * @since 0.2.0\n * @category Function\n * @param {Function} func The function to partially apply arguments to.\n * @param {...*} [partials] The arguments to be partially applied.\n * @returns {Function} Returns the new partially applied function.\n * @example\n *\n * function greet(greeting, name) {\n * return greeting + ' ' + name;\n * }\n *\n * var sayHelloTo = _.partial(greet, 'hello');\n * sayHelloTo('fred');\n * // => 'hello fred'\n *\n * // Partially applied with placeholders.\n * var greetFred = _.partial(greet, _, 'fred');\n * greetFred('hi');\n * // => 'hi fred'\n */\n var partial = baseRest(function(func, partials) {\n var holders = replaceHolders(partials, getHolder(partial));\n return createWrap(func, WRAP_PARTIAL_FLAG, undefined, partials, holders);\n });\n\n /**\n * This method is like `_.partial` except that partially applied arguments\n * are appended to the arguments it receives.\n *\n * The `_.partialRight.placeholder` value, which defaults to `_` in monolithic\n * builds, may be used as a placeholder for partially applied arguments.\n *\n * **Note:** This method doesn't set the \"length\" property of partially\n * applied functions.\n *\n * @static\n * @memberOf _\n * @since 1.0.0\n * @category Function\n * @param {Function} func The function to partially apply arguments to.\n * @param {...*} [partials] The arguments to be partially applied.\n * @returns {Function} Returns the new partially applied function.\n * @example\n *\n * function greet(greeting, name) {\n * return greeting + ' ' + name;\n * }\n *\n * var greetFred = _.partialRight(greet, 'fred');\n * greetFred('hi');\n * // => 'hi fred'\n *\n * // Partially applied with placeholders.\n * var sayHelloTo = _.partialRight(greet, 'hello', _);\n * sayHelloTo('fred');\n * // => 'hello fred'\n */\n var partialRight = baseRest(function(func, partials) {\n var holders = replaceHolders(partials, getHolder(partialRight));\n return createWrap(func, WRAP_PARTIAL_RIGHT_FLAG, undefined, partials, holders);\n });\n\n /**\n * Creates a function that invokes `func` with arguments arranged according\n * to the specified `indexes` where the argument value at the first index is\n * provided as the first argument, the argument value at the second index is\n * provided as the second argument, and so on.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Function\n * @param {Function} func The function to rearrange arguments for.\n * @param {...(number|number[])} indexes The arranged argument indexes.\n * @returns {Function} Returns the new function.\n * @example\n *\n * var rearged = _.rearg(function(a, b, c) {\n * return [a, b, c];\n * }, [2, 0, 1]);\n *\n * rearged('b', 'c', 'a')\n * // => ['a', 'b', 'c']\n */\n var rearg = flatRest(function(func, indexes) {\n return createWrap(func, WRAP_REARG_FLAG, undefined, undefined, undefined, indexes);\n });\n\n /**\n * Creates a function that invokes `func` with the `this` binding of the\n * created function and arguments from `start` and beyond provided as\n * an array.\n *\n * **Note:** This method is based on the\n * [rest parameter](https://mdn.io/rest_parameters).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Function\n * @param {Function} func The function to apply a rest parameter to.\n * @param {number} [start=func.length-1] The start position of the rest parameter.\n * @returns {Function} Returns the new function.\n * @example\n *\n * var say = _.rest(function(what, names) {\n * return what + ' ' + _.initial(names).join(', ') +\n * (_.size(names) > 1 ? ', & ' : '') + _.last(names);\n * });\n *\n * say('hello', 'fred', 'barney', 'pebbles');\n * // => 'hello fred, barney, & pebbles'\n */\n function rest(func, start) {\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n start = start === undefined ? start : toInteger(start);\n return baseRest(func, start);\n }\n\n /**\n * Creates a function that invokes `func` with the `this` binding of the\n * create function and an array of arguments much like\n * [`Function#apply`](http://www.ecma-international.org/ecma-262/7.0/#sec-function.prototype.apply).\n *\n * **Note:** This method is based on the\n * [spread operator](https://mdn.io/spread_operator).\n *\n * @static\n * @memberOf _\n * @since 3.2.0\n * @category Function\n * @param {Function} func The function to spread arguments over.\n * @param {number} [start=0] The start position of the spread.\n * @returns {Function} Returns the new function.\n * @example\n *\n * var say = _.spread(function(who, what) {\n * return who + ' says ' + what;\n * });\n *\n * say(['fred', 'hello']);\n * // => 'fred says hello'\n *\n * var numbers = Promise.all([\n * Promise.resolve(40),\n * Promise.resolve(36)\n * ]);\n *\n * numbers.then(_.spread(function(x, y) {\n * return x + y;\n * }));\n * // => a Promise of 76\n */\n function spread(func, start) {\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n start = start == null ? 0 : nativeMax(toInteger(start), 0);\n return baseRest(function(args) {\n var array = args[start],\n otherArgs = castSlice(args, 0, start);\n\n if (array) {\n arrayPush(otherArgs, array);\n }\n return apply(func, this, otherArgs);\n });\n }\n\n /**\n * Creates a throttled function that only invokes `func` at most once per\n * every `wait` milliseconds. The throttled function comes with a `cancel`\n * method to cancel delayed `func` invocations and a `flush` method to\n * immediately invoke them. Provide `options` to indicate whether `func`\n * should be invoked on the leading and/or trailing edge of the `wait`\n * timeout. The `func` is invoked with the last arguments provided to the\n * throttled function. Subsequent calls to the throttled function return the\n * result of the last `func` invocation.\n *\n * **Note:** If `leading` and `trailing` options are `true`, `func` is\n * invoked on the trailing edge of the timeout only if the throttled function\n * is invoked more than once during the `wait` timeout.\n *\n * If `wait` is `0` and `leading` is `false`, `func` invocation is deferred\n * until to the next tick, similar to `setTimeout` with a timeout of `0`.\n *\n * See [David Corbacho's article](https://css-tricks.com/debouncing-throttling-explained-examples/)\n * for details over the differences between `_.throttle` and `_.debounce`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {Function} func The function to throttle.\n * @param {number} [wait=0] The number of milliseconds to throttle invocations to.\n * @param {Object} [options={}] The options object.\n * @param {boolean} [options.leading=true]\n * Specify invoking on the leading edge of the timeout.\n * @param {boolean} [options.trailing=true]\n * Specify invoking on the trailing edge of the timeout.\n * @returns {Function} Returns the new throttled function.\n * @example\n *\n * // Avoid excessively updating the position while scrolling.\n * jQuery(window).on('scroll', _.throttle(updatePosition, 100));\n *\n * // Invoke `renewToken` when the click event is fired, but not more than once every 5 minutes.\n * var throttled = _.throttle(renewToken, 300000, { 'trailing': false });\n * jQuery(element).on('click', throttled);\n *\n * // Cancel the trailing throttled invocation.\n * jQuery(window).on('popstate', throttled.cancel);\n */\n function throttle(func, wait, options) {\n var leading = true,\n trailing = true;\n\n if (typeof func != 'function') {\n throw new TypeError(FUNC_ERROR_TEXT);\n }\n if (isObject(options)) {\n leading = 'leading' in options ? !!options.leading : leading;\n trailing = 'trailing' in options ? !!options.trailing : trailing;\n }\n return debounce(func, wait, {\n 'leading': leading,\n 'maxWait': wait,\n 'trailing': trailing\n });\n }\n\n /**\n * Creates a function that accepts up to one argument, ignoring any\n * additional arguments.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Function\n * @param {Function} func The function to cap arguments for.\n * @returns {Function} Returns the new capped function.\n * @example\n *\n * _.map(['6', '8', '10'], _.unary(parseInt));\n * // => [6, 8, 10]\n */\n function unary(func) {\n return ary(func, 1);\n }\n\n /**\n * Creates a function that provides `value` to `wrapper` as its first\n * argument. Any additional arguments provided to the function are appended\n * to those provided to the `wrapper`. The wrapper is invoked with the `this`\n * binding of the created function.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Function\n * @param {*} value The value to wrap.\n * @param {Function} [wrapper=identity] The wrapper function.\n * @returns {Function} Returns the new function.\n * @example\n *\n * var p = _.wrap(_.escape, function(func, text) {\n * return '

' + func(text) + '

';\n * });\n *\n * p('fred, barney, & pebbles');\n * // => '

fred, barney, & pebbles

'\n */\n function wrap(value, wrapper) {\n return partial(castFunction(wrapper), value);\n }\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Casts `value` as an array if it's not one.\n *\n * @static\n * @memberOf _\n * @since 4.4.0\n * @category Lang\n * @param {*} value The value to inspect.\n * @returns {Array} Returns the cast array.\n * @example\n *\n * _.castArray(1);\n * // => [1]\n *\n * _.castArray({ 'a': 1 });\n * // => [{ 'a': 1 }]\n *\n * _.castArray('abc');\n * // => ['abc']\n *\n * _.castArray(null);\n * // => [null]\n *\n * _.castArray(undefined);\n * // => [undefined]\n *\n * _.castArray();\n * // => []\n *\n * var array = [1, 2, 3];\n * console.log(_.castArray(array) === array);\n * // => true\n */\n function castArray() {\n if (!arguments.length) {\n return [];\n }\n var value = arguments[0];\n return isArray(value) ? value : [value];\n }\n\n /**\n * Creates a shallow clone of `value`.\n *\n * **Note:** This method is loosely based on the\n * [structured clone algorithm](https://mdn.io/Structured_clone_algorithm)\n * and supports cloning arrays, array buffers, booleans, date objects, maps,\n * numbers, `Object` objects, regexes, sets, strings, symbols, and typed\n * arrays. The own enumerable properties of `arguments` objects are cloned\n * as plain objects. An empty object is returned for uncloneable values such\n * as error objects, functions, DOM nodes, and WeakMaps.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to clone.\n * @returns {*} Returns the cloned value.\n * @see _.cloneDeep\n * @example\n *\n * var objects = [{ 'a': 1 }, { 'b': 2 }];\n *\n * var shallow = _.clone(objects);\n * console.log(shallow[0] === objects[0]);\n * // => true\n */\n function clone(value) {\n return baseClone(value, CLONE_SYMBOLS_FLAG);\n }\n\n /**\n * This method is like `_.clone` except that it accepts `customizer` which\n * is invoked to produce the cloned value. If `customizer` returns `undefined`,\n * cloning is handled by the method instead. The `customizer` is invoked with\n * up to four arguments; (value [, index|key, object, stack]).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to clone.\n * @param {Function} [customizer] The function to customize cloning.\n * @returns {*} Returns the cloned value.\n * @see _.cloneDeepWith\n * @example\n *\n * function customizer(value) {\n * if (_.isElement(value)) {\n * return value.cloneNode(false);\n * }\n * }\n *\n * var el = _.cloneWith(document.body, customizer);\n *\n * console.log(el === document.body);\n * // => false\n * console.log(el.nodeName);\n * // => 'BODY'\n * console.log(el.childNodes.length);\n * // => 0\n */\n function cloneWith(value, customizer) {\n customizer = typeof customizer == 'function' ? customizer : undefined;\n return baseClone(value, CLONE_SYMBOLS_FLAG, customizer);\n }\n\n /**\n * This method is like `_.clone` except that it recursively clones `value`.\n *\n * @static\n * @memberOf _\n * @since 1.0.0\n * @category Lang\n * @param {*} value The value to recursively clone.\n * @returns {*} Returns the deep cloned value.\n * @see _.clone\n * @example\n *\n * var objects = [{ 'a': 1 }, { 'b': 2 }];\n *\n * var deep = _.cloneDeep(objects);\n * console.log(deep[0] === objects[0]);\n * // => false\n */\n function cloneDeep(value) {\n return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG);\n }\n\n /**\n * This method is like `_.cloneWith` except that it recursively clones `value`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to recursively clone.\n * @param {Function} [customizer] The function to customize cloning.\n * @returns {*} Returns the deep cloned value.\n * @see _.cloneWith\n * @example\n *\n * function customizer(value) {\n * if (_.isElement(value)) {\n * return value.cloneNode(true);\n * }\n * }\n *\n * var el = _.cloneDeepWith(document.body, customizer);\n *\n * console.log(el === document.body);\n * // => false\n * console.log(el.nodeName);\n * // => 'BODY'\n * console.log(el.childNodes.length);\n * // => 20\n */\n function cloneDeepWith(value, customizer) {\n customizer = typeof customizer == 'function' ? customizer : undefined;\n return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG, customizer);\n }\n\n /**\n * Checks if `object` conforms to `source` by invoking the predicate\n * properties of `source` with the corresponding property values of `object`.\n *\n * **Note:** This method is equivalent to `_.conforms` when `source` is\n * partially applied.\n *\n * @static\n * @memberOf _\n * @since 4.14.0\n * @category Lang\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property predicates to conform to.\n * @returns {boolean} Returns `true` if `object` conforms, else `false`.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n *\n * _.conformsTo(object, { 'b': function(n) { return n > 1; } });\n * // => true\n *\n * _.conformsTo(object, { 'b': function(n) { return n > 2; } });\n * // => false\n */\n function conformsTo(object, source) {\n return source == null || baseConformsTo(object, source, keys(source));\n }\n\n /**\n * Performs a\n * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero)\n * comparison between two values to determine if they are equivalent.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.eq(object, object);\n * // => true\n *\n * _.eq(object, other);\n * // => false\n *\n * _.eq('a', 'a');\n * // => true\n *\n * _.eq('a', Object('a'));\n * // => false\n *\n * _.eq(NaN, NaN);\n * // => true\n */\n function eq(value, other) {\n return value === other || (value !== value && other !== other);\n }\n\n /**\n * Checks if `value` is greater than `other`.\n *\n * @static\n * @memberOf _\n * @since 3.9.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if `value` is greater than `other`,\n * else `false`.\n * @see _.lt\n * @example\n *\n * _.gt(3, 1);\n * // => true\n *\n * _.gt(3, 3);\n * // => false\n *\n * _.gt(1, 3);\n * // => false\n */\n var gt = createRelationalOperation(baseGt);\n\n /**\n * Checks if `value` is greater than or equal to `other`.\n *\n * @static\n * @memberOf _\n * @since 3.9.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if `value` is greater than or equal to\n * `other`, else `false`.\n * @see _.lte\n * @example\n *\n * _.gte(3, 1);\n * // => true\n *\n * _.gte(3, 3);\n * // => true\n *\n * _.gte(1, 3);\n * // => false\n */\n var gte = createRelationalOperation(function(value, other) {\n return value >= other;\n });\n\n /**\n * Checks if `value` is likely an `arguments` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an `arguments` object,\n * else `false`.\n * @example\n *\n * _.isArguments(function() { return arguments; }());\n * // => true\n *\n * _.isArguments([1, 2, 3]);\n * // => false\n */\n var isArguments = baseIsArguments(function() { return arguments; }()) ? baseIsArguments : function(value) {\n return isObjectLike(value) && hasOwnProperty.call(value, 'callee') &&\n !propertyIsEnumerable.call(value, 'callee');\n };\n\n /**\n * Checks if `value` is classified as an `Array` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array, else `false`.\n * @example\n *\n * _.isArray([1, 2, 3]);\n * // => true\n *\n * _.isArray(document.body.children);\n * // => false\n *\n * _.isArray('abc');\n * // => false\n *\n * _.isArray(_.noop);\n * // => false\n */\n var isArray = Array.isArray;\n\n /**\n * Checks if `value` is classified as an `ArrayBuffer` object.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array buffer, else `false`.\n * @example\n *\n * _.isArrayBuffer(new ArrayBuffer(2));\n * // => true\n *\n * _.isArrayBuffer(new Array(2));\n * // => false\n */\n var isArrayBuffer = nodeIsArrayBuffer ? baseUnary(nodeIsArrayBuffer) : baseIsArrayBuffer;\n\n /**\n * Checks if `value` is array-like. A value is considered array-like if it's\n * not a function and has a `value.length` that's an integer greater than or\n * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is array-like, else `false`.\n * @example\n *\n * _.isArrayLike([1, 2, 3]);\n * // => true\n *\n * _.isArrayLike(document.body.children);\n * // => true\n *\n * _.isArrayLike('abc');\n * // => true\n *\n * _.isArrayLike(_.noop);\n * // => false\n */\n function isArrayLike(value) {\n return value != null && isLength(value.length) && !isFunction(value);\n }\n\n /**\n * This method is like `_.isArrayLike` except that it also checks if `value`\n * is an object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an array-like object,\n * else `false`.\n * @example\n *\n * _.isArrayLikeObject([1, 2, 3]);\n * // => true\n *\n * _.isArrayLikeObject(document.body.children);\n * // => true\n *\n * _.isArrayLikeObject('abc');\n * // => false\n *\n * _.isArrayLikeObject(_.noop);\n * // => false\n */\n function isArrayLikeObject(value) {\n return isObjectLike(value) && isArrayLike(value);\n }\n\n /**\n * Checks if `value` is classified as a boolean primitive or object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a boolean, else `false`.\n * @example\n *\n * _.isBoolean(false);\n * // => true\n *\n * _.isBoolean(null);\n * // => false\n */\n function isBoolean(value) {\n return value === true || value === false ||\n (isObjectLike(value) && baseGetTag(value) == boolTag);\n }\n\n /**\n * Checks if `value` is a buffer.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a buffer, else `false`.\n * @example\n *\n * _.isBuffer(new Buffer(2));\n * // => true\n *\n * _.isBuffer(new Uint8Array(2));\n * // => false\n */\n var isBuffer = nativeIsBuffer || stubFalse;\n\n /**\n * Checks if `value` is classified as a `Date` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a date object, else `false`.\n * @example\n *\n * _.isDate(new Date);\n * // => true\n *\n * _.isDate('Mon April 23 2012');\n * // => false\n */\n var isDate = nodeIsDate ? baseUnary(nodeIsDate) : baseIsDate;\n\n /**\n * Checks if `value` is likely a DOM element.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a DOM element, else `false`.\n * @example\n *\n * _.isElement(document.body);\n * // => true\n *\n * _.isElement('');\n * // => false\n */\n function isElement(value) {\n return isObjectLike(value) && value.nodeType === 1 && !isPlainObject(value);\n }\n\n /**\n * Checks if `value` is an empty object, collection, map, or set.\n *\n * Objects are considered empty if they have no own enumerable string keyed\n * properties.\n *\n * Array-like values such as `arguments` objects, arrays, buffers, strings, or\n * jQuery-like collections are considered empty if they have a `length` of `0`.\n * Similarly, maps and sets are considered empty if they have a `size` of `0`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is empty, else `false`.\n * @example\n *\n * _.isEmpty(null);\n * // => true\n *\n * _.isEmpty(true);\n * // => true\n *\n * _.isEmpty(1);\n * // => true\n *\n * _.isEmpty([1, 2, 3]);\n * // => false\n *\n * _.isEmpty({ 'a': 1 });\n * // => false\n */\n function isEmpty(value) {\n if (value == null) {\n return true;\n }\n if (isArrayLike(value) &&\n (isArray(value) || typeof value == 'string' || typeof value.splice == 'function' ||\n isBuffer(value) || isTypedArray(value) || isArguments(value))) {\n return !value.length;\n }\n var tag = getTag(value);\n if (tag == mapTag || tag == setTag) {\n return !value.size;\n }\n if (isPrototype(value)) {\n return !baseKeys(value).length;\n }\n for (var key in value) {\n if (hasOwnProperty.call(value, key)) {\n return false;\n }\n }\n return true;\n }\n\n /**\n * Performs a deep comparison between two values to determine if they are\n * equivalent.\n *\n * **Note:** This method supports comparing arrays, array buffers, booleans,\n * date objects, error objects, maps, numbers, `Object` objects, regexes,\n * sets, strings, symbols, and typed arrays. `Object` objects are compared\n * by their own, not inherited, enumerable properties. Functions and DOM\n * nodes are compared by strict equality, i.e. `===`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * var object = { 'a': 1 };\n * var other = { 'a': 1 };\n *\n * _.isEqual(object, other);\n * // => true\n *\n * object === other;\n * // => false\n */\n function isEqual(value, other) {\n return baseIsEqual(value, other);\n }\n\n /**\n * This method is like `_.isEqual` except that it accepts `customizer` which\n * is invoked to compare values. If `customizer` returns `undefined`, comparisons\n * are handled by the method instead. The `customizer` is invoked with up to\n * six arguments: (objValue, othValue [, index|key, object, other, stack]).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @param {Function} [customizer] The function to customize comparisons.\n * @returns {boolean} Returns `true` if the values are equivalent, else `false`.\n * @example\n *\n * function isGreeting(value) {\n * return /^h(?:i|ello)$/.test(value);\n * }\n *\n * function customizer(objValue, othValue) {\n * if (isGreeting(objValue) && isGreeting(othValue)) {\n * return true;\n * }\n * }\n *\n * var array = ['hello', 'goodbye'];\n * var other = ['hi', 'goodbye'];\n *\n * _.isEqualWith(array, other, customizer);\n * // => true\n */\n function isEqualWith(value, other, customizer) {\n customizer = typeof customizer == 'function' ? customizer : undefined;\n var result = customizer ? customizer(value, other) : undefined;\n return result === undefined ? baseIsEqual(value, other, undefined, customizer) : !!result;\n }\n\n /**\n * Checks if `value` is an `Error`, `EvalError`, `RangeError`, `ReferenceError`,\n * `SyntaxError`, `TypeError`, or `URIError` object.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an error object, else `false`.\n * @example\n *\n * _.isError(new Error);\n * // => true\n *\n * _.isError(Error);\n * // => false\n */\n function isError(value) {\n if (!isObjectLike(value)) {\n return false;\n }\n var tag = baseGetTag(value);\n return tag == errorTag || tag == domExcTag ||\n (typeof value.message == 'string' && typeof value.name == 'string' && !isPlainObject(value));\n }\n\n /**\n * Checks if `value` is a finite primitive number.\n *\n * **Note:** This method is based on\n * [`Number.isFinite`](https://mdn.io/Number/isFinite).\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a finite number, else `false`.\n * @example\n *\n * _.isFinite(3);\n * // => true\n *\n * _.isFinite(Number.MIN_VALUE);\n * // => true\n *\n * _.isFinite(Infinity);\n * // => false\n *\n * _.isFinite('3');\n * // => false\n */\n function isFinite(value) {\n return typeof value == 'number' && nativeIsFinite(value);\n }\n\n /**\n * Checks if `value` is classified as a `Function` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a function, else `false`.\n * @example\n *\n * _.isFunction(_);\n * // => true\n *\n * _.isFunction(/abc/);\n * // => false\n */\n function isFunction(value) {\n if (!isObject(value)) {\n return false;\n }\n // The use of `Object#toString` avoids issues with the `typeof` operator\n // in Safari 9 which returns 'object' for typed arrays and other constructors.\n var tag = baseGetTag(value);\n return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;\n }\n\n /**\n * Checks if `value` is an integer.\n *\n * **Note:** This method is based on\n * [`Number.isInteger`](https://mdn.io/Number/isInteger).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an integer, else `false`.\n * @example\n *\n * _.isInteger(3);\n * // => true\n *\n * _.isInteger(Number.MIN_VALUE);\n * // => false\n *\n * _.isInteger(Infinity);\n * // => false\n *\n * _.isInteger('3');\n * // => false\n */\n function isInteger(value) {\n return typeof value == 'number' && value == toInteger(value);\n }\n\n /**\n * Checks if `value` is a valid array-like length.\n *\n * **Note:** This method is loosely based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a valid length, else `false`.\n * @example\n *\n * _.isLength(3);\n * // => true\n *\n * _.isLength(Number.MIN_VALUE);\n * // => false\n *\n * _.isLength(Infinity);\n * // => false\n *\n * _.isLength('3');\n * // => false\n */\n function isLength(value) {\n return typeof value == 'number' &&\n value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;\n }\n\n /**\n * Checks if `value` is the\n * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types)\n * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`)\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is an object, else `false`.\n * @example\n *\n * _.isObject({});\n * // => true\n *\n * _.isObject([1, 2, 3]);\n * // => true\n *\n * _.isObject(_.noop);\n * // => true\n *\n * _.isObject(null);\n * // => false\n */\n function isObject(value) {\n var type = typeof value;\n return value != null && (type == 'object' || type == 'function');\n }\n\n /**\n * Checks if `value` is object-like. A value is object-like if it's not `null`\n * and has a `typeof` result of \"object\".\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is object-like, else `false`.\n * @example\n *\n * _.isObjectLike({});\n * // => true\n *\n * _.isObjectLike([1, 2, 3]);\n * // => true\n *\n * _.isObjectLike(_.noop);\n * // => false\n *\n * _.isObjectLike(null);\n * // => false\n */\n function isObjectLike(value) {\n return value != null && typeof value == 'object';\n }\n\n /**\n * Checks if `value` is classified as a `Map` object.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a map, else `false`.\n * @example\n *\n * _.isMap(new Map);\n * // => true\n *\n * _.isMap(new WeakMap);\n * // => false\n */\n var isMap = nodeIsMap ? baseUnary(nodeIsMap) : baseIsMap;\n\n /**\n * Performs a partial deep comparison between `object` and `source` to\n * determine if `object` contains equivalent property values.\n *\n * **Note:** This method is equivalent to `_.matches` when `source` is\n * partially applied.\n *\n * Partial comparisons will match empty array and empty object `source`\n * values against any array or object value, respectively. See `_.isEqual`\n * for a list of supported value comparisons.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property values to match.\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\n * @example\n *\n * var object = { 'a': 1, 'b': 2 };\n *\n * _.isMatch(object, { 'b': 2 });\n * // => true\n *\n * _.isMatch(object, { 'b': 1 });\n * // => false\n */\n function isMatch(object, source) {\n return object === source || baseIsMatch(object, source, getMatchData(source));\n }\n\n /**\n * This method is like `_.isMatch` except that it accepts `customizer` which\n * is invoked to compare values. If `customizer` returns `undefined`, comparisons\n * are handled by the method instead. The `customizer` is invoked with five\n * arguments: (objValue, srcValue, index|key, object, source).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {Object} object The object to inspect.\n * @param {Object} source The object of property values to match.\n * @param {Function} [customizer] The function to customize comparisons.\n * @returns {boolean} Returns `true` if `object` is a match, else `false`.\n * @example\n *\n * function isGreeting(value) {\n * return /^h(?:i|ello)$/.test(value);\n * }\n *\n * function customizer(objValue, srcValue) {\n * if (isGreeting(objValue) && isGreeting(srcValue)) {\n * return true;\n * }\n * }\n *\n * var object = { 'greeting': 'hello' };\n * var source = { 'greeting': 'hi' };\n *\n * _.isMatchWith(object, source, customizer);\n * // => true\n */\n function isMatchWith(object, source, customizer) {\n customizer = typeof customizer == 'function' ? customizer : undefined;\n return baseIsMatch(object, source, getMatchData(source), customizer);\n }\n\n /**\n * Checks if `value` is `NaN`.\n *\n * **Note:** This method is based on\n * [`Number.isNaN`](https://mdn.io/Number/isNaN) and is not the same as\n * global [`isNaN`](https://mdn.io/isNaN) which returns `true` for\n * `undefined` and other non-number values.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`.\n * @example\n *\n * _.isNaN(NaN);\n * // => true\n *\n * _.isNaN(new Number(NaN));\n * // => true\n *\n * isNaN(undefined);\n * // => true\n *\n * _.isNaN(undefined);\n * // => false\n */\n function isNaN(value) {\n // An `NaN` primitive is the only value that is not equal to itself.\n // Perform the `toStringTag` check first to avoid errors with some\n // ActiveX objects in IE.\n return isNumber(value) && value != +value;\n }\n\n /**\n * Checks if `value` is a pristine native function.\n *\n * **Note:** This method can't reliably detect native functions in the presence\n * of the core-js package because core-js circumvents this kind of detection.\n * Despite multiple requests, the core-js maintainer has made it clear: any\n * attempt to fix the detection will be obstructed. As a result, we're left\n * with little choice but to throw an error. Unfortunately, this also affects\n * packages, like [babel-polyfill](https://www.npmjs.com/package/babel-polyfill),\n * which rely on core-js.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a native function,\n * else `false`.\n * @example\n *\n * _.isNative(Array.prototype.push);\n * // => true\n *\n * _.isNative(_);\n * // => false\n */\n function isNative(value) {\n if (isMaskable(value)) {\n throw new Error(CORE_ERROR_TEXT);\n }\n return baseIsNative(value);\n }\n\n /**\n * Checks if `value` is `null`.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is `null`, else `false`.\n * @example\n *\n * _.isNull(null);\n * // => true\n *\n * _.isNull(void 0);\n * // => false\n */\n function isNull(value) {\n return value === null;\n }\n\n /**\n * Checks if `value` is `null` or `undefined`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is nullish, else `false`.\n * @example\n *\n * _.isNil(null);\n * // => true\n *\n * _.isNil(void 0);\n * // => true\n *\n * _.isNil(NaN);\n * // => false\n */\n function isNil(value) {\n return value == null;\n }\n\n /**\n * Checks if `value` is classified as a `Number` primitive or object.\n *\n * **Note:** To exclude `Infinity`, `-Infinity`, and `NaN`, which are\n * classified as numbers, use the `_.isFinite` method.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a number, else `false`.\n * @example\n *\n * _.isNumber(3);\n * // => true\n *\n * _.isNumber(Number.MIN_VALUE);\n * // => true\n *\n * _.isNumber(Infinity);\n * // => true\n *\n * _.isNumber('3');\n * // => false\n */\n function isNumber(value) {\n return typeof value == 'number' ||\n (isObjectLike(value) && baseGetTag(value) == numberTag);\n }\n\n /**\n * Checks if `value` is a plain object, that is, an object created by the\n * `Object` constructor or one with a `[[Prototype]]` of `null`.\n *\n * @static\n * @memberOf _\n * @since 0.8.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a plain object, else `false`.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * }\n *\n * _.isPlainObject(new Foo);\n * // => false\n *\n * _.isPlainObject([1, 2, 3]);\n * // => false\n *\n * _.isPlainObject({ 'x': 0, 'y': 0 });\n * // => true\n *\n * _.isPlainObject(Object.create(null));\n * // => true\n */\n function isPlainObject(value) {\n if (!isObjectLike(value) || baseGetTag(value) != objectTag) {\n return false;\n }\n var proto = getPrototype(value);\n if (proto === null) {\n return true;\n }\n var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor;\n return typeof Ctor == 'function' && Ctor instanceof Ctor &&\n funcToString.call(Ctor) == objectCtorString;\n }\n\n /**\n * Checks if `value` is classified as a `RegExp` object.\n *\n * @static\n * @memberOf _\n * @since 0.1.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a regexp, else `false`.\n * @example\n *\n * _.isRegExp(/abc/);\n * // => true\n *\n * _.isRegExp('/abc/');\n * // => false\n */\n var isRegExp = nodeIsRegExp ? baseUnary(nodeIsRegExp) : baseIsRegExp;\n\n /**\n * Checks if `value` is a safe integer. An integer is safe if it's an IEEE-754\n * double precision number which isn't the result of a rounded unsafe integer.\n *\n * **Note:** This method is based on\n * [`Number.isSafeInteger`](https://mdn.io/Number/isSafeInteger).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a safe integer, else `false`.\n * @example\n *\n * _.isSafeInteger(3);\n * // => true\n *\n * _.isSafeInteger(Number.MIN_VALUE);\n * // => false\n *\n * _.isSafeInteger(Infinity);\n * // => false\n *\n * _.isSafeInteger('3');\n * // => false\n */\n function isSafeInteger(value) {\n return isInteger(value) && value >= -MAX_SAFE_INTEGER && value <= MAX_SAFE_INTEGER;\n }\n\n /**\n * Checks if `value` is classified as a `Set` object.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a set, else `false`.\n * @example\n *\n * _.isSet(new Set);\n * // => true\n *\n * _.isSet(new WeakSet);\n * // => false\n */\n var isSet = nodeIsSet ? baseUnary(nodeIsSet) : baseIsSet;\n\n /**\n * Checks if `value` is classified as a `String` primitive or object.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a string, else `false`.\n * @example\n *\n * _.isString('abc');\n * // => true\n *\n * _.isString(1);\n * // => false\n */\n function isString(value) {\n return typeof value == 'string' ||\n (!isArray(value) && isObjectLike(value) && baseGetTag(value) == stringTag);\n }\n\n /**\n * Checks if `value` is classified as a `Symbol` primitive or object.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a symbol, else `false`.\n * @example\n *\n * _.isSymbol(Symbol.iterator);\n * // => true\n *\n * _.isSymbol('abc');\n * // => false\n */\n function isSymbol(value) {\n return typeof value == 'symbol' ||\n (isObjectLike(value) && baseGetTag(value) == symbolTag);\n }\n\n /**\n * Checks if `value` is classified as a typed array.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a typed array, else `false`.\n * @example\n *\n * _.isTypedArray(new Uint8Array);\n * // => true\n *\n * _.isTypedArray([]);\n * // => false\n */\n var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;\n\n /**\n * Checks if `value` is `undefined`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is `undefined`, else `false`.\n * @example\n *\n * _.isUndefined(void 0);\n * // => true\n *\n * _.isUndefined(null);\n * // => false\n */\n function isUndefined(value) {\n return value === undefined;\n }\n\n /**\n * Checks if `value` is classified as a `WeakMap` object.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a weak map, else `false`.\n * @example\n *\n * _.isWeakMap(new WeakMap);\n * // => true\n *\n * _.isWeakMap(new Map);\n * // => false\n */\n function isWeakMap(value) {\n return isObjectLike(value) && getTag(value) == weakMapTag;\n }\n\n /**\n * Checks if `value` is classified as a `WeakSet` object.\n *\n * @static\n * @memberOf _\n * @since 4.3.0\n * @category Lang\n * @param {*} value The value to check.\n * @returns {boolean} Returns `true` if `value` is a weak set, else `false`.\n * @example\n *\n * _.isWeakSet(new WeakSet);\n * // => true\n *\n * _.isWeakSet(new Set);\n * // => false\n */\n function isWeakSet(value) {\n return isObjectLike(value) && baseGetTag(value) == weakSetTag;\n }\n\n /**\n * Checks if `value` is less than `other`.\n *\n * @static\n * @memberOf _\n * @since 3.9.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if `value` is less than `other`,\n * else `false`.\n * @see _.gt\n * @example\n *\n * _.lt(1, 3);\n * // => true\n *\n * _.lt(3, 3);\n * // => false\n *\n * _.lt(3, 1);\n * // => false\n */\n var lt = createRelationalOperation(baseLt);\n\n /**\n * Checks if `value` is less than or equal to `other`.\n *\n * @static\n * @memberOf _\n * @since 3.9.0\n * @category Lang\n * @param {*} value The value to compare.\n * @param {*} other The other value to compare.\n * @returns {boolean} Returns `true` if `value` is less than or equal to\n * `other`, else `false`.\n * @see _.gte\n * @example\n *\n * _.lte(1, 3);\n * // => true\n *\n * _.lte(3, 3);\n * // => true\n *\n * _.lte(3, 1);\n * // => false\n */\n var lte = createRelationalOperation(function(value, other) {\n return value <= other;\n });\n\n /**\n * Converts `value` to an array.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {Array} Returns the converted array.\n * @example\n *\n * _.toArray({ 'a': 1, 'b': 2 });\n * // => [1, 2]\n *\n * _.toArray('abc');\n * // => ['a', 'b', 'c']\n *\n * _.toArray(1);\n * // => []\n *\n * _.toArray(null);\n * // => []\n */\n function toArray(value) {\n if (!value) {\n return [];\n }\n if (isArrayLike(value)) {\n return isString(value) ? stringToArray(value) : copyArray(value);\n }\n if (symIterator && value[symIterator]) {\n return iteratorToArray(value[symIterator]());\n }\n var tag = getTag(value),\n func = tag == mapTag ? mapToArray : (tag == setTag ? setToArray : values);\n\n return func(value);\n }\n\n /**\n * Converts `value` to a finite number.\n *\n * @static\n * @memberOf _\n * @since 4.12.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {number} Returns the converted number.\n * @example\n *\n * _.toFinite(3.2);\n * // => 3.2\n *\n * _.toFinite(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toFinite(Infinity);\n * // => 1.7976931348623157e+308\n *\n * _.toFinite('3.2');\n * // => 3.2\n */\n function toFinite(value) {\n if (!value) {\n return value === 0 ? value : 0;\n }\n value = toNumber(value);\n if (value === INFINITY || value === -INFINITY) {\n var sign = (value < 0 ? -1 : 1);\n return sign * MAX_INTEGER;\n }\n return value === value ? value : 0;\n }\n\n /**\n * Converts `value` to an integer.\n *\n * **Note:** This method is loosely based on\n * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {number} Returns the converted integer.\n * @example\n *\n * _.toInteger(3.2);\n * // => 3\n *\n * _.toInteger(Number.MIN_VALUE);\n * // => 0\n *\n * _.toInteger(Infinity);\n * // => 1.7976931348623157e+308\n *\n * _.toInteger('3.2');\n * // => 3\n */\n function toInteger(value) {\n var result = toFinite(value),\n remainder = result % 1;\n\n return result === result ? (remainder ? result - remainder : result) : 0;\n }\n\n /**\n * Converts `value` to an integer suitable for use as the length of an\n * array-like object.\n *\n * **Note:** This method is based on\n * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {number} Returns the converted integer.\n * @example\n *\n * _.toLength(3.2);\n * // => 3\n *\n * _.toLength(Number.MIN_VALUE);\n * // => 0\n *\n * _.toLength(Infinity);\n * // => 4294967295\n *\n * _.toLength('3.2');\n * // => 3\n */\n function toLength(value) {\n return value ? baseClamp(toInteger(value), 0, MAX_ARRAY_LENGTH) : 0;\n }\n\n /**\n * Converts `value` to a number.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to process.\n * @returns {number} Returns the number.\n * @example\n *\n * _.toNumber(3.2);\n * // => 3.2\n *\n * _.toNumber(Number.MIN_VALUE);\n * // => 5e-324\n *\n * _.toNumber(Infinity);\n * // => Infinity\n *\n * _.toNumber('3.2');\n * // => 3.2\n */\n function toNumber(value) {\n if (typeof value == 'number') {\n return value;\n }\n if (isSymbol(value)) {\n return NAN;\n }\n if (isObject(value)) {\n var other = typeof value.valueOf == 'function' ? value.valueOf() : value;\n value = isObject(other) ? (other + '') : other;\n }\n if (typeof value != 'string') {\n return value === 0 ? value : +value;\n }\n value = baseTrim(value);\n var isBinary = reIsBinary.test(value);\n return (isBinary || reIsOctal.test(value))\n ? freeParseInt(value.slice(2), isBinary ? 2 : 8)\n : (reIsBadHex.test(value) ? NAN : +value);\n }\n\n /**\n * Converts `value` to a plain object flattening inherited enumerable string\n * keyed properties of `value` to own properties of the plain object.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {Object} Returns the converted plain object.\n * @example\n *\n * function Foo() {\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.assign({ 'a': 1 }, new Foo);\n * // => { 'a': 1, 'b': 2 }\n *\n * _.assign({ 'a': 1 }, _.toPlainObject(new Foo));\n * // => { 'a': 1, 'b': 2, 'c': 3 }\n */\n function toPlainObject(value) {\n return copyObject(value, keysIn(value));\n }\n\n /**\n * Converts `value` to a safe integer. A safe integer can be compared and\n * represented correctly.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {number} Returns the converted integer.\n * @example\n *\n * _.toSafeInteger(3.2);\n * // => 3\n *\n * _.toSafeInteger(Number.MIN_VALUE);\n * // => 0\n *\n * _.toSafeInteger(Infinity);\n * // => 9007199254740991\n *\n * _.toSafeInteger('3.2');\n * // => 3\n */\n function toSafeInteger(value) {\n return value\n ? baseClamp(toInteger(value), -MAX_SAFE_INTEGER, MAX_SAFE_INTEGER)\n : (value === 0 ? value : 0);\n }\n\n /**\n * Converts `value` to a string. An empty string is returned for `null`\n * and `undefined` values. The sign of `-0` is preserved.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Lang\n * @param {*} value The value to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.toString(null);\n * // => ''\n *\n * _.toString(-0);\n * // => '-0'\n *\n * _.toString([1, 2, 3]);\n * // => '1,2,3'\n */\n function toString(value) {\n return value == null ? '' : baseToString(value);\n }\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Assigns own enumerable string keyed properties of source objects to the\n * destination object. Source objects are applied from left to right.\n * Subsequent sources overwrite property assignments of previous sources.\n *\n * **Note:** This method mutates `object` and is loosely based on\n * [`Object.assign`](https://mdn.io/Object/assign).\n *\n * @static\n * @memberOf _\n * @since 0.10.0\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} [sources] The source objects.\n * @returns {Object} Returns `object`.\n * @see _.assignIn\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * }\n *\n * function Bar() {\n * this.c = 3;\n * }\n *\n * Foo.prototype.b = 2;\n * Bar.prototype.d = 4;\n *\n * _.assign({ 'a': 0 }, new Foo, new Bar);\n * // => { 'a': 1, 'c': 3 }\n */\n var assign = createAssigner(function(object, source) {\n if (isPrototype(source) || isArrayLike(source)) {\n copyObject(source, keys(source), object);\n return;\n }\n for (var key in source) {\n if (hasOwnProperty.call(source, key)) {\n assignValue(object, key, source[key]);\n }\n }\n });\n\n /**\n * This method is like `_.assign` except that it iterates over own and\n * inherited source properties.\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @alias extend\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} [sources] The source objects.\n * @returns {Object} Returns `object`.\n * @see _.assign\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * }\n *\n * function Bar() {\n * this.c = 3;\n * }\n *\n * Foo.prototype.b = 2;\n * Bar.prototype.d = 4;\n *\n * _.assignIn({ 'a': 0 }, new Foo, new Bar);\n * // => { 'a': 1, 'b': 2, 'c': 3, 'd': 4 }\n */\n var assignIn = createAssigner(function(object, source) {\n copyObject(source, keysIn(source), object);\n });\n\n /**\n * This method is like `_.assignIn` except that it accepts `customizer`\n * which is invoked to produce the assigned values. If `customizer` returns\n * `undefined`, assignment is handled by the method instead. The `customizer`\n * is invoked with five arguments: (objValue, srcValue, key, object, source).\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @alias extendWith\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} sources The source objects.\n * @param {Function} [customizer] The function to customize assigned values.\n * @returns {Object} Returns `object`.\n * @see _.assignWith\n * @example\n *\n * function customizer(objValue, srcValue) {\n * return _.isUndefined(objValue) ? srcValue : objValue;\n * }\n *\n * var defaults = _.partialRight(_.assignInWith, customizer);\n *\n * defaults({ 'a': 1 }, { 'b': 2 }, { 'a': 3 });\n * // => { 'a': 1, 'b': 2 }\n */\n var assignInWith = createAssigner(function(object, source, srcIndex, customizer) {\n copyObject(source, keysIn(source), object, customizer);\n });\n\n /**\n * This method is like `_.assign` except that it accepts `customizer`\n * which is invoked to produce the assigned values. If `customizer` returns\n * `undefined`, assignment is handled by the method instead. The `customizer`\n * is invoked with five arguments: (objValue, srcValue, key, object, source).\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} sources The source objects.\n * @param {Function} [customizer] The function to customize assigned values.\n * @returns {Object} Returns `object`.\n * @see _.assignInWith\n * @example\n *\n * function customizer(objValue, srcValue) {\n * return _.isUndefined(objValue) ? srcValue : objValue;\n * }\n *\n * var defaults = _.partialRight(_.assignWith, customizer);\n *\n * defaults({ 'a': 1 }, { 'b': 2 }, { 'a': 3 });\n * // => { 'a': 1, 'b': 2 }\n */\n var assignWith = createAssigner(function(object, source, srcIndex, customizer) {\n copyObject(source, keys(source), object, customizer);\n });\n\n /**\n * Creates an array of values corresponding to `paths` of `object`.\n *\n * @static\n * @memberOf _\n * @since 1.0.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {...(string|string[])} [paths] The property paths to pick.\n * @returns {Array} Returns the picked values.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }, 4] };\n *\n * _.at(object, ['a[0].b.c', 'a[1]']);\n * // => [3, 4]\n */\n var at = flatRest(baseAt);\n\n /**\n * Creates an object that inherits from the `prototype` object. If a\n * `properties` object is given, its own enumerable string keyed properties\n * are assigned to the created object.\n *\n * @static\n * @memberOf _\n * @since 2.3.0\n * @category Object\n * @param {Object} prototype The object to inherit from.\n * @param {Object} [properties] The properties to assign to the object.\n * @returns {Object} Returns the new object.\n * @example\n *\n * function Shape() {\n * this.x = 0;\n * this.y = 0;\n * }\n *\n * function Circle() {\n * Shape.call(this);\n * }\n *\n * Circle.prototype = _.create(Shape.prototype, {\n * 'constructor': Circle\n * });\n *\n * var circle = new Circle;\n * circle instanceof Circle;\n * // => true\n *\n * circle instanceof Shape;\n * // => true\n */\n function create(prototype, properties) {\n var result = baseCreate(prototype);\n return properties == null ? result : baseAssign(result, properties);\n }\n\n /**\n * Assigns own and inherited enumerable string keyed properties of source\n * objects to the destination object for all destination properties that\n * resolve to `undefined`. Source objects are applied from left to right.\n * Once a property is set, additional values of the same property are ignored.\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} [sources] The source objects.\n * @returns {Object} Returns `object`.\n * @see _.defaultsDeep\n * @example\n *\n * _.defaults({ 'a': 1 }, { 'b': 2 }, { 'a': 3 });\n * // => { 'a': 1, 'b': 2 }\n */\n var defaults = baseRest(function(object, sources) {\n object = Object(object);\n\n var index = -1;\n var length = sources.length;\n var guard = length > 2 ? sources[2] : undefined;\n\n if (guard && isIterateeCall(sources[0], sources[1], guard)) {\n length = 1;\n }\n\n while (++index < length) {\n var source = sources[index];\n var props = keysIn(source);\n var propsIndex = -1;\n var propsLength = props.length;\n\n while (++propsIndex < propsLength) {\n var key = props[propsIndex];\n var value = object[key];\n\n if (value === undefined ||\n (eq(value, objectProto[key]) && !hasOwnProperty.call(object, key))) {\n object[key] = source[key];\n }\n }\n }\n\n return object;\n });\n\n /**\n * This method is like `_.defaults` except that it recursively assigns\n * default properties.\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 3.10.0\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} [sources] The source objects.\n * @returns {Object} Returns `object`.\n * @see _.defaults\n * @example\n *\n * _.defaultsDeep({ 'a': { 'b': 2 } }, { 'a': { 'b': 1, 'c': 3 } });\n * // => { 'a': { 'b': 2, 'c': 3 } }\n */\n var defaultsDeep = baseRest(function(args) {\n args.push(undefined, customDefaultsMerge);\n return apply(mergeWith, undefined, args);\n });\n\n /**\n * This method is like `_.find` except that it returns the key of the first\n * element `predicate` returns truthy for instead of the element itself.\n *\n * @static\n * @memberOf _\n * @since 1.1.0\n * @category Object\n * @param {Object} object The object to inspect.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @returns {string|undefined} Returns the key of the matched element,\n * else `undefined`.\n * @example\n *\n * var users = {\n * 'barney': { 'age': 36, 'active': true },\n * 'fred': { 'age': 40, 'active': false },\n * 'pebbles': { 'age': 1, 'active': true }\n * };\n *\n * _.findKey(users, function(o) { return o.age < 40; });\n * // => 'barney' (iteration order is not guaranteed)\n *\n * // The `_.matches` iteratee shorthand.\n * _.findKey(users, { 'age': 1, 'active': true });\n * // => 'pebbles'\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.findKey(users, ['active', false]);\n * // => 'fred'\n *\n * // The `_.property` iteratee shorthand.\n * _.findKey(users, 'active');\n * // => 'barney'\n */\n function findKey(object, predicate) {\n return baseFindKey(object, getIteratee(predicate, 3), baseForOwn);\n }\n\n /**\n * This method is like `_.findKey` except that it iterates over elements of\n * a collection in the opposite order.\n *\n * @static\n * @memberOf _\n * @since 2.0.0\n * @category Object\n * @param {Object} object The object to inspect.\n * @param {Function} [predicate=_.identity] The function invoked per iteration.\n * @returns {string|undefined} Returns the key of the matched element,\n * else `undefined`.\n * @example\n *\n * var users = {\n * 'barney': { 'age': 36, 'active': true },\n * 'fred': { 'age': 40, 'active': false },\n * 'pebbles': { 'age': 1, 'active': true }\n * };\n *\n * _.findLastKey(users, function(o) { return o.age < 40; });\n * // => returns 'pebbles' assuming `_.findKey` returns 'barney'\n *\n * // The `_.matches` iteratee shorthand.\n * _.findLastKey(users, { 'age': 36, 'active': true });\n * // => 'barney'\n *\n * // The `_.matchesProperty` iteratee shorthand.\n * _.findLastKey(users, ['active', false]);\n * // => 'fred'\n *\n * // The `_.property` iteratee shorthand.\n * _.findLastKey(users, 'active');\n * // => 'pebbles'\n */\n function findLastKey(object, predicate) {\n return baseFindKey(object, getIteratee(predicate, 3), baseForOwnRight);\n }\n\n /**\n * Iterates over own and inherited enumerable string keyed properties of an\n * object and invokes `iteratee` for each property. The iteratee is invoked\n * with three arguments: (value, key, object). Iteratee functions may exit\n * iteration early by explicitly returning `false`.\n *\n * @static\n * @memberOf _\n * @since 0.3.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns `object`.\n * @see _.forInRight\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.forIn(new Foo, function(value, key) {\n * console.log(key);\n * });\n * // => Logs 'a', 'b', then 'c' (iteration order is not guaranteed).\n */\n function forIn(object, iteratee) {\n return object == null\n ? object\n : baseFor(object, getIteratee(iteratee, 3), keysIn);\n }\n\n /**\n * This method is like `_.forIn` except that it iterates over properties of\n * `object` in the opposite order.\n *\n * @static\n * @memberOf _\n * @since 2.0.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns `object`.\n * @see _.forIn\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.forInRight(new Foo, function(value, key) {\n * console.log(key);\n * });\n * // => Logs 'c', 'b', then 'a' assuming `_.forIn` logs 'a', 'b', then 'c'.\n */\n function forInRight(object, iteratee) {\n return object == null\n ? object\n : baseForRight(object, getIteratee(iteratee, 3), keysIn);\n }\n\n /**\n * Iterates over own enumerable string keyed properties of an object and\n * invokes `iteratee` for each property. The iteratee is invoked with three\n * arguments: (value, key, object). Iteratee functions may exit iteration\n * early by explicitly returning `false`.\n *\n * @static\n * @memberOf _\n * @since 0.3.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns `object`.\n * @see _.forOwnRight\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.forOwn(new Foo, function(value, key) {\n * console.log(key);\n * });\n * // => Logs 'a' then 'b' (iteration order is not guaranteed).\n */\n function forOwn(object, iteratee) {\n return object && baseForOwn(object, getIteratee(iteratee, 3));\n }\n\n /**\n * This method is like `_.forOwn` except that it iterates over properties of\n * `object` in the opposite order.\n *\n * @static\n * @memberOf _\n * @since 2.0.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns `object`.\n * @see _.forOwn\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.forOwnRight(new Foo, function(value, key) {\n * console.log(key);\n * });\n * // => Logs 'b' then 'a' assuming `_.forOwn` logs 'a' then 'b'.\n */\n function forOwnRight(object, iteratee) {\n return object && baseForOwnRight(object, getIteratee(iteratee, 3));\n }\n\n /**\n * Creates an array of function property names from own enumerable properties\n * of `object`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to inspect.\n * @returns {Array} Returns the function names.\n * @see _.functionsIn\n * @example\n *\n * function Foo() {\n * this.a = _.constant('a');\n * this.b = _.constant('b');\n * }\n *\n * Foo.prototype.c = _.constant('c');\n *\n * _.functions(new Foo);\n * // => ['a', 'b']\n */\n function functions(object) {\n return object == null ? [] : baseFunctions(object, keys(object));\n }\n\n /**\n * Creates an array of function property names from own and inherited\n * enumerable properties of `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to inspect.\n * @returns {Array} Returns the function names.\n * @see _.functions\n * @example\n *\n * function Foo() {\n * this.a = _.constant('a');\n * this.b = _.constant('b');\n * }\n *\n * Foo.prototype.c = _.constant('c');\n *\n * _.functionsIn(new Foo);\n * // => ['a', 'b', 'c']\n */\n function functionsIn(object) {\n return object == null ? [] : baseFunctions(object, keysIn(object));\n }\n\n /**\n * Gets the value at `path` of `object`. If the resolved value is\n * `undefined`, the `defaultValue` is returned in its place.\n *\n * @static\n * @memberOf _\n * @since 3.7.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to get.\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\n * @returns {*} Returns the resolved value.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.get(object, 'a[0].b.c');\n * // => 3\n *\n * _.get(object, ['a', '0', 'b', 'c']);\n * // => 3\n *\n * _.get(object, 'a.b.c', 'default');\n * // => 'default'\n */\n function get(object, path, defaultValue) {\n var result = object == null ? undefined : baseGet(object, path);\n return result === undefined ? defaultValue : result;\n }\n\n /**\n * Checks if `path` is a direct property of `object`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = { 'a': { 'b': 2 } };\n * var other = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.has(object, 'a');\n * // => true\n *\n * _.has(object, 'a.b');\n * // => true\n *\n * _.has(object, ['a', 'b']);\n * // => true\n *\n * _.has(other, 'a');\n * // => false\n */\n function has(object, path) {\n return object != null && hasPath(object, path, baseHas);\n }\n\n /**\n * Checks if `path` is a direct or inherited property of `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path to check.\n * @returns {boolean} Returns `true` if `path` exists, else `false`.\n * @example\n *\n * var object = _.create({ 'a': _.create({ 'b': 2 }) });\n *\n * _.hasIn(object, 'a');\n * // => true\n *\n * _.hasIn(object, 'a.b');\n * // => true\n *\n * _.hasIn(object, ['a', 'b']);\n * // => true\n *\n * _.hasIn(object, 'b');\n * // => false\n */\n function hasIn(object, path) {\n return object != null && hasPath(object, path, baseHasIn);\n }\n\n /**\n * Creates an object composed of the inverted keys and values of `object`.\n * If `object` contains duplicate values, subsequent values overwrite\n * property assignments of previous values.\n *\n * @static\n * @memberOf _\n * @since 0.7.0\n * @category Object\n * @param {Object} object The object to invert.\n * @returns {Object} Returns the new inverted object.\n * @example\n *\n * var object = { 'a': 1, 'b': 2, 'c': 1 };\n *\n * _.invert(object);\n * // => { '1': 'c', '2': 'b' }\n */\n var invert = createInverter(function(result, value, key) {\n if (value != null &&\n typeof value.toString != 'function') {\n value = nativeObjectToString.call(value);\n }\n\n result[value] = key;\n }, constant(identity));\n\n /**\n * This method is like `_.invert` except that the inverted object is generated\n * from the results of running each element of `object` thru `iteratee`. The\n * corresponding inverted value of each inverted key is an array of keys\n * responsible for generating the inverted value. The iteratee is invoked\n * with one argument: (value).\n *\n * @static\n * @memberOf _\n * @since 4.1.0\n * @category Object\n * @param {Object} object The object to invert.\n * @param {Function} [iteratee=_.identity] The iteratee invoked per element.\n * @returns {Object} Returns the new inverted object.\n * @example\n *\n * var object = { 'a': 1, 'b': 2, 'c': 1 };\n *\n * _.invertBy(object);\n * // => { '1': ['a', 'c'], '2': ['b'] }\n *\n * _.invertBy(object, function(value) {\n * return 'group' + value;\n * });\n * // => { 'group1': ['a', 'c'], 'group2': ['b'] }\n */\n var invertBy = createInverter(function(result, value, key) {\n if (value != null &&\n typeof value.toString != 'function') {\n value = nativeObjectToString.call(value);\n }\n\n if (hasOwnProperty.call(result, value)) {\n result[value].push(key);\n } else {\n result[value] = [key];\n }\n }, getIteratee);\n\n /**\n * Invokes the method at `path` of `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the method to invoke.\n * @param {...*} [args] The arguments to invoke the method with.\n * @returns {*} Returns the result of the invoked method.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': [1, 2, 3, 4] } }] };\n *\n * _.invoke(object, 'a[0].b.c.slice', 1, 3);\n * // => [2, 3]\n */\n var invoke = baseRest(baseInvoke);\n\n /**\n * Creates an array of the own enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects. See the\n * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys)\n * for more details.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keys(new Foo);\n * // => ['a', 'b'] (iteration order is not guaranteed)\n *\n * _.keys('hi');\n * // => ['0', '1']\n */\n function keys(object) {\n return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);\n }\n\n /**\n * Creates an array of the own and inherited enumerable property names of `object`.\n *\n * **Note:** Non-object values are coerced to objects.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property names.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.keysIn(new Foo);\n * // => ['a', 'b', 'c'] (iteration order is not guaranteed)\n */\n function keysIn(object) {\n return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);\n }\n\n /**\n * The opposite of `_.mapValues`; this method creates an object with the\n * same values as `object` and keys generated by running each own enumerable\n * string keyed property of `object` thru `iteratee`. The iteratee is invoked\n * with three arguments: (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 3.8.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapValues\n * @example\n *\n * _.mapKeys({ 'a': 1, 'b': 2 }, function(value, key) {\n * return key + value;\n * });\n * // => { 'a1': 1, 'b2': 2 }\n */\n function mapKeys(object, iteratee) {\n var result = {};\n iteratee = getIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, iteratee(value, key, object), value);\n });\n return result;\n }\n\n /**\n * Creates an object with the same keys as `object` and values generated\n * by running each own enumerable string keyed property of `object` thru\n * `iteratee`. The iteratee is invoked with three arguments:\n * (value, key, object).\n *\n * @static\n * @memberOf _\n * @since 2.4.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @returns {Object} Returns the new mapped object.\n * @see _.mapKeys\n * @example\n *\n * var users = {\n * 'fred': { 'user': 'fred', 'age': 40 },\n * 'pebbles': { 'user': 'pebbles', 'age': 1 }\n * };\n *\n * _.mapValues(users, function(o) { return o.age; });\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n *\n * // The `_.property` iteratee shorthand.\n * _.mapValues(users, 'age');\n * // => { 'fred': 40, 'pebbles': 1 } (iteration order is not guaranteed)\n */\n function mapValues(object, iteratee) {\n var result = {};\n iteratee = getIteratee(iteratee, 3);\n\n baseForOwn(object, function(value, key, object) {\n baseAssignValue(result, key, iteratee(value, key, object));\n });\n return result;\n }\n\n /**\n * This method is like `_.assign` except that it recursively merges own and\n * inherited enumerable string keyed properties of source objects into the\n * destination object. Source properties that resolve to `undefined` are\n * skipped if a destination value exists. Array and plain object properties\n * are merged recursively. Other objects and value types are overridden by\n * assignment. Source objects are applied from left to right. Subsequent\n * sources overwrite property assignments of previous sources.\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 0.5.0\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} [sources] The source objects.\n * @returns {Object} Returns `object`.\n * @example\n *\n * var object = {\n * 'a': [{ 'b': 2 }, { 'd': 4 }]\n * };\n *\n * var other = {\n * 'a': [{ 'c': 3 }, { 'e': 5 }]\n * };\n *\n * _.merge(object, other);\n * // => { 'a': [{ 'b': 2, 'c': 3 }, { 'd': 4, 'e': 5 }] }\n */\n var merge = createAssigner(function(object, source, srcIndex) {\n baseMerge(object, source, srcIndex);\n });\n\n /**\n * This method is like `_.merge` except that it accepts `customizer` which\n * is invoked to produce the merged values of the destination and source\n * properties. If `customizer` returns `undefined`, merging is handled by the\n * method instead. The `customizer` is invoked with six arguments:\n * (objValue, srcValue, key, object, source, stack).\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The destination object.\n * @param {...Object} sources The source objects.\n * @param {Function} customizer The function to customize assigned values.\n * @returns {Object} Returns `object`.\n * @example\n *\n * function customizer(objValue, srcValue) {\n * if (_.isArray(objValue)) {\n * return objValue.concat(srcValue);\n * }\n * }\n *\n * var object = { 'a': [1], 'b': [2] };\n * var other = { 'a': [3], 'b': [4] };\n *\n * _.mergeWith(object, other, customizer);\n * // => { 'a': [1, 3], 'b': [2, 4] }\n */\n var mergeWith = createAssigner(function(object, source, srcIndex, customizer) {\n baseMerge(object, source, srcIndex, customizer);\n });\n\n /**\n * The opposite of `_.pick`; this method creates an object composed of the\n * own and inherited enumerable property paths of `object` that are not omitted.\n *\n * **Note:** This method is considerably slower than `_.pick`.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The source object.\n * @param {...(string|string[])} [paths] The property paths to omit.\n * @returns {Object} Returns the new object.\n * @example\n *\n * var object = { 'a': 1, 'b': '2', 'c': 3 };\n *\n * _.omit(object, ['a', 'c']);\n * // => { 'b': '2' }\n */\n var omit = flatRest(function(object, paths) {\n var result = {};\n if (object == null) {\n return result;\n }\n var isDeep = false;\n paths = arrayMap(paths, function(path) {\n path = castPath(path, object);\n isDeep || (isDeep = path.length > 1);\n return path;\n });\n copyObject(object, getAllKeysIn(object), result);\n if (isDeep) {\n result = baseClone(result, CLONE_DEEP_FLAG | CLONE_FLAT_FLAG | CLONE_SYMBOLS_FLAG, customOmitClone);\n }\n var length = paths.length;\n while (length--) {\n baseUnset(result, paths[length]);\n }\n return result;\n });\n\n /**\n * The opposite of `_.pickBy`; this method creates an object composed of\n * the own and inherited enumerable string keyed properties of `object` that\n * `predicate` doesn't return truthy for. The predicate is invoked with two\n * arguments: (value, key).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The source object.\n * @param {Function} [predicate=_.identity] The function invoked per property.\n * @returns {Object} Returns the new object.\n * @example\n *\n * var object = { 'a': 1, 'b': '2', 'c': 3 };\n *\n * _.omitBy(object, _.isNumber);\n * // => { 'b': '2' }\n */\n function omitBy(object, predicate) {\n return pickBy(object, negate(getIteratee(predicate)));\n }\n\n /**\n * Creates an object composed of the picked `object` properties.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The source object.\n * @param {...(string|string[])} [paths] The property paths to pick.\n * @returns {Object} Returns the new object.\n * @example\n *\n * var object = { 'a': 1, 'b': '2', 'c': 3 };\n *\n * _.pick(object, ['a', 'c']);\n * // => { 'a': 1, 'c': 3 }\n */\n var pick = flatRest(function(object, paths) {\n return object == null ? {} : basePick(object, paths);\n });\n\n /**\n * Creates an object composed of the `object` properties `predicate` returns\n * truthy for. The predicate is invoked with two arguments: (value, key).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The source object.\n * @param {Function} [predicate=_.identity] The function invoked per property.\n * @returns {Object} Returns the new object.\n * @example\n *\n * var object = { 'a': 1, 'b': '2', 'c': 3 };\n *\n * _.pickBy(object, _.isNumber);\n * // => { 'a': 1, 'c': 3 }\n */\n function pickBy(object, predicate) {\n if (object == null) {\n return {};\n }\n var props = arrayMap(getAllKeysIn(object), function(prop) {\n return [prop];\n });\n predicate = getIteratee(predicate);\n return basePickBy(object, props, function(value, path) {\n return predicate(value, path[0]);\n });\n }\n\n /**\n * This method is like `_.get` except that if the resolved value is a\n * function it's invoked with the `this` binding of its parent object and\n * its result is returned.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @param {Array|string} path The path of the property to resolve.\n * @param {*} [defaultValue] The value returned for `undefined` resolved values.\n * @returns {*} Returns the resolved value.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c1': 3, 'c2': _.constant(4) } }] };\n *\n * _.result(object, 'a[0].b.c1');\n * // => 3\n *\n * _.result(object, 'a[0].b.c2');\n * // => 4\n *\n * _.result(object, 'a[0].b.c3', 'default');\n * // => 'default'\n *\n * _.result(object, 'a[0].b.c3', _.constant('default'));\n * // => 'default'\n */\n function result(object, path, defaultValue) {\n path = castPath(path, object);\n\n var index = -1,\n length = path.length;\n\n // Ensure the loop is entered when path is empty.\n if (!length) {\n length = 1;\n object = undefined;\n }\n while (++index < length) {\n var value = object == null ? undefined : object[toKey(path[index])];\n if (value === undefined) {\n index = length;\n value = defaultValue;\n }\n object = isFunction(value) ? value.call(object) : value;\n }\n return object;\n }\n\n /**\n * Sets the value at `path` of `object`. If a portion of `path` doesn't exist,\n * it's created. Arrays are created for missing index properties while objects\n * are created for all other missing properties. Use `_.setWith` to customize\n * `path` creation.\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 3.7.0\n * @category Object\n * @param {Object} object The object to modify.\n * @param {Array|string} path The path of the property to set.\n * @param {*} value The value to set.\n * @returns {Object} Returns `object`.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.set(object, 'a[0].b.c', 4);\n * console.log(object.a[0].b.c);\n * // => 4\n *\n * _.set(object, ['x', '0', 'y', 'z'], 5);\n * console.log(object.x[0].y.z);\n * // => 5\n */\n function set(object, path, value) {\n return object == null ? object : baseSet(object, path, value);\n }\n\n /**\n * This method is like `_.set` except that it accepts `customizer` which is\n * invoked to produce the objects of `path`. If `customizer` returns `undefined`\n * path creation is handled by the method instead. The `customizer` is invoked\n * with three arguments: (nsValue, key, nsObject).\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to modify.\n * @param {Array|string} path The path of the property to set.\n * @param {*} value The value to set.\n * @param {Function} [customizer] The function to customize assigned values.\n * @returns {Object} Returns `object`.\n * @example\n *\n * var object = {};\n *\n * _.setWith(object, '[0][1]', 'a', Object);\n * // => { '0': { '1': 'a' } }\n */\n function setWith(object, path, value, customizer) {\n customizer = typeof customizer == 'function' ? customizer : undefined;\n return object == null ? object : baseSet(object, path, value, customizer);\n }\n\n /**\n * Creates an array of own enumerable string keyed-value pairs for `object`\n * which can be consumed by `_.fromPairs`. If `object` is a map or set, its\n * entries are returned.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @alias entries\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the key-value pairs.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.toPairs(new Foo);\n * // => [['a', 1], ['b', 2]] (iteration order is not guaranteed)\n */\n var toPairs = createToPairs(keys);\n\n /**\n * Creates an array of own and inherited enumerable string keyed-value pairs\n * for `object` which can be consumed by `_.fromPairs`. If `object` is a map\n * or set, its entries are returned.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @alias entriesIn\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the key-value pairs.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.toPairsIn(new Foo);\n * // => [['a', 1], ['b', 2], ['c', 3]] (iteration order is not guaranteed)\n */\n var toPairsIn = createToPairs(keysIn);\n\n /**\n * An alternative to `_.reduce`; this method transforms `object` to a new\n * `accumulator` object which is the result of running each of its own\n * enumerable string keyed properties thru `iteratee`, with each invocation\n * potentially mutating the `accumulator` object. If `accumulator` is not\n * provided, a new object with the same `[[Prototype]]` will be used. The\n * iteratee is invoked with four arguments: (accumulator, value, key, object).\n * Iteratee functions may exit iteration early by explicitly returning `false`.\n *\n * @static\n * @memberOf _\n * @since 1.3.0\n * @category Object\n * @param {Object} object The object to iterate over.\n * @param {Function} [iteratee=_.identity] The function invoked per iteration.\n * @param {*} [accumulator] The custom accumulator value.\n * @returns {*} Returns the accumulated value.\n * @example\n *\n * _.transform([2, 3, 4], function(result, n) {\n * result.push(n *= n);\n * return n % 2 == 0;\n * }, []);\n * // => [4, 9]\n *\n * _.transform({ 'a': 1, 'b': 2, 'c': 1 }, function(result, value, key) {\n * (result[value] || (result[value] = [])).push(key);\n * }, {});\n * // => { '1': ['a', 'c'], '2': ['b'] }\n */\n function transform(object, iteratee, accumulator) {\n var isArr = isArray(object),\n isArrLike = isArr || isBuffer(object) || isTypedArray(object);\n\n iteratee = getIteratee(iteratee, 4);\n if (accumulator == null) {\n var Ctor = object && object.constructor;\n if (isArrLike) {\n accumulator = isArr ? new Ctor : [];\n }\n else if (isObject(object)) {\n accumulator = isFunction(Ctor) ? baseCreate(getPrototype(object)) : {};\n }\n else {\n accumulator = {};\n }\n }\n (isArrLike ? arrayEach : baseForOwn)(object, function(value, index, object) {\n return iteratee(accumulator, value, index, object);\n });\n return accumulator;\n }\n\n /**\n * Removes the property at `path` of `object`.\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Object\n * @param {Object} object The object to modify.\n * @param {Array|string} path The path of the property to unset.\n * @returns {boolean} Returns `true` if the property is deleted, else `false`.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 7 } }] };\n * _.unset(object, 'a[0].b.c');\n * // => true\n *\n * console.log(object);\n * // => { 'a': [{ 'b': {} }] };\n *\n * _.unset(object, ['a', '0', 'b', 'c']);\n * // => true\n *\n * console.log(object);\n * // => { 'a': [{ 'b': {} }] };\n */\n function unset(object, path) {\n return object == null ? true : baseUnset(object, path);\n }\n\n /**\n * This method is like `_.set` except that accepts `updater` to produce the\n * value to set. Use `_.updateWith` to customize `path` creation. The `updater`\n * is invoked with one argument: (value).\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 4.6.0\n * @category Object\n * @param {Object} object The object to modify.\n * @param {Array|string} path The path of the property to set.\n * @param {Function} updater The function to produce the updated value.\n * @returns {Object} Returns `object`.\n * @example\n *\n * var object = { 'a': [{ 'b': { 'c': 3 } }] };\n *\n * _.update(object, 'a[0].b.c', function(n) { return n * n; });\n * console.log(object.a[0].b.c);\n * // => 9\n *\n * _.update(object, 'x[0].y.z', function(n) { return n ? n + 1 : 0; });\n * console.log(object.x[0].y.z);\n * // => 0\n */\n function update(object, path, updater) {\n return object == null ? object : baseUpdate(object, path, castFunction(updater));\n }\n\n /**\n * This method is like `_.update` except that it accepts `customizer` which is\n * invoked to produce the objects of `path`. If `customizer` returns `undefined`\n * path creation is handled by the method instead. The `customizer` is invoked\n * with three arguments: (nsValue, key, nsObject).\n *\n * **Note:** This method mutates `object`.\n *\n * @static\n * @memberOf _\n * @since 4.6.0\n * @category Object\n * @param {Object} object The object to modify.\n * @param {Array|string} path The path of the property to set.\n * @param {Function} updater The function to produce the updated value.\n * @param {Function} [customizer] The function to customize assigned values.\n * @returns {Object} Returns `object`.\n * @example\n *\n * var object = {};\n *\n * _.updateWith(object, '[0][1]', _.constant('a'), Object);\n * // => { '0': { '1': 'a' } }\n */\n function updateWith(object, path, updater, customizer) {\n customizer = typeof customizer == 'function' ? customizer : undefined;\n return object == null ? object : baseUpdate(object, path, castFunction(updater), customizer);\n }\n\n /**\n * Creates an array of the own enumerable string keyed property values of `object`.\n *\n * **Note:** Non-object values are coerced to objects.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property values.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.values(new Foo);\n * // => [1, 2] (iteration order is not guaranteed)\n *\n * _.values('hi');\n * // => ['h', 'i']\n */\n function values(object) {\n return object == null ? [] : baseValues(object, keys(object));\n }\n\n /**\n * Creates an array of the own and inherited enumerable string keyed property\n * values of `object`.\n *\n * **Note:** Non-object values are coerced to objects.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category Object\n * @param {Object} object The object to query.\n * @returns {Array} Returns the array of property values.\n * @example\n *\n * function Foo() {\n * this.a = 1;\n * this.b = 2;\n * }\n *\n * Foo.prototype.c = 3;\n *\n * _.valuesIn(new Foo);\n * // => [1, 2, 3] (iteration order is not guaranteed)\n */\n function valuesIn(object) {\n return object == null ? [] : baseValues(object, keysIn(object));\n }\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Clamps `number` within the inclusive `lower` and `upper` bounds.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category Number\n * @param {number} number The number to clamp.\n * @param {number} [lower] The lower bound.\n * @param {number} upper The upper bound.\n * @returns {number} Returns the clamped number.\n * @example\n *\n * _.clamp(-10, -5, 5);\n * // => -5\n *\n * _.clamp(10, -5, 5);\n * // => 5\n */\n function clamp(number, lower, upper) {\n if (upper === undefined) {\n upper = lower;\n lower = undefined;\n }\n if (upper !== undefined) {\n upper = toNumber(upper);\n upper = upper === upper ? upper : 0;\n }\n if (lower !== undefined) {\n lower = toNumber(lower);\n lower = lower === lower ? lower : 0;\n }\n return baseClamp(toNumber(number), lower, upper);\n }\n\n /**\n * Checks if `n` is between `start` and up to, but not including, `end`. If\n * `end` is not specified, it's set to `start` with `start` then set to `0`.\n * If `start` is greater than `end` the params are swapped to support\n * negative ranges.\n *\n * @static\n * @memberOf _\n * @since 3.3.0\n * @category Number\n * @param {number} number The number to check.\n * @param {number} [start=0] The start of the range.\n * @param {number} end The end of the range.\n * @returns {boolean} Returns `true` if `number` is in the range, else `false`.\n * @see _.range, _.rangeRight\n * @example\n *\n * _.inRange(3, 2, 4);\n * // => true\n *\n * _.inRange(4, 8);\n * // => true\n *\n * _.inRange(4, 2);\n * // => false\n *\n * _.inRange(2, 2);\n * // => false\n *\n * _.inRange(1.2, 2);\n * // => true\n *\n * _.inRange(5.2, 4);\n * // => false\n *\n * _.inRange(-3, -2, -6);\n * // => true\n */\n function inRange(number, start, end) {\n start = toFinite(start);\n if (end === undefined) {\n end = start;\n start = 0;\n } else {\n end = toFinite(end);\n }\n number = toNumber(number);\n return baseInRange(number, start, end);\n }\n\n /**\n * Produces a random number between the inclusive `lower` and `upper` bounds.\n * If only one argument is provided a number between `0` and the given number\n * is returned. If `floating` is `true`, or either `lower` or `upper` are\n * floats, a floating-point number is returned instead of an integer.\n *\n * **Note:** JavaScript follows the IEEE-754 standard for resolving\n * floating-point values which can produce unexpected results.\n *\n * @static\n * @memberOf _\n * @since 0.7.0\n * @category Number\n * @param {number} [lower=0] The lower bound.\n * @param {number} [upper=1] The upper bound.\n * @param {boolean} [floating] Specify returning a floating-point number.\n * @returns {number} Returns the random number.\n * @example\n *\n * _.random(0, 5);\n * // => an integer between 0 and 5\n *\n * _.random(5);\n * // => also an integer between 0 and 5\n *\n * _.random(5, true);\n * // => a floating-point number between 0 and 5\n *\n * _.random(1.2, 5.2);\n * // => a floating-point number between 1.2 and 5.2\n */\n function random(lower, upper, floating) {\n if (floating && typeof floating != 'boolean' && isIterateeCall(lower, upper, floating)) {\n upper = floating = undefined;\n }\n if (floating === undefined) {\n if (typeof upper == 'boolean') {\n floating = upper;\n upper = undefined;\n }\n else if (typeof lower == 'boolean') {\n floating = lower;\n lower = undefined;\n }\n }\n if (lower === undefined && upper === undefined) {\n lower = 0;\n upper = 1;\n }\n else {\n lower = toFinite(lower);\n if (upper === undefined) {\n upper = lower;\n lower = 0;\n } else {\n upper = toFinite(upper);\n }\n }\n if (lower > upper) {\n var temp = lower;\n lower = upper;\n upper = temp;\n }\n if (floating || lower % 1 || upper % 1) {\n var rand = nativeRandom();\n return nativeMin(lower + (rand * (upper - lower + freeParseFloat('1e-' + ((rand + '').length - 1)))), upper);\n }\n return baseRandom(lower, upper);\n }\n\n /*------------------------------------------------------------------------*/\n\n /**\n * Converts `string` to [camel case](https://en.wikipedia.org/wiki/CamelCase).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the camel cased string.\n * @example\n *\n * _.camelCase('Foo Bar');\n * // => 'fooBar'\n *\n * _.camelCase('--foo-bar--');\n * // => 'fooBar'\n *\n * _.camelCase('__FOO_BAR__');\n * // => 'fooBar'\n */\n var camelCase = createCompounder(function(result, word, index) {\n word = word.toLowerCase();\n return result + (index ? capitalize(word) : word);\n });\n\n /**\n * Converts the first character of `string` to upper case and the remaining\n * to lower case.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to capitalize.\n * @returns {string} Returns the capitalized string.\n * @example\n *\n * _.capitalize('FRED');\n * // => 'Fred'\n */\n function capitalize(string) {\n return upperFirst(toString(string).toLowerCase());\n }\n\n /**\n * Deburrs `string` by converting\n * [Latin-1 Supplement](https://en.wikipedia.org/wiki/Latin-1_Supplement_(Unicode_block)#Character_table)\n * and [Latin Extended-A](https://en.wikipedia.org/wiki/Latin_Extended-A)\n * letters to basic Latin letters and removing\n * [combining diacritical marks](https://en.wikipedia.org/wiki/Combining_Diacritical_Marks).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to deburr.\n * @returns {string} Returns the deburred string.\n * @example\n *\n * _.deburr('déjà vu');\n * // => 'deja vu'\n */\n function deburr(string) {\n string = toString(string);\n return string && string.replace(reLatin, deburrLetter).replace(reComboMark, '');\n }\n\n /**\n * Checks if `string` ends with the given target string.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to inspect.\n * @param {string} [target] The string to search for.\n * @param {number} [position=string.length] The position to search up to.\n * @returns {boolean} Returns `true` if `string` ends with `target`,\n * else `false`.\n * @example\n *\n * _.endsWith('abc', 'c');\n * // => true\n *\n * _.endsWith('abc', 'b');\n * // => false\n *\n * _.endsWith('abc', 'b', 2);\n * // => true\n */\n function endsWith(string, target, position) {\n string = toString(string);\n target = baseToString(target);\n\n var length = string.length;\n position = position === undefined\n ? length\n : baseClamp(toInteger(position), 0, length);\n\n var end = position;\n position -= target.length;\n return position >= 0 && string.slice(position, end) == target;\n }\n\n /**\n * Converts the characters \"&\", \"<\", \">\", '\"', and \"'\" in `string` to their\n * corresponding HTML entities.\n *\n * **Note:** No other characters are escaped. To escape additional\n * characters use a third-party library like [_he_](https://mths.be/he).\n *\n * Though the \">\" character is escaped for symmetry, characters like\n * \">\" and \"/\" don't need escaping in HTML and have no special meaning\n * unless they're part of a tag or unquoted attribute value. See\n * [Mathias Bynens's article](https://mathiasbynens.be/notes/ambiguous-ampersands)\n * (under \"semi-related fun fact\") for more details.\n *\n * When working with HTML you should always\n * [quote attribute values](http://wonko.com/post/html-escaping) to reduce\n * XSS vectors.\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category String\n * @param {string} [string=''] The string to escape.\n * @returns {string} Returns the escaped string.\n * @example\n *\n * _.escape('fred, barney, & pebbles');\n * // => 'fred, barney, & pebbles'\n */\n function escape(string) {\n string = toString(string);\n return (string && reHasUnescapedHtml.test(string))\n ? string.replace(reUnescapedHtml, escapeHtmlChar)\n : string;\n }\n\n /**\n * Escapes the `RegExp` special characters \"^\", \"$\", \"\\\", \".\", \"*\", \"+\",\n * \"?\", \"(\", \")\", \"[\", \"]\", \"{\", \"}\", and \"|\" in `string`.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to escape.\n * @returns {string} Returns the escaped string.\n * @example\n *\n * _.escapeRegExp('[lodash](https://lodash.com/)');\n * // => '\\[lodash\\]\\(https://lodash\\.com/\\)'\n */\n function escapeRegExp(string) {\n string = toString(string);\n return (string && reHasRegExpChar.test(string))\n ? string.replace(reRegExpChar, '\\\\$&')\n : string;\n }\n\n /**\n * Converts `string` to\n * [kebab case](https://en.wikipedia.org/wiki/Letter_case#Special_case_styles).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the kebab cased string.\n * @example\n *\n * _.kebabCase('Foo Bar');\n * // => 'foo-bar'\n *\n * _.kebabCase('fooBar');\n * // => 'foo-bar'\n *\n * _.kebabCase('__FOO_BAR__');\n * // => 'foo-bar'\n */\n var kebabCase = createCompounder(function(result, word, index) {\n return result + (index ? '-' : '') + word.toLowerCase();\n });\n\n /**\n * Converts `string`, as space separated words, to lower case.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the lower cased string.\n * @example\n *\n * _.lowerCase('--Foo-Bar--');\n * // => 'foo bar'\n *\n * _.lowerCase('fooBar');\n * // => 'foo bar'\n *\n * _.lowerCase('__FOO_BAR__');\n * // => 'foo bar'\n */\n var lowerCase = createCompounder(function(result, word, index) {\n return result + (index ? ' ' : '') + word.toLowerCase();\n });\n\n /**\n * Converts the first character of `string` to lower case.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the converted string.\n * @example\n *\n * _.lowerFirst('Fred');\n * // => 'fred'\n *\n * _.lowerFirst('FRED');\n * // => 'fRED'\n */\n var lowerFirst = createCaseFirst('toLowerCase');\n\n /**\n * Pads `string` on the left and right sides if it's shorter than `length`.\n * Padding characters are truncated if they can't be evenly divided by `length`.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to pad.\n * @param {number} [length=0] The padding length.\n * @param {string} [chars=' '] The string used as padding.\n * @returns {string} Returns the padded string.\n * @example\n *\n * _.pad('abc', 8);\n * // => ' abc '\n *\n * _.pad('abc', 8, '_-');\n * // => '_-abc_-_'\n *\n * _.pad('abc', 3);\n * // => 'abc'\n */\n function pad(string, length, chars) {\n string = toString(string);\n length = toInteger(length);\n\n var strLength = length ? stringSize(string) : 0;\n if (!length || strLength >= length) {\n return string;\n }\n var mid = (length - strLength) / 2;\n return (\n createPadding(nativeFloor(mid), chars) +\n string +\n createPadding(nativeCeil(mid), chars)\n );\n }\n\n /**\n * Pads `string` on the right side if it's shorter than `length`. Padding\n * characters are truncated if they exceed `length`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to pad.\n * @param {number} [length=0] The padding length.\n * @param {string} [chars=' '] The string used as padding.\n * @returns {string} Returns the padded string.\n * @example\n *\n * _.padEnd('abc', 6);\n * // => 'abc '\n *\n * _.padEnd('abc', 6, '_-');\n * // => 'abc_-_'\n *\n * _.padEnd('abc', 3);\n * // => 'abc'\n */\n function padEnd(string, length, chars) {\n string = toString(string);\n length = toInteger(length);\n\n var strLength = length ? stringSize(string) : 0;\n return (length && strLength < length)\n ? (string + createPadding(length - strLength, chars))\n : string;\n }\n\n /**\n * Pads `string` on the left side if it's shorter than `length`. Padding\n * characters are truncated if they exceed `length`.\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to pad.\n * @param {number} [length=0] The padding length.\n * @param {string} [chars=' '] The string used as padding.\n * @returns {string} Returns the padded string.\n * @example\n *\n * _.padStart('abc', 6);\n * // => ' abc'\n *\n * _.padStart('abc', 6, '_-');\n * // => '_-_abc'\n *\n * _.padStart('abc', 3);\n * // => 'abc'\n */\n function padStart(string, length, chars) {\n string = toString(string);\n length = toInteger(length);\n\n var strLength = length ? stringSize(string) : 0;\n return (length && strLength < length)\n ? (createPadding(length - strLength, chars) + string)\n : string;\n }\n\n /**\n * Converts `string` to an integer of the specified radix. If `radix` is\n * `undefined` or `0`, a `radix` of `10` is used unless `value` is a\n * hexadecimal, in which case a `radix` of `16` is used.\n *\n * **Note:** This method aligns with the\n * [ES5 implementation](https://es5.github.io/#x15.1.2.2) of `parseInt`.\n *\n * @static\n * @memberOf _\n * @since 1.1.0\n * @category String\n * @param {string} string The string to convert.\n * @param {number} [radix=10] The radix to interpret `value` by.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {number} Returns the converted integer.\n * @example\n *\n * _.parseInt('08');\n * // => 8\n *\n * _.map(['6', '08', '10'], _.parseInt);\n * // => [6, 8, 10]\n */\n function parseInt(string, radix, guard) {\n if (guard || radix == null) {\n radix = 0;\n } else if (radix) {\n radix = +radix;\n }\n return nativeParseInt(toString(string).replace(reTrimStart, ''), radix || 0);\n }\n\n /**\n * Repeats the given string `n` times.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to repeat.\n * @param {number} [n=1] The number of times to repeat the string.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {string} Returns the repeated string.\n * @example\n *\n * _.repeat('*', 3);\n * // => '***'\n *\n * _.repeat('abc', 2);\n * // => 'abcabc'\n *\n * _.repeat('abc', 0);\n * // => ''\n */\n function repeat(string, n, guard) {\n if ((guard ? isIterateeCall(string, n, guard) : n === undefined)) {\n n = 1;\n } else {\n n = toInteger(n);\n }\n return baseRepeat(toString(string), n);\n }\n\n /**\n * Replaces matches for `pattern` in `string` with `replacement`.\n *\n * **Note:** This method is based on\n * [`String#replace`](https://mdn.io/String/replace).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to modify.\n * @param {RegExp|string} pattern The pattern to replace.\n * @param {Function|string} replacement The match replacement.\n * @returns {string} Returns the modified string.\n * @example\n *\n * _.replace('Hi Fred', 'Fred', 'Barney');\n * // => 'Hi Barney'\n */\n function replace() {\n var args = arguments,\n string = toString(args[0]);\n\n return args.length < 3 ? string : string.replace(args[1], args[2]);\n }\n\n /**\n * Converts `string` to\n * [snake case](https://en.wikipedia.org/wiki/Snake_case).\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the snake cased string.\n * @example\n *\n * _.snakeCase('Foo Bar');\n * // => 'foo_bar'\n *\n * _.snakeCase('fooBar');\n * // => 'foo_bar'\n *\n * _.snakeCase('--FOO-BAR--');\n * // => 'foo_bar'\n */\n var snakeCase = createCompounder(function(result, word, index) {\n return result + (index ? '_' : '') + word.toLowerCase();\n });\n\n /**\n * Splits `string` by `separator`.\n *\n * **Note:** This method is based on\n * [`String#split`](https://mdn.io/String/split).\n *\n * @static\n * @memberOf _\n * @since 4.0.0\n * @category String\n * @param {string} [string=''] The string to split.\n * @param {RegExp|string} separator The separator pattern to split by.\n * @param {number} [limit] The length to truncate results to.\n * @returns {Array} Returns the string segments.\n * @example\n *\n * _.split('a-b-c', '-', 2);\n * // => ['a', 'b']\n */\n function split(string, separator, limit) {\n if (limit && typeof limit != 'number' && isIterateeCall(string, separator, limit)) {\n separator = limit = undefined;\n }\n limit = limit === undefined ? MAX_ARRAY_LENGTH : limit >>> 0;\n if (!limit) {\n return [];\n }\n string = toString(string);\n if (string && (\n typeof separator == 'string' ||\n (separator != null && !isRegExp(separator))\n )) {\n separator = baseToString(separator);\n if (!separator && hasUnicode(string)) {\n return castSlice(stringToArray(string), 0, limit);\n }\n }\n return string.split(separator, limit);\n }\n\n /**\n * Converts `string` to\n * [start case](https://en.wikipedia.org/wiki/Letter_case#Stylistic_or_specialised_usage).\n *\n * @static\n * @memberOf _\n * @since 3.1.0\n * @category String\n * @param {string} [string=''] The string to convert.\n * @returns {string} Returns the start cased string.\n * @example\n *\n * _.startCase('--foo-bar--');\n * // => 'Foo Bar'\n *\n * _.startCase('fooBar');\n * // => 'Foo Bar'\n *\n * _.startCase('__FOO_BAR__');\n * // => 'FOO BAR'\n */\n var startCase = createCompounder(function(result, word, index) {\n return result + (index ? ' ' : '') + upperFirst(word);\n });\n\n /**\n * Checks if `string` starts with the given target string.\n *\n * @static\n * @memberOf _\n * @since 3.0.0\n * @category String\n * @param {string} [string=''] The string to inspect.\n * @param {string} [target] The string to search for.\n * @param {number} [position=0] The position to search from.\n * @returns {boolean} Returns `true` if `string` starts with `target`,\n * else `false`.\n * @example\n *\n * _.startsWith('abc', 'a');\n * // => true\n *\n * _.startsWith('abc', 'b');\n * // => false\n *\n * _.startsWith('abc', 'b', 1);\n * // => true\n */\n function startsWith(string, target, position) {\n string = toString(string);\n position = position == null\n ? 0\n : baseClamp(toInteger(position), 0, string.length);\n\n target = baseToString(target);\n return string.slice(position, position + target.length) == target;\n }\n\n /**\n * Creates a compiled template function that can interpolate data properties\n * in \"interpolate\" delimiters, HTML-escape interpolated data properties in\n * \"escape\" delimiters, and execute JavaScript in \"evaluate\" delimiters. Data\n * properties may be accessed as free variables in the template. If a setting\n * object is given, it takes precedence over `_.templateSettings` values.\n *\n * **Note:** In the development build `_.template` utilizes\n * [sourceURLs](http://www.html5rocks.com/en/tutorials/developertools/sourcemaps/#toc-sourceurl)\n * for easier debugging.\n *\n * For more information on precompiling templates see\n * [lodash's custom builds documentation](https://lodash.com/custom-builds).\n *\n * For more information on Chrome extension sandboxes see\n * [Chrome's extensions documentation](https://developer.chrome.com/extensions/sandboxingEval).\n *\n * @static\n * @since 0.1.0\n * @memberOf _\n * @category String\n * @param {string} [string=''] The template string.\n * @param {Object} [options={}] The options object.\n * @param {RegExp} [options.escape=_.templateSettings.escape]\n * The HTML \"escape\" delimiter.\n * @param {RegExp} [options.evaluate=_.templateSettings.evaluate]\n * The \"evaluate\" delimiter.\n * @param {Object} [options.imports=_.templateSettings.imports]\n * An object to import into the template as free variables.\n * @param {RegExp} [options.interpolate=_.templateSettings.interpolate]\n * The \"interpolate\" delimiter.\n * @param {string} [options.sourceURL='lodash.templateSources[n]']\n * The sourceURL of the compiled template.\n * @param {string} [options.variable='obj']\n * The data object variable name.\n * @param- {Object} [guard] Enables use as an iteratee for methods like `_.map`.\n * @returns {Function} Returns the compiled template function.\n * @example\n *\n * // Use the \"interpolate\" delimiter to create a compiled template.\n * var compiled = _.template('hello <%= user %>!');\n * compiled({ 'user': 'fred' });\n * // => 'hello fred!'\n *\n * // Use the HTML \"escape\" delimiter to escape data property values.\n * var compiled = _.template('<%- value %>');\n * compiled({ 'value': '