var je=Object.create;var K=Object.defineProperty;var qe=Object.getOwnPropertyDescriptor;var Je=Object.getOwnPropertyNames;var We=Object.getPrototypeOf,Qe=Object.prototype.hasOwnProperty;var Ke=(i,t)=>()=>(t||i((t={exports:{}}).exports,t),t.exports),Ge=(i,t)=>{for(var e in t)K(i,e,{get:t[e],enumerable:!0})},pe=(i,t,e,n)=>{if(t&&typeof t=="object"||typeof t=="function")for(let s of Je(t))!Qe.call(i,s)&&s!==e&&K(i,s,{get:()=>t[s],enumerable:!(n=qe(t,s))||n.enumerable});return i};var Ze=(i,t,e)=>(e=i!=null?je(We(i)):{},pe(t||!i||!i.__esModule?K(e,"default",{value:i,enumerable:!0}):e,i)),Xe=i=>pe(K({},"__esModule",{value:!0}),i);var a=(i,t,e)=>new Promise((n,s)=>{var o=g=>{try{l(e.next(g))}catch(u){s(u)}},r=g=>{try{l(e.throw(g))}catch(u){s(u)}},l=g=>g.done?n(g.value):Promise.resolve(g.value).then(o,r);l((e=e.apply(i,t)).next())});var ze=Ke(c=>{"use strict";Object.defineProperty(c,"__esModule",{value:!0});var f=require("obsidian"),ae="YYYY-MM-DD",re="gggg-[W]ww",Ne="YYYY-MM",Ee="YYYY-[Q]Q",Le="YYYY";function z(i){var e,n;let t=window.app.plugins.getPlugin("periodic-notes");return t&&((n=(e=t.settings)==null?void 0:e[i])==null?void 0:n.enabled)}function _(){var i,t,e,n;try{let{internalPlugins:s,plugins:o}=window.app;if(z("daily")){let{format:u,folder:m,template:d}=((t=(i=o.getPlugin("periodic-notes"))==null?void 0:i.settings)==null?void 0:t.daily)||{};return{format:u||ae,folder:(m==null?void 0:m.trim())||"",template:(d==null?void 0:d.trim())||""}}let{folder:r,format:l,template:g}=((n=(e=s.getPluginById("daily-notes"))==null?void 0:e.instance)==null?void 0:n.options)||{};return{format:l||ae,folder:(r==null?void 0:r.trim())||"",template:(g==null?void 0:g.trim())||""}}catch(s){console.info("No custom daily note settings found!",s)}}function H(){var i,t,e,n,s,o,r;try{let l=window.app.plugins,g=(i=l.getPlugin("calendar"))==null?void 0:i.options,u=(e=(t=l.getPlugin("periodic-notes"))==null?void 0:t.settings)==null?void 0:e.weekly;if(z("weekly"))return{format:u.format||re,folder:((n=u.folder)==null?void 0:n.trim())||"",template:((s=u.template)==null?void 0:s.trim())||""};let m=g||{};return{format:m.weeklyNoteFormat||re,folder:((o=m.weeklyNoteFolder)==null?void 0:o.trim())||"",template:((r=m.weeklyNoteTemplate)==null?void 0:r.trim())||""}}catch(l){console.info("No custom weekly note settings found!",l)}}function V(){var t,e,n,s;let i=window.app.plugins;try{let o=z("monthly")&&((e=(t=i.getPlugin("periodic-notes"))==null?void 0:t.settings)==null?void 0:e.monthly)||{};return{format:o.format||Ne,folder:((n=o.folder)==null?void 0:n.trim())||"",template:((s=o.template)==null?void 0:s.trim())||""}}catch(o){console.info("No custom monthly note settings found!",o)}}function Y(){var t,e,n,s;let i=window.app.plugins;try{let o=z("quarterly")&&((e=(t=i.getPlugin("periodic-notes"))==null?void 0:t.settings)==null?void 0:e.quarterly)||{};return{format:o.format||Ee,folder:((n=o.folder)==null?void 0:n.trim())||"",template:((s=o.template)==null?void 0:s.trim())||""}}catch(o){console.info("No custom quarterly note settings found!",o)}}function j(){var t,e,n,s;let i=window.app.plugins;try{let o=z("yearly")&&((e=(t=i.getPlugin("periodic-notes"))==null?void 0:t.settings)==null?void 0:e.yearly)||{};return{format:o.format||Le,folder:((n=o.folder)==null?void 0:n.trim())||"",template:((s=o.template)==null?void 0:s.trim())||""}}catch(o){console.info("No custom yearly note settings found!",o)}}function Ie(...i){let t=[];for(let n=0,s=i.length;n{let se=n(),oe=i.clone().set({hour:se.get("hour"),minute:se.get("minute"),second:se.get("second")});return w&&oe.add(parseInt(b,10),P),y?oe.format(y.substring(1).trim()):oe.format(o)}).replace(/{{\s*yesterday\s*}}/gi,i.clone().subtract(1,"day").format(o)).replace(/{{\s*tomorrow\s*}}/gi,i.clone().add(1,"d").format(o)));return t.foldManager.save(d,g),d}catch(d){console.error(`Failed to create file: '${m}'`,d),new f.Notice("Unable to create new file.")}})}function lt(i,t){var e;return(e=t[C(i,"day")])!=null?e:null}function gt(){let{vault:i}=window.app,{folder:t}=_(),e=i.getAbstractFileByPath(f.normalizePath(t));if(!e)throw new le("Failed to find daily notes folder");let n={};return f.Vault.recurseChildren(e,s=>{if(s instanceof f.TFile){let o=B(s,"day");if(o){let r=C(o,"day");n[r]=s}}}),n}var ge=class extends Error{};function ut(){let{moment:i}=window,t=i.localeData()._week.dow,e=["sunday","monday","tuesday","wednesday","thursday","friday","saturday"];for(;t;)e.push(e.shift()),t--;return e}function ct(i){return ut().indexOf(i.toLowerCase())}function Me(i){return a(this,null,function*(){let{vault:t}=window.app,{template:e,format:n,folder:s}=H(),[o,r]=yield D(e),l=i.format(n),g=yield q(s,l);try{let u=yield t.create(g,o.replace(/{{\s*(date|time)\s*(([+-]\d+)([yqmwdhs]))?\s*(:.+?)?}}/gi,(m,d,h,T,w,b)=>{let P=window.moment(),y=i.clone().set({hour:P.get("hour"),minute:P.get("minute"),second:P.get("second")});return h&&y.add(parseInt(T,10),w),b?y.format(b.substring(1).trim()):y.format(n)}).replace(/{{\s*title\s*}}/gi,l).replace(/{{\s*time\s*}}/gi,window.moment().format("HH:mm")).replace(/{{\s*(sunday|monday|tuesday|wednesday|thursday|friday|saturday)\s*:(.*?)}}/gi,(m,d,h)=>{let T=ct(d);return i.weekday(T).format(h.trim())}));return window.app.foldManager.save(u,r),u}catch(u){console.error(`Failed to create file: '${g}'`,u),new f.Notice("Unable to create new file.")}})}function dt(i,t){var e;return(e=t[C(i,"week")])!=null?e:null}function pt(){let i={};if(!xe())return i;let{vault:t}=window.app,{folder:e}=H(),n=t.getAbstractFileByPath(f.normalizePath(e));if(!n)throw new ge("Failed to find weekly notes folder");return f.Vault.recurseChildren(n,s=>{if(s instanceof f.TFile){let o=B(s,"week");if(o){let r=C(o,"week");i[r]=s}}}),i}var ue=class extends Error{};function Re(i){return a(this,null,function*(){let{vault:t}=window.app,{template:e,format:n,folder:s}=V(),[o,r]=yield D(e),l=i.format(n),g=yield q(s,l);try{let u=yield t.create(g,o.replace(/{{\s*(date|time)\s*(([+-]\d+)([yqmwdhs]))?\s*(:.+?)?}}/gi,(m,d,h,T,w,b)=>{let P=window.moment(),y=i.clone().set({hour:P.get("hour"),minute:P.get("minute"),second:P.get("second")});return h&&y.add(parseInt(T,10),w),b?y.format(b.substring(1).trim()):y.format(n)}).replace(/{{\s*date\s*}}/gi,l).replace(/{{\s*time\s*}}/gi,window.moment().format("HH:mm")).replace(/{{\s*title\s*}}/gi,l));return window.app.foldManager.save(u,r),u}catch(u){console.error(`Failed to create file: '${g}'`,u),new f.Notice("Unable to create new file.")}})}function mt(i,t){var e;return(e=t[C(i,"month")])!=null?e:null}function ft(){let i={};if(!Oe())return i;let{vault:t}=window.app,{folder:e}=V(),n=t.getAbstractFileByPath(f.normalizePath(e));if(!n)throw new ue("Failed to find monthly notes folder");return f.Vault.recurseChildren(n,s=>{if(s instanceof f.TFile){let o=B(s,"month");if(o){let r=C(o,"month");i[r]=s}}}),i}var ce=class extends Error{};function ht(i){return a(this,null,function*(){let{vault:t}=window.app,{template:e,format:n,folder:s}=Y(),[o,r]=yield D(e),l=i.format(n),g=yield q(s,l);try{let u=yield t.create(g,o.replace(/{{\s*(date|time)\s*(([+-]\d+)([yqmwdhs]))?\s*(:.+?)?}}/gi,(m,d,h,T,w,b)=>{let P=window.moment(),y=i.clone().set({hour:P.get("hour"),minute:P.get("minute"),second:P.get("second")});return h&&y.add(parseInt(T,10),w),b?y.format(b.substring(1).trim()):y.format(n)}).replace(/{{\s*date\s*}}/gi,l).replace(/{{\s*time\s*}}/gi,window.moment().format("HH:mm")).replace(/{{\s*title\s*}}/gi,l));return window.app.foldManager.save(u,r),u}catch(u){console.error(`Failed to create file: '${g}'`,u),new f.Notice("Unable to create new file.")}})}function bt(i,t){var e;return(e=t[C(i,"quarter")])!=null?e:null}function wt(){let i={};if(!$e())return i;let{vault:t}=window.app,{folder:e}=Y(),n=t.getAbstractFileByPath(f.normalizePath(e));if(!n)throw new ce("Failed to find quarterly notes folder");return f.Vault.recurseChildren(n,s=>{if(s instanceof f.TFile){let o=B(s,"quarter");if(o){let r=C(o,"quarter");i[r]=s}}}),i}var de=class extends Error{};function yt(i){return a(this,null,function*(){let{vault:t}=window.app,{template:e,format:n,folder:s}=j(),[o,r]=yield D(e),l=i.format(n),g=yield q(s,l);try{let u=yield t.create(g,o.replace(/{{\s*(date|time)\s*(([+-]\d+)([yqmwdhs]))?\s*(:.+?)?}}/gi,(m,d,h,T,w,b)=>{let P=window.moment(),y=i.clone().set({hour:P.get("hour"),minute:P.get("minute"),second:P.get("second")});return h&&y.add(parseInt(T,10),w),b?y.format(b.substring(1).trim()):y.format(n)}).replace(/{{\s*date\s*}}/gi,l).replace(/{{\s*time\s*}}/gi,window.moment().format("HH:mm")).replace(/{{\s*title\s*}}/gi,l));return window.app.foldManager.save(u,r),u}catch(u){console.error(`Failed to create file: '${g}'`,u),new f.Notice("Unable to create new file.")}})}function Tt(i,t){var e;return(e=t[C(i,"year")])!=null?e:null}function Pt(){let i={};if(!Ue())return i;let{vault:t}=window.app,{folder:e}=j(),n=t.getAbstractFileByPath(f.normalizePath(e));if(!n)throw new de("Failed to find yearly notes folder");return f.Vault.recurseChildren(n,s=>{if(s instanceof f.TFile){let o=B(s,"year");if(o){let r=C(o,"year");i[r]=s}}}),i}function vt(){var n,s;let{app:i}=window,t=i.internalPlugins.plugins["daily-notes"];if(t&&t.enabled)return!0;let e=i.plugins.getPlugin("periodic-notes");return e&&((s=(n=e.settings)==null?void 0:n.daily)==null?void 0:s.enabled)}function xe(){var e,n;let{app:i}=window;if(i.plugins.getPlugin("calendar"))return!0;let t=i.plugins.getPlugin("periodic-notes");return t&&((n=(e=t.settings)==null?void 0:e.weekly)==null?void 0:n.enabled)}function Oe(){var e,n;let{app:i}=window,t=i.plugins.getPlugin("periodic-notes");return t&&((n=(e=t.settings)==null?void 0:e.monthly)==null?void 0:n.enabled)}function $e(){var e,n;let{app:i}=window,t=i.plugins.getPlugin("periodic-notes");return t&&((n=(e=t.settings)==null?void 0:e.quarterly)==null?void 0:n.enabled)}function Ue(){var e,n;let{app:i}=window,t=i.plugins.getPlugin("periodic-notes");return t&&((n=(e=t.settings)==null?void 0:e.yearly)==null?void 0:n.enabled)}function Ct(i){let t={day:_,week:H,month:V,quarter:Y,year:j}[i];return t()}function St(i,t){return{day:Be,month:Re,week:Me}[i](t)}c.DEFAULT_DAILY_NOTE_FORMAT=ae;c.DEFAULT_MONTHLY_NOTE_FORMAT=Ne;c.DEFAULT_QUARTERLY_NOTE_FORMAT=Ee;c.DEFAULT_WEEKLY_NOTE_FORMAT=re;c.DEFAULT_YEARLY_NOTE_FORMAT=Le;c.appHasDailyNotesPluginLoaded=vt;c.appHasMonthlyNotesPluginLoaded=Oe;c.appHasQuarterlyNotesPluginLoaded=$e;c.appHasWeeklyNotesPluginLoaded=xe;c.appHasYearlyNotesPluginLoaded=Ue;c.createDailyNote=Be;c.createMonthlyNote=Re;c.createPeriodicNote=St;c.createQuarterlyNote=ht;c.createWeeklyNote=Me;c.createYearlyNote=yt;c.getAllDailyNotes=gt;c.getAllMonthlyNotes=ft;c.getAllQuarterlyNotes=wt;c.getAllWeeklyNotes=pt;c.getAllYearlyNotes=Pt;c.getDailyNote=lt;c.getDailyNoteSettings=_;c.getDateFromFile=B;c.getDateFromPath=rt;c.getDateUID=C;c.getMonthlyNote=mt;c.getMonthlyNoteSettings=V;c.getPeriodicNoteSettings=Ct;c.getQuarterlyNote=bt;c.getQuarterlyNoteSettings=Y;c.getTemplateInfo=D;c.getWeeklyNote=dt;c.getWeeklyNoteSettings=H;c.getYearlyNote=Tt;c.getYearlyNoteSettings=j});var Ft={};Ge(Ft,{default:()=>ie});module.exports=Xe(Ft);var Ye=require("obsidian");var v=require("obsidian");var N=require("obsidian");var F=require("obsidian");var et="https://raw.githubusercontent.com/",G=(i,t,e,n=!0)=>a(void 0,null,function*(){let s=`https://github.com/${i}/releases/download/${t}/${e}`;try{let o=yield(0,F.request)({url:s});return o==="Not Found"||o==='{"error":"Not Found"}'?null:o}catch(o){return n&&console.log("error in grabReleaseFileFromRepository",s,o),null}}),me=(i,t=!0,e=!0)=>a(void 0,null,function*(){let n=et+i+(t===!0?"/HEAD/manifest.json":"/HEAD/manifest-beta.json");try{let s=yield(0,F.request)({url:n});return s==="404: Not Found"?null:yield JSON.parse(s)}catch(s){return s!="Error: Request failed, status 404"&&e&&console.log(`error in grabManifestJsonFromRepository for ${n}`,s),null}}),fe=(i=!0)=>a(void 0,null,function*(){let t="https://raw.githubusercontent.com/obsidianmd/obsidian-releases/HEAD/community-plugins.json";try{let e=yield(0,F.request)({url:t});return e==="404: Not Found"?null:yield JSON.parse(e)}catch(e){return i&&console.log("error in grabCommmunityPluginList",e),null}}),he=(i=!0)=>a(void 0,null,function*(){let t="https://raw.githubusercontent.com/obsidianmd/obsidian-releases/HEAD/community-css-themes.json";try{let e=yield(0,F.request)({url:t});return e==="404: Not Found"?null:yield JSON.parse(e)}catch(e){return i&&console.log("error in grabCommmunityThemesList",e),null}}),L=(i,t=!1,e)=>a(void 0,null,function*(){let n=`https://raw.githubusercontent.com/${i}/HEAD/theme${t?"-beta":""}.css`;try{let s=yield(0,F.request)({url:n});return s==="404: Not Found"?null:s}catch(s){return e&&console.log("error in grabCommmunityThemeCssFile",s),null}}),be=(i,t=!0)=>a(void 0,null,function*(){let e=`https://raw.githubusercontent.com/${i}/HEAD/manifest.json`;try{let n=yield(0,F.request)({url:e});return n==="404: Not Found"?null:n}catch(n){return t&&console.log("error in grabCommmunityThemeManifestFile",n),null}}),tt=i=>{let t=0;for(let e=0;ett(i).toString(),R=(i,t,e)=>a(void 0,null,function*(){let n=yield L(i,t,e);return n?M(n):"0"}),nt=(i,t,e=!0)=>a(void 0,null,function*(){let n=`https://api.github.com/repos/${i}/commits?path=${t}&page=1&per_page=1`;try{let s=yield(0,F.request)({url:n});return s==="404: Not Found"?null:JSON.parse(s)}catch(s){return e&&console.log("error in grabLastCommitInfoForAFile",s),null}}),we=(i,t)=>a(void 0,null,function*(){let e=yield nt(i,t);return e[0].commit.committer.date?e[0].commit.committer.date:""});var ye={pluginList:[],pluginSubListFrozenVersion:[],themesList:[],updateAtStartup:!1,updateThemesAtStartup:!1,ribbonIconEnabled:!0,loggingEnabled:!1,loggingPath:"BRAT-log",loggingVerboseEnabled:!1,debuggingMode:!0,notificationsEnabled:!0};function Te(i,t,e=""){return a(this,null,function*(){let n=!1;i.settings.pluginList.contains(t)||(i.settings.pluginList.unshift(t),n=!0),e!==""&&i.settings.pluginSubListFrozenVersion.filter(s=>s.repo===t).length===0&&(i.settings.pluginSubListFrozenVersion.unshift({repo:t,version:e}),n=!0),n&&i.saveSettings()})}function Pe(i,t){return a(this,null,function*(){return i.settings.pluginList.contains(t)})}function ve(i,t,e){return a(this,null,function*(){let n={repo:t,lastUpdate:M(e)};i.settings.themesList.unshift(n),i.saveSettings()})}function Ce(i,t){return a(this,null,function*(){return!!i.settings.themesList.find(n=>n.repo===t)})}function Se(i,t,e){i.settings.themesList.forEach(n=>{n.repo===t&&(n.lastUpdate=e,i.saveSettings())})}var Z=require("obsidian");function p(i,t,e=10,n){if(i.settings.notificationsEnabled===!1)return;let s=n?Z.Platform.isDesktop?"(click=dismiss, right-click=Info)":"(click=dismiss)":"",o=new Z.Notice(`BRAT ${t} ${s}`,e*1e3);n&&(o.noticeEl.oncontextmenu=()=>a(this,null,function*(){n()}))}function X(){return a(this,null,function*(){try{let i=yield fetch("https://obsidian.md/?"+Math.random());return i.status>=200&&i.status<300}catch(i){return!1}})}var x=(i,t,e)=>a(void 0,null,function*(){let n=yield L(t,!0,i.settings.debuggingMode);if(n||(n=yield L(t,!1,i.settings.debuggingMode)),!n)return p(i,"There is no theme.css or theme-beta.css file in the root path of this repository, so there is no theme to install."),!1;let s=yield be(t,i.settings.debuggingMode);if(!s)return p(i,"There is no manifest.json file in the root path of this repository, so theme cannot be installed."),!1;let o=yield JSON.parse(s),r=(0,N.normalizePath)(it(i)+o.name),l=i.app.vault.adapter;(yield l.exists(r))===!1&&(yield l.mkdir(r)),yield l.write((0,N.normalizePath)(r+"/theme.css"),n),yield l.write((0,N.normalizePath)(r+"/manifest.json"),s),Se(i,t,M(n));let g="";return e?(yield ve(i,t,n),g=`${o.name} theme installed from ${t}. `,setTimeout(()=>{i.app.customCss.setTheme(o.name)},500)):g=`${o.name} theme updated from ${t}.`,i.log(g+`[Theme Info](https://github.com/${t})`,!1),p(i,`${g}`,20,()=>a(void 0,null,function*(){window.open(`https://github.com/${t}`)})),!0}),I=(i,t)=>a(void 0,null,function*(){if((yield X())===!1){console.log("BRAT: No internet detected.");return}let e,n="Checking for beta theme updates STARTED";i.log(n,!0),t&&i.settings.notificationsEnabled&&(e=new N.Notice(`BRAT ${n}`,3e4));for(let o of i.settings.themesList){let r=yield R(o.repo,!0,i.settings.debuggingMode);r==="0"&&(r=yield R(o.repo,!1,i.settings.debuggingMode)),r!==o.lastUpdate&&(yield x(i,o.repo,!1))}let s="Checking for beta theme updates COMPLETED";i.log(s,!0),t&&(i.settings.notificationsEnabled&&e.hide(),p(i,s))}),ee=(i,t)=>a(void 0,null,function*(){i.settings.themesList=i.settings.themesList.filter(n=>n.repo!=t),i.saveSettings();let e=`Removed ${t} from BRAT themes list and will no longer be updated. However, the theme files still exist in the vault. To remove them, go into Settings > Appearance and remove the theme.`;i.log(e,!0),p(i,`${e}`)}),it=i=>(0,N.normalizePath)(i.app.vault.configDir+"/themes")+"/";var te=require("obsidian");var k=(i,t=!0)=>{let e=t?40:30,n=i.createEl("div");n.style.float="right",t===!1?(n.style.padding="10px",n.style.paddingLeft="15px",n.style.paddingRight="15px"):(n.style.padding="15px",n.style.paddingLeft="15px",n.style.paddingRight="15px",n.style.marginLeft="15px");let s=n.createSpan("coffee");s.addClass("ex-coffee-span");let r=s.createEl("a",{href:"https://bit.ly/o42-kofi"}).createEl("img",{attr:{src:"https://cdn.ko-fi.com/cdn/kofi3.png?v=3"}});r.height=e;let l=n.createSpan("coffee");l.addClass("ex-twitter-span"),l.style.paddingLeft="10px";let u=l.createEl("a",{href:"https://bit.ly/o42-twitter"}).createEl("img",{attr:{src:"https://cdn.cdnlogo.com/logos/t/96/twitter-icon.svg"}});u.height=e;let m=n.createSpan("coffee");m.addClass("ex-twitter-span"),m.style.paddingLeft="10px",m.style.right="0";let h=m.createEl("a",{href:"https://bit.ly/o42-medium"}).createEl("img",{attr:{src:"https://miro.medium.com/v2/resize:fill:176:176/1*sHhtYhaCe2Uc3IU0IgKwIQ.png"}});return h.height=e,n};var E=class extends te.Modal{constructor(e,n=!1){super(e.app);this.plugin=e,this.address="",this.openSettingsTabAfterwards=n}submitForm(){return a(this,null,function*(){if(this.address==="")return;let e=this.address.replace("https://github.com/","");if(yield Ce(this.plugin,e)){p(this.plugin,"This plugin is already in the list for beta testing",10);return}(yield x(this.plugin,e,!0))&&this.close()})}onOpen(){this.contentEl.createEl("h4",{text:"Github repository for beta theme:"}),this.contentEl.createEl("form",{},e=>{e.addClass("brat-modal"),new te.Setting(e).addText(o=>{o.setPlaceholder("Repository (example: https://github.com/GitubUserName/repository-name"),o.onChange(r=>{this.address=r.trim()}),o.inputEl.addEventListener("keydown",r=>a(this,null,function*(){r.key==="Enter"&&this.address!==" "&&(r.preventDefault(),yield this.submitForm())})),o.inputEl.style.width="100%",window.setTimeout(()=>{let r=document.querySelector(".setting-item-info");r&&r.remove(),o.inputEl.focus()},10)}),e.createDiv("modal-button-container",o=>{o.createEl("button",{attr:{type:"button"},text:"Never mind"}).addEventListener("click",()=>this.close()),o.createEl("button",{attr:{type:"submit"},cls:"mod-cta",text:"Add Theme"})});let n=e.createDiv();n.style.borderTop="1px solid #ccc",n.style.marginTop="30px";let s=n.createSpan();s.innerHTML="BRAT by TFTHacker",s.style.fontStyle="italic",n.appendChild(s),k(n,!1),window.setTimeout(()=>{e.querySelectorAll(".brat-modal .setting-item-info").forEach(r=>{r.remove()})},50),e.addEventListener("submit",o=>a(this,null,function*(){o.preventDefault(),this.address!==""&&(yield this.submitForm())}))})}onClose(){return a(this,null,function*(){this.openSettingsTabAfterwards&&(yield this.plugin.app.setting.open(),yield this.plugin.app.setting.openTabById("obsidian42-brat"))})}};var ne=class extends v.PluginSettingTab{constructor(e,n){super(e,n);this.plugin=n}display(){let{containerEl:e}=this;e.empty(),k(e,!0),e.createEl("h1",{text:this.plugin.appName}),e.createEl("h2",{text:"by TfTHacker"}),new v.Setting(e).setName("Auto-update plugins at startup").setDesc("If enabled all beta plugins will be checked for updates each time Obsidian starts. Note: this does not update frozen version plugins.").addToggle(s=>{s.setValue(this.plugin.settings.updateAtStartup),s.onChange(o=>a(this,null,function*(){this.plugin.settings.updateAtStartup=o,yield this.plugin.saveSettings()}))}),new v.Setting(e).setName("Auto-update themes at startup").setDesc("If enabled all beta themes will be checked for updates each time Obsidian starts.").addToggle(s=>{s.setValue(this.plugin.settings.updateThemesAtStartup),s.onChange(o=>a(this,null,function*(){this.plugin.settings.updateThemesAtStartup=o,yield this.plugin.saveSettings()}))}),new v.Setting(e).setName("Ribbon Button").setDesc("Toggle ribbon button off and on.").addToggle(s=>{s.setValue(this.plugin.settings.ribbonIconEnabled),s.onChange(o=>a(this,null,function*(){this.plugin.settings.ribbonIconEnabled=o,this.plugin.settings.ribbonIconEnabled===!1?this.plugin.ribbonIcon.remove():this.plugin.showRibbonButton(),yield this.plugin.saveSettings()}))}),e.createEl("hr"),e.createEl("h2",{text:"Beta Plugin List"}),e.createEl("div",{text:'The following is a list of beta plugins added via the command palette "Add a beta plugin for testing" or "Add a beta plugin with frozen version for testing". A frozen version is a specific release of a plugin based on its releease tag. '}),e.createEl("p"),e.createEl("div",{text:"Click the x button next to a plugin to remove it from the list."}),e.createEl("p"),e.createEl("span").createEl("b",{text:"Note: "}),e.createSpan({text:"This does not delete the plugin, this should be done from the Community Plugins tab in Settings."}),new v.Setting(e).addButton(s=>{s.setButtonText("Add Beta plugin"),s.onClick(()=>a(this,null,function*(){this.plugin.app.setting.close(),yield this.plugin.betaPlugins.displayAddNewPluginModal(!0,!1)}))});let n=new Set(this.plugin.settings.pluginSubListFrozenVersion.map(s=>s.repo));for(let s of this.plugin.settings.pluginList)n.has(s)||new v.Setting(e).setName(s).addButton(o=>{o.setIcon("cross"),o.setTooltip("Delete this beta plugin"),o.onClick(()=>a(this,null,function*(){o.buttonEl.textContent===""?o.setButtonText("Click once more to confirm removal"):(o.buttonEl.parentElement.parentElement.remove(),yield this.plugin.betaPlugins.deletePlugin(s))}))});new v.Setting(e).addButton(s=>{s.setButtonText("Add Beta plugin with frozen version"),s.onClick(()=>a(this,null,function*(){this.plugin.app.setting.close(),yield this.plugin.betaPlugins.displayAddNewPluginModal(!0,!0)}))});for(let s of this.plugin.settings.pluginSubListFrozenVersion)new v.Setting(e).setName(`${s.repo} (version ${s.version})`).addButton(o=>{o.setIcon("cross"),o.setTooltip("Delete this beta plugin"),o.onClick(()=>a(this,null,function*(){o.buttonEl.textContent===""?o.setButtonText("Click once more to confirm removal"):(o.buttonEl.parentElement.parentElement.remove(),yield this.plugin.betaPlugins.deletePlugin(s.repo))}))});e.createEl("hr"),e.createEl("h2",{text:"Beta Themes List"}),new v.Setting(e).addButton(s=>{s.setButtonText("Add Beta Theme"),s.onClick(()=>a(this,null,function*(){this.plugin.app.setting.close(),new E(this.plugin).open()}))});for(let s of this.plugin.settings.themesList)new v.Setting(e).setName(s.repo).addButton(o=>{o.setIcon("cross"),o.setTooltip("Delete this beta theme"),o.onClick(()=>a(this,null,function*(){o.buttonEl.textContent===""?o.setButtonText("Click once more to confirm removal"):(o.buttonEl.parentElement.parentElement.remove(),yield ee(this.plugin,s.repo))}))});e.createEl("hr"),e.createEl("h2",{text:"Monitoring"}),new v.Setting(e).setName("Enable Notifications").setDesc("BRAT will provide popup notifications for its various activities. Turn this off means no notifications from BRAT.").addToggle(s=>{s.setValue(this.plugin.settings.notificationsEnabled),s.onChange(o=>a(this,null,function*(){this.plugin.settings.notificationsEnabled=o,yield this.plugin.saveSettings()}))}),new v.Setting(e).setName("Enable Logging").setDesc("Plugin updates will be logged to a file in the log file.").addToggle(s=>{s.setValue(this.plugin.settings.loggingEnabled),s.onChange(o=>a(this,null,function*(){this.plugin.settings.loggingEnabled=o,yield this.plugin.saveSettings()}))}),new v.Setting(this.containerEl).setName("BRAT Log File Location").setDesc("Logs will be saved to this file. Don't add .md to the file name.").addSearch(s=>{s.setPlaceholder("Example: BRAT-log").setValue(this.plugin.settings.loggingPath).onChange(o=>a(this,null,function*(){this.plugin.settings.loggingPath=o,yield this.plugin.saveSettings()}))}),new v.Setting(e).setName("Enable Verbose Logging").setDesc("Get a lot more information in the log.").addToggle(s=>{s.setValue(this.plugin.settings.loggingVerboseEnabled),s.onChange(o=>a(this,null,function*(){this.plugin.settings.loggingVerboseEnabled=o,yield this.plugin.saveSettings()}))}),new v.Setting(e).setName("Debugging Mode").setDesc("Atomic Bomb level console logging. Can be used for troubleshoting and development.").addToggle(s=>{s.setValue(this.plugin.settings.debuggingMode),s.onChange(o=>a(this,null,function*(){this.plugin.settings.debuggingMode=o,yield this.plugin.saveSettings()}))})}};var O=require("obsidian");var $=class extends O.Modal{constructor(e,n,s=!1,o=!1){super(e.app);this.plugin=e,this.betaPlugins=n,this.address="",this.openSettingsTabAfterwards=s,this.useFrozenVersion=o,this.version=""}submitForm(){return a(this,null,function*(){if(this.address==="")return;let e=this.address.replace("https://github.com/","");if(yield Pe(this.plugin,e)){p(this.plugin,"This plugin is already in the list for beta testing",10);return}(yield this.betaPlugins.addPlugin(e,!1,!1,!1,this.version))&&this.close()})}onOpen(){this.contentEl.createEl("h4",{text:"Github repository for beta plugin:"}),this.contentEl.createEl("form",{},e=>{e.addClass("brat-modal"),new O.Setting(e).addText(o=>{o.setPlaceholder("Repository (example: https://github.com/GitubUserName/repository-name)"),o.onChange(r=>{this.address=r.trim()}),o.inputEl.addEventListener("keydown",r=>a(this,null,function*(){r.key==="Enter"&&this.address!==" "&&(this.useFrozenVersion&&this.version!==""||!this.useFrozenVersion)&&(r.preventDefault(),yield this.submitForm())})),o.inputEl.style.width="100%"}),this.useFrozenVersion&&new O.Setting(e).addText(o=>{o.setPlaceholder("Specify the release version tag (example: 1.0.0)"),o.onChange(r=>{this.version=r.trim()}),o.inputEl.style.width="100%"}),e.createDiv("modal-button-container",o=>{o.createEl("button",{attr:{type:"button"},text:"Never mind"}).addEventListener("click",()=>this.close()),o.createEl("button",{attr:{type:"submit"},cls:"mod-cta",text:"Add Plugin"})});let n=e.createDiv();n.style.borderTop="1px solid #ccc",n.style.marginTop="30px";let s=n.createSpan();s.innerHTML="BRAT by TFTHacker",s.style.fontStyle="italic",n.appendChild(s),k(n,!1),window.setTimeout(()=>{e.querySelectorAll(".brat-modal .setting-item-info").forEach(r=>{r.remove()})},50),e.addEventListener("submit",o=>a(this,null,function*(){o.preventDefault(),this.address!==""&&(this.useFrozenVersion&&this.version!==""||!this.useFrozenVersion)&&(yield this.submitForm())}))})}onClose(){return a(this,null,function*(){this.openSettingsTabAfterwards&&(yield this.plugin.app.setting.open(),yield this.plugin.app.setting.openTabById("obsidian42-brat"))})}};var A=require("obsidian");var U=class{constructor(t){this.plugin=t}displayAddNewPluginModal(t=!1,e=!1){return a(this,null,function*(){new $(this.plugin,this,t,e).open()})}validateRepository(t,e=!1,n=!1){return a(this,null,function*(){let o=yield me(t,!e,this.plugin.settings.debuggingMode);return o?"id"in o?"version"in o?o:(n&&p(this.plugin,`${t} The version attribute for the release is missing from the manifest file`,15),null):(n&&p(this.plugin,`${t} The plugin id attribute for the release is missing from the manifest file`,15),null):(n&&p(this.plugin,`${t} This does not seem to be an obsidian plugin, as there is no manifest.json file.`,15),null)})}getAllReleaseFiles(t,e,n,s=""){return a(this,null,function*(){let o=s===""?e.version:s,r=n||s!=="";return{mainJs:yield G(t,o,"main.js",this.plugin.settings.debuggingMode),manifest:r?yield G(t,o,"manifest.json",this.plugin.settings.debuggingMode):"",styles:yield G(t,o,"styles.css",this.plugin.settings.debuggingMode)}})}writeReleaseFilesToPluginFolder(t,e){return a(this,null,function*(){let n=(0,A.normalizePath)(this.plugin.app.vault.configDir+"/plugins/"+t)+"/",s=this.plugin.app.vault.adapter;((yield s.exists(n))===!1||!(yield s.exists(n+"manifest.json")))&&(yield s.mkdir(n)),yield s.write(n+"main.js",e.mainJs),yield s.write(n+"manifest.json",e.manifest),e.styles&&(yield s.write(n+"styles.css",e.styles))})}addPlugin(t,e=!1,n=!1,s=!1,o=""){return a(this,null,function*(){var m;let l=yield this.validateRepository(t,!0,!1),g=!!l;if(g===!1&&(l=yield this.validateRepository(t,!1,!0)),l===null){let d=`${t} A manifest.json or manifest-beta.json file does not exist in the root directory of the repository. This plugin cannot be installed.`;return this.plugin.log(d,!0),p(this.plugin,`${d}`,10),!1}if(!l.hasOwnProperty("version")){let d=`${t} The manifest${g?"-beta":""}.json file in the root directory of the repository does not have a version number in the file. This plugin cannot be installed.`;return this.plugin.log(d,!0),p(this.plugin,`${d}`,10),!1}if(l.hasOwnProperty("minAppVersion")&&!(0,A.requireApiVersion)(l.minAppVersion)){let d=`Plugin: ${t} The manifest${g?"-beta":""}.json for this plugin indicates that the Obsidian version of the app needs to be ${l.minAppVersion}, but this installation of Obsidian is ${A.apiVersion}. You will need to update your Obsidian to use this plugin or contact the plugin developer for more information.`;return this.plugin.log(d,!0),p(this.plugin,`${d}`,30),!1}let u=()=>a(this,null,function*(){let d=yield this.getAllReleaseFiles(t,l,g,o);if((g||d.manifest==="")&&(d.manifest=JSON.stringify(l)),d.mainJs===null){let h=`${t} The release is not complete and cannot be download. main.js is missing from the Release`;return this.plugin.log(h,!0),p(this.plugin,`${h}`,10),null}return d});if(e===!1){let d=yield u();if(d===null)return!1;yield this.writeReleaseFilesToPluginFolder(l.id,d),yield Te(this.plugin,t,o),yield this.plugin.app.plugins.loadManifests();let h=o===""?"":` (version: ${o})`,T=`${t}${h} The plugin has been registered with BRAT. You may still need to enable it the Community Plugin List.`;this.plugin.log(T,!0),p(this.plugin,T,10)}else{let d=this.plugin.app.vault.configDir+"/plugins/"+l.id+"/",h="";try{h=yield this.plugin.app.vault.adapter.read(d+"manifest.json")}catch(w){if(w.errno===-4058||w.errno===-2)return yield this.addPlugin(t,!1,g,!1,o),!0;console.log("BRAT - Local Manifest Load",l.id,JSON.stringify(w,null,2))}if(o!==""||this.plugin.settings.pluginSubListFrozenVersion.map(w=>w.repo).includes(t))return p(this.plugin,`The version of ${t} is frozen, not updating.`,3),!1;let T=yield JSON.parse(h);if(T.version!==l.version){let w=yield u();if(w===null)return!1;if(n){let b=`There is an update available for ${l.id} from version ${T.version} to ${l.version}. `;this.plugin.log(b+`[Release Info](https://github.com/${t}/releases/tag/${l.version})`,!1),p(this.plugin,b,30,()=>a(this,null,function*(){window.open(`https://github.com/${t}/releases/tag/${l.version}`)}))}else{yield this.writeReleaseFilesToPluginFolder(l.id,w),yield this.plugin.app.plugins.loadManifests(),(m=this.plugin.app.plugins.plugins[l.id])!=null&&m.manifest&&(yield this.reloadPlugin(l.id));let b=`${l.id} Plugin has been updated from version ${T.version} to ${l.version}. `;this.plugin.log(b+`[Release Info](https://github.com/${t}/releases/tag/${l.version})`,!1),p(this.plugin,b,30,()=>a(this,null,function*(){window.open(`https://github.com/${t}/releases/tag/${l.version}`)}))}}else s&&p(this.plugin,`No update available for ${t}`,3)}return!0})}reloadPlugin(t){return a(this,null,function*(){let e=this.plugin.app.plugins;try{yield e.disablePlugin(t),yield e.enablePlugin(t)}catch(n){this.plugin.settings.debuggingMode&&console.log("reload plugin",n)}})}updatePlugin(t,e=!1,n=!1){return a(this,null,function*(){let s=yield this.addPlugin(t,!0,e,n);return s===!1&&e===!1&&p(this.plugin,`${t} Update of plugin failed.`),s})}checkForUpdatesAndInstallUpdates(t=!1,e=!1){return a(this,null,function*(){if((yield X())===!1){console.log("BRAT: No internet detected.");return}let n,s="Checking for plugin updates STARTED";this.plugin.log(s,!0),t&&this.plugin.settings.notificationsEnabled&&(n=new A.Notice(`BRAT ${s}`,3e4));let o=new Set(this.plugin.settings.pluginSubListFrozenVersion.map(l=>l.repo));for(let l of this.plugin.settings.pluginList)o.has(l)||(yield this.updatePlugin(l,e));let r="Checking for plugin updates COMPLETED";this.plugin.log(r,!0),t&&(n.hide(),p(this.plugin,r,10))})}deletePlugin(t){return a(this,null,function*(){let e=`Removed ${t} from BRAT plugin list`;this.plugin.log(e,!0),this.plugin.settings.pluginList=this.plugin.settings.pluginList.filter(n=>n!=t),this.plugin.settings.pluginSubListFrozenVersion=this.plugin.settings.pluginSubListFrozenVersion.filter(n=>n.repo!=t),this.plugin.saveSettings()})}getEnabledDisabledPlugins(t){let e=this.plugin.app.plugins,n=Object.values(e.manifests),s=Object.values(e.plugins).map(o=>o.manifest);return t?n.filter(o=>s.find(r=>o.id===r.id)):n.filter(o=>!s.find(r=>o.id===r.id))}};var Fe=require("obsidian");function Ae(){(0,Fe.addIcon)("BratIcon",'')}var J=require("obsidian"),_e=Ze(ze());function He(i,t,e=!1){if(i.settings.debuggingMode&&console.log("BRAT: "+t),i.settings.loggingEnabled){if(i.settings.loggingVerboseEnabled===!1&&e===!0)return;{let n=i.settings.loggingPath+".md",s="[["+(0,J.moment)().format((0,_e.getDailyNoteSettings)().format).toString()+"]] "+(0,J.moment)().format("HH:mm"),o=J.Platform.isDesktop?window.require("os").hostname():"MOBILE",r=s+" "+o+" "+t.replace(` `," ")+` `;setTimeout(()=>a(this,null,function*(){if((yield i.app.vault.adapter.exists(n))===!0){let l=yield i.app.vault.adapter.read(n);r=r+l;let g=i.app.vault.getAbstractFileByPath(n);yield i.app.vault.modify(g,r)}else yield i.app.vault.create(n,r)}),10)}}}var Ve=require("obsidian");var S=class extends Ve.FuzzySuggestModal{constructor(e){super(e.app);this.scope.register(["Shift"],"Enter",n=>this.enterTrigger(n)),this.scope.register(["Ctrl"],"Enter",n=>this.enterTrigger(n))}setSuggesterData(e){this.data=e}display(e){return a(this,null,function*(){this.callbackFunction=e,this.open()})}getItems(){return this.data}getItemText(e){return e.display}onChooseItem(){}renderSuggestion(e,n){n.createEl("div",{text:e.item.display})}enterTrigger(e){let n=document.querySelector(".suggestion-item.is-selected div").textContent,s=this.data.find(o=>o.display===n);s&&(this.invokeCallback(s,e),this.close())}onChooseSuggestion(e,n){this.invokeCallback(e.item,n)}invokeCallback(e,n){this.callbackFunction(e,n)}};var W=class{constructor(t){this.bratCommands=[{id:"BRAT-AddBetaPlugin",icon:"BratIcon",name:"Plugins: Add a beta plugin for testing",showInRibbon:!0,callback:()=>a(this,null,function*(){yield this.plugin.betaPlugins.displayAddNewPluginModal(!1,!1)})},{id:"BRAT-AddBetaPluginWithFrozenVersion",icon:"BratIcon",name:"Plugins: Add a beta plugin with frozen version based on a release tag",showInRibbon:!0,callback:()=>a(this,null,function*(){yield this.plugin.betaPlugins.displayAddNewPluginModal(!1,!0)})},{id:"BRAT-checkForUpdatesAndUpdate",icon:"BratIcon",name:"Plugins: Check for updates to all beta plugins and UPDATE",showInRibbon:!0,callback:()=>a(this,null,function*(){yield this.plugin.betaPlugins.checkForUpdatesAndInstallUpdates(!0,!1)})},{id:"BRAT-checkForUpdatesAndDontUpdate",icon:"BratIcon",name:"Plugins: Only check for updates to beta plugins, but don't Update",showInRibbon:!0,callback:()=>a(this,null,function*(){yield this.plugin.betaPlugins.checkForUpdatesAndInstallUpdates(!0,!0)})},{id:"BRAT-updateOnePlugin",icon:"BratIcon",name:"Plugins: Choose a single plugin version to update",showInRibbon:!0,callback:()=>a(this,null,function*(){let t=new Set(this.plugin.settings.pluginSubListFrozenVersion.map(s=>s.repo)),e=Object.values(this.plugin.settings.pluginList).filter(s=>!t.has(s)).map(s=>({display:s,info:s})),n=new S(this.plugin);n.setSuggesterData(e),yield n.display(s=>a(this,null,function*(){let o=`Checking for updates for ${s.info}`;this.plugin.log(o,!0),p(this.plugin,` ${o}`,3),yield this.plugin.betaPlugins.updatePlugin(s.info,!1,!0)}))})},{id:"BRAT-restartPlugin",icon:"BratIcon",name:"Plugins: Restart a plugin that is already installed",showInRibbon:!0,callback:()=>a(this,null,function*(){let t=Object.values(this.plugin.app.plugins.manifests).map(n=>({display:n.id,info:n.id})),e=new S(this.plugin);e.setSuggesterData(t),yield e.display(n=>a(this,null,function*(){p(this.plugin,`${n.info} Plugin reloading .....`,5),yield this.plugin.betaPlugins.reloadPlugin(n.info)}))})},{id:"BRAT-disablePlugin",icon:"BratIcon",name:"Plugins: Disable a plugin - toggle it off",showInRibbon:!0,callback:()=>a(this,null,function*(){let t=this.plugin.betaPlugins.getEnabledDisabledPlugins(!0).map(n=>({display:`${n.name} (${n.id})`,info:n.id})),e=new S(this.plugin);e.setSuggesterData(t),yield e.display(n=>a(this,null,function*(){this.plugin.log(`${n.display} plugin disabled`,!1),this.plugin.settings.debuggingMode&&console.log(n.info),yield this.plugin.app.plugins.disablePluginAndSave(n.info)}))})},{id:"BRAT-enablePlugin",icon:"BratIcon",name:"Plugins: Enable a plugin - toggle it on",showInRibbon:!0,callback:()=>a(this,null,function*(){let t=this.plugin.betaPlugins.getEnabledDisabledPlugins(!1).map(n=>({display:`${n.name} (${n.id})`,info:n.id})),e=new S(this.plugin);e.setSuggesterData(t),yield e.display(n=>a(this,null,function*(){this.plugin.log(`${n.display} plugin enabled`,!1),yield this.plugin.app.plugins.enablePluginAndSave(n.info)}))})},{id:"BRAT-openGitHubZRepository",icon:"BratIcon",name:"Plugins: Open the GitHub repository for a plugin",showInRibbon:!0,callback:()=>a(this,null,function*(){let t=yield fe(this.plugin.settings.debuggingMode),e=Object.values(t).map(o=>({display:`Plugin: ${o.name} (${o.repo})`,info:o.repo})),n=Object.values(this.plugin.settings.pluginList).map(o=>({display:"BRAT: "+o,info:o}));e.forEach(o=>n.push(o));let s=new S(this.plugin);s.setSuggesterData(n),yield s.display(o=>a(this,null,function*(){o.info&&window.open(`https://github.com/${o.info}`)}))})},{id:"BRAT-openGitHubRepoTheme",icon:"BratIcon",name:"Themes: Open the GitHub repository for a theme (appearance)",showInRibbon:!0,callback:()=>a(this,null,function*(){let t=yield he(this.plugin.settings.debuggingMode),e=Object.values(t).map(s=>({display:`Theme: ${s.name} (${s.repo})`,info:s.repo})),n=new S(this.plugin);n.setSuggesterData(e),yield n.display(s=>a(this,null,function*(){s.info&&window.open(`https://github.com/${s.info}`)}))})},{id:"BRAT-opentPluginSettings",icon:"BratIcon",name:"Plugins: Open Plugin Settings Tab",showInRibbon:!0,callback:()=>a(this,null,function*(){let t=this.plugin.app.setting,e=Object.values(t.pluginTabs).map(o=>({display:"Plugin: "+o.name,info:o.id})),n=new S(this.plugin),s=Object.values(t.settingTabs).map(o=>({display:"Core: "+o.name,info:o.id}));e.forEach(o=>s.push(o)),n.setSuggesterData(s),yield n.display(o=>a(this,null,function*(){t.open(),t.openTabById(o.info)}))})},{id:"BRAT-GrabBetaTheme",icon:"BratIcon",name:"Themes: Grab a beta theme for testing from a Github repository",showInRibbon:!0,callback:()=>a(this,null,function*(){new E(this.plugin).open()})},{id:"BRAT-updateBetaThemes",icon:"BratIcon",name:"Themes: Update beta themes",showInRibbon:!0,callback:()=>a(this,null,function*(){return yield I(this.plugin,!0)})},{id:"BRAT-allCommands",icon:"BratIcon",name:"All Commands list",showInRibbon:!1,callback:()=>a(this,null,function*(){return this.ribbonDisplayCommands()})}];this.plugin=t,this.bratCommands.forEach(e=>a(this,null,function*(){this.plugin.addCommand({id:e.id,name:e.name,icon:e.icon,callback:()=>a(this,null,function*(){yield e.callback()})})}))}ribbonDisplayCommands(){return a(this,null,function*(){let t=[];this.bratCommands.forEach(r=>{r.showInRibbon&&t.push({display:r.name,info:r.callback})});let e=new S(this.plugin),n=this.plugin.app.setting,s=Object.values(n.settingTabs).map(r=>({display:"Core: "+r.name,info:()=>a(this,null,function*(){n.open(),n.openTabById(r.id)})})),o=Object.values(n.pluginTabs).map(r=>({display:"Plugin: "+r.name,info:()=>a(this,null,function*(){n.open(),n.openTabById(r.id)})}));t.push({display:"---- Core Plugin Settings ----",info:()=>a(this,null,function*(){yield this.ribbonDisplayCommands()})}),s.forEach(r=>t.push(r)),t.push({display:"---- Plugin Settings ----",info:()=>a(this,null,function*(){yield this.ribbonDisplayCommands()})}),o.forEach(r=>t.push(r)),e.setSuggesterData(t),yield e.display(r=>a(this,null,function*(){return yield r.info()}))})}};var Q=class{constructor(t){this.console=(t,...e)=>{console.log("BRAT: "+t,e)};this.themes={themeseCheckAndUpates:t=>a(this,null,function*(){yield I(this.plugin,t)}),themeInstallTheme:t=>a(this,null,function*(){let e=t.replace("https://github.com/","");yield x(this.plugin,e,!0)}),themesDelete:t=>a(this,null,function*(){let e=t.replace("https://github.com/","");yield ee(this.plugin,e)}),grabCommmunityThemeCssFile:(t,e=!1)=>a(this,null,function*(){return yield L(t,e,this.plugin.settings.debuggingMode)}),grabChecksumOfThemeCssFile:(t,e=!1)=>a(this,null,function*(){return yield R(t,e,this.plugin.settings.debuggingMode)}),grabLastCommitDateForAFile:(t,e)=>a(this,null,function*(){return yield we(t,e)})};this.plugin=t}};var ie=class extends Ye.Plugin{constructor(){super(...arguments);this.appName="Obsidian42 - Beta Reviewer's Auto-update Tool (BRAT)";this.appID="obsidian42-brat"}onload(){return a(this,null,function*(){console.log("loading Obsidian42 - BRAT"),yield this.loadSettings(),this.addSettingTab(new ne(this.app,this)),this.betaPlugins=new U(this),this.commands=new W(this),Ae(),this.settings.ribbonIconEnabled&&this.showRibbonButton(),this.app.workspace.onLayoutReady(()=>{this.settings.updateAtStartup&&setTimeout(()=>a(this,null,function*(){yield this.betaPlugins.checkForUpdatesAndInstallUpdates(!1)}),6e4),this.settings.updateThemesAtStartup&&setTimeout(()=>a(this,null,function*(){yield I(this,!1)}),12e4),setTimeout(()=>a(this,null,function*(){this.bratAPI=new Q(this),globalThis.bratAPI=this.bratAPI}),500)})})}showRibbonButton(){this.ribbonIcon=this.addRibbonIcon("BratIcon","BRAT",()=>a(this,null,function*(){return this.commands.ribbonDisplayCommands()}))}log(e,n=!1){He(this,e,n)}onunload(){console.log("unloading "+this.appName)}loadSettings(){return a(this,null,function*(){this.settings=Object.assign({},ye,yield this.loadData())})}saveSettings(){return a(this,null,function*(){yield this.saveData(this.settings)})}}; //# sourceMappingURL=data:application/json;base64,ewogICJ2ZXJzaW9uIjogMywKICAic291cmNlcyI6IFsiLi4vbm9kZV9tb2R1bGVzL29ic2lkaWFuLWRhaWx5LW5vdGVzLWludGVyZmFjZS9kaXN0L21haW4uanMiLCAiLi4vc3JjL21haW4udHMiLCAiLi4vc3JjL3VpL1NldHRpbmdzVGFiLnRzIiwgIi4uL3NyYy9mZWF0dXJlcy90aGVtZXMudHMiLCAiLi4vc3JjL2ZlYXR1cmVzL2dpdGh1YlV0aWxzLnRzIiwgIi4uL3NyYy91aS9zZXR0aW5ncy50cyIsICIuLi9zcmMvdXRpbHMvbm90aWZpY2F0aW9ucy50cyIsICIuLi9zcmMvdXRpbHMvaW50ZXJuZXRjb25uZWN0aW9uLnRzIiwgIi4uL3NyYy91aS9BZGROZXdUaGVtZS50cyIsICIuLi9zcmMvdWkvUHJvbW90aW9uYWwudHMiLCAiLi4vc3JjL3VpL0FkZE5ld1BsdWdpbk1vZGFsLnRzIiwgIi4uL3NyYy9mZWF0dXJlcy9CZXRhUGx1Z2lucy50cyIsICIuLi9zcmMvdWkvaWNvbnMudHMiLCAiLi4vc3JjL3V0aWxzL2xvZ2dpbmcudHMiLCAiLi4vc3JjL3VpL0dlbmVyaWNGdXp6eVN1Z2dlc3Rlci50cyIsICIuLi9zcmMvdWkvUGx1Z2luQ29tbWFuZHMudHMiLCAiLi4vc3JjL3V0aWxzL0JyYXRBUEkudHMiXSwKICAic291cmNlc0NvbnRlbnQiOiBbIid1c2Ugc3RyaWN0JztcblxuT2JqZWN0LmRlZmluZVByb3BlcnR5KGV4cG9ydHMsICdfX2VzTW9kdWxlJywgeyB2YWx1ZTogdHJ1ZSB9KTtcblxudmFyIG9ic2lkaWFuID0gcmVxdWlyZSgnb2JzaWRpYW4nKTtcblxuY29uc3QgREV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XBsYWNlKC97e1xccyp0aW1lXFxzKn19L2dpLCBtb21lbnQoKS5mb3JtYXQoXCJISDptbVwiKSlcbiAgICAgICAgICAgIC5yZXBsYWNlKC97e1xccyp0aXRsZVxccyp9fS9naSwgZmlsZW5hbWUpXG4gICAgICAgICAgICAucmVwbGFjZSgve3tcXHMqKGRhdGV8dGltZSlcXHMqKChbKy1dXFxkKykoW3lxbXdkaHNdKSk/XFxzKig6Lis/KT99fS9naSwgKF8sIF90aW1lT3JEYXRlLCBjYWxjLCB0aW1lRGVsdGEsIHVuaXQsIG1vbWVudEZvcm1hdCkgPT4ge1xuICAgICAgICAgICAgY29uc3Qgbm93ID0gbW9tZW50KCk7XG4gICAgICAgICAgICBjb25zdCBjdXJyZW50RGF0ZSA9IGRhdGUuY2xvbmUoKS5zZXQoe1xuICAgICAgICAgICAgICAgIGhvdXI6IG5vdy5nZXQoXCJob3VyXCIpLFxuICAgICAgICAgICAgICAgIG1pbnV0ZTogbm93LmdldChcIm1pbnV0ZVwiKSxcbiAgICAgICAgICAgICAgICBzZWNvbmQ6IG5vdy5nZXQoXCJzZWNvbmRcIiksXG4gICAgICAgICAgICB9KTtcbiAgICAgICAgICAgIGlmIChjYWxjKSB7XG4gICAgICAgICAgICAgICAgY3VycmVudERhdGUuYWRkKHBhcnNlSW50KHRpbWVEZWx0YSwgMTApLCB1bml0KTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIGlmIChtb21lbnRGb3JtYXQpIHtcbiAgICAgICAgICAgICAgICByZXR1cm4gY3VycmVudERhdGUuZm9ybWF0KG1vbWVudEZvcm1hdC5zdWJzdHJpbmcoMSkudHJpbSgpKTtcbiAgICAgICAgICAgIH1cbiAgICAgICAgICAgIHJldHVybiBjdXJyZW50RGF0ZS5mb3JtYXQoZm9ybWF0KTtcbiAgICAgICAgfSlcbiAgICAgICAgICAgIC5yZXBsYWNlKC97e1xccyp5ZXN0ZXJkYXlcXHMqfX0vZ2ksIGRhdGUuY2xvbmUoKS5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ZW1wbGF0ZUNvbnRlbnRzXG4gICAgICAgICAgICAucmVwbGFjZSgve3tcXHMqKGRhdGV8dGltZSlcXHMqKChbKy1dXFxkKykoW3lxbXdkaHNdKSk/XFxzKig6Lis/KT99fS9naSwgKF8sIF90aW1lT3JEYXRlLCBjYWxjLCB0aW1lRGVsdGEsIHVuaXQsIG1vbWVudEZvcm1hdCkgPT4ge1xuICAgICAgICAgICAgY29uc3Qgbm93ID0gd2luZG93Lm1vbWVudCgpO1xuICAgICAgICAgICAgY29uc3QgY3VycmVudERhdGUgPSBkYXRlLmNsb25lKCkuc2V0KHtcbiAgICAgICAgICAgICAgICBob3VyOiBub3cuZ2V0KFwiaG91clwiKSxcbiAgICAgICAgICAgICAgICBtaW51dGU6IG5vdy5nZXQoXCJtaW51dGVcIiksXG4gICAgICAgICAgICAgICAgc2Vjb25kOiBub3cuZ2V0KFwic2Vjb25kXCIpLFxuICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICBpZiAoY2FsYykge1xuICAgICAgICAgICAgICAgIGN1cnJlbnREYXRlLmFkZChwYXJzZUludCh0aW1lRGVsdGEsIDEwKSwgdW5pdCk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBpZiAobW9tZW50Rm9ybWF0KSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuIGN1cnJlbnREYXRlLmZvcm1hdChtb21lbnRGb3JtYXQuc3Vic3RyaW5nKDEpLnRyaW0oKSk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICByZXR1cm4gY3VycmVudERhdGUuZm9ybWF0KGZvcm1hdCk7XG4gICAgICAgIH0pXG4gICAgICAgICAgICAucmVwbGFjZSgve3tcXHMqdGl0bGVcXHMqfX0vZ2ksIGZpbGVuYW1lKVxuICAgICAgICAgICAgLnJlcGxhY2UoL3t7XFxzKnRpbWVcXHMqfX0vZ2ksIHdpbmRvdy5tb21lbnQoKS5mb3JtYXQoXCJISDptbVwiKSlcbiAgICAgICAgICAgIC5yZXBsYWNlKC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IGN1cnJlbnREYXRlID0gZGF0ZS5jbG9uZSgpLnNldCh7XG4gICAgICAgICAgICAgICAgaG91cjogbm93LmdldChcImhvdXJcIiksXG4gICAgICAgICAgICAgICAgbWludXRlOiBub3cuZ2V0KFwibWludXRlXCIpLFxuICAgICAgICAgICAgICAgIHNlY29uZDogbm93LmdldChcInNlY29uZFwiKSxcbiAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgaWYgKGNhbGMpIHtcbiAgICAgICAgICAgICAgICBjdXJyZW50RGF0ZS5hZGQocGFyc2VJbnQodGltZURlbHRhLCAxMCksIHVuaXQpO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgaWYgKG1vbWVudEZvcm1hdCkge1xuICAgICAgICAgICAgICAgIHJldHVybiBjdXJyZW50RGF0ZS5mb3JtYXQobW9tZW50Rm9ybWF0LnN1YnN0cmluZygxKS50cmltKCkpO1xuICAgICAgICAgICAgfVxuICAgICAgICAgICAgcmV0dXJuIGN1cnJlbnREYXRlLmZvcm1hdChmb3JtYXQpO1xuICAgICAgICB9KVxuICAgICAgICAgICAgLnJlcGxhY2UoL3t7XFxzKmRhdGVcXHMqfX0vZ2ksIGZpbGVuYW1lKVxuICAgICAgICAgICAgLnJlcGxhY2UoL3t7XFxzKnRpbWVcXHMqfX0vZ2ksIHdpbmRvdy5tb21lbnQoKS5mb3JtYXQoXCJISDptbVwiKSlcbiAgICAgICAgICAgIC5yZXBsYWNlKC97e1xccyp0aXRsZVxccyp9fS9naSwgZmlsZW5hbWUpKTtcbiAgICAgICAgLy8gZXNsaW50LWRpc2FibGUtbmV4dC1saW5lIEB0eXBlc2NyaXB0LWVzbGludC9uby1leHBsaWNpdC1hbnlcbiAgICAgICAgd2luZG93LmFwcC5mb2xkTWFuYWdlci5zYXZlKGNyZWF0ZWRGaWxlLCBJRm9sZEluZm8pO1xuICAgICAgICByZXR1cm4gY3JlYXRlZEZpbGU7XG4gICAgfVxuICAgIGNhdGNoIChlcnIpIHtcbiAgICAgICA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JtYXQoZm9ybWF0KTtcbiAgICBjb25zdCBub3JtYWxpemVkUGF0aCA9IGF3YWl0IGdldE5vdGVQYXRoKGZvbGRlciwgZmlsZW5hbWUpO1xuICAgIHRyeSB7XG4gICAgICAgIGNvbnN0IGNyZWF0ZWRGaWxlID0gYXdhaXQgdmF1bHQuY3JlYXRlKG5vcm1hbGl6ZWRQYXRoLCB0ZW1wbGF0ZUNvbnRlbnRzXG4gICAgICAgICAgICAucmVwbGFjZSgve3tcXHMqKGRhdGV8dGltZSlcXHMqKChbKy1dXFxkKykoW3lxbXdkaHNdKSk/XFxzKig6Lis/KT99fS9naSwgKF8sIF90aW1lT3JEYXRlLCBjYWxjLCB0aW1lRGVsdGEsIHVuaXQsIG1vbWVudEZvcm1hdCkgPT4ge1xuICAgICAgICAgICAgY29uc3Qgbm93ID0gd2luZG93Lm1vbWVudCgpO1xuICAgICAgICAgICAgY29uc3QgY3VycmVudERhdGUgPSBkYXRlLmNsb25lKCkuc2V0KHtcbiAgICAgICAgICAgICAgICBob3VyOiBub3cuZ2V0KFwiaG91clwiKSxcbiAgICAgICAgICAgICAgICBtaW51dGU6IG5vdy5nZXQoXCJtaW51dGVcIiksXG4gICAgICAgICAgICAgICAgc2Vjb25kOiBub3cuZ2V0KFwic2Vjb25kXCIpLFxuICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICBpZiAoY2FsYykge1xuICAgICAgICAgICAgICAgIGN1cnJlbnREYXRlLmFkZChwYXJzZUludCh0aW1lRGVsdGEsIDEwKSwgdW5pdCk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICBpZiAobW9tZW50Rm9ybWF0KSB7XG4gICAgICAgICAgICAgICAgcmV0dXJuIGN1cnJlbnREYXRlLmZvcm1hdChtb21lbnRGb3JtYXQuc3Vic3RyaW5nKDEpLnRyaW0oKSk7XG4gICAgICAgICAgICB9XG4gICAgICAgICAgICByZXR1cm4gY3VycmVudERhdGUuZm9ybWF0KGZvcm1hdCk7XG4gICAgICAgIH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AgICAgICB0aGlzLmNvbnRlbnRFbC5jcmVhdGVFbCgnaDQnLCB7IHRleHQ6IFwiR2l0aHViIHJlcG9zaXRvcnkgZm9yIGJldGEgdGhlbWU6XCIgfSk7XG4gICAgICAgIHRoaXMuY29udGVudEVsLmNyZWF0ZUVsKCdmb3JtJywge30sIChmb3JtRWwpID0+IHtcbiAgICAgICAgICAgIGZvcm1FbC5hZGRDbGFzcyhcImJyYXQtbW9kYWxcIik7XG4gICAgICAgICAgICBuZXcgU2V0dGluZyhmb3JtRWwpXG4gICAgICAgICAgICAgICAgLmFkZFRleHQoKHRleHRFbCkgPT4ge1xuICAgICAgICAgICAgICAgICAgICB0ZXh0RWwuc2V0UGxhY2Vob2xkZXIoJ1JlcG9zaXRvcnkgKGV4YW1wbGU6IGh0dHBzOi8vZ2l0aHViLmNvbS9HaXR1YlVzZXJOYW1lL3JlcG9zaXRvcnktbmFtZScpO1xuICAgICAgICAgICAgICAgICAgICB0ZXh0RWwub25DaGFuZ2UoKHZhbHVlKSA9PiB7XG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLmFkZHJlc3MgPSB2YWx1ZS50cmltKCk7XG4gICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgICAgICB0ZXh0RWwuaW5wdXRFbC5hZGRFdmVudExpc3RlbmVyKCdrZXlkb3duJywgYXN5bmMgKGU6IEtleWJvYXJkRXZlbnQpID0+IHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChlLmtleSA9PT0gJ0VudGVyJyAmJiB0aGlzLmFkZHJlc3MgIT09ICcgJykge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGUucHJldmVudERlZmF1bHQoKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICBhd2FpdCB0aGlzLnN1Ym1pdEZvcm0oKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH1cbiAgICAgICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICAgICAgICAgIHRleHRFbC5pbnB1dEVsLnN0eWxlLndpZHRoID0gXCIxMDAlXCI7XG4gICAgICAgICAgICAgICAgICAgIHdpbmRvdy5zZXRUaW1lb3V0KCgpID0+IHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGNvbnN0IHRpdGxlID0gZG9jdW1lbnQucXVlcnlTZWxlY3RvcihcIi5zZXR0aW5nLWl0ZW0taW5mb1wiKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmICh0aXRsZSkgdGl0bGUucmVtb3ZlKCk7XG4gICAgICAgICAgICAgICAgICAgICAgICB0ZXh0RWwuaW5wdXRFbC5mb2N1cygpXG4gICAgICAgICAgICAgICAgICAgIH0sIDEwKTtcbiAgICAgICAgICAgICAgICB9KTtcblxuICAgICAgICAgICAgZm9ybUVsLmNyZWF0ZURpdignbW9kYWwtYnV0dG9uLWNvbnRhaW5lcicsIChidXR0b25Db250YWluZXJFbCkgPT4ge1xuICAgICAgICAgICAgICAgIGJ1dHRvbkNvbnRhaW5lckVsXG4gICAgICAgICAgICAgICAgICAgIC5jcmVhdGVFbCgnYnV0dG9uJywgeyBhdHRyOiB7IHR5cGU6ICdidXR0b24nIH0sIHRleHQ6ICdOZXZlciBtaW5kJyB9KVxuICAgICAgICAgICAgICAgICAgICAuYWRkRXZlbnRMaXN0ZW5lcignY2xpY2snLCAoKSA9PiB0aGlzLmNsb3NlKCkpO1xuICAgICAgICAgICAgICAgIGJ1dHRvbkNvbnRhaW5lckVsLmNyZWF0ZUVsKCdidXR0b24nLCB7XG4gICAgICAgICAgICAgICAgICAgIGF0dHI6IHsgdHlwZTogJ3N1Ym1pdCcgfSxcbiAgICAgICAgICAgICAgICAgICAgY2xzOiAnbW9kLWN0YScsXG4gICAgICAgICAgICAgICAgICAgIHRleHQ6ICdBZGQgVGhlbWUnLFxuICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgfSk7XG5cbiAgICAgICAgICAgIGNvbnN0IG5ld0RpdiA9IGZvcm1FbC5jcmVhdGVEaX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CB7XG4gICAgICAgIHRoaXMuY29udGVudEVsLmNyZWF0ZUVsKCdoNCcsIHsgdGV4dDogXCJHaXRodWIgcmVwb3NpdG9yeSBmb3IgYmV0YSBwbHVnaW46XCIgfSk7XG4gICAgICAgIHRoaXMuY29udGVudEVsLmNyZWF0ZUVsKCdmb3JtJywge30sIChmb3JtRWwpID0+IHtcbiAgICAgICAgICAgIGZvcm1FbC5hZGRDbGFzcyhcImJyYXQtbW9kYWxcIilcbiAgICAgICAgICAgIG5ldyBTZXR0aW5nKGZvcm1FbClcbiAgICAgICAgICAgICAgICAuYWRkVGV4dCgodGV4dEVsKSA9PiB7XG4gICAgICAgICAgICAgICAgICAgIHRleHRFbC5zZXRQbGFjZWhvbGRlcignUmVwb3NpdG9yeSAoZXhhbXBsZTogaHR0cHM6Ly9naXRodWIuY29tL0dpdHViVXNlck5hbWUvcmVwb3NpdG9yeS1uYW1lKScpO1xuICAgICAgICAgICAgICAgICAgICB0ZXh0RWwub25DaGFuZ2UoKHZhbHVlKSA9PiB7XG4gICAgICAgICAgICAgICAgICAgICAgICB0aGlzLmFkZHJlc3MgPSB2YWx1ZS50cmltKCk7XG4gICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgICAgICB0ZXh0RWwuaW5wdXRFbC5hZGRFdmVudExpc3RlbmVyKCdrZXlkb3duJywgYXN5bmMgKGU6IEtleWJvYXJkRXZlbnQpID0+IHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGlmIChlLmtleSA9PT0gJ0VudGVyJyAmJiB0aGlzLmFkZHJlc3MgIT09ICcgJykge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIGlmIChcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgKHRoaXMudXNlRnJvemVuVmVyc2lvbiAmJiB0aGlzLnZlcnNpb24gIT09IFwiXCIpIFxuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICB8fCAoIXRoaXMudXNlRnJvemVuVmVyc2lvbilcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICApIHtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgZS5wcmV2ZW50RGVmYXVsdCgpO1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgICBhd2FpdCB0aGlzLnN1Ym1pdEZvcm0oKTtcbiAgICAgICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgICAgICB0ZXh0RWwuaW5wdXRFbC5zdHlsZS53aWR0aCA9IFwiMTAwJVwiO1xuICAgICAgICAgICAgICAgIH0pO1xuXG4gICAgICAgICAgICBpZiAodGhpcy51c2VGcm96ZW5WZXJzaW9uKSB7XG4gICAgICAgICAgICAgICAgbmV3IFNldHRpbmcoZm9ybUVsKVxuICAgICAgICAgICAgICAgICAgICAuYWRkVGV4dCgodGV4dEVsKSA9PiB7XG4gICAgICAgICAgICAgICAgICAgICAgICB0ZXh0RWwuc2V0UGxhY2Vob2xkZXIoJ1NwZWNpZnkgdGhlIHJlbGVhc2UgdmVyc2lvbiB0YWcgKGV4YW1wbGU6IDEuMC4wKScpO1xuICAgICAgICAgICAgICAgICAgICAgICAgdGV4dEVsLm9uQ2hhbmdlKCh2YWx1ZSkgPT4ge1xuICAgICAgICAgICAgICAgICAgICAgICAgICAgIHRoaXMudmVyc2lvbiA9IHZhbHVlLnRyaW0oKTtcbiAgICAgICAgICAgICAgICAgICAgICAgIH0pO1xuICAgICAgICAgICAgICAgICAgICAgICAgdGV4dEVsLmlucHV0RWwuc3R5bGUud2lkdGggPSBcIjEwMCVcIjtcbiAgICAgICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICB9XG5cbiAgICAgICAgICAgIGZvcm1FbC5jcmVhdGVEaXYoJ21vZGFsLWJ1dHRvbi1jb250YWluZXInLCAoYnV0dG9uQ29udGFpbmVyRWwpID0+IHtcbiAgICAgICAgICAgICAgICBidXR0b25Db250YWluZXJFbFxuICAgICAgICAgICAgICAgICAgICAuY3JlYXRlRWwoJ2J1dHRvbicsIHsgYXR0cjogeyB0eXBlOiAnYnV0dG9uJyB9LCB0ZXh0OiAnTmV2ZXIgbWluZCcgfSlcbiAgICAgICAgICAgICAgICAgICAgLmFkZEV2ZW50TGlzdGVuZXIoJ2NsaWNrJywgKCkgPT4gdGhpcy5jbG9zZSgpKTtcbiAgICAgICAgICAgICAgICBidXR0b25Db250YWluZXJFbC5jcmVhdGVFbCgnYnV0dG9uJywge1xuICAgICAgICAgICAgICAgICAgICBhdHRyOiB7IHR5cGU6ICdzdWJtaXQnIH0sXG4gICAgICAgICAgICAgICAgICAgIGNsczogJ21vZC1jdGEnLFxuICAgICAgICAgICAgICAgICAgICB0ZXh0OiAnQWRkIFBsdWdpbicsXG4gICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICB9KTtcblxuICAgICAgICAgICAgY29uc3QgbmV3RGl2ID0gZm9ybUVsLmNyZWF0ZURpdigpO1xuICAgICAgICAgICAgbmV3RGl2LnN0eWxlLmJvcmRlclRvcCA9IFwiMXB4IHNvbGlkICNjY2NcIjtcbiAgICAgICAgICAgIG5ld0Rpdi5zdHlsZS5tYXJnaW5Ub3AgPSBcIjMwcHhcIjtcbiAgICAgICAgICAgIGNvbnN0IGJ5VGZUaGFja2VyID0gbmV3RGl2LmNyZWF0ZVNwYW4oKTtcbiAgICAgICAgICAgIGJ5VGZUaGFja2VyLmlubmVySFRNTCA9IFwiQlJBVCBieSA8YSBocmVmPSdodHRwczovL2JpdC5seS9vNDItdHdpdHRlcic+VEZUSGFja2VyPC9hPlwiO1xuICAgICAgICAgICAgYnlUZlRoYWNrZXIuc3R5bGUuZm9udFN0eWxlID0gXCJpdGFsaWNcIjtcbiAgICAgICAgICAgIG5ld0Rpdi5hcHBlbmRDaGlsZChieVRmVGhhY2tlcik7XG4gICAgICAgICAgICBwcm9tb3Rpb25hbExpbmtzKG5ld0RpdiwgZmFsc2UpO1xuXG4gICAgICAgICAgICB3aW5kb3cuc2V0VGltZW91dCgoKSA9PiB7XG4gICAgICAgICAgICAgICAgY29uc3QgdGl0bGUgPSBmb3JtRWwucXVlcnlTZWxlY3RvckFsbChcIi5icmF0LW1vZGFsIC5zZXR0aW5nLWl0ZW0taW5mb1wiKTtcbiAgICAgICAgICAgICAgICB0aXRsZS5mb3JFYWNoKCh0aXRsZUVsKSA9PiB7XG4gICAgICAgICAgICAgICAgICAgIHRpdGxlRWwucmVtb3ZlKCk7XG4gICAgICAgICAgICAgICAgfSlcbiAgICAgICAgICAgIH0sIDUwKVxuXG5cbiAgICAgICAgICAgIC8vIGludm9rZWQgd2hlbiBidXR0b24gaXMgY2xpY2tlZC4gXG4gICAgICAgICAgICBmb3JtRWwuYWRkRXZlbnRMaXN0ZW5lcignc3VibWl0JywgYXN5bmMgKGU6IEV2ZW50KSA9PiB7XG4gICAgICAgICAgICAgICAgZS5wcmV2ZW50RGVmYXVsdCgpO1xuICAgICAgICAgICAgICAgIGlmICh0aGlzLmFkZHJlc3MgIT09ICcnKSB7XG4gICAgICAgICAgICAgICAgICAgIGlmIChcbiAgICAgICAgICAgICAgICAgICAgICAgICh0aGlzLnVzZUZyb3plblZlcnNpb24gJiYgdGhpcy52ZXJzaW9uICE9PSBcIlwiKSBcbiAgICAgICAgICAgICAgICAgICAgICAgIHx8ICghdGhpcy51c2VGcm96ZW5WZXJzaW9uKVxuICAgICAgICAgICAgICAgICAgICApIHtcbiAgICAgICAgICAgICAgICAgICAgICAgIGF3YWl0IHRoaXMuc3VibWl0Rm9ybSgpO1xuICAgICAgICAgICAgICAgICAgICB9XG4gICAgICAgICAgICAgICAgfVxuICAgICAgICAgICAgfSk7XG4gICAgICAgIH0pO1xuICAgIH1cbiAgICBcbiAgICBhc3luYyBvbkNsb3NlKCk6IFByb21pc2U8dm9pZD4ge1xuICAgICAgICBpZih0aGlzLm9wZW5TZXR0aW5nc1RhYkFmdGVyd2FyZHMpIHtcbiAgICAgIC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Nob3dJblJpYmJvbjogdHJ1ZSxcbiAgICAgICAgICAgIGNhbGxiYWNrOiBhc3luYyAoKSA9PiB7XG4gICAgICAgICAgICAgICAgY29uc3QgcGx1Z2luU3ViTGlzdEZyb3plblZlcnNpb25OYW1lcyA9IFxuICAgICAgICAgICAgICAgICAgICBuZXcgU2V0KHRoaXMucGx1Z2luLnNldHRpbmdzLnBsdWdpblN1Ykxpc3RGcm96ZW5WZXJzaW9uLm1hcChmID0+IGYucmVwbykpO1xuICAgICAgICAgICAgICAgIGNvbnN0IHBsdWdpbkxpc3Q6IFN1Z2dlc3Rlckl0ZW1bXSA9IFxuICAgICAgICAgICAgICAgICAgICBPYmplY3RcbiAgICAgICAgICAgICAgICAgICAgICAgIC52YWx1ZXModGhpcy5wbHVnaW4uc2V0dGluZ3MucGx1Z2luTGlzdClcbiAgICAgICAgICAgICAgICAgICAgICAgIC5maWx0ZXIoKGYpID0+ICFwbHVnaW5TdWJMaXN0RnJvemVuVmVyc2lvbk5hbWVzLmhhcyhmKSlcbiAgICAgICAgICAgICAgICAgICAgICAgIC5tYXAoKG0pID0+IHsgcmV0dXJuIHsgZGlzcGxheTogbSwgaW5mbzogbSB9IH0pO1xuICAgICAgICAgICAgICAgIGNvbnN0IGdmcyA9IG5ldyBHZW5lcmljRnV6enlTdWdnZXN0ZXIodGhpcy5wbHVnaW4pO1xuICAgICAgICAgICAgICAgIGdmcy5zZXRTdWdnZXN0ZXJEYXRhKHBsdWdpbkxpc3QpO1xuICAgICAgICAgICAgICAgIGF3YWl0IGdmcy5kaXNwbGF5KGFzeW5jIChyZXN1bHRzKSA9PiB7XG4gICAgICAgICAgICAgICAgICAgIGNvbnN0IG1zZyA9IGBDaGVja2luZyBmb3IgdXBkYXRlcyBmb3IgJHtyZXN1bHRzLmluZm99YDtcbiAgICAgICAgICAgICAgICAgICAgdGhpcy5wbHVnaW4ubG9nKG1zZyx0cnVlKTtcbiAgICAgICAgICAgICAgICAgICAgVG9hc3RNZXNzYWdlK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tbXVuaXR5VGhlbWVMaXN0OiBTdWdnZXN0ZXJJdGVtW10gPSBPYmplY3QudmFsdWVzKGNvbW11bml0eVRoZW1lKS5tYXAoKHApID0+IHsgcmV0dXJuIHsgZGlzcGxheTogYFRoZW1lOiAke3AubmFtZX0gICgke3AucmVwb30pYCwgaW5mbzogcC5yZXBvIH0gfSk7XG4gICAgICAgICAgICAgICAgY29uc3QgZ2ZzID0gbmV3IEdlbmVyaWNGdXp6eVN1Z2dlc3Rlcih0aGlzLnBsdWdpbik7XG4gICAgICAgICAgICAgICAgZ2ZzLnNldFN1Z2dlc3RlckRhdGEoY29tbXVuaXR5VGhlbWVMaXN0KTtcbiAgICAgICAgICAgICAgICBhd2FpdCBnZnMuZGlzcGxheShhc3luYyAocmVzdWx0cykgPT4ge1xuICAgICAgICAgICAgICAgICAgICBpZiAocmVzdWx0cy5pbmZvKSB3aW5kb3cub3BlbihgaHR0cHM6Ly9naXRodWIuY29tLyR7cmVzdWx0cy5pbmZvfWApXG4gICAgICAgICAgICAgICAgfSk7XG4gICAgICAgICAgICB9XG4gICAgICAgIH0sXG4gICAgICAgIHtcbiAgICAgICAgICAgIGlkOiBcIkJSQVQtb3BlbnRQbHVnaW5TZXR0aW5nc1wiLFxuICAgICAgICAgICAgaWNvbjogXCJCcmF0SWNvblwiLFxuICAgICAgICAgICAgbmFtZTogXCJQbHVnaW5zOiBPcGVuIFBsdWdpbiBTZXR0aW5ncyBUYWJcIixcbiAgICAgICAgICAgIHNob3dJblJpYmJvbjogdHJ1ZSxcbiAgICAgICAgICAgIGNhbGxiYWNrOiBhc3luYyAoKSA9PiB7XG4gICAgICAgICAgICAgICAgLy8gQHRzLWlnbm9yZVxuICAgICAgICAgICAgICAgIGNvbnN0IHNldHRpbmdzID0gdGhpcy5wbHVnaW4uYXBwLnNldHRpbmc7XG4gICAgICAgICAgICAgICAgLy8gQHRzLWlnbm9yZVxuICAgICAgICAgICAgICAgIGNvbnN0IGxpc3RPZlBsdWdpblNldHRp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ixcbiAgICAgICAgICAgIG5hbWU6IFwiVGhlbWVzOiBHcmFiIGEgYmV0YSB0aGVtZSBmb3IgdGVzdGluZyBmcm9tIGEgR2l0aHViIHJlcG9zaXRvcnlcIixcbiAgICAgICAgICAgIHNob3dJblJpYmJvbjogdHJ1ZSxcbiAgICAgICAgICAgIGNhbGxiYWNrOiBhc3luYyAoKSA9PiB7IChuZXcgQWRkTmV3VGhlbWUodGhpcy5wbHVnaW4pKS5vcGVuKCkgfVxuICAgICAgICB9LFxuICAgICAgICB7XG4gICAgICAgICAgICBpZDogXCJCUkFULXVwZGF0ZUJldGFUaGVtZXNcIixcbiAgICAgICAgICAgIGljb246IFwiQnJhdEljb25cIixcbiAgICAgICAgICAgIG5hbWU6IFwiVGhlbWVzOiBVcGRhdGUgYmV0YSB0aGVtZXNcIixcbiAgICAgICAgICAgIHNob3dJblJpYmJvbjogdHJ1ZSxcbiAgICAgICAgICAgIGNhbGxiYWNrOiBhc3luYyAoKSA9PiBhd2FpdCB0aGVtZXNDaGVja0FuZFVwZGF0ZXModGhpcy5wbHVnaW4sIHRydWUpIFxuICAgICAgICB9LCAgICAgICAgXG4gICAgICAgIHtcbiAgICAgICAgICAgIGlkOiBcIkJSQVQtYWxsQ29tbWFuZHNcIixcbiAgICAgICAgICAgIGljb246IFwiQnJhdEljb25cIixcbiAgICAgICAgICAgIG5hbWU6IFwiQWxsIENvbW1hbmRzIGxpc3RcIixcbiAgICAgICAgICAgIHNob3dJblJpYmJvbjogZmFsc2UsXG4gICAgICAgICAgICBjYWxsYmFjazogYXN5bmMgKCkgPT4gdGhpcy5yaWJib25EaXNwbGF5Q29tbWFuZHMoKVxuICAgICAgICB9LFxuICAgIF1cblxuICAgIGFzeW5jIHJpYmJvbkRpc3BsYXlDb21tYW5kcygpOiBQcm9taXNlPHZvaWQ+IHtcbiAgICAgICAgY29uc3QgYnJhdENvbW1hbmRMaXN0OiBTdWdnZXN0ZXJJdGVtW10gPSBbXTtcbiAgICAgICAgdGhp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