User:Eejit43/scripts/afcrc-helper.js
Appearance
< User:Eejit43 | scripts
Code that you insert on this page could contain malicious content capable of compromising your account. If you import a script from another page with "importScript", "mw.loader.load", "iusc", or "lusc", take note that this causes you to dynamically load a remote script, which could be changed by others. Editors are responsible for all edits and actions they perform, including by scripts. User scripts are not centrally supported and may malfunction or become inoperable due to software changes. A guide to help you find broken scripts is available. If you are unsure whether code you are adding to this page is safe, you can ask at the appropriate village pump. This code will be executed when previewing this page. |
This user script seems to have a documentation page at User:Eejit43/scripts/afcrc-helper. |
// <nowiki>
// Note: This script was compiled and minified from TypeScript. For a more readable version, see https://github.com/Eejit43/wikipedia-scripts/blob/main/scripts/afcrc-helper/afcrc-helper.ts
"use strict";(()=>{var X=Object.defineProperty;var C=(h,e)=>()=>(h&&(e=h(h=0)),e);var F=(h,e)=>{for(var t in e)X(h,t,{get:e[t],enumerable:!0})};var L,B=C(()=>{"use strict";L=class h extends OO.ui.Dialog{contentLayout;logOutput;closeButton;constructor(){super({size:"large"}),h.static.name="ActionsDialog",h.static.title="Actions"}initialize=()=>(OO.ui.Dialog.prototype.initialize.apply(this),mw.util.addCSS(`
.afcrc-helper-actions-container div {
margin-block: 8px;
}`),this.contentLayout=new OO.ui.PanelLayout({padded:!0,expanded:!1}),this.$body.append(this.contentLayout.$element),this.logOutput=document.createElement("div"),this.logOutput.classList.add("afcrc-helper-actions-container"),this.closeButton=new OO.ui.ButtonWidget({label:"Close",flags:["safe","close"]}),this.closeButton.on("click",()=>this.close()),this.contentLayout.$element.append(this.logOutput,this.closeButton.$element),this);addLogEntry(e,t="notice"){let n=new OO.ui.MessageWidget({type:t,inline:!0,label:new OO.ui.HtmlSnippet(e)});this.logOutput.append(n.$element[0]),this.updateSize(),this.closeButton.scrollElementIntoView()}showReload(){this.closeButton.$element.remove();let e=new OO.ui.ButtonWidget({label:"Reload",flags:["primary"]});e.on("click",()=>window.location.reload()),this.contentLayout.$element.append(e.$element)}};Object.assign(L.prototype,OO.ui.Dialog.prototype)});var E,V=C(()=>{"use strict";B();E=class h extends OO.ui.ProcessDialog{api=new mw.Api;scriptMessage=" ([[User:Eejit43/scripts/afcrc-helper|afcrc-helper]])";requestPageType;pageTitle;createdPageWatchMethod;beforeText;pageContent;parsedRequests;editsCreationsToMake=[];constructor(e,t,n){super({size:"large"}),h.static.name="AfcrcHelperDialog",h.static.title="afcrc-helper",h.static.actions=[{action:"cancel",label:"Close",flags:["safe","close"]},{action:"save",label:"Run",flags:["primary","progressive"]}],this.pageTitle=t,this.requestPageType=e,this.createdPageWatchMethod=n&&["nochange","preferences","unwatch","watch"].includes(n)?n:"preferences",document.body.classList.add("afcrc-helper-open"),mw.util.addCSS(`
body.afcrc-helper-open #mw-teleport-target {
z-index: 500;
}
.afcrc-helper-request {
margin: 10px;
border-radius: 5px;
background-color: #eee;
padding: 5px;
color: #202122;
}
.afcrc-helper-request summary {
cursor: pointer;
}
.afcrc-helper-target-editor {
min-width: 1ch;
max-width: calc(100% - 4ch);
font-family: monospace;
}
.afcrc-helper-external-link {
text-decoration: none !important;
}
.afcrc-helper-external-link svg {
display: inline-block;
width: 1em;
height: 1em;
fill: currentColor;
}
.afcrc-helper-request-info,
.afcrc-helper-request-responder {
margin: 5px;
}
.afcrc-helper-request-info > div,
.afcrc-helper-request-responder > div {
margin-block: 8px;
}
.afcrc-helper-request-responder > div:last-of-type {
margin-bottom: 0;
}
.afcrc-helper-request-responder .oo-ui-fieldLayout {
margin-left: 8px;
}
.afcrc-helper-request-responder .oo-ui-fieldLayout-header {
width: max-content;
}
.afcrc-helper-action-radio {
margin-top: 8px;
}
.afcrc-helper-action-radio .oo-ui-radioOptionWidget {
display: inline;
padding: 8px;
}
.afcrc-closing-reason-input,
.afcrc-comment-input {
max-width: 50%;
}
.afcrc-helper-template-parameters-container,
.afcrc-helper-template-parameters-container details {
margin-block: 10px;
border: 1px solid #a2a9b1;
border-radius: 2px;
background-color: white;
padding: 5px;
}
.afcrc-helper-template-parameters-container {
margin-left: 8px;
}
.afcrc-helper-template-parameters-container summary {
cursor: pointer;
font-weight: bold;
}
.afcrc-helper-template-parameters-container details {
margin-block: 5px;
background-color: #e2e2e2;
}
#afcrc-helper-no-templates-message {
padding: 5px;
}`)}getActionProcess=e=>!e||e==="cancel"?new OO.ui.Process(()=>{this.parsedRequests.length>0?OO.ui.confirm("Are you sure you want to close? All changes will be discarded.").then(t=>t?this.close():null):this.close()}):e==="save"?new OO.ui.Process(()=>{this.performActions()}):h.super.prototype.getActionProcess.call(this,e);getTeardownProcess=()=>h.super.prototype.getTeardownProcess.call(this).next(()=>{this.$body.empty(),document.body.classList.remove("afcrc-helper-open")});async load(){let e=await this.api.get({action:"query",formatversion:"2",prop:"revisions",rvprop:"content",rvslots:"main",titles:this.pageTitle});this.pageContent=e.query.pages[0].revisions[0].slots.main.content.trim(),this.parseRequests(),this.loadInputElements()}parseRequests(){this.beforeText=/^(.*?)==/s.exec(this.pageContent)[1],this.pageContent=this.pageContent.replace(/^.*?==/s,"==");let e=[...this.pageContent.matchAll(/^==.*?==$(\s*(?!==[^=]).*)*/gim)].map(t=>t[0]);for(let t of e){if(/{{afc-c\|/i.test(t))continue;let s=/^==(.*?)==$/m.exec(t)[1].trim();this.parseSubtypeRequests(t,s)}}loadInputElements(){if(this.parsedRequests.length>0){let e=0,t=()=>{let s=Math.min(e+5,this.parsedRequests.length);this.title.setLabel(`afcrc-helper (loading ${e+1}-${s}/${this.parsedRequests.length} requests)`);for(let o=e;o<s;o++)this.loadSubtypeElements(o);s<this.parsedRequests.length?(e=s,setTimeout(t,0)):this.title.setLabel(`afcrc-helper (${this.parsedRequests.length} requests loaded)`)};t()}else{let e=new OO.ui.MessageWidget({type:"notice",label:"No valid requests to handle!"}),t=new OO.ui.PanelLayout({padded:!0,expanded:!1});t.$element.append(e.$element),this.$body.append(t.$element),this.updateSize()}}async performActions(){let e=new OO.ui.WindowManager;document.body.append(e.$element[0]);let t=new L;e.addWindows([t]),t.open();let n={accepted:0,denied:0,"commented on":0,closed:0},s=(await this.api.get({action:"query",formatversion:"2",prop:"revisions",rvprop:"content",rvslots:"main",titles:this.pageTitle})).query.pages[0].revisions[0].slots.main.content.trim();this.performSubtypeActions(t,n,s)}formatDeniedReason(e){let t=e.startsWith("autofill:")?/autofill:(\w+)/.exec(e)[1]:`decline|2=${e}`,n=e.startsWith("autofill:")&&e.includes(",")?" "+e.slice(e.indexOf(",")+1).trim():"";return`{{subst:AfC ${this.requestPageType}|${t}}}${n}`}mapDeniedReasons(e,t,n){if(t)return`* ${this.formatDeniedReason(e[0][1])} ~~~~`;let s={};for(let[i,a]of e)s[a]||(s[a]=[]),s[a].push(i);let o=Object.entries(s);return o.map(([i,a])=>`* ${this.formatDeniedReason(i)}${o.length>1||!n?` (${a.map(c=>`[[${c}]]`).join(", ")})`:""} ~~~~`).join(`
`)}mapComments(e,t,n){if(t)return`* {{AfC comment|1=${e[0][1]}}} ~~~~`;let s={};for(let[i,a]of e)s[a]||(s[a]=[]),s[a].push(i);let o=Object.entries(s);return o.map(([i,a])=>`* {{AfC comment|1=${i}}}${o.length>1||!n?` (${a.map(c=>`[[${c}]]`).join(", ")})`:""} ~~~~`).join(`
`)}modifySectionData(e,{prepend:t,append:n}){let{fullSectionText:s,sectionText:o}=e;return t&&(e.sectionText=t+`
`+e.sectionText),n&&(e.sectionText+=`
`+n),e.fullSectionText=e.fullSectionText.replace(o,e.sectionText),e.pageText=e.pageText.replace(s,e.fullSectionText),e}async makeAllEditsCreations(e){for(let t of this.editsCreationsToMake){let n=t.type==="edit"?this.api.edit(t.title,t.transform):this.api.create(t.title,{summary:t.summary,watchlist:this.createdPageWatchMethod},t.text),s=document.createElement("a");s.target="_blank",s.href=mw.util.getUrl(t.title,"isRedirect"in t&&t.isRedirect?{redirect:"no"}:void 0),s.textContent=t.title,e.addLogEntry(`${t.type==="edit"?"Editing":"Creating"} ${s.outerHTML}...`),await n.catch(async(o,i)=>{o==="ratelimited"?(e.addLogEntry(`Rate limited. Waiting for 70 seconds... (resuming at ${new Date(Date.now()+7e4).toLocaleTimeString()})`,"warning"),await new Promise(a=>setTimeout(a,7e4)),e.addLogEntry("Continuing...","success"),await n.catch((a,c)=>{e.addLogEntry(`Error ${t.type==="edit"?"editing":"creating"} ${s.outerHTML}: ${c?.error.info??"Unknown error"} (${a}).`,"error")})):e.addLogEntry(`Error ${t.type==="edit"?"editing":"creating"} ${s.outerHTML}: ${i?.error.info??"Unknown error"} (${o}).`,"error")})}}parseSubtypeRequests(e,t){throw new Error("Not implemented.")}loadSubtypeElements(e){throw new Error("Not implemented.")}updateRequestColor(e,t){throw new Error("Not implemented.")}async performSubtypeActions(e,t,n){throw new Error("Not implemented.")}};Object.assign(E.prototype,OO.ui.ProcessDialog.prototype)});var S,z=C(()=>{"use strict";S=class{titleIndex;title;detailsElement;responderElement;dialog;templateParametersEditor;templateEditorsInfo=[];commentInput;tagSelectLayout;denyReasonLayout;closingReasonLayout;commentLayout;constructor(e,t,n,s,o){this.titleIndex=e,this.title=t,this.detailsElement=n,this.responderElement=s,this.dialog=o}setup(){let e=document.createElement("div"),t=document.createElement("b");t.textContent=this.title,e.append(t);let n=new OO.ui.RadioSelectWidget({classes:["afcrc-helper-action-radio"],items:["Accept","Deny","Comment","Close","None"].map(s=>new OO.ui.RadioOptionWidget({data:s,label:s}))});n.selectItemByLabel("None"),n.on("choose",s=>this.handleActionChange(s)),this.loadCommentLayout(),e.append(n.$element[0],this.commentLayout.$element[0]),this.responderElement.append(e)}handleActionChange(e){setTimeout(()=>this.dialog.updateSize(),0);let t=e.getData().toLowerCase();switch(this.updateActionsToTake({action:t}),this.dialog.updateRequestColor(this.detailsElement,this.titleIndex),this.tagSelectLayout&&this.tagSelectLayout.$element.hide(),this.templateParametersEditor&&(this.templateParametersEditor.style.display="none"),this.denyReasonLayout&&this.denyReasonLayout.$element.hide(),this.closingReasonLayout&&this.closingReasonLayout.$element.hide(),t){case"accept":{(!this.tagSelectLayout||!this.templateParametersEditor)&&this.loadTagSelectAndParametersEditor(),this.tagSelectLayout.$element.show(),this.templateParametersEditor.style.display="block";break}case"deny":{this.denyReasonLayout||this.loadDenyReasonLayout(),this.denyReasonLayout.$element.show();break}case"close":{this.closingReasonLayout||this.loadClosingReasonLayout(),this.closingReasonLayout.$element.show();break}}if(["accept","comment","close"].includes(t)){this.commentLayout.$element.show();let n=this.commentInput.getValue().trim();n?this.updateActionsToTake({comment:n}):this.updateActionsToTake({comment:void 0})}else this.commentLayout.$element.hide(),this.updateActionsToTake({comment:void 0})}loadTagSelectAndParametersEditor(){let e=new OO.ui.MenuTagMultiselectWidget({allowArbitrary:!1,allowReordering:!1,options:Object.entries(this.dialog.redirectTemplates).map(([s,{redirect:o}])=>{if(!o)return{data:s,label:s};let i=new OO.ui.HtmlSnippet(`${s} <i>(redirect with possibilities)</i>`);return{data:s,label:i}})});e.getMenu().filterMode="substring",e.on("change",()=>{let s=e.getValue().sort((i,a)=>i.toLowerCase().localeCompare(a.toLowerCase()));e.getValue().join(";")!==s.join(";")&&e.setValue(s),this.updateActionsToTake({redirectTemplates:s});let o=0;for(let i of this.templateEditorsInfo){let a=s.includes(i.name);i.details.style.display=a?"block":"none",a&&o++}t.textContent=`Template parameters (${o>0?`for ${o} template${o>1?"s":""}`:"none to show"})`,n.style.display=o>0?"none":"block"}),this.tagSelectLayout=new OO.ui.FieldLayout(e,{classes:["afcrc-helper-tag-select-layout"],align:"inline",label:"Redirect templates:"}),this.commentLayout.$element[0].before(this.tagSelectLayout.$element[0]),this.templateParametersEditor=document.createElement("details"),this.templateParametersEditor.classList.add("afcrc-helper-template-parameters-container");let t=document.createElement("summary");t.textContent="Template parameters (none to show)",this.templateParametersEditor.append(t);for(let[s,o]of Object.entries(this.dialog.redirectTemplates)){let i=Object.entries(o.parameters);if(i.length===0)continue;let a=document.createElement("details");a.style.display="none";let c=document.createElement("summary");c.textContent=s,a.append(c);let u={name:s,details:a,parameters:[]};for(let[p,d]of i){let m=new OO.ui.TextInputWidget({placeholder:d.default?.toString(),required:d.required}),T=new OO.ui.FieldLayout(m,{label:new OO.ui.HtmlSnippet(`${p}${!d.label||p.toLowerCase()===d.label?.toLowerCase()?"":` (${d.label})`}${d.description?` (${d.description})`:""} (type: ${d.type}) ${d.suggested?" (suggested)":""}${d.example?` (example: "${d.example}")`:""}`),align:"inline"});a.append(T.$element[0]),u.parameters.push({name:p,aliases:d.aliases,editor:m})}this.templateParametersEditor.append(a),this.templateEditorsInfo.push(u)}this.updateActionsToTake({redirectTemplateParameters:this.templateEditorsInfo});let n=document.createElement("div");n.id="afcrc-helper-no-templates-message",n.textContent="No templates with parameters to display!",this.templateParametersEditor.append(n),this.commentLayout.$element[0].before(this.templateParametersEditor)}loadDenyReasonLayout(){let e=new OO.ui.ComboBoxInputWidget({classes:["afcrc-closing-reason-input"],placeholder:"autofill:unlikely",options:[["exists","existing pages"],["empty","empty submissions"],["notarget","nonexistent or no provided target"],["notitle","no title provided"],["unlikely","unlikely redirects"],["notredirect","article creation requests"],["externallink","external link redirects"],["editrequest","edit requests"],["notenglish","requests not in English"]].map(([t,n])=>({data:`autofill:${t}`,label:`Autofilled text for ${n}`}))});e.on("change",t=>{this.updateActionsToTake({denyReason:t||"autofill:unlikely"})}),e.setValue("autofill:unlikely"),e.getMenu().selectItemByData("autofill:unlikely"),this.denyReasonLayout=new OO.ui.FieldLayout(e,{align:"inline",label:"Deny reason:",help:'Supports automatic reasoning, custom reasoning, or a combination of the two with "autofill:REASON, CUSTOM" format'}),this.denyReasonLayout.$element.hide(),this.commentLayout.$element[0].before(this.denyReasonLayout.$element[0])}loadClosingReasonLayout(){let e=new OO.ui.DropdownWidget({classes:["afcrc-closing-reason-input"],menu:{items:[["No response","r"],["Succeeded","s"],["Withdrawn","w"]].map(([t,n])=>new OO.ui.MenuOptionWidget({data:n,label:t}))}});e.getMenu().selectItemByData("r"),e.getMenu().on("choose",t=>{this.updateActionsToTake({closingReason:{name:t.getLabel(),id:t.getData()}}),this.dialog.updateRequestColor(this.detailsElement,this.titleIndex)}),this.closingReasonLayout=new OO.ui.FieldLayout(e,{align:"inline",label:"Closing reason:"}),this.closingReasonLayout.$element.hide(),this.commentLayout.$element[0].before(this.closingReasonLayout.$element[0])}loadCommentLayout(){this.commentInput=new OO.ui.TextInputWidget,this.commentInput.on("change",e=>{let t=e.trim();t?this.updateActionsToTake({comment:t}):this.updateActionsToTake({comment:void 0})}),this.commentLayout=new OO.ui.FieldLayout(this.commentInput,{classes:["afcrc-comment-input"],align:"inline",label:"Comment:"}),this.commentLayout.$element.hide()}updateActionsToTake(e){Object.assign(this.dialog.actionsToTake[this.titleIndex].requests[this.title],e)}}});var Q={};F(Q,{default:()=>N});var N,_=C(()=>{"use strict";V();z();N=class extends E{redirectTemplates;parsedRequests=[];actionsToTake=[];async load(){let e=await this.api.get({action:"query",formatversion:"2",prop:"revisions",rvprop:"content",rvslots:"main",titles:"User:Eejit43/scripts/redirect-helper.json"});this.redirectTemplates=JSON.parse(e.query.pages?.[0]?.revisions?.[0]?.slots?.main?.content||"{}"),super.load()}parseSubtypeRequests(e,t){let n={},s=[...t.matchAll(/\[\[(.*?)]]/g)].map(c=>c[1]?.trim().replace(/^:/,"").replaceAll("_"," ")).filter(Boolean);if(s.length===0)return;n.pages=s;let o=/Target of redirect: ?\[\[(.*?)]]/.exec(e)?.[1].trim().replace(/^:/,"").replaceAll("_"," ");if(!o)return;n.target=o,n.reason=/reason: ?(.*?)\*source(?: \(if applicable\))?:/is.exec(e)?.[1].trim()??"",n.source=/source(?: \(if applicable\))?: ?(.*?)(?:<references \/>|\n\n)/is.exec(e)?.[1].trim()??"";let i=e.match(e.includes("<references />")?/<references \/>\n+(.*)/:new RegExp(`(?:<references \\/>${n.source?`|${n.source.replaceAll(/[\s#$()*+,.?[\\\]^{|}-]/g,"\\$&")}`:""})
+(.*)`))?.[1].trim(),a=i?/(?:Special:Contributions\/|User(?: talk)?:)(.*?)\|/.exec(i)?.[1].trim():null;n.requester=i&&a?{type:/\[\[User( talk)?:/.test(i)?"user":"ip",name:a}:null,this.parsedRequests.push(n),this.actionsToTake.push({target:n.target,requests:Object.fromEntries(s.map(c=>[c,{originalText:{fullSectionText:e,sectionText:e.replace(/^==.*?==$/m,"").trim()},action:"none"}]))})}loadSubtypeElements(e){let t=this.parsedRequests[e],n=document.createElement("details");n.classList.add("afcrc-helper-request"),n.addEventListener("click",()=>setTimeout(()=>this.updateSize(),0));let s=document.createElement("summary");s.innerHTML=t.pages.map(l=>`<b>${l}</b>`).join(", ")+" \u2192 ",s.addEventListener("keyup",l=>{document.activeElement?.tagName==="INPUT"&&l.key===" "&&l.preventDefault()});let o=document.createElement("input");o.classList.add("afcrc-helper-target-editor"),o.style.width=`${t.target.length}ch`,o.value=t.target,o.addEventListener("input",()=>{o.value=o.value.replaceAll("_"," "),o.style.width=`${o.value.length}ch`,this.actionsToTake[e].target=o.value,i.href=mw.util.getUrl(o.value)}),s.append(o);let i=document.createElement("a");i.classList.add("afcrc-helper-external-link"),i.target="_blank",i.href=mw.util.getUrl(t.target),i.innerHTML=`
<svg viewbox="0 0 48 48">
<path d="M36 24c-1.2 0-2 0.8-2 2v12c0 1.2-0.8 2-2 2h-22c-1.2
0-2-0.8-2-2v-22c0-1.2 0.8-2 2-2h12c1.2 0 2-0.8 2-2s-0.8-2-2-2h-12c-3.4
0-6 2.6-6 6v22c0 3.4 2.6 6 6 6h22c3.4 0 6-2.6
6-6v-12c0-1.2-0.8-2-2-2z"></path>
<path d="M43.8 5.2c-0.2-0.4-0.6-0.8-1-1-0.2-0.2-0.6-0.2-0.8-0.2h-12c-1.2
0-2 0.8-2 2s0.8 2 2 2h7.2l-18.6 18.6c-0.8 0.8-0.8 2 0 2.8 0.4 0.4 0.8
0.6 1.4 0.6s1-0.2 1.4-0.6l18.6-18.6v7.2c0 1.2 0.8 2 2 2s2-0.8
2-2v-12c0-0.2 0-0.6-0.2-0.8z"></path>
</svg>`,s.append(i),n.append(s);let a=document.createElement("div");a.classList.add("afcrc-helper-request-info");let c=document.createElement("span");c.style.color="dimgray",c.textContent="None";let u=document.createElement("span");u.style.color="dimgray",u.textContent="Unknown";let p=document.createElement("div"),d=document.createElement("b");d.textContent="Reason: ",p.append(d),t.reason?p.append(t.reason):p.append(c.cloneNode(!0)),a.append(p);let m=document.createElement("div"),T=document.createElement("b");T.textContent="Source: ",m.append(T),t.source?m.append(t.source):m.append(c.cloneNode(!0)),a.append(m);let b=document.createElement("div"),R=document.createElement("b");if(R.textContent="Requester: ",b.append(R),t.requester){let l=document.createElement("a");l.target="_blank",l.href=t.requester.type==="user"?mw.util.getUrl(`User:${t.requester.name}`):mw.util.getUrl(`Special:Contributions/${t.requester.name}`),l.textContent=t.requester.name,b.append(l)}else b.append(u.cloneNode(!0));a.append(b),n.append(a),n.append(document.createElement("hr"));let g=document.createElement("div");g.classList.add("afcrc-helper-request-responder");for(let l of t.pages)new S(e,l,n,g,this).setup();n.append(g),this.$body.append(n),this.updateSize()}updateRequestColor(e,t){let n=Object.values(this.actionsToTake[t].requests),s=n.every(c=>c.action==="accept"||c.action==="deny"),o=n.find(c=>c.action==="close")?.closingReason?.id,i=n.every(c=>c.action==="close"&&c.closingReason?.id===o),a="";if(s){let c=n.filter(p=>p.action==="accept").length,u=n.filter(p=>p.action==="deny").length;c>0&&u>0?a="#fff17e":c>0?a="#a0ffa0":a="#ffcece"}else i&&(o==="r"?a="#ffcece":o==="s"?a="#90c090":a="#b8b8b8");e.style.backgroundColor=a}async performSubtypeActions(e,t,n){if(this.actionsToTake.some(o=>Object.values(o.requests).some(i=>i.action!=="none"))){for(let{target:i,requests:a}of this.actionsToTake){let c=Object.values(a).some(l=>l.action==="accept"||l.action==="deny"),u=Object.values(a).every(l=>l.action==="accept"||l.action==="deny"),p=Object.values(a).find(l=>l.action==="close")?.closingReason?.id,d=Object.values(a).every(l=>l.action==="close"&&l.closingReason?.id===p),m=[],T=[],b=[],R=Object.keys(a).length;for(let[l,y]of Object.entries(a))switch(y.action){case"accept":{c&&!u?e.addLogEntry(`Not all requests to "${i}" were accepted or denied, the handling of "${l}" will be ignored.`,"warning"):(m.push(l),y.comment&&b.push([l,y.comment]),t.accepted++);break}case"deny":{c&&!u?e.addLogEntry(`Not all requests to "${i}" were accepted or denied, the handling of "${l}" is being ignored.`,"warning"):(T.push([l,y.denyReason]),t.denied++);break}case"comment":{y.comment?(b.push([l,y.comment]),t["commented on"]++):e.addLogEntry(`The request to create "${l}" \u2192 "${i}" was marked to be commented on, but no comment was provided so it will be skipped.`,"warning");break}case"close":{d?(y.comment&&b.push([l,y.comment]),t.closed++):e.addLogEntry(`Not all requests to "${i}" were closed with the same reason, the handling of "${l}" is being ignored.`,"warning");break}}let g={pageText:n,...Object.values(a)[0].originalText};if(b.length>0&&(g=this.modifySectionData(g,{append:this.mapComments(b,R===1,b.length===R)})),u){let l;if(m.length>0&&T.length>0){l="p";let y=`* {{subst:AfC redirect}} (${m.map(O=>`[[${O}]]`).join(", ")}) ~~~~`,q=this.mapDeniedReasons(T,!1,!1);for(let O of m)this.handleAcceptedRedirect(O,a[O],i);g=this.modifySectionData(g,{append:`${y}
${q}`})}else if(m.length>0){l="a";for(let y of m)this.handleAcceptedRedirect(y,a[y],i);g=this.modifySectionData(g,{append:`* {{subst:AfC redirect${m.length>1?"|all":""}}} ~~~~`})}else l="d",g=this.modifySectionData(g,{append:this.mapDeniedReasons(T,R===1,!0)});g=this.modifySectionData(g,{prepend:`{{AfC-c|${l}}}`,append:"{{AfC-c|b}}"})}else d&&(g=this.modifySectionData(g,{prepend:`{{AfC-c|${p}}}`,append:"{{AfC-c|b}}"}));n=g.pageText}if(this.beforeText+this.pageContent===n)return e.addLogEntry("No requests have been handled (page content identical)!");let o=Object.entries(t).filter(([,i])=>i>0).map(([i,a])=>`${i} ${a}`).join(", ");this.editsCreationsToMake.push({type:"edit",title:this.pageTitle,transform:()=>({text:n,summary:`Handling AfC redirect requests (${o})${this.scriptMessage}`})}),await this.makeAllEditsCreations(e),e.addLogEntry("All changes made, click below to reload!","success"),e.showReload()}else e.addLogEntry("No requests have been handled!")}handleAcceptedRedirect(e,t,n){let s=t.redirectTemplates&&t.redirectTemplates.length>0?t.redirectTemplates.map(i=>{let a=t.redirectTemplateParameters?.find(p=>p.name===i);if(!a)return`{{${i}}}`;let c=a.parameters.findLastIndex((p,d)=>p.name===(d+1).toString()&&p.editor.getValue().trim()),u=a.parameters.map((p,d)=>{let m=p.editor.getValue().trim();return!m&&d>c?null:`|${p.name===(d+1).toString()?"":`${p.name}=`}${m}`}).filter(Boolean).join("");return`{{${i}${u}}}`}):null,o=mw.Title.newFromText(e);this.editsCreationsToMake.push({type:"create",isRedirect:!0,title:o.getPrefixedText(),text:`#REDIRECT [[${n}]]${s?`
{{Redirect category shell|
${s.join(`
`)}
}}`:""}`,summary:`Creating redirect to [[${n}]] as requested at [[WP:AFC/R]]${this.scriptMessage}`},{type:"create",isRedirect:!1,title:o.getTalkPage().getPrefixedText(),text:`{{WikiProject banner shell|
{{WikiProject Articles for creation|ts={{subst:LOCALTIMESTAMP}}|reviewer=${mw.config.get("wgUserName")}}}
}}`,summary:`Adding [[Wikipedia:WikiProject Articles for creation|WikiProject Articles for creation]] banner${this.scriptMessage}`})}}});var x,J=C(()=>{"use strict";x=class extends OO.ui.TextInputWidget{api=new mw.Api;constructor(e){super(e),OO.ui.mixin.LookupElement.call(this,e)}getLookupRequest=()=>{let e=this.getValue(),t=$.Deferred();e||t.resolve([]);let n=mw.Title.newFromText(e);return this.api.get({action:"query",formatversion:"2",gaplimit:20,gapnamespace:14,gapprefix:n?.getMainText()??e,generator:"allpages",prop:"categories"}).catch(()=>null).then(s=>{if(s?.query?.pages){let o=s.query.pages.filter(i=>!i.categories?.some(a=>a.title==="Category:Wikipedia soft redirected categories")).map(i=>{let a=i.title.split(":")[1];return{data:a,label:a}});this.emit("showing-values",o),t.resolve(o)}else t.resolve([])}),t.promise({abort(){}})};getLookupCacheDataFromResponse=e=>e??[];getLookupMenuOptionsFromData=e=>e.map(({data:t,label:n})=>new OO.ui.MenuOptionWidget({data:t,label:n}))};Object.assign(x.prototype,OO.ui.mixin.LookupElement.prototype)});var v,G=C(()=>{"use strict";v=class extends OO.ui.TextInputWidget{api=new mw.Api;constructor(e){super(e),OO.ui.mixin.LookupElement.call(this,e)}getLookupRequest=()=>{let e=this.getValue(),t=$.Deferred();e||t.resolve([]);let n=mw.Title.newFromText(e);return this.api.get({action:"query",formatversion:"2",gaplimit:20,gapnamespace:n?.getNamespaceId()??0,gapprefix:n?.getMainText()??e,generator:"allpages"}).catch(()=>null).then(s=>{if(s?.query?.pages){let o=s.query.pages.map(i=>({data:i.title,label:i.title}));this.emit("showing-values",o),t.resolve(o)}else t.resolve([])}),t.promise({abort(){}})};getLookupCacheDataFromResponse=e=>e??[];getLookupMenuOptionsFromData=e=>e.map(({data:t,label:n})=>new OO.ui.MenuOptionWidget({data:t,label:n}))};Object.assign(v.prototype,OO.ui.mixin.LookupElement.prototype)});var Y={};F(Y,{default:()=>U});var U,K=C(()=>{"use strict";J();V();G();U=class extends E{parsedRequests=[];actionsToTake=[];parseSubtypeRequests(e,t){let n={},s=/:?Category:(.*?)(]]|$)/.exec(t)?.[1].trim();if(!s)return;n.category=s.replaceAll("_"," "),n.examples=[...(/example pages which belong to this category:(.*?)(parent category\/categories:|\n\[\[(special:contributions\/|user:))/is.exec(e)?.[1]??"").matchAll(/\*\s*(?:\[\[)?(.*?)(\||]]|\s*?\n)/g)].map(u=>u[1].trim().replace(/^:/,"").replaceAll("_"," ")).filter(Boolean)??[],n.parents=[...(/parent category\/categories:(.*?)(\n\n|\n\[\[(special:contributions\/|user:))/is.exec(e)?.[1]??"").matchAll(/(?<!\|)#?:?Category:(.*?)(\||]]|\s*?\n)/g)].map(u=>u[1].trim().replace(/^:/,"").replaceAll("_"," ")).filter(Boolean)??[];let o=e.indexOf("[[User:"),i=e.indexOf("[[User talk:"),a=e.indexOf("[[Special:Contributions/"),c=Math.min(...[o,i,a].filter(u=>u!==-1));n.requester=c===Number.POSITIVE_INFINITY?null:c===a?{type:"ip",name:/\[\[Special:Contributions\/(.*?)(\||]])/.exec(e)[1].trim()}:{type:"user",name:/\[\[User(?: talk)?:(.*?)(\||]])/.exec(e)[1].trim()},n.requester?.name||(n.requester=null),this.parsedRequests.push(n),this.actionsToTake.push({category:n.category,examples:n.examples,parents:n.parents,originalText:{fullSectionText:e,sectionText:e.replace(/^==.*?==$/m,"").trim()},action:"none"})}loadSubtypeElements(e){let t=this.parsedRequests[e],n=document.createElement("details");n.classList.add("afcrc-helper-request"),n.addEventListener("click",()=>setTimeout(()=>this.updateSize(),0));let s=document.createElement("summary");s.innerHTML=`<b>Category:${t.category}</b>`,n.append(s);let o=document.createElement("div");o.classList.add("afcrc-helper-request-info");let i=document.createElement("span");i.style.color="dimgray",i.textContent="None";let a=document.createElement("span");a.style.color="dimgray",a.textContent="Unknown";let c=document.createElement("div"),u=document.createElement("b");if(u.textContent="Examples: ",c.append(u),t.examples.length>0)for(let[r,f]of t.examples.entries()){let w=document.createElement("a");w.target="_blank",w.href=mw.util.getUrl(f),w.textContent=f,c.append(w),r!==t.examples.length-1&&c.append(", ")}else c.append(i.cloneNode(!0));o.append(c);let p=document.createElement("div"),d=document.createElement("b");if(d.textContent="Parents: ",p.append(d),t.parents.length>0)for(let[r,f]of t.parents.entries()){let w=document.createElement("a");w.target="_blank",w.href=mw.util.getUrl(`Category:${f}`),w.textContent=f,p.append(w),r!==t.parents.length-1&&p.append(", ")}else p.append(i.cloneNode(!0));o.append(p);let m=document.createElement("div"),T=document.createElement("b");if(T.textContent="Requester: ",m.append(T),t.requester){let r=document.createElement("a");r.target="_blank",r.href=t.requester.type==="user"?mw.util.getUrl(`User:${t.requester.name}`):mw.util.getUrl(`Special:Contributions/${t.requester.name}`),r.textContent=t.requester.name,m.append(r)}else m.append(a.cloneNode(!0));o.append(m),n.append(o),n.append(document.createElement("hr"));let b=document.createElement("div");b.classList.add("afcrc-helper-request-responder");let R=new OO.ui.RadioSelectWidget({classes:["afcrc-helper-action-radio"],items:["Accept","Deny","Comment","Close","None"].map(r=>new OO.ui.RadioOptionWidget({data:r,label:r}))});R.selectItemByLabel("None"),R.on("choose",()=>{setTimeout(()=>this.updateSize(),0);let r=R.findSelectedItem().getData().toLowerCase();if(this.actionsToTake[e].action=r,["comment","close"].includes(r)){j.$element.show();let f=I.getValue().trim();f?this.actionsToTake[e].comment=f:delete this.actionsToTake[e].comment}else j.$element.hide(),delete this.actionsToTake[e].comment;switch(this.updateRequestColor(n,e),q.$element.hide(),P.$element.hide(),M.$element.hide(),D.$element.hide(),r){case"accept":{q.$element.show(),P.$element.show();break}case"deny":{M.$element.show();break}case"close":{D.$element.show();break}}});let g=new v({placeholder:"Add pages here"});g.on("change",()=>{let r=g.getValue();r=r.replace(new RegExp(`^(https?:)?/{2}?${mw.config.get("wgServer").replace(/^\/{2}/,"")}/wiki/`),""),r=r.replace(/^:/,""),r.length>0&&g.setValue(r[0].toUpperCase()+r.slice(1).replaceAll("_"," "))}),g.on("showing-values",r=>{for(let f of r)l.addAllowedValue(f.data)});let l=new OO.ui.TagMultiselectWidget({allowReordering:!1,inputPosition:"outline",inputWidget:g});l.on("change",()=>{let r=l.getValue().sort((f,w)=>f.toLowerCase().localeCompare(w.toLowerCase()));l.getValue().join(";")!==r.join(";")&&l.setValue(r),this.actionsToTake[e].examples=r});let{examples:y}=this.actionsToTake[e];for(let r of y)l.addAllowedValue(r);l.setValue(y);let q=new OO.ui.FieldLayout(l,{align:"inline",label:"Pages to categorize:"});q.$element.hide();let O=new x({placeholder:"Add categories here"});O.on("change",()=>{let r=O.getValue();r=r.replace(new RegExp(`^(https?:)?/{2}?${mw.config.get("wgServer").replace(/^\/{2}/,"")}/wiki/`),""),r=r.replace(/^Category:/,""),r.length>0&&O.setValue(r[0].toUpperCase()+r.slice(1).replaceAll("_"," "))}),O.on("showing-values",r=>{for(let f of r)k.addAllowedValue(f.data)});let k=new OO.ui.TagMultiselectWidget({allowReordering:!1,inputPosition:"outline",inputWidget:O});k.on("change",()=>{let r=k.getValue().sort((f,w)=>f.toLowerCase().localeCompare(w.toLowerCase()));k.getValue().join(";")!==r.join(";")&&k.setValue(r),this.actionsToTake[e].parents=r});let{parents:H}=this.actionsToTake[e];for(let r of H)k.addAllowedValue(r);k.setValue(H);let P=new OO.ui.FieldLayout(k,{align:"inline",label:"Categories:"});P.$element.hide();let A=new OO.ui.ComboBoxInputWidget({classes:["afcrc-closing-reason-input"],placeholder:"autofill:unlikely",options:[["exists","existing categories"],["empty","empty submissions"],["unlikely","categories that are unlikely to have enough pages"],["notcategory","page creation requests"],["notenglish","requests not in English"]].map(([r,f])=>({data:`autofill:${r}`,label:`Autofilled text for ${f}`}))});A.on("change",()=>{this.actionsToTake[e].denyReason=A.getValue()||"autofill:unlikely"}),A.setValue("autofill:unlikely"),A.getMenu().selectItemByData("autofill:unlikely");let M=new OO.ui.FieldLayout(A,{align:"inline",label:"Deny reason:",help:'Supports automatic reasoning, custom reasoning, or a combination of the two with "autofill:REASON, CUSTOM" format'});M.$element.hide();let W=new OO.ui.DropdownWidget({classes:["afcrc-closing-reason-input"],menu:{items:[["No response","r"],["Succeeded","s"],["Withdrawn","w"]].map(([r,f])=>new OO.ui.MenuOptionWidget({data:f,label:r}))}});W.getMenu().on("choose",()=>{let r=W.getMenu().findSelectedItem();this.actionsToTake[e].closingReason={name:r.getLabel(),id:r.getData()},this.updateRequestColor(n,e)}),W.getMenu().selectItemByData("r"),this.actionsToTake[e].closingReason={name:"No response",id:"r"};let D=new OO.ui.FieldLayout(W,{align:"inline",label:"Closing reason:"});D.$element.hide();let I=new OO.ui.TextInputWidget;I.on("change",()=>{let r=I.getValue().trim();r?this.actionsToTake[e].comment=r:delete this.actionsToTake[e].comment});let j=new OO.ui.FieldLayout(I,{classes:["afcrc-comment-input"],align:"inline",label:"Comment:"});j.$element.hide(),b.append(R.$element[0],q.$element[0],P.$element[0],M.$element[0],D.$element[0],j.$element[0]),n.append(b),this.$body.append(n),this.updateSize()}updateRequestColor(e,t){let{action:n}=this.actionsToTake[t],s="";n==="accept"?s="#a0ffa0":n==="deny"?s="#ffcece":n==="close"&&(this.actionsToTake[t].closingReason?.id==="r"?s="#ffcece":this.actionsToTake[t].closingReason?.id==="s"?s="#90c090":s="#b8b8b8"),e.style.backgroundColor=s}async performSubtypeActions(e,t,n){if(this.actionsToTake.some(o=>o.action!=="none")){for(let i of this.actionsToTake){let a={pageText:n,...i.originalText};switch(i.action){case"accept":{a=this.modifySectionData(a,{prepend:"{{AfC-c|a}}",append:`* {{subst:AfC category}} ~~~~
{{AfC-c|b}}`}),this.handleAcceptedCategory(i),t.accepted++;break}case"deny":{a=this.modifySectionData(a,{prepend:"{{AfC-c|d}}",append:`* ${this.formatDeniedReason(i.denyReason)} ~~~~
{{AfC-c|b}}`}),t.denied++;break}case"comment":{i.comment?(a=this.modifySectionData(a,{append:`* {{AfC comment|1=${i.comment}}} ~~~~`}),t["commented on"]++):e.addLogEntry(`The request to create "${i.category}" was marked to be commented on, but no comment was provided so it will be skipped.`,"warning");break}case"close":{a=this.modifySectionData(a,{prepend:`{{AfC-c|${i.closingReason.id}}}`,append:(i.comment?`* {{AfC comment|1=${i.comment}}} ~~~~`:"")+`
{{AfC-c|b}`}),t.closed++;break}}n=a.pageText}if(this.beforeText+this.pageContent===n)return e.addLogEntry("No requests have been handled (page content identical)!");let o=Object.entries(t).filter(([,i])=>i>0).map(([i,a])=>`${i} ${a}`).join(", ");this.editsCreationsToMake.push({type:"edit",title:this.pageTitle,transform:()=>({text:n,summary:`Handling AfC category requests (${o})${this.scriptMessage}`})}),await this.makeAllEditsCreations(e),e.addLogEntry("All changes made, click below to reload!","success"),e.showReload()}else e.addLogEntry("No requests have been handled!")}handleAcceptedCategory(e){this.editsCreationsToMake.push({type:"create",isRedirect:!1,title:`Category:${e.category}`,text:e.parents.map(t=>`[[Category:${t}]]`).join(`
`),summary:`Creating category as requested at [[WP:AFC/C]]${this.scriptMessage}`},{type:"create",isRedirect:!1,title:`Category talk:${e.category}`,text:`{{WikiProject banner shell|
{{WikiProject Articles for creation|ts={{subst:LOCALTIMESTAMP}}|reviewer=${mw.config.get("wgUserName")}}}
}}`,summary:`Adding [[Wikipedia:WikiProject Articles for creation|WikiProject Articles for creation]] banner${this.scriptMessage}`},...e.examples.map(t=>({type:"edit",title:t,transform:({content:n})=>({text:`${n}
[[Category:${e.category}]]`,summary:`Adding page to [[:Category:${e.category}]] as requested at [[WP:AFC/C]]${this.scriptMessage}`})})))}}});mw.loader.using(["mediawiki.util","oojs-ui-core","oojs-ui-widgets","oojs-ui-windows"],async()=>{let{default:h}=await Promise.resolve().then(()=>(_(),Q)),{default:e}=await Promise.resolve().then(()=>(K(),Y)),t=mw.config.get("wgPageName").replaceAll("_"," "),n=t==="Wikipedia:Articles for creation/Redirects";if(!n&&!(t==="Wikipedia:Articles for creation/Categories"))return;let o=n?"redirect":"category";mw.util.addPortletLink(mw.config.get("skin")==="minerva"?"p-tb":"p-cactions","#",`Handle ${o} creation requests`,"afcrc-helper").addEventListener("click",a=>{a.preventDefault();let c=new OO.ui.WindowManager;document.body.append(c.$element[0]);let u=o==="redirect"?h:e,p=new u(o,t,window.afcrcConfiguration?.createdPageWatchMethod);c.addWindows([p]),p.open(),p.load()})});})();
// </nowiki>
//# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsiLi4vLi4vc2NyaXB0cy9hZmNyYy1oZWxwZXIvc2hvdy1hY3Rpb25zLWRpYWxvZy50cyIsICIuLi8uLi9zY3JpcHRzL2FmY3JjLWhlbHBlci9oZWxwZXItZGlhbG9nLnRzIiwgIi4uLy4uL3NjcmlwdHMvYWZjcmMtaGVscGVyL3JlZGlyZWN0LXJlcXVlc3QtaGFuZGxlci50cyIsICIuLi8uLi9zY3JpcHRzL2FmY3JjLWhlbHBlci9yZWRpcmVjdHMtZGlhbG9nLnRzIiwgIi4uLy4uL3NjcmlwdHMvYWZjcmMtaGVscGVyL2NhdGVnb3J5LWlucHV0LXdpZGdldC50cyI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QgaGFuZGxlID0gKCkgPT4ge1xuICAgICAgICAgICAgICAgIGNvbnN0IGJhdGNoU2l6ZSA9IDU7XG4gICAgICAgICAgICAgICAgY29uc3QgZW5kSW5kZXggPSBNYXRoLm1pbihpbmRleCArIGJhdGNoU2l6ZSwgdGhpcy5wYXJzZWRSZXF1ZXN0cy5sZW5ndGgpO1xuICAgICAgICAgICAgICAgICh0aGlzIGFzIHVua25vd24gYXMgeyB0aXRsZTogT08udWkuTGFiZWxXaWRnZXQgfSkudGl0bGUuc2V0TGFiZWwoXG4gICAgICAgICAgICAgICAgICAgIGBhZmNyYy1oZWxwZXIgKGxvYWRpbmcgJHtpbmRleCArIDF9LSR7ZW5kSW5kZXh9LyR7dGhpcy5wYXJzZWRSZXF1ZXN0cy5sZW5ndGh9IHJlcXVlc3RzKWAsXG4gICAgICAgICAgICAgICAgKTtcblxuICAgICAgICAgICAgICAgIGZvciAobGV0IHN1YkluZGV4ID0gaW5kZXg7IHN1YkluZGV4IDwgZW5kSW5kZXg7IHN1YkluZGV4KyspIHRoaXMubG9hZFN1YnR5cGVFbGVtZW50cyhzdWJJbmRleCk7XG5cbiAgICAgICAgICAgICAgICBpZiAoZW5kSW5kZXggPCB0aGlzLnBhcnNlZFJlcXVlc3RzLmxlbmd0aCkge1xuICAgICAgICAgICAgICAgICAgICBpbmRleCA9IGVuZEluZGV4O1xuICAgICAgICAgICAgICAgICAgICBzZXRUaW1lb3V0KGhhbmRsZSwgMCk7XG4gICAgICAgICAgICAgICAgfSBlbHNlXG4gICAgICAgICAgICAgICAgICAgICh0aGlzIGFzIHVua25vd24gYXMgeyB0aXRsZTogT08udWkuTGFiZWxXaWRnZXQgfSkudGl0bGUuc2V0TGFiZWwoXG4gICAgICAgICAgICAgICAgICAgICAgICBgYWZjcmMtaGVscGVyICgke3RoaXMucGFyc2VkUmVxdWVzdHMubGVuZ3RofSByZXF1ZXN0cyBsb2FkZWQpYCxcbiAgICAgICAgICAgICAgICAgICAgKTtcbiAgICAg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93KCkgKyA3MF8wMDApLnRvTG9jYWxlVGltZVN0cmluZygpfSlgLFxuICAgICAgICAgICAgICAgICAgICAgICAgJ3dhcm5pbmcnLFxuICAgICAgICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgICAgICAgICBhd2FpdCBuZXcgUHJvbWlzZSgocmVzb2x2ZSkgPT4gc2V0VGltZW91dChyZXNvbHZlLCA3MF8wMDApKTtcblxuICAgICAgICAgICAgICAgICAgICBzaG93QWN0aW9uc0RpYWxvZy5hZGRMb2dFbnRyeSgnQ29udGludWluZy4uLicsICdzdWNjZXNzJyk7XG5cbiAgICAgICAgICAgICAgICAgICAgYXdhaXQgYXBpRnVuY3Rpb24uY2F0Y2goKGVycm9yQ29kZTogc3RyaW5nLCBlcnJvckluZm86IE1lZGlhV2lraURhdGFFcnJvcikgPT4ge1xuICAgICAgICAgICAgICAgICAgICAgICAgc2hvd0FjdGlvbnNEaWFsb2cuYWRkTG9nRW50cnkoXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgYEVycm9yICR7YWN0aW9uLnR5cGUgPT09ICdlZGl0JyA/ICdlZGl0aW5nJyA6ICdjcmVhdGluZyd9ICR7bGlua0VsZW1lbnQub3V0ZXJIVE1MfTogJHtlcnJvckluZm8/LmVycm9yLmluZm8gPz8gJ1Vua25vd24gZXJyb3InfSAoJHtlcnJvckNvZGV9KS5gLFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICdlcnJvcicsXG4gICAgICAgICAgICAgICAgICAgICAgICApO1xuICAgICAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICB9IGVsc2VcbiAgICAgICAgICAgICAgICAgICAgc2hvd0FjdGlvbnNEaWFsb2cuYWRkTG9nRW50cnkoXG4gICAgICAgICAgICAgICAgICAgICAgICBgRXJyb3IgJHthY3Rpb24udHlwZSA9PT0gJ2VkaXQnID8gJ2VkaXRpbmcnIDogJ2NyZWF0aW5nJ30gJHtsaW5rRWxlbWVudC5vdXRlckhUTUx9OiA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YXlvdXQuJGVsZW1lbnQuaGlkZSgpO1xuXG4gICAgICAgIHN3aXRjaCAob3B0aW9uKSB7XG4gICAgICAgICAgICBjYXNlICdhY2NlcHQnOiB7XG4gICAgICAgICAgICAgICAgaWYgKCF0aGlzLnRhZ1NlbGVjdExheW91dCB8fCAhdGhpcy50ZW1wbGF0ZVBhcmFtZXRlcnNFZGl0b3IpIHRoaXMubG9hZFRhZ1NlbGVjdEFuZFBhcmFtZXRlcnNFZGl0b3IoKTtcblxuICAgICAgICAgICAgICAgIHRoaXMudGFnU2VsZWN0TGF5b3V0IS4kZWxlbWVudC5zaG93KCk7XG4gICAgICAgICAgICAgICAgdGhpcy50ZW1wbGF0ZVBhcmFtZXRlcnNFZGl0b3IhLnN0eWxlLmRpc3BsYXkgPSAnYmxvY2snO1xuXG4gICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBjYXNlICdkZW55Jzoge1xuICAgICAgICAgICAgICAgIGlmICghdGhpcy5kZW55UmVhc29uTGF5b3V0KSB0aGlzLmxvYWREZW55UmVhc29uTGF5b3V0KCk7XG5cbiAgICAgICAgICAgICAgICB0aGlzLmRlbnlSZWFzb25MYXlvdXQhLiRlbGVtZW50LnNob3coKTtcblxuICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgY2FzZSAnY2xvc2UnOiB7XG4gICAgICAgICAgICAgICAgaWYgKCF0aGlzLmNsb3NpbmdSZWFzb25MYXlvdXQpIHRoaXMubG9hZENsb3NpbmdSZWFzb25MYXlvdXQoKTtcblxuICAgICAgICAgICAgICAgIHRoaXMuY2xvc2luZ1JlYXNvbkxheW91dCEuJGVsZW1lbnQuc2hvdygpO1xuXG4gICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICB9XG4gICAgICAgIH1cblxuICAgICAgICBpZiAoWydhY2NlcHQnLCAnY29tbWVudCcsICdjbG9zZSddLmluY2x1ZGVzKG9w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ICAgICAgIHRoaXMudGVtcGxhdGVQYXJhbWV0ZXJzRWRpdG9yLmFwcGVuZChub1RlbXBsYXRlc01lc3NhZ2UpO1xuXG4gICAgICAgIHRoaXMuY29tbWVudExheW91dC4kZWxlbWVudFswXS5iZWZvcmUodGhpcy50ZW1wbGF0ZVBhcmFtZXRlcnNFZGl0b3IpO1xuICAgIH1cblxuICAgIC8qKlxuICAgICAqIExvYWRzIHRoZSBkZW55IHJlYXNvbiBsYXlvdXQuXG4gICAgICovXG4gICAgcHJpdmF0ZSBsb2FkRGVueVJlYXNvbkxheW91dCgpIHtcbiAgICAgICAgY29uc3QgZGVueVJlYXNvbklucHV0ID0gbmV3IE9PLnVpLkNvbWJvQm94SW5wdXRXaWRnZXQoe1xuICAgICAgICAgICAgY2xhc3NlczogWydhZmNyYy1jbG9zaW5nLXJlYXNvbi1pbnB1dCddLFxuICAgICAgICAgICAgcGxhY2Vob2xkZXI6ICdhdXRvZmlsbDp1bmxpa2VseScsXG4gICAgICAgICAgICBvcHRpb25zOiBbXG4gICAgICAgICAgICAgICAgWydleGlzdHMnLCAnZXhpc3RpbmcgcGFnZXMnXSxcbiAgICAgICAgICAgICAgICBbJ2VtcHR5JywgJ2VtcHR5IHN1Ym1pc3Npb25zJ10sXG4gICAgICAgICAgICAgICAgWydub3RhcmdldCcsICdub25leGlzdGVudCBvciBubyBwcm92aWRlZCB0YXJnZXQnXSxcbiAgICAgICAgICAgICAgICBbJ25vdGl0bGUnLCAnbm8gdGl0bGUgcHJvdmlkZWQnXSxcbiAgICAgICAgICAgICAgICBbJ3VubGlrZWx5JywgJ3VubGlrZWx5IHJlZGlyZWN0cyddLFxuICAgICAgICAgICAgICAgIFsnbm90cmVkaXJlY3QnLCAnYXJ0aWNsZSBjcmVhdGlvbiByZXF1ZXN0cyddLFxuICAgICAgICAgICAgICAgIFsnZXh0ZXJuYWxsaW5rJywgJ2V4dGVybmFsIGxpbmsgcmVkaXJlY3RzJ10sXG4gICAgICAgICAgICAgICA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ZW50LmhpZGUoKTtcblxuICAgICAgICB0aGlzLmNvbW1lbnRMYXlvdXQuJGVsZW1lbnRbMF0uYmVmb3JlKHRoaXMuZGVueVJlYXNvbkxheW91dC4kZWxlbWVudFswXSk7XG4gICAgfVxuXG4gICAgLyoqXG4gICAgICogTG9hZHMgdGhlIGNsb3NpbmcgcmVhc29uIGxheW91dC5cbiAgICAgKi9cbiAgICBwcml2YXRlIGxvYWRDbG9zaW5nUmVhc29uTGF5b3V0KCkge1xuICAgICAgICBjb25zdCBjbG9zaW5nUmVhc29uRHJvcGRvd24gPSBuZXcgT08udWkuRHJvcGRvd25XaWRnZXQoe1xuICAgICAgICAgICAgY2xhc3NlczogWydhZmNyYy1jbG9zaW5nLXJlYXNvbi1pbnB1dCddLFxuICAgICAgICAgICAgbWVudToge1xuICAgICAgICAgICAgICAgIGl0ZW1zOiBbXG4gICAgICAgICAgICAgICAgICAgIFsnTm8gcmVzcG9uc2UnLCAnciddLFxuICAgICAgICAgICAgICAgICAgICBbJ1N1Y2NlZWRlZCcsICdzJ10sXG4gICAgICAgICAgICAgICAgICAgIFsnV2l0aGRyYXduJywgJ3cnXSxcbiAgICAgICAgICAgICAgICBdLm1hcCgoW3RpdGxlLCBpZF0pID0+IG5ldyBPTy51aS5NZW51T3B0aW9uV2lkZ2V0KHsgZGF0YTogaWQsIGxhYmVsOiB0aXRsZSB9KSksXG4gICAgICAgICAgICB9LFxuICAgICAgICB9KTtcbiAgICAgICAgY2xvc2luZ1JlYXNvbkRyb3Bkb3duLmdldE1lbnUoKS5zZWxlY3RJdGVtQnlEYXRhKCdyJyk7XG5cbiAgICAgICAgY2xvc2luZ1JlYXNvbkRyb3Bkb3duLmdldE1lbnUoKS5vbignY2hvb3NlJywgKHNlbGVjdGVkKSA9PiB7XG4gICAgICAgICAgICB0aGlzLnVwZGF0ZUFjdGlvbnNUb1Rha2UoeyBjbG9zaW5nUmVhc29uOiB7IG5hbWU6IHNlbGVjdGVkLmdldExhYmVsKCkgYXM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oaXMuYWN0aW9uc1RvVGFrZS5wdXNoKHtcbiAgICAgICAgICAgIHRhcmdldDogcGFyc2VkRGF0YS50YXJnZXQsXG4gICAgICAgICAgICByZXF1ZXN0czogT2JqZWN0LmZyb21FbnRyaWVzKFxuICAgICAgICAgICAgICAgIHJlcXVlc3RlZFBhZ2VzLm1hcCgocGFnZSkgPT4gW1xuICAgICAgICAgICAgICAgICAgICBwYWdlLFxuICAgICAgICAgICAgICAgICAgICB7XG4gICAgICAgICAgICAgICAgICAgICAgICBvcmlnaW5hbFRleHQ6IHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBmdWxsU2VjdGlvblRleHQ6IHNlY3Rpb25UZXh0LFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlY3Rpb25UZXh0OiBzZWN0aW9uVGV4dC5yZXBsYWNlKC9ePT0uKj89PSQvbSwgJycpLnRyaW0oKSxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0sXG4gICAgICAgICAgICAgICAgICAgICAgICBhY3Rpb246ICdub25lJyxcbiAgICAgICAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgICBdKSxcbiAgICAgICAgICAgICksXG4gICAgICAgIH0pO1xuICAgIH1cblxuICAgIC8qKlxuICAgICAqIExvYWRzIGEgZ2l2ZW4gcmVkaXJlY3QgcmVxdWVzdCBpbnRvIHRoZSBkaWFsb2cuXG4gICAgICogQHBhcmFtIGluZGV4IFRoZSBpbmRleCBvZiB0aGUgcmVxdWVzdCB0byBsb2FkLlxuICAgICAqL1xuICAgIHByb3RlY3RlZCBsb2FkU3VidHlwZUVsZW1lbnRzKGluZGV4OiBudW1iZXIpIHtcbiAgICAgICAgY29uc3QgcmVxdWVzdCA9IHRoaXMucGFyc2VkUmVxdWVzdHNbaW5kZXhdO1xuXG4gICAgICAgIGNvbnN0IGRldGFpbHNFbGVtZW50ID0gZG9jdW1lbnQuY3JlYXRlRWxlbWVudCgnZGV0YWlscycpO1xuICAgICAgICBkZXRhaWx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ge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChzb21lUmVxdWVzdEFjY2VwdGVkRGVuaWVkICYmICFhbGxSZXF1ZXN0c0FjY2VwdGVkRGVuaWVkKVxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzaG93QWN0aW9uc0RpYWxvZy5hZGRMb2dFbnRyeShcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGBOb3QgYWxsIHJlcXVlc3RzIHRvIFwiJHt0YXJnZXR9XCIgd2VyZSBhY2NlcHRlZCBvciBkZW5pZWQsIHRoZSBoYW5kbGluZyBvZiBcIiR7cmVxdWVzdGVkVGl0bGV9XCIgd2lsbCBiZSBpZ25vcmVkLmAsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAnd2FybmluZycsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICk7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgZWxzZSB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGFjY2VwdGVkUGFnZXMucHVzaChyZXF1ZXN0ZWRUaXRsZSk7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChhY3Rpb24uY29tbWVudCkgY29tbWVudHMucHVzaChbcmVxdWVzdGVkVGl0bGUsIGFjdGlvbi5jb21tZW50XSk7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvdW50cy5hY2NlcHRlZCsrO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGJyZWFrO1xuICAgICAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICAgICAgY2FzZSAnZGVueSc6IHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoc29tZVJlcXVlc3RBY2NlcHRlZERlbmllZCAmJiAhYWxsUmVxdWVzdHNBY2NlcHRlZERlbmllZClcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgc2hvd0FjdGlvbnNEaWFsb2cuYWRkTG9nRW50cnkoXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBgTm90IGFsbCByZXF1ZXN0cyB0byBcIiR7dGFyZ2V0fVwiIHdlcmUgYWNjZXB0ZWQgb3IgZGVuaWVkLCB0aGUgaGFuZGxpbmcgb2YgXCIke3JlcXVlc3RlZFRpdGxlfVwiIGlzIGJlaW5nIGlnbm9yZWQuYCxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICd3YXJuaW5nJyxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBlbHNlIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZGVuaWVkUGFnZXMucHVzaChbcmVxdWVzdGVkVGl0bGUsIGFjdGlvbi5kZW55UmVhc29uIV0pO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb3VudHMuZGVuaWVkKys7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgICAgICBjYXNlICdjb21tZW50Jzoge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChhY3Rpb24uY29tbWVudCkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb21tZW50cy5wdXNoKFtyZXF1ZXN0ZWRUaXRsZSwgYWN0aW9uLmNvbW1lbnRdKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgY291bnRzWydjb21tZW50ZWQgb24nXSsrO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZVxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBzaG93QWN0aW9uc0RpYWxvZy5hZGRMb2dFbnRyeShcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGBUaGUgcmVxdWVzdCB0byBjcmVhdGUgXCIke3JlcXVlc3RlZFRpdGxlfVwiIFx1MjE5MiBcIiR7dGFyZ2V0fVwiIHdhcyBtYXJrZWQgdG8gYmUgY29tbWVudGVkIG9uLCBidXQgbm8gY29tbWVudCB3YXMgcHJvdmlkZWQgc28gaXQgd2lsbCBiZSBza2lwcGVkLmAsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAnd2FybmluZycsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICk7XG5cbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgICAgIGNhc2UgJ2Nsb3NlJzoge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChhbGxSZXF1ZXN0c0Nsb3NlZCkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBpZiAoYWN0aW9uLmNvbW1lbnQpIGNvbW1lbnRzLnB1c2goW3JlcXVlc3RlZFRpdGxlLCBhY3Rpb24uY29tbWVudF0pO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBjb3VudHMuY2xvc2VkKys7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgfSBlbHNlXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNob3dBY3Rpb25zRGlhbG9nLmFkZExvZ0VudHJ5KFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgYE5vdCBhbGwgcmVxdWVzdHMgdG8gXCIke3RhcmdldH1cIiB3ZXJlIGNsb3NlZCB3aXRoIHRoZSBzYW1lIHJlYXNvbiwgdGhlIGhhbmRsaW5nIG9mIFwiJHtyZXF1ZXN0ZWRUaXRsZX1cIiBpcyBiZWluZyBpZ25vcmVkLmAsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAnd2FybmluZycsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICk7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgIGxldCBzZWN0aW9uRGF0YSA9IHsgcGFnZVRleHQ6IG5ld1BhZ2VUZXh0LCAuLi5PYmplY3QudmFsdWVzKHJlcXVlc3RzKVswXS5vcmlnaW5hbFRleHQgfTtcblxuICAgICAgICAgICAgICAgIGlmIChjb21tZW50cy5sZW5ndGggPiAwKVxuICAgICAgICAgICAgICAgICAgICBzZWN0aW9uRGF0YSA9IHRoaXMubW9kaWZ5U2VjdGlvbkRhdGEoc2VjdGlvbkRhdGEsIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGFwcGVuZDogdGhpcy5tYXBDb21tZW50cyhjb21tZW50cywgYW1vdW50T2ZQYWdlcyA9PT0gMSwgY29tbWVudHMubGVuZ3RoID09PSBhbW91bnRPZlBhZ2VzKSxcbiAgICAgICAgICAgICAgICAgICAgfSk7XG5cbiAgICAgICAgICAgICAgICBpZiAoYWxsUmVxdWVzdHNBY2NlcHRlZERlbmllZCkge1xuICAgICAgICAgICAgICAgICAgICBsZXQgY2xvc2luZ0lkOiBzdHJpbmc7XG5cbiAgICAgICAgICAgICAgICAgICAgaWYgKGFjY2VwdGVkUGFnZXMubGVuZ3RoID4gMCAmJiBkZW5pZWRQYWdlcy5sZW5ndGggPiAwKSB7XG4gICAgICAgICAgICAgICAgICAgICAgICBjbG9zaW5nSWQgPSAncCc7XG5cbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IGFjY2VwdGVkUGFnZXNNZXNzYWdlID0gYCoge3tzdWJzdDpBZkMgcmVkaXJlY3R9fSAoJHthY2NlcHRlZFBhZ2VzLm1hcCgocGFnZSkgPT4gYFtbJHtwYWdlfV1dYCkuam9pbignLCAnKX0pIH5+fn5gO1xuIC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gICAgICAgICAgICAgICAgICAgICB9KTtcbiAgICAgICAgICAgICAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGNsb3NpbmdJZCA9ICdkJztcblxuICAgICAgICAgICAgICAgICAgICAgICAgc2VjdGlvbkRhdGEgPSB0aGlzLm1vZGlmeVNlY3Rpb25EYXRhKHNlY3Rpb25EYXRhLCB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgYXBwZW5kOiB0aGlzLm1hcERlbmllZFJlYXNvbnMoZGVuaWVkUGFnZXMsIGFtb3VudE9mUGFnZXMgPT09IDEsIHRydWUpLFxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgICAgICAgIH1cblxuICAgICAgICAgICAgICAgICAgICBzZWN0aW9uRGF0YSA9IHRoaXMubW9kaWZ5U2VjdGlvbkRhdGEoc2VjdGlvbkRhdGEsIHsgcHJlcGVuZDogYHt7QWZDLWN8JHtjbG9zaW5nSWR9fX1gLCBhcHBlbmQ6ICd7e0FmQy1jfGJ9fScgfSk7XG4gICAgICAgICAgICAgICAgfSBlbHNlIGlmIChhbGxSZXF1ZXN0c0Nsb3NlZClcbiAgICAgICAgICAgICAgICAgICAgc2VjdGlvbkRhdGEgPSB0aGlzLm1vZGlmeVNlY3Rpb25EYXRhKHNlY3Rpb25EYXRhLCB7XG4gICAgICAgICAgICAgICAgICAgICAgICBwcmVwZW5kOiBge3tBZkMtY3wke2ZpcnN0Q2xvc2VSZWFzb259fX1gLFxuICAgICAgICAgICAgICAgICAgICAgICAgYXBwZW5kOiAne3tBZkMtY3xifX0nLFxuICAgICAgICAgICAgICAgICAgICB9KTtcblxuICAgICAgICAgICAgICAgIG5ld1BhZ2VUZXh0ID0gc2VjdGlvbkRhdGEucGFnZVRleHQ7XG4gICAgICAgICAgICB9XG5cbiAgICAgICAgICAgIGlmICh0aGlzLmJlZm9yZVRleHQgKyB0aGlzLnBhZ2VDb250ZW50ID09PSBuZXdQYWdlVGV4dClcbiAgICAgICAgICAgICAgICByZXR1cm4gc2hvd0FjdGlvbnNEaWFsb2cuYWRkTG9nRW50cnkoJ05vIHJlcXVlc3RzIGhhdmUgYmVlbiBoYW5kbGVkIChwYWdlIGNvbnRlbnQgaWRlbnRpY2FsKSEnKTtcblxuICAgICAgICAgICAgY29uc3QgbWFwcGVkQ291bnRzID0gT2JqZWN0LmVudHJpZXMoY291bnRzKVxuICAgICAgICAgICAgICAgIC5maWx0ZXIoKFssIGNvdW50XSkgPT4gY291bnQgPiAwKVxuICAgICAgICAgICAgICAgIC5tYXAoKFthY3Rpb24sIGNvdW50XSkgPT4gYCR7YWN0aW9ufSAke2NvdW50fWApXG4gICAgICAgICAgICAgICAgLmpvaW4oJywgJyk7XG5cbiAgICAgICAgICAgIHRoaXMuZWRpdHNDcmVhdGlvbnNUb01ha2UucHVzaCh7XG4gICAgICAgICAgICAgICAgdHlwZTogJ2VkaXQnLFxuICAgICAgICAgICAgICAgIHRpdGxlOiB0aGlzLnBhZ2VUaXRsZSxcbiAgICAgICAgICAgICAgICB0cmFuc2Zvcm06ICgpID0+ICh7XG4gICAgICAgICAgICAgICAgICAgIHRleHQ6IG5ld1BhZ2VUZXh0LFxuICAgICAgICAgICAgICAgICAgICBzdW1tYXJ5OiBgSGFuZGxpbmcgQWZDIHJlZGlyZWN0IHJlcXVlc3RzICgke21hcHBlZENvdW50c30pJHt0aGlzLnNjcmlwdE1lc3NhZ2V9YCxcbiAgICAgICAgICAgICAgICB9KSxcbiAgICAgICAgICAgIH0pO1xuXG4gICAgICAgICAgICBhd2FpdCB0aGlzLm1ha2VBbGxFZGl0c0NyZWF0aW9ucyhzaG93QWN0aW9uc0RpYWxvZyk7XG5cbiAgICAgICAgICAgIHNob3dBY3Rpb25zRGlhbG9nLmFkZExvZ0VudHJ5KCdBbGwgY2hhbmdlcyBtYWRlLCBjbGljayBiZWxvdyB0byByZWxvYWQhJywgJ3N1Y2Nlc3MnKTtcblxuICAgICAgICAgICAgc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7eyR7dGFnfX19YDtcblxuICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IGxhc3ROdW1iZXJQYXJhbWV0ZXJJbmRleCA9IGZvdW5kQXJndW1lbnRFZGl0b3IucGFyYW1ldGVycy5maW5kTGFzdEluZGV4KFxuICAgICAgICAgICAgICAgICAgICAgICAgICAocGFyYW1ldGVyLCBpbmRleCkgPT4gcGFyYW1ldGVyLm5hbWUgPT09IChpbmRleCArIDEpLnRvU3RyaW5nKCkgJiYgcGFyYW1ldGVyLmVkaXRvci5nZXRWYWx1ZSgpLnRyaW0oKSxcbiAgICAgICAgICAgICAgICAgICAgICApO1xuXG4gICAgICAgICAgICAgICAgICAgICAgY29uc3QgbWFwcGVkQXJndW1lbnRzID0gZm91bmRBcmd1bWVudEVkaXRvci5wYXJhbWV0ZXJzXG4gICAgICAgICAgICAgICAgICAgICAgICAgIC5tYXAoKHBhcmFtZXRlciwgaW5kZXgpID0+IHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IHZhbHVlID0gcGFyYW1ldGVyLmVkaXRvci5nZXRWYWx1ZSgpLnRyaW0oKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmICghdmFsdWUgJiYgaW5kZXggPiBsYXN0TnVtYmVyUGFyYW1ldGVySW5kZXgpIHJldHVybiBudWxsO1xuXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICByZXR1cm4gYHwke3BhcmFtZXRlci5uYW1lID09PSAoaW5kZXggKyAxKS50b1N0cmluZygpID8gJycgOiBgJHtwYXJhbWV0ZXIubmFtZX09YH0ke3ZhbHVlfWA7XG4gICAgICAgICAgICAgICAgICAgICAgICAgIH0pXG4gICAgICAgICAgICAgICAgICAgICAgICAgIC5maWx0ZXIoQm9vbGVhbilcbiAgICAgICAgICAgICAgICAgICAgICAgICAgLmpvaW4oJycpO1xuXG4gICAgICAgICAgICAgICAgICAgICAgcmV0dXJuIGB7eyR7dGFnfSR7bWFwcGVkQXJndW1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gICAgICAgICAgIC5maWx0ZXIoXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgKHBhZ2UpID0+XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICFwYWdlLmNhdGVnb3JpZXM/LnNvbWUoKGNhdGVnb3J5KSA9PiBjYXRlZ29yeS50aXRsZSA9PT0gJ0NhdGVnb3J5Oldpa2lwZWRpYSBzb2Z0IHJlZGlyZWN0ZWQgY2F0ZWdvcmllcycpLFxuICAgICAgICAgICAgICAgICAgICAgICAgKVxuICAgICAgICAgICAgICAgICAgICAgICAgLm1hcCgocGFnZSkgPT4ge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IHRpdGxlV2l0aG91dE5hbWVzcGFjZSA9IHBhZ2UudGl0bGUuc3BsaXQoJzonKVsxXTtcblxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHJldHVybiB7IGRhdGE6IHRpdGxlV2l0aG91dE5hbWVzcGFjZSwgbGFiZWw6IHRpdGxlV2l0aG91dE5hbWVzcGFjZSB9O1xuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XG5cbiAgICAgICAgICAgICAgICAgICAgdGhpcy5lbWl0KCdzaG93aW5nLXZhbHVlcycsIHBhZ2VzKTtcblxuICAgICAgICAgICAgICAgICAgICBkZWZlcnJlZC5yZXNvbHZlKHBhZ2VzKTtcbiAgICAgICAgICAgICAgICB9IGVsc2UgZGVmZXJyZWQucmVzb2x2ZShbXSk7XG4gICAgICAgICAgICB9KTtcblxuICAgICAgICByZXR1cm4gZGVmZXJyZWQucHJvbWlzZSh7IGFib3J0KCkge30gfSk7IC8vIGVzbGludC1kaXNhYmxlLWxpbmUgQHR5cGVzY3JpcHQtZXNsaW50L25vLWVtcHR5LWZ1bmN0aW9uXG4gICAgfTtcblxuICAgIGdldExvb2t1cENhY2hlRGF0YUZyb21SZXNwb25zZSA9IDxUPihyZXNwb25zZTogVFtdIHwgbnVsbCB8IHVuZGVmaW5lZCkgPT4gcmVzcG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gICAgICAgIH1cblxuICAgICAgICAgICAgdGhpcy51cGRhdGVSZXF1ZXN0Q29sb3IoZGV0YWlsc0VsZW1lbnQsIGluZGV4KTtcblxuICAgICAgICAgICAgcGFnZVNlbGVjdExheW91dC4kZWxlbWVudC5oaWRlKCk7XG4gICAgICAgICAgICBjYXRlZ29yeVNlbGVjdExheW91dC4kZWxlbWVudC5oaWRlKCk7XG4gICAgICAgICAgICBkZW55UmVhc29uTGF5b3V0LiRlbGVtZW50LmhpZGUoKTtcbiAgICAgICAgICAgIGNsb3NpbmdSZWFzb25MYXlvdXQuJGVsZW1lbnQuaGlkZSgpO1xuXG4gICAgICAgICAgICBzd2l0Y2ggKG9wdGlvbikge1xuICAgICAgICAgICAgICAgIGNhc2UgJ2FjY2VwdCc6IHtcbiAgICAgICAgICAgICAgICAgICAgcGFnZVNlbGVjdExheW91dC4kZWxlbWVudC5zaG93KCk7XG4gICAgICAgICAgICAgICAgICAgIGNhdGVnb3J5U2VsZWN0TGF5b3V0LiRlbGVtZW50LnNob3coKTtcblxuICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgY2FzZSAnZGVueSc6IHtcbiAgICAgICAgICAgICAgICAgICAgZGVueVJlYXNvbkxheW91dC4kZWxlbWVudC5zaG93KCk7XG5cbiAgICAgICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgIGNhc2UgJ2Nsb3NlJzoge1xuICAgICAgICAgICAgICAgICAgICBjbG9zaW5nUmVhc29uTGF5b3V0LiRlbGVtZW50LnNob3coKTtcblxuICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICB9XG4gICAgICAgIH0pO1xuXG4gICAgICAgIGNvbnN0IHBhZ2VTZWxlY3RJbnB1dCA9IG5ldyBQYWdlSW5wdXRXaWRnZXQoeyBwbGFjZWhvbGRlcjogJ0Fk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XNvbkxheW91dCA9IG5ldyBPTy51aS5GaWVsZExheW91dChkZW55UmVhc29uLCB7XG4gICAgICAgICAgICBhbGlnbjogJ2lubGluZScsXG4gICAgICAgICAgICBsYWJlbDogJ0RlbnkgcmVhc29uOicsXG4gICAgICAgICAgICBoZWxwOiAnU3VwcG9ydHMgYXV0b21hdGljIHJlYXNvbmluZywgY3VzdG9tIHJlYXNvbmluZywgb3IgYSBjb21iaW5hdGlvbiBvZiB0aGUgdHdvIHdpdGggXCJhdXRvZmlsbDpSRUFTT04sIENVU1RPTVwiIGZvcm1hdCcsXG4gICAgICAgIH0pO1xuICAgICAgICBkZW55UmVhc29uTGF5b3V0LiRlbGVtZW50LmhpZGUoKTtcblxuICAgICAgICBjb25zdCBjbG9zaW5nUmVhc29uID0gbmV3IE9PLnVpLkRyb3Bkb3duV2lkZ2V0KHtcbiAgICAgICAgICAgIGNsYXNzZXM6IFsnYWZjcmMtY2xvc2luZy1yZWFzb24taW5wdXQnXSxcbiAgICAgICAgICAgIG1lbnU6IHtcbiAgICAgICAgICAgICAgICBpdGVtczogW1xuICAgICAgICAgICAgICAgICAgICBbJ05vIHJlc3BvbnNlJywgJ3InXSxcbiAgICAgICAgICAgICAgICAgICAgWydTdWNjZWVkZWQnLCAncyddLFxuICAgICAgICAgICAgICAgICAgICBbJ1dpdGhkcmF3bicsICd3J10sXG4gICAgICAgICAgICAgICAgXS5tYXAoKFt0aXRsZSwgaWRdKSA9PiBuZXcgT08udWkuTWVudU9wdGlvbldpZGdldCh7IGRhdGE6IGlkLCBsYWJlbDogdGl0bGUgfSkpLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgfSk7XG4gICAgICAgIGNsb3NpbmdSZWFzb24uZ2V0TWVudSgpLm9uKCdjaG9vc2UnLCAoKSA9PiB7XG4gICAgICAgICAgICBjb25zdCBzZWxlY3RlZCA9IGNsb3NpbmdSZWFzb24uZ2V0TWVudSgpLmZpbmRTZWxlY3RlZEl0ZW0oKSBhcyBPTy51aS5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AgIGVsc2UgZGVsZXRlIHRoaXMuYWN0aW9uc1RvVGFrZVtpbmRleF0uY29tbWVudDtcbiAgICAgICAgfSk7XG5cbiAgICAgICAgY29uc3QgY29tbWVudElucHV0TGF5b3V0ID0gbmV3IE9PLnVpLkZpZWxkTGF5b3V0KGNvbW1lbnRJbnB1dCwge1xuICAgICAgICAgICAgY2xhc3NlczogWydhZmNyYy1jb21tZW50LWlucHV0J10sXG4gICAgICAgICAgICBhbGlnbjogJ2lubGluZScsXG4gICAgICAgICAgICBsYWJlbDogJ0NvbW1lbnQ6JyxcbiAgICAgICAgfSk7XG4gICAgICAgIGNvbW1lbnRJbnB1dExheW91dC4kZWxlbWVudC5oaWRlKCk7XG5cbiAgICAgICAgcmVxdWVzdFJlc3BvbmRlckVsZW1lbnQuYXBwZW5kKFxuICAgICAgICAgICAgYWN0aW9uUmFkaW9JbnB1dC4kZWxlbWVudFswXSxcbiAgICAgICAgICAgIHBhZ2VTZWxlY3RMYXlvdXQuJGVsZW1lbnRbMF0sXG4gICAgICAgICAgICBjYXRlZ29yeVNlbGVjdExheW91dC4kZWxlbWVudFswXSxcbiAgICAgICAgICAgIGRlbnlSZWFzb25MYXlvdXQuJGVsZW1lbnRbMF0sXG4gICAgICAgICAgICBjbG9zaW5nUmVhc29uTGF5b3V0LiRlbGVtZW50WzBdLFxuICAgICAgICAgICAgY29tbWVudElucHV0TGF5b3V0LiRlbGVtZW50WzBdLFxuICAgICAgICApO1xuXG4gICAgICAgIGRldGFpbHNFbGVtZW50LmFwcGVuZChyZXF1ZXN0UmVzcG9uZGVyRWxlbWVudCk7XG5cbiAgICAgICAgKHRoaXMgYXMgdW5rbm93biBhcyB7ICRib2R5OiBKUXVlcnkgfSkuJGJvZHkuYXBwZW5kKGRldGFpbHNFbGVtZW50KTtcblxuICAgICAgICB0aGlzLnVwZGF0ZVNpemUoKTtcbiAgICB9XG5cbiAgICAvKipcbiAgICAgKiBVcGRhdGVzIHRoZSBjb2xvciBvZiBhIGRld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YS5hY3Rpb24pIHtcbiAgICAgICAgICAgICAgICAgICAgY2FzZSAnYWNjZXB0Jzoge1xuICAgICAgICAgICAgICAgICAgICAgICAgc2VjdGlvbkRhdGEgPSB0aGlzLm1vZGlmeVNlY3Rpb25EYXRhKHNlY3Rpb25EYXRhLCB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcHJlcGVuZDogJ3t7QWZDLWN8YX19JyxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBhcHBlbmQ6ICcqIHt7c3Vic3Q6QWZDIGNhdGVnb3J5fX0gfn5+flxcbnt7QWZDLWN8Yn19JyxcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xuXG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLmhhbmRsZUFjY2VwdGVkQ2F0ZWdvcnkoYWN0aW9uRGF0YSk7XG5cbiAgICAgICAgICAgICAgICAgICAgICAgIGNvdW50cy5hY2NlcHRlZCsrO1xuXG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICBjYXNlICdkZW55Jzoge1xuICAgICAgICAgICAgICAgICAgICAgICAgc2VjdGlvbkRhdGEgPSB0aGlzLm1vZGlmeVNlY3Rpb25EYXRhKHNlY3Rpb25EYXRhLCB7XG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgcHJlcGVuZDogJ3t7QWZDLWN8ZH19JyxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBhcHBlbmQ6IGAqICR7dGhpcy5mb3JtYXREZW5pZWRSZWFzb24oYWN0aW9uRGF0YS5kZW55UmVhc29uISl9IH5+fn5cXG57e0FmQy1jfGJ9fWAsXG4gICAgICAgICAgICAgICAgICAgICAgICB9KTtcblxuICAgICAgICAgICAgICAgICAgICAgICAgY291bnRzLmRlbmllZCsrO1xuXG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICBjYXNlICdjb21tZW50Jzoge1xuICAgICAgICAgICAgICAgICAgICAgICAgaWYgKGFjdGlvbkRhdGEuY29tbWVudCkge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNlY3Rpb25EYXRhID0gdGhpcy5tb2RpZnlTZWN0aW9uRGF0YShzZWN0aW9uRGF0YSwge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBhcHBlbmQ6IGAqIHt7QWZDIGNvbW1lbnR8MT0ke2FjdGlvbkRhdGEuY29tbWVudH19fSB+fn5+YCxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9KTtcblxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGNvdW50c1snY29tbWVudGVkIG9uJ10rKztcbiAgICAgICAgICAgICAgICAgICAgICAgIH0gZWxzZVxuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHNob3dBY3Rpb25zRGlhbG9nLmFkZExvZ0VudHJ5KFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBgVGhlIHJlcXVlc3QgdG8gY3JlYXRlIFwiJHthY3Rpb25EYXRhLmNhdGVnb3J5fVwiIHdhcyBtYXJrZWQgdG8gYmUgY29tbWVudGVkIG9uLCBidXQgbm8gY29tbWVudCB3YXMgcHJvdmlkZWQgc28gaXQgd2lsbCBiZSBza2lwcGVkLmAsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICd3YXJuaW5nJyxcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICApO1xuXG4gICAgICAgICAgICAgICAgICAgICAgICBicmVhaztcbiAgICAgICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgICAgICAgICBjYXNlICdjbG9zZSc6IHtcbiAgICAgICAgICAgICAgICAgICAgICAgIHNlY3Rpb25EYXRhID0gdGhpcy5tb2RpZnlTZWN0aW9uRGF0YShzZWN0aW9uRGF0YSwge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHByZXBlbmQ6IGB7e0FmQy1jfCR7YWN0aW9uRGF0YS5jbG9zaW5nUmVhc29uIS5pZH19fWAsXG4gICAgICAgICAgICAgICAgICAgICAgICAgICAgYXBwZW5kOiAoYWN0aW9uRGF0YS5jb21tZW50ID8gYCoge3tBZkMgY29tbWVudHwxPSR7YWN0aW9uRGF0YS5jb21tZW50fX19IH5+fn5gIDogJycpICsgJ1xcbnt7QWZDLWN8Yn0nLFxuICAgICAgICAgICAgICAgICAgICAgICAgfSk7XG5cbiAgICAgICAgICAgICAgICAgICAgICAgIGNvdW50cy5jbG9zZWQrKztcblxuICAgICAgICAgICAgICAgICAgICAgICAgYnJlYWs7XG4gICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgICBuZXdQYWdlVGV4dCA9IHNlY3Rpb25EYXRhLnBhZ2VUZXh0O1xuICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICBpZiAodGhpcy5iZWZvcmVUZXh0ICsgdGhpcy5wYWdlQ29udGVudCA9PT0gbmV3UGFnZVRleHQpXG4gICAgICAgICAgICAgICAgcmV0dXJuIHNob3dBY3Rpb25zRGlhbG9nLmFkZExvZ0VudHJ5KCdObyByZXF1ZXN0cyBoYXZlIGJlZW4gaGFuZGxlZCAocGFnZSBjb250ZW50IGlkZW50aWNhbCkhJyk7XG5cbiAgICAgICAgICAgIGNvbnN0IG1hcHBlZENvdW50cyA9IE9iamVjdC5lbnRyaWVzKGNvdW50cylcbiAgICAgICAgICAgICAgICAuZmlsdGVyKChbLCBjb3VudF0pID0+IGNvdW50ID4gMClcbiAgICAgICAgICAgICAgICAubWFwKChbYWN0aW9uLCBjb3VudF0pID0+IGAke2FjdGlvbn0gJHtjb3VudH1gKVxuICAgICAgICAgICAgICAgIC5qb2luKCcsICcpO1xuXG4gICAgICAgICAgICB0aGlzLmVkaXRzQ3JlYXRpb25zVG9NYWtlLnB1c2goe1xuICAgICAgICAgICAgICAgIHR5cGU6ICdlZGl0JyxcbiAgIC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