diff --git a/dist/main.js b/dist/main.js index ab8f42349..b06e9a474 100644 --- a/dist/main.js +++ b/dist/main.js @@ -1,4 +1,4 @@ -var t,e,n=require("crypto"),r=require("module"),i=require("events"),o=require("assert"),s=require("timers"),a=require("util"),c=require("stream"),u=c,l=c.Transform,f=C(require("typescript")),p=require("atom"),h=(t={},e=p,Object.keys(e).forEach((function(n){"default"!==n&&"__esModule"!==n&&Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[n]}})})),t),d=p.CompositeDisposable,g=p.Emitter,m=p.BufferedNodeProcess,v=(p.BufferedProcess,p.Disposable),y=require("path"),w=y,b=y.dirname,_=require("fs"),x=_,S=C(_),k=require("child_process"),E=require("os");function C(t){return t&&t.__esModule?t.default:t}var T="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},A={};Object.defineProperty(A,"__esModule",{value:!0});var P=k,O=x,I=w;function j(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var N=j(E),D=j(O),F=j(I);const L=/\s+at.*(?:\(|\s)(.*)\)?/,M=/^(?:(?:(?:node|(?:internal\/[\w/]*|.*node_modules\/(?:babel-polyfill|pirates)\/.*)?\w+)\.js:\d+:\d+)|native)/,R=void 0===N.default.homedir?"":N.default.homedir();class B extends Error{constructor(t){if(!Array.isArray(t))throw new TypeError("Expected input to be an Array, got "+typeof t);let e=(t=[...t].map((t=>t instanceof Error?t:null!==t&&"object"==typeof t?Object.assign(new Error(t.message),t):new Error(t)))).map((t=>{return"string"==typeof t.stack?(t=>t.replace(/\s+at .*aggregate-error\/index.js:\d+:\d+\)?/g,""))((e=t.stack,n=Object.assign({pretty:!1},n),e.replace(/\\/g,"/").split("\n").filter((t=>{const e=t.match(L);if(null===e||!e[1])return!0;const n=e[1];return!n.includes(".app/Contents/Resources/electron.asar")&&!n.includes(".app/Contents/Resources/default_app.asar")&&!M.test(n)})).filter((t=>""!==t.trim())).map((t=>n.pretty?t.replace(L,((t,e)=>t.replace(e,e.replace(R,"~")))):t)).join("\n"))):String(t);var e,n})).join("\n");e="\n"+((t,e=1,n)=>{if(n={indent:" ",includeEmptyLines:!1,...n},"string"!=typeof t)throw new TypeError(`Expected \`input\` to be a \`string\`, got \`${typeof t}\``);if("number"!=typeof e)throw new TypeError(`Expected \`count\` to be a \`number\`, got \`${typeof e}\``);if("string"!=typeof n.indent)throw new TypeError(`Expected \`options.indent\` to be a \`string\`, got \`${typeof n.indent}\``);if(0===e)return t;const r=n.includeEmptyLines?/^/gm:/^(?!\s*$)/gm;return t.replace(r,n.indent.repeat(e))})(e,4),super(e),this.name="AggregateError",Object.defineProperty(this,"_errors",{value:t})}*[Symbol.iterator](){for(const t of this._errors)yield t}}var z=B;const q=(t,e,n)=>new Promise(((r,i)=>{if(n=Object.assign({concurrency:1/0},n),"function"!=typeof e)throw new TypeError("Mapper function is required");const{concurrency:o}=n;if(!("number"==typeof o&&o>=1))throw new TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${o}\` (${typeof o})`);const s=[],a=t[Symbol.iterator]();let c=!1,u=!1,l=0,f=0;const p=()=>{if(c)return;const t=a.next(),n=f;if(f++,t.done)return u=!0,void(0===l&&r(s));l++,Promise.resolve(t.value).then((t=>e(t,n))).then((t=>{s[n]=t,l--,p()}),(t=>{c=!0,i(t)}))};for(let t=0;t(await H(t,((t,n)=>Promise.all([e(t,n),t])),n)).filter((t=>Boolean(t[0]))).map((t=>t[1]));var V=$,W=$;V.default=W;const G="undefined"!=typeof atom,K="undefined"!=typeof atom&&(atom.inDevMode()||atom.inSpecMode()); +var t,e,n=require("crypto"),r=require("module"),i=require("events"),o=require("assert"),s=require("timers"),a=require("util"),c=require("stream"),u=c,l=c.Transform,f=T(require("typescript")),p=require("atom"),h=(t={},e=p,Object.keys(e).forEach((function(n){"default"!==n&&"__esModule"!==n&&Object.defineProperty(t,n,{enumerable:!0,get:function(){return e[n]}})})),t),d=p.CompositeDisposable,g=p.TextBuffer,m=p.Emitter,v=p.BufferedNodeProcess,y=(p.BufferedProcess,p.Disposable),w=require("path"),b=w,_=w.dirname,S=require("fs"),x=S,k=T(S),E=require("child_process"),C=require("os");function T(t){return t&&t.__esModule?t.default:t}var A="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},P={};Object.defineProperty(P,"__esModule",{value:!0});var I=E,O=x,j=b;function N(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var D=N(C),F=N(O),L=N(j);const M=/\s+at.*(?:\(|\s)(.*)\)?/,R=/^(?:(?:(?:node|(?:internal\/[\w/]*|.*node_modules\/(?:babel-polyfill|pirates)\/.*)?\w+)\.js:\d+:\d+)|native)/,B=void 0===D.default.homedir?"":D.default.homedir();class z extends Error{constructor(t){if(!Array.isArray(t))throw new TypeError("Expected input to be an Array, got "+typeof t);let e=(t=[...t].map((t=>t instanceof Error?t:null!==t&&"object"==typeof t?Object.assign(new Error(t.message),t):new Error(t)))).map((t=>{return"string"==typeof t.stack?(t=>t.replace(/\s+at .*aggregate-error\/index.js:\d+:\d+\)?/g,""))((e=t.stack,n=Object.assign({pretty:!1},n),e.replace(/\\/g,"/").split("\n").filter((t=>{const e=t.match(M);if(null===e||!e[1])return!0;const n=e[1];return!n.includes(".app/Contents/Resources/electron.asar")&&!n.includes(".app/Contents/Resources/default_app.asar")&&!R.test(n)})).filter((t=>""!==t.trim())).map((t=>n.pretty?t.replace(M,((t,e)=>t.replace(e,e.replace(B,"~")))):t)).join("\n"))):String(t);var e,n})).join("\n");e="\n"+((t,e=1,n)=>{if(n={indent:" ",includeEmptyLines:!1,...n},"string"!=typeof t)throw new TypeError(`Expected \`input\` to be a \`string\`, got \`${typeof t}\``);if("number"!=typeof e)throw new TypeError(`Expected \`count\` to be a \`number\`, got \`${typeof e}\``);if("string"!=typeof n.indent)throw new TypeError(`Expected \`options.indent\` to be a \`string\`, got \`${typeof n.indent}\``);if(0===e)return t;const r=n.includeEmptyLines?/^/gm:/^(?!\s*$)/gm;return t.replace(r,n.indent.repeat(e))})(e,4),super(e),this.name="AggregateError",Object.defineProperty(this,"_errors",{value:t})}*[Symbol.iterator](){for(const t of this._errors)yield t}}var q=z;const H=(t,e,n)=>new Promise(((r,i)=>{if(n=Object.assign({concurrency:1/0},n),"function"!=typeof e)throw new TypeError("Mapper function is required");const{concurrency:o}=n;if(!("number"==typeof o&&o>=1))throw new TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${o}\` (${typeof o})`);const s=[],a=t[Symbol.iterator]();let c=!1,u=!1,l=0,f=0;const p=()=>{if(c)return;const t=a.next(),n=f;if(f++,t.done)return u=!0,void(0===l&&r(s));l++,Promise.resolve(t.value).then((t=>e(t,n))).then((t=>{s[n]=t,l--,p()}),(t=>{c=!0,i(t)}))};for(let t=0;t(await $(t,((t,n)=>Promise.all([e(t,n),t])),n)).filter((t=>Boolean(t[0]))).map((t=>t[1]));var W=V,G=V;W.default=G;const K="undefined"!=typeof atom,Q="undefined"!=typeof atom&&(atom.inDevMode()||atom.inSpecMode()); /*! * escape-html * Copyright(c) 2012-2013 TJ Holowaychuk @@ -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:
  • ${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()}; +var Z=/["'&<>]/,J=function(t){var e,n=""+t,r=Z.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 X(t){if(K){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 F.default.promises.readFile(L.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 tt=K?async function(t){return atom.packages.resolvePackagePath(t)}:async function(t){var e;const n=L.default.join(null!==(e=process.env.ATOM_HOME)&&void 0!==e?e:L.default.join(D.default.homedir(),".atom"),"packages",t);try{return await F.default.promises.access(n,F.default.constants.R_OK),n}catch(t){return null}};function et(t,e){if(!t)throw new Error(null!=e?e:"Invariant violation")}async function nt(t){const e=await(K?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 F.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 F.default.promises.readFile(L.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 Q&&(et(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`;et("string"==typeof e.name&&e.name.length>0,i),et(null==e.minimumVersion||"string"==typeof e.minimumVersion&&e.minimumVersion.length>0,i)})),et(e.length>0,`Dependency#${n} for ${t} has no group items`);else{const r=`Dependency#${n} for ${t} is invalid`;et("string"==typeof e.name&&e.name.length>0,r),et(null==e.minimumVersion||"string"==typeof e.minimumVersion&&e.minimumVersion.length>0,r)}}))),e}async function rt(t){if(null==t.directory)return!0;if(null==t.minimumVersion)return!1;const e=await X(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 it=new Set(["✓","done"]),ot=/(?:Installing|Moving) (.*?) to .* (.*)/;let st=!0;const at=K?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)}}},ct=K?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(!K)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),st&&(st=!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=>J(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 ut=async function(t){if(et("string"==typeof t&&t.length>0,"[Package-Deps] Package name is required"),e=t,K&&(null!==(n=atom.config.get("atom-package-deps.ignored"))&&void 0!==n?n:[]).includes(e))return;var e,n;const r=await nt(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 tt(t.name)})))):{...t,directory:await tt(t.name)}))),o=await W(i,(async function(t){return Array.isArray(t)?(await Promise.all(t.map((t=>rt(t))))).every(Boolean):rt(t)}));if(0===o.length)return;const s=await ct({packageName:t,dependencies:o});if(0===s.length)return;const a=at({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 q(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;tdt(t,e,...n);for(const t of ht)dt[t]=(e,...n)=>dt(t,e,...n);lt=dt;var mt,vt={},yt={};yt=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 wt;function bt(t,e,n,r,i){if(n)for(var o in n)"ref"!==o&&"on"!==o&&(o in ft||i&&o in i||("dataset"===o?bt(t.dataset,null,n&&n.dataset,null,null):"innerHTML"!==o&&e&&ht.has(e.tag)?t.removeAttribute(yt.get(o)||o):(t[o]="",delete t[o])));if(i)for(var o in i)if("ref"!==o&&"on"!==o&&!(o in ft)){var s=n&&n[o],a=i[o];"dataset"===o?_t(t.dataset,s,a,!1):"style"===o&&"string"!=typeof a?("string"==typeof s&&(t.style="",s=null),_t(t.style,s,a,!0)):"attributes"===o?St(t,s,a):a!==s&&("innerHTML"!==o&&r&&ht.has(r.tag)?t.setAttribute(yt.get(o)||o,a):r&&"input"===r.tag&&"value"===o&&t[o]===a||(t[o]=a))}}function _t(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 St(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 ht.has(r)?(n=document.createElementNS("http://www.w3.org/2000/svg",r),i&&kt(n,i,e),o&&mt(n,null,t,e)):(n=document.createElement(r),i&&kt(n,i,e),o&&mt(n,null,t,e))}return t.domNode=n,n}function kt(t,e,n){for(let r=0;r0?(i=At.pop()).clear():i=new Map,jt(i,e,o,s));var h=Ot(f),d=h?i.get(h):null;if(null==d)t.insertBefore(vt(f,r),a.domNode),f=n[++u];else{var g=e[d];Tt(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(vt(n[e],r),m)}else if(u>l)for(let t=o;t<=s;t++){var v=e[t];v&&Pt(v,r&&r.refs)}i&&At.push(i)}(r,t.children,e.children,n),mt(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;Pt(t,n&&n.refs);const s=vt(e,n);return i&&i.insertBefore(s,o),e.domNode=s,s}}let At=[new Map,new Map,new Map,new Map];function Pt(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 Dt=null;var Ft=function(){return Dt||(Dt=new Nt),Dt};const Lt=new WeakSet;let Mt=0,Rt=0;function Bt(t){return null!=t&&!1!==t}function zt(t,e){e.context=t,e.ambiguous&&(e.ambiguous.forEach((e=>{e.context=t})),delete e.ambiguous)}function qt(t,e=!0){if(!Bt(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(!Bt(n)){const e=t.constructor&&t.constructor.name?" in "+t.constructor.name:"";throw new Error("invalid falsy value "+n+" returned from render()"+e)}zt(t,n),Mt++;let r=t.virtualNode,i=t.element,o=Ct(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&&Ft().readDocument((function(){t.readAfterUpdate()})),Mt--}function Ht(t,e=!0){Rt++,$t(t.virtualNode),1===Rt&&e&&t.element.remove(),Rt--}function $t(t){t.component&&"function"==typeof t.component.destroy?t.component.destroy():t.children&&t.children.forEach($t)}Et={initialize:function(t){if("function"!=typeof t.update)throw new Error("Etch components must implement `update(props, children)`.");let e=t.render();if(!Bt(e)){let n=t.constructor&&t.constructor.name?" in "+t.constructor.name:"";throw new Error("invalid falsy value "+e+" returned from render()"+n)}zt(t,e),t.refs={},t.virtualNode=e,t.element=vt(t.virtualNode,{refs:t.refs,listenerContext:t})},update:function(t,e=!0){if(Mt>0)return qt(t,e),Promise.resolve();let n=Ft();return Lt.has(t)||(Lt.add(t),n.updateDocument((function(){Lt.delete(t),qt(t,e)}))),n.getNextUpdatePromise()},updateSync:qt,destroy:function(t,e=!0){if(Mt>0||Rt>0)return Ht(t,e),Promise.resolve();let n=Ft();return n.updateDocument((function(){Ht(t,e)})),n.getNextUpdatePromise()},destroySync:Ht};const{initialize:Ut,update:Vt,updateSync:Wt,destroy:Gt,destroySync:Kt}=Et;function Qt(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}))}pt={dom:lt,render:vt,initialize:Ut,update:Vt,updateSync:Wt,destroy:Gt,destroySync:Kt,setScheduler:function(t){Dt=t},getScheduler:Ft};var Zt=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]",S="[object GeneratorFunction]",x="[object Map]",k="[object Number]",E="[object Object]",C="[object Promise]",T="[object RegExp]",P="[object Set]",I="[object String]",O="[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]",$="[object Uint32Array]",U=/\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=/($^)/,St=/['\n\r\u2028\u2029\\]/g,xt="\\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="['’]",It="[\\ud800-\\udfff]",Ot="["+At+"]",jt="["+xt+"]",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+")",$t="(?:"+qt+"|"+Lt+")",Ut="(?:['’](?: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,It].join("|")+")",Jt=RegExp(Pt,"g"),Yt=RegExp(jt,"g"),Xt=RegExp(Mt+"(?="+Mt+")|"+Zt+Kt,"g"),te=RegExp([qt+"?"+Ft+"+"+Ut+"(?="+[Ot,qt,"$"].join("|")+")",$t+"+"+Vt+"(?="+[Ot,qt+Ht,"$"].join("|")+")",qt+"?"+Ht+"+"+Ut,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"+xt+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[$]=!0,oe[m]=oe[v]=oe[N]=oe[y]=oe[D]=oe[w]=oe[b]=oe[_]=oe[x]=oe[k]=oe[E]=oe[T]=oe[P]=oe[I]=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[x]=se[k]=se[E]=se[T]=se[P]=se[I]=se[O]=se[z]=se[q]=se[H]=se[$]=!0,se[b]=se[_]=se[j]=!1;var ae={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},ce=parseFloat,ue=parseInt,le="object"==typeof A&&A&&A.Object===Object&&A,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,Se=ve&&ve.isSet,xe=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 Oe(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 A,st=(e=null==e?pe:mn.defaults(pe.Object(),e,mn.pick(pe,re))).Array,xt=e.Date,kt=e.Error,Et=e.Function,Ct=e.Math,Tt=e.Object,At=e.RegExp,Pt=e.String,It=e.TypeError,Ot=st.prototype,jt=Et.prototype,Nt=Tt.prototype,Dt=e["__core-js_shared__"],Ft=jt.toString,Lt=Nt.hasOwnProperty,Mt=0,Rt=(A=/[^.]+$/.exec(Dt&&Dt.keys&&Dt.keys.IE_PROTO||""))?"Symbol(src)_1."+A:"",Bt=Nt.toString,zt=Ft.call(Tt),qt=pe._,Ht=At("^"+Ft.call(Lt).replace(rt,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),$t=ge?e.Buffer:n,Ut=e.Symbol,Vt=e.Uint8Array,Wt=$t?$t.allocUnsafe:n,Gt=cn(Tt.getPrototypeOf,Tt),Kt=Tt.create,Qt=Nt.propertyIsEnumerable,Zt=Ot.splice,Xt=Ut?Ut.isConcatSpreadable:n,ee=Ut?Ut.iterator:n,ae=Ut?Ut.toStringTag:n,le=function(){try{var t=ho(Tt,"defineProperty");return t({},"",{}),t}catch(t){}}(),fe=e.clearTimeout!==pe.clearTimeout&&e.clearTimeout,he=xt&&xt.now!==pe.Date.now&&xt.now,de=e.setTimeout!==pe.setTimeout&&e.setTimeout,me=Ct.ceil,ve=Ct.floor,Me=Tt.getOwnPropertySymbols,Ve=$t?$t.isBuffer:n,vn=e.isFinite,yn=Ot.join,wn=cn(Tt.keys,Tt),bn=Ct.max,_n=Ct.min,Sn=xt.now,xn=e.parseInt,kn=Ct.random,En=Ot.reverse,Cn=ho(e,"DataView"),Tn=ho(e,"Map"),An=ho(e,"Promise"),Pn=ho(e,"Set"),In=ho(e,"WeakMap"),On=ho(Tt,"create"),jn=In&&new In,Nn={},Dn=qo(Cn),Fn=qo(Tn),Ln=qo(An),Mn=qo(Pn),Rn=qo(In),Bn=Ut?Ut.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 $n=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 Un(){}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 Oi(t,a)}else{var p=vo(t),h=p==_||p==S;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 $:return Ti(t,n);case x:return new r;case k:case I:return new r(t);case T: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 O: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 It(r);return Do((function(){t.apply(n,i)}),e)}function hr(t,e,n,r){var i=-1,o=Ie,s=!0,a=t.length,c=[],u=e.length;if(!a)return c;n&&(e=je(e,Ze(n))),r?(o=Oe,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(Sr),gr=Fi(xr,!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 Sr(t,e){return t&&br(t,e,Da)}function xr(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 Ir(t,e){return null!=t&&e in Tt(t)}function Or(t,e,r){for(var i=r?Oe:Ie,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($a(t))}function ti(t,e){var n=$a(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&&So(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 It(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]&&!Ie(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=Sn(),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 Ss(t,e){return(Gs(t)?Te:gr)(t,lo(e,3))}var xs=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&&So(t,e[0],e[1])?e=[]:n>2&&So(e[0],e[1],e[2])&&(e=[e[0]]),Wr(t,wr(e,1),[])})),Ps=he||function(){return pe.Date.now()};function Is(t,e,r){return e=r?n:e,e=t&&null==e?t.length:e,Xi(t,u,n,n,n,n,e)}function Os(t,e){var i;if("function"!=typeof e)throw new It(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 It(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 It(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 It(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=Si((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==S||"[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)==x};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)==T};var ua=Se?Ze(Se):function(t){return ia(t)&&vo(t)==P};function la(t){return"string"==typeof t||!Gs(t)&&ia(t)&&Tr(t)==I}function fa(t){return"symbol"==typeof t||ia(t)&&Tr(t)==O}var pa=xe?Ze(xe):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):Oi(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==x?an:e==P?ln:$a)(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 Sa=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])})),xa=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&&So(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 Ia(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 $a(t){return null==t?[]:Je(t,Da(t))}var Ua=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__=Oi(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 xo(t)?Ue(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=Ui((function(t,e){return t+e}),0),_c=Zi("ceil"),Sc=Ui((function(t,e){return t/e}),1),xc=Zi("floor");var kc=Ui((function(t,e){return t*e}),1),Ec=Zi("round"),Cc=Ui((function(t,e){return t-e}),0);return Hn.after=function(t,e){if("function"!=typeof e)throw new It(r);return t=va(t),function(){if(--t<1)return e.apply(this,arguments)}},Hn.ary=Is,Hn.assign=Sa,Hn.assignIn=xa,Hn.assignInWith=ka,Hn.assignWith=Ea,Hn.at=Ca,Hn.before=Os,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?So(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)?xi(hn(t),0,r):t.split(e,r):[]},Hn.spread=function(t,e){if("function"!=typeof t)throw new It(r);return e=null==e?0:bn(va(e),0),Yr((function(n){var r=n[e],i=xi(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 It(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]:Oi(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)?$n(Gt(t)):{}}return(i?Ce:Sr)(t,(function(t,r,i){return e(n,t,r,i)})),n},Hn.unary=function(t){return Is(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=$a,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=xa,Hn.extendWith=ka,lc(Hn,Hn),Hn.add=bc,Hn.attempt=ec,Hn.camelCase=Ua,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=Sc,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=$s,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&&So(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),Sr)},Hn.findLast=bs,Hn.findLastIndex=Go,Hn.findLastKey=function(t,e){return Re(t,lo(e,3),xr)},Hn.floor=xc,Hn.forEach=_s,Hn.forEachRight=Ss,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&&Sr(t,lo(e,3))},Hn.forOwnRight=function(t,e){return t&&xr(t,lo(e,3))},Hn.get=Pa,Hn.gt=Us,Hn.gte=Vs,Hn.has=function(t,e){return null!=t&&yo(t,e,Pr)},Hn.hasIn=Ia,Hn.head=Qo,Hn.identity=sc,Hn.includes=function(t,e,n,r){t=Qs(t)?t:$a(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 $e(t,sc)},Hn.meanBy=function(t,e){return $e(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?So(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?xi(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=Ss,Hn.first=Qo,lc(Hn,function(){var t={};return Sr(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)},Sr(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=Ot[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)}))}})),Sr(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__=Oi(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Oi(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Oi(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 Un;){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 Jt=f.DiagnosticCategory;function Yt(t){return{line:t.row+1,offset:t.column+1}}function Xt(t){return new h.Point(t.line-1,t.offset-1)}function te(t){return ee(t.start,t.end)}function ee(t,e){return new h.Range(Xt(t),Xt(e))}function ne(t){const e=re(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 re(t){".json"!==b.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=re(b.join(b.dirname(t),e.extends));e=Object.assign({},n,e)}return e}function ie(t){return{label:se(t.prefixDisplayParts)+t.parameters.map((t=>se(t.displayParts))).join(se(t.separatorDisplayParts))+se(t.suffixDisplayParts),documentation:se(t.documentation),parameters:t.parameters.map(oe)}}function oe(t){return{label:se(t.displayParts),documentation:se(t.documentation)}}function se(t){return t.map((t=>t.text)).join("")}const ae=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 ce(t,e){const n=new Error("Max time reached");return atom.notifications.addError(`${t} took more than ${e} seconds to complete`,{dismissable:!0,description:t+" took too long to complete and was terminated.",stack:n.stack}),n}async function ue(t,e){const n=function(t,e){const n=performance.now();let r=n;return async function(){const i=performance.now();return i-r>t&&(await new Promise(setImmediate),r=i),i-n<=e}}(100,5e3),r=new g;try{const i=atom.grammars.grammarForId(e),o=atom.grammars.languageModeForGrammarAndBuffer(i,r);r.setLanguageMode(o),r.setText(t);const s=r.getEndPosition();o.startTokenizing&&o.startTokenizing(),await async function(t){return new Promise((e=>{if(t.fullyTokenized||t.tree)e(void 0);else if(t.onDidTokenize){const n=t.onDidTokenize((()=>{n.dispose(),e(void 0)}))}else e(void 0)}))}(o);const a=o.buildHighlightIterator();if(a.getOpenScopeIds&&a.getCloseScopeIds){let t={row:0,column:0};a.seek(t);const e=[];for(;t.row"")),...a.getOpenScopeIds().map((t=>``))),a.moveToSuccessor();const i=a.getPosition();if(e.push(r.getTextInRange([t,i]).replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'")),!await n()){console.error(ce("Atom-TypeScript: Highlighter",5));break}t=i}return e.join("")}return t}finally{r.destroy()}}function le(t){return void 0!==t&&ge(b.extname(t))}function fe(){const t=atom.config.get("atom-typescript"),e=t.tsSyntaxScopes;return t.allowJS&&e.push(...t.jsSyntaxScopes),e}function pe(t){return le(t.getPath())&&he(t)}function he(t){const[e]=t.getRootScopeDescriptor().getScopesArray();return fe().includes(e)}function de(t){return null!=t}const ge=function(t,e){const n=Zt.memoize((n=>Zt.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=fe();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(de).map((t=>"."+t)))}return n.includes(t)}),5e3);function me(t,e){const n=t.getPath();if(void 0!==n){return{file:n,...e?Yt(e):function(t){const e=t.getCursorBufferPosition();return{line:e.row+1,offset:e.column+1}}(t)}}}function ve(t){const e=t.dataset.startLine;return void 0!==e?parseInt(e,10)-1:0}function ye(t){const e=t.dataset.endLine;return void 0!==e?parseInt(e,10)-1:0}function we(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=ve(n),i=ye(n);if(isFinite(r)&&isFinite(i)){if(t>=r&&e<=i){const r=we(t,e,n);return r||n}if(isFinite(i)&&e=i&&e<=o?n:void 0}function be(t){return t.spans.length>0?t.spans[0].start.line-1:0}function _e(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;ibe(t)-be(e)));for(const e of t.childItems)Se(e)}}class xe{constructor(t){this.props=t,pt.initialize(this)}async update(t){this.props={...this.props,...t},await pt.update(this)}async destroy(){await pt.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 pt.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}},pt.dom("div",{className:"header list-item",on:{click:t=>this.entryClicked(t,i)}},pt.dom("span",{className:a},i.text)),pt.dom("ol",{className:"entries list-tree"},i.childItems?i.childItems.map((t=>pt.dom(xe,{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,Qt(pt.update(this))):this.props.ctrl.gotoNode(e)}}class ke{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 pt.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=we(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||!pe(t))return this.update({navTree:null});this.editor=t,await this.loadNavTree(),this.editorScrolling=t.onDidChangeCursorPosition(this.selectAtCursorLine),this.editorChanging=t.onDidStopChanging(this.loadNavTree)},Se(t.navTree),pt.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 pt.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 pt.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(Se(t),Zt.isEqual(t,this.props.navTree))return;_e(t,this.props.navTree),this.props.navTree=t;const e=this.firstNode();if(e){const t=this.getCursorLine();void 0!==t&&this.markSelection(we(t,t,e))}}scrollTo(t){const e=t;"function"==typeof e.scrollIntoViewIfNeeded?e.scrollIntoViewIfNeeded():e.scrollIntoView()}}class Ee{constructor(t){this.comp=new ke({navTree:t.navTree})}static create(t){return Ee.instance||(Ee.instance=new Ee(t)),Ee.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(){Ee.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}}}}Ee.instance=null;var Ce,Te=u,Ae=a,Pe=s;Ce=function(t,e){return Ie(t,e)};var Ie=function(t,e){return t?Oe(t,e):new je(e)};Ce.createStream=Ie;function Oe(t,e){if(!t)throw new Error("expected readStream");if(!t.readable)throw new Error("readStream must be readable");var n=new je(e);return t.pipe(n),n}function je(t){Te.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 Te.Readable&&(e.encoding=t._readableState.encoding)}))}Ce.createLineStream=function(t){return console.log("WARNING: byline#createLineStream is deprecated and will be removed soon"),Oe(t)},Ce.LineStream=je,Ae.inherits(je,Te.Transform),je.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)},je.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 Pe.setImmediate((function(){i._pushBuffer(t,e,n)}))}}n()},je.prototype._flush=function(t){this._pushBuffer(this._chunkEncoding,0,t)},je.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 Ne{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 De=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})),Fe=new Set(Object.keys({geterr:!0,geterrForProject:!0})),Le=new Set(Object.keys({configFileDiag:!0,semanticDiag:!0,suggestionDiag:!0,syntaxDiag:!0}));class Me{constructor(t,e,n){this.tsServerPath=t,this.version=e,this.reportBusyWhile=n,this.emitter=new m,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 Ne(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 De.has(t)}(t)||this.multistepSupported&&function(t){return Fe.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 v({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(Be()).pipe(new ze)).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,Le.has(e)?this.emitter.emit(t.event,t.body):"requestCompleted"===t.event&&this.callbacks.resolveMS(t.body))}}var Re,Be=T(Ce);class ze 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 qe(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(He(e)){do{r++,i+=String.fromCharCode(e),e=t.charCodeAt(r)}while(He(e));return s=15}if($e(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($e(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 He(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 $e(t){return 10===t||13===t||8232===t||8233===t}function Ue(t){return t>=48&&t<=57}(Re||(Re={})).DEFAULT={allowTrailingComma:!1};var Ve,We,Ge=function(t,e,n){void 0===e&&(e=[]),void 0===n&&(n=Re.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=Re.DEFAULT);var r=qe(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 S(){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 x(){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 x();case 1:return S();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]},Ke=x,Qe=b;We=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 Ze,Je,Ye,Xe,tn,en,nn,rn,on,sn,an=b,cn=!1;function un(){Je={},Ye="win32"===process.platform,Xe=/^([a-zA-Z]:|[\\\/]{2}[^\\\/]+[\\\/]+[^\\\/]+)?([\\\/])?([\s\S]*?)$/,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,r,i,o,s=(e=t,n=Xe.exec(e),r=(n[1]||"")+(n[2]||""),i=n[3]||"",o=tn.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)}},nn=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,(rn={}).parse=function(t){if("string"!=typeof t)throw new TypeError("Parameter 'pathString' must be a string, not "+typeof t);var e,n=(e=t,nn.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)}},Je=Ye?en.parse:rn.parse,on=rn.parse,Je.posix=on,sn=en.parse,Je.win32=sn}var ln=an.parse||(cn||(cn=!0,un()),Je),fn=function(t,e){var n="/";/^([A-Za-z]:)/.test(t)?n="":/^\\\\/.test(t)&&(n="\\\\");for(var r=[t],i=ln(t);i.dir!==r[r.length-1];)r.push(i.dir),i=ln(i.dir);return r.reduce((function(t,r){return t.concat(e.map((function(t){return an.resolve(n,r,t)})))}),[])};Ze=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 fn(t,r)}),e);var i=fn(t,r);return e&&e.paths?i.concat(e.paths):i};var pn;pn=function(t,e){return e||{}};var hn,dn,gn={},mn={},vn=Array.prototype.slice,yn=Object.prototype.toString;function wn(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 bn(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}'),hn=function(t,e){return gn(_n,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(An[i]||0,10),s=parseInt(r[i]||0,10);if(o!==s)return"<"===n?o="===n&&o>=s}return">="===n}function In(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 Nn={};for(var Dn in jn)Object.prototype.hasOwnProperty.call(jn,Dn)&&(Nn[Dn]=On(jn[Dn]));Ve.core=Nn;Ve.isCore=function(t){return hn(t)};var Fn=x,Ln=b,Mn=Fn.realpathSync&&"function"==typeof Fn.realpathSync.native?Fn.realpathSync.native:Fn.realpathSync,Rn=function(t){try{var e=Fn.statSync(t)}catch(t){if(t&&("ENOENT"===t.code||"ENOTDIR"===t.code))return!1;throw t}return e.isFile()||e.isFIFO()},Bn=function(t){try{var e=Fn.statSync(t)}catch(t){if(t&&("ENOENT"===t.code||"ENOTDIR"===t.code))return!1;throw t}return e.isDirectory()},zn=function(t){try{return Mn(t)}catch(t){if("ENOENT"!==t.code)throw t}return t},qn=function(t,e,n){return n&&!1===n.preserveSymlinks?t(e):e},Hn=function(t,e){var n=t(e);try{return JSON.parse(n)}catch(t){}};async function $n(t,e){const{NODE_PATH:n}=process.env,r=e+".js",i=await async function(t,e){return new Promise(((n,r)=>Un(t,e,((t,e)=>{t?r(t):void 0===e?r(new Error("Module path is undefined")):n(e)}))))}("typescript/lib/"+r,{basedir:b.dirname(t),paths:void 0!==n?n.split(b.delimiter):void 0}).catch((async()=>{const e=await async function(t){const e=await async function(t){let e=t,n=b.dirname(e);for(;e!==n;){const t=await Wn(e,[[".atom-typescript.json"],[".atom","atom-typescript.json"],[".vscode","settings.json"]]);if(void 0!==t)return{basedir:e,configFile:t};e=n,n=b.dirname(e)}}(t);if(e)try{const t=Ge(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=b.dirname(t["typescript.tsdk"])}return b.isAbsolute(r)?r:b.join(e.basedir,r)}catch(t){console.warn(t)}var n}(b.dirname(t));if(void 0!==e){const t=b.join(e,"lib",r);if(await Vn(t))return t}const n=atom.config.get("atom-typescript.tsdkPath");if(n){const t=b.join(n,"lib",r);if(await Vn(t))return t}return require.resolve("typescript/lib/"+r)})),o=b.resolve(i,"../../package.json");return{version:require(o).version,pathToBin:i}}Ve.sync=function(t,e){if("string"!=typeof t)throw new TypeError("Path must be a string.");var n=pn(0,e),r=n.isFile||Rn,i=n.readFileSync||Fn.readFileSync,o=n.isDirectory||Bn,s=n.realpathSync||zn,a=n.readPackageSync||Hn;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||Ln.dirname(We()),p=n.filename||f;n.paths=n.paths||[];var h=qn(s,Ln.resolve(f),n);if(/^(?:\.\.?(?:\/|$)|\/|([A-Za-z]:)?[/\\])/.test(t)){var d=Ln.resolve(h,t);"."!==t&&".."!==t&&"/"!==t.slice(-1)||(d+="/");var g=y(d)||b(d);if(g)return qn(s,g,n)}else{if(l&&hn(t))return t;var m=function(t,e){for(var r=function(){return function(t,e,n){for(var r=Ze(e,n,t),i=0;ix.access(t,x.constants.F_OK,(t=>{e(!t)}))))}async function Wn(t,e){for(const n of e){const e=b.join(t,...n);if(await Vn(e))return e}}class Gn{constructor(t){this.reportBusyWhile=t,this.clients=new Map,this.memoizedClients=new Map,this.emitter=new m,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 $n(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 Me(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 Kn(t){return{grammarScopes:fe(),priority:100,async highlight(e,n){if(!pe(e))return;const r=me(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(te))}(r.file,o.body)):void 0}}}async function Qn(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 Zn=Symbol.for("react.element"),Jn={dom:(t,e,...n)=>n.length>0?{$$typeof:Zn,type:t,ref:null,props:{...e,children:n}}:{$$typeof:Zn,type:t,ref:null,props:{...e}}};class Yn{constructor(t){this.getClient=t,this.providerName="TypeScript type tooltips",this.priority=100,this.grammarScopes=fe()}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 Qn(i,Jn,Xn);return{component:()=>Jn.dom("div",{className:"atom-typescript-datatip-tooltip"},o),range:h.Range.fromObject([Xt(i.start),Xt(i.end)])}}catch(t){return}}}async function Xn(t){const e=atom.config.get("editor.fontFamily"),n=await ue(t.replace(/\r?\n$/,""),"source.ts");return Jn.dom("div",{style:{fontFamily:e},className:"atom-typescript-datatip-tooltip-code",dangerouslySetInnerHTML:{__html:n}})}function tr(t){const e=te(t);return{path:t.file,position:e.start,range:e,language:"TypeScript"}}function er(t){return{uri:t.file,range:ee(t.start,t.end),name:void 0}}class nr{constructor(t){this.props=t,pt.initialize(this)}async update(t){return this.props={...this.props,...t},pt.update(this)}render(){const t={fontFamily:atom.config.get("editor.fontFamily")};return pt.dom("div",{className:"editor editor-colors",style:t,innerHTML:this.props.highlightedText})}}var rr,ir,or,sr={},ar=!1;function cr(){return ar||(ar=!0,function(){var t,e;t=b.sep,rr=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(ur={})),ur}var pr,hr,dr,gr=!1;function mr(){return gr||(gr=!0,function(){var t;t=b.sep,pr=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;spt.dom("span",{className:t.type},t.text))))}match(t){return t.query?function(t,e){let n=0,r=[];const i=[],o=sr.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 yr={},wr=yr&&yr.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(yr,"__esModule",{value:!0});const br=h,_r=wr(pt),Sr=_r.default.dom,xr=wr(sr);yr=class{constructor(t){this.props=t,this.props.hasOwnProperty("initialSelectionIndex")||(this.props.initialSelectionIndex=0),t.initiallyVisibleItemCount&&this.initializeVisibilityObserver(),this.computeItems(!1),this.disposables=new br.CompositeDisposable,_r.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 br.Disposable((()=>{e.removeEventListener("blur",n)})))}static setScheduler(t){_r.default.setScheduler(t)}static getScheduler(){return _r.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(),_r.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(),_r.default.update(this)}render(){return Sr.div({},Sr(br.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&&_r.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)})})),Sr.ol({className:t,ref:"items"},...this.listItems)}return!this.props.loadingMessage&&this.props.emptyMessage?Sr.span({ref:"emptyMessage"},this.props.emptyMessage):""}renderErrorMessage(){return this.props.errorMessage?Sr.span({ref:"errorMessage"},this.props.errorMessage):""}renderInfoMessage(){return this.props.infoMessage?Sr.span({ref:"infoMessage"},this.props.infoMessage):""}renderLoadingMessage(){return this.props.loadingMessage?Sr.div({className:"loading"},Sr.span({ref:"loadingMessage",className:"loading-message"},this.props.loadingMessage),this.props.loadingBadge?Sr.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=xr.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),_r.default.getScheduler().getNextUpdatePromise()):_r.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 kr{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 br.Disposable((()=>{this.element.removeEventListener("mousedown",this.mouseDown),this.element.removeEventListener("mouseup",this.mouseUp),this.element.removeEventListener("click",this.didClick)})),_r.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,_r.default.getScheduler().updateDocument(this.scrollIntoViewIfNeeded.bind(this))}scrollIntoViewIfNeeded(){this.selected&&this.element.scrollIntoViewIfNeeded(!1)}}var Er=T(yr);async function Cr({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||Qt(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 Er({items:[],elementForItem:t=>pt.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&&Qt(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 Tr=[];function Ar(t,e,n){Tr.push({selector:t,command:e,desc:n})}async function Pr(t,e,n){const r=Promise.all(t.body.refs.map((async t=>{var e,n;const r=(await new Promise(((e,n)=>x.readFile(t.file,((t,r)=>{t?n(t):e(r.toString("utf-8"))}))))).split(/\r?\n/g),i=void 0!==t.contextStart&&void 0!==t.contextEnd?r.slice(t.contextStart.line-1,t.contextEnd.line):r,o=(await ue(i.join("\n"),"source.tsx")).split("\n")[t.start.line-(null!==(e=null===(n=t.contextStart)||void 0===n?void 0:n.line)&&void 0!==e?e:1)];return{...t,hlText:o}}))),i=await Cr({items:r,itemTemplate:(t,e)=>pt.dom("li",null,pt.dom(vr,{label:atom.project.relativize(t.file),query:e.getFilterQuery()}),pt.dom("div",{className:"pull-right"},"line: ",t.start.line),pt.dom(nr,{highlightedText:t.hlText})),itemFilterKey:"file"});i&&await n(e,i)}async function Ir(t,e,n){if(t.body)if(t.body.length>1){const r=await Cr({items:t.body,itemTemplate:(t,e)=>pt.dom("li",null,pt.dom(vr,{label:t.file,query:e.getFilterQuery()}),pt.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 Or(t){const e=t.spans.map(te).reduce(((t,e)=>e.union(t)));return{kind:Nr[t.kind],plainText:t.text,startPosition:e.start,endPosition:e.end,landingPosition:t.nameSpan?te(t.nameSpan).start:void 0,children:t.childItems?t.childItems.map(Or).sort(jr):[]}}function jr(t,e){const n=t.landingPosition?t.landingPosition:t.startPosition,r=e.landingPosition?e.landingPosition:e.startPosition;return n.compare(r)}Ar("atom-text-editor","typescript:find-references",(t=>({description:"Find where symbol under text cursor is referenced",async didDispatch(e){const n=me(e);if(!n)return;const r=await t.getClient(n.file),i=await r.execute("references",n);await Pr(i,e,t.histGoForward)}}))),Ar("atom-text-editor","typescript:go-to-declaration",(t=>({description:"Go to declaration of symbol under text cursor",async didDispatch(e){const n=me(e);if(!n)return;const r=await t.getClient(n.file),i=await r.execute("definition",n);await Ir(i,e,t.histGoForward)}})));const Nr={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 Dr{constructor(t){this.getClient=t,this.triggerCharacters=new Set([]),this.grammarScopes=fe(),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(ie),activeParameter:i.argumentIndex,activeSignature:i.selectedItemIndex}}catch(t){return}}}function Fr(t){return pt.dom("li",null,t.description)}class Lr{constructor(t,e){this.getClient=t,this.applyEdits=e,this.selector=fe().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(Mr);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($r.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(Br(t.scopeDescriptor.getScopesArray(),"string.template.")&&!Br(t.scopeDescriptor.getScopesArray(),"template.expression."))return[];try{let i=await this.getSuggestionsWithCache({prefix:n,location:e,triggerCharacter:r,activatedManually:t.activatedManually});return i=sr.filter(i,n,{key:"displayText"}),i.map((r=>({replacementPrefix:r.replacementRange?t.editor.getTextInBufferRange(r.replacementRange):n,location:e,...this.getDetailsFromCache(r),...qr(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);Qt((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 Cr({items:r.details.codeActions,itemTemplate:Fr,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=Rr(this.lastSuggestions.prefix,n.offset),i=Rr(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(zr.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(zr.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 Mr=/(?:(?![\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 Rr(t,e){return e-("."===t?0:t.length)}function Br(t,e){for(const n of t)if(n.includes(e))return!0;return!1}function zr(t,e){return{displayText:e.name,text:void 0!==e.insertText?e.insertText:e.name,leftLabel:e.kind,replacementRange:e.replacementSpan?te(e.replacementSpan):void 0,type:Hr[e.kind],isMemberCompletion:t,identifier:void 0!==e.source?{name:e.name,source:e.source}:e.name,hasAction:e.hasAction}}function qr(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 Hr={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},$r=new Set(Object.keys({".":null,'"':null,"'":null,"`":null,"/":null,"@":null,"<":null,"#":null}));async function Ur(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 Vr(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")}Ar("atom-text-editor","typescript:refactor-selection",(t=>({description:"Get a list of applicable refactors to selected code",async didDispatch(e){const n=me(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 Ur(i,o);if(0===s.length)return void atom.notifications.addInfo("AtomTS: No applicable refactors for the selection");const a=await Cr({items:s,itemTemplate:(t,e)=>pt.dom("li",null,pt.dom(vr,{label:`${t.refactorDescription}: ${t.actionDescription}`,query:e.getFilterQuery()})),itemFilterKey:"actionDescription"});void 0!==a&&await Vr(a,i,t)}})));class Wr{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=>te(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 Ur(r,{file:n,...Yt(e)});return a.push(...c),a}async applyFix(t){if("changes"in t)return this.applyEdits(t.changes);return Vr(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 Gr(t,e){let n;try{return await new Promise(((r,i)=>{try{const o=new v({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()}}Ar("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})}}}))),Ar("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(`${b.sep}node_modules${b.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})}}}))),Ar("atom-workspace","typescript:clear-errors",(t=>({description:"Clear error messages",didDispatch(){t.clearErrors()}}))),Ar("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(te(e[n]),e[n].newText)}(e,s)}))}}))),Ar("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 $n(r,"tsc")).pathToBin;for(const t of n)t.contains(r)&&(await Gr(i,t.getPath()),atom.notifications.addSuccess("Successfully created tsconfig.json in "+t.getPath()))}}))),Ar("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)}}))),Ar("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 Kr,Qr,Zr={},Jr=!1;function Yr(){return Jr||(Jr=!0,Kr={},function(){var t="object"==typeof self&&self.self===self&&self||"object"==typeof A&&A.global===A&&A||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===Kr||Kr.nodeType?t._=h:(!module.nodeType&&Kr&&(Kr=h),Qr=h,Kr._=Qr),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<=S};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),$=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=$(q),h.unescape=$(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}))}()),Kr}var Xr,ti=!1;function ei(){return ti||(ti=!0,function(){var t,e,n,r,i,o,s,a,c=[].slice;a=Yr(),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);vi.lastIndex=r;var c=vi.exec(t);return s=i,i+=c[0],o=s+c[1],r=vi.lastIndex,u[o]||e&&e[o]===o?process.nextTick(f):e&&Object.prototype.hasOwnProperty.call(e,o)?d(e[o]):gi.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(!di){var i=r.dev.toString(32)+":"+r.ino.toString(32);if(c.hasOwnProperty(i))return h(null,c[i],o)}gi.stat(o,(function(t){if(t)return n(t);gi.readlink(o,(function(t,e){di||(c[i]=e),h(t,e)}))}))}function h(t,r,i){if(t)return n(t);var o=hi.resolve(s,r);e&&(e[i]=o),d(o)}function d(e){t=hi.resolve(e,t.slice(r)),l()}l()},pi.realpath=bi),pi}var ki,Ei,Ci,Ti,Ai,Pi,Ii,Oi=!1;function ji(t){return t&&"realpath"===t.syscall&&("ELOOP"===t.code||"ENOMEM"===t.code||"ENAMETOOLONG"===t.code)}function Ni(t,e,n){if(Pi)return Ci(t,e,n);"function"==typeof e&&(n=e,e=null),Ci(t,e,(function(r,i){ji(r)?Ii.realpath(t,e,n):n(r,i)}))}function Di(t,e){if(Pi)return Ti(t,e);try{return Ti(t,e)}catch(n){if(ji(n))return Ii.realpathSync(t,e);throw n}}function Fi(){Ei.realpath=Ni,Ei.realpathSync=Di}function Li(){Ei.realpath=Ci,Ei.realpathSync=Ti}function Mi(){return Oi||(Oi=!0,ki={},ki=Ni,Ni.realpath=Ni,Ni.sync=Di,Ni.realpathSync=Di,Ni.monkeypatch=Fi,Ni.unmonkeypatch=Li,Ci=(Ei=x).realpath,Ti=Ei.realpathSync,Ai=process.version,Pi=/^v[0-5]\./.test(Ai),Ii=xi()),ki}var Ri,Bi,zi=!1;function qi(){return zi||(zi=!0,Ri={},Ri=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 Gi(){return $i||($i=!0,Hi={},Hi=Ui,Ui.range=Wi),Hi}var Ki,Qi,Zi,Ji,Yi,Xi,to,eo,no=!1;function ro(t){return parseInt(t,10)==t?parseInt(t,10):t.charCodeAt(0)}function io(t){return t.split(Ji).join("\\").split(Yi).join("{").split(Xi).join("}").split(to).join(",").split(eo).join(".")}function oo(t){if(!t)return[""];var e=[],n=Zi("{","}",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=oo(o);return o.length&&(s[s.length-1]+=a.shift(),s.push.apply(s,a)),e.push.apply(e,s),e}function so(t){return t?("{}"===t.substr(0,2)&&(t="\\{\\}"+t.substr(2)),fo(function(t){return t.split("\\\\").join(Ji).split("\\{").join(Yi).split("\\}").join(Xi).split("\\,").join(to).split("\\.").join(eo)}(t),!0).map(io)):[]}function ao(t){return"{"+t+"}"}function co(t){return/^-?0\d/.test(t)}function uo(t,e){return t<=e}function lo(t,e){return t>=e}function fo(t,e){var n=[],r=Zi("{","}",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(/,.*\}/)?fo(t=r.pre+"{"+r.body+Xi+r.post):[t];if(a)i=r.body.split(/\.\./);else if(1===(i=oo(r.body)).length&&1===(i=fo(i[0],!1).map(ao)).length)return(f=r.post.length?fo(r.post,!1):[""]).map((function(t){return r.pre+i[0]+t}));var u,l=r.pre,f=r.post.length?fo(r.post,!1):[""];if(a){var p=ro(i[0]),h=ro(i[1]),d=Math.max(i[0].length,i[1].length),g=3==i.length?Math.abs(ro(i[2])):1,m=uo;h0){var _=new Array(b+1).join("0");w=y<0?"-"+_+w.slice(1):_+w}}u.push(w)}}else u=Qi(i,(function(t){return fo(t,!1)}));for(var S=0;S65536)throw new TypeError("pattern is too long");var n=this.options;if(!n.noglobstar&&"**"===t)return mo;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+=bo,o=!0;break;case"?":i+=wo,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 I=C.split("(").length-1,O=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 Ro(){return Co||(Co=!0,Mo()),ho}var Bo,zo=!1;function qo(){return zo||(zo=!0,Bo={},Bo="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}),Bo}var Ho,$o,Uo,Vo=!1;function Wo(t){return"/"===t.charAt(0)}function Go(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 Ko(){return Vo||(Vo=!0,Ho={},Ho="win32"===process.platform?Go:Wo,$o=Wo,Ho.posix=$o,Uo=Go,Ho.win32=Uo),Ho}var Qo,Zo,Jo,Yo,Xo,ts,es,ns,rs,is,os,ss,as,cs=!1;function us(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function ls(t,e){return t.toLowerCase().localeCompare(e.toLowerCase())}function fs(t,e){return t.localeCompare(e)}function ps(t){var e=null;if("/**"===t.slice(-3)){var n=t.replace(/(\/\*\*)+$/,"");e=new as(n,{dot:!0})}return{matcher:new as(t,{dot:!0}),gmatcher:e}}function hs(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(ps))}(t,n),t.changedCwd=!1;var r=process.cwd();us(n,"cwd")?(t.cwd=is.resolve(n.cwd),t.changedCwd=t.cwd!==r):t.cwd=r,t.root=n.root||is.resolve(t.cwd,"/"),t.root=is.resolve(t.root),"win32"===process.platform&&(t.root=t.root.replace(/\\/g,"/")),t.cwdAbs=ss(t.cwd)?t.cwd:ms(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 as(e,n),t.options=t.minimatch.options}function ds(t){for(var e=t.nounique,n=e?[]:Object.create(null),r=0,i=t.matches.length;rthis.maxLength)return!1;if(!this.stat&&Ps(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=_s.lstatSync(e)}catch(t){if(t&&("ENOENT"===t.code||"ENOTDIR"===t.code))return this.statCache[e]=!1,!1}if(o&&o.isSymbolicLink())try{i=_s.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},Ds.prototype._mark=function(t){return Ts.mark(this,t)},Ds.prototype._makeAbs=function(t){return Ts.makeAbs(this,t)}),bs}var Ls,Ms=!1;function Rs(t,e){if(t&&e)return Rs(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 Qs[t]}}))}(t))}function Xs(t){for(var e=t.length,n=[],r=0;r1)return!0;for(var i=0;ithis.maxLength)return e();if(!this.stat&&ha(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=da("stat\0"+n,(function(r,i){if(i&&i.isSymbolicLink())return na.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&&na.lstat(n,c)},_a.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 xa(){return wa||(wa=!0,Sa()),ea}var ka,Ea,Ca,Ta,Aa,Pa,Ia,Oa,ja,Na=!1;function Da(t){["unlink","chmod","stat","lstat","rmdir","readdir"].forEach((function(e){t[e]=t[e]||Ta[e],t[e+="Sync"]=t[e]||Ta[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||Ia}function Fa(t,e,n){"function"==typeof e&&(n=e,e={}),Ea(t,"rimraf: missing path"),Ea.equal(typeof t,"string","rimraf: path should be a string"),Ea.equal(typeof n,"function","rimraf: callback function required"),Ea(e,"rimraf: invalid options argument provided"),Ea.equal(typeof e,"object","rimraf: options should be object"),Da(e);var r=0,i=null,o=0;if(e.disableGlob||!Aa.hasMagic(t))return s(null,[t]);function s(t,s){return t?n(t):0===(o=s.length)?n():void s.forEach((function(t){La(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=w(t),n=w(e),!r||!n||t.toLowerCase()===e.toLowerCase()&&r.dev===n.dev&&r.ino===n.ino},Zr=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(Zr);class $a{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 Ua{constructor(t){this.props=t,pt.initialize(this)}async update(t){this.props={...this.props,...t},await pt.update(this)}render(){return pt.dom("div",{className:"atomts-rename-view",ref:"main"},pt.dom("div",{className:"block"},pt.dom("div",null,pt.dom("span",{ref:"title"},this.props.title),pt.dom("span",{className:"subtle-info-message"},pt.dom("span",null,"Close this panel with "),pt.dom("span",{className:"highlight"},"esc"),pt.dom("span",null," key. And commit with the "),pt.dom("span",{className:"highlight"},"enter"),pt.dom("span",null," key."))),pt.dom("div",{className:"find-container block"},pt.dom("div",{className:"editor-container"},pt.dom($a,{ref:"editor",initialText:this.props.initialText,selectAll:this.props.selectAll}))),this.renderValidationMessage()))}async destroy(){await pt.destroy(this)}focus(){return this.refs.editor.focus()}getText(){return this.refs.editor.getModel().getText()}renderValidationMessage(){return void 0!==this.props.validationMessage?pt.dom("div",{className:"highlight-error"},this.props.validationMessage):null}}async function Va(t){const e=new Ua({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?Qt(e.update({validationMessage:i})):n(r)}}))}))}finally{n.destroy(),i.dispose(),r&&r.focus()}}function Wa(t){const e=new d;for(const n of Tr)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();pe(e)?await r.didDispatch(e,(()=>t.abortKeyBinding())):(t.abortKeyBinding(),he(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){Ga(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){Ga(t)}}}))}return e}function Ga(t){atom.notifications.addFatalError("Something went wrong, see details below.",{detail:t.message,dismissable:!0,stack:t.stack})}Ar("atom-text-editor","typescript:rename-file",(t=>({description:"Rename current file",async didDispatch(e){const n=e.getPath();if(!n)return;const r=await Va({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)=>{Zr.move(n,r,(n=>{n?i(n):(e.getBuffer().setPath(r),t())}))}))}}))),Ar("atom-text-editor","typescript:rename-refactor",(t=>({description:"Rename symbol under text cursor everywhere it is used",async didDispatch(e){const n=me(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 Va({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})))}))))}}))),Ar("atom-workspace","typescript:restart-all-servers",(t=>({description:"Kill all tsserver instances. They will be auto-restarted",async didDispatch(){t.killAllServers()}}))),Ar("atom-workspace","typescript:return-from-declaration",(t=>({description:"If used `go-to-declaration`, return to previous text cursor position",async didDispatch(){await t.histGoBack()}}))),Ar("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()}}))),Ar("atom-text-editor","typescript:toggle-semantic-view",(t=>({description:"Toggle semantic view outline",didDispatch(){t.toggleSemanticViewController()}}))),Ar("atom-text-editor","typescript:show-tooltip",(t=>({description:"Show type tooltip at current text cursor position",didDispatch:async e=>t.showTooltipAt(e)}))),Ar("atom-text-editor","typescript:show-signature-help",(t=>({description:"Show signature help tooltip at current text cursor position",didDispatch:async e=>t.showSigHelpAt(e)}))),Ar("atom-text-editor","typescript:hide-signature-help",(t=>({description:"Hide the currently visible signature help",async didDispatch(e,n){t.hideSigHelpAt(e)||n()}}))),Ar("atom-text-editor","typescript:signature-help-next",(t=>({description:"Show next signature help if available",async didDispatch(e,n){t.rotateSigHelp(e,1)||n()}}))),Ar("atom-text-editor","typescript:signature-help-prev",(t=>({description:"Show previous signature help if available",async didDispatch(e,n){t.rotateSigHelp(e,-1)||n()}}))),Ar("atom-text-editor","typescript:toggle-file-symbols",(t=>({description:"Toggle view for finding file symbols",async didDispatch(e){t.toggleFileSymbolsView(e)}}))),Ar("atom-text-editor","typescript:toggle-project-symbols",(t=>({description:"Toggle view for finding file symbols",async didDispatch(e){t.toggleProjectSymbolsView(e)}})));class Ka{constructor(t,e){this.children=e,this.props={...t,delay:{show:0,hide:0}},pt.initialize(this),this.tooltipDisposable=atom.tooltips.add(this.element,this.props)}async update(t,e){this.props={...this.props,...t},this.children=e,await pt.update(this),this.tooltipDisposable.dispose(),this.tooltipDisposable=atom.tooltips.add(this.element,this.props)}render(){return pt.dom("div",{className:"inline-block"},this.children?this.children:null)}async destroy(){await pt.destroy(this),this.tooltipDisposable.dispose()}}class Qa{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(),pt.initialize(this),this.disposables.add(atom.config.onDidChange("atom-typescript.buildStatusTimeout",(({newValue:t})=>{this.setHideBuildStatus(t),Qt(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 pt.update(this)}render(){if(this.hiddenBuildStatus)return pt.dom("span",null);let t,e;return this.props.buildStatus.success?(t="highlight-success",e="Emit Success"):(t="highlight-error",e="Emit Failed"),pt.dom(Ka,{title:this.props.buildStatus.success?"Build was successful":"Build failed; click to show error message"},pt.dom("span",{className:t,on:{click:this.buildStatusClicked}},e))}async destroy(){await pt.destroy(this)}resetBuildStatusTimeout(){this.hiddenBuildStatus=!1,this.props.buildStatus.success&&this.hideBuildStatus()}setHideBuildStatus(t){this.hideBuildStatus=t>0?Zt.debounce((()=>{this.hiddenBuildStatus=!0,Qt(pt.update(this))}),1e3*t):0===t?()=>{this.hiddenBuildStatus=!0}:()=>{}}}class Za{constructor(t){this.props={...t},pt.initialize(this)}async update(t){this.props={...this.props,...t},await pt.update(this)}render(){return pt.dom(Ka,{title:()=>this.props.tsConfigPath.startsWith("/dev/null")?"No tsconfig.json":"Click to open "+atom.project.relativize(this.props.tsConfigPath)},pt.dom("a",{className:"inline-block",href:"",on:{click:t=>{t.preventDefault(),this.openConfigPath()}}},this.props.tsConfigPath.startsWith("/dev/null")?"No project":_((t=this.props.tsConfigPath,"~"+atom.project.relativize(t)))));var t}async destroy(){await pt.destroy(this)}openConfigPath(){this.props.tsConfigPath.startsWith("/dev/null")?atom.notifications.addInfo("No tsconfig for current file"):Qt(atom.workspace.open(this.props.tsConfigPath))}}class Ja{constructor(t={}){this.props={visible:!0,pending:[],progress:{max:0,value:0},...t},pt.initialize(this)}async update(t){this.props={...this.props,...t},await pt.update(this)}render(){return pt.dom("ts-status-panel",{className:this.props.visible?"":"hide"},this.renderVersion(),this.renderPending(),this.renderConfigPath(),this.renderStatus(),this.renderProgress())}async destroy(){await pt.destroy(this)}dispose(){Qt(this.destroy())}async show(){await this.update({visible:!0})}async hide(){await this.update({visible:!1})}renderVersion(){return void 0!==this.props.clientVersion?pt.dom(Ka,{title:"Active TypeScript version"},this.props.clientVersion):null}renderPending(){return this.props.pending.length>0?pt.dom(Ka,{title:`Pending Requests:
    ${this.props.pending.map((({title:t})=>`
  • ${t}
  • `)).join("")}
`,html:!0},pt.dom("span",{ref:"pendingCounter"},this.props.pending.length.toString()),pt.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?pt.dom(Za,{tsConfigPath:this.props.tsConfigPath}):null}renderStatus(){return this.props.buildStatus?pt.dom(Qa,{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=me(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 Cr({items:this.getHistory().slice().reverse().map(((t,e)=>({...t,idx:e}))),itemTemplate:(t,e)=>pt.dom("li",{className:"two-lines"},pt.dom("div",{className:"primary-line"},pt.dom(vr,{label:t.file,query:e.getFilterQuery()})),pt.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 Xa{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=Zt.debounce((()=>{Qt(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(!pe(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=te(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 tc{constructor(t){this.disposables=new d,this.disposables.add(atom.workspace.observeTextEditors((e=>{const n=new Xa(t,e);this.disposables.add(n,e.onDidDestroy((()=>{this.disposables.remove(n),n.dispose()})))})))}dispose(){this.disposables.dispose()}}function ec(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 nc{constructor(t){this.parent=t,this.props={left:0,right:0,top:0,bottom:0},pt.initialize(this)}async destroy(){return pt.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 pt.update(this)}writeAfterUpdate(){ec(this.element,this.parent,this.props,atom.config.get("atom-typescript").sigHelpPosition)}render(){return pt.dom("div",{className:"atom-typescript-tooltip tooltip",key:this.sigHelpHash()},pt.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)=>pt.dom("div",{className:i(n)},pt.dom("div",null,se(e.prefixDisplayParts),this.renderSigHelpParams(e.parameters,t.argumentIndex),se(e.suffixDisplayParts),pt.dom("div",{className:"atom-typescript-tooltip-signature-help-documentation"},se(e.documentation))))))}renderSigHelpParams(t,e){return t.map(((t,n)=>pt.dom("span",{className:"atom-typescript-tooltip-signature-help-parameter"},n>0?", ":null,pt.dom("span",{className:n===e?"atom-typescript-tooltip-signature-help-selected":void 0},se(t.displayParts)))))}}class rc{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 nc(r),r.appendChild(this.view.element);const i=Zt.debounce(this.updateTooltip.bind(this),100,{leading:!0});this.disposables.add(this.editor.onDidChangeCursorPosition((t=>{n=t.newBufferPosition,Qt(i(n))})),r.onDidChangeScrollTop((()=>{setImmediate((()=>this.updateTooltipPosition(n)))})),r.onDidChangeScrollLeft((()=>{setImmediate((()=>this.updateTooltipPosition(n)))}))),Qt(this.updateTooltip(n))}isDisposed(){return this.cancelled}dispose(){this.cancelled||(this.cancelled=!0,this.disposables.dispose(),Qt(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);Qt(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(!pe(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 ic{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(/[<(,]/)&&Qt(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())&&(Qt(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 rc(this.deps,t,e))}}function oc(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 y((()=>{t.removeEventListener(e,i)}))}class sc{constructor(){this.tooltip=null,this.props={left:0,right:0,top:0,bottom:0},pt.initialize(this)}async destroy(){return pt.destroy(this)}async update(t){this.props={...this.props,...t},this.tooltip=await Qn(this.props.info,pt,(t=>pt.dom("div",{className:"atom-typescript-tooltip-tooltip-code"},t))),await pt.update(this)}writeAfterUpdate(){ec(this.element,document.body,this.props,atom.config.get("atom-typescript").tooltipPosition)}render(){return pt.dom("div",{className:"atom-typescript-tooltip tooltip"},pt.dom("div",{className:"tooltip-inner"},this.tooltip))}}class ac{constructor(t,e,n,r){this.getClient=t,this.cancelled=!1,Qt(this.initialize(e,n,r))}dispose(){this.cancelled=!0,this.view&&(Qt(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 sc,document.body.appendChild(this.view.element),await this.view.update({...t,info:e})}}class cc{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&&pe(t)&&k.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(oc(e,"mousemove",".scroll-view",this.trackMouseMovement(t)),oc(e,"mouseout",".scroll-view",this.clearExprTypeTimeout),oc(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 ac(this.getClient,t,e,n)}hideExpressionType(){this.pendingTooltip&&(this.pendingTooltip.dispose(),this.pendingTooltip=void 0)}}class uc{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&&Qt(this.view.setGetClient(this.getClient)),this.subscriptions.add(new y((()=>{this.view&&(atom.workspace.hide(this.view),Qt(this.view.destroy()))})),atom.config.observe("atom-typescript.showSemanticView",(t=>{t?Qt(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=Ee.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 lc{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 lc({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 lc({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 fc(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(hc(n.childItems)):[]}async function pc(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 lc.fromNavto(n,e)}(r)):[]}function*hc(t,e){t.sort(((t,e)=>t.spans[0].start.line-e.spans[0].start.line));for(const n of t){const t=lc.fromNavTree(n,e);yield t,n.childItems&&(yield*hc(n.childItems,t))}}async function dc(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 gc(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 Cr({items:fc(n,e),itemTemplate:({name:t,position:e},n)=>pt.dom("li",{className:"two-lines"},pt.dom("div",{className:"primary-line"},pt.dom(vr,{label:t,query:n.getFilterQuery()})),pt.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 dc(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 mc{constructor(t){this.deps=t}toggleFileView(t){Qt(gc(t,this.deps))}toggleProjectView(t){Qt(async function(t,e){const n=t.getPath();if(void 0!==n){const r=await Cr({items:t=>pc(n,t,e),itemTemplate({name:t,position:e,file:n},r){const i=atom.project.relativize(n);return pt.dom("li",{className:"two-lines"},pt.dom("div",{className:"primary-line"},pt.dom(vr,{label:t,query:r.getFilterQuery()})),pt.dom("div",{className:"secondary-line"},`File ${i} line ${e.row+1}`))},itemFilterKey:"name"});r&&await dc(r,t,e.histGoForward)}}(t,this.deps))}dispose(){}}class vc{constructor(){this.errors=new Map,this.fileGrammars=new Map,this.pushErrors=Zt.debounce(this.pushErrors.bind(this),100)}*getErrorsInRange(t,e){for(const n of this.errors.values()){const r=n.get(b.normalize(t));r&&(yield*r.filter((t=>te(t).intersectsWith(e))))}}*getErrorsAt(t,e){for(const n of this.errors.values()){const r=n.get(b.normalize(t));r&&(yield*r.filter((t=>te(t).containsPoint(e))))}}setErrors(t,e,n){let r=this.errors.get(t);r||(r=new Map,this.errors.set(t,r)),r.set(b.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(!yc("suppressAllDiagnostics",i))for(const e of r){if(yc("ignoredDiagnosticCodes",i).includes(""+e.code))continue;if(yc("ignoreUnusedSuggestionDiagnostics",i)&&e.reportsUnnecessary)continue;if("suggestion"===e.category&&yc("ignoredSuggestionDiagnostics",i).includes(""+e.code))continue;if(yc("ignoreNonSuggestionSuggestionDiagnostics",i)&&"suggestion"===e.category&&!ae(e.code,Jt.Suggestion))continue;let{start:r,end:o}=e;r&&o||(r=o={line:1,offset:1}),t.push({severity:this.getSeverity(yc("unusedAsInfo",i),e),excerpt:e.text,location:{file:n,position:ee(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 yc(t,e){return atom.config.get("atom-typescript."+t,{scope:[e]})}class wc{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(),Qt(this.close())},this.init=async()=>{this.state&&(await this.state.client.execute("open",{file:this.state.filePath,fileContent:this.buffer.getText()}),Qt(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=>{Qt(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=Zt.debounce((()=>{Qt(this.getErr({allFiles:!1,delay:0}))}),t)})),t.onDidChangePath(this.onDidChangePath),t.onDidDestroy(this.dispose),t.onDidSave((()=>{Qt(this.onDidSave())})),t.onDidStopChanging((({changes:t})=>{t.length>0&&this.deps.reportBuildStatus(void 0)})),t.onDidChangeText((t=>{Qt(this.onDidChangeText(t)),n()}))),this.openPromise=this.open(this.buffer.getPath())}static create(t,e){const n=wc.bufferMap.get(t);if(n)return n;{const n=new wc(t,e);return wc.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())pe(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=Zt.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||!le(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",(()=>Qt(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((()=>Qt(this.readConfigFile()))))),this.events.emit("opened")}}async readConfigFile(){if(!this.state||!this.state.configFile)return;const t=ne(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}})}}wc.bufferMap=new WeakMap;class bc{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=pe(this.editor),this.isTypescript?atom.views.getView(this.editor).classList.add("typescript-editor"):atom.views.getView(this.editor).classList.remove("typescript-editor")},this.buffer=wc.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=bc.editorMap.get(e);return n||(n=new bc(e,t),bc.editorMap.set(e,n)),n}}static lookupPane(t){return bc.editorMap.get(t)}reportInfo(){const t=this.buffer.getInfo();t&&this.opts.reportClientInfo(t)}}bc.editorMap=new WeakMap;class _c{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=()=>{Qt(this.clientResolver.restartAllServers())},this.withBuffer=async(t,e)=>{const n=b.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=>{Qt(this.statusPanel.update({progress:t}))},this.reportBuildStatus=t=>{Qt(this.statusPanel.update({buildStatus:t}))},this.reportClientInfo=t=>{Qt(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:te(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=Zt.throttle((t=>Qt(this.statusPanel.update({pending:t}))),100,{leading:!1}),this.subscriptions=new d,this.clientResolver=new Gn(this.reportBusyWhile),this.subscriptions.add(this.clientResolver),this.statusPanel=new Ja,this.subscriptions.add(this.statusPanel),this.errorPusher=new vc,this.subscriptions.add(this.errorPusher),this.codefixProvider=new Wr(this.clientResolver,this.errorPusher,this.applyEdits),this.subscriptions.add(this.codefixProvider),this.semanticViewController=new uc(this.getClient),this.subscriptions.add(this.semanticViewController),this.editorPosHist=new Ya(t&&t.editorPosHistState),this.subscriptions.add(this.editorPosHist),this.symbolsViewController=new mc({histGoForward:this.histGoForward,getClient:this.getClient}),this.subscriptions.add(this.symbolsViewController),this.tooltipManager=new cc(this.getClient),this.subscriptions.add(this.tooltipManager),this.sigHelpManager=new ic({getClient:this.getClient}),this.subscriptions.add(this.sigHelpManager),this.occurrenceManager=new tc(this.getClient),this.subscriptions.add(this.occurrenceManager),this.typescriptPaneFactory=bc.createFactory({clearFileErrors:this.clearFileErrors,getClient:this.getClient,reportBuildStatus:this.reportBuildStatus,reportClientInfo:this.reportClientInfo}),this.subscribeEditors(),this.subscriptions.add(Wa({getClient:this.getClient,applyEdits:this.applyEdits,clearErrors:this.clearErrors,killAllServers:this.killAllServers,reportProgress:this.reportProgress,reportBuildStatus:this.reportBuildStatus,toggleSemanticViewController:()=>{Qt(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=bc.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 Yn(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 Dr(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 Lr(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:()=>{Qt(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:fe(),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(!pe(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 Pr(t,n,e)}else await Ir(c,n,e)}}:void 0}};var t,e}provideReferences(){return t=this.getClient,{isEditorSupported:async t=>pe(t),async findReferences(e,n){const r=me(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(er)}:void 0}};var t}provideOutlines(){return t=this.getClient,{name:"Atom-TypeScript",grammarScopes:fe(),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:[Or(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:fe(),wordRegExp:/([A-Za-z0-9_])+|['"`](\\.|[^'"`\\\\])*['"`]/g,async getDefinition(e,n){if(!pe(e))return;const r=me(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(tr)}:void 0}}}provideCodeHighlight(){if(!atom.config.get("atom-typescript").preferBuiltinOccurrenceHighlight)return this.occurrenceManager.dispose(),Kn(this.getClient)}subscribeEditors(){this.subscriptions.add(atom.workspace.observeTextEditors((t=>{this.typescriptPaneFactory(t)})),atom.workspace.onDidChangeActiveTextEditor((t=>{if(t&&pe(t)){Qt(this.statusPanel.show());const e=bc.lookupPane(t);e&&e.didActivate()}else Qt(this.statusPanel.hide())})))}}let Sc;var xc=T(pt);exports.activate=function(t){xc.setScheduler(atom.views),Sc=new _c(t),setImmediate((()=>Qt(async function(){["atom-ide-ui","linter","nuclide"].some((t=>atom.packages.isPackageLoaded(t)))||await P.install("atom-typescript",!0)}())))},exports.deactivate=function(){Sc&&Sc.destroy(),Sc=void 0},exports.serialize=function(){return Sc?Sc.serialize():void 0},exports.deserializeSemanticView=function(t){return Ee.create(t.data)},exports.consumeLinter=function(t){if(Sc)return Sc.consumeLinter(t)},exports.consumeStatusBar=function(t){if(Sc)return Sc.consumeStatusBar(t)},exports.consumeDatatipService=function(t){if(Sc)return Sc.consumeDatatipService(t)},exports.consumeSignatureHelp=function(t){if(Sc)return Sc.consumeSigHelpService(t)},exports.consumeBusySignal=function(t){if(Sc)return Sc.consumeBusySignal(t)},exports.provideAutocomplete=function(){if(Sc)return Sc.provideAutocomplete()},exports.provideIntentions=function(){if(Sc)return Sc.provideIntentions()},exports.provideIntentionsHighlight=function(){if(Sc)return Sc.provideIntentionsHighlight()},exports.provideCodeActions=function(){if(Sc)return Sc.provideCodeActions()},exports.provideHyperclick=function(){if(Sc)return Sc.provideHyperclick()},exports.provideReferences=function(){if(Sc)return Sc.provideReferences()},exports.provideOutlines=function(){if(Sc)return Sc.provideOutlines()},exports.provideDefinitions=function(){if(Sc)return Sc.provideDefinitions()},exports.provideCodeHighlight=function(){if(Sc)return Sc.provideCodeHighlight()}; //# sourceMappingURL=main.js.map diff --git a/dist/main.js.map b/dist/main.js.map index 6d16c5d3d..c70969809 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,oB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C7B,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': '