From 700d576ff88f470c3d631eb05dee69abbfa3277f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Malte=20J=C3=BCrgens?= Date: Sat, 18 Feb 2023 15:46:56 +0100 Subject: [PATCH] update vencord --- assets/vencord/settings.patch | 61 ++--- assets/vencord/vencord.js | 423 ++++++++++++++++++++++++++++++++-- 2 files changed, 415 insertions(+), 69 deletions(-) diff --git a/assets/vencord/settings.patch b/assets/vencord/settings.patch index 7ed2035..345eedc 100644 --- a/assets/vencord/settings.patch +++ b/assets/vencord/settings.patch @@ -1,46 +1,15 @@ -diff --git a/src/components/Settings.tsx b/src/components/Settings.tsx -index 8ffe111..8f037bd 100644 ---- a/src/components/Settings.tsx -+++ b/src/components/Settings.tsx -@@ -61,37 +61,22 @@ export default ErrorBoundary.wrap(function Settings() { - Settings Directory: {settingsDir} - - -- {!IS_WEB && -+ - -- - -- } -- -- {IS_WEB && } -+ - - - + {IS_WEB ? ( + + ) : ( + diff --git a/assets/vencord/vencord.js b/assets/vencord/vencord.js index bf67aea..b364160 100644 --- a/assets/vencord/vencord.js +++ b/assets/vencord/vencord.js @@ -1,33 +1,410 @@ -"use strict";var Vencord=(()=>{var Xi=Object.create;var tt=Object.defineProperty;var Ji=Object.getOwnPropertyDescriptor;var Zi=Object.getOwnPropertyNames;var es=Object.getPrototypeOf,ts=Object.prototype.hasOwnProperty;var ns=(e=>typeof require!="undefined"?require:typeof Proxy!="undefined"?new Proxy(e,{get:(t,n)=>(typeof require!="undefined"?require:t)[n]}):e)(function(e){if(typeof require!="undefined")return require.apply(this,arguments);throw new Error('Dynamic require of "'+e+'" is not supported')});var a=(e,t)=>()=>(e&&(t=e(e=0)),t);var D=(e,t)=>{for(var n in t)tt(e,n,{get:t[n],enumerable:!0})},Lo=(e,t,n,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of Zi(t))!ts.call(e,r)&&r!==n&&tt(e,r,{get:()=>t[r],enumerable:!(o=Ji(t,r))||o.enumerable});return e};var os=(e,t,n)=>(n=e!=null?Xi(es(e)):{},Lo(t||!e||!e.__esModule?tt(n,"default",{value:e,enumerable:!0}):n,e)),rs=e=>Lo(tt({},"__esModule",{value:!0}),e);function he(e){let t=te(e);return new Proxy(ss,{get:(n,o)=>t()[o],set:(n,o,r)=>t()[o]=r,has:(n,o)=>o in t(),apply:(n,o,r)=>t().apply(o,r),ownKeys:()=>Reflect.ownKeys(t()),construct:(n,o)=>Reflect.construct(t(),o),deleteProperty:(n,o)=>delete t()[o],defineProperty:(n,o,r)=>!!Object.defineProperty(t(),o,r),getPrototypeOf:()=>Object.getPrototypeOf(t())})}var ss,ot=a(()=>{"use strict";O();ss=function(){}});function Mt(e){if(ye!==void 0)throw"no.";le=e.push([[Symbol()],{},t=>t]),ye=le.c,e.pop()}function X(e,t=!0){if(typeof e!="function")throw new Error("Invalid filter. Expected a function got "+typeof e);for(let n in ye){let o=ye[n];if(!!o?.exports){if(e(o.exports))return o.exports;if(typeof o.exports=="object"){if(o.exports.default&&e(o.exports.default))return t?o.exports.default:o.exports;for(let r in o.exports)if(r.length<=3){let i=o.exports[r];if(i&&e(i))return i}}}}return null}function Vo(e,t=!0){if(typeof e!="function")throw new Error("Invalid filter. Expected a function got "+typeof e);let n=[];for(let o in ye){let r=ye[o];if(!!r?.exports){if(e(r.exports))n.push(r.exports);else if(typeof r.exports!="object")continue;if(r.exports.default&&e(r.exports.default))n.push(t?r.exports.default:r.exports);else for(let i in r.exports)if(i.length<=3){let l=r.exports[i];l&&e(l)&&n.push(l)}}}return n}function $o(e,t){let n={};for(let o in le.m)if(le.m[o].toString().includes(e)){let i=le(o);e:for(let l in i){let m=i[l];for(let g in t)if(t[g](m)){n[g]=m;continue e}}break}return n}function Ne(e,t){return he(()=>$o(e,t))}function be(...e){return X(h.byProps(e))}function as(...e){return Vo(h.byProps(e))}function cs(e){return X(h.byDisplayName(e))}function k(e,t){if(typeof e=="string")e=h.byProps([e]);else if(Array.isArray(e))e=h.byProps(e);else if(typeof e!="function")throw new Error("filter must be a string, string[] or function, got "+typeof e);let n=X(e);if(n)return void t(n);Bo.set(e,t)}function ls(e){It.add(e)}function ds(e){It.delete(e)}function ps(...e){let t={},n=le.m;e:for(let o in n){let r=n[o].original??n[o],i=r.toString();for(let l of e)if(typeof l=="string"&&!i.includes(l)||l instanceof RegExp&&!l.test(i))continue e;t[o]=r}return t}function ms(e){let t=le.m[e];if(!t)return null;let n=` +// Vencord 62b2ace +// Standalone: false +// Platform: linux +"use strict";var Vencord=(()=>{var ym=Object.create;var Fn=Object.defineProperty;var vm=Object.getOwnPropertyDescriptor;var bm=Object.getOwnPropertyNames;var Sm=Object.getPrototypeOf,xm=Object.prototype.hasOwnProperty;var Tm=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,n)=>(typeof require<"u"?require:t)[n]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw new Error('Dynamic require of "'+e+'" is not supported')});var m=(e,t)=>()=>(e&&(t=e(e=0)),t);var Qt=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),ee=(e,t)=>{for(var n in t)Fn(e,n,{get:t[n],enumerable:!0})},Ma=(e,t,n,r)=>{if(t&&typeof t=="object"||typeof t=="function")for(let s of bm(t))!xm.call(e,s)&&s!==n&&Fn(e,s,{get:()=>t[s],enumerable:!(r=vm(t,s))||r.enumerable});return e};var Ra=(e,t,n)=>(n=e!=null?ym(Sm(e)):{},Ma(t||!e||!e.__esModule?Fn(n,"default",{value:e,enumerable:!0}):n,e)),Ao=e=>Ma(Fn({},"__esModule",{value:!0}),e);var l,o,i=m(()=>{"use strict";l=Symbol.for("react.fragment"),o=(...e)=>(o=Vencord.Webpack.Common.React.createElement)(...e)});function Pm(e){let t={};for(let n in e)t[n]=e[n],t[e[n]]=n;return Object.freeze(t)}var j,ze=m(()=>{"use strict";i();j=Pm({QUICK_CSS_UPDATE:"VencordQuickCssUpdate",GET_QUICK_CSS:"VencordGetQuickCss",SET_QUICK_CSS:"VencordSetQuickCss",GET_SETTINGS_DIR:"VencordGetSettingsDir",GET_SETTINGS:"VencordGetSettings",SET_SETTINGS:"VencordSetSettings",OPEN_EXTERNAL:"VencordOpenExternal",OPEN_QUICKCSS:"VencordOpenQuickCss",GET_UPDATES:"VencordGetUpdates",GET_REPO:"VencordGetRepo",GET_HASHES:"VencordGetHashes",UPDATE:"VencordUpdate",BUILD:"VencordBuild",GET_DESKTOP_CAPTURE_SOURCES:"VencordGetDesktopCaptureSources",OPEN_MONACO_EDITOR:"VencordOpenMonacoEditor"})});var N,le=m(()=>{"use strict";i();N=class{constructor(t,n="white"){this.name=t;this.color=n}static makeTitle(t,n){return["%c %c %s ","",`background: ${t}; color: black; font-weight: bold; border-radius: 5px;`,n]}_log(t,n,r,s=""){console[t](`%c Vencord %c %c ${this.name} ${s}`,`background: ${n}; color: black; font-weight: bold; border-radius: 5px;`,"",`background: ${this.color}; color: black; font-weight: bold; border-radius: 5px;`,...r)}log(...t){this._log("log","#a6d189",t)}info(...t){this._log("info","#a6d189",t)}error(...t){this._log("error","#e78284",t)}errorCustomFmt(t,...n){this._log("error","#e78284",n,t)}warn(...t){this._log("warn","#e5c890",t)}debug(...t){this._log("debug","#eebebe",t)}}});function We(e){let t=function(){};return t.cachedValue=void 0,t.get=()=>t.cachedValue??=e(),new Proxy(t,Nn)}var Aa,Nn,Et=m(()=>{"use strict";i();Aa=["arguments","caller","prototype"],Nn={};for(let e of["apply","construct","defineProperty","deleteProperty","get","getOwnPropertyDescriptor","getPrototypeOf","has","isExtensible","ownKeys","preventExtensions","set","setPrototypeOf"])Nn[e]=(t,...n)=>Reflect[e](t.get(),...n);Nn.ownKeys=e=>{let t=e.get(),n=Reflect.ownKeys(t);for(let r of Aa)n.includes(r)||n.push(r);return n};Nn.getOwnPropertyDescriptor=(e,t)=>typeof t=="string"&&Aa.includes(t)?Reflect.getOwnPropertyDescriptor(e,t):Reflect.getOwnPropertyDescriptor(e.get(),t)});var km,Ve,_o=m(()=>{"use strict";i();le();km=(e,t,n)=>t,Ve=km});function Do(e){if(et!==void 0)throw"no.";st=e.push([[Symbol("Vencord")],{},t=>t]),et=st.c,e.pop()}function Ae(e,t=!0){return We(()=>Ce(e,t))}function La(e,t=!0){if(typeof e!="function")throw new Error("Invalid filter. Expected a function got "+typeof e);let n=[];for(let r in et){let s=et[r];if(!!s?.exports){if(e(s.exports))n.push(s.exports);else if(typeof s.exports!="object")continue;if(s.exports.default&&e(s.exports.default))n.push(t?s.exports.default:s.exports);else for(let a in s.exports)if(a.length<=3){let c=s.exports[a];c&&e(c)&&n.push(c)}}}return n}function Me(e,t){return We(()=>Bn(e,t))}function _e(...e){return Ce(E.byProps(...e))}function M(...e){return Ae(E.byProps(...e))}function Im(...e){return La(E.byProps(...e))}function xe(...e){return Ce(E.byCode(...e))}function re(...e){return Ae(E.byCode(...e))}function $(e,t){if(typeof e=="string")e=E.byProps(e);else if(Array.isArray(e))e=E.byProps(...e);else if(typeof e!="function")throw new Error("filter must be a string, string[] or function, got "+typeof e);let n=Ce(e,!0,!0);if(n)return void t(n);_a.set(e,t)}function Mm(e){Fo.add(e)}function Rm(e){Fo.delete(e)}function Oo(...e){let t={},n=st.m;e:for(let r in n){let s=n[r].original??n[r],a=s.toString();for(let c of e)if(typeof c=="string"&&!a.includes(c)||c instanceof RegExp&&!c.test(a))continue e;t[r]=s}return t}function Cm(e){let t=st.m[e];if(!t)return null;let n=` // [EXTRACTED] WebpackModule${e} // WARNING: This module was extracted to be more easily readable. // This module is NOT ACTUALLY USED! This means putting breakpoints will have NO EFFECT!! ${t.toString()} //# sourceURL=ExtractedWebpackModule${e} -`;return(0,eval)(n)}var rt,kt,le,ye,h,Bo,It,it=a(()=>{"use strict";ot();kt=new Promise(e=>rt=e),h={byProps:e=>e.length===1?t=>t[e[0]]!==void 0:t=>e.every(n=>t[n]!==void 0),byDisplayName:e=>t=>t.default?.displayName===e,byCode:(...e)=>t=>{if(typeof t!="function")return!1;let n=Function.prototype.toString.call(t);for(let o of e)if(!n.includes(o))return!1;return!0}},Bo=new Map,It=new Set});var At={};D(At,{Alerts:()=>Ee,Button:()=>M,Card:()=>ze,ChannelStore:()=>De,Clipboard:()=>gs,FluxDispatcher:()=>I,Forms:()=>u,GuildStore:()=>st,Margins:()=>$,Parser:()=>xe,React:()=>f,Router:()=>Go,Select:()=>We,SelectedChannelStore:()=>G,Slider:()=>_t,Switch:()=>at,Text:()=>ne,TextInput:()=>de,Toasts:()=>B,Tooltip:()=>Se,UserStore:()=>F,UserUtils:()=>Ft});var $,I,f,st,F,G,De,u,ze,M,at,Se,Go,de,ne,We,_t,xe,Ee,us,fs,B,Ft,gs,v=a(()=>{"use strict";O();it();$=C(h.byProps(["marginTop20"])),u={},We=C(h.byCode("optionClassName","popoutPosition","autoFocus","maxVisibleItems")),_t=C(h.byCode("closestMarkerIndex","stickToMarkers")),us={MESSAGE:0,SUCCESS:1,FAILURE:2,CUSTOM:3},fs={TOP:0,BOTTOM:1},B={Type:us,Position:fs,genId:()=>(Math.random()||Math.random()).toString(36).slice(2)},Ft={fetchUser:C(h.byCode(".USER(","getUser"))},gs=Ne('document.queryCommandEnabled("copy")||document.queryCommandSupported("copy")',{copy:h.byCode(".default.copy("),SUPPORTS_COPY:e=>typeof e=="boolean"});k("useState",e=>f=e);k(["dispatch","subscribe"],e=>{I=e;let t=()=>{e.unsubscribe("CONNECTION_OPEN",t),rt()};e.subscribe("CONNECTION_OPEN",t)});k(["getCurrentUser","initialize"],e=>F=e);k("getSortedPrivateChannels",e=>De=e);k("getCurrentlySelectedChannelId",e=>G=e);k("getGuildCount",e=>st=e);k(["Hovers","Looks","Sizes"],e=>M=e);k(h.byCode("helpdeskArticleId"),e=>at=e);k(["Positions","Colors"],e=>Se=e);k(e=>e.Types?.PRIMARY==="cardPrimary",e=>ze=e);k(e=>e.Tags&&h.byCode("errorSeparator")(e),e=>u.FormTitle=e);k(e=>e.Tags&&h.byCode("titleClassName","sectionTitle")(e),e=>u.FormSection=e);k(e=>e.Types?.INPUT_PLACEHOLDER,e=>u.FormText=e);k(e=>{if(typeof e!="function")return!1;let t=e.toString();return t.length<200&&t.includes("divider")},e=>u.FormDivider=e);k(h.byCode("currentToast?"),e=>B.show=e);k(h.byCode("currentToast:null"),e=>B.pop=e);k(["show","close"],e=>Ee=e);k("parseTopic",e=>xe=e);k(["open","saveAccountChanges"],e=>Go=e);k(["defaultProps","Sizes","contextType"],e=>de=e);k(e=>{if(typeof e!="function")return!1;let t=e.toString();return t.length<1500&&t.includes("data-text-variant")&&t.includes("always-white")},e=>ne=e)});var Nt={};D(Nt,{Common:()=>At,_initWebpack:()=>Mt,_resolveReady:()=>rt,addListener:()=>ls,cache:()=>ye,extract:()=>ms,filters:()=>h,find:()=>X,findAll:()=>Vo,findAllByProps:()=>as,findByDisplayName:()=>cs,findByProps:()=>be,listeners:()=>It,mapMangledModule:()=>$o,mapMangledModuleLazy:()=>Ne,onceReady:()=>kt,removeListener:()=>ds,search:()=>ps,subscriptions:()=>Bo,waitFor:()=>k,wreq:()=>le});var A=a(()=>{"use strict";v();it()});function te(e){let t;return()=>t??(t=e())}function C(e){return he(()=>X(e))}function pe(e,t=null,n){let[o,r]=f.useState({value:t,error:null,pending:!0});return f.useEffect(()=>{let i=!0;return e().then(l=>i&&r({value:l,error:null,pending:!1})).catch(l=>i&&(r({value:null,error:l,pending:!1}),n?.(l))),()=>void(i=!1)},[]),[o.value,o.error,o.pending]}function ys(e){return t=>{let n=f.useMemo(e,[]);return Vencord.Webpack.Common.React.createElement(n,{...t})}}function Pe(e,t){for(let n in t){let o=t[n];typeof o=="object"&&!Array.isArray(o)?(e[n]??={},Pe(e[n],o)):e[n]??=o}return e}function bs(e,t=n=>n){let{length:n}=e;if(n===0)return"";if(n===1)return t(e[0]);let o="";for(let r=0;r2?o+=", ":n-r>1&&(o+=" and ");return o}function Te(...e){return e.join(" ")}function Dt(e){return new Promise(t=>setTimeout(t,e))}function Ss(e,t,n){return t.constructor.name==="AsyncFunction"?async function(){try{await t.apply(n??this,arguments)}catch(o){console.error(`Caught an Error in ${e||"anonymous"} -`,o)}}:function(){try{t.apply(n??this,arguments)}catch(o){console.error(`Caught an Error in ${e||"anonymous"} -`,o)}}}function Ot(e,t){let n="```";return`${n}${t||""} -${e} -${n}`}var hs,O=a(()=>{"use strict";A();v();ot();hs=te});function He(){return`-${jo.fromTimestamp(Date.now())}`}function oe(e,t){let n=xs({channelId:e,content:"",embeds:[]});return Es.receiveMessage(e,Pe(t,n)),t}function j(e,t,n){return e.find(o=>o.name===t)?.value||n}var xs,Es,jo,Lt=a(()=>{"use strict";O();A();xs=C(h.byCode('username:"Clyde"')),Es=C(h.byProps(["receiveMessage"]));k("fromTimestamp",e=>jo=e)});var ct,Oe,Ut,Bt=a(()=>{"use strict";ct=(s=>(s[s.SUB_COMMAND=1]="SUB_COMMAND",s[s.SUB_COMMAND_GROUP=2]="SUB_COMMAND_GROUP",s[s.STRING=3]="STRING",s[s.INTEGER=4]="INTEGER",s[s.BOOLEAN=5]="BOOLEAN",s[s.USER=6]="USER",s[s.CHANNEL=7]="CHANNEL",s[s.ROLE=8]="ROLE",s[s.MENTIONABLE=9]="MENTIONABLE",s[s.NUMBER=10]="NUMBER",s[s.ATTACHMENT=11]="ATTACHMENT",s))(ct||{}),Oe=(i=>(i[i.BUILT_IN=0]="BUILT_IN",i[i.BUILT_IN_TEXT=1]="BUILT_IN_TEXT",i[i.BUILT_IN_INTEGRATION=2]="BUILT_IN_INTEGRATION",i[i.BOT=3]="BOT",i[i.PLACEHOLDER=4]="PLACEHOLDER",i))(Oe||{}),Ut=(o=>(o[o.CHAT_INPUT=1]="CHAT_INPUT",o[o.USER=2]="USER",o[o.MESSAGE=3]="MESSAGE",o))(Ut||{})});var jt={};D(jt,{ApplicationCommandInputType:()=>Oe,ApplicationCommandOptionType:()=>ct,ApplicationCommandType:()=>Ut,BUILT_IN:()=>Ce,OptionalMessageOption:()=>Le,RequiredMessageOption:()=>ve,_handleCommand:()=>Ts,_init:()=>Ps,commands:()=>Vt,findOption:()=>j,generateId:()=>He,registerCommand:()=>$t,sendBotMessage:()=>oe,unregisterCommand:()=>Gt});function Ho(e){e.displayName||=e.name,e.displayDescription||=e.description,e.options?.forEach((t,n,o)=>{t===zo?o[n]=Le:t===Wo&&(o[n]=ve),t.choices?.forEach(r=>r.displayName||=r.name),Ho(o[n])})}function $t(e,t){if(!Ce){console.warn("[CommandsAPI]",`Not registering ${e.name} as the CommandsAPI hasn't been initialised.`,"Please restart to use commands");return}if(Ce.some(n=>n.name===e.name))throw new Error(`Command '${e.name}' already exists.`);e.isVencordCommand=!0,e.id??=He(),e.applicationId??="-1",e.type??=1,e.inputType??=1,e.plugin||=t,Ho(e),Vt[e.name]=e,Ce.push(e)}function Gt(e){let t=Ce.findIndex(n=>n.name===e);return t===-1?!1:(Ce.splice(t,1),delete Vt[e],!0)}var Ce,Vt,zo,Wo,Le,ve,Ps,Ts,re=a(()=>{"use strict";O();Lt();Bt();Lt();Bt();Vt={},zo=Symbol("OptionalMessageOption"),Wo=Symbol("RequiredMessageOption"),Le=zo,ve=Wo,Ps=function(e){try{Ce=e,Le=e.find(t=>t.name==="shrug").options[0],ve=e.find(t=>t.name==="me").options[0]}catch{console.error("Failed to load CommandsApi")}return e},Ts=function(e,t,n){if(!e.isVencordCommand)return e.execute(t,n);let o=r=>{let i=`An Error occurred while executing command "${e.name}"`,l=r instanceof Error?r.stack||r.message:String(r);console.error(i,r),oe(n.channel.id,{content:`${i}: -${Ot(l)}`,author:{username:"Vencord"}})};try{let r=e.execute(t,n);return r instanceof Promise?r.catch(o):r}catch(r){return o(r)}}});var Ht={};D(Ht,{clear:()=>_s,createStore:()=>Ko,del:()=>Is,delMany:()=>Ms,entries:()=>Ns,get:()=>Cs,getMany:()=>Rs,keys:()=>Fs,promisifyRequest:()=>L,set:()=>vs,setMany:()=>ws,update:()=>ks,values:()=>As});function L(e){return new Promise((t,n)=>{e.oncomplete=e.onsuccess=()=>t(e.result),e.onabort=e.onerror=()=>n(e.error)})}function Ko(e,t){let n=indexedDB.open(e);n.onupgradeneeded=()=>n.result.createObjectStore(t);let o=L(n);return(r,i)=>o.then(l=>i(l.transaction(t,r).objectStore(t)))}function z(){return zt||(zt=Ko("VencordData","VencordStore")),zt}function Cs(e,t=z()){return t("readonly",n=>L(n.get(e)))}function vs(e,t,n=z()){return n("readwrite",o=>(o.put(t,e),L(o.transaction)))}function ws(e,t=z()){return t("readwrite",n=>(e.forEach(o=>n.put(o[1],o[0])),L(n.transaction)))}function Rs(e,t=z()){return t("readonly",n=>Promise.all(e.map(o=>L(n.get(o)))))}function ks(e,t,n=z()){return n("readwrite",o=>new Promise((r,i)=>{o.get(e).onsuccess=function(){try{o.put(t(this.result),e),r(L(o.transaction))}catch(l){i(l)}}}))}function Is(e,t=z()){return t("readwrite",n=>(n.delete(e),L(n.transaction)))}function Ms(e,t=z()){return t("readwrite",n=>(e.forEach(o=>n.delete(o)),L(n.transaction)))}function _s(e=z()){return e("readwrite",t=>(t.clear(),L(t.transaction)))}function Wt(e,t){return e.openCursor().onsuccess=function(){!this.result||(t(this.result),this.result.continue())},L(e.transaction)}function Fs(e=z()){return e("readonly",t=>{if(t.getAllKeys)return L(t.getAllKeys());let n=[];return Wt(t,o=>n.push(o.key)).then(()=>n)})}function As(e=z()){return e("readonly",t=>{if(t.getAll)return L(t.getAll());let n=[];return Wt(t,o=>n.push(o.value)).then(()=>n)})}function Ns(e=z()){return e("readonly",t=>{if(t.getAll&&t.getAllKeys)return Promise.all([L(t.getAllKeys()),L(t.getAll())]).then(([o,r])=>o.map((i,l)=>[i,r[l]]));let n=[];return e("readonly",o=>Wt(o,r=>n.push([r.key,r.value])).then(()=>n))})}var zt,qo=a(()=>{"use strict";});var Kt={};D(Kt,{_modifyAccessories:()=>Ls,accessories:()=>lt,addAccessory:()=>Ds,removeAccessory:()=>Os});function Ds(e,t,n){lt.set(e,{callback:t,position:n})}function Os(e){lt.delete(e)}function Ls(e,t){for(let n of lt.values())e.splice(n.position!=null?n.position<0?e.length+n.position:n.position:e.length,0,n.callback(t));return e}var lt,Qo=a(()=>{"use strict";lt=new Map});var U,we=a(()=>{"use strict";U=class{constructor(t,n){this.name=t;this.color=n}_log(t,n,o){console[t](`%c Vencord %c %c ${this.name} `,`background: ${n}; color: black; font-weight: bold; border-radius: 5px;`,"",`background: ${this.color}; color: black; font-weight: bold; border-radius: 5px;`,...o)}log(...t){this._log("log","#a6d189",t)}info(...t){this._log("info","#a6d189",t)}error(...t){this._log("error","#e78284",t)}warn(...t){this._log("warn","#e5c890",t)}debug(...t){this._log("debug","#eebebe",t)}}});var tn={};D(tn,{_handleClick:()=>Vs,_handlePreEdit:()=>Bs,_handlePreSend:()=>Us,addClickListener:()=>Zt,addPreEditListener:()=>Re,addPreSendListener:()=>W,removeClickListener:()=>en,removePreEditListener:()=>ke,removePreSendListener:()=>H});function Us(e,t,n){for(let o of Yt)try{o(e,t,n)}catch(r){Qt.error(`MessageSendHandler: Listener encoutered an unknown error. (${r})`)}}function Bs(e,t,n){for(let o of Xt)try{o(e,t,n)}catch(r){Qt.error(`MessageEditHandler: Listener encoutered an unknown error. (${r})`)}}function W(e){return Yt.add(e),e}function Re(e){return Xt.add(e),e}function H(e){return Yt.delete(e)}function ke(e){return Xt.delete(e)}function Vs(e,t,n){for(let o of Jt)try{o(e,t,n)}catch(r){Qt.error(`MessageClickHandler: Listener encoutered an unknown error. (${r})`)}}function Zt(e){return Jt.add(e),e}function en(e){return Jt.delete(e)}var Qt,Yt,Xt,Jt,me=a(()=>{"use strict";we();Qt=new U("MessageEvents","#e5c890"),Yt=new Set,Xt=new Set;Jt=new Set});var rn={};D(rn,{currentNotice:()=>Ke,nextNotice:()=>Yo,noticesQueue:()=>on,popNotice:()=>$s,showNotice:()=>Gs});function $s(){nn.dismiss()}function Yo(){Ke=on.shift(),Ke&&nn.show(...Ke,"VencordNotice")}function Gs(e,t,n){on.push(["GENERIC",e,t,n]),Ke||Yo()}var nn,on,Ke,sn=a(()=>{"use strict";A();k(e=>e.show&&e.dismiss&&!e.suppressAll,e=>nn=e);on=[],Ke=null});var an={};D(an,{Commands:()=>Ws,DataStore:()=>Hs,MessageAccessories:()=>Ks,MessageEvents:()=>js,Notices:()=>zs});var js,zs,Ws,Hs,Ks,Xo=a(()=>{"use strict";re();qo();Qo();me();sn();js=tn,zs=rn,Ws=jt,Hs=Ht,Ks=Kt});var cn={};D(cn,{Devs:()=>d,REACT_GLOBAL:()=>qs,WEBPACK_CHUNK:()=>ie});var ie,qs,d,E=a(()=>{"use strict";ie="webpackChunkdiscord_app",qs="Vencord.Webpack.Common.React",d=Object.freeze({Ven:{name:"Vendicated",id:343383572805058560n},Arjix:{name:"ArjixWasTaken",id:674710789138939916n},Cyn:{name:"Cynosphere",id:150745989836308480n},Megu:{name:"Megumin",id:545581357812678656n},botato:{name:"botato",id:440990343899643943n},obscurity:{name:"obscurity",id:336678828233588736n},rushii:{name:"rushii",id:295190422244950017n},Glitch:{name:"Glitchy",id:269567451199569920n},Samu:{name:"Samu",id:702973430449832038n},Animal:{name:"Animal",id:118437263754395652n},MaiKokain:{name:"Mai",id:722647978577363026n},echo:{name:"ECHO",id:712639419785412668n},katlyn:{name:"katlyn",id:250322741406859265n},Nuckyz:{name:"Nuckyz",id:235834946571337729n}})});function c(e){return e}var y=a(()=>{"use strict"});var ln,Jo=a(()=>{"use strict";E();y();ln=c({name:"STFU",description:"Disables the 'HOLD UP' banner in the console",authors:[d.Ven],patches:[{find:"setDevtoolsCallbacks",replacement:{match:/if\(.{0,10}\|\|"0.0.0"!==.{0,2}\.remoteApp\.getVersion\(\)\)/,replace:"if(false)"}}]})});var dn,Zo=a(()=>{"use strict";E();y();K();dn=c({name:"AnonymiseFileNames",authors:[d.obscurity],description:"Anonymise uploaded file names",patches:[{find:"instantBatchUpload:function",replacement:{match:/uploadFiles:(.{1,2}),/,replace:"uploadFiles:(...args)=>(args[0].uploads.forEach(f=>f.filename=Vencord.Plugins.plugins.AnonymiseFileNames.anonymise(f.filename)),$1(...args)),"}}],options:{method:{description:"Anonymising method",type:4,options:[{label:"Random Characters",value:0,default:!0},{label:"Consistent",value:1},{label:"Timestamp (4chan-like)",value:2}]},randomisedLength:{description:"Random characters length",type:1,default:7,disabled:()=>P.plugins.AnonymiseFileNames.method!==0},consistent:{description:"Consistent filename",type:0,default:"image",disabled:()=>P.plugins.AnonymiseFileNames.method!==1}},anonymise(e){let t="image",n=e.match(/\..+$/g)?.[0]??"";switch(P.plugins.AnonymiseFileNames.method){case 0:let o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";t=Array.from({length:P.plugins.AnonymiseFileNames.randomisedLength},()=>o[Math.floor(Math.random()*o.length)]).join("");break;case 1:t=P.plugins.AnonymiseFileNames.consistent;break;case 2:t=`${Math.floor(Date.now()/1e3)}${Math.floor(window.performance.now())}`;break}return t+n}})});var pn,er=a(()=>{"use strict";E();y();pn=c({name:"CommandsAPI",authors:[d.Arjix],description:"Api required by anything that uses commands",patches:[{find:'"giphy","tenor"',replacement:[{match:/(?<=\w=)(\w)(\.filter\(.{0,30}giphy)/,replace:"Vencord.Api.Commands._init($1)$2"}]},{find:"Unexpected value for option",replacement:{match:/,(.{1,2})\.execute\((.{1,2}),(.{1,2})\)]/,replace:(e,t,n,o)=>`,Vencord.Api.Commands._handleCommand(${t}, ${n}, ${o})]`}}]})});var mn,tr=a(()=>{"use strict";E();y();mn=c({name:"MessageAccessoriesAPI",description:"API to add message accessories.",authors:[d.Cyn],patches:[{find:"_messageAttachmentToEmbedMedia",replacement:{match:/\(\)\.container\)},(.+?)\)};return/,replace:(e,t)=>`().container)},Vencord.Api.MessageAccessories._modifyAccessories([${t}],this.props))};return`}}]})});var un,nr=a(()=>{"use strict";E();y();un=c({name:"MessageEventsAPI",description:"Api required by anything using message events.",authors:[d.Arjix],patches:[{find:"sendMessage:function",replacement:[{match:/(?<=_sendMessage:function\([^)]+\)){/,replace:"{Vencord.Api.MessageEvents._handlePreSend(...arguments);"},{match:/(?<=\beditMessage:function\([^)]+\)){/,replace:"{Vencord.Api.MessageEvents._handlePreEdit(...arguments);"}]},{find:"if(e.altKey){",replacement:{match:/var \w=(\w)\.id,\w=(\w)\.id;return .{1,2}\.useCallback\(\(?function\((.{1,2})\){/,replace:(e,t,n,o)=>`var _msg=${t},_chan=${n};${e}Vencord.Api.MessageEvents._handleClick(_msg, _chan, ${o});`}}]})});var fn,or=a(()=>{"use strict";E();y();fn=c({name:"ApiNotices",description:"Fixes notices being automatically dismissed",authors:[d.Ven],required:!0,patches:[{find:"updateNotice:",replacement:[{match:/;(.{1,2}=null;)(?=.{0,50}updateNotice)/g,replace:";if(Vencord.Api.Notices.currentNotice)return !1;$1"},{match:/(?<=NOTICE_DISMISS:function.+?){(?=if\(null==(.+?)\))/,replace:'{if($1?.id=="VencordNotice")return ($1=null,Vencord.Api.Notices.nextNotice(),true);'}]}]})});var gn,rr=a(()=>{"use strict";E();y();gn=c({name:"BANger",description:"Replaces the GIF in the ban dialogue with a custom one.",authors:[{name:"Xinto",id:423915768191647755n},d.Glitch],patches:[{find:"BAN_CONFIRM_TITLE.",replacement:{match:/src:\w\(\d+\)/g,replace:"src: Vencord.Settings.plugins.BANger.source"}}],options:{source:{description:"Source to replace ban GIF with (Video or Gif)",type:0,default:"https://i.imgur.com/wp5q52C.mp4",restartNeeded:!0}}})});var hn,ir=a(()=>{"use strict";E();y();hn=c({name:"BetterGifAltText",authors:[d.Ven],description:"Change GIF alt text from simply being 'GIF' to containing the gif tags / filename",patches:[{find:"onCloseImage=",replacement:{match:/(return .{1,2}\.createElement.{0,50}isWindowFocused)/,replace:"Vencord.Plugins.plugins.BetterGifAltText.altify(e);$1"}},{find:'preload:"none","aria',replacement:{match:/\?.{0,5}\.Messages\.GIF/,replace:"?(e.alt='GIF',Vencord.Plugins.plugins.BetterGifAltText.altify(e))"}}],altify(e){if(e.alt!=="GIF")return e.alt;let t=e.original||e.src;try{t=decodeURI(t)}catch{}let n=t.slice(t.lastIndexOf("/")+1).replace(/\d/g,"").replace(/.gif$/,"").split(/[,\-_ ]+/g).slice(0,20).join(" ");return n.length>300&&(n=n.slice(0,300)+"..."),n&&(e.alt+=` - ${n}`),e.alt}})});var yn,sr=a(()=>{"use strict";E();y();yn=c({name:"BetterUploadButton",authors:[d.obscurity],description:"Upload with a single click, open menu with right click",patches:[{find:"Messages.CHAT_ATTACH_UPLOAD_OR_INVITE",replacement:{match:/CHAT_ATTACH_UPLOAD_OR_INVITE,onDoubleClick:([^,]+),onClick:([^,]+)}}/,replace:"CHAT_ATTACH_UPLOAD_OR_INVITE,onClick:$1,onContextMenu:$2}}"}}]})});var ar,cr=a(()=>{"use strict";ar=["action_object_map","action_type_map","action_ref_map","spm@*.aliexpress.com","scm@*.aliexpress.com","aff_platform","aff_trace_key","algo_expid@*.aliexpress.*","algo_pvid@*.aliexpress.*","btsid","ws_ab_test","pd_rd_*@amazon.*","_encoding@amazon.*","psc@amazon.*","tag@amazon.*","ref_@amazon.*","pf_rd_*@amazon.*","pf@amazon.*","crid@amazon.*","keywords@amazon.*","sprefix@amazon.*","sr@amazon.*","ie@amazon.*","node@amazon.*","qid@amazon.*","callback@bilibili.com","cvid@bing.com","form@bing.com","sk@bing.com","sp@bing.com","sc@bing.com","qs@bing.com","pq@bing.com","sc_cid","mkt_tok","trk","trkCampaign","ga_*","gclid","gclsrc","hmb_campaign","hmb_medium","hmb_source","spReportId","spJobID","spUserID","spMailingID","itm_*","s_cid","elqTrackId","elqTrack","assetType","assetId","recipientId","campaignId","siteId","mc_cid","mc_eid","pk_*","sc_campaign","sc_channel","sc_content","sc_medium","sc_outcome","sc_geo","sc_country","nr_email_referer","vero_conv","vero_id","yclid","_openstat","mbid","cmpid","cid","c_id","campaign_id","Campaign","hash@ebay.*","fb_action_ids","fb_action_types","fb_ref","fb_source","fbclid","refsrc@facebook.com","hrc@facebook.com","gs_l","gs_lcp@google.*","ved@google.*","ei@google.*","sei@google.*","gws_rd@google.*","gs_gbg@google.*","gs_mss@google.*","gs_rn@google.*","_hsenc","_hsmi","__hssc","__hstc","hsCtaTracking","source@sourceforge.net","position@sourceforge.net","t@*.twitter.com","s@*.twitter.com","ref_*@*.twitter.com","tt_medium","tt_content","lr@yandex.*","redircnt@yandex.*","feature@youtube.com","kw@youtube.com","wt_zmc","utm_source","utm_content","utm_medium","utm_campaign","utm_term","si@open.spotify.com"]});var lr,Qs,bn,dr=a(()=>{"use strict";me();y();cr();lr=/[\\^$.*+?()[\]{}|]/g,Qs=RegExp(lr.source),bn=c({name:"clearURLs",description:"Removes tracking garbage from URLs",authors:[{name:"adryd",id:0n}],dependencies:["MessageEventsAPI"],escapeRegExp(e){return e&&Qs.test(e)?e.replace(lr,"\\$&"):e||""},createRules(){let e=ar;this.universalRules=new Set,this.rulesByHost=new Map,this.hostRules=new Map;for(let t of e){let n=t.split("@"),o=new RegExp("^"+this.escapeRegExp(n[0]).replace(/\\\*/,".+?")+"$");if(!n[1]){this.universalRules.add(o);continue}let r=new RegExp("^(www\\.)?"+this.escapeRegExp(n[1]).replace(/\\\./,"\\.").replace(/^\\\*\\\./,"(.+?\\.)?").replace(/\\\*/,".+?")+"$"),i=r.toString();this.hostRules.set(i,r),this.rulesByHost.get(i)==null&&this.rulesByHost.set(i,new Set),this.rulesByHost.get(i).add(o)}},removeParam(e,t,n){(t===e||e instanceof RegExp&&e.test(t))&&n.delete(t)},replacer(e){try{var t=new URL(e)}catch{return e}return t.searchParams.entries().next().done?e:(this.universalRules.forEach(n=>{t.searchParams.forEach((o,r,i)=>{this.removeParam(n,r,i)})}),this.hostRules.forEach((n,o)=>{!n.test(t.hostname)||this.rulesByHost.get(o).forEach(r=>{t.searchParams.forEach((i,l,m)=>{this.removeParam(r,l,m)})})}),t.toString())},onSend(e){e.content.match(/http(s)?:\/\//)&&(e.content=e.content.replace(/(https?:\/\/[^\s<]+[^<.,:;"'>)|\]\s])/g,t=>this.replacer(t)))},start(){this.createRules(),this.preSend=W((e,t)=>this.onSend(t)),this.preEdit=Re((e,t,n)=>this.onSend(n))},stop(){H(this.preSend),ke(this.preEdit)}})});var Sn,pr=a(()=>{"use strict";E();y();v();Sn=c({name:"ClickableRoleDot",authors:[d.Ven],description:"Makes RoleDots (Accessibility Feature) copy colour to clipboard on click",patches:[{find:"M0 4C0 1.79086 1.79086 0 4 0H16C18.2091 0 20 1.79086 20 4V16C20 18.2091 18.2091 20 16 20H4C1.79086 20 0 18.2091 0 16V4Z",replacement:{match:/(viewBox:"0 0 20 20")/,replace:"$1,onClick:()=>Vencord.Plugins.plugins.ClickableRoleDot.copyToClipBoard(e.color)"}}],copyToClipBoard(e){navigator.clipboard.writeText(e).then(()=>this.notifySuccess)},notifySuccess(){B.show({message:"Copied to Clipboard!",type:B.Type.SUCCESS,id:B.genId(),options:{duration:1e3,position:B.Position.BOTTOM}})}})});var xn,En,mr=a(()=>{"use strict";E();y();xn=e=>()=>{throw new Error(`'${e}' is Discord Desktop only.`)},En=c({name:"ConsoleShortcuts",description:"Adds shorter Aliases for many things on the window. Run `shortcutList` for a list.",authors:[d.Ven],getShortcuts(){return{toClip:xn("toClip"),fromClip:xn("fromClip"),wp:Vencord.Webpack,wpc:Vencord.Webpack.wreq.c,wreq:Vencord.Webpack.wreq,wpsearch:Vencord.Webpack.search,wpex:Vencord.Webpack.extract,findByProps:Vencord.Webpack.findByProps,find:Vencord.Webpack.find,Plugins:Vencord.Plugins,React:Vencord.Webpack.Common.React,Settings:Vencord.Settings,Api:Vencord.Api,reload:()=>location.reload(),restart:xn("restart")}},start(){let e=this.getShortcuts();window.shortcutList=e;for(let[t,n]of Object.entries(e))window[t]=n},stop(){delete window.shortcutList;for(let e in this.getShortcuts())delete window[e]}})});var Pn,ur=a(()=>{"use strict";y();Pn=c({name:"discord-screenaudio",authors:[{name:"maltejur",id:205966226709676032n}],required:!0,description:"UI patches for discord-screenaudio.",patches:[]})});var Ie,dt=a(()=>{"use strict";Ie=class{set=new Set;get changeCount(){return this.set.size}get hasChanges(){return this.changeCount>0}handleChange(t){this.set.delete(t)||this.set.add(t)}getChanges(){return this.set.values()}map(t){return[...this.getChanges()].map(t)}}});function Tn(e,t=300){let n;return function(...o){clearTimeout(n),n=setTimeout(()=>{e(...o)},t)}}var fr=a(()=>{"use strict"});var Cn={};D(Cn,{getCurrentChannel:()=>gr,getCurrentGuild:()=>Ys});function gr(){return De.getChannel(G.getChannelId())}function Ys(){return st.getGuild(gr()?.guild_id)}var hr=a(()=>{"use strict";v()});function Xs(e){let t={};for(let n in e)t[n]=e[n],t[e[n]]=n;return Object.freeze(t)}var _,Ue=a(()=>{"use strict";_=Xs({QUICK_CSS_UPDATE:"VencordQuickCssUpdate",GET_QUICK_CSS:"VencordGetQuickCss",SET_QUICK_CSS:"VencordSetQuickCss",GET_SETTINGS_DIR:"VencordGetSettingsDir",GET_SETTINGS:"VencordGetSettings",SET_SETTINGS:"VencordSetSettings",OPEN_EXTERNAL:"VencordOpenExternal",OPEN_QUICKCSS:"VencordOpenQuickCss",GET_UPDATES:"VencordGetUpdates",GET_REPO:"VencordGetRepo",GET_HASHES:"VencordGetHashes",UPDATE:"VencordUpdate",BUILD:"VencordBuild",GET_DESKTOP_CAPTURE_SOURCES:"VencordGetDesktopCaptureSources",OPEN_MONACO_EDITOR:"VencordOpenMonacoEditor"})});var Qe={};D(Qe,{ModalCloseButton:()=>Js,ModalContent:()=>wn,ModalFooter:()=>Rn,ModalHeader:()=>vn,ModalRoot:()=>qe,ModalSize:()=>pt,Modals:()=>Be,closeModal:()=>ea,openModal:()=>In,openModalLazy:()=>Zs});function Zs(e,t){return kn.openModalLazy(e,t)}function In(e,t,n){return kn.openModal(e,t,n)}function ea(e,t){return kn.closeModal(e,t)}var pt,Be,qe,vn,wn,Rn,Js,kn,mt=a(()=>{"use strict";A();it();pt=(r=>(r.SMALL="small",r.MEDIUM="medium",r.LARGE="large",r.DYNAMIC="dynamic",r))(pt||{}),Be=Ne(".onAnimationEnd,",{ModalRoot:h.byCode("headerIdIsManaged:"),ModalHeader:h.byCode("children","separator","wrap","NO_WRAP","grow","shrink","id","header"),ModalContent:h.byCode("scrollerRef","content","className","children"),ModalFooter:h.byCode("HORIZONTAL_REVERSE","START","STRETCH","NO_WRAP","footerSeparator"),ModalCloseButton:h.byCode("closeWithCircleBackground","hideOnFullscreen")}),qe=e=>Vencord.Webpack.Common.React.createElement(Be.ModalRoot,{...e}),vn=e=>Vencord.Webpack.Common.React.createElement(Be.ModalHeader,{...e}),wn=e=>Vencord.Webpack.Common.React.createElement(Be.ModalContent,{...e}),Rn=e=>Vencord.Webpack.Common.React.createElement(Be.ModalFooter,{...e}),Js=e=>Vencord.Webpack.Common.React.createElement(Be.ModalCloseButton,{...e}),kn=Ne("onCloseRequest:null!=",{openModal:h.byCode("onCloseRequest:null!="),closeModal:h.byCode("onCloseCallback&&"),openModalLazy:e=>e?.length===1&&h.byCode(".apply(this,arguments)")(e)})});var Mn={};D(Mn,{ChangeList:()=>Ie,Constants:()=>cn,Discord:()=>Cn,IpcEvents:()=>_,LazyComponent:()=>ys,Logger:()=>U,Modals:()=>Qe,classes:()=>Te,debounce:()=>Tn,humanFriendlyJoin:()=>bs,lazy:()=>hs,lazyWebpack:()=>C,makeCodeblock:()=>Ot,makeLazy:()=>te,mergeDefaults:()=>Pe,proxyLazy:()=>he,sleep:()=>Dt,suppressErrors:()=>Ss,useAwaiter:()=>pe});var ue=a(()=>{"use strict";dt();E();fr();hr();Ue();we();O();mt();ot();});var _n,Fn,yr=a(()=>{"use strict";ue();E();y();K();A();v();_n=C(h.byProps(["key","removeBuildOverride"])),Fn=c({name:"Experiments",authors:[d.Megu,d.Ven,{name:"Nickyux",id:427146305651998721n},{name:"BanTheNons",id:460478012794863637n}],description:"Enable Access to Experiments in Discord!",patches:[{find:"Object.defineProperties(this,{isDeveloper",replacement:{match:/(?<={isDeveloper:\{[^}]+,get:function\(\)\{return )\w/,replace:"true"}},{find:'type:"user",revision',replacement:{match:/(\w)\|\|"CONNECTION_OPEN".+?;/g,replace:"$1=!0;"}},{find:".isStaff=function(){",predicate:()=>P.plugins.Experiments.enableIsStaff===!0,replacement:[{match:/return\s*(\w+)\.hasFlag\((.+?)\.STAFF\)}/,replace:"return Vencord.Webpack.Common.UserStore.getCurrentUser().id===$1.id||$1.hasFlag($2.STAFF)}"},{match:/hasFreePremium=function\(\){return this.isStaff\(\)\s*\|\|/,replace:"hasFreePremium=function(){return "}]}],options:{enableIsStaff:{description:"Enable isStaff (requires restart)",type:3,default:!1,restartNeeded:!0}},settingsAboutComponent:()=>{let e=navigator.platform.includes("Mac"),t=e?"cmd":"ctrl",n=e?"opt":"alt";return Vencord.Webpack.Common.React.createElement(f.Fragment,null,Vencord.Webpack.Common.React.createElement(u.FormTitle,{tag:"h3"},"More Information"),Vencord.Webpack.Common.React.createElement(u.FormText,{variant:"text-md/normal"},"You can enable client DevTools"," ",Vencord.Webpack.Common.React.createElement("kbd",{className:_n.key},t)," +"," ",Vencord.Webpack.Common.React.createElement("kbd",{className:_n.key},n)," +"," ",Vencord.Webpack.Common.React.createElement("kbd",{className:_n.key},"O")," ","after enabling ",Vencord.Webpack.Common.React.createElement("code",null,"isStaff")," below"),Vencord.Webpack.Common.React.createElement(u.FormText,null,"and then toggling ",Vencord.Webpack.Common.React.createElement("code",null,"Enable DevTools")," in the ",Vencord.Webpack.Common.React.createElement("code",null,"Developer Options")," tab in settings."))}})});function br({option:e,pluginSettings:t,id:n,onChange:o,onError:r}){let i=t[n]??e.default,[l,m]=f.useState(i??!1),[g,b]=f.useState(null);f.useEffect(()=>{r(g!==null)},[g]);let S=[{label:"Enabled",value:!0,default:i===!0},{label:"Disabled",value:!1,default:typeof i>"u"||i===!1}];function s(p){let T=(e.isValid&&e.isValid(p))??!0;typeof T=="string"?b(T):T?(b(null),m(p),o(p)):b("Invalid input provided.")}return Vencord.Webpack.Common.React.createElement(u.FormSection,null,Vencord.Webpack.Common.React.createElement(u.FormTitle,null,e.description),Vencord.Webpack.Common.React.createElement(We,{isDisabled:e.disabled?.()??!1,options:S,placeholder:e.placeholder??"Select an option",maxVisibleItems:5,closeOnSelect:!0,select:s,isSelected:p=>p===l,serialize:p=>String(p),...e.componentProps}),g&&Vencord.Webpack.Common.React.createElement(u.FormText,{style:{color:"var(--text-danger)"}},g))}var Sr=a(()=>{"use strict";v()});function xr({option:e,pluginSettings:t,id:n,onChange:o,onError:r}){function i(s){return e.type===2?BigInt(s):Number(s)}let[l,m]=f.useState(`${t[n]??e.default??0}`),[g,b]=f.useState(null);f.useEffect(()=>{r(g!==null)},[g]);function S(s){let p=(e.isValid&&e.isValid(s))??!0;typeof p=="string"?b(p):p?e.type===1&&BigInt(s)>=ta?(m(`${Number.MAX_SAFE_INTEGER}`),o(i(s))):(m(s),o(i(s))):b("Invalid input provided.")}return Vencord.Webpack.Common.React.createElement(u.FormSection,null,Vencord.Webpack.Common.React.createElement(u.FormTitle,null,e.description),Vencord.Webpack.Common.React.createElement(de,{type:"number",pattern:"-?[0-9]+",value:l,onChange:S,placeholder:e.placeholder??"Enter a number",disabled:e.disabled?.()??!1,...e.componentProps}),g&&Vencord.Webpack.Common.React.createElement(u.FormText,{style:{color:"var(--text-danger)"}},g))}var ta,Er=a(()=>{"use strict";y();v();ta=BigInt(Number.MAX_SAFE_INTEGER)});function Pr({option:e,pluginSettings:t,onChange:n,onError:o,id:r}){let i=t[r]??e.options?.find(s=>s.default)?.value,[l,m]=f.useState(i??null),[g,b]=f.useState(null);f.useEffect(()=>{o(g!==null)},[g]);function S(s){let p=(e.isValid&&e.isValid(s))??!0;typeof p=="string"?b(p):p?(m(s),n(s)):b("Invalid input provided.")}return Vencord.Webpack.Common.React.createElement(u.FormSection,null,Vencord.Webpack.Common.React.createElement(u.FormTitle,null,e.description),Vencord.Webpack.Common.React.createElement(We,{isDisabled:e.disabled?.()??!1,options:e.options,placeholder:e.placeholder??"Select an option",maxVisibleItems:5,closeOnSelect:!0,select:S,isSelected:s=>s===l,serialize:s=>String(s),...e.componentProps}),g&&Vencord.Webpack.Common.React.createElement(u.FormText,{style:{color:"var(--text-danger)"}},g))}var Tr=a(()=>{"use strict";v()});function ut(e,t,n=1){let o=[];for(let r=e;r<=t;r+=n)o.push(Math.round(r*100)/100);return o}function Cr({option:e,pluginSettings:t,id:n,onChange:o,onError:r}){let i=t[n]??e.default,[l,m]=f.useState(null);f.useEffect(()=>{r(l!==null)},[l]);function g(b){let S=(e.isValid&&e.isValid(b))??!0;typeof S=="string"?m(S):S?(m(null),o(b)):m("Invalid input provided.")}return Vencord.Webpack.Common.React.createElement(u.FormSection,null,Vencord.Webpack.Common.React.createElement(u.FormTitle,null,e.description),Vencord.Webpack.Common.React.createElement(_t,{disabled:e.disabled?.()??!1,markers:e.markers,minValue:e.markers[0],maxValue:e.markers[e.markers.length-1],initialValue:i,onValueChange:g,onValueRender:b=>String(b.toFixed(2)),stickToMarkers:e.stickToMarkers??!0,...e.componentProps}))}var An=a(()=>{"use strict";v()});function vr({option:e,pluginSettings:t,id:n,onChange:o,onError:r}){let[i,l]=f.useState(t[n]??e.default??null),[m,g]=f.useState(null);f.useEffect(()=>{r(m!==null)},[m]);function b(S){let s=(e.isValid&&e.isValid(S))??!0;typeof s=="string"?g(s):s?(l(S),o(S)):g("Invalid input provided.")}return Vencord.Webpack.Common.React.createElement(u.FormSection,null,Vencord.Webpack.Common.React.createElement(u.FormTitle,null,e.description),Vencord.Webpack.Common.React.createElement(de,{type:"text",value:i,onChange:b,placeholder:e.placeholder??"Enter a value",disabled:e.disabled?.()??!1,...e.componentProps}),m&&Vencord.Webpack.Common.React.createElement(u.FormText,{style:{color:"var(--text-danger)"}},m))}var wr=a(()=>{"use strict";v()});var Nn=a(()=>{"use strict";Sr();Er();Tr();An();wr()});var Dn,Rr=a(()=>{"use strict";re();Nn();E();y();K();Dn=c({name:"Fart2",authors:[d.Animal],description:"Enable farting v2, a slash command that allows you to perform or request that someone perform a little toot.",dependencies:["CommandsAPI"],commands:[{name:"fart",description:"A simple command in which you may either request that a user do a little toot for you, or conduct one yourself.",options:[{type:6,name:"user",description:"A Discord\u2122 user of which you would humbly request a toot from.",required:!1}],execute(e){let t=new Audio("https://raw.githubusercontent.com/ItzOnlyAnimal/AliuPlugins/main/fart.mp3");return t.volume=P.plugins.Fart2.volume,t.play(),{content:e[0]?`<@${e[0].value}> fart`:"fart"}}}],options:{volume:{description:"how loud you wanna fart (aka volume)",type:5,markers:ut(0,1,.1),default:.5,stickToMarkers:!1}}})});var na,On,kr=a(()=>{"use strict";me();E();y();na=/https?:\/\/twitter\.com(?=\/\w+?\/status\/)/g,On=c({name:"FxTwitter",description:"Uses FxTwitter to improve embeds from twitter on send",authors:[d.Samu],dependencies:["MessageEventsAPI"],addPrefix(e){e.content=e.content.replace(na,"https://fxtwitter.com")},start(){this.preSend=W((e,t)=>this.addPrefix(t))},stop(){H(this.preSend)}})});var Ln,Ir=a(()=>{"use strict";E();y();Ln=c({name:"iLoveSpam",description:"Do not hide messages from 'likely spammers'",authors:[d.botato,d.Animal],patches:[{find:"),{hasFlag:",replacement:{match:/(if\((.{1,2})<=1<<30\)return)/,replace:"if($2===(1<<20)){return false};$1"}}]})});var Un,Mr=a(()=>{"use strict";E();y();K();Un=c({name:"Ify",description:"Disables Spotify auto-pausing, allows activity to continue playing when idling and bypasses premium checks, allowing you to listen along with others.",authors:[d.Cyn,d.Nuckyz],patches:[{find:'dispatch({type:"SPOTIFY_PROFILE_UPDATE"',replacement:[{match:/(function\((.{1,2})\){)(.{1,6}dispatch\({type:"SPOTIFY_PROFILE_UPDATE")/,replace:(e,t,n,o)=>`${t}${n}.body.product="premium";${o}`}]},{find:'.displayName="SpotifyStore"',predicate:()=>P.plugins.Ify.noSpotifyAutoPause,replacement:{match:/function (.{1,2})\(\).{0,200}SPOTIFY_AUTO_PAUSED\);.{0,}}}}/,replace:"function $1(){}"}},{find:'.displayName="SpotifyStore"',predicate:()=>P.plugins.Ify.keepSpotifyActivityOnIdle,replacement:{match:/(shouldShowActivity=function\(\){.{1,50})&&!.{1,6}\.isIdle\(\)(.{0,}?})/,replace:(e,t,n)=>`${t}${n}`}}],options:{noSpotifyAutoPause:{description:"Disable Spotify auto-pause",type:3,default:!0,restartNeeded:!0},keepSpotifyActivityOnIdle:{description:"Keep Spotify activity playing when idling",type:3,default:!1,restartNeeded:!0}}})});function Lr(e,t){let n=e.findIndex(o=>o.id===t);return n===-1?n:e.length-n-1}function Ar({channelId:e,messageId:t,_isQuickEdit:n}){if(n)return;let o=F.getCurrentUser().id,r=Bn.getMessages(e)._array.filter(i=>i.author.id===o);gt=Lr(r,t)}function Nr({message:e,_isQuickReply:t}){t||(ft=Lr(Bn.getMessages(e.channel_id)._array,e.id))}function Dr(e){let t=e.key==="ArrowUp";!t&&e.key!=="ArrowDown"||!oa(e)||ra(e)||(e.shiftKey?sa(t):ia(t))}function Ur(e,t){let n=Bn.getMessages(G.getChannelId())._array;if(!t){let i=F.getCurrentUser().id;n=n.filter(l=>l.author.id===i)}let o=i=>e?Math.min(n.length-1,i+1):Math.max(-1,i-1),r;return t?ft=r=o(ft):gt=r=o(gt),r===-1?void 0:n[n.length-r-1]}function ia(e){let t=Ur(e,!0);if(!t)return void I.dispatch({type:"DELETE_PENDING_REPLY",channelId:G.getChannelId()});let n=De.getChannel(t.channel_id),o=F.getCurrentUser().id;I.dispatch({type:"CREATE_PENDING_REPLY",channel:n,message:t,shouldMention:!0,showMentionToggle:n.guild_id!==null&&t.author.id!==o,_isQuickReply:!0})}function sa(e){let t=Ur(e,!1);t?I.dispatch({type:"MESSAGE_START_EDIT",channelId:t.channel_id,messageId:t.id,content:t.content,_isQuickEdit:!0}):I.dispatch({type:"MESSAGE_END_EDIT",channelId:G.getChannelId()})}var Bn,Or,ft,gt,Vn,_r,Fr,oa,ra,Br=a(()=>{"use strict";E();O();y();A();v();Bn=C(h.byProps(["getRawMessages"])),Or=navigator.platform.includes("Mac"),ft=-1,gt=-1,Vn=c({name:"InteractionKeybinds",authors:[d.obscurity,d.Ven],description:"Reply to (ctrl + up/down) and edit (ctrl + shift + up/down) messages via keybinds",start(){I.subscribe("DELETE_PENDING_REPLY",_r),I.subscribe("MESSAGE_END_EDIT",Fr),I.subscribe("MESSAGE_START_EDIT",Ar),I.subscribe("CREATE_PENDING_REPLY",Nr),document.addEventListener("keydown",Dr)},stop(){I.unsubscribe("DELETE_PENDING_REPLY",_r),I.unsubscribe("MESSAGE_END_EDIT",Fr),I.unsubscribe("MESSAGE_START_EDIT",Ar),I.unsubscribe("CREATE_PENDING_REPLY",Nr),document.removeEventListener("keydown",Dr)}}),_r=()=>ft=-1,Fr=()=>gt=-1;oa=e=>Or?e.metaKey:e.ctrlKey,ra=e=>e.altKey||!Or&&e.metaKey});var $n,Vr,$r,Gn,Gr=a(()=>{"use strict";me();E();y();A();v();$n=!1,Vr=e=>e.key==="Backspace"&&($n=!0),$r=e=>e.key==="Backspace"&&($n=!1),Gn=c({name:"MessageQuickActions",description:"Quick Delete, Quick edit",authors:[d.Ven],dependencies:["MessageEventsAPI"],start(){let{deleteMessage:e,startEditMessage:t}=be("deleteMessage","startEditMessage"),{can:n}=be("can","initialize"),{MANAGE_MESSAGES:o}=X(i=>typeof i.MANAGE_MESSAGES=="bigint"),{isEditing:r}=be("isEditing","isEditingAny");document.addEventListener("keydown",Vr),document.addEventListener("keyup",$r),this.onClick=Zt((i,l,m)=>{let g=i.author.id===F.getCurrentUser().id;$n?(g||n(o,l))&&(e(l.id,i.id),m.preventDefault()):g&&m.detail>=2&&!r(l.id,i.id)&&(t(l.id,i.id,i.content),m.preventDefault())})},stop(){en(this.onClick),document.removeEventListener("keydown",Vr),document.removeEventListener("keyup",$r)}})});function aa(e){let t="";for(let n=0;n{"use strict";re();E();y();jn=c({name:"MoreCommands",description:"echo, lenny, mock",authors:[d.Arjix,d.echo,{name:"ICodeInAssembly",id:702973430449832038n}],dependencies:["CommandsAPI"],commands:[{name:"echo",description:"Sends a message as Clyde (locally)",options:[Le],inputType:3,execute:(e,t)=>{let n=j(e,"message","");oe(t.channel.id,{content:n})}},{name:"lenny",description:"Sends a lenny face",options:[Le],execute:e=>({content:j(e,"message","")+" ( \u0361\xB0 \u035C\u0296 \u0361\xB0)"})},{name:"mock",description:"mOcK PeOpLe",options:[ve],execute:e=>({content:aa(j(e,"message",""))})}]})});function la(e,t){let n=0,o=0;for(;(o=e.indexOf(t,o)+1)!==0;)n++;return n}function da(e,t){if(!t.global)throw new Error("pattern must be global");let n=0;for(;t.test(e);)n++;return n}function ma(e){let t=la(e,Wr)+da(e,pa);return Math.min(t,10)}function zr(){if(!P.plugins.Moyai.triggerWhenUnfocused&&!document.hasFocus())return;let e=document.createElement("audio");e.src=ca,e.volume=P.plugins.Moyai.volume,e.play()}var Wr,ca,zn,pa,Hr=a(()=>{"use strict";An();E();O();y();K();v();Wr="\u{1F5FF}",ca="https://raw.githubusercontent.com/MeguminSama/VencordPlugins/main/plugins/moyai/moyai.mp3",zn=c({name:"Moyai",authors:[d.Megu,d.Nuckyz],description:"\u{1F5FF}\u{1F5FF}\u{1F5FF}\u{1F5FF}\u{1F5FF}\u{1F5FF}\u{1F5FF}\u{1F5FF}",async onMessage(e){if(e.optimistic||e.type!=="MESSAGE_CREATE"||e.message.state==="SENDING"||P.plugins.Moyai.ignoreBots&&e.message.author?.bot||!e.message.content||e.channelId!==G.getChannelId())return;let t=ma(e.message.content);for(let n=0;n/gi});var Wn,Kr=a(()=>{"use strict";E();y();Wn=c({name:"MuteNewGuild",description:"Mutes newly joined guilds",authors:[d.Glitch],patches:[{find:",acceptInvite:function",replacement:{match:/(\w=null!==[^;]+)/,replace:"$1;Vencord.Webpack.findByProps('updateGuildNotificationSettings').updateGuildNotificationSettings($1,{'muted':true,'suppress_everyone':true,'suppress_roles':true})"}}]})});var Hn,qr=a(()=>{"use strict";me();E();y();K();A();v();Hn=c({name:"NitroBypass",authors:[d.Arjix],description:"Allows you to stream in nitro quality and send fake emojis.",dependencies:["MessageEventsAPI"],patches:[{find:"canUseAnimatedEmojis:function",predicate:()=>P.plugins.NitroBypass.enableEmojiBypass===!0,replacement:["canUseAnimatedEmojis","canUseEmojisEverywhere"].map(e=>({match:new RegExp(`${e}:function\\(.+?}`),replace:`${e}:function (e) { return true; }`}))},{find:"canUseAnimatedEmojis:function",predicate:()=>P.plugins.NitroBypass.enableStreamQualityBypass===!0,replacement:["canUseHighVideoUploadQuality","canStreamHighQuality","canStreamMidQuality"].map(e=>({match:new RegExp(`${e}:function\\(.+?}`),replace:`${e}:function (e) { return true; }`}))},{find:"STREAM_FPS_OPTION.format",predicate:()=>P.plugins.NitroBypass.enableStreamQualityBypass===!0,replacement:{match:/(userPremiumType|guildPremiumTier):.{0,10}TIER_\d,?/g,replace:""}}],options:{enableEmojiBypass:{description:"Allow sending fake emojis",type:3,default:!0,restartNeeded:!0},enableStreamQualityBypass:{description:"Allow streaming in nitro quality",type:3,default:!0,restartNeeded:!0}},get guildId(){return window.location.href.split("channels/")[1].split("/")[0]},get canUseEmotes(){return Boolean(F.getCurrentUser().premiumType)},start(){if(!P.plugins.NitroBypass.enableEmojiBypass)return;if(this.canUseEmotes){console.info("[NitroBypass] Skipping start because you have nitro");return}let{getCustomEmojiById:e}=be("getCustomEmojiById");function t(n,o){return!n[o]||/\s/.test(n[o])?"":" "}this.preSend=W((n,o)=>{let{guildId:r}=this;for(let i of o.validNonShortcutEmojis){if(!i.require_colons||i.guildId===r&&!i.animated)continue;let l=`<${i.animated?"a":""}:${i.originalName||i.name}:${i.id}>`,m=i.url.replace(/\?size=[0-9]+/,"?size=48");o.content=o.content.replace(l,(g,b,S)=>`${t(S,b-1)}${m}${t(S,b+g.length)}`)}}),this.preEdit=Re((n,o,r)=>{let{guildId:i}=this;for(let[l,m,g]of r.content.matchAll(/(?/ig)){let b=e(g);if(b==null||b.guildId===i&&!b.animated||!b.require_colons)continue;let S=b.url.replace(/\?size=[0-9]+/,"?size=48");r.content=r.content.replace(l,(s,p,T)=>`${t(T,p-1)}${S}${t(T,p+s.length)}`)}})},stop(){H(this.preSend),ke(this.preEdit)}})});var Kn,Qr=a(()=>{"use strict";E();y();Kn=c({name:"NoBlockedMessages",description:"Hides all blocked messages from chat completely.",authors:[d.rushii],patches:[{find:'safety_prompt:"DMSpamExperiment",response:"show_redacted_messages"',replacement:[{match:/collapsedReason;return (?=\w{1,2}.createElement)/,replace:"collapsedReason; return null;"}]}]})});var qn,Yr=a(()=>{"use strict";me();E();y();qn=c({name:"NoCanaryMessageLinks",description:"Removes the canary and ptb prefix from message links",authors:[d.Samu],dependencies:["MessageEventsAPI"],removeBetas(e){e.content=e.content.replace(/(?<=https:\/\/)(canary.|ptb.)(?=discord(?:app)?.com\/channels\/(?:\d{17,20}|@me)\/\d{17,20}\/\d{17,20})/g,"")},start(){this.preSend=W((e,t)=>this.removeBetas(t))},stop(){H(this.preSend)}})});var Qn,Xr=a(()=>{"use strict";E();y();Qn=c({name:"No F1",description:"Disables F1 help bind.",authors:[d.Cyn],patches:[{find:',"f1"],comboKeysBindGlobal:',replacement:{match:',"f1"],comboKeysBindGlobal:',replace:"],comboKeysBindGlobal:"}}]})});var Yn,Jr=a(()=>{"use strict";E();y();Yn=c({name:"No RPC",description:"Disables Discord's RPC server.",authors:[d.Cyn],target:"DESKTOP",patches:[{find:'.ensureModule("discord_rpc")',replacement:{match:/\.ensureModule\("discord_rpc"\)\.then\(\(.+?\)\)}/,replace:'.ensureModule("discord_rpc")}'}}]})});var Xn,Zr=a(()=>{"use strict";y();Xn=c({name:"NoReplyMention",description:"Disables reply pings by default",authors:[{name:"DustyAngel47",id:714583473804935238n}],patches:[{find:"CREATE_PENDING_REPLY:function",replacement:{match:/CREATE_PENDING_REPLY:function\((.{1,2})\){/,replace:"CREATE_PENDING_REPLY:function($1){$1.shouldMention=false;"}}]})});var Jn,ei=a(()=>{"use strict";E();y();Jn=c({name:"NoSystemBadge",description:"Disables the taskbar and system tray unread count badge.",authors:[d.rushii],target:"DESKTOP",patches:[{find:"setSystemTrayApplications:function",replacement:[{match:/setBadge:function.+?},/,replace:"setBadge:function(){},"},{match:/setSystemTrayIcon:function.+?},/,replace:"setSystemTrayIcon:function(){},"}]}]})});var Zn,ti=a(()=>{"use strict";E();y();Zn=c({name:"NoTrack",description:"Disable Discord's tracking and crash reporting",authors:[d.Cyn],required:!0,patches:[{find:"TRACKING_URL:",replacement:{match:/^.+$/,replace:"()=>{}"}},{find:"window.DiscordSentry=",replacement:{match:/window\.DiscordSentry=function.+\}\(\)/,replace:""}}]})});function oi(e){let t=e instanceof File,n=t?URL.createObjectURL(e):e;return new Promise((o,r)=>{let i=new Image;i.onload=()=>{t&&URL.revokeObjectURL(n),o(i)},i.onerror=(l,m,g,b,S)=>r(S||l),i.crossOrigin="Anonymous",i.src=n})}async function xa(e,t,n){for(let o of e)switch(o.name){case"image":let r=Sa.getUploads(t.channel.id,ni)[0];if(r){if(!r.isImage)throw"Upload is not an image";return r.item.file}break;case"url":return o.value;case"user":try{return(await ya(o.value)).getAvatarURL(n?void 0:t.guild?.id,2048).replace(/\?size=\d+$/,"?size=2048")}catch(i){throw console.error(`[petpet] Failed to fetch user -`,i),"Failed to fetch user. Check the console for more info."}}return null}var ni,ua,fa,ht,ga,ha,ya,ba,Sa,eo,ri=a(()=>{"use strict";re();E();O();y();A();ni=0,ua=20,fa=128,ht=10,ga=te(()=>import("https://unpkg.com/gifenc@1.0.3/dist/gifenc.esm.js")),ha=te(()=>Promise.all(Array.from({length:ht},(e,t)=>oi(`https://raw.githubusercontent.com/VenPlugs/petpet/main/frames/pet${t}.gif`)))),ya=C(h.byCode(".USER(")),ba=C(h.byCode("UPLOAD_FILE_LIMIT_ERROR")),Sa=C(h.byProps(["getUploads"]));eo=c({name:"petpet",description:"headpet a cutie",authors:[d.Ven],dependencies:["CommandsAPI"],commands:[{inputType:0,name:"petpet",description:"Create a petpet gif. You can only specify one of the image options",options:[{name:"delay",description:"The delay between each frame. Defaults to 20.",type:4},{name:"resolution",description:"Resolution for the gif. Defaults to 120. If you enter an insane number and it freezes Discord that's your fault.",type:4},{name:"image",description:"Image attachment to use",type:11},{name:"url",description:"URL to fetch image from",type:3},{name:"user",description:"User whose avatar to use as image",type:6},{name:"no-server-pfp",description:"Use the normal avatar instead of the server specific one when using the 'user' option",type:5}],execute:async(e,t)=>{let{GIFEncoder:n,quantize:o,applyPalette:r}=await ga(),i=await ha(),l=j(e,"no-server-pfp",!1);try{var m=await xa(e,t,l);if(!m)throw"No Image specified!"}catch(x){console.log(x);return}let g=await oi(m),b=j(e,"delay",ua),S=j(e,"resolution",fa),s=new n,p=document.createElement("canvas");p.width=p.height=S;let T=p.getContext("2d");for(let x=0;xba([w],t.channel,ni))}}]})});var to,ii=a(()=>{"use strict";E();y();to=c({name:"PlainFolderIcon",description:"Doesn't show the small guild icons in folders",authors:[d.botato],patches:[{find:"().expandedFolderIconWrapper",replacement:[{match:/\(\w\|\|\w\)(&&\(\w=\w\.createElement\(\w+\.animated)/,replace:"true$1"}]}]})});function no(){return Vencord.Webpack.Common.React.createElement(f.Fragment,null,Vencord.Webpack.Common.React.createElement(u.FormTitle,{tag:"h3"},"More Information"),Vencord.Webpack.Common.React.createElement(u.FormText,null,"The two pronoun formats are lowercase and capitalized. Example:",Vencord.Webpack.Common.React.createElement("ul",null,Vencord.Webpack.Common.React.createElement("li",null,"Lowercase: they/them"),Vencord.Webpack.Common.React.createElement("li",null,"Capitalized: They/Them")),'Text like "Ask me my pronouns" or "Any pronouns" will always be capitalized. ',Vencord.Webpack.Common.React.createElement("br",null),Vencord.Webpack.Common.React.createElement("br",null),"You can also configure whether or not to display pronouns for the current user (since you probably already know them)"))}var si=a(()=>{"use strict";v()});var fe,yt=a(()=>{"use strict";fe={hh:"He/Him",hi:"He/It",hs:"He/She",ht:"He/They",ih:"It/Him",ii:"It/Its",is:"It/She",it:"It/They",shh:"She/He",sh:"She/Her",si:"She/It",st:"She/They",th:"They/He",ti:"They/It",ts:"They/She",tt:"They/Them",any:"Any pronouns",other:"Other pronouns",ask:"Ask me my pronouns",avoid:"Avoid pronouns, use my name",unspecified:"Unspecified"}});var Me,Ye=a(()=>{Me="35d2b8d"});function St(e){return new Promise(t=>{e in bt?t(bt[e]):e in Ve?Ve[e].push(t):(Ve[e]=[t],Ea())})}async function Pa(e){let t=new URLSearchParams;t.append("platform","discord"),t.append("ids",e.join(","));try{return await(await fetch("https://pronoundb.org/api/v1/lookup-bulk?"+t.toString(),{method:"GET",headers:{Accept:"application/json","X-PronounDB-Source":`Vencord/${Me} (github.com/Vendicated/Vencord)`}})).json().then(o=>(Object.assign(bt,o),o))}catch(n){console.error("PronounDB fetching failed: ",n);let o=Object.fromEntries(e.map(r=>[r,"unspecified"]));return Object.assign(bt,o),o}}function xt(e){let{pronounsFormat:t}=P.plugins.PronounDB;return t==="CAPITALIZED"?fe[e]:t==="LOWERCASE"&&["any","ask","avoid","other"].includes(e)?fe[e]:fe[e].toLowerCase()}var bt,Ve,Ea,oo=a(()=>{"use strict";Ye();ue();K();ro();yt();bt={},Ve={},Ea=Tn(async()=>{let e=Object.keys(Ve),t=await Pa(e);for(let n of e)Ve[n].forEach(o=>o(t[n])),delete Ve[n]})});function io({message:e}){if(e.author.bot||e.author.system||!P.plugins.PronounDB.showSelf&&e.author.id===F.getCurrentUser().id)return null;let[t,,n]=pe(()=>St(e.author.id),null,o=>console.error("Fetching pronouns failed: ",o));return!n&&t&&t!=="unspecified"&&fe[t]?Vencord.Webpack.Common.React.createElement("span",{className:Te(ai.timestampInline,ai.timestamp)},"\u2022 ",xt(t)):null}var ai,ci=a(()=>{"use strict";O();K();A();v();yt();oo();ai=C(h.byProps(["timestampInline"]))});function so(e,t){if(e.user.bot||e.user.system||!P.plugins.PronounDB.showSelf&&e.user.id===F.getCurrentUser().id)return null;let[n,,o]=pe(()=>St(e.user.id),null,r=>console.error("Fetching pronouns failed: ",r));if(!o&&n&&n!=="unspecified"&&fe[n]){let[,r]=t.props.children;return r.props.children=xt(n),t}else return null}var li=a(()=>{"use strict";ue();K();v();yt();oo()});var ao,ro=a(()=>{"use strict";y();si();ci();li();ao=c({name:"PronounDB",authors:[{name:"Tyman",id:487443883127472129n}],description:"Adds pronouns to user messages using pronoundb",patches:[{find:"showCommunicationDisabledStyles",replacement:{match:/(?<=return\s+\w{1,3}\.createElement\(.+!\w{1,3}&&)(\w{1,3}.createElement\(.+?\{.+?\}\))/,replace:"[$1, Vencord.Plugins.plugins.PronounDB.PronounsChatComponent(e)]"}},{find:".headerTagUsernameNoNickname",replacement:{match:/""!==(.{1,2})&&(r\.createElement\(r\.Fragment.+?\.Messages\.USER_POPOUT_PRONOUNS.+?pronounsText.+?\},\1\)\))/,replace:(e,t,n)=>`Vencord.Plugins.plugins.PronounDB.PronounsProfileWrapper(e, ${n})`}}],options:{pronounsFormat:{type:4,description:"The format for pronouns to appear in chat",options:[{label:"Lowercase",value:"LOWERCASE",default:!0},{label:"Capitalized",value:"CAPITALIZED"}]},showSelf:{type:3,description:"Enable or disable showing pronouns for the current user",default:!0}},settingsAboutComponent:no,PronounsChatComponent:io,PronounsProfileWrapper:so})});function lo(e,t){t={invalidEmojis:[],tts:!1,validNonShortcutEmojis:[],...t};let n=Ta.getPendingReply(e);di.sendMessage(e,t,void 0,di.getSendMessageOptionsForReply(n)).then(()=>{n&&I.dispatch({type:"DELETE_PENDING_REPLY",channelId:e})})}var co,di,Ta,po,pi=a(()=>{"use strict";re();ue();E();y();A();v();co=C(h.byProps(["getPlayerState"])),di=C(h.byProps(["getSendMessageOptionsForReply","sendMessage"])),Ta=C(h.byProps(["getPendingReply"]));po=c({name:"Sendify",description:"Send your current Spotify music to chat",authors:[d.katlyn],dependencies:["CommandsAPI"],commands:[{name:"track",description:"Send your current Spotify track to chat",inputType:0,options:[],execute:(e,t)=>{let n=co.getTrack();if(n===null){oe(t.channel.id,{content:"You're not listening to any music."});return}lo(t.channel.id,{content:`https://open.spotify.com/track/${n.id}`})}},{name:"album",description:"Send your current Spotify album to chat",inputType:0,options:[],execute:(e,t)=>{let n=co.getTrack();if(n===null){oe(t.channel.id,{content:"You're not listening to any music."});return}lo(t.channel.id,{content:`https://open.spotify.com/album/${n.album.id}`})}},{name:"artist",description:"Send your current Spotify artist to chat",inputType:0,options:[],execute:(e,t)=>{let n=co.getTrack();if(n===null){oe(t.channel.id,{content:"You're not listening to any music."});return}lo(t.channel.id,{content:n.artists[0].external_urls.spotify})}}]})});var mo,mi=a(()=>{"use strict";Ye();E();y();mo=c({name:"Settings",description:"Adds Settings UI and debug info",authors:[d.Ven,d.Megu],required:!0,patches:[{find:"().versionHash",replacement:[{match:/\w\.createElement\(.{1,2}.Fragment,.{0,30}\{[^}]+\},"Host ".+?\):null/,replace:e=>{let t=e.indexOf("Host")-1,n=e.slice(0,t);return`${e}, ${n}"Vencord ", "${Me} (Web)"), " ")`}}]},{find:"Messages.ACTIVITY_SETTINGS",replacement:{match:/\{section:(.{1,2})\.ID\.HEADER,\s*label:(.{1,2})\..{1,2}\.Messages\.ACTIVITY_SETTINGS\}/,replace:(e,t)=>{let n="";return`{section:${t}.ID.HEADER,label:"Vencord"},{section:"VencordSetting",label:"Vencord",element:Vencord.Components.Settings},{section:"VencordPlugins",label:"Plugins",element:Vencord.Components.PluginSettings},`+n+`{section:${t}.ID.DIVIDER},${e}`}}}]})});var uo,ui=a(()=>{"use strict";E();y();uo=c({name:"SilentTyping",authors:[d.Ven],description:"Hide that you are typing",patches:[{find:"startTyping:",replacement:{match:/startTyping:.+?,stop/,replace:"startTyping:()=>{},stop"}}]})});var fo,fi=a(()=>{"use strict";me();E();y();fo=c({name:"Unindent",description:"Trims leading indentation from codeblocks",authors:[d.Ven],dependencies:["MessageEventsAPI"],patches:[{find:"inQuote:",replacement:{match:/,content:([^,]+),inQuote/,replace:(e,t)=>`,content:Vencord.Plugins.plugins.Unindent.unindent(${t}),inQuote`}}],unindent(e){e=e.replace(/\t/g," ");let t=e.match(/^ *(?=\S)/gm)?.reduce((n,o)=>Math.min(n,o.length),1/0)??0;return t?e.replace(new RegExp(`^ {${t}}`,"gm"),""):e},unindentMsg(e){e.content=e.content.replace(/```(.|\n)*?```/g,t=>{let n=t.split(` -`);if(n.length<2)return t;let o="";return n[n.length-1]==="```"&&(o=n.pop()),`${n[0]} +`;return(0,eval)(n)}var Lo,On,Eo,st,et,E,_a,Fo,Ce,No,Ea,Bn,Fa=m(()=>{"use strict";i();le();Et();_o();Lo=new N("Webpack"),Eo=new Promise(e=>On=e),E={byProps:(...e)=>e.length===1?t=>t[e[0]]!==void 0:t=>e.every(n=>t[n]!==void 0),byCode:(...e)=>t=>{if(typeof t!="function")return!1;let n=Function.prototype.toString.call(t);for(let r of e)if(!n.includes(r))return!1;return!0}},_a=new Map,Fo=new Set;Ce=Ve("find",function(t,n=!0,r=!1){if(typeof t!="function")throw new Error("Invalid filter. Expected a function got "+typeof t);for(let s in et){let a=et[s];if(!!a?.exports){if(t(a.exports))return a.exports;if(typeof a.exports=="object"){if(a.exports.default&&t(a.exports.default))return n?a.exports.default:a.exports;for(let c in a.exports)if(c.length<=3){let f=a.exports[c];if(f&&t(f))return f}}}}if(!r){let s=new Error("Didn't find module matching this filter");Lo.warn(s)}return null});No=Ve("findBulk",function(...t){if(!Array.isArray(t))throw new Error("Invalid filters. Expected function[] got "+typeof t);let{length:n}=t;if(n===0)throw new Error("Expected at least two filters.");if(n===1)return Ce(t[0]);let r=t,s=0,a=Array(n);e:for(let c in et){let f=et[c];if(!!f?.exports)for(let d=0;d$o,_initWebpack:()=>Do,_resolveReady:()=>On,addListener:()=>Mm,cache:()=>et,extract:()=>Cm,filters:()=>E,find:()=>Ce,findAll:()=>La,findAllByProps:()=>Im,findBulk:()=>No,findByCode:()=>xe,findByCodeLazy:()=>re,findByProps:()=>_e,findByPropsLazy:()=>M,findLazy:()=>Ae,findModuleId:()=>Ea,listeners:()=>Fo,mapMangledModule:()=>Bn,mapMangledModuleLazy:()=>Me,onceReady:()=>Eo,removeListener:()=>Rm,search:()=>Oo,subscriptions:()=>_a,waitFor:()=>$,wreq:()=>st});var L=m(()=>{"use strict";i();k();Fa()});var $o={};ee($o,{Alerts:()=>at,Button:()=>F,Card:()=>Te,ChannelStore:()=>ae,Clipboard:()=>Ee,ContextMenu:()=>Yo,Flux:()=>Uo,FluxDispatcher:()=>I,Forms:()=>y,GuildChannelStore:()=>zo,GuildStore:()=>qe,Margins:()=>V,Menu:()=>ue,MessageStore:()=>vt,NavigationRouter:()=>Ko,Parser:()=>Ke,PermissionStore:()=>jo,PresenceStore:()=>Xt,PrivateChannelsStore:()=>Go,React:()=>b,ReactDOM:()=>Am,ReadStateStore:()=>$n,RelationshipStore:()=>Hn,RestAPI:()=>Ho,Router:()=>jn,Select:()=>St,SelectedChannelStore:()=>pe,SelectedGuildStore:()=>Un,Slider:()=>qo,Switch:()=>bt,Text:()=>Y,TextArea:()=>Wo,TextInput:()=>Le,Toasts:()=>A,Tooltip:()=>me,UserStore:()=>G,UserUtils:()=>Zt,hljs:()=>Jt,moment:()=>_m});var V,I,Uo,b,Am,Ho,_m,Jt,vt,jo,Go,zo,$n,Xt,qe,G,pe,Un,ae,Hn,y,Te,F,bt,me,jn,Le,Y,Wo,St,qo,Ke,at,Lm,Em,A,Zt,Ee,Ko,ue,Yo,k=m(()=>{"use strict";i();O();Et();L();V=M("marginTop20"),Uo=M("connectStores"),Am=M("createPortal","render"),Ho=M("getAPIBaseURL","get"),_m=M("parseTwoDigitYear"),Jt=M("highlight"),vt=M("getRawMessages"),jo=M("can","getGuildPermissions"),Go=M("openPrivateChannel"),zo=M("getChannels"),$n=M("lastMessageId"),Xt=M("setCurrentUserOnConnectionOpen"),y={},Wo=re("handleSetRef","textArea"),St=Q(()=>xe("optionClassName","popoutPosition","autoFocus","maxVisibleItems")),qo=Q(()=>xe("closestMarkerIndex","stickToMarkers")),Lm={MESSAGE:0,SUCCESS:1,FAILURE:2,CUSTOM:3},Em={TOP:0,BOTTOM:1},A={Type:Lm,Position:Em,genId:()=>(Math.random()||Math.random()).toString(36).slice(2)},Zt={fetchUser:re(".USER(","getUser")},Ee=Me('document.queryCommandEnabled("copy")||document.queryCommandSupported("copy")',{copy:E.byCode(".default.copy("),SUPPORTS_COPY:e=>typeof e=="boolean"}),Ko=Me("Transitioning to external path",{transitionTo:E.byCode("Transitioning to external path"),transitionToGuild:E.byCode("transitionToGuild"),goBack:E.byCode("goBack()"),goForward:E.byCode("goForward()")});$("useState",e=>b=e);$(["dispatch","subscribe"],e=>{I=e;let t=()=>{e.unsubscribe("CONNECTION_OPEN",t),On()};e.subscribe("CONNECTION_OPEN",t)});$(["getCurrentUser","initialize"],e=>G=e);$("getSortedPrivateChannels",e=>ae=e);$("getCurrentlySelectedChannelId",e=>pe=e);$("getLastSelectedGuildId",e=>Un=e);$("getGuildCount",e=>qe=e);$("getRelationshipType",e=>Hn=e);$(["Hovers","Looks","Sizes"],e=>F=e);$(E.byCode("helpdeskArticleId"),e=>bt=e);$(["Positions","Colors"],e=>me=e);$(e=>e.Types?.PRIMARY==="cardPrimary",e=>Te=e);$(E.byCode("errorSeparator"),e=>y.FormTitle=e);$(E.byCode("titleClassName","sectionTitle"),e=>y.FormSection=e);$(e=>e.Types?.INPUT_PLACEHOLDER,e=>y.FormText=e);$(e=>{if(typeof e!="function")return!1;let t=e.toString();return t.length<200&&t.includes("().divider")},e=>y.FormDivider=e);$(E.byCode("currentToast?"),e=>A.show=e);$(E.byCode("currentToast:null"),e=>A.pop=e);$(["show","close"],e=>at=e);$("parseTopic",e=>Ke=e);$(["open","saveAccountChanges"],e=>jn=e);$(["defaultProps","Sizes","contextType"],e=>Le=e);$(e=>{if(typeof e!="function")return!1;let t=e.toString();return t.length<1500&&t.includes("data-text-variant")&&t.includes("always-white")},e=>Y=e);ue=We(()=>{let e=Vencord.Settings.plugins.MenuItemDeobfuscatorAPI.enabled,t=["MenuSeparator","MenuGroup","MenuItem","MenuCheckboxItem","MenuRadioItem","MenuControlItem"],n=Bn("\u266B \u2282(\uFF61\u25D5\u203F\u203F\u25D5\uFF61\u2282) \u266A",{ContextMenu:E.byCode("getContainerProps"),...Object.fromEntries((e?t:[]).map(r=>[r,s=>s.name===r]))});if(!e)for(let r of t)Object.defineProperty(n,r,{get(){throw new Error("MenuItemDeobfuscator must be enabled to use this.")}});return n}),Yo=Me('type:"CONTEXT_MENU_OPEN"',{open:E.byCode("stopPropagation"),openLazy:e=>e.toString().length<50,close:E.byCode("CONTEXT_MENU_CLOSE")})});function Fe(e){let t;return()=>t??(t=e())}function ve(e,t){let n=Object.assign({fallbackValue:null,deps:[],onError:null},t),[r,s]=b.useState({value:n.fallbackValue,error:null,pending:!0});return b.useEffect(()=>{let a=!0;return r.pending||s({...r,pending:!0}),e().then(c=>a&&s({value:c,error:null,pending:!1})).catch(c=>a&&(s({value:null,error:c,pending:!1}),n.onError?.(c))),()=>void(a=!1)},n.deps),[r.value,r.error,r.pending]}function ct(){let[,e]=b.useState(0);return()=>e(t=>t+1)}function Q(e){let t=Fe(e);return n=>{let r=t();return o(r,{...n})}}function xt(e,t){for(let n in t){let r=t[n];typeof r=="object"&&!Array.isArray(r)?(e[n]??={},xt(e[n],r)):e[n]??=r}return e}function Fm(e,t=n=>n){let{length:n}=e;if(n===0)return"";if(n===1)return t(e[0]);let r="";for(let s=0;s2?r+=", ":n-s>1&&(r+=" and ");return r}function ie(...e){return e.join(" ")}function Vt(e){return new Promise(t=>setTimeout(t,e))}function Dm(e,t,n){return t.constructor.name==="AsyncFunction"?async function(){try{await t.apply(n??this,arguments)}catch(r){console.error(`Caught an Error in ${e||"anonymous"} +`,r)}}:function(){try{t.apply(n??this,arguments)}catch(r){console.error(`Caught an Error in ${e||"anonymous"} +`,r)}}}function Gn(e,t){let n="```";return`${n}${t||""} +${e.replaceAll("```","\\`\\`\\`")} +${n}`}function en(e,t="Copied to clipboard!"){Ee.SUPPORTS_COPY?Ee.copy(e):t="Your browser does not support copying to clipboard",A.show({message:t,id:A.genId(),type:A.Type.SUCCESS})}function Nm(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function Qo(e){try{return new URL(e)}catch{return null}}var Jo,O=m(()=>{"use strict";i();k();Jo=e=>{let t=e.getBoundingClientRect(),n=Math.max(document.documentElement.clientHeight,window.innerHeight);return!(t.bottom<0||t.top-n>=0)}});function u(e){return e}var T=m(()=>{"use strict";i()});function Xo(e,t=e,n=""){return Om[n]??=new Proxy(e,{get(r,s){let a=r[s];if(!(s in r)){if(n==="plugins"&&s in te)return r[s]=Xo({enabled:te[s].required??!1},t,`plugins.${s}`);if(n.startsWith("plugins.")){let c=n.slice(8);if(c in te){let f=te[c].options?.[s];if(!f)return a;if("default"in f)return r[s]=f.default;if(f.type===4){let d=f.options.find(v=>v.default);return d&&(r[s]=d.value),d?.value}}}return a}return typeof a=="object"&&!Array.isArray(a)&&a!==null?Xo(a,t,`${n}${n&&"."}${s}`):a},set(r,s,a){if(r[s]===a)return!0;r[s]=a;let c=`${n}${n&&"."}${s}`;for(let f of zn)(!f._path||f._path===c)&&f(a,c);return VencordNative.ipc.invoke(j.SET_SETTINGS,JSON.stringify(t,null,4)),!0}})}function De(e){let[,t]=b.useReducer(()=>({}),{}),n=e?(r,s)=>e.includes(s)&&t():t;return b.useEffect(()=>(zn.add(n),()=>void zn.delete(n)),[]),S}function Zo(e,t){t._path=e,zn.add(t)}function X(e,...t){let{plugins:n}=lt;if(!(e in n)){for(let r of t)if(r in n){Na.info(`Migrating settings from old name ${r} to ${e}`),n[e]=n[r],delete n[r],VencordNative.ipc.invoke(j.SET_SETTINGS,JSON.stringify(lt,null,4));break}}}var Na,Da,lt,zn,Om,Oa,S,R=m(()=>{"use strict";i();ze();le();O();T();k();tn();Na=new N("Settings"),Da={notifyAboutUpdates:!0,useQuickCss:!0,themeLinks:[],enableReactDevtools:!1,plugins:{}};try{lt=JSON.parse(VencordNative.ipc.sendSync(j.GET_SETTINGS)),xt(lt,Da)}catch(e){lt=xt({},Da),Na.error(`An error occurred while loading the settings. Corrupt settings file? +`,e)}zn=new Set,Om={};Oa=lt,S=Xo(lt)});var Tt,nn=m(()=>{i();Tt="62b2ace"});var Vo,Ba=m(()=>{i();Vo="Vendicated/Vencord"});var tr={};ee(tr,{Devs:()=>p,REACT_GLOBAL:()=>Bm,VENCORD_USER_AGENT:()=>er,WEBPACK_CHUNK:()=>tt});var tt,Bm,er,p,x=m(()=>{"use strict";i();nn();Ba();tt="webpackChunkdiscord_app",Bm="Vencord.Webpack.Common.React",er=`Vencord/${Tt}${Vo?` (https://github.com/${Vo})`:""}`,p=Object.freeze({Ven:{name:"Vendicated",id:343383572805058560n},Arjix:{name:"ArjixWasTaken",id:674710789138939916n},Cyn:{name:"Cynosphere",id:150745989836308480n},Megu:{name:"Megumin",id:545581357812678656n},botato:{name:"botato",id:440990343899643943n},obscurity:{name:"obscurity",id:336678828233588736n},rushii:{name:"rushii",id:295190422244950017n},Glitch:{name:"Glitchy",id:269567451199569920n},Samu:{name:"Samu",id:702973430449832038n},Animal:{name:"Animal",id:118437263754395652n},MaiKokain:{name:"Mai",id:722647978577363026n},echo:{name:"ECHO",id:712639419785412668n},katlyn:{name:"katlyn",id:250322741406859265n},nea:{name:"nea",id:310702108997320705n},Nuckyz:{name:"Nuckyz",id:235834946571337729n},D3SOX:{name:"D3SOX",id:201052085641281538n},Nickyux:{name:"Nickyux",id:427146305651998721n},mantikafasi:{name:"mantikafasi",id:287555395151593473n},Xinto:{name:"Xinto",id:423915768191647755n},JacobTm:{name:"Jacob.Tm",id:302872992097107991n},DustyAngel47:{name:"DustyAngel47",id:714583473804935238n},BanTheNons:{name:"BanTheNons",id:460478012794863637n},BigDuck:{name:"BigDuck",id:1024588272623681609n},AverageReactEnjoyer:{name:"Average React Enjoyer",id:1004904120056029256n},adryd:{name:"adryd",id:0n},Tyman:{name:"Tyman",id:487443883127472129n},afn:{name:"afn",id:420043923822608384n},KraXen72:{name:"KraXen72",id:379304073515499530n},kemo:{name:"kemo",id:299693897859465228n},dzshn:{name:"dzshn",id:310449948011528192n},Ducko:{name:"Ducko",id:506482395269169153n},jewdev:{name:"jewdev",id:222369866529636353n},Luna:{name:"Luny",id:821472922140803112n},Vap:{name:"Vap0r1ze",id:454072114492866560n},KingFish:{name:"King Fish",id:499400512559382538n}})});var nr,$a=m(()=>{"use strict";i();R();x();O();T();nr=u({name:"BetterNotesBox",description:"Hide notes or disable spellcheck (Configure in settings!!)",authors:[p.Ven],patches:[{find:"hideNote:",all:!0,predicate:Fe(()=>Vencord.Settings.plugins.BetterNotesBox.hide),replacement:{match:/hideNote:.+?(?=[,}])/g,replace:"hideNote:true"}},{find:"Messages.NOTE_PLACEHOLDER",replacement:{match:/\.NOTE_PLACEHOLDER,/,replace:"$&spellCheck:!Vencord.Settings.plugins.BetterNotesBox.noSpellCheck,"}}],options:{hide:{type:3,description:"Hide notes",default:!1,restartNeeded:!0},noSpellCheck:{type:3,description:"Disable spellcheck in notes",disabled:()=>S.plugins.BetterNotesBox.hide,default:!1}}})});var or,Ua=m(()=>{"use strict";i();x();T();or=u({name:"TimeBarAllActivities",description:"Adds the Spotify time bar to all activities if they have start and end timestamps",authors:[p.obscurity],patches:[{find:"renderTimeBar=function",replacement:{match:/renderTimeBar=function\((.{1,3})\){.{0,50}?var/,replace:"renderTimeBar=function($1){var"}}]})});var rr,Ha=m(()=>{"use strict";i();R();x();T();rr=u({name:"AnonymiseFileNames",authors:[p.obscurity],description:"Anonymise uploaded file names",patches:[{find:"instantBatchUpload:function",replacement:{match:/uploadFiles:(.{1,2}),/,replace:"uploadFiles:(...args)=>(args[0].uploads.forEach(f=>f.filename=Vencord.Plugins.plugins.AnonymiseFileNames.anonymise(f.filename)),$1(...args)),"}}],options:{method:{description:"Anonymising method",type:4,options:[{label:"Random Characters",value:0,default:!0},{label:"Consistent",value:1},{label:"Timestamp (4chan-like)",value:2}]},randomisedLength:{description:"Random characters length",type:1,default:7,disabled:()=>S.plugins.AnonymiseFileNames.method!==0},consistent:{description:"Consistent filename",type:0,default:"image",disabled:()=>S.plugins.AnonymiseFileNames.method!==1}},anonymise(e){let t="image",n=e.lastIndexOf("."),r=n!==-1?e.slice(n):"";switch(S.plugins.AnonymiseFileNames.method){case 0:let s="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";t=Array.from({length:S.plugins.AnonymiseFileNames.randomisedLength},()=>s[Math.floor(Math.random()*s.length)]).join("");break;case 1:t=S.plugins.AnonymiseFileNames.consistent;break;case 2:t=`${Math.floor(Date.now()/1e3)}${Math.floor(window.performance.now())}`;break}return t+r}})});function Wn(){return o("svg",{"aria-hidden":"true",height:"16",viewBox:"0 0 16 16",width:"16",style:{marginRight:"0.5em",transform:"translateY(2px)"}},o("path",{fill:"#db61a2","fill-rule":"evenodd",d:"M4.25 2.5c-1.336 0-2.75 1.164-2.75 3 0 2.15 1.58 4.144 3.365 5.682A20.565 20.565 0 008 13.393a20.561 20.561 0 003.135-2.211C12.92 9.644 14.5 7.65 14.5 5.5c0-1.836-1.414-3-2.75-3-1.373 0-2.609.986-3.029 2.456a.75.75 0 01-1.442 0C6.859 3.486 5.623 2.5 4.25 2.5zM8 14.25l-.345.666-.002-.001-.006-.003-.018-.01a7.643 7.643 0 01-.31-.17 22.075 22.075 0 01-3.434-2.414C2.045 10.731 0 8.35 0 5.5 0 2.836 2.086 1 4.25 1 5.797 1 7.153 1.802 8 3.02 8.847 1.802 10.203 1 11.75 1 13.914 1 16 2.836 16 5.5c0 2.85-2.045 5.231-3.885 6.818a22.08 22.08 0 01-3.744 2.584l-.018.01-.006.003h-.002L8 14.25zm0 0l.345.666a.752.752 0 01-.69 0L8 14.25z"}))}var ir=m(()=>{"use strict";i()});function on(e){return o(F,{...e,look:F.Looks.LINK,color:F.Colors.TRANSPARENT,onClick:()=>VencordNative.ipc.invoke(j.OPEN_EXTERNAL,"https://github.com/sponsors/Vendicated")},o(Wn,null),"Donate")}var sr=m(()=>{"use strict";i();ze();k();ir()});function rn(e){return o(Te,{className:e.className,style:{padding:"2em",backgroundColor:"#e7828430",borderColor:"#e78284",color:"var(--text-normal)",...e.style}},e.children)}var qn=m(()=>{"use strict";i();k()});var $m,ja,Ga,ar,D,ne=m(()=>{"use strict";i();le();O();k();qn();$m="#e78284",ja=new N("React ErrorBoundary",$m),Ga={},ar=Q(()=>class extends b.PureComponent{state={error:Ga,stack:"",message:""};static getDerivedStateFromError(t){let n=t?.stack??"",r=t?.message||String(t);if(t instanceof Error&&n){let s=n.indexOf(` +`);s!==-1&&(r=n.slice(0,s),n=n.slice(s+1).replace(/https:\/\/\S+\/assets\//g,""))}return{error:t,stack:n,message:r}}componentDidCatch(t,n){this.props.onError?.(t,n),ja.error(`A component threw an Error +`,t),ja.error("Component Stack",n.componentStack)}render(){if(this.state.error===Ga)return this.props.children;if(this.props.noop)return null;if(this.props.fallback)return o(this.props.fallback,{children:this.props.children,...this.state});let t=this.props.message||"An error occurred while rendering this Component. More info can be found below and in your console.";return o(rn,{style:{overflow:"hidden"}},o("h1",null,"Oh no!"),o("p",null,t),o("code",null,this.state.message,!!this.state.stack&&o("pre",{className:V.marginTop8},this.state.stack)))}});ar.wrap=(e,t)=>n=>o(ar,{...t},o(e,{...n}));D=ar});function Z(e){return e.style??={},e.style.display="flex",e.style.gap??="1em",e.style.flexDirection||=e.flexDirection,delete e.flexDirection,o("div",{...e},e.children)}var Ne=m(()=>{"use strict";i()});var dr={};ee(dr,{ModalCloseButton:()=>cr,ModalContent:()=>ot,ModalFooter:()=>sn,ModalHeader:()=>nt,ModalRoot:()=>Be,ModalSize:()=>Ft,Modals:()=>Oe,closeModal:()=>an,openModal:()=>we,openModalLazy:()=>pr});function pr(e,t){return lr.openModalLazy(e,t)}function we(e,t,n){return lr.openModal(e,t,n)}function an(e,t){return lr.closeModal(e,t)}var Ft,Oe,Be,nt,ot,sn,cr,lr,Ye=m(()=>{"use strict";i();L();Ft=(s=>(s.SMALL="small",s.MEDIUM="medium",s.LARGE="large",s.DYNAMIC="dynamic",s))(Ft||{}),Oe=Me("().closeWithCircleBackground",{ModalRoot:E.byCode("().root"),ModalHeader:E.byCode("().header"),ModalContent:E.byCode("().content"),ModalFooter:E.byCode("().footerSeparator"),ModalCloseButton:E.byCode("().closeWithCircleBackground")}),Be=e=>o(Oe.ModalRoot,{...e}),nt=e=>o(Oe.ModalHeader,{...e}),ot=e=>o(Oe.ModalContent,{...e}),sn=e=>o(Oe.ModalFooter,{...e}),cr=e=>o(Oe.ModalCloseButton,{...e}),lr=Me("onCloseRequest:null!=",{openModal:E.byCode("onCloseRequest:null!="),closeModal:E.byCode("onCloseCallback&&"),openModalLazy:e=>e?.length===1&&E.byCode(".apply(this,arguments)")(e)})});var Um,Hm,jm,za,mr,Wa=m(()=>{"use strict";i();fr();sr();ne();Ne();ir();x();ze();le();Ye();T();k();Um="https://media.discordapp.net/stickers/1026517526106087454.webp",Hm=Object.values(p).map(e=>e.id.toString()),jm={tooltip:"Vencord Contributor",image:Um,position:0,props:{style:{borderRadius:"50%",transform:"scale(0.9)"}},shouldShow:({user:e})=>Hm.includes(e.id),onClick:()=>VencordNative.ipc.invoke(j.OPEN_EXTERNAL,"https://github.com/Vendicated/Vencord")},za={},mr=u({name:"BadgeAPI",description:"API to add badges to users.",authors:[p.Megu],required:!0,patches:[{find:"PREMIUM_GUILD_SUBSCRIPTION_TOOLTIP.format({date:",replacement:{match:/&&((\w{1,3})\.push\({tooltip:\w{1,3}\.\w{1,3}\.Messages\.PREMIUM_GUILD_SUBSCRIPTION_TOOLTIP\.format.+?;)(?:return\s\w{1,3};?})/,replace:(e,t,n)=>`&&${t} return Vencord.Api.Badges.inject(${n}, arguments[0]);}`}},{find:"Messages.PROFILE_USER_BADGES,role:",replacement:{match:/src:(\w{1,3})\[(\w{1,3})\.key\],/,replace:(e,t,n)=>`src: ${n}.image ?? ${t}[${n}.key], ...${n}.props,`}}],async start(){Vencord.Api.Badges.addBadge(jm);let t=(await fetch("https://gist.githubusercontent.com/Vendicated/51a3dd775f6920429ec6e9b735ca7f01/raw/badges.csv").then(n=>n.text())).trim().split(` +`);if(t.shift()!=="id,tooltip,image"){new N("BadgeAPI").error("Invalid badges.csv file!");return}for(let n of t){let[r,s,a]=n.split(",");za[r]={image:a,tooltip:s}}},addDonorBadge(e,t){let n=za[t];n&&e.unshift({...n,position:0,props:{style:{borderRadius:"50%",transform:"scale(0.9)"}},onClick(){let r=we(s=>o(D,{noop:!0,onError:()=>{an(r),VencordNative.ipc.invoke(j.OPEN_EXTERNAL,"https://github.com/sponsors/Vendicated")}},o(Oe.ModalRoot,{...s},o(Oe.ModalHeader,null,o(Z,{style:{width:"100%",justifyContent:"center"}},o(y.FormTitle,{tag:"h2",style:{width:"100%",textAlign:"center",margin:0}},o(Wn,null),"Vencord Donor"))),o(Oe.ModalContent,null,o(Z,null,o("img",{role:"presentation",src:"https://cdn.discordapp.com/emojis/1026533070955872337.png",alt:"",style:{margin:"auto"}}),o("img",{role:"presentation",src:"https://cdn.discordapp.com/emojis/1026533090627174460.png",alt:"",style:{margin:"auto"}})),o("div",{style:{padding:"1em"}},o(y.FormText,null,"This Badge is a special perk for Vencord Donors"),o(y.FormText,{className:V.marginTop20},"Please consider supporting the development of Vencord by becoming a donor. It would mean a lot!!"))),o(Oe.ModalFooter,null,o(Z,{style:{width:"100%",justifyContent:"center"}},o(on,null))))))}})}})});var gr,qa=m(()=>{"use strict";i();x();T();gr=u({name:"CommandsAPI",authors:[p.Arjix],description:"Api required by anything that uses commands",patches:[{find:'"giphy","tenor"',replacement:[{match:/(?<=\w=)(\w)(\.filter\(.{0,30}giphy)/,replace:"Vencord.Api.Commands._init($1)$2"}]},{find:"Unexpected value for option",replacement:{match:/,(.{1,2})\.execute\((.{1,2}),(.{1,2})\)]/,replace:(e,t,n,r)=>`,Vencord.Api.Commands._handleCommand(${t}, ${n}, ${r})]`}},{find:"().source,children",replacement:{match:/(?<=:(.{1,3})\.displayDescription\}.{0,200}\(\)\.source,children:)[^}]+/,replace:"$1.plugin||($&)"}}]})});var Ka,hr,Ya=m(()=>{"use strict";i();R();x();T();Ka={radio:"MenuRadioItem",separator:"MenuSeparator",checkbox:"MenuCheckboxItem",groupstart:"MenuGroup",control:"MenuControlItem",compositecontrol:"MenuControlItem",item:"MenuItem",customitem:"MenuItem"};X("MenuItemDeobfuscatorAPI","MenuItemDeobfuscatorApi");hr=u({name:"MenuItemDeobfuscatorAPI",description:"Deobfuscates Discord's Menu Item module",authors:[p.Ven],patches:[{find:'"Menu API',replacement:{match:/function.{0,80}type===(.{1,3})\..{1,3}\).{0,50}navigable:.+?Menu API/s,replace:(e,t)=>{let n="",r=[],s=/\(.{1,3}\.type===(.{1,5})\)/g,a=/type:"(\w+)"/g,c;for(;(c=s.exec(e))!==null;){let f=c[1];a.lastIndex=s.lastIndex;let d=a.exec(e)?.[1];if(d&&d in Ka){let v=Ka[d];n+=`Object.defineProperty(${f},"name",{value:"${v}"});`,r.push(`${v}:${f}`)}}return r.length<6&&console.warn("[ApiMenuItemDeobfuscator] Expected to at least remap 6 items, only remapped",r.length),`${n}Object.assign(${t},{${r.join(",")}});${e}`}}}]})});var yr,Qa=m(()=>{"use strict";i();x();T();yr=u({name:"MessageAccessoriesAPI",description:"API to add message accessories.",authors:[p.Cyn],patches:[{find:"_messageAttachmentToEmbedMedia",replacement:{match:/(\(\)\.container\)?,children:)(\[[^\]]+\])(}\)\};return)/,replace:(e,t,n,r)=>`${t}Vencord.Api.MessageAccessories._modifyAccessories(${n},this.props)${r}`}}]})});var vr,Ja=m(()=>{"use strict";i();x();T();vr=u({name:"MessageEventsAPI",description:"Api required by anything using message events.",authors:[p.Arjix],patches:[{find:"sendMessage:function",replacement:[{match:/(?<=_sendMessage:function\([^)]+\)){/,replace:"{if(Vencord.Api.MessageEvents._handlePreSend(...arguments)){return;};"},{match:/(?<=\beditMessage:function\([^)]+\)){/,replace:"{Vencord.Api.MessageEvents._handlePreEdit(...arguments);"}]},{find:'("interactionUsernameProfile',replacement:{match:/var \w=(\w)\.id,\w=(\w)\.id;return .{1,2}\.useCallback\(\(?function\((.{1,2})\){/,replace:(e,t,n,r)=>`var _msg=${t},_chan=${n};${e}Vencord.Api.MessageEvents._handleClick(_msg, _chan, ${r});`}}]})});var br,Xa=m(()=>{"use strict";i();x();T();br=u({name:"MessagePopoverAPI",description:"API to add buttons to message popovers.",authors:[p.KingFish],patches:[{find:"Messages.MESSAGE_UTILITIES_A11Y_LABEL",replacement:{match:/(message:(.).{0,100}Fragment,\{children:\[)(.{0,90}renderPopout:.{0,200}message_reaction_emoji_picker.+?return (.{1,3})\(.{0,30}"add-reaction")/,replace:"$1...Vencord.Api.MessagePopover._buildPopoverElements($2,$4),$3"}}]})});var Sr,Za=m(()=>{"use strict";i();R();x();T();X("NoticesAPI","NoticesApi");Sr=u({name:"NoticesAPI",description:"Fixes notices being automatically dismissed",authors:[p.Ven],required:!0,patches:[{find:"updateNotice:",replacement:[{match:/;(.{1,2}=null;)(?=.{0,50}updateNotice)/g,replace:";if(Vencord.Api.Notices.currentNotice)return !1;$1"},{match:/(?<=NOTICE_DISMISS:function.+?){(?=if\(null==(.+?)\))/,replace:'{if($1?.id=="VencordNotice")return ($1=null,Vencord.Api.Notices.nextNotice(),true);'}]}]})});var xr,Va=m(()=>{"use strict";i();x();T();xr=u({name:"ServerListAPI",authors:[p.kemo],description:"Api required for plugins that modify the server list",patches:[{find:"Messages.DISCODO_DISABLED",replacement:{match:/(Messages\.DISCODO_DISABLED\);return)(.*?homeIcon.*?)(\}function)/,replace:"$1[$2].concat(Vencord.Api.ServerList.renderAll(Vencord.Api.ServerList.ServerListRenderPosition.Above))$3"}},{find:"Messages.SERVERS",replacement:{match:/(Messages\.SERVERS,children:)(.+?default:return null\}\}\)\))/,replace:"$1Vencord.Api.ServerList.renderAll(Vencord.Api.ServerList.ServerListRenderPosition.In).concat($2)"}}]})});var kr={};ee(kr,{currentNotice:()=>cn,nextNotice:()=>ec,noticesQueue:()=>wr,popNotice:()=>Pr,showNotice:()=>ln});function Pr(){Tr.dismiss()}function ec(){cn=wr.shift(),cn&&Tr.show(...cn,"VencordNotice")}function ln(e,t,n){wr.push(["GENERIC",e,t,n]),cn||ec()}var Tr,wr,cn,pn=m(()=>{"use strict";i();L();$(e=>e.show&&e.dismiss&&!e.suppressAll,e=>Tr=e);wr=[],cn=null});function Pe(e){return e.disabled&&(e.style??={},e.style.pointerEvents="none",e["aria-disabled"]=!0),o("a",{role:"link",target:"_blank",...e},e.children)}var wt=m(()=>{"use strict";i()});async function tc(e,t){return(await Gm.getAsset(e,[t,void 0]))[0]}async function Wm(e){let t={};return await zm.lookupApp(t,e),t.application}var Gm,zm,nc,Dt,Ir,oc=m(()=>{"use strict";i();pn();wt();x();T();L();k();Gm=Me("getAssetImage: size must === [number, number] for Twitch",{getAsset:E.byCode("apply(")}),zm=re(".APPLICATION_RPC(");nc={};Ir=u({name:"WebRichPresence (arRPC)",description:"Client plugin for arRPC to enable RPC on Discord Web (experimental)",authors:[p.Ducko],target:"WEB",settingsAboutComponent:()=>o(l,null,o(y.FormTitle,{tag:"h3"},"How to use arRPC"),o(y.FormText,null,o(Pe,{href:"https://github.com/OpenAsar/arrpc/tree/main#server"},"Follow the instructions in the GitHub repo")," to get the server running, and then enable the plugin.")),async start(){if(Dt&&Dt.close(),Dt=new WebSocket("ws://127.0.0.1:1337"),Dt.onmessage=async t=>{let n=JSON.parse(t.data);if(n.activity?.assets?.large_image&&(n.activity.assets.large_image=await tc(n.activity.application_id,n.activity.assets.large_image)),n.activity?.assets?.small_image&&(n.activity.assets.small_image=await tc(n.activity.application_id,n.activity.assets.small_image)),n.activity){let r=n.activity.application_id;nc[r]||=await Wm(r);let s=nc[r];n.activity.name||=s.name}I.dispatch({type:"LOCAL_ACTIVITY_UPDATE",...n})},!await new Promise(t=>setTimeout(()=>t(Dt.readyState===WebSocket.OPEN),1e3))){ln("Failed to connect to arRPC, is it running?","Retry",()=>{Pr(),this.start()});return}A.show({message:"Connected to arRPC",type:A.Type.SUCCESS,id:A.genId(),options:{duration:1e3,position:A.Position.BOTTOM}})},stop(){I.dispatch({type:"LOCAL_ACTIVITY_UPDATE",activity:null}),Dt.close()}})});var Mr,rc=m(()=>{"use strict";i();x();T();Mr=u({name:"BANger",description:"Replaces the GIF in the ban dialogue with a custom one.",authors:[p.Xinto,p.Glitch],patches:[{find:"BAN_CONFIRM_TITLE.",replacement:{match:/src:\w\(\d+\)/g,replace:"src: Vencord.Settings.plugins.BANger.source"}}],options:{source:{description:"Source to replace ban GIF with (Video or Gif)",type:0,default:"https://i.imgur.com/wp5q52C.mp4",restartNeeded:!0}}})});var Rr,ic=m(()=>{"use strict";i();x();T();Rr=u({name:"BetterGifAltText",authors:[p.Ven],description:"Change GIF alt text from simply being 'GIF' to containing the gif tags / filename",patches:[{find:"onCloseImage=",replacement:{match:/(return.{0,10}\.jsx.{0,50}isWindowFocused)/,replace:"Vencord.Plugins.plugins.BetterGifAltText.altify(e);$1"}},{find:'preload:"none","aria',replacement:{match:/(?<==(.{1,3})\.alt.{0,20})\?.{0,5}\.Messages\.GIF/,replace:"?($1.alt='GIF',Vencord.Plugins.plugins.BetterGifAltText.altify($1))"}}],altify(e){if(e.alt!=="GIF")return e.alt;let t=e.original||e.src;try{t=decodeURI(t)}catch{}let n=t.slice(t.lastIndexOf("/")+1).replace(/\d/g,"").replace(/.gif$/,"").split(/[,\-_ ]+/g).slice(0,20).join(" ");return n.length>300&&(n=n.slice(0,300)+"..."),n&&(e.alt+=` - ${n}`),e.alt}})});var Cr,sc=m(()=>{"use strict";i();R();x();T();k();X("BetterRoleDot","ClickableRoleDot");Cr=u({name:"BetterRoleDot",authors:[p.Ven],description:"Copy role colour on RoleDot (accessibility setting) click. Also allows using both RoleDot and coloured names simultaneously",patches:[{find:"M0 4C0 1.79086 1.79086 0 4 0H16C18.2091 0 20 1.79086 20 4V16C20 18.2091 18.2091 20 16 20H4C1.79086 20 0 18.2091 0 16V4Z",replacement:{match:/viewBox:"0 0 20 20"/,replace:"$&,onClick:()=>Vencord.Plugins.plugins.BetterRoleDot.copyToClipBoard(e.color),style:{cursor:'pointer'}"}},{find:'"username"===',all:!0,predicate:()=>S.plugins.BetterRoleDot.bothStyles,replacement:{match:/"(?:username|dot)"===\w\b/g,replace:"true"}}],options:{bothStyles:{type:3,description:"Show both role dot and coloured names",default:!1}},copyToClipBoard(e){Ee.copy(e),A.show({message:"Copied to Clipboard!",type:A.Type.SUCCESS,id:A.genId(),options:{duration:1e3,position:A.Position.BOTTOM}})}})});var Ar,ac=m(()=>{"use strict";i();x();T();Ar=u({name:"BetterUploadButton",authors:[p.obscurity,p.Ven],description:"Upload with a single click, open menu with right click",patches:[{find:"Messages.CHAT_ATTACH_UPLOAD_OR_INVITE",replacement:{match:/CHAT_ATTACH_UPLOAD_OR_INVITE,onDoubleClick:(.+?:void 0)\},(.{1,3})\)/,replace:(e,t,n)=>`${e.slice(0,-1)},{onClick:${t},onContextMenu:${n}.onClick})`}}]})});function cc(){dn.textContent=` + .vc-nsfw-img [class^=imageWrapper] img, + .vc-nsfw-img [class^=wrapperPaused] video { + filter: blur(${S.plugins.BlurNSFW.blurAmount}px); + transition: filter 0.2s; + } + .vc-nsfw-img [class^=imageWrapper]:hover img, + .vc-nsfw-img [class^=wrapperPaused]:hover video { + filter: unset; + } + `}var dn,_r,lc=m(()=>{"use strict";i();R();x();T();_r=u({name:"BlurNSFW",description:"Blur attachments in NSFW channels until hovered",authors:[p.Ven],patches:[{find:"().embedWrapper,embed",replacement:[{match:/(\.renderEmbed=.+?(.)=.\.props)(.+?\(\)\.embedWrapper)/g,replace:"$1,vcProps=$2$3+(vcProps.channel.nsfw?' vc-nsfw-img':'')"},{match:/(\.renderAttachments=.+?(.)=this\.props)(.+?\(\)\.embedWrapper)/g,replace:"$1,vcProps=$2$3+(vcProps.channel.nsfw?' vc-nsfw-img':'')"}]}],options:{blurAmount:{type:1,description:"Blur Amount",default:10,onChange:cc}},start(){dn=document.createElement("style"),dn.id="VcBlurNsfw",document.head.appendChild(dn),cc()},stop(){dn?.remove()}})});function qm(e){let t=S.plugins.CallTimer.format==="human",n=h=>t?h:h.toString().padStart(2,"0"),r=h=>t?h:"",s=t?" ":":",a=Math.floor(e/864e5),c=Math.floor(e%864e5/36e5),f=Math.floor(e%864e5%36e5/6e4),d=Math.floor(e%864e5%36e5%6e4/1e3),v="";return a&&(v+=`${a}d `),(c||v)&&(v+=`${n(c)}${r("h")}${s}`),(f||v||!t)&&(v+=`${n(f)}${r("m")}${s}`),v+=`${n(d)}${r("s")}`,v}var Lr,pc=m(()=>{"use strict";i();R();ne();x();T();k();Lr=u({name:"CallTimer",description:"Adds a timer to vcs",authors:[p.Ven],startTime:0,interval:void 0,options:{format:{type:4,description:"The timer format. This can be any valid moment.js format",options:[{label:"30d 23:00:42",value:"stopwatch",default:!0},{label:"30d 23h 00m 42s",value:"human"}]}},patches:[{find:".renderConnectionStatus=",replacement:{match:/(?<=renderConnectionStatus=.+\(\)\.channel,children:)\w/,replace:"[$&, Vencord.Plugins.plugins.CallTimer.renderTimer(this.props.channel.id)]"}}],renderTimer(e){return o(D,{noop:!0},o(this.Timer,{channelId:e}))},Timer({channelId:e}){let[t,n]=b.useState(0),r=b.useMemo(()=>Date.now(),[e]);return b.useEffect(()=>{let s=setInterval(()=>n(Date.now()-r),1e3);return()=>{clearInterval(s),n(0)}},[e]),o("p",{style:{margin:0}},"Connected for ",qm(t))}})});var $r={};ee($r,{_handleClick:()=>Qm,_handlePreEdit:()=>Ym,_handlePreSend:()=>Km,addClickListener:()=>Or,addPreEditListener:()=>Pt,addPreSendListener:()=>$e,removeClickListener:()=>Br,removePreEditListener:()=>kt,removePreSendListener:()=>Ue});function Km(e,t,n){for(let r of Fr)try{let s=r(e,t,n);if(s&&s.cancel===!0)return!0}catch(s){Er.error(`MessageSendHandler: Listener encountered an unknown error +`,s)}return!1}function Ym(e,t,n){for(let r of Dr)try{r(e,t,n)}catch(s){Er.error(`MessageEditHandler: Listener encountered an unknown error +`,s)}}function $e(e){return Fr.add(e),e}function Pt(e){return Dr.add(e),e}function Ue(e){return Fr.delete(e)}function kt(e){return Dr.delete(e)}function Qm(e,t,n){e=vt.getMessage(t.id,e.id)??e;for(let r of Nr)try{r(e,t,n)}catch(s){Er.error(`MessageClickHandler: Listener encountered an unknown error +`,s)}}function Or(e){return Nr.add(e),e}function Br(e){return Nr.delete(e)}var Er,Fr,Dr,Nr,pt=m(()=>{"use strict";i();le();k();Er=new N("MessageEvents","#e5c890"),Fr=new Set,Dr=new Set;Nr=new Set});var dc,mc=m(()=>{"use strict";i();dc=["action_object_map","action_type_map","action_ref_map","spm@*.aliexpress.com","scm@*.aliexpress.com","aff_platform","aff_trace_key","algo_expid@*.aliexpress.*","algo_pvid@*.aliexpress.*","btsid","ws_ab_test","pd_rd_*@amazon.*","_encoding@amazon.*","psc@amazon.*","tag@amazon.*","ref_@amazon.*","pf_rd_*@amazon.*","pf@amazon.*","crid@amazon.*","keywords@amazon.*","sprefix@amazon.*","sr@amazon.*","ie@amazon.*","node@amazon.*","qid@amazon.*","callback@bilibili.com","cvid@bing.com","form@bing.com","sk@bing.com","sp@bing.com","sc@bing.com","qs@bing.com","pq@bing.com","sc_cid","mkt_tok","trk","trkCampaign","ga_*","gclid","gclsrc","hmb_campaign","hmb_medium","hmb_source","spReportId","spJobID","spUserID","spMailingID","itm_*","s_cid","elqTrackId","elqTrack","assetType","assetId","recipientId","campaignId","siteId","mc_cid","mc_eid","pk_*","sc_campaign","sc_channel","sc_content","sc_medium","sc_outcome","sc_geo","sc_country","nr_email_referer","vero_conv","vero_id","yclid","_openstat","mbid","cmpid","cid","c_id","campaign_id","Campaign","hash@ebay.*","fb_action_ids","fb_action_types","fb_ref","fb_source","fbclid","refsrc@facebook.com","hrc@facebook.com","gs_l","gs_lcp@google.*","ved@google.*","ei@google.*","sei@google.*","gws_rd@google.*","gs_gbg@google.*","gs_mss@google.*","gs_rn@google.*","_hsenc","_hsmi","__hssc","__hstc","hsCtaTracking","source@sourceforge.net","position@sourceforge.net","t@*.twitter.com","s@*.twitter.com","ref_*@*.twitter.com","tt_medium","tt_content","lr@yandex.*","redircnt@yandex.*","feature@youtube.com","kw@youtube.com","wt_zmc","utm_source","utm_content","utm_medium","utm_campaign","utm_term","si@open.spotify.com"]});var uc,Jm,Ur,fc=m(()=>{"use strict";i();pt();R();x();T();mc();uc=/[\\^$.*+?()[\]{}|]/g,Jm=RegExp(uc.source);X("ClearURLs","clearURLs");Ur=u({name:"ClearURLs",description:"Removes tracking garbage from URLs",authors:[p.adryd],dependencies:["MessageEventsAPI"],escapeRegExp(e){return e&&Jm.test(e)?e.replace(uc,"\\$&"):e||""},createRules(){let e=dc;this.universalRules=new Set,this.rulesByHost=new Map,this.hostRules=new Map;for(let t of e){let n=t.split("@"),r=new RegExp("^"+this.escapeRegExp(n[0]).replace(/\\\*/,".+?")+"$");if(!n[1]){this.universalRules.add(r);continue}let s=new RegExp("^(www\\.)?"+this.escapeRegExp(n[1]).replace(/\\\./,"\\.").replace(/^\\\*\\\./,"(.+?\\.)?").replace(/\\\*/,".+?")+"$"),a=s.toString();this.hostRules.set(a,s),this.rulesByHost.get(a)==null&&this.rulesByHost.set(a,new Set),this.rulesByHost.get(a).add(r)}},removeParam(e,t,n){(t===e||e instanceof RegExp&&e.test(t))&&n.delete(t)},replacer(e){try{var t=new URL(e)}catch{return e}return t.searchParams.entries().next().done?e:(this.universalRules.forEach(n=>{t.searchParams.forEach((r,s,a)=>{this.removeParam(n,s,a)})}),this.hostRules.forEach((n,r)=>{!n.test(t.hostname)||this.rulesByHost.get(r).forEach(s=>{t.searchParams.forEach((a,c,f)=>{this.removeParam(s,c,f)})})}),t.toString())},onSend(e){e.content.match(/http(s)?:\/\//)&&(e.content=e.content.replace(/(https?:\/\/[^\s<]+[^<.,:;"'>)|\]\s])/g,t=>this.replacer(t)))},start(){this.createRules(),this.preSend=$e((e,t)=>this.onSend(t)),this.preEdit=Pt((e,t,n)=>this.onSend(n))},stop(){Ue(this.preSend),kt(this.preEdit)}})});var Hr,jr,gc=m(()=>{"use strict";i();x();T();Hr=e=>()=>{throw new Error(`'${e}' is Discord Desktop only.`)},jr=u({name:"ConsoleShortcuts",description:"Adds shorter Aliases for many things on the window. Run `shortcutList` for a list.",authors:[p.Ven],getShortcuts(){return{toClip:Hr("toClip"),fromClip:Hr("fromClip"),wp:Vencord.Webpack,wpc:Vencord.Webpack.wreq.c,wreq:Vencord.Webpack.wreq,wpsearch:Vencord.Webpack.search,wpex:Vencord.Webpack.extract,wpexs:e=>Vencord.Webpack.extract(Vencord.Webpack.findModuleId(e)),findByProps:Vencord.Webpack.findByProps,find:Vencord.Webpack.find,Plugins:Vencord.Plugins,React:Vencord.Webpack.Common.React,Settings:Vencord.Settings,Api:Vencord.Api,reload:()=>location.reload(),restart:Hr("restart")}},start(){let e=this.getShortcuts();window.shortcutList=e;for(let[t,n]of Object.entries(e))window[t]=n},stop(){delete window.shortcutList;for(let e in this.getShortcuts())delete window[e]}})});function Gr(){return`-${hc.fromTimestamp(Date.now())}`}function U(e,t){let n=Xm({channelId:e,content:"",embeds:[]});return Zm.receiveMessage(e,xt(t,n)),t}function ce(e,t,n){return e.find(r=>r.name===t)?.value||n}var Xm,Zm,hc,Kn=m(()=>{"use strict";i();O();L();Xm=re('username:"Clyde"'),Zm=M("receiveMessage");$("fromTimestamp",e=>hc=e)});var dt,Qe,zr,mn=m(()=>{"use strict";i();dt=(g=>(g[g.SUB_COMMAND=1]="SUB_COMMAND",g[g.SUB_COMMAND_GROUP=2]="SUB_COMMAND_GROUP",g[g.STRING=3]="STRING",g[g.INTEGER=4]="INTEGER",g[g.BOOLEAN=5]="BOOLEAN",g[g.USER=6]="USER",g[g.CHANNEL=7]="CHANNEL",g[g.ROLE=8]="ROLE",g[g.MENTIONABLE=9]="MENTIONABLE",g[g.NUMBER=10]="NUMBER",g[g.ATTACHMENT=11]="ATTACHMENT",g))(dt||{}),Qe=(a=>(a[a.BUILT_IN=0]="BUILT_IN",a[a.BUILT_IN_TEXT=1]="BUILT_IN_TEXT",a[a.BUILT_IN_INTEGRATION=2]="BUILT_IN_INTEGRATION",a[a.BOT=3]="BOT",a[a.PLACEHOLDER=4]="PLACEHOLDER",a))(Qe||{}),zr=(r=>(r[r.CHAT_INPUT=1]="CHAT_INPUT",r[r.USER=2]="USER",r[r.MESSAGE=3]="MESSAGE",r))(zr||{})});var Kr={};ee(Kr,{ApplicationCommandInputType:()=>Qe,ApplicationCommandOptionType:()=>dt,ApplicationCommandType:()=>zr,BUILT_IN:()=>mt,OptionalMessageOption:()=>ut,RequiredMessageOption:()=>It,_handleCommand:()=>eu,_init:()=>Vm,commands:()=>Wr,findOption:()=>ce,generateId:()=>Gr,prepareOption:()=>qr,registerCommand:()=>Nt,sendBotMessage:()=>U,unregisterCommand:()=>un});function qr(e){return e.displayName||=e.name,e.displayDescription||=e.description,e.options?.forEach((t,n,r)=>{t===yc?r[n]=ut:t===vc&&(r[n]=It),t.choices?.forEach(s=>s.displayName||=s.name),qr(r[n])}),e}function tu(e,t){e.options?.forEach(n=>{if(n.type!==1)throw new Error("When specifying sub-command options, all options must be sub-commands.");let r={...e,...n,type:1,name:`${e.name} ${n.name}`,displayName:`${e.name} ${n.name}`,subCommandPath:[{name:n.name,type:n.type,displayName:n.name}],rootCommand:e};Nt(r,t)})}function Nt(e,t){if(!mt){console.warn("[CommandsAPI]",`Not registering ${e.name} as the CommandsAPI hasn't been initialised.`,"Please restart to use commands");return}if(mt.some(n=>n.name===e.name))throw new Error(`Command '${e.name}' already exists.`);if(e.isVencordCommand=!0,e.id??=`-${mt.length+1}`,e.applicationId??="-1",e.type??=1,e.inputType??=1,e.plugin||=t,qr(e),e.options?.[0]?.type===1){tu(e,t);return}Wr[e.name]=e,mt.push(e)}function un(e){let t=mt.findIndex(n=>n.name===e);return t===-1?!1:(mt.splice(t,1),delete Wr[e],!0)}var mt,Wr,yc,vc,ut,It,Vm,eu,be=m(()=>{"use strict";i();O();Kn();mn();Kn();mn();Wr={},yc=Symbol("OptionalMessageOption"),vc=Symbol("RequiredMessageOption"),ut=yc,It=vc,Vm=function(e){try{mt=e,ut=e.find(t=>t.name==="shrug").options[0],It=e.find(t=>t.name==="me").options[0]}catch{console.error("Failed to load CommandsApi")}return e},eu=function(e,t,n){if(!e.isVencordCommand)return e.execute(t,n);let r=s=>{let a=`An Error occurred while executing command "${e.name}"`,c=s instanceof Error?s.stack||s.message:String(s);console.error(a,s),U(n.channel.id,{content:`${a}: +${Gn(c)}`,author:{username:"Vencord"}})};try{let s=e.execute(t,n);return s instanceof Promise?s.catch(r):s}catch(s){return r(s)}}});var bc,Yr,Sc=m(()=>{"use strict";i();be();Kn();mn();x();T();L();bc=0,Yr=u({name:"CorruptMp4s",description:"Create corrupt mp4s with extremely high or negative duration",authors:[p.Ven],dependencies:["CommandsAPI"],commands:[{name:"corrupt",description:"Create a corrupt mp4 with extremely high or negative duration",inputType:0,options:[{name:"mp4",description:"the video to corrupt",type:11,required:!0},{name:"kind",description:"the kind of corruption",type:3,choices:[{name:"infinite",value:"infinite",label:"Very high duration"},{name:"negative",value:"negative",label:"Negative duration"}]}],execute:async(e,t)=>{let s=_e("getUploads").getUploads(t.channel.id,bc)[0]?.item?.file;if(s?.type!=="video/mp4")return void U(t.channel.id,{content:"Please upload a mp4 file"});let a=ce(e,"kind","infinite"),c=new Uint8Array(await s.arrayBuffer()),f=!1;for(let g=0;gv([h],t.channel,bc))}}]})});var Qr,xc=m(()=>{"use strict";i();be();mn();x();T();Qr=u({name:"UrbanDictionary",description:"Searches for a word on Urban Dictionary",authors:[p.jewdev],dependencies:["CommandsAPI"],commands:[{name:"urban",description:"Returns the definition of a word from Urban Dictionary",inputType:0,options:[{type:3,name:"word",description:"The word to search for on Urban Dictionary",required:!0}],execute:async(e,t)=>{try{let{list:[n]}=await(await fetch(`https://api.urbandictionary.com/v0/define?term=${e[0].value}`)).json();if(!n)return void U(t.channel.id,{content:"No results found."});let r=s=>s.replace(/\[(.+?)\]/g,(a,c)=>`[${c}](https://www.urbandictionary.com/define.php?term=${encodeURIComponent(c)})`);return void U(t.channel.id,{embeds:[{type:"rich",author:{name:`Definition of ${n.word}`,url:n.permalink},description:r(n.definition),fields:[{name:"Example",value:r(n.example)}],color:16750848,footer:{text:`\u{1F44D} ${n.thumbs_up.toString()} | \u{1F44E} ${n.thumbs_down.toString()} | Uploaded by ${n.author}`,icon_url:"https://www.urbandictionary.com/favicon.ico"},timestamp:new Date(n.written_on).toISOString()}]})}catch(n){return void U(t.channel.id,{content:`Something went wrong: \`${n}\``})}}}]})});var Jr,Tc=m(()=>{"use strict";i();T();Jr=u({name:"discord-screenaudio",authors:[{name:"maltejur",id:205966226709676032n}],required:!0,description:"UI patches for discord-screenaudio.",patches:[]})});function Xr({value:e,onChange:t,validate:n}){let[r,s]=b.useState(e),[a,c]=b.useState();function f(d){s(d);let v=n(d);v===!0?(c(void 0),t(d)):c(v)}return o(l,null,o(Le,{type:"text",value:r,onChange:f,error:a}))}var Zr=m(()=>{"use strict";i();k()});function ru(e){let t=G.getCurrentUser().id;return Object.values(qe.getGuilds()).filter(n=>{if(!(n.ownerId===t||BigInt(jo.getGuildPermissions({id:n.id})&wc)===wc))return!1;let s=n.getMaxEmojiSlots(),{emojis:a}=nu.getGuilds()[n.id],c=0;for(let f of a)f.animated===e&&c++;return cn.name.localeCompare(r.name))}async function iu(e,t,n,r){let s=await fetch(`https://cdn.discordapp.com/emojis/${t}.${r?"gif":"png"}`).then(c=>c.blob()),a=new FileReader;a.onload=()=>{ou({guildId:e,name:n,image:a.result}).then(()=>{A.show({message:`Successfully cloned ${n}!`,type:A.Type.SUCCESS,id:A.genId()})}).catch(c=>{new N("EmoteCloner").error("Failed to upload emoji",c),A.show({message:"Oopsie something went wrong :( Check console!!!",type:A.Type.FAILURE,id:A.genId()})})},a.readAsDataURL(s)}function cu({id:e,name:t,isAnimated:n}){let[r,s]=b.useState(!1),[a,c]=b.useState(t),[f,d]=b.useReducer(h=>h+1,0),v=b.useMemo(()=>ru(n),[n,f]);return o(l,null,o(y.FormTitle,{className:V.marginTop20},"Custom Name"),o(Xr,{value:a,onChange:c,validate:h=>h.length>1&&h.length<32&&au.test(h)||"Name must be between 2 and 32 characters and only contain alphanumeric characters"}),o("div",{style:{display:"flex",flexWrap:"wrap",gap:"1em",padding:"1em 0.5em",justifyContent:"center",alignItems:"center"}},v.map(h=>o(me,{text:h.name},({onMouseLeave:g,onMouseEnter:w})=>o("div",{onMouseLeave:g,onMouseEnter:w,role:"button","aria-label":"Clone to "+h.name,"aria-disabled":r,style:{borderRadius:"50%",backgroundColor:"var(--background-secondary)",display:"inline-flex",justifyContent:"center",alignItems:"center",width:"4em",height:"4em",cursor:r?"not-allowed":"pointer",filter:r?"brightness(50%)":"none"},onClick:r?void 0:async()=>{s(!0),iu(h.id,e,a,n).finally(()=>{d(),s(!1)})}},h.icon?o("img",{"aria-hidden":!0,style:{borderRadius:"50%",width:"100%",height:"100%"},src:h.getIconURL(512,!0),alt:h.name}):o(y.FormText,{style:{fontSize:su(h.acronym),width:"100%",overflow:"hidden",whiteSpace:"nowrap",textAlign:"center",cursor:r?"not-allowed":"pointer"}},h.acronym))))))}var wc,nu,ou,su,au,Vr,Pc=m(()=>{"use strict";i();R();Zr();x();le();O();Ye();T();L();k();wc=1n<<30n,nu=M("getGuilds","getGuildEmoji"),ou=re('"EMOJI_UPLOAD_START"',"GUILD_EMOJIS(");su=e=>[20,20,18,18,16,14,12][e.length]??4,au=/^\w+$/i;X("EmoteCloner","EmoteYoink");Vr=u({name:"EmoteCloner",description:"Adds a Clone context menu item to emotes to clone them your own server",authors:[p.Ven],dependencies:["MenuItemDeobfuscatorAPI"],patches:[{find:"open-native-link",replacement:{match:/id:"open-native-link".{0,200}\(\{href:(.{0,3}),.{0,200}\},"open-native-link"\)/,replace:"$&,Vencord.Plugins.plugins.EmoteCloner.makeMenu(arguments[2])"}},{find:"REMOVE_ALL_REACTIONS_CONFIRM_BODY,",predicate:Fe(()=>!S.plugins.ReverseImageSearch.enabled),noWarn:!0,replacement:{match:/(?.).onHeightUpdate.{0,200}(.)=(.)=.\.url;.+?\(null!=\3\?\3:\2[^)]+/,replace:"$&,$.target"}}],makeMenu(e){if(e?.dataset.type!=="emoji")return null;let{id:t}=e.dataset,n=e.alt.match(/:(.*)(?:~\d+)?:/)?.[1];if(!n||!t)return null;let r=new URL(e.src).pathname.endsWith(".gif");return o(ue.MenuItem,{id:"emote-cloner",key:"emote-cloner",label:"Clone",action:()=>we(s=>o(Be,{...s},o(nt,null,o("img",{role:"presentation","aria-hidden":!0,src:`https://cdn.discordapp.com/emojis/${t}.${r?"gif":"png"}`,alt:"",height:24,width:24,style:{marginRight:"0.5em"}}),o(y.FormText,null,"Clone ",n)),o(ot,null,o(cu,{id:t,name:n,isAnimated:r}))))})}})});var ei,ti,kc=m(()=>{"use strict";i();R();x();T();L();k();ei=M("key","removeBuildOverride"),ti=u({name:"Experiments",authors:[p.Megu,p.Ven,p.Nickyux,p.BanTheNons],description:"Enable Access to Experiments in Discord!",patches:[{find:"Object.defineProperties(this,{isDeveloper",replacement:{match:/(?<={isDeveloper:\{[^}]+,get:function\(\)\{return )\w/,replace:"true"}},{find:'type:"user",revision',replacement:{match:/(\w)\|\|"CONNECTION_OPEN".+?;/g,replace:"$1=!0;"}},{find:".isStaff=function(){",predicate:()=>S.plugins.Experiments.enableIsStaff===!0,replacement:[{match:/return\s*(\w+)\.hasFlag\((.+?)\.STAFF\)}/,replace:"return Vencord.Webpack.Common.UserStore.getCurrentUser().id===$1.id||$1.hasFlag($2.STAFF)}"},{match:/hasFreePremium=function\(\){return this.isStaff\(\)\s*\|\|/,replace:"hasFreePremium=function(){return "}]}],options:{enableIsStaff:{description:"Enable isStaff (requires restart)",type:3,default:!1,restartNeeded:!0}},settingsAboutComponent:()=>{let e=navigator.platform.includes("Mac"),t=e?"cmd":"ctrl",n=e?"opt":"alt";return o(b.Fragment,null,o(y.FormTitle,{tag:"h3"},"More Information"),o(y.FormText,{variant:"text-md/normal"},"You can enable client DevTools"," ",o("kbd",{className:ei.key},t)," +"," ",o("kbd",{className:ei.key},n)," +"," ",o("kbd",{className:ei.key},"O")," ","after enabling ",o("code",null,"isStaff")," below"),o(y.FormText,null,"and then toggling ",o("code",null,"Enable DevTools")," in the ",o("code",null,"Developer Options")," tab in settings."))}})});var Yn,Ic,lu,Mc,Rc,Qn=m(()=>{"use strict";i();O();Yn=Fe(()=>import("https://unpkg.com/gifenc@1.0.3/dist/gifenc.esm.js")),Ic=Fe(async()=>{let e={},t=new Proxy(window,{set:(n,r,s)=>e[r]=s});return Function("self",await fetch("https://cdnjs.cloudflare.com/ajax/libs/apng-canvas/2.1.1/apng-canvas.min.js").then(n=>n.text()))(t),e.APNG}),lu="https://unpkg.com/@vap/shiki-worker@0.0.8/dist",Mc=`${lu}/index.min.js`,Rc="https://unpkg.com/@vap/shiki@0.10.3/dist/onig.wasm"});var pu,du,ni,Cc=m(()=>{"use strict";i();pt();R();x();Qn();T();L();k();pu=0,du=re("UPLOAD_FILE_LIMIT_ERROR");X("FakeNitro","NitroBypass");ni=u({name:"FakeNitro",authors:[p.Arjix,p.D3SOX,p.Ven,p.obscurity],description:"Allows you to stream in nitro quality and send fake emojis/stickers.",dependencies:["MessageEventsAPI"],patches:[{find:"canUseAnimatedEmojis:function",predicate:()=>S.plugins.FakeNitro.enableEmojiBypass===!0,replacement:["canUseAnimatedEmojis","canUseEmojisEverywhere"].map(e=>({match:new RegExp(`${e}:function\\(.+?}`),replace:`${e}:function(e){return true;}`}))},{find:"canUseAnimatedEmojis:function",predicate:()=>S.plugins.FakeNitro.enableStickerBypass===!0,replacement:{match:/canUseStickersEverywhere:function\(.+?}/,replace:"canUseStickersEverywhere:function(e){return true;}"}},{find:'"SENDABLE"',predicate:()=>S.plugins.FakeNitro.enableStickerBypass===!0,replacement:{match:/(\w+)\.available\?/,replace:"true?"}},{find:"canUseAnimatedEmojis:function",predicate:()=>S.plugins.FakeNitro.enableStreamQualityBypass===!0,replacement:["canUseHighVideoUploadQuality","canStreamHighQuality","canStreamMidQuality"].map(e=>({match:new RegExp(`${e}:function\\(.+?}`),replace:`${e}:function(e){return true;}`}))},{find:"STREAM_FPS_OPTION.format",predicate:()=>S.plugins.FakeNitro.enableStreamQualityBypass===!0,replacement:{match:/(userPremiumType|guildPremiumTier):.{0,10}TIER_\d,?/g,replace:""}}],options:{enableEmojiBypass:{description:"Allow sending fake emojis",type:3,default:!0,restartNeeded:!0},emojiSize:{description:"Size of the emojis when sending",type:5,default:48,markers:[32,48,64,128,160,256,512]},enableStickerBypass:{description:"Allow sending fake stickers",type:3,default:!0,restartNeeded:!0},stickerSize:{description:"Size of the stickers when sending",type:5,default:160,markers:[32,64,128,160,256,512]},enableStreamQualityBypass:{description:"Allow streaming in nitro quality",type:3,default:!0,restartNeeded:!0}},get guildId(){return window.location.href.split("channels/")[1].split("/")[0]},get canUseEmotes(){return(G.getCurrentUser().premiumType??0)>0},get canUseStickers(){return(G.getCurrentUser().premiumType??0)>1},getStickerLink(e){return`https://media.discordapp.net/stickers/${e}.png?size=${S.plugins.FakeNitro.stickerSize}`},async sendAnimatedSticker(e,t,n){let[{parseURL:r},{GIFEncoder:s,quantize:a,applyPalette:c}]=await Promise.all([Ic(),Yn()]),{frames:f,width:d,height:v}=await r(e),h=new s,g=S.plugins.FakeNitro.stickerSize,w=document.createElement("canvas");w.width=g,w.height=g;let P=w.getContext("2d",{willReadFrequently:!0}),B=g/Math.max(d,v);P.scale(B,B);let _=null;for(let{left:C,top:q,width:se,height:de,disposeOp:Ie,img:ge,delay:Ge}of f){P.drawImage(ge,C,q,se,de);let{data:yt}=P.getImageData(0,0,g,g),Co=a(yt,256),Ia=c(yt,Co);h.writeFrame(Ia,g,g,{transparent:!0,palette:Co,delay:Ge}),Ie===1?P.clearRect(C,q,se,de):Ie===2&&_&&P.drawImage(_,C,q,se,de),_=ge}h.finish();let oe=new File([h.bytesView()],`${t}.gif`,{type:"image/gif"});du([oe],ae.getChannel(n),pu)},start(){let e=S.plugins.FakeNitro;if(!e.enableEmojiBypass&&!e.enableStickerBypass)return;let t=M("getCustomEmojiById"),n=M("getAllGuildStickers");function r(s,a){return!s[a]||/\s/.test(s[a])?"":" "}this.preSend=$e((s,a,c)=>{let{guildId:f}=this;e:{if(!e.enableStickerBypass)break e;let d=n.getStickerById(c?.stickerIds?.[0]);if(!d||d.available!==!1&&(this.canUseStickers||d?.guild_id===f))break e;let v=this.getStickerLink(d.id);if(d.format_type===2)return this.sendAnimatedSticker(this.getStickerLink(d.id),d.id,s),{cancel:!0};"pack_id"in d&&(v=`https://distok.top/stickers/${d.pack_id==="847199849233514549"?"749043879713701898":d.pack_id}/${d.id}.gif`),delete c.stickerIds,a.content+=" "+v}if(!this.canUseEmotes&&e.enableEmojiBypass)for(let d of a.validNonShortcutEmojis){if(!d.require_colons||d.guildId===f&&!d.animated)continue;let v=`<${d.animated?"a":""}:${d.originalName||d.name}:${d.id}>`,h=d.url.replace(/\?size=\d+/,`?size=${S.plugins.FakeNitro.emojiSize}`);a.content=a.content.replace(v,(g,w,P)=>`${r(P,w-1)}${h}${r(P,w+g.length)}`)}return{cancel:!1}}),!this.canUseEmotes&&e.enableEmojiBypass&&(this.preEdit=Pt((s,a,c)=>{let{guildId:f}=this;for(let[d,v,h]of c.content.matchAll(/(?/ig)){let g=t.getCustomEmojiById(h);if(g==null||g.guildId===f&&!g.animated||!g.require_colons)continue;let w=g.url.replace(/\?size=\d+/,`?size=${S.plugins.FakeNitro.emojiSize}`);c.content=c.content.replace(d,(P,B,_)=>`${r(_,B-1)}${w}${r(_,B+P.length)}`)}}))},stop(){Ue(this.preSend),kt(this.preEdit)}})});function Ac({option:e,pluginSettings:t,id:n,onChange:r,onError:s}){let a=t[n]??e.default,[c,f]=b.useState(a??!1),[d,v]=b.useState(null);b.useEffect(()=>{s(d!==null)},[d]);let h=[{label:"Enabled",value:!0,default:a===!0},{label:"Disabled",value:!1,default:typeof a>"u"||a===!1}];function g(w){let P=(e.isValid&&e.isValid(w))??!0;typeof P=="string"?v(P):P?(v(null),f(w),r(w)):v("Invalid input provided.")}return o(y.FormSection,null,o(y.FormTitle,null,e.description),o(St,{isDisabled:e.disabled?.()??!1,options:h,placeholder:e.placeholder??"Select an option",maxVisibleItems:5,closeOnSelect:!0,select:g,isSelected:w=>w===c,serialize:w=>String(w),...e.componentProps}),d&&o(y.FormText,{style:{color:"var(--text-danger)"}},d))}var _c=m(()=>{"use strict";i();k()});function Lc({option:e,onChange:t,onError:n}){return e.component({setValue:t,setError:n,option:e})}var Ec=m(()=>{"use strict";i()});function oi({option:e,pluginSettings:t,id:n,onChange:r,onError:s}){function a(g){return e.type===2?BigInt(g):Number(g)}let[c,f]=b.useState(`${t[n]??e.default??0}`),[d,v]=b.useState(null);b.useEffect(()=>{s(d!==null)},[d]);function h(g){let w=(e.isValid&&e.isValid(g))??!0;typeof w=="string"?v(w):w?e.type===1&&BigInt(g)>=mu?(f(`${Number.MAX_SAFE_INTEGER}`),r(a(g))):(f(g),r(a(g))):v("Invalid input provided.")}return o(y.FormSection,null,o(y.FormTitle,null,e.description),o(Le,{type:"number",pattern:"-?[0-9]+",value:c,onChange:h,placeholder:e.placeholder??"Enter a number",disabled:e.disabled?.()??!1,...e.componentProps}),d&&o(y.FormText,{style:{color:"var(--text-danger)"}},d))}var mu,Fc=m(()=>{"use strict";i();T();k();mu=BigInt(Number.MAX_SAFE_INTEGER)});function Dc({option:e,pluginSettings:t,onChange:n,onError:r,id:s}){let a=t[s]??e.options?.find(g=>g.default)?.value,[c,f]=b.useState(a??null),[d,v]=b.useState(null);b.useEffect(()=>{r(d!==null)},[d]);function h(g){let w=(e.isValid&&e.isValid(g))??!0;typeof w=="string"?v(w):w?(f(g),n(g)):v("Invalid input provided.")}return o(y.FormSection,null,o(y.FormTitle,null,e.description),o(St,{isDisabled:e.disabled?.()??!1,options:e.options,placeholder:e.placeholder??"Select an option",maxVisibleItems:5,closeOnSelect:!0,select:h,isSelected:g=>g===c,serialize:g=>String(g),...e.componentProps}),d&&o(y.FormText,{style:{color:"var(--text-danger)"}},d))}var Nc=m(()=>{"use strict";i();k()});function Ot(e,t,n=1){let r=[];for(let s=e;s<=t;s+=n)r.push(Math.round(s*100)/100);return r}function Oc({option:e,pluginSettings:t,id:n,onChange:r,onError:s}){let a=t[n]??e.default,[c,f]=b.useState(null);b.useEffect(()=>{s(c!==null)},[c]);function d(v){let h=(e.isValid&&e.isValid(v))??!0;typeof h=="string"?f(h):h?(f(null),r(v)):f("Invalid input provided.")}return o(y.FormSection,null,o(y.FormTitle,null,e.description),o(qo,{disabled:e.disabled?.()??!1,markers:e.markers,minValue:e.markers[0],maxValue:e.markers[e.markers.length-1],initialValue:a,onValueChange:d,onValueRender:v=>String(v.toFixed(2)),stickToMarkers:e.stickToMarkers??!0,...e.componentProps}))}var Jn=m(()=>{"use strict";i();k()});function Bc({option:e,pluginSettings:t,id:n,onChange:r,onError:s}){let[a,c]=b.useState(t[n]??e.default??null),[f,d]=b.useState(null);b.useEffect(()=>{s(f!==null)},[f]);function v(h){let g=(e.isValid&&e.isValid(h))??!0;typeof g=="string"?d(g):g?(c(h),r(h)):d("Invalid input provided.")}return o(y.FormSection,null,o(y.FormTitle,null,e.description),o(Le,{type:"text",value:a,onChange:v,placeholder:e.placeholder??"Enter a value",disabled:e.disabled?.()??!1,...e.componentProps}),f&&o(y.FormText,{style:{color:"var(--text-danger)"}},f))}var $c=m(()=>{"use strict";i();k()});var ri=m(()=>{"use strict";i();_c();Ec();Fc();Nc();Jn();$c()});var ii,Uc=m(()=>{"use strict";i();be();R();ri();x();T();ii=u({name:"Fart2",authors:[p.Animal],description:"Enable farting v2, a slash command that allows you to perform or request that someone perform a little toot.",dependencies:["CommandsAPI"],commands:[{name:"fart",description:"A simple command in which you may either request that a user do a little toot for you, or conduct one yourself.",options:[{type:6,name:"user",description:"A Discord\u2122 user of which you would humbly request a toot from.",required:!1}],execute(e){let t=new Audio("https://raw.githubusercontent.com/ItzOnlyAnimal/AliuPlugins/main/fart.mp3");return t.volume=S.plugins.Fart2.volume,t.play(),{content:e[0]?`<@${e[0].value}> fart`:"fart"}}}],options:{volume:{description:"how loud you wanna fart (aka volume)",type:5,markers:Ot(0,1,.1),default:.5,stickToMarkers:!1}}})});var Hc,si,jc=m(()=>{"use strict";i();x();T();L();$(["getGuild"],e=>Hc=e);si=u({name:"ForceOwnerCrown",description:"Force the owner crown next to usernames even if the server is large.",authors:[p.D3SOX,p.Nickyux],patches:[{find:".renderOwner=",replacement:{match:/isOwner;return null!=(\w+)?&&/g,replace:"isOwner;if(Vencord.Plugins.plugins.ForceOwnerCrown.isGuildOwner(this.props)){$1=true;}return null!=$1&&"}}],isGuildOwner(e){if(e?.channel?.type===3)return!1;let t=e?.guildId??e?.channel?.guild_id,n=e?.user?.id;if(t&&n){let r=Hc.getGuild(t);if(r)return r.ownerId===n;console.error("[ForceOwnerCrown] failed to get guild",{guildId:t,guild:r,props:e})}else console.error("[ForceOwnerCrown] no guildId or userId",{guildId:t,userId:n,props:e});return!1}})});var ai,Gc=m(()=>{"use strict";i();be();x();T();L();ai=u({name:"FriendInvites",description:"Generate and manage friend invite links.",authors:[p.afn],dependencies:["CommandsAPI"],commands:[{name:"create friend invite",description:"Generates a friend invite link.",inputType:3,execute:async(e,t)=>{let r=await _e("createFriendInvite").createFriendInvite();return void U(t.channel.id,{content:` + discord.gg/${r.code} + Expires: + Max uses: \`${r.max_uses}\` + `.trim().replace(/\s+/g," ")})}},{name:"view friend invites",description:"View a list of all generated friend invites.",inputType:3,execute:async(e,t)=>{let s=(await _e("createFriendInvite").getAllFriendInvites()).map(a=>`_discord.gg/${a.code}_ + Expires: + Times used: \`${a.uses}/${a.max_uses}\``.trim().replace(/\s+/g," "));return void U(t.channel.id,{content:s.join(` + +`)||"You have no active friend invites!"})}},{name:"revoke friend invites",description:"Revokes ALL generated friend invite links.",inputType:3,execute:async(e,t)=>(await _e("createFriendInvite").revokeFriendInvites(),void U(t.channel.id,{content:"All friend links have been revoked."}))}]})});var uu,ci,zc=m(()=>{"use strict";i();pt();x();T();uu=/https?:\/\/twitter\.com(?=\/\w+?\/status\/)/g,ci=u({name:"FxTwitter",description:"Uses FxTwitter to improve embeds from twitter on send",authors:[p.Samu],dependencies:["MessageEventsAPI"],addPrefix(e){e.content=e.content.replace(uu,"https://fxtwitter.com")},start(){this.preSend=$e((e,t)=>this.addPrefix(t))},stop(){Ue(this.preSend)}})});var Bt={};ee(Bt,{clear:()=>bu,createStore:()=>Wc,del:()=>yu,delMany:()=>vu,entries:()=>Tu,get:()=>Je,getMany:()=>gu,keys:()=>Su,promisifyRequest:()=>he,set:()=>Re,setMany:()=>fu,update:()=>hu,values:()=>xu});function he(e){return new Promise((t,n)=>{e.oncomplete=e.onsuccess=()=>t(e.result),e.onabort=e.onerror=()=>n(e.error)})}function Wc(e,t){let n=indexedDB.open(e);n.onupgradeneeded=()=>n.result.createObjectStore(t);let r=he(n);return(s,a)=>r.then(c=>a(c.transaction(t,s).objectStore(t)))}function He(){return li||(li=Wc("VencordData","VencordStore")),li}function Je(e,t=He()){return t("readonly",n=>he(n.get(e)))}function Re(e,t,n=He()){return n("readwrite",r=>(r.put(t,e),he(r.transaction)))}function fu(e,t=He()){return t("readwrite",n=>(e.forEach(r=>n.put(r[1],r[0])),he(n.transaction)))}function gu(e,t=He()){return t("readonly",n=>Promise.all(e.map(r=>he(n.get(r)))))}function hu(e,t,n=He()){return n("readwrite",r=>new Promise((s,a)=>{r.get(e).onsuccess=function(){try{r.put(t(this.result),e),s(he(r.transaction))}catch(c){a(c)}}}))}function yu(e,t=He()){return t("readwrite",n=>(n.delete(e),he(n.transaction)))}function vu(e,t=He()){return t("readwrite",n=>(e.forEach(r=>n.delete(r)),he(n.transaction)))}function bu(e=He()){return e("readwrite",t=>(t.clear(),he(t.transaction)))}function pi(e,t){return e.openCursor().onsuccess=function(){!this.result||(t(this.result),this.result.continue())},he(e.transaction)}function Su(e=He()){return e("readonly",t=>{if(t.getAllKeys)return he(t.getAllKeys());let n=[];return pi(t,r=>n.push(r.key)).then(()=>n)})}function xu(e=He()){return e("readonly",t=>{if(t.getAll)return he(t.getAll());let n=[];return pi(t,r=>n.push(r.value)).then(()=>n)})}function Tu(e=He()){return e("readonly",t=>{if(t.getAll&&t.getAllKeys)return Promise.all([he(t.getAllKeys()),he(t.getAll())]).then(([r,s])=>r.map((a,c)=>[a,s[c]]));let n=[];return e("readonly",r=>pi(r,s=>n.push([s.key,s.value])).then(()=>n))})}var li,$t=m(()=>{"use strict";i();});var di={};ee(di,{_buildPopoverElements:()=>Pu,addButton:()=>Mt,buttons:()=>Xn,removeButton:()=>Rt});function Mt(e,t){Xn.set(e,t)}function Rt(e){Xn.delete(e)}function Pu(e,t){let n=[];for(let[r,s]of Xn.entries())try{let a=s(e);a&&(a.key??=r,n.push(t(a)))}catch(a){wu.error(`[${r}]`,a)}return n}var wu,Xn,fn=m(()=>{"use strict";i();le();wu=new N("MessagePopover"),Xn=new Map});var gn,Kc,ku,Iu,hn,qc,Mu,mi,Yc=m(()=>{"use strict";i();$t();fn();x();T();k();Kc="HideAttachments_HiddenIds",ku=()=>o("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true"},o("path",{d:"M5 21q-.825 0-1.413-.587Q3 19.825 3 19V5q0-.825.587-1.413Q4.175 3 5 3h14q.825 0 1.413.587Q21 4.175 21 5v14q0 .825-.587 1.413Q19.825 21 19 21Zm0-2h14V5H5v14Zm1-2h12l-3.75-5-3 4L9 13Zm-1 2V5v14Z"})),Iu=()=>o("svg",{viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true"},o("path",{d:"m21 18.15-2-2V5H7.85l-2-2H19q.825 0 1.413.587Q21 4.175 21 5Zm-1.2 4.45L18.2 21H5q-.825 0-1.413-.587Q3 19.825 3 19V5.8L1.4 4.2l1.4-1.4 18.4 18.4ZM6 17l3-4 2.25 3 .825-1.1L5 7.825V19h11.175l-2-2Zm7.425-6.425ZM10.6 13.4Z"})),hn=new Set,qc=()=>Je(Kc).then(e=>(hn=e??new Set,hn)),Mu=e=>Re(Kc,e),mi=u({name:"HideAttachments",description:"Hide attachments and Embeds for individual messages via hover button",authors:[p.Ven],dependencies:["MessagePopoverAPI"],async start(){gn=document.createElement("style"),gn.id="VencordHideAttachments",document.head.appendChild(gn),await qc(),await this.buildCss(),Mt("HideAttachments",e=>{if(!e.attachments.length&&!e.embeds.length)return null;let t=hn.has(e.id);return{label:t?"Show Attachments":"Hide Attachments",icon:t?ku:Iu,message:e,channel:ae.getChannel(e.channel_id),onClick:()=>this.toggleHide(e.id)}})},stop(){gn.remove(),hn.clear(),Rt("HideAttachments")},async buildCss(){let e=[...hn].map(t=>`#message-accessories-${t}`).join(",");gn.textContent=` + :is(${e}) [class*="embedWrapper"] { + /* important is not necessary, but add it to make sure bad themes won't break it */ + display: none !important; + } + :is(${e})::after { + content: "Attachments hidden"; + color: var(--text-muted); + font-size: 80%; + } + `},async toggleHide(e){let t=await qc();t.delete(e)||t.add(e),await Mu(t),await this.buildCss(),I.dispatch({type:"MESSAGE_UPDATE",message:{id:e}})}})});var ui,Qc=m(()=>{"use strict";i();x();T();ui=u({name:"iLoveSpam",description:"Do not hide messages from 'likely spammers'",authors:[p.botato,p.Animal],patches:[{find:"),{hasFlag:",replacement:{match:/(if\((.{1,2})<=1<<30\)return)/,replace:"if($2===(1<<20)){return false};$1"}}]})});var fi,Se,gi,Jc=m(()=>{"use strict";i();$t();x();T();L();fi=M("IgnoreActivities_reRenderGames"),Se=[],gi=u({name:"IgnoreActivities",authors:[p.Nuckyz],description:"Ignore certain activities (like games) from showing up on your status. You can configure which ones are ignored from the Registered Games tab.",patches:[{find:".Messages.SETTINGS_GAMES_OVERLAY_ON",replacement:[{match:/;(.\.renderOverlayToggle=function\(\).+?\)};)/,replace:(e,t)=>{let n=[{match:/,.{1,2}=.{1,2}\.overlayWarn/,replace:""},{match:/,.{1,2}=.{1,2}\?\(0,.{1,2}\.jsx\)\(.{1,20}Messages\.SETTINGS_GAMES_OVERLAY_WARNING.{1,100}null/,replace:""},{match:/,.{1,2}=.{1,2}\?.{1,50}Messages\.SETTINGS_GAMES_OVERLAY_OFF/,replace:""},{match:/[^[]{1,2},\(0,.{1,2}\.jsx\)\("div".{1,20}\(\)\.overlayStatusText.+}\),/,replace:""},{match:/renderOverlayToggle/,replace:"renderIgnoreActivitiesToggle"},{match:/((.)=this\.props\.game)(.{1,70})=.{1,2}overlay/,replace:"$1,IgnoreActivities_gameProps=$2$3=Vencord.Plugins.plugins.IgnoreActivities.isActivityEnabled(IgnoreActivities_gameProps)"},{match:/.\.handleOverlayToggle/,replace:"() => Vencord.Plugins.plugins.IgnoreActivities.handleActivityToggle(IgnoreActivities_gameProps)"},{match:/(\(0,.{1,2}\.jsx\)\()(.{2})\..(.{1,50}\.overlayToggleIconOn)/,replace:"$1$2.IgnoreActivities_toggleOn$3"},{match:/(\(0,.{1,2}\.jsx\)\()(.{2})\..{1}(.{1,50}\.overlayToggleIconOff)/,replace:"$1$2.IgnoreActivities_toggleOff$3"},{match:/text:.{2}\..\.Messages\.SETTINGS_GAMES_TOGGLE_OVERLAY/,replace:'text:"Toggle activity"'},{match:/"aria-label":.{2}\..\.Messages\.SETTINGS_GAMES_TOGGLE_OVERLAY/,replace:'"aria-label":"Toggle activity"'}].reduce((r,{match:s,replace:a})=>r.replace(s,a),t);return`;${t}${n}`}},{match:/(this.renderLastPlayed\(\)]}\),this.renderOverlayToggle\(\))/,replace:"$1,this.renderIgnoreActivitiesToggle()"}]},{find:'.displayName="RunningGameStore"',replacement:{match:/(.:\(\)=>.{2})(.+function (.{2})\(\){.+\.dispatch\({type:"RUNNING_GAMES_CHANGE")/,replace:"$1,IgnoreActivities_reRenderGames:()=>$3$2"}},{find:"M8.67872 19H11V21H7V23H17V21H13V19H20C21.103 19 22 18.104 22 17V6C22 5.89841 21.9924 5.79857 21.9777 5.70101L20 7.67872V15H12.6787L8.67872 19ZM13.1496 6H4V15H4.14961L2.00515 17.1445C2.00174 17.0967 2 17.0486 2 17V6C2 4.897 2.897 4 4 4H15.1496L13.1496 6Z",replacement:{match:/(.:\(\)=>.)(.+)(function (.)\(.{1,10}\.width.+\)\)})/s,replace:(e,t,n,r)=>{let s=[{match:/function ./,replace:"function IgnoreActivities_toggleOffToExport"},{match:/M8.67872 19H11V21H7V23H17V21H13V19H20C21.103 19 22 18.104 22 17V6C22 5.89841 21.9924 5.79857 21.9777 5.70101L20 7.67872V15H12.6787L8.67872 19ZM13.1496 6H4V15H4.14961L2.00515 17.1445C2.00174 17.0967 2 17.0486 2 17V6C2 4.897 2.897 4 4 4H15.1496L13.1496 6Z/,replace:"M 16 8 C 7.664063 8 1.25 15.34375 1.25 15.34375 L 0.65625 16 L 1.25 16.65625 C 1.25 16.65625 7.097656 23.324219 14.875 23.9375 C 15.246094 23.984375 15.617188 24 16 24 C 16.382813 24 16.753906 23.984375 17.125 23.9375 C 24.902344 23.324219 30.75 16.65625 30.75 16.65625 L 31.34375 16 L 30.75 15.34375 C 30.75 15.34375 24.335938 8 16 8 Z M 16 10 C 18.203125 10 20.234375 10.601563 22 11.40625 C 22.636719 12.460938 23 13.675781 23 15 C 23 18.613281 20.289063 21.582031 16.78125 21.96875 C 16.761719 21.972656 16.738281 21.964844 16.71875 21.96875 C 16.480469 21.980469 16.242188 22 16 22 C 15.734375 22 15.476563 21.984375 15.21875 21.96875 C 11.710938 21.582031 9 18.613281 9 15 C 9 13.695313 9.351563 12.480469 9.96875 11.4375 L 9.9375 11.4375 C 11.71875 10.617188 13.773438 10 16 10 Z M 16 12 C 14.34375 12 13 13.34375 13 15 C 13 16.65625 14.34375 18 16 18 C 17.65625 18 19 16.65625 19 15 C 19 13.34375 17.65625 12 16 12 Z M 7.25 12.9375 C 7.09375 13.609375 7 14.285156 7 15 C 7 16.753906 7.5 18.394531 8.375 19.78125 C 5.855469 18.324219 4.105469 16.585938 3.53125 16 C 4.011719 15.507813 5.351563 14.203125 7.25 12.9375 Z M 24.75 12.9375 C 26.648438 14.203125 27.988281 15.507813 28.46875 16 C 27.894531 16.585938 26.144531 18.324219 23.625 19.78125 C 24.5 18.394531 25 16.753906 25 15 C 25 14.285156 24.90625 13.601563 24.75 12.9375 Z"},{match:/viewBox:"0 0 24 24"/,replace:'viewBox:"0 0 32 26"'},{match:/x:"2"/,replace:'x:"3"'},{match:/y:"20"/,replace:'y:"26"'}].reduce((a,{match:c,replace:f})=>a.replace(c,f),r);return`${t},IgnoreActivities_toggleOff:()=>IgnoreActivities_toggleOffToExport${n}${r}${s}`}}},{find:"M4 2.5C2.897 2.5 2 3.397 2 4.5V15.5C2 16.604 2.897 17.5 4 17.5H11V19.5H7V21.5H17V19.5H13V17.5H20C21.103 17.5 22 16.604 22 15.5V4.5C22 3.397 21.103 2.5 20 2.5H4ZM20 4.5V13.5H4V4.5H20Z",replacement:{match:/(.:\(\)=>.)(.+)(function (.)\(.{1,10}\.width.+\)\)})/,replace:(e,t,n,r)=>{let s=[{match:/function ./,replace:"function IgnoreActivities_toggleOnToExport"},{match:/M4 2.5C2.897 2.5 2 3.397 2 4.5V15.5C2 16.604 2.897 17.5 4 17.5H11V19.5H7V21.5H17V19.5H13V17.5H20C21.103 17.5 22 16.604 22 15.5V4.5C22 3.397 21.103 2.5 20 2.5H4ZM20 4.5V13.5H4V4.5H20Z/,replace:"M 16 8 C 7.664063 8 1.25 15.34375 1.25 15.34375 L 0.65625 16 L 1.25 16.65625 C 1.25 16.65625 7.097656 23.324219 14.875 23.9375 C 15.246094 23.984375 15.617188 24 16 24 C 16.382813 24 16.753906 23.984375 17.125 23.9375 C 24.902344 23.324219 30.75 16.65625 30.75 16.65625 L 31.34375 16 L 30.75 15.34375 C 30.75 15.34375 24.335938 8 16 8 Z M 16 10 C 18.203125 10 20.234375 10.601563 22 11.40625 C 22.636719 12.460938 23 13.675781 23 15 C 23 18.613281 20.289063 21.582031 16.78125 21.96875 C 16.761719 21.972656 16.738281 21.964844 16.71875 21.96875 C 16.480469 21.980469 16.242188 22 16 22 C 15.734375 22 15.476563 21.984375 15.21875 21.96875 C 11.710938 21.582031 9 18.613281 9 15 C 9 13.695313 9.351563 12.480469 9.96875 11.4375 L 9.9375 11.4375 C 11.71875 10.617188 13.773438 10 16 10 Z M 16 12 C 14.34375 12 13 13.34375 13 15 C 13 16.65625 14.34375 18 16 18 C 17.65625 18 19 16.65625 19 15 C 19 13.34375 17.65625 12 16 12 Z M 7.25 12.9375 C 7.09375 13.609375 7 14.285156 7 15 C 7 16.753906 7.5 18.394531 8.375 19.78125 C 5.855469 18.324219 4.105469 16.585938 3.53125 16 C 4.011719 15.507813 5.351563 14.203125 7.25 12.9375 Z M 24.75 12.9375 C 26.648438 14.203125 27.988281 15.507813 28.46875 16 C 27.894531 16.585938 26.144531 18.324219 23.625 19.78125 C 24.5 18.394531 25 16.753906 25 15 C 25 14.285156 24.90625 13.601563 24.75 12.9375 Z"},{match:/viewBox:"0 0 24 24"/,replace:'viewBox:"0 0 32 26"'}].reduce((a,{match:c,replace:f})=>a.replace(c,f),r);return`${t},IgnoreActivities_toggleOn:()=>IgnoreActivities_toggleOnToExport${n}${r}${s}`}}},{find:'.displayName="LocalActivityStore"',replacement:{match:/((.)\.push\(.\({type:.\..{1,3}\.LISTENING.+?;)/,replace:"$1$2=$2.filter(Vencord.Plugins.plugins.IgnoreActivities.isActivityEnabled);"}}],async start(){if(Se=await Je("IgnoreActivities_ignoredActivities")??[],Se.length!==0){let e=fi.Z.getGamesSeen();for(let[t,n]of Se.entries())e.some(r=>r.id!==void 0&&r.id===n||r.exePath===n)||Se.splice(t,1);await Re("IgnoreActivities_ignoredActivities",Se)}},isActivityEnabled(e){if("type"in e){if(e.application_id!==void 0)return!Se.includes(e.application_id);{let t=fi.Z.getRunningGames().find(n=>n.name===e.name)?.exePath;if(t)return!Se.includes(t)}}else if("exePath"in e)return e.id!==void 0?!Se.includes(e.id):!Se.includes(e.exePath);return!0},async handleActivityToggle(e){let t=e.id??e.exePath;t!==void 0&&(Se.includes(t)?Se.splice(Se.indexOf(t,1)):Se.push(t),fi.IgnoreActivities_reRenderGames(),await Re("IgnoreActivities_ignoredActivities",Se))}})});var hi,Xc=m(()=>{"use strict";i();$t();x();T();k();hi=u({name:"KeepCurrentChannel",description:"Attempt to navigate the channel you were in before switching accounts or loading Discord.",authors:[p.Nuckyz],isSwitchingAccount:!1,previousCache:{},attemptToNavigateToChannel(e,t){!ae.hasChannel(t)||Ko.transitionTo(`/channels/${e??"@me"}/${t}`)},onLogout(e){this.isSwitchingAccount=e.isSwitchingAccount},onConnectionOpen(){!this.isSwitchingAccount||(this.isSwitchingAccount=!1,this.previousCache.channelId&&this.attemptToNavigateToChannel(this.previousCache.guildId,this.previousCache.channelId))},async onChannelSelect({guildId:e,channelId:t}){this.isSwitchingAccount||(this.previousCache={guildId:e,channelId:t},await Re("KeepCurrentChannel_previousData",this.previousCache))},async start(){let e=await Je("KeepCurrentChannel_previousData");e?(this.previousCache=e,this.previousCache.channelId&&this.attemptToNavigateToChannel(this.previousCache.guildId,this.previousCache.channelId)):(this.previousCache={guildId:Un.getGuildId(),channelId:pe.getChannelId()??null},await Re("KeepCurrentChannel_previousData",this.previousCache)),I.subscribe("LOGOUT",this.onLogout.bind(this)),I.subscribe("CONNECTION_OPEN",this.onConnectionOpen.bind(this)),I.subscribe("CHANNEL_SELECT",this.onChannelSelect.bind(this))},stop(){I.unsubscribe("LOGOUT",this.onLogout),I.unsubscribe("CONNECTION_OPEN",this.onConnectionOpen),I.unsubscribe("CHANNEL_SELECT",this.onChannelSelect)}})});async function yi(e){return(await Cu.getAsset(bi,[e,void 0]))[0]}function vi(e){I.dispatch({type:"LOCAL_ACTIVITY_UPDATE",activity:e})}var bi,Ru,Cu,Si,Zc=m(()=>{"use strict";i();R();wt();x();T();L();k();bi="1043533871037284423",Ru=M("getLocalPresence"),Cu=Me("getAssetImage: size must === [number, number] for Twitch",{getAsset:E.byCode("apply(")});Si=u({name:"LastFMRichPresence",description:"Little plugin for Last.fm rich presence",authors:[p.dzshn],settingsAboutComponent:()=>o(l,null,o(y.FormTitle,{tag:"h3"},"How to get an API key"),o(y.FormText,null,"An API key is required to fetch your current track. To get one, you can visit ",o(Pe,{href:"https://www.last.fm/api/account/create"},"this page")," and fill in the following information: ",o("br",null)," ",o("br",null),"Application name: Discord Rich Presence ",o("br",null),"Application description: (personal use) ",o("br",null)," ",o("br",null),"And copy the API key (not the shared secret!)")),options:{username:{description:"last.fm username",type:0},apiKey:{description:"last.fm api key",type:0},hideWithSpotify:{description:"hide last.fm presence if spotify is running",type:3,default:!0},useListeningStatus:{description:'show "Listening to" status instead of "Playing"',type:3,default:!1}},start(){this.settings=S.plugins.LastFMRichPresence,this.updateInterval=setInterval(()=>{this.updatePresence()},16e3)},stop(){clearInterval(this.updateInterval)},async fetchTrackData(){if(!this.settings.username||!this.settings.apiKey)return null;let t=(await(await fetch(`https://ws.audioscrobbler.com/2.0/?method=user.getrecenttracks&api_key=${this.settings.apiKey}&user=${this.settings.username}&limit=1&format=json`)).json()).recenttracks.track[0];return t["@attr"]?.nowplaying?{name:t.name||"Unknown",album:t.album["#text"],artist:t.artist["#text"]||"Unknown",url:t.url,imageUrl:(t.image||[]).filter(n=>n.size==="large")[0]?.["#text"]}:null},async updatePresence(){if(this.settings.hideWithSpotify){for(let r of Ru.getActivities())if(r.type===2&&r.application_id!==bi){vi();return}}let e=await this.fetchTrackData();if(!e){vi();return}let t=!e.album||e.album===e.name,n;e.imageUrl?n={large_image:await yi(e.imageUrl),large_text:e.name,small_image:await yi("lastfm-small"),small_text:"Last.fm"}:n={large_image:await yi("lastfm-large"),large_text:"Last.fm"},vi({application_id:bi,name:"some music",details:e.name,state:t?e.artist:`${e.artist} - ${e.album}`,assets:n,buttons:["Open in Last.fm"],metadata:{button_urls:[e.url]},type:this.settings.useListeningStatus?2:0,flags:1})}})});var Vc,xi,el=m(()=>{"use strict";i();x();T();Vc=["Eyrokac","Rdcg$l`'k|~n",'H`tf$d&iajo+d`{"',"Sucqplh`(Eclhualva()&","Lncgmka'8KNMDC,shpanf'`x./,","Ioqweijnfn*IeuvfvAotkfxo./,","Hd{#cp\x7Ft$)nbd!{lq%mig~*\x7Fh`v#mk&sm{gx nd#idjb(a\x7Ffao\"bja&amdkge!Rlo\xECkhf)hyedfjjb*'^hzdrdmm$lu'|ao+mnqw$fijxh~bbmg#Tjm\xEEefd+fnp#lpkffz5","h",`sijklm&cam*rot"hjjq'|ak\x7F xmv#wc'ep*mawmvvlrb(|ynr>"Aqq&cgg-\x7F ugoh%rom)e\x7Fhdpp%$`,'Tnfb}"u\'~`nno!kp$vvhfzeyee"a}%Tfam*Xh`fls%Jboldos-"lj`&hn)~ce!`jcbct|)gdbhnf$wikm$zgaxkmc%afely+og"144?\'ign+iu%p$qisiefr gpfa$',"Ndtfv%ahfgk+ghtf$|ir(|z' Oguaw&`ggdj mgw$|ir(me|n","(!\u0363\xB3$\u0359\u0290'\u0369\xB9#","(\uFF88\u25D7\u30ED\u25D1,\uFF8F-2\uFF6C\uFF95\u272C","Ynw#hjil(ze+psgwp|&sgmkr!","Tikmolh`(fl+a!dvjk\x7F'y|e\x7Fe/,-","3/3750?5><9>885:7","mdmt","Wdn`khc+(oxbeof","Ig\"zkp*'g{*xolglj`&~g|*gowg/$mgt(Eclm`.#ticf{l*xed\"wl`&Kangj igbhqn'd`dn `v#lqrw{3%$bhv-h|)kangj_imwhlhb","Tscmw%Tnoa~x",'I\u2018f#npus(ec`e!vl$lhsm{`ncu"ekw&f(defeov-$Rnf|)sdu\u2018pf$wcam{ceg!vl$du\'D`d~x-"jw%oi(okht-"DJP)Kag\x7Fs,!mq$du\'A\u2010|n sg`akrkq)~jkdl#pj&diefbnf"jp)&@F\\*{ltq#Hlhrp\'',"Ynw$v`&cg`dl fml`%rhlhs*","Dnl$p%qhz{s' hv$w%hh|aceg!;#gpvt(fl+cndea`&dg|fon&v#wjjqm(","\uD83D)pft`gs(ec`e!13$qojmz#",`a!njcmr'ide~nu"lb%rheoedldpz$lu'gbkr`,'dn"zkp&kg\x7Fo4',"hnpqkw",'sn"fau\x7F','Sn"tmqnh}}*musvkaw&flf&+ldv$w%lr{}*aulr#vlao|)cetn"jp$',"Dxkmc%ot(hhxomwwai\x7F'{hln",`hd{#}js&(pe~'sg#gprb(3#"`,"hd{b${","<;vqkijbq33271:56<3799?24944:",`Thof$lu'ofdn,!qsefc'az*bnrcma+&Om{o+iu"\`khct$)bnrd"bcdoi&`,"snofplkb{)c\x7F'r\"lod\x7F'|f*aurv#cpno`abchijklmno"],xi=u({name:"LoadingQuotes",description:"Replace Discords loading quotes",authors:[p.Ven,p.KraXen72],patches:[{find:".LOADING_DID_YOU_KNOW",replacement:{match:/\._loadingText=.+?random\(.+?;/s,replace:"._loadingText=Vencord.Plugins.plugins.LoadingQuotes.quote;"}}],xor(e){let t="read if cute",n=Array.from(e,(r,s)=>r.charCodeAt(0)^s%t.length);return String.fromCharCode(...n)},get quote(){return this.xor(Vc[Math.floor(Math.random()*Vc.length)])}})});var Ti={};ee(Ti,{getCurrentChannel:()=>Zn,getCurrentGuild:()=>Au,openPrivateChannel:()=>_u});function Zn(){return ae.getChannel(pe.getChannelId())}function Au(){return qe.getGuild(Zn()?.guild_id)}function _u(e){Go.openPrivateChannel(e)}var wi=m(()=>{"use strict";i();k()});function Lu(){let e=Zn().guild_id,t=Pi[e];if(tl=ct(),!t)return null;let n=String(t[0]);return n==="0"&&t[1]>0&&(n="Loading..."),o(Z,{id:"vc-membercount",style:{marginTop:"1em",marginBottom:"-.5em",paddingInline:"1em",justifyContent:"center",alignContent:"center",gap:0}},o(me,{text:`${t[1]} Online`,position:"bottom"},r=>o("div",{...r},o("span",{style:{backgroundColor:"var(--status-green-600)",width:"12px",height:"12px",borderRadius:"50%",display:"inline-block",marginRight:"0.5em"}}),o("span",{style:{color:"var(--status-green-600)"}},t[1]))),o(me,{text:`${t[0]||"?"} Total Members`,position:"bottom"},r=>o("div",{...r},o("span",{style:{width:"6px",height:"6px",borderRadius:"50%",border:"3px solid var(--status-grey-500)",display:"inline-block",marginRight:"0.5em",marginLeft:"1em"}}),o("span",{style:{color:"var(--status-grey-500)"}},n))))}var Pi,tl,ki,nl=m(()=>{"use strict";i();ne();Ne();x();wi();O();T();k();Pi={};ki=u({name:"MemberCount",description:"Shows the amount of online & total members in the server member list",authors:[p.Ven],patches:[{find:".isSidebarVisible,",replacement:{match:/(var (.)=.\.className.+?children):\[(.\.useMemo[^}]+"aria-multiselectable")/,replace:"$1:[$2.startsWith('members')?Vencord.Plugins.plugins.MemberCount.render():null,$3"}}],onGuildMemberListUpdate({guildId:e,groups:t,memberCount:n,id:r}){if(r!=="everyone"&&Pi[e])return;let s=0;for(let a of t)a.id!=="offline"&&(s+=a.count);Pi[e]=[n,s],tl?.()},start(){I.subscribe("GUILD_MEMBER_LIST_UPDATE",this.onGuildMemberListUpdate)},stop(){I.unsubscribe("GUILD_MEMBER_LIST_UPDATE",this.onGuildMemberListUpdate)},render:()=>o(D,{noop:!0},o(Lu,null))})});var Ii,ol,rl,Mi,il=m(()=>{"use strict";i();pt();R();x();T();L();k();Ii=!1,ol=e=>e.key==="Backspace"&&(Ii=!0),rl=e=>e.key==="Backspace"&&(Ii=!1);X("MessageClickActions","MessageQuickActions");Mi=u({name:"MessageClickActions",description:"Hold Delete and click to delete, double click to edit",authors:[p.Ven],dependencies:["MessageEventsAPI"],start(){let e=M("deleteMessage","startEditMessage"),t=M("can","initialize"),n=Ae(s=>typeof s.MANAGE_MESSAGES=="bigint"),r=M("isEditing","isEditingAny");document.addEventListener("keydown",ol),document.addEventListener("keyup",rl),this.onClick=Or((s,a,c)=>{let f=s.author.id===G.getCurrentUser().id;Ii?(f||t.can(n.MANAGE_MESSAGES,a))&&(e.deleteMessage(a.id,s.id),c.preventDefault()):f&&c.detail>=2&&!r.isEditing(a.id,s.id)&&(e.startEditMessage(a.id,s.id,s.content),c.preventDefault())})},stop(){Br(this.onClick),document.removeEventListener("keydown",ol),document.removeEventListener("keyup",rl)}})});function sl(){S.plugins.MessageLogger.deleteStyle==="text"?(document.body.classList.remove("messagelogger-red-overlay"),document.body.classList.add("messagelogger-red-text")):(document.body.classList.remove("messagelogger-red-text"),document.body.classList.add("messagelogger-red-overlay"))}var Ri,al=m(()=>{"use strict";i();R();ne();x();le();T();L();k();Ri=u({name:"MessageLogger",description:"Temporarily logs deleted and edited messages.",authors:[p.rushii,p.Ven],timestampModule:null,moment:null,css:` + .messagelogger-red-overlay .messageLogger-deleted { + background-color: rgba(240, 71, 71, 0.15); + } + .messagelogger-red-text .messageLogger-deleted div { + color: #f04747; + } + + .messageLogger-deleted [class^="buttons"] { + display: none; + } + + .messageLogger-deleted-attachment { + filter: grayscale(1); + } + + .messageLogger-deleted-attachment:hover { + filter: grayscale(0); + transition: 250ms filter linear; + } + + .theme-dark .messageLogger-edited { + filter: brightness(80%); + } + + .theme-light .messageLogger-edited { + opacity: 0.5; + } + `,start(){this.moment=M("relativeTimeRounding","relativeTimeThreshold"),this.timestampModule=M("messageLogger_TimestampComponent");let e=this.style=document.createElement("style");e.textContent=this.css,e.id="MessageLogger-css",document.head.appendChild(e),sl()},stop(){this.style?.remove(),document.querySelectorAll(".messageLogger-deleted").forEach(e=>e.remove()),document.querySelectorAll(".messageLogger-edited").forEach(e=>e.remove()),document.body.classList.remove("messagelogger-red-overlay"),document.body.classList.remove("messagelogger-red-text")},renderEdit(e){let t=this.timestampModule.messageLogger_TimestampComponent;return o(D,{noop:!0},o("div",{className:"messageLogger-edited"},Ke.parse(e.content),o(t,{timestamp:e.timestamp,isEdited:!0,isInline:!1},o("span",null," ","(edited)"))))},makeEdit(e,t){return{timestamp:this.moment?.call(e.edited_timestamp),content:t.content}},options:{deleteStyle:{type:4,description:"The style of deleted messages",default:"text",options:[{label:"Red text",value:"text",default:!0},{label:"Red overlay",value:"overlay"}],onChange:()=>sl()},ignoreBots:{type:3,description:"Whether to ignore messages by bots",default:!1},ignoreSelf:{type:3,description:"Whether to ignore messages by yourself",default:!1}},handleDelete(e,t,n){try{let f=function(d){let v=e.get(d);if(!v)return;let h=64;(v.flags&h)===h||s&&v.author?.bot||a&&v.author?.id===c?e=e.remove(d):e=e.update(d,w=>w.set("deleted",!0).set("attachments",w.attachments.map(P=>(P.deleted=!0,P))))};var r=f;if(e==null||!n&&!e.has(t.id))return e;let{ignoreBots:s,ignoreSelf:a}=S.plugins.MessageLogger,c=G.getCurrentUser().id;n?t.ids.forEach(f):f(t.id)}catch(s){new N("MessageLogger").error("Error during handleDelete",s)}return e},patches:[{find:'displayName="MessageStore"',replacement:[{match:/MESSAGE_DELETE:function\((\w)\){var .+?((?:\w{1,2}\.){2})getOrCreate.+?},/,replace:"MESSAGE_DELETE:function($1){ var cache = $2getOrCreate($1.channelId); cache = Vencord.Plugins.plugins.MessageLogger.handleDelete(cache, $1, false); $2commit(cache);},"},{match:/MESSAGE_DELETE_BULK:function\((\w)\){var .+?((?:\w{1,2}\.){2})getOrCreate.+?},/,replace:"MESSAGE_DELETE_BULK:function($1){ var cache = $2getOrCreate($1.channelId); cache = Vencord.Plugins.plugins.MessageLogger.handleDelete(cache, $1, true); $2commit(cache);},"},{match:/(MESSAGE_UPDATE:function\((\w)\).+?)\.update\((\w)/,replace:"$1.update($3,m => $2.message.content !== m.editHistory?.[0]?.content && $2.message.content !== m.content ? m.set('editHistory',[...(m.editHistory || []), Vencord.Plugins.plugins.MessageLogger.makeEdit($2.message, m)]) : m).update($3"}]},{find:"isFirstMessageInForumPost=function",replacement:[{match:/(\w)\.customRenderedContent=(\w)\.customRenderedContent;/,replace:"$1.customRenderedContent = $2.customRenderedContent;$1.deleted = $2.deleted || false;$1.editHistory = $2.editHistory || [];"}]},{find:"THREAD_STARTER_MESSAGE?null===",replacement:[{match:/interactionData:(\w)\.interactionData/,replace:"interactionData:$1.interactionData,deleted:$1.deleted,editHistory:$1.editHistory,attachments:$1.attachments"},{match:/attachments:(\w{1,2})\((\w)\)/,replace:"attachments: $1((() => { let old = arguments[1]?.attachments; if (!old) return $2; let new_ = $2.attachments?.map(a => a.id) ?? []; let diff = old.filter(a => !new_.includes(a.id)); old.forEach(a => a.deleted = true); $2.attachments = [...diff, ...$2.attachments]; return $2;})()),deleted: arguments[1]?.deleted,editHistory: arguments[1]?.editHistory"},{match:/(\((\w)\){return null==\2\.attachments.+?)spoiler:/,replace:"$1deleted: arguments[0]?.deleted,spoiler:"}]},{find:'["className","attachment","inlineMedia"]',replacement:[{match:/((\w)\.className,\w=\2\.attachment),/,replace:"$1,deleted=$2.attachment?.deleted,"},{match:/(hiddenSpoilers:\w,className:)/,replace:"$1 (deleted ? 'messageLogger-deleted-attachment ' : '') +"}]},{find:"Message must not be a thread starter message",replacement:[{match:/var (\w)=(\w).id,(?=\w=\w.message)/,replace:"var $1=$2.id,deleted=$2.message.deleted,"},{match:/\)\("li",\{(.+?),className:/,replace:')("li",{$1,className:(deleted ? "messageLogger-deleted " : "")+'}]},{find:'Messages.MESSAGE_EDITED,")"',replacement:[{match:/(\)\("div",\{id:.+?children:\[)/,replace:"$1 (arguments[0].message.editHistory.length > 0 ? arguments[0].message.editHistory.map(edit => Vencord.Plugins.plugins.MessageLogger.renderEdit(edit)) : null), "}]},{find:'displayName="ReferencedMessageStore"',replacement:[{match:/MESSAGE_DELETE:function\((\w)\).+?},/,replace:"MESSAGE_DELETE:function($1){},"},{match:/MESSAGE_DELETE_BULK:function\((\w)\).+?},/,replace:"MESSAGE_DELETE_BULK:function($1){},"}]},{find:"Messages.MESSAGE_EDITED_TIMESTAMP_A11Y_LABEL.format",replacement:{match:/{(\w{1,2}:\(\)=>(\w{1,2}))}/,replace:"{$1,messageLogger_TimestampComponent:()=>$2}"}},{find:'id:"remove-reactions"',replacement:[{match:/children:(\[""===.+?\])/,replace:"children:arguments[0].message.deleted?[]:$1"}]}]})});function cl(e){Nt({name:e.name,description:e.name,inputType:1,execute:async(t,n)=>await Vn(e.name)?(S.plugins.MessageTags.clyde&&U(n.channel.id,{author:Xe,content:`${ft} The tag **${e.name}** has been sent!`}),{content:e.message.replaceAll("\\n",` +`)}):(U(n.channel.id,{author:Xe,content:`${ft} The tag **${e.name}** does not exist anymore! Please reload ur Discord to fix :)`}),{content:`/${e.name}`}),[Eu]:!0},"CustomTags")}var ft,to,Eu,Xe,eo,Vn,Fu,Du,Ci,ll=m(()=>{"use strict";i();be();$t();R();x();T();ft="<:luna:1035316192220553236>",to="MessageTags_TAGS",Eu=Symbol("MessageTags"),Xe={id:"821472922140803112",bot:!1},eo=()=>Je(to).then(e=>e??[]),Vn=e=>Je(to).then(t=>(t??[]).find(n=>n.name===e)??null),Fu=async e=>{let t=await eo();return t.push(e),Re(to,t),t},Du=async e=>{let t=await eo();return t=await t.filter(n=>n.name!==e),Re(to,t),t};Ci=u({name:"MessageTags",description:"Allows you to save messages and to use them with a simple command.",authors:[p.Luna],options:{clyde:{name:"Clyde message on send",description:"If enabled, clyde will send you an ephemeral message when a tag was used.",type:3,default:!0}},dependencies:["CommandsAPI"],async start(){for(let e of await eo())cl(e)},commands:[{name:"tags",description:"Manage all the tags for yourself",inputType:0,options:[{name:"create",description:"Create a new tag",type:1,options:[{name:"tag-name",description:"The name of the tag to trigger the response",type:3,required:!0},{name:"message",description:"The message that you will send when using this tag",type:3,required:!0}]},{name:"list",description:"List all tags from yourself",type:1,options:[]},{name:"delete",description:"Remove a tag from your yourself",type:1,options:[{name:"tag-name",description:"The name of the tag to trigger the response",type:3,required:!0}]},{name:"preview",description:"Preview a tag without sending it publicly",type:1,options:[{name:"tag-name",description:"The name of the tag to trigger the response",type:3,required:!0}]}],async execute(e,t){switch(e[0].name){case"create":{let n=ce(e[0].options,"tag-name",""),r=ce(e[0].options,"message","");if(await Vn(n))return U(t.channel.id,{author:Xe,content:`${ft} A Tag with the name **${n}** already exists!`});let s={name:n,enabled:!0,message:r};cl(s),await Fu(s),U(t.channel.id,{author:Xe,content:`${ft} Successfully created the tag **${n}**!`});break}case"delete":{let n=ce(e[0].options,"tag-name","");if(!await Vn(n))return U(t.channel.id,{author:Xe,content:`${ft} A Tag with the name **${n}** does not exist!`});un(n),await Du(n),U(t.channel.id,{author:Xe,content:`${ft} Successfully deleted the tag **${n}**!`});break}case"list":{U(t.channel.id,{author:Xe,embeds:[{title:"All Tags:",description:(await eo()).map(n=>`\`${n.name}\`: ${n.message.slice(0,72).replaceAll("\\n"," ")}${n.message.length>72?"...":""}`).join(` +`)||`${ft} Woops! There are no tags yet, use \`/tags create\` to create one!`,color:14122879,type:"rich"}]});break}case"preview":{let n=ce(e[0].options,"tag-name",""),r=await Vn(n);if(!r)return U(t.channel.id,{author:Xe,content:`${ft} A Tag with the name **${n}** does not exist!`});U(t.channel.id,{author:Xe,content:r.message.replaceAll("\\n",` +`)});break}}return U(t.channel.id,{author:Xe,content:"Invalid sub-command"})}}]})});function Nu(e){let t="";for(let n=0;n{"use strict";i();be();x();T();Ai=u({name:"MoreCommands",description:"echo, lenny, mock",authors:[p.Arjix,p.echo,p.Samu],dependencies:["CommandsAPI"],commands:[{name:"echo",description:"Sends a message as Clyde (locally)",options:[ut],inputType:3,execute:(e,t)=>{let n=ce(e,"message","");U(t.channel.id,{content:n})}},{name:"lenny",description:"Sends a lenny face",options:[ut],execute:e=>({content:ce(e,"message","")+" ( \u0361\xB0 \u035C\u0296 \u0361\xB0)"})},{name:"mock",description:"mOcK PeOpLe",options:[It],execute:e=>({content:Nu(ce(e,"message",""))})}]})});var _i,dl=m(()=>{"use strict";i();be();R();x();T();X("MoreKaomoji","moarKaomojis");_i=u({name:"MoreKaomoji",description:"Adds more Kaomoji to discord. \u30FD(\xB4\u25BD`)/",authors:[p.JacobTm],dependencies:["CommandsAPI"],commands:[{name:"dissatisfaction",description:" \uFF1E\uFE4F\uFF1C"},{name:"smug",description:" \u0CA0_\u0CA0"},{name:"happy",description:" \u30FD(\xB4\u25BD`)/"},{name:"crying",description:" \u0CA5_\u0CA5"},{name:"angry",description:" \u30FD(\uFF40\u0414\xB4)\uFF89"},{name:"anger",description:" \u30FD(\uFF4F`\u76BF\u2032\uFF4F)\uFF89"},{name:"joy",description:" <(\uFFE3\uFE36\uFFE3)>"}].map(e=>({...e,options:[ut],execute:t=>({content:ce(t,"message","")+e.description})}))})});function Bu(e,t){let n=0,r=0;for(;(r=e.indexOf(t,r)+1)!==0;)n++;return n}function $u(e,t){if(!t.global)throw new Error("pattern must be global");let n=0;for(;t.test(e);)n++;return n}function Hu(e){let t=Bu(e,Ei)+$u(e,Uu);return Math.min(t,10)}function Li(){if(!S.plugins.Moyai.triggerWhenUnfocused&&!document.hasFocus())return;let e=document.createElement("audio");e.src=Ou,e.volume=S.plugins.Moyai.volume,e.play()}var Ei,Ou,Fi,Uu,ml=m(()=>{"use strict";i();R();Jn();x();O();T();k();Ei="\u{1F5FF}",Ou="https://raw.githubusercontent.com/MeguminSama/VencordPlugins/main/plugins/moyai/moyai.mp3",Fi=u({name:"Moyai",authors:[p.Megu,p.Nuckyz],description:"\u{1F5FF}\u{1F5FF}\u{1F5FF}\u{1F5FF}\u{1F5FF}\u{1F5FF}\u{1F5FF}\u{1F5FF}",async onMessage(e){if(e.optimistic||e.type!=="MESSAGE_CREATE"||e.message.state==="SENDING"||S.plugins.Moyai.ignoreBots&&e.message.author?.bot||!e.message.content||e.channelId!==pe.getChannelId())return;let t=Hu(e.message.content);for(let n=0;n/gi});var Di,ul=m(()=>{"use strict";i();x();T();Di=u({name:"MuteNewGuild",description:"Mutes newly joined guilds",authors:[p.Glitch],patches:[{find:",acceptInvite:function",replacement:{match:/(\w=null!==[^;]+)/,replace:"$1;Vencord.Webpack.findByProps('updateGuildNotificationSettings').updateGuildNotificationSettings($1,{'muted':true,'suppress_everyone':true,'suppress_roles':true})"}}]})});var ju,Ni,fl=m(()=>{"use strict";i();R();x();T();L();ju=M("getRelationships","isBlocked"),Ni=u({name:"NoBlockedMessages",description:"Hides all blocked messages from chat completely.",authors:[p.rushii,p.Samu],patches:[{find:'safety_prompt:"DMSpamExperiment",response:"show_redacted_messages"',replacement:[{match:/\.collapsedReason;return/,replace:".collapsedReason;return null;return;"}]},{find:'displayName="MessageStore"',predicate:()=>S.plugins.NoBlockedMessages.ignoreBlockedMessages===!0,replacement:[{match:/(?<=MESSAGE_CREATE:function\((\w)\){var \w=\w\.channelId,\w=\w\.message,\w=\w\.isPushNotification,\w=\w\.\w\.getOrCreate\(\w\));/,replace:";if(Vencord.Plugins.plugins.NoBlockedMessages.isBlocked(n))return;"}]}],options:{ignoreBlockedMessages:{description:"Completely ignores (recent) incoming messages from blocked users (locally).",type:3,default:!1,restartNeeded:!0}},isBlocked:e=>ju.isBlocked(e.author.id)})});var Oi,gl=m(()=>{"use strict";i();pt();R();x();T();Oi=u({name:"NoCanaryMessageLinks",description:"Allows you to change/remove the subdomain of discord message and channel links",authors:[p.Samu,p.nea],options:{linkPrefix:{description:"The subdomain for your discord message links",type:0,default:"",restartNeeded:!1},alwaysUseDiscordHost:{description:"Always use discord.com host (replace discordapp.com)",type:3,default:!1,restartNeeded:!1}},dependencies:["MessageEventsAPI"],removeBetas(e){let t=S.plugins.NoCanaryMessageLinks;e.content=e.content.replace(/https:\/\/(?:canary\.|ptb\.)?(discord(?:app)?\.com)(\/channels\/(?:\d{17,20}|@me)\/\d{17,20}(?:\/\d{17,20})?)/g,(n,r,s)=>"https://"+(t.linkPrefix?t.linkPrefix+".":"")+(t.alwaysUseDiscordHost?"discord.com":r)+s)},start(){this.preSend=$e((e,t)=>this.removeBetas(t))},stop(){Ue(this.preSend)}})});var Bi,hl=m(()=>{"use strict";i();R();x();T();X("NoDevtoolsWarning","STFU");Bi=u({name:"NoDevtoolsWarning",description:"Disables the 'HOLD UP' banner in the console",authors:[p.Ven],patches:[{find:"setDevtoolsCallbacks",replacement:{match:/if\(.{0,10}\|\|"0.0.0"!==.{0,2}\.remoteApp\.getVersion\(\)\)/,replace:"if(false)"}}]})});var $i,yl=m(()=>{"use strict";i();x();T();$i=u({name:"No F1",description:"Disables F1 help bind.",authors:[p.Cyn],patches:[{find:',"f1"],comboKeysBindGlobal:',replacement:{match:',"f1"],comboKeysBindGlobal:',replace:"],comboKeysBindGlobal:"}}]})});var Ui,vl=m(()=>{"use strict";i();x();T();Ui=u({name:"No RPC",description:"Disables Discord's RPC server.",authors:[p.Cyn],target:"DESKTOP",patches:[{find:'.ensureModule("discord_rpc")',replacement:{match:/\.ensureModule\("discord_rpc"\)\.then\(\(.+?\)\)}/,replace:'.ensureModule("discord_rpc")}'}}]})});var Hi,bl=m(()=>{"use strict";i();x();T();Hi=u({name:"NoReplyMention",description:"Disables reply pings by default",authors:[p.DustyAngel47],patches:[{find:"CREATE_PENDING_REPLY:function",replacement:{match:/CREATE_PENDING_REPLY:function\((.{1,2})\){/,replace:"CREATE_PENDING_REPLY:function($1){$1.shouldMention=false;"}}]})});var ji,Sl=m(()=>{"use strict";i();x();T();ji=u({name:"NoSystemBadge",description:"Disables the taskbar and system tray unread count badge.",authors:[p.rushii],target:"DESKTOP",patches:[{find:"setSystemTrayApplications:function",replacement:[{match:/setBadge:function.+?},/,replace:"setBadge:function(){},"},{match:/setSystemTrayIcon:function.+?},/,replace:"setSystemTrayIcon:function(){},"}]}]})});var Gi,xl=m(()=>{"use strict";i();x();T();Gi=u({name:"NoTrack",description:"Disable Discord's tracking and crash reporting",authors:[p.Cyn],required:!0,patches:[{find:"TRACKING_URL:",replacement:{match:/^.+$/,replace:"()=>{}"}},{find:"window.DiscordSentry=",replacement:{match:/window\.DiscordSentry=function.+\}\(\)/,replace:""}}]})});var zi,Tl=m(()=>{"use strict";i();x();T();zi=u({name:"NoUnblockToJump",description:"Allows you to jump to messages of blocked users without unblocking them",authors:[p.dzshn],patches:[{find:'.id,"Search Results"',replacement:{match:/if\(.{1,10}\)(.{1,10}\.show\({.{1,50}UNBLOCK_TO_JUMP_TITLE)/,replace:"if(false)$1"}},{find:"renderJumpButton=function()",replacement:{match:/if\(.{1,10}\)(.{1,10}\.show\({.{1,50}UNBLOCK_TO_JUMP_TITLE)/,replace:"if(false)$1"}},{find:"flash:!0,returnMessageId",replacement:{match:/.\?(.{1,10}\.show\({.{1,50}UNBLOCK_TO_JUMP_TITLE)/,replace:"false?$1"}}]})});var Wi,wl=m(()=>{"use strict";i();x();T();Wi=u({name:"oneko",description:"cat follow mouse (real)",authors:[p.Ven,p.adryd],start(){fetch("https://raw.githubusercontent.com/adryd325/oneko.js/14bab15a755d0e35cd4ae19c931d96d306f99f42/oneko.js").then(e=>e.text()).then(e=>e.replace("./oneko.gif","https://raw.githubusercontent.com/adryd325/oneko.js/14bab15a755d0e35cd4ae19c931d96d306f99f42/oneko.gif")).then(eval)},stop(){clearInterval(window.onekoInterval),delete window.onekoInterval,document.getElementById("oneko")?.remove()}})});function kl(e){let t=e instanceof File,n=t?URL.createObjectURL(e):e;return new Promise((r,s)=>{let a=new Image;a.onload=()=>{t&&URL.revokeObjectURL(n),r(a)},a.onerror=(c,f,d,v,h)=>s(h||c),a.crossOrigin="Anonymous",a.src=n})}async function Qu(e,t,n){for(let r of e)switch(r.name){case"image":let s=Yu.getUploads(t.channel.id,Pl)[0];if(s){if(!s.isImage)throw"Upload is not an image";return s.item.file}break;case"url":return r.value;case"user":try{return(await qu(r.value)).getAvatarURL(n?void 0:t.guild?.id,2048).replace(/\?size=\d+$/,"?size=2048")}catch(a){throw console.error(`[petpet] Failed to fetch user +`,a),"Failed to fetch user. Check the console for more info."}}return null}var Pl,Gu,zu,no,Wu,qu,Ku,Yu,qi,Il=m(()=>{"use strict";i();be();x();Qn();O();T();L();Pl=0,Gu=20,zu=128,no=10,Wu=Fe(()=>Promise.all(Array.from({length:no},(e,t)=>kl(`https://raw.githubusercontent.com/VenPlugs/petpet/main/frames/pet${t}.gif`)))),qu=re(".USER("),Ku=re("UPLOAD_FILE_LIMIT_ERROR"),Yu=M("getUploads");qi=u({name:"petpet",description:"headpet a cutie",authors:[p.Ven],dependencies:["CommandsAPI"],commands:[{inputType:0,name:"petpet",description:"Create a petpet gif. You can only specify one of the image options",options:[{name:"delay",description:"The delay between each frame. Defaults to 20.",type:4},{name:"resolution",description:"Resolution for the gif. Defaults to 120. If you enter an insane number and it freezes Discord that's your fault.",type:4},{name:"image",description:"Image attachment to use",type:11},{name:"url",description:"URL to fetch image from",type:3},{name:"user",description:"User whose avatar to use as image",type:6},{name:"no-server-pfp",description:"Use the normal avatar instead of the server specific one when using the 'user' option",type:5}],execute:async(e,t)=>{let{GIFEncoder:n,quantize:r,applyPalette:s}=await Yn(),a=await Wu(),c=ce(e,"no-server-pfp",!1);try{var f=await Qu(e,t,c);if(!f)throw"No Image specified!"}catch(_){U(t.channel.id,{content:String(_)});return}let d=await kl(f),v=ce(e,"delay",Gu),h=ce(e,"resolution",zu),g=new n,w=document.createElement("canvas");w.width=w.height=h;let P=w.getContext("2d");for(let _=0;_Ku([B],t.channel,Pl))}}]})});var Ki,Ml=m(()=>{"use strict";i();x();T();Ki=u({name:"PlainFolderIcon",description:"Doesn't show the small guild icons in folders",authors:[p.botato],patches:[{find:"().expandedFolderIconWrapper",replacement:[{match:/\(\w\|\|\w\)&&(\(.{0,40}\(.{1,3}\.animated)/,replace:"$1"}]}]})});function oo(e,t="0 0 24 24"){return({color:n,tooltip:r})=>o(me,{text:r},s=>o("svg",{...s,height:"18",width:"18",viewBox:t,fill:n},o("path",{d:e})))}var Rl,Ju,Xu,Zu,Yi,Cl=m(()=>{"use strict";i();R();ne();x();T();L();k();Rl={desktop:oo("M4 2.5c-1.103 0-2 .897-2 2v11c0 1.104.897 2 2 2h7v2H7v2h10v-2h-4v-2h7c1.103 0 2-.896 2-2v-11c0-1.103-.897-2-2-2H4Zm16 2v9H4v-9h16Z"),web:oo("M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2Zm-1 17.93c-3.95-.49-7-3.85-7-7.93 0-.62.08-1.21.21-1.79L9 15v1c0 1.1.9 2 2 2v1.93Zm6.9-2.54c-.26-.81-1-1.39-1.9-1.39h-1v-3c0-.55-.45-1-1-1H8v-2h2c.55 0 1-.45 1-1V7h2c1.1 0 2-.9 2-2v-.41c2.93 1.19 5 4.06 5 7.41 0 2.08-.8 3.97-2.1 5.39Z"),mobile:oo("M15.5 1h-8A2.5 2.5 0 0 0 5 3.5v17A2.5 2.5 0 0 0 7.5 23h8a2.5 2.5 0 0 0 2.5-2.5v-17A2.5 2.5 0 0 0 15.5 1zm-4 21c-.83 0-1.5-.67-1.5-1.5s.67-1.5 1.5-1.5 1.5.67 1.5 1.5-.67 1.5-1.5 1.5zm4.5-4H7V4h9v14z"),console:oo("M14.8 2.7 9 3.1V47h3.3c1.7 0 6.2.3 10 .7l6.7.6V2l-4.2.2c-2.4.1-6.9.3-10 .5zm1.8 6.4c1 1.7-1.3 3.6-2.7 2.2C12.7 10.1 13.5 8 15 8c.5 0 1.2.5 1.6 1.1zM16 33c0 6-.4 10-1 10s-1-4-1-10 .4-10 1-10 1 4 1 10zm15-8v23.3l3.8-.7c2-.3 4.7-.6 6-.6H43V3h-2.2c-1.3 0-4-.3-6-.6L31 1.7V25z","0 0 50 50")},Ju=re("STATUS_YELLOW","TWITCH","STATUS_GREY"),Xu=({platform:e,status:t})=>{let n=e[0].toUpperCase()+e.slice(1),r=Rl[e]??Rl.desktop;return o(r,{color:`var(--${Ju(t)}`,tooltip:n})},Zu=({user:e})=>{if(!e||e.bot)return null;let t=Xt.getState()?.clientStatuses?.[e.id];if(!t)return null;let n=Object.entries(t).map(([r,s])=>o(Xu,{key:r,platform:r,status:s}));return n.length?o("div",{className:"vc-platform-indicator",style:{display:"flex",alignItems:"center",marginLeft:"4px",gap:"4px"}},n):null},Yi=u({name:"PlatformIndicators",description:"Adds platform indicators (Desktop, Mobile, Web...) to users",authors:[p.kemo],patches:[{find:"this.renderPremium()",predicate:()=>["both","list"].includes(S.plugins.PlatformIndicators.displayMode),replacement:{match:/this.renderPremium\(\)[^\]]*?\]/,replace:"$&.concat(Vencord.Plugins.plugins.PlatformIndicators.renderPlatformIndicators(this.props))"}},{find:"PrivateChannel.renderAvatar",predicate:()=>["both","list"].includes(S.plugins.PlatformIndicators.displayMode),replacement:{match:/(subText:(.{1,3})\..+?decorators:)(.+?:null)/,replace:"$1[$3].concat(Vencord.Plugins.plugins.PlatformIndicators.renderPlatformIndicators($2.props))"}},{find:"Messages.PROFILE_USER_BADGES",predicate:()=>["both","badges"].includes(S.plugins.PlatformIndicators.displayMode),replacement:{match:/(Messages\.PROFILE_USER_BADGES,role:"group",children:)(.+?\.key\)\}\)\))/,replace:"$1[Vencord.Plugins.plugins.PlatformIndicators.renderPlatformIndicators(e)].concat($2)"}}],renderPlatformIndicators:({user:e})=>o(D,{noop:!0},o(Zu,{user:e})),options:{displayMode:{type:4,description:"Where to display the platform indicators",restartNeeded:!0,options:[{label:"Member List & Badges",value:"both",default:!0},{label:"Member List Only",value:"list"},{label:"Badges Only",value:"badges"}]}}})});function Qi(){return o(b.Fragment,null,o(y.FormTitle,{tag:"h3"},"More Information"),o(y.FormText,null,"To add your own pronouns, visit"," ",o(Pe,{href:"https://pronoundb.org"},"pronoundb.org")),o(y.FormDivider,null),o(y.FormText,null,"The two pronoun formats are lowercase and capitalized. Example:",o("ul",null,o("li",null,"Lowercase: they/them"),o("li",null,"Capitalized: They/Them")),'Text like "Ask me my pronouns" or "Any pronouns" will always be capitalized. ',o("br",null),o("br",null),"You can also configure whether or not to display pronouns for the current user (since you probably already know them)"))}var Al=m(()=>{"use strict";i();wt();k()});function gt(e,t=300){let n;return function(...r){clearTimeout(n),n=setTimeout(()=>{e(...r)},t)}}var yn=m(()=>{"use strict";i()});var ht,ro=m(()=>{"use strict";i();ht={hh:"He/Him",hi:"He/It",hs:"He/She",ht:"He/They",ih:"It/Him",ii:"It/Its",is:"It/She",it:"It/They",shh:"She/He",sh:"She/Her",si:"She/It",st:"She/They",th:"They/He",ti:"They/It",ts:"They/She",tt:"They/Them",any:"Any pronouns",other:"Other pronouns",ask:"Ask me my pronouns",avoid:"Avoid pronouns, use my name",unspecified:"Unspecified"}});function so(e){return new Promise(t=>{e in io?t(io[e]):e in Ut?Ut[e].push(t):(Ut[e]=[t],Vu())})}async function ef(e){let t=new URLSearchParams;t.append("platform","discord"),t.append("ids",e.join(","));try{return await(await fetch("https://pronoundb.org/api/v1/lookup-bulk?"+t.toString(),{method:"GET",headers:{Accept:"application/json","X-PronounDB-Source":er}})).json().then(r=>(Object.assign(io,r),r))}catch(n){console.error("PronounDB fetching failed: ",n);let r=Object.fromEntries(e.map(s=>[s,"unspecified"]));return Object.assign(io,r),r}}function ao(e){let{pronounsFormat:t}=S.plugins.PronounDB;return t==="CAPITALIZED"?ht[e]:t==="LOWERCASE"&&["any","ask","avoid","other"].includes(e)?ht[e]:ht[e].toLowerCase()}var io,Ut,Vu,Ji=m(()=>{"use strict";i();R();x();yn();Xi();ro();io={},Ut={},Vu=gt(async()=>{let e=Object.keys(Ut),t=await ef(e);for(let n of e)Ut[n].forEach(r=>r(t[n])),delete Ut[n]})});function Zi({message:e}){return e.author.bot||e.author.system||!S.plugins.PronounDB.showSelf&&e.author.id===G.getCurrentUser().id?null:o(tf,{message:e})}function tf({message:e}){let[t,,n]=ve(()=>so(e.author.id),{fallbackValue:null,onError:r=>console.error("Fetching pronouns failed: ",r)});return!n&&t&&t!=="unspecified"&&ht[t]?o("span",{className:ie(_l.timestampInline,_l.timestamp)},"\u2022 ",ao(t)):null}var _l,Ll=m(()=>{"use strict";i();R();O();L();k();Ji();ro();_l=M("timestampInline")});function Vi(e,t,n){let r=G.getUser(n.userId)??{};return r.bot||r.system||!S.plugins.PronounDB.showSelf&&r.id===G.getCurrentUser().id?null:o(nf,{userId:n.userId,Component:e,leProps:t})}function nf({userId:e,Component:t,leProps:n}){let[r,,s]=ve(()=>so(e),{fallbackValue:null,onError:a=>console.error("Fetching pronouns failed: ",a)});return!s&&r&&r!=="unspecified"&&ht[r]?(n.currentPronouns||=ao(r),o(t,{...n})):null}var El=m(()=>{"use strict";i();R();O();k();Ji();ro()});var es,Xi=m(()=>{"use strict";i();x();T();Al();Ll();El();es=u({name:"PronounDB",authors:[p.Tyman],description:"Adds pronouns to user messages using pronoundb",patches:[{find:"showCommunicationDisabledStyles",replacement:{match:/(?<=return\s*\(0,\w{1,3}\.jsxs?\)\(.+!\w{1,3}&&)(\(0,\w{1,3}.jsxs?\)\(.+?\{.+?\}\))/,replace:"[$1, Vencord.Plugins.plugins.PronounDB.PronounsChatComponent(e)]"}},{find:"currentPronouns:",all:!0,noWarn:!0,replacement:{match:/\(0,.{1,3}\.jsxs?\)\((.{1,10}),(\{[^[}]*currentPronouns:[^}]*(\w)\.pronouns[^}]*\})\)/,replace:(e,t,n,r)=>n.includes("onPronounsChange")?e:`${r}&&Vencord.Plugins.plugins.PronounDB.PronounsProfileWrapper(${t}, ${n}, ${r})`}},{find:"2022-01_pronouns",replacement:{match:"!1",replace:"!0"}}],options:{pronounsFormat:{type:4,description:"The format for pronouns to appear in chat",options:[{label:"Lowercase",value:"LOWERCASE",default:!0},{label:"Capitalized",value:"CAPITALIZED"}]},showSelf:{type:3,description:"Enable or disable showing pronouns for the current user",default:!0}},settingsAboutComponent:Qi,PronounsChatComponent:Zi,PronounsProfileWrapper:Vi})});var of,ts,Fl=m(()=>{"use strict";i();fn();x();T();L();k();of=Ae(e=>e.emitter?._events?.INSERT_TEXT),ts=u({name:"QuickMention",authors:[p.kemo],description:"Adds a quick mention button to the message actions bar",dependencies:["MessagePopoverAPI"],start(){Mt("QuickMention",e=>({label:"Quick Mention",icon:this.Icon,message:e,channel:ae.getChannel(e.channel_id),onClick:()=>of.dispatchToLastSubscribed("INSERT_TEXT",{rawText:`<@${e.author.id}> `})}))},stop(){Rt("QuickMention")},Icon:()=>o("svg",{className:"icon",height:"24",width:"24",viewBox:"0 0 24 24",fill:"currentColor"},o("path",{d:"M12 2C6.486 2 2 6.486 2 12C2 17.515 6.486 22 12 22C14.039 22 15.993 21.398 17.652 20.259L16.521 18.611C15.195 19.519 13.633 20 12 20C7.589 20 4 16.411 4 12C4 7.589 7.589 4 12 4C16.411 4 20 7.589 20 12V12.782C20 14.17 19.402 15 18.4 15L18.398 15.018C18.338 15.005 18.273 15 18.209 15H18C17.437 15 16.6 14.182 16.6 13.631V12C16.6 9.464 14.537 7.4 12 7.4C9.463 7.4 7.4 9.463 7.4 12C7.4 14.537 9.463 16.6 12 16.6C13.234 16.6 14.35 16.106 15.177 15.313C15.826 16.269 16.93 17 18 17L18.002 16.981C18.064 16.994 18.129 17 18.195 17H18.4C20.552 17 22 15.306 22 12.782V12C22 6.486 17.514 2 12 2ZM12 14.599C10.566 14.599 9.4 13.433 9.4 11.999C9.4 10.565 10.566 9.399 12 9.399C13.434 9.399 14.6 10.565 14.6 11.999C14.6 13.433 13.434 14.599 12 14.599Z"}))})});function Hl(e,t){let n=e.findIndex(r=>r.id===t);return n===-1?n:e.length-n-1}function Ol({channelId:e,messageId:t,_isQuickEdit:n}){if(n)return;let r=G.getCurrentUser().id,s=vt.getMessages(e)._array.filter(a=>a.author.id===r);lo=Hl(s,t)}function Bl({message:e,_isQuickReply:t}){t||(co=Hl(vt.getMessages(e.channel_id)._array,e.id))}function $l(e){let t=e.key==="ArrowUp";!t&&e.key!=="ArrowDown"||!sf(e)||af(e)||(e.shiftKey?lf(t):cf(t))}function jl(e,t){let n=document.getElementById("message-content-"+t);if(!n)return;let r=Math.max(document.documentElement.clientHeight,window.innerHeight),s=n.getBoundingClientRect();(s.bottom<200||s.top-r>=-200)&&rf.jumpToMessage({channelId:e,messageId:t,flash:!1,jumpType:"INSTANT"})}function Gl(e,t){let n=vt.getMessages(pe.getChannelId())._array;if(!t){let a=G.getCurrentUser().id;n=n.filter(c=>c.author.id===a)}let r=a=>e?Math.min(n.length-1,a+1):Math.max(-1,a-1),s;return t?co=s=r(co):lo=s=r(lo),s===-1?void 0:n[n.length-s-1]}function cf(e){let t=Gl(e,!0);if(!t)return void I.dispatch({type:"DELETE_PENDING_REPLY",channelId:pe.getChannelId()});let n=ae.getChannel(t.channel_id),r=G.getCurrentUser().id;I.dispatch({type:"CREATE_PENDING_REPLY",channel:n,message:t,shouldMention:!0,showMentionToggle:n.guild_id!==null&&t.author.id!==r,_isQuickReply:!0}),jl(n.id,t.id)}function lf(e){let t=Gl(e,!1);t?(I.dispatch({type:"MESSAGE_START_EDIT",channelId:t.channel_id,messageId:t.id,content:t.content,_isQuickEdit:!0}),jl(t.channel_id,t.id)):I.dispatch({type:"MESSAGE_END_EDIT",channelId:pe.getChannelId()})}var rf,Ul,co,lo,ns,Dl,Nl,sf,af,zl=m(()=>{"use strict";i();R();x();T();L();k();rf=M("jumpToMessage"),Ul=navigator.platform.includes("Mac"),co=-1,lo=-1;X("QuickReply","InteractionKeybinds");ns=u({name:"QuickReply",authors:[p.obscurity,p.Ven],description:"Reply to (ctrl + up/down) and edit (ctrl + shift + up/down) messages via keybinds",start(){I.subscribe("DELETE_PENDING_REPLY",Dl),I.subscribe("MESSAGE_END_EDIT",Nl),I.subscribe("MESSAGE_START_EDIT",Ol),I.subscribe("CREATE_PENDING_REPLY",Bl),document.addEventListener("keydown",$l)},stop(){I.unsubscribe("DELETE_PENDING_REPLY",Dl),I.unsubscribe("MESSAGE_END_EDIT",Nl),I.unsubscribe("MESSAGE_START_EDIT",Ol),I.unsubscribe("CREATE_PENDING_REPLY",Bl),document.removeEventListener("keydown",$l)}}),Dl=()=>co=-1,Nl=()=>lo=-1;sf=e=>Ul?e.metaKey:e.ctrlKey,af=e=>e.altKey||!Ul&&e.metaKey});var rs={};ee(rs,{ServerListRenderPosition:()=>po,addServerListElement:()=>vn,removeServerListElement:()=>bn,renderAll:()=>uf});function os(e){return e===0?df:mf}function vn(e,t){os(e).add(t)}function bn(e,t){os(e).delete(t)}var pf,po,df,mf,uf,mo=m(()=>{"use strict";i();le();pf=new N("ServerListAPI"),po=(n=>(n[n.Above=0]="Above",n[n.In=1]="In",n))(po||{}),df=new Set,mf=new Set;uf=e=>{let t=[];for(let n of os(e))try{t.unshift(n())}catch(r){pf.error("Failed to render server list element:",r)}return t}});function ff(){let e=[];Object.values(qe.getGuilds()).forEach(t=>{zo.getChannels(t.id).SELECTABLE.forEach(n=>{!$n.hasUnread(n.channel.id)||e.push({channelId:n.channel.id,messageId:$n.lastMessageId(n.channel.id),readStateType:0})})}),I.dispatch({type:"BULK_ACK",context:"APP",channels:e})}var gf,is,Wl=m(()=>{"use strict";i();mo();x();T();k();gf=()=>o(F,{onClick:ff,size:F.Sizes.MIN,color:F.Colors.BRAND,style:{marginTop:"2px",marginBottom:"8px",marginLeft:"9px"}},"Read all"),is=u({name:"ReadAllNotificationsButton",description:"Read all server notifications with a single button click!",authors:[p.kemo],dependencies:["ServerListAPI"],renderReadAllButton:()=>o(gf,null),start(){vn(1,this.renderReadAllButton)},stop(){bn(1,this.renderReadAllButton)}})});var ss,as,ql=m(()=>{"use strict";i();x();T();k();ss={Google:"https://www.google.com/searchbyimage?image_url=",Yandex:"https://yandex.com/images/search?rpt=imageview&url=",SauceNAO:"https://saucenao.com/search.php?url=",IQDB:"https://iqdb.org/?url=",TinEye:"https://www.tineye.com/search?url="},as=u({name:"ReverseImageSearch",description:"Adds ImageSearch to image context menus",authors:[p.Ven],dependencies:["MenuItemDeobfuscatorAPI"],patches:[{find:"open-native-link",replacement:{match:/id:"open-native-link".{0,200}\(\{href:(.{0,3}),.{0,200}\},"open-native-link"\)/,replace:(e,t)=>`${e},Vencord.Plugins.plugins.ReverseImageSearch.makeMenu(${t}, arguments[2])`}},{find:"REMOVE_ALL_REACTIONS_CONFIRM_BODY,",replacement:{match:/(?.).onHeightUpdate.{0,200}(.)=(.)=.\.url;.+?\(null!=\3\?\3:\2[^)]+/,replace:"$&,$.target"}}],makeMenu(e,t){return t&&!(t instanceof HTMLImageElement)&&t.attributes["data-role"]?.value!=="img"?null:o(ue.MenuItem,{label:"Search Image",key:"search-image",id:"search-image"},Object.keys(ss).map(n=>{let r="search-image-"+n;return o(ue.MenuItem,{key:r,id:r,label:n,action:()=>this.search(e,ss[n])})}),o(ue.MenuItem,{key:"search-image-all",id:"search-image-all",label:"All",action:()=>Object.values(ss).forEach(n=>this.search(e,n))}))},search(e,t){open(t+encodeURIComponent(e),"_blank")}})});async function Kl(e){await Zt.fetchUser(e),await I.dispatch({type:"USER_PROFILE_MODAL_OPEN",userId:e,channelId:pe.getChannelId(),analyticsLocation:"Explosive Hotel"})}function uo(e){let{OAuth2AuthorizeModal:t}=_e("OAuth2AuthorizeModal");we(n=>o(t,{...n,scopes:["identify"],responseType:"code",redirectUri:"https://manti.vendicated.dev/URauth",permissions:0n,clientId:"915703782174752809",cancelCompletesFlow:!1,callback:async r=>{try{let s=new URL(r);s.searchParams.append("returnType","json"),s.searchParams.append("clientMod","vencord");let a=await fetch(s,{headers:new Headers({Accept:"application/json"})}),{token:c,status:f}=await a.json();f===0?(S.plugins.ReviewDB.token=c,Ze("Successfully logged in!"),e?.()):a.status===1&&Ze("An Error occurred while logging in.")}catch(s){new N("ReviewDB").error("Failed to authorise",s)}}}))}function Ze(e){A.show({type:A.Type.MESSAGE,message:e,id:A.genId(),options:{position:A.Position.BOTTOM}})}function Yl(e,t){if(e.senderdiscordid===t)return!0;let n=BigInt(t);return n===p.mantikafasi.id||n===p.Ven.id||n===p.rushii.id}var fo=m(()=>{"use strict";i();R();x();le();Ye();L();k()});async function Jl(e){return await(await fetch(Sn+"/getUserReviews?snowflakeFormat=string&discordid="+e)).json()}async function Xl(e){return e.token=cs(),e.token?fetch(Sn+"/addUserReview",{method:"POST",body:JSON.stringify(e),headers:{"Content-Type":"application/json"}}).then(t=>t.text()).then(t=>(Ze(t),Ql[t]??2)):(Ze("Please authorize to add a review."),uo(),2)}function Zl(e){return fetch(Sn+"/deleteReview",{method:"POST",headers:new Headers({"Content-Type":"application/json",Accept:"application/json"}),body:JSON.stringify({token:cs(),reviewid:e})}).then(t=>t.json())}async function Vl(e){let t=await fetch(Sn+"/reportReview",{method:"POST",headers:new Headers({"Content-Type":"application/json",Accept:"application/json"}),body:JSON.stringify({reviewid:e,token:cs()})});Ze(await t.text())}function ep(e){return fetch(Sn+"/getLastReviewID?discordid="+e).then(t=>t.text()).then(Number)}var Sn,cs,Ql,go=m(()=>{"use strict";i();R();fo();Sn="https://manti.vendicated.dev",cs=()=>S.plugins.ReviewDB.token,Ql=(t=>(t[t["Added your review"]=0]="Added your review",t[t["Updated your review"]=1]="Updated your review",t[t.Error=2]="Error",t))(Ql||{})});var ls,tp=m(()=>{"use strict";i();O();L();ls=Q(()=>{let{button:e,dangerous:t}=_e("button","wrapper","disabled");return function(r){return r.type==="delete"?o("div",{className:ie(e,t),"aria-label":"Delete Review",onClick:r.callback},o("svg",{"aria-hidden":"false",width:"16",height:"16",viewBox:"0 0 20 20"},o("path",{fill:"currentColor",d:"M15 3.999V2H9V3.999H3V5.999H21V3.999H15Z"}),o("path",{fill:"currentColor",d:"M5 6.99902V18.999C5 20.101 5.897 20.999 7 20.999H17C18.103 20.999 19 20.101 19 18.999V6.99902H5ZM11 17H9V11H11V17ZM15 17H13V11H15V17Z"}))):o("div",{className:e,"aria-label":"Report Review",onClick:()=>r.callback()},o("svg",{"aria-hidden":"false",width:"16",height:"16",viewBox:"0 0 20 20"},o("path",{fill:"currentColor",d:"M20,6.002H14V3.002C14,2.45 13.553,2.002 13,2.002H4C3.447,2.002 3,2.45 3,3.002V22.002H5V14.002H10.586L8.293,16.295C8.007,16.581 7.922,17.011 8.076,17.385C8.23,17.759 8.596,18.002 9,18.002H20C20.553,18.002 21,17.554 21,17.002V7.002C21,6.45 20.553,6.002 20,6.002Z"})))}})});var np,op=m(()=>{"use strict";i();O();L();k();go();fo();tp();np=Q(()=>{let e=E.byProps,[{cozyMessage:t,buttons:n,message:r,groupStart:s},{container:a,isHeader:c},{avatar:f,clickable:d,username:v,messageContent:h,wrapper:g,cozy:w},{contents:P},B,{defaultColor:_}]=No(e("cozyMessage"),e("container","isHeader"),e("avatar","zalgo"),e("contents"),e("button","wrapper","disabled"),e("defaultColor"));return function({review:C,refetch:q}){function se(){Kl(C.senderdiscordid)}function de(){at.show({title:"Are you sure?",body:"Do you really want to delete this review?",confirmText:"Delete",cancelText:"Nevermind",onConfirm:()=>{Zl(C.id).then(ge=>{ge.successful&&q(),Ze(ge.message)})}})}function Ie(){at.show({title:"Are you sure?",body:"Do you really you want to report this review?",confirmText:"Report",cancelText:"Nevermind",onConfirm:()=>Vl(C.id)})}return o("div",{className:ie(t,r,s,g,w,"user-review")},o("div",{className:P},o("img",{className:ie(f,d),style:{left:"8px"},onClick:se,src:C.profile_photo||"/assets/1f0bfc0865d324c2587920a7d80c609b.png?size=128"}),o("span",{className:ie(v,d),style:{color:"var(--text-normal)",right:"8px"},onClick:()=>se()},C.username),o("p",{className:ie(h,_),style:{fontSize:15,marginTop:4,right:"8px"}},C.comment),o("div",{className:ie(a,c,n),style:{padding:"0px"}},o("div",{className:B.wrapper},o(ls,{type:"report",callback:Ie}),Yl(C,G.getCurrentUser().id)&&o(ls,{type:"delete",callback:de})))))}})});function ps({userId:e}){let[t,n]=b.useState(0),[r,s,a]=ve(()=>Jl(e),{fallbackValue:[],deps:[t]}),c=()=>n(t+1);if(a)return null;function f({key:d,target:v}){d==="Enter"&&Xl({userid:e,comment:v.value,star:-1}).then(h=>{(h===0||h===1)&&(v.value="",c())})}return o("div",{className:"ReviewDB"},o(l,null,o(Y,{tag:"h2",variant:"eyebrow",style:{paddingLeft:"0px",marginBottom:"12px",color:"var(--header-primary)"}},"User Reviews"),r?.map(d=>o(np,{key:d.id,review:d,refetch:c})),r?.length===0&&o(y.FormText,{style:{paddingLeft:"0px",paddingRight:"12px",marginBottom:"12px"}},"Looks like nobody reviewed this user yet. You could be the first!"),o("textarea",{className:ie(hf.textarea,"enter-comment"),placeholder:"Review @"+G.getUser(e)?.username,onKeyDown:f,style:{padding:"12px",marginBottom:"12px",color:"var(--text-normal)",border:"1px solid var(--profile-message-input-border-color)",fontSize:"14px",borderRadius:"3px"}})))}var hf,rp=m(()=>{"use strict";i();O();L();k();go();op();hf=Ae(e=>typeof e.textarea=="string")});var ds,ip=m(()=>{"use strict";i();R();ne();x();T();k();rp();go();fo();ds=u({name:"ReviewDB",description:"Review other users (Adds a new settings to profiles)",authors:[p.mantikafasi,p.Ven],patches:[{find:"disableBorderColor:!0",replacement:{match:/\(.{0,10}\{user:(.),setNote:.,canDM:.,.+?\}\)/,replace:"$&,Vencord.Plugins.plugins.ReviewDB.getReviewsComponent($1)"}}],options:{authorize:{type:6,description:"Authorise with ReviewDB",component:()=>o(F,{onClick:uo},"Authorise with ReviewDB")},notifyReviews:{type:3,description:"Notify about new reviews on startup",default:!0}},async start(){let e=S.plugins.ReviewDB;!e.lastReviewId||!e.notifyReviews||setTimeout(async()=>{let t=await ep(G.getCurrentUser().id);e.lastReviewIdo(D,{message:"Failed to render Reviews"},o(ps,{userId:e.id}))})});function yf(){return ap=ct(),o("span",{id:"vc-friendcount",style:{display:"inline-block",width:"100%",fontSize:"12px",fontWeight:"600",color:"var(--header-secondary)",textTransform:"uppercase",textAlign:"center"}},ms," online")}function vf(){return cp=ct(),o("span",{id:"vc-guildcount",style:{display:"inline-block",width:"100%",fontSize:"12px",fontWeight:"600",color:"var(--header-secondary)",textTransform:"uppercase",textAlign:"center"}},sp," servers")}var ms,sp,ap,cp,us,lp=m(()=>{"use strict";i();mo();R();ne();x();O();T();k();ms=0,sp=0;us=u({name:"ServerListIndicators",description:"Add online friend count or server count in the server list",authors:[p.dzshn],dependencies:["ServerListAPI"],options:{mode:{description:"mode",type:4,options:[{label:"Only online friend count",value:2,default:!0},{label:"Only server count",value:1},{label:"Both server and online friend counts",value:3}]}},renderIndicator:()=>{let{mode:e}=S.plugins.ServerListIndicators;return o(D,{noop:!0},o("div",{style:{marginBottom:"4px"}},!!(e&2)&&o(yf,null),!!(e&1)&&o(vf,null)))},handlePresenceUpdate(){ms=0;let e=Hn.getRelationships();for(let t of Object.keys(e))e[t]===1&&Xt.getStatus(t)!=="offline"&&(ms+=1);ap?.()},handleGuildUpdate(){sp=qe.getGuildCount(),cp?.()},start(){this.handlePresenceUpdate(),this.handleGuildUpdate(),vn(0,this.renderIndicator),I.subscribe("PRESENCE_UPDATES",this.handlePresenceUpdate),I.subscribe("GUILD_CREATE",this.handleGuildUpdate),I.subscribe("GUILD_DELETE",this.handleGuildUpdate)},stop(){bn(0,this.renderIndicator),I.unsubscribe("PRESENCE_UPDATES",this.handlePresenceUpdate),I.unsubscribe("GUILD_CREATE",this.handleGuildUpdate),I.unsubscribe("GUILD_DELETE",this.handleGuildUpdate)}})});var pp,dp=m(()=>{i();pp=`.vcSettingsTabBar { + margin-top: 20px; + margin-bottom: -2px; + border-bottom: 2px solid var(--background-modifier-accent); +} + +.vcSettingsTabBarItem { + margin-right: 32px; + padding-bottom: 16px; + margin-bottom: -2px; +} + +.vcSettingsQuickActionCard { + padding: 1em; + display: flex; + gap: 1em; + align-items: center; + justify-content: space-between; + flex-wrap: wrap; + flex-grow: 1; + flex-direction: row; + margin-bottom: 1em; +} +`});async function bf(e){try{var t=JSON.parse(e)}catch(n){throw console.log(e),new Error("Failed to parse JSON: "+String(n))}if("settings"in t&&"quickCss"in t)await VencordNative.ipc.invoke(j.SET_SETTINGS,JSON.stringify(t.settings,null,4)),await VencordNative.ipc.invoke(j.SET_QUICK_CSS,t.quickCss);else throw new Error("Invalid Settings. Is this even a Vencord Settings file?")}async function Sf(){let e=JSON.parse(VencordNative.ipc.sendSync(j.GET_SETTINGS)),t=await VencordNative.ipc.invoke(j.GET_QUICK_CSS);return JSON.stringify({settings:e,quickCss:t},null,4)}async function mp(){let e="vencord-settings-backup.json",t=await Sf(),n=new TextEncoder().encode(t);{let r=new File([n],e,{type:"application/json"}),s=document.createElement("a");s.href=URL.createObjectURL(r),s.download=e,document.body.appendChild(s),s.click(),setImmediate(()=>{URL.revokeObjectURL(s.href),document.body.removeChild(s)})}}async function up(e=!0){if(!0){let t=document.createElement("input");t.type="file",t.style.display="none",t.accept="application/json",t.onchange=async()=>{let n=t.files?.[0];if(!n)return;let r=new FileReader;r.onload=async()=>{try{await bf(r.result),e&&xf()}catch(s){new N("SettingsSync").error(s),e&&Tf(s)}},r.readAsText(n)},document.body.appendChild(t),t.click(),setImmediate(()=>document.body.removeChild(t))}else if(t)try{}catch(n){}}var xf,Tf,fp=m(()=>{"use strict";i();k();ze();le();xf=()=>A.show({type:A.Type.SUCCESS,message:"Settings successfully imported. Restart to apply changes!",id:A.genId()}),Tf=e=>A.show({type:A.Type.FAILURE,message:`Failed to import settings: ${String(e)}`,id:A.genId()})});function wf(){return o(y.FormSection,{title:"Settings Sync"},o(Te,{style:{backgroundColor:"var(--info-warning-background)",borderColor:"var(--info-warning-foreground)",color:"var(--info-warning-text)",padding:"1em",marginBottom:"0.5em"}},o(Z,{flexDirection:"column"},o("strong",null,"Warning"),o("span",null,"Importing a settings file will overwrite your current settings."))),o(Y,{variant:"text-md/normal",className:V.marginBottom8},"You can import and export your Vencord settings as a JSON file. This allows you to easily transfer your settings to another device, or recover your settings after reinstalling Vencord or Discord."),o(Y,{variant:"text-md/normal",className:V.marginBottom8},"Settings Export contains:",o("ul",null,o("li",null,"\u2014 Custom QuickCSS"),o("li",null,"\u2014 Plugin Settings"))),o(Z,null,o(F,{onClick:up,size:F.Sizes.SMALL},"Import Settings"),o(F,{onClick:mp,size:F.Sizes.SMALL},"Export Settings")))}var gp,hp=m(()=>{"use strict";i();ne();Ne();fp();k();gp=D.wrap(wf)});var hs={};ee(hs,{UpdateLogger:()=>yp,changes:()=>xn,checkForUpdates:()=>vp,getRepo:()=>bp,isNewer:()=>fs,isOutdated:()=>Ct,rebuild:()=>yo,update:()=>ho,updateError:()=>gs});async function Ht(e){let t=await e;if(t.ok)return t.value;throw gs=t.error,t.error}async function vp(){return xn=await Ht(VencordNative.ipc.invoke(j.GET_UPDATES)),xn.some(e=>e.hash===Tt)?(fs=!0,Ct=!1):Ct=xn.length>0}async function ho(){if(!Ct)return!0;let e=await Ht(VencordNative.ipc.invoke(j.UPDATE));return e&&(Ct=!1),e}function bp(){return Ht(VencordNative.ipc.invoke(j.GET_REPO))}async function yo(){let e=await Ht(VencordNative.ipc.invoke(j.GET_HASHES));if(!await Ht(VencordNative.ipc.invoke(j.BUILD)))throw new Error("The Build failed. Please try manually building the new update");let t=await Ht(VencordNative.ipc.invoke(j.GET_HASHES));return e["patcher.js"]!==t["patcher.js"]||e["preload.js"]!==t["preload.js"]}var yp,Ct,fs,gs,xn,Tn=m(()=>{"use strict";i();nn();ze();le();yp=new N("Updater","white"),Ct=!1,fs=!1});async function Sp(){Ct&&setImmediate(async()=>{if(confirm("Uh Oh! Failed to render this Page. However, there is an update available that might fix it. Would you like to update and restart now?"))try{await ho(),await yo(),location.reload()}catch(t){console.error(t),alert("That also failed :( Try updating or reinstalling with the installer!")}})}var ys=m(()=>{"use strict";i();Tn()});var wn,vs=m(()=>{"use strict";i();wn=class{set=new Set;get changeCount(){return this.set.size}get hasChanges(){return this.changeCount>0}handleChange(t){this.set.delete(t)||this.set.add(t)}add(t){return this.set.add(t)}remove(t){return this.set.delete(t)}getChanges(){return this.set.values()}map(t){return[...this.getChanges()].map(t)}}});var Ts={};ee(Ts,{PMLogger:()=>Pf,isPluginEnabled:()=>bs,patches:()=>xp,plugins:()=>kf,startAllPlugins:()=>Ss,startDependenciesRecursive:()=>vo,startPlugin:()=>Pn,stopPlugin:()=>xs});function bs(e){return(te[e]?.required||te[e]?.isDependency||Tp[e]?.enabled)??!1}function vo(e){let t=!1,n=[];return e.dependencies?.forEach(r=>{if(!S.plugins[r].enabled){if(vo(te[r]),te[r].patches){ke.warn(`Enabling dependency ${r} requires restart.`),S.plugins[r].enabled=!0,t=!0;return}Pn(te[r])||n.push(r)}}),{restartNeeded:t,failures:n}}var ke,Pf,kf,xp,Tp,wp,Ss,Pn,xs,bo=m(()=>{"use strict";i();be();R();le();tn();_o();ke=new N("PluginManager","#a6d189"),Pf=ke,kf=te,xp=[],Tp=S.plugins;wp=Object.values(te);for(let e of wp)e.dependencies?.forEach(t=>{let n=te[t];if(n)Tp[t].enabled=!0,n.isDependency=!0;else{let r=new Error(`Plugin ${e.name} has unresolved dependency ${t}`);ke.warn(r)}});for(let e of wp)if(e.patches&&bs(e.name))for(let t of e.patches)t.plugin=e.name,Array.isArray(t.replacement)||(t.replacement=[t.replacement]),xp.push(t);Ss=Ve("startAllPlugins",function(){for(let t in te)bs(t)&&Pn(te[t])});Pn=Ve("startPlugin",function(t){if(t.start){if(ke.info("Starting plugin",t.name),t.started)return ke.warn(`${t.name} already started`),!1;try{t.start(),t.started=!0}catch(n){return ke.error(`Failed to start ${t.name} +`,n),!1}}if(t.commands?.length){ke.info("Registering commands of plugin",t.name);for(let n of t.commands)try{Nt(n,t.name)}catch(r){return ke.error(`Failed to register command ${n.name} +`,r),!1}}return!0},e=>`startPlugin ${e.name}`),xs=Ve("stopPlugin",function(t){if(t.stop){if(ke.info("Stopping plugin",t.name),!t.started)return ke.warn(`${t.name} already stopped`),!1;try{t.stop(),t.started=!1}catch(n){return ke.error(`Failed to stop ${t.name} +`,n),!1}}if(t.commands?.length){ke.info("Unregistering commands of plugin",t.name);for(let n of t.commands)try{un(n.name)}catch(r){return ke.error(`Failed to unregister command ${n.name} +`,r),!1}}return!0},e=>`stopPlugin ${e.name}`)});function Pp(e){let t=new Rf({username:e.name,id:Gr(),bot:!0});return I.dispatch({type:"USER_UPDATE",user:t}),t}function ws({plugin:e,onRestartNeeded:t,onClose:n,transitionState:r}){let[s,a]=b.useState([]),c=De().plugins[e.name],[f,d]=b.useState({}),[v,h]=b.useState({}),[g,w]=b.useState(null),P=()=>Object.values(v).every(C=>!C);b.useEffect(()=>{(async()=>{for(let C of e.authors.slice(0,6)){let q=C.id?await Zt.fetchUser(`${C.id}`).catch(()=>Pp(C)):Pp(C);a(se=>[...se,q])}})()},[]);async function B(){if(!e.options){n();return}if(e.beforeSave){let q=await Promise.resolve(e.beforeSave(f));if(q!==!0){w(q);return}}let C=!1;for(let[q,se]of Object.entries(f)){let de=e.options[q];c[q]=se,de?.onChange?.(se),de?.restartNeeded&&(C=!0)}C&&t(),n()}function _(){if(!c||!e.options)return o(y.FormText,null,"There are no settings for this plugin.");let C=Object.entries(e.options).map(([q,se])=>{function de(Ge){d(yt=>({...yt,[q]:Ge}))}function Ie(Ge){h(yt=>({...yt,[q]:Ge}))}let ge=Cf[se.type];return o(ge,{id:q,key:q,option:se,onChange:de,onError:Ie,pluginSettings:c})});return o(Z,{flexDirection:"column",style:{gap:12}},C)}function oe(C,q){let se=e.authors.length-q,de=e.authors.length-se,Ie=de+e.authors.length-q;return o(me,{text:e.authors.slice(de,Ie).map(ge=>ge.name).join(", ")},({onMouseEnter:ge,onMouseLeave:Ge})=>o("div",{className:Mf.moreUsers,onMouseEnter:ge,onMouseLeave:Ge},"+",se))}return o(Be,{transitionState:r,size:"medium"},o(nt,null,o(Y,{variant:"heading-md/bold"},e.name)),o(ot,{style:{marginBottom:8,marginTop:8}},o(y.FormSection,null,o(y.FormTitle,{tag:"h3"},"About ",e.name),o(y.FormText,null,e.description),o("div",{style:{marginTop:8,marginBottom:8,width:"fit-content"}},o(If,{users:s,count:e.authors.length,guildId:void 0,renderIcon:!1,max:6,showDefaultAvatarsForNullUsers:!0,showUserPopout:!0,renderMoreUsers:oe}))),!!e.settingsAboutComponent&&o("div",{style:{marginBottom:8}},o(y.FormSection,null,o(D,{message:"An error occurred while rendering this plugin's custom InfoComponent"},o(e.settingsAboutComponent,null)))),o(y.FormSection,null,o(y.FormTitle,{tag:"h3"},"Settings"),_())),o(sn,null,o(Z,{flexDirection:"column",style:{width:"100%"}},o(Z,{style:{marginLeft:"auto"}},o(F,{onClick:n,size:F.Sizes.SMALL,color:F.Colors.RED},"Cancel"),o(me,{text:"You must fix all errors before saving",shouldShow:!P()},({onMouseEnter:C,onMouseLeave:q})=>o(F,{size:F.Sizes.SMALL,color:F.Colors.BRAND,onClick:B,onMouseEnter:C,onMouseLeave:q,disabled:!P()},"Save & Close"))),g&&o(Y,{variant:"text-md/semibold",style:{color:"var(--text-danger)"}},"Error while saving: ",g))))}var If,Mf,Rf,Cf,kp=m(()=>{"use strict";i();be();R();ne();Ne();O();Ye();Et();T();L();k();ri();If=Q(()=>xe("defaultRenderUser","showDefaultAvatarsForNullUsers")),Mf=M("moreUsers","emptyUser","avatarContainer","clickableAvatar"),Rf=We(()=>G.getCurrentUser().constructor);Cf={[0]:Bc,[1]:oi,[2]:oi,[3]:Ac,[4]:Dc,[5]:Oc,[6]:Lc}});var Ps,Ip,Mp,Rp,Cp=m(()=>{"use strict";i();Ps={marginTop:16,display:"grid",gridGap:16,gridTemplateColumns:"repeat(auto-fill, minmax(250px, 1fr))"},Ip={backgroundColor:"var(--background-modifier-selected)",color:"var(--interactive-active)",borderRadius:3,cursor:"pointer",display:"block",height:"min-content",padding:10,width:"100%"},Mp={gap:10,height:40,gridTemplateColumns:"1fr 150px",display:"grid"},Rp={height:"24px",width:"24px",padding:"0",background:"transparent",marginRight:8}});function Ef(e){A.show({message:e,type:A.Type.FAILURE,id:A.genId(),options:{position:A.Position.BOTTOM}})}function Ff({plugins:e,...t}){if(e.length===0)return null;let n=e.length===1?"The plugin":"The following plugins require a reload to apply changes:",r=e.length===1?" requires a reload to apply changes.":".";return o(rn,{...t,style:{padding:"1em",display:"grid",gridTemplateColumns:"1fr auto",gap:8,...t.style}},o("span",{style:{margin:"auto 0"}},n," ",o("code",null,e.join(", ")),r),o(F,{look:F.Looks.INVERTED,onClick:()=>location.reload()},"Reload"))}function Lp({plugin:e,disabled:t,onRestartNeeded:n,onMouseEnter:r,onMouseLeave:s}){let c=De().plugins[e.name],[f,d]=b.useState(!1);function v(){return c?.enabled||e.started}function h(){pr(async()=>w=>o(ws,{...w,plugin:e,onRestartNeeded:()=>n(e.name)}))}function g(){let w=v();if(!w){let{restartNeeded:_,failures:oe}=vo(e);if(oe.length){Ap.error(`Failed to start dependencies for ${e.name}: ${oe.join(", ")}`),ln("Failed to start dependencies: "+oe.join(", "),"Close",()=>null);return}else if(_){c.enabled=!0,n(e.name);return}}if(e.patches){c.enabled=!w,n(e.name);return}if(w&&!e.started){c.enabled=!w;return}let P=w?xs(e):Pn(e),B=w?"stop":"start";if(!P){Ap.error(`Failed to ${B} plugin ${e.name}`),Ef(`Failed to ${B} plugin: ${e.name}`);return}c.enabled=!w}return o(Z,{style:Ip,flexDirection:"column",onMouseEnter:r,onMouseLeave:s},o(bt,{onChange:g,disabled:t,value:v(),note:o(Y,{variant:"text-md/normal",style:{height:40,overflow:"hidden",textOverflow:"ellipsis",display:"-webkit-box",WebkitLineClamp:2,lineClamp:2,WebkitBoxOrient:"vertical",boxOrient:"vertical"}},e.description),hideBorder:!0},o(Z,{style:{marginTop:"auto",width:"100%",height:"100%",alignItems:"center"}},o(Y,{variant:"text-md/bold",style:{flexGrow:"1"}},e.name),o("button",{role:"switch",onClick:()=>h(),style:Rp,className:"button-12Fmur"},e.options?o(_f,{style:{color:f?"":"var(--text-muted)"},onMouseEnter:()=>d(!0),onMouseLeave:()=>d(!1)}):o(Lf,{width:"24",height:"24",style:{color:f?"":"var(--text-muted)"},onMouseEnter:()=>d(!0),onMouseLeave:()=>d(!1)})))))}function Df(e){return o(b.Fragment,null,o(y.FormText,null,"This plugin is required by:"),e.map(t=>o(y.FormText,{style:{margin:"0 auto"}},t)))}function ks(e,t){return t[e]?.filter(n=>S.plugins[n].enabled)||[]}var Ap,_p,_f,Lf,So,Is=m(()=>{"use strict";i();pn();R();ne();qn();Ne();ys();vs();le();O();Ye();L();k();tn();bo();kp();Cp();Ap=new N("PluginSettings","#a6d189"),_p=M("inputDefault","inputWrapper"),_f=Q(()=>xe("18.564C15.797 19.099 14.932 19.498 14 19.738V22H10V19.738C9.069")),Lf=Q(()=>xe("4.4408921e-16 C4.4771525,-1.77635684e-15 4.4408921e-16"));So=D.wrap(function(){let t=De(),n=b.useMemo(()=>new wn,[]);b.useEffect(()=>()=>void(n.hasChanges&&at.show({title:"Restart required",body:o(l,null,o("p",null,"The following plugins require a restart:"),o("div",null,n.map((h,g)=>o(l,null,g>0&&", ",Ke.parse("`"+h+"`"))))),confirmText:"Restart now",cancelText:"Later!",onConfirm:()=>location.reload()})),[]);let r=b.useMemo(()=>{let h={};for(let g in te){let w=te[g].dependencies;if(w)for(let P of w)h[P]??=[],h[P].push(g)}return h},[]),s=b.useMemo(()=>Object.values(te).sort((h,g)=>h.name.localeCompare(g.name)),[]),[a,c]=b.useState({value:"",status:"all"}),f=h=>c(g=>({...g,value:h})),d=h=>c(g=>({...g,status:h})),v=h=>{let g=a.status==="enabled"||a.status==="all",w=a.status==="disabled"||a.status==="all",P=t.plugins[h.name]?.enabled||h.started;return(g&&P||w&&!P)&&(h.name.toLowerCase().includes(a.value.toLowerCase())||h.description.toLowerCase().includes(a.value.toLowerCase()))};return o(y.FormSection,null,o(y.FormTitle,{tag:"h5",className:ie(V.marginTop20,V.marginBottom8)},"Filters"),o(Ff,{plugins:[...n.getChanges()],style:{marginBottom:16}}),o("div",{style:Mp},o(Le,{value:a.value,placeholder:"Search for a plugin...",onChange:f,style:{marginBottom:24}}),o("div",{className:_p.inputWrapper},o(St,{className:_p.inputDefault,options:[{label:"Show All",value:"all",default:!0},{label:"Show Enabled",value:"enabled"},{label:"Show Disabled",value:"disabled"}],serialize:String,select:d,isSelected:h=>h===a.status,closeOnSelect:!0}))),o(y.FormTitle,{className:V.marginTop20},"Plugins"),o("div",{style:Ps},s?.length?s.filter(h=>!h.required&&!ks(h.name,r).length&&v(h)).map(h=>{let w=r[h.name]?.filter(P=>t.plugins[P].enabled)?.length;return o(Lp,{onRestartNeeded:P=>n.add(P),disabled:h.required||!!w,plugin:h,key:h.name})}):o(Y,{variant:"text-md/normal"},"No plugins meet search criteria.")),o(y.FormDivider,null),o(y.FormTitle,{tag:"h5",className:ie(V.marginTop20,V.marginBottom8)},"Required Plugins"),o("div",{style:Ps},s?.length?s.filter(h=>h.required||ks(h.name,r).length&&v(h)).map(h=>{let w=r[h.name]?.filter(B=>t.plugins[B].enabled)?.length,P=h.required?"This plugin is required for Vencord to function.":Df(ks(h.name,r));return o(me,{text:P,key:h.name},({onMouseLeave:B,onMouseEnter:_})=>o(Lp,{onMouseLeave:B,onMouseEnter:_,onRestartNeeded:oe=>n.handleChange(oe),disabled:h.required||!!w,plugin:h}))}):o(Y,{variant:"text-md/normal"},"No plugins meet search criteria.")))},{message:"Failed to render the Plugin Settings. If this persists, try using the installer to reinstall!",onError:Sp})});var Ep,Fp=m(()=>{"use strict";i();ne();Is();Ep=D.wrap(So)});function Of({link:e}){let[t,n,r]=ve(()=>fetch(e).then(a=>{if(a.status>300)throw`${a.status} ${a.statusText}`;let c=a.headers.get("Content-Type");if(!c?.startsWith("text/css")&&!c?.startsWith("text/plain"))throw"Not a CSS file. Remember to use the raw link!";return"Okay!"})),s=r?"Checking...":n?`Error: ${n instanceof Error?n.message:String(n)}`:"Valid!";return o(y.FormText,{style:{color:r?"var(--text-muted)":n?"var(--text-danger)":"var(--text-positive)"}},s)}function Bf({themeLinks:e}){return e.length?o(l,null,o(y.FormTitle,{className:V.marginTop20,tag:"h5"},"Validator"),o(y.FormText,null,"This section will tell you whether your themes can successfully be loaded"),o("div",null,e.map(t=>o(Te,{style:{padding:".5em",marginBottom:".5em"},key:t},o(y.FormTitle,{tag:"h5",style:{overflowWrap:"break-word"}},t),o(Of,{link:t}))))):null}var Nf,Dp,Np=m(()=>{"use strict";i();R();ne();wt();O();L();k();Nf=Ae(e=>typeof e.textarea=="string");Dp=D.wrap(function(){let e=De(),t=b.useRef();function n(){e.themeLinks=[...new Set(t.current.value.trim().split(/\n+/).map(r=>r.trim()).filter(Boolean))]}return o(l,null,o(Te,{style:{padding:"1em",marginBottom:"1em",marginTop:"1em"}},o(y.FormTitle,{tag:"h5"},"Paste links to .css / .theme.css files here"),o(y.FormText,null,"One link per line"),o(y.FormText,null,"Be careful to use the raw links or github.io links!"),o(y.FormDivider,null),o(y.FormTitle,{tag:"h5"},"Find Themes:"),o("div",null,o(Pe,{style:{marginRight:".5em"},href:"https://betterdiscord.app/themes"},"BetterDiscord Themes"),o(Pe,{href:"https://github.com/search?q=discord+theme"},"Github")),o(y.FormText,null,'If using the BD site, click on "Source" somewhere below the Download button'),o(y.FormText,null,'In the GitHub repository of your theme, find X.theme.css / X.css, click on it, then click the "Raw" button'),o(y.FormText,null,"If the theme has configuration that requires you to edit the file:",o("ul",null,o("li",null,"\u2022 Make a github account"),o("li",null,"\u2022 Click the fork button on the top right"),o("li",null,"\u2022 Edit the file"),o("li",null,"\u2022 Use the link to your own repository instead")))),o(y.FormTitle,{tag:"h5"},"Themes"),o(Wo,{style:{padding:".5em",border:"1px solid var(--background-modifier-accent)"},ref:t,defaultValue:e.themeLinks.join(` +`),className:Nf.textarea,placeholder:"Theme Links",spellCheck:!1,onBlur:n}),o(Bf,{themeLinks:e.themeLinks}))})});var Op=m(()=>{"use strict";i();ne();qn();Ne();ys();wt();O();Tn();k();nn()});function Uf(){let[e,,t]=ve(()=>VencordNative.ipc.invoke(j.GET_SETTINGS_DIR),{fallbackValue:"Loading..."}),n=De(),[r]=b.useState(Math.random()>.5?"https://cdn.discordapp.com/emojis/1026533090627174460.png":"https://media.discordapp.net/stickers/1039992459209490513.png");return o(b.Fragment,null,o(Hf,{image:r}),o(y.FormSection,{title:"Quick Actions"},o(Te,{className:$f("QuickActionCard")},o(F,{onClick:()=>VencordNative.ipc.send(j.OPEN_EXTERNAL,e),size:F.Sizes.SMALL,disabled:e==="Loading..."},"Launch Directory"))),o(y.FormDivider,null),o(y.FormSection,{title:"Settings"},o(y.FormText,{className:V.marginBottom20},'Hint: You can change the position of this settings section in the settings of the "Settings" plugin!'),o(bt,{value:n.useQuickCss,onChange:s=>n.useQuickCss=s,note:"Loads styles from your QuickCss file"},"Use QuickCss"),!1))}function Hf({image:e}){return o(Te,{style:{padding:"1em",display:"flex",flexDirection:"row",marginBottom:"1em",marginTop:"1em"}},o("div",null,o(y.FormTitle,{tag:"h5"},"Support the Project"),o(y.FormText,null,"Please consider supporting the Development of Vencord by donating!"),o(on,{style:{transform:"translateX(-1em)"}})),o("img",{role:"presentation",src:e,alt:"",height:128,style:{marginLeft:"auto",transform:"rotate(10deg)"}}))}var $f,Bp,$p=m(()=>{"use strict";i();R();sr();ne();ze();O();k();$f=e=>`vcSettings${e}`;Bp=D.wrap(Uf)});var Gp={};ee(Gp,{default:()=>Ms});function jf(e){let{tab:t="VencordSettings"}=e,n=Hp[t]?.component;return o(y.FormSection,null,o(Y,{variant:"heading-md/normal",tag:"h2"},"Vencord Settings"),o(xo,{type:xo.Types.TOP,look:xo.Looks.BRAND,className:Up("TabBar"),selectedItem:t,onItemSelect:jn.open},Object.entries(Hp).map(([r,{name:s,component:a}])=>a?o(xo.Item,{id:r,className:Up("TabBarItem"),key:r},s):null)),o(y.FormDivider,null),n&&o(n,null))}function Ms(e){return o(D,null,o(jf,{tab:e.tab}))}var jp,Up,xo,Hp,Rs=m(()=>{"use strict";i();ne();L();k();dp();hp();Fp();Np();Op();$p();jp=document.createElement("style");jp.textContent=pp;document.head.appendChild(jp);Up=e=>`vcSettings${e}`,xo=re('[role="tab"][aria-disabled="false"]'),Hp={VencordSettings:{name:"Vencord",component:()=>o(Bp,null)},VencordPlugins:{name:"Plugins",component:()=>o(Ep,null)},VencordThemes:{name:"Themes",component:()=>o(Dp,null)},VencordUpdater:{name:"Updater"},VencordSettingsSync:{name:"Backup & Restore",component:()=>o(gp,null)}}});var kn,Cs,zp=m(()=>{"use strict";i();R();x();le();O();T();nn();kn=Q(()=>(Rs(),Ao(Gp)).default),Cs=u({name:"Settings",description:"Adds Settings UI and debug info",authors:[p.Ven,p.Megu],required:!0,patches:[{find:"().versionHash",replacement:[{match:/\[\(0,.{1,3}\.jsxs?\)\((.{1,10}),(\{[^{}}]+\{.{0,20}\(\)\.versionHash,.+?\})\)," "/,replace:(e,t,n)=>(n=n.replace(/children:\[.+\]/,""),`${e},Vencord.Plugins.plugins.Settings.makeInfoElements(${t}, ${n})`)}]},{find:"Messages.ACTIVITY_SETTINGS",replacement:{get match(){switch(S.plugins.Settings.settingsLocation){case"top":return/\{section:(.{1,2})\.ID\.HEADER,\s*label:(.{1,2})\..{1,2}\.Messages\.USER_SETTINGS\}/;case"aboveNitro":return/\{section:(.{1,2})\.ID\.HEADER,\s*label:(.{1,2})\..{1,2}\.Messages\.BILLING_SETTINGS\}/;case"belowNitro":return/\{section:(.{1,2})\.ID\.HEADER,\s*label:(.{1,2})\..{1,2}\.Messages\.APP_SETTINGS\}/;case"aboveActivity":return/\{section:(.{1,2})\.ID\.HEADER,\s*label:(.{1,2})\..{1,2}\.Messages\.ACTIVITY_SETTINGS\}/;case"belowActivity":return/(?<=\{section:(.{1,2})\.ID\.DIVIDER},)\{section:"changelog"/;case"bottom":return/\{section:(.{1,2})\.ID\.CUSTOM,\s*element:.+?}/;default:return new N("Settings").error(new Error("No switch case matched????? Don't mess with the settings, silly")),/(?!a)a/}},replace:(e,t)=>{let n="",r="";return`{section:${t}.ID.HEADER,label:"Vencord"},{section:"VencordSettings",label:"Vencord",element:Vencord.Plugins.plugins.Settings.tabs.vencord},{section:"VencordPlugins",label:"Plugins",element:Vencord.Plugins.plugins.Settings.tabs.plugins},{section:"VencordThemes",label:"Themes",element:Vencord.Plugins.plugins.Settings.tabs.themes},`+n+'{section:"VencordSettingsSync",label:"Backup & Restore",element:Vencord.Plugins.plugins.Settings.tabs.sync},'+r+`{section:${t}.ID.DIVIDER},${e}`}}}],options:{settingsLocation:{type:4,description:"Where to put the Vencord settings section",options:[{label:"At the very top",value:"top"},{label:"Above the Nitro section",value:"aboveNitro"},{label:"Below the Nitro section",value:"belowNitro"},{label:"Above Activity Settings",value:"aboveActivity",default:!0},{label:"Below Activity Settings",value:"belowActivity"},{label:"At the very bottom",value:"bottom"}],restartNeeded:!0}},tabs:{vencord:()=>o(kn,{tab:"VencordSettings"}),plugins:()=>o(kn,{tab:"VencordPlugins"}),themes:()=>o(kn,{tab:"VencordThemes"}),updater:()=>o(kn,{tab:"VencordUpdater"}),sync:()=>o(kn,{tab:"VencordSettingsSync"})},get electronVersion(){return VencordNative.getVersions().electron||window.armcord?.electron||null},get chromiumVersion(){try{return VencordNative.getVersions().chrome||navigator.userAgentData?.brands?.find(e=>e.brand==="Chromium"||e.brand==="Google Chrome")?.version||null}catch{return null}},get additionalInfo(){return" (Web)"},makeInfoElements(e,t){let{electronVersion:n,chromiumVersion:r,additionalInfo:s}=this;return o(l,null,o(e,{...t},"Vencord ",Tt,s),n&&o(e,{...t},"Electron ",n),r&&o(e,{...t},"Chromium ",r))}})});var Wp,qp,Kp=m(()=>{"use strict";i();Wp=e=>e.split(/(?=[A-Z])/).map(t=>t.toLowerCase()),qp=e=>e.map(t=>t[0].toUpperCase()+t.slice(1)).join(" ")});var Yp,Qp=m(()=>{i();Yp=`.shiki-root { + border-radius: 4px; +} + +.shiki-root code { + display: block; + overflow-x: auto; + padding: 0.5em; + position: relative; + + font-size: 0.875rem; + line-height: 1.125rem; + text-indent: 0; + white-space: pre-wrap; + background: transparent; + border: none; +} + +.shiki-root [class^='devicon-'], +.shiki-root [class*=' devicon-'] { + margin-right: 8px; + user-select: none; +} + +.shiki-plain code { + padding-top: 8px; +} + +.shiki-btns { + font-size: 1em; + position: absolute; + right: 0; + bottom: 0; + opacity: 0; +} + +.shiki-root:hover .shiki-btns { + opacity: 1; +} + +.shiki-btn { + border-radius: 4px 4px 0 0; + padding: 4px 8px; +} + +.shiki-btn~.shiki-btn { + margin-left: 4px; +} + +.shiki-btn:last-child { + border-radius: 4px 0; +} + +.shiki-spinner-container { + align-items: center; + background-color: rgba(0, 0, 0, 0.6); + display: flex; + position: absolute; + justify-content: center; + top: 0; + right: 0; + bottom: 0; + left: 0; +} + +.shiki-preview { + margin-bottom: 2em; +} + +.shiki-lang { + padding: 0 5px; + margin-bottom: 6px; + font-weight: bold; + text-transform: capitalize; + display: flex; + align-items: center; +} + +.shiki-table { + border-collapse: collapse; + width: 100%; +} + +.shiki-table tr { + height: 19px; + width: 100%; +} + +.shiki-root td:first-child { + border-right: 1px solid transparent; + padding-left: 5px; + padding-right: 8px; + user-select: none; +} + +.shiki-root td:last-child { + padding-left: 8px; + word-break: break-word; + width: 100%; +} +`});var Xp=Qt((lk,As)=>{"use strict";i();var Gf=Object.prototype.hasOwnProperty,ye="~";function In(){}Object.create&&(In.prototype=Object.create(null),new In().__proto__||(ye=!1));function zf(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function Jp(e,t,n,r,s){if(typeof n!="function")throw new TypeError("The listener must be a function");var a=new zf(n,r||e,s),c=ye?ye+t:t;return e._events[c]?e._events[c].fn?e._events[c]=[e._events[c],a]:e._events[c].push(a):(e._events[c]=a,e._eventsCount++),e}function To(e,t){--e._eventsCount===0?e._events=new In:delete e._events[t]}function fe(){this._events=new In,this._eventsCount=0}fe.prototype.eventNames=function(){var t=[],n,r;if(this._eventsCount===0)return t;for(r in n=this._events)Gf.call(n,r)&&t.push(ye?r.slice(1):r);return Object.getOwnPropertySymbols?t.concat(Object.getOwnPropertySymbols(n)):t};fe.prototype.listeners=function(t){var n=ye?ye+t:t,r=this._events[n];if(!r)return[];if(r.fn)return[r.fn];for(var s=0,a=r.length,c=new Array(a);s{"use strict";i();Object.defineProperty(jt,"__esModule",{value:!0});jt.Channel=jt.ChannelPort=void 0;var Wf=Xp(),wo="vapIpc",_s=Symbol.for("vapIpc.edgeCreate"),Ls=class{_pipes=new Map;_listeners=new Map;_createListenerMap(){return new Map}_emit(t,n,...r){for(let[s,a]of this._listeners.entries()){if(s===t)continue;let c=a.get(n);c&&c(...r)}}createPipe(t){let n=this.getPipe(t);if(n)return n;let r=this._createListenerMap();this._listeners.set(t,r);let s={emit:this._emit.bind(this,t),listen:(a,c)=>void r.set(a,c)};return this._pipes.set(t,s),s}getPipe(t){return this._pipes.get(t)??null}};jt.ChannelPort=Ls;var Es=class{id;_edges=new Map;_callbacks=new Map;_callers=new Map;_edgePipes=new Map;_pipes=[];_emitter=new Wf.EventEmitter;_logger;_destroyed=!1;constructor(t){this.id=t}addPipe(t){t.listen(`${wo}:handshake`,n=>{this._handleHandshake(t,n)}),t.listen(`${wo}:message`,n=>{this._handleMessage(t,n)}),this._pipes.push(t),this._logger?.log(`Adding pipe to channel "${this.id}"`)}setLogger(t){this._logger=t}_handleHandshake(t,n){if(this.id===n.id)return;this._logger?.log(`\u{1F91D} "${n.id}" -> "${this.id}" (edges: [${n.channelIds.join(", ")}])`);let r=this._edges.get(n.id);if(r){let s=n.channelIds.filter(a=>!r?.channelIds.includes(a));if(s.includes(this.id)&&s.splice(s.indexOf(this.id),1),!s.length)return;this._edges.set(n.id,{...n,channelIds:[...r.channelIds,...s]})}else{let s=[...n.channelIds].filter(a=>a!==this.id);this._edges.set(n.id,{...n,channelIds:s}),this._edgePipes.set(n.id,t)}this._emitter.emit(_s,n),this.handshakeAll()}_handleMessage(t,n){if(n.proxiedBy===this.id)return;if(n.destination!==this.id)return this._emitMessage({...n,proxiedBy:this.id});if(!n.nonce)return void this._emitter.emit(n.name,n.data);let r=this._callbacks.get(n.nonce);if(r)return void r(n.data);let s=this._callers.get(n.name);if(s){s(n.data).catch(a=>(console.error(a),new Error(a?.message??`${a}`))).then(a=>{this._emitMessage({name:n.name,source:this.id,destination:n.source,data:a,nonce:n.nonce})});return}}_emitHandshake(t){let n=this.getEdge();t.emit(`${wo}:handshake`,n)}_emitMessage(t){let n=this.findEdgeId(t.destination);if(!n)return;this._edgePipes.get(n)?.emit(`${wo}:message`,t)}getEdge(){let t=[...this._edges.keys(),...[...this._edges.values()].map(n=>n.channelIds).flat()].filter((n,r,s)=>s.indexOf(n)===r);return{id:this.id,channelIds:t}}findEdgeId(t){for(let n of this._edges.values())if(n.id===t||n.channelIds.includes(t))return n.id;return null}waitForEdge(t){let n=this.findEdgeId(t);return n?Promise.resolve(n):new Promise(r=>{let s=a=>{(a.id===t||a.channelIds.includes(t))&&(this._emitter.off(_s,s),r(a.id))};this._emitter.on(_s,s)})}createNonce(){return Math.random().toString(16).slice(2)}send(t){this._emitMessage({...t,source:this.id})}call(t,n={timeout:1e4}){let r=this.createNonce(),s=new Promise((a,c)=>{let f=setTimeout(()=>{this._callbacks.delete(r),c(new Error("Call timed out"))},n.timeout);this._callbacks.set(r,d=>{this._callbacks.delete(r),clearTimeout(f),n.signal?.aborted?n.signal.reason instanceof Error&&c(n.signal.reason):d instanceof Error?c(d):a(d)})});return this._emitMessage({...t,source:this.id,nonce:r}),s}on(t,n){return this._emitter.on(t,n),this}off(t,n){return this._emitter.off(t,n),this}once(t,n){this._emitter.once(t,n)}onCall(t,n){this._callers.set(t,async(...r)=>await n(...r))}removeCaller(){}handshakeAll(){this._pipes.forEach(t=>this._emitHandshake(t))}destroy(){this._emitter.removeAllListeners(),this._callbacks.clear(),this._callers.clear(),this._edgePipes.clear(),this._pipes=[],this._destroyed=!0}};jt.Channel=Es});var Os=Qt(Gt=>{"use strict";i();Object.defineProperty(Gt,"__esModule",{value:!0});Gt.RemoteClient=Gt.RemoteHost=void 0;var Ds=class{channel;constructor(t,n){this.channel=t;for(let[r,s]of Object.entries(n))t.onCall(r,async a=>await s(...a));t.handshakeAll()}};Gt.RemoteHost=Ds;var Ns=class{hostName;channel;constructor(t,n){this.hostName=t,this.channel=n}async connect(){await this.channel.waitForEdge(this.hostName)}run(t,...n){return this.channel.call({name:t,destination:this.hostName,data:n})}};Gt.RemoteClient=Ns});var ed=Qt(zt=>{"use strict";i();Object.defineProperty(zt,"__esModule",{value:!0});zt.WorkerClient=zt.createWorkerHost=void 0;var Zp=Fs(),Vp=Os(),qf=(e,t)=>{let n=new Zp.Channel(e);return n.addPipe({emit:(r,s)=>postMessage({event:r,data:s}),listen:(r,s)=>addEventListener("message",({data:a})=>{a.event===r&&s(a.data)})}),new Vp.RemoteHost(n,t)};zt.createWorkerHost=qf;var Bs=class extends Vp.RemoteClient{workerOpts;worker;workerListeners=[];url;constructor(t,n,r,s={}){let a=new Zp.Channel(t);if(super(n,a),this.workerOpts=s,r instanceof Blob){let c=new Blob([r],{type:"text/javascript"});this.url=URL.createObjectURL(c)}else this.url=r}async init(){let t=this.worker=new Worker(this.url,this.workerOpts);this.channel.addPipe({emit:(n,r)=>t.postMessage({event:n,data:r}),listen:(n,r)=>{let s=a=>{let{event:c,data:f}=a.data;c===n&&r(f)};this.workerListeners.push(s),t.addEventListener("message",s)}}),await this.connect()}destroy(){if(this.worker){for(let t of this.workerListeners)this.worker.removeEventListener("message",t);this.worker.terminate()}this.channel.destroy(),this.url.startsWith("blob:")&&URL.revokeObjectURL(this.url)}};zt.WorkerClient=Bs});var td=Qt(rt=>{"use strict";i();var Kf=rt&&rt.__createBinding||(Object.create?function(e,t,n,r){r===void 0&&(r=n);var s=Object.getOwnPropertyDescriptor(t,n);(!s||("get"in s?!t.__esModule:s.writable||s.configurable))&&(s={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,s)}:function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]}),$s=rt&&rt.__exportStar||function(e,t){for(var n in e)n!=="default"&&!Object.prototype.hasOwnProperty.call(t,n)&&Kf(t,e,n)};Object.defineProperty(rt,"__esModule",{value:!0});$s(Fs(),rt);$s(Os(),rt);$s(ed(),rt)});function Hs(e){Po.id!==e.id&&(Object.assign(Po,e),Us.forEach(t=>t(e)))}var Po,Us,nd,js=m(()=>{"use strict";i();k();Po={id:null,theme:null},Us=new Set,nd=()=>{let[,e]=b.useState(Po);return b.useEffect(()=>(Us.add(e),()=>void Us.delete(e)),[]),Po}});function At(e){if(Object.prototype.hasOwnProperty.call(Wt,e))return Wt[e];let t=Object.values(Wt).find(n=>n.aliases?.includes(e));return t?(Zf.set(e,t),t):null}var Yf,Qf,od,Jf,Xf,Wt,rd,id,Zf,ko=m(()=>{"use strict";i();Yf="Vap0r1ze/vapcord",Qf="88a7032a59cca40da170926651b08201ea3b965a",od=`https://raw.githubusercontent.com/${Yf}/${Qf}/assets/shiki-codeblocks`,Jf=e=>`${od}/${e}`,Xf=`${od}/languages.json`,Wt={},rd=async()=>{let e=await fetch(Xf).then(n=>n.json()),t=Object.fromEntries(e.map(n=>[n.id,{...n,grammarUrl:Jf(n.fileName)}]));Object.assign(Wt,t)},id=e=>e.grammar?Promise.resolve(e.grammar):fetch(e.grammarUrl).then(t=>t.json()),Zf=new Map});var Vf,eg,z,it,Gs=m(()=>{"use strict";i();Vf="shikijs/shiki",eg="0b28ad8ccfbf2615f2d9d38ea8255416b8ac3043",z=e=>`https://raw.githubusercontent.com/${Vf}/${eg}/packages/shiki/themes/${e}.json`,it={DarkPlus:z("dark-plus"),MaterialCandy:"https://raw.githubusercontent.com/millsp/material-candy/master/material-candy.json",DraculaSoft:z("dracula-soft"),Dracula:z("dracula"),GithubDarkDimmed:z("github-dark-dimmed"),GithubDark:z("github-dark"),GithubLight:z("github-light"),LightPlus:z("light-plus"),MaterialDarker:z("material-darker"),MaterialDefault:z("material-default"),MaterialLighter:z("material-lighter"),MaterialOcean:z("material-ocean"),MaterialPalenight:z("material-palenight"),MinDark:z("min-dark"),MinLight:z("min-light"),Monokai:z("monokai"),Nord:z("nord"),OneDarkPro:z("one-dark-pro"),Poimandres:z("poimandres"),RosePineDawn:z("rose-pine-dawn"),RosePineMoon:z("rose-pine-moon"),RosePine:z("rose-pine"),SlackDark:z("slack-dark"),SlackOchin:z("slack-ochin"),SolarizedDark:z("solarized-dark"),SolarizedLight:z("solarized-light"),VitesseDark:z("vitesse-dark"),VitesseLight:z("vitesse-light"),CssVariables:z("css-variables")}});var ad,zs,sd,H,Ws=m(()=>{"use strict";i();Qn();ad=Ra(td());js();ko();Gs();zs=Object.values(it),H={client:null,currentTheme:null,currentThemeUrl:null,timeoutMs:1e4,languages:Wt,themes:it,loadedThemes:new Set,loadedLangs:new Set,clientPromise:new Promise(e=>sd=e),init:async e=>{let t=await fetch(Mc).then(s=>s.blob()),n=H.client=new ad.WorkerClient("shiki-client","shiki-host",t,{name:"ShikiWorker"});await n.init();let r=e||zs[0];await rd(),await n.run("setOnigasm",{wasm:Rc}),await n.run("setHighlighter",{theme:r,langs:[]}),H.loadedThemes.add(r),await H._setTheme(r),sd(n)},_setTheme:async e=>{H.currentThemeUrl=e;let{themeData:t}=await H.client.run("getTheme",{theme:e});H.currentTheme=JSON.parse(t),Hs({id:e,theme:H.currentTheme})},loadTheme:async e=>{let t=await H.clientPromise;H.loadedThemes.has(e)||(await t.run("loadTheme",{theme:e}),H.loadedThemes.add(e))},setTheme:async e=>{await H.clientPromise,e||=zs[0],H.loadedThemes.has(e)||await H.loadTheme(e),await H._setTheme(e)},loadLang:async e=>{let t=await H.clientPromise,n=At(e);!n||H.loadedLangs.has(n.id)||(await t.run("loadLanguage",{lang:{...n,grammar:n.grammar??await id(n)}}),H.loadedLangs.add(n.id))},tokenizeCode:async(e,t)=>{let n=await H.clientPromise,r=At(t);return r?(H.loadedLangs.has(r.id)||await H.loadLang(r.id),await n.run("codeToThemedTokens",{code:e,lang:t,theme:H.currentThemeUrl??zs[0]})):[]},destroy(){H.currentTheme=null,H.currentThemeUrl=null,Hs({id:null,theme:null}),H.client?.destroy()}}});var cd,ld=m(()=>{"use strict";i();k();O();cd=(e=!1)=>{let t=b.useRef(null),[n,r]=b.useState(!1);return[a=>{t.current?.disconnect(),t.current=null,a&&(Jo(a)&&(r(!0),e)||(t.current=new IntersectionObserver(c=>{for(let f of c)f.target===a&&(f.isIntersecting&&e?(r(!0),t.current?.disconnect(),t.current=null):r(f.isIntersecting))}),t.current.observe(a)))},n]}});function pd(e){return De(e.map(t=>`plugins.ShikiCodeblocks.${t}`)).plugins.ShikiCodeblocks}var dd=m(()=>{"use strict";i();R()});function md(e){return e=e.slice(1),e.length<6&&(e=e.split("").map(t=>t+t).join("")),e.length===6&&(e+="ff"),e.length>6&&(e=e.slice(0,6)),e.split(/(..)/).filter(Boolean).map(t=>parseInt(t,16))}var ud=m(()=>{"use strict";i()});var Io=m(()=>{"use strict";i()});var je,fd,Mn=m(()=>{"use strict";i();k();ko();Io();je=e=>`shiki-${e}`,fd=({lang:e,tryHljs:t})=>{let n=e?Jt?.getLanguage?.(e):null,s=(e?At(e):null)?.name;switch(t){case"ALWAYS":return!0;case"PRIMARY":return!!n||e==="";case"SECONDARY":return!s&&!!n;case"NEVER":return!1}return!1}});function gd(e){let[t,n]=b.useState(!1);function r(s){Ee.copy(s),n(!0),setTimeout(()=>{n(!1)},e)}return[t,r]}var hd=m(()=>{"use strict";i();k()});function yd({content:e,...t}){let[n,r]=gd(1e3);return o("button",{...t,style:{...t.style,cursor:n?"default":void 0},onClick:()=>r(e)},n?"Copied!":"Copy")}var vd=m(()=>{"use strict";i();hd()});function bd({content:e,theme:t}){let n=[];return Ee.SUPPORTS_COPY&&n.push(o(yd,{content:e,className:je("btn"),style:{backgroundColor:t.accentBgColor,color:t.accentFgColor}})),o("div",{className:je("btns")},n)}var Sd=m(()=>{"use strict";i();k();Mn();vd()});var xd,Td=m(()=>{"use strict";i();Mn();xd=({theme:e,useHljs:t,lang:n,content:r,tokens:s})=>{let a;if(t)try{let{value:f}=hljs.highlight(n,r,!0);a=f.split(` +`).map((d,v)=>o("span",{key:v,dangerouslySetInnerHTML:{__html:d}}))}catch{a=r.split(` +`).map(f=>o("span",null,f))}else a=(s??r.split(` +`).map(d=>[{color:e.plainColor,content:d}])).map(d=>d.length===0?o("span",null,` +`):o(l,null,d.map(({content:v,color:h,fontStyle:g},w)=>o("span",{key:w,style:{color:h,fontStyle:(g??0)&1?"italic":void 0,fontWeight:(g??0)&2?"bold":void 0,textDecoration:(g??0)&4?"underline":void 0}},v))));let c=a.map((f,d)=>o("tr",{key:d},o("td",{style:{color:e.plainColor}},d+1),o("td",null,f)));return o("table",{className:je("table")},...c)}});function wd({langName:e,useDevIcon:t,shikiLang:n}){return e?o("div",{className:je("lang")},t!=="DISABLED"&&n?.devicon&&o("i",{className:`devicon-${n.devicon}${t==="COLOR"?" colored":""}`}),e):o(l,null)}var Pd=m(()=>{"use strict";i();Io();Mn()});var qs,og,kd=m(()=>{"use strict";i();ne();O();ld();k();ko();Ws();dd();js();ud();Mn();Sd();Td();Pd();qs=e=>o(D,null,o(og,{...e})),og=({lang:e,content:t,isPreview:n})=>{let{tryHljs:r,useDevIcon:s,bgOpacity:a}=pd(["tryHljs","useDevIcon","bgOpacity"]),{id:c,theme:f}=nd(),d=e?At(e):null,v=fd({lang:e,tryHljs:r}),[h,g]=cd(!0),[w]=ve(async()=>!d||v||!g?null:await H.tokenizeCode(t,e),{fallbackValue:null,deps:[e,t,c,g]}),P={plainColor:f?.fg||"var(--text-normal)",accentBgColor:f?.colors?.["statusBar.background"]||(v?"#7289da":"#007BC8"),accentFgColor:f?.colors?.["statusBar.foreground"]||"#FFF",backgroundColor:f?.colors?.["editor.background"]||"var(--background-secondary)"},B;e&&(B=v?Jt?.getLanguage?.(e)?.name:d?.name);let _=[je("root")];return B||_.push(je("plain")),n&&_.push(je("preview")),o("pre",{ref:h,className:_.join(" "),style:{backgroundColor:v?P.backgroundColor:`rgba(${md(P.backgroundColor).concat(a/100).join(", ")})`,color:P.plainColor}},o("code",null,o(wd,{langName:B,useDevIcon:s,shikiLang:d}),o(xd,{theme:P,useHljs:v,lang:e,content:t,tokens:w}),!n&&o(bd,{content:t,theme:P})))}});function Mo(e,t){let n=document.createElement("style");n.innerText=e,document.head.appendChild(n),Rn.set(t,n)}function Id(e){return Rn.get(e)?.remove(),Rn.delete(e)}var Rn,Md,Rd=m(()=>{"use strict";i();Rn=new Map;Md=()=>{Rn.forEach(e=>e.remove()),Rn.clear()}});var rg,Cd,Cn,Ks,Ad=m(()=>{"use strict";i();x();O();Kp();T();Qp();Ys();Ws();Gs();kd();Io();Rd();rg=Object.keys(it),Cd="@import url('https://cdn.jsdelivr.net/gh/devicons/devicon@v2.10.1/devicon.min.css');",Cn=()=>S.plugins.ShikiCodeblocks,Ks=u({name:"ShikiCodeblocks",description:"Brings vscode-style codeblocks into Discord, powered by Shiki",authors:[p.Vap],patches:[{find:"codeBlock:{react:function",replacement:{match:/codeBlock:\{react:function\((.),(.),(.)\)\{/,replace:"$&return Vencord.Plugins.plugins.ShikiCodeblocks.renderHighlighter($1,$2,$3);"}}],start:async()=>{Mo(Yp,"MAIN"),Cn().useDevIcon!=="DISABLED"&&Mo(Cd,"DEVICONS"),await H.init(Cn().customTheme||Cn().theme)},stop:()=>{H.destroy(),Md()},options:{theme:{type:4,description:"Default themes",options:rg.map(e=>({label:qp(Wp(e)),value:it[e],default:it[e]===it.DarkPlus})),disabled:()=>!!Cn().customTheme,onChange:H.setTheme},customTheme:{type:0,description:"A link to a custom vscode theme",placeholder:it.MaterialCandy,isValid:e=>{if(!e)return!0;let t=Qo(e);return t?t.pathname.endsWith(".json")?!0:"Must be a json file":"Must be a valid URL"},onChange:e=>H.setTheme(e||Cn().theme)},tryHljs:{type:4,description:"Use the more lightweight default Discord highlighter and theme.",options:[{label:"Never",value:"NEVER"},{label:"Prefer Shiki instead of Highlight.js",value:"SECONDARY",default:!0},{label:"Prefer Highlight.js instead of Shiki",value:"PRIMARY"},{label:"Always",value:"ALWAYS"}]},useDevIcon:{type:4,description:"How to show language icons on codeblocks",options:[{label:"Disabled",value:"DISABLED"},{label:"Colorless",value:"GREYSCALE",default:!0},{label:"Colored",value:"COLOR"}],onChange:e=>{e==="DISABLED"?Id("DEVICONS"):Mo(Cd,"DEVICONS")}},bgOpacity:{type:5,description:"Background opacity",markers:[0,20,40,60,80,100],default:100,stickToMarkers:!1}},shiki:H,createHighlighter:qs,renderHighlighter:({lang:e,content:t})=>qs({lang:e,content:t,isPreview:!1})})});var ig,sg,Qs,Js,_d=m(()=>{"use strict";i();R();Ne();x();Ye();T();L();k();ig=1048576n,sg=1024n,Qs=(e,t)=>!0;$(e=>e.can&&e.initialize,e=>({can:Qs}=e));Js=u({name:"ShowHiddenChannels",description:"Show hidden channels",authors:[p.BigDuck,p.AverageReactEnjoyer,p.D3SOX],options:{hideUnreads:{description:"Hide unreads",type:3,default:!0,restartNeeded:!0}},patches:[{find:".CannotShow",replacement:{match:/renderLevel:(\w+)\.CannotShow/g,replace:"renderLevel:Vencord.Plugins.plugins.ShowHiddenChannels.shouldShow(this.record, this.category, this.isMuted)?$1.Show:$1.CannotShow"}},{find:".rulesChannelId))",replacement:{match:/(\w+)\.locked(.*?)switch\((\w+)\.type\)({case \w+\.\w+\.GUILD_ANNOUNCEMENT)/g,replace:"Vencord.Plugins.plugins.ShowHiddenChannels.isHiddenChannel($3)||$1.locked$2switch($3._isHiddenChannel?2:$3.type)$4"}},{find:".handleThreadsPopoutClose();",replacement:{match:/((\w)\.handleThreadsPopoutClose\(\);)/g,replace:"if(arguments[0].button===0&&Vencord.Plugins.plugins.ShowHiddenChannels.channelSelected($2?.props?.channel))return;$1"}},{find:".prototype.shouldShowEmptyCategory=function(){",replacement:{match:/(\.prototype\.shouldShowEmptyCategory=function\(\){)/g,replace:"$1return true;"}},{find:'?"button":"link"',predicate:()=>S.plugins.ShowHiddenChannels.hideUnreads===!0,replacement:{match:/(\w)\.connected,(\w)=(\w\.unread),(\w=\w\.canHaveDot)/g,replace:"$1.connected,$2=Vencord.Plugins.plugins.ShowHiddenChannels.isHiddenChannel($1.channel)?false:$3,$4"}},{find:'.displayName="ChannelListUnreadsStore"',replacement:{match:/((.)\.getGuildId\(\))(&&\(!\(.\.isThread.{1,100}\.hasRelevantUnread\()/,replace:"$1&&!$2._isHiddenChannel$3"}}],shouldShow(e,t,n){return!this.isHiddenChannel(e)||!t||e.type===0&&t.guild?.hideMutedChannels&&n?!1:!t.isCollapsed},isHiddenChannel(e){return!e||(e.channelId&&(e=ae.getChannel(e.channelId)),!e||e.isDM()||e.isGroupDM()||e.isMultiUserDM())?!1:(e._isHiddenChannel=!Qs(sg,e)||e.type===2&&!Qs(ig,e),e._isHiddenChannel)},channelSelected(e){if(!e)return!1;let t=this.isHiddenChannel(e);if(e.type===0&&t){let n=e.lastActiveTimestamp?new Date(e.lastActiveTimestamp).toLocaleString():null;we(r=>o(Be,{size:"small",...r},o(nt,null,o(Z,null,o(Y,{variant:"heading-md/bold"},e.name),e.isNSFW()&&o(Y,{style:{backgroundColor:"var(--status-danger)",borderRadius:"8px",paddingLeft:4,paddingRight:4},variant:"heading-md/normal"},"NSFW"))),o(ot,{style:{marginBottom:10,marginTop:10,marginRight:8,marginLeft:8}},o(Y,{variant:"text-md/normal"},"You don't have the permission to view the messages in this channel."),(e.topic||"").length>0&&o(l,null,o(Y,{variant:"text-md/bold",style:{marginTop:10}},"Topic:"),o(Y,{variant:"code"},e.topic)),n&&o(l,null,o(Y,{variant:"text-md/bold",style:{marginTop:10}},"Last message sent:"),o(Y,{variant:"code"},n))),o(sn,null,o(Z,null,o(F,{onClick:r.onClose,size:F.Sizes.SMALL,color:F.Colors.PRIMARY},"Close")))))}return t}})});var Xs,Ld=m(()=>{"use strict";i();x();T();Xs=u({name:"SilentTyping",authors:[p.Ven],description:"Hide that you are typing",patches:[{find:"startTyping:",replacement:{match:/startTyping:.+?,stop/,replace:"startTyping:()=>{},stop"}}]})});var Ed,Fd=m(()=>{i();Ed=`#vc-spotify-player { + padding: 0.375rem 0.5rem; + border-bottom: 1px solid var(--background-modifier-accent); + --vc-spotify-green: #1db954; /* so cusotm themes can easily change it */ +} +.vc-spotify-button { + background: none; + color: var(--interactive-normal); + padding: 0; + width: 32px; + height: 32px; + + border-radius: 100%; + display: flex; + justify-content: center; + align-items: center; +} +.vc-spotify-button:hover { + color: var(--interactive-hover); + background-color: var(--background-modifier-selected); +} + +.vc-spotify-button svg { + height: 24px; + width: 24px; +} +[class*="vc-spotify-shuffle"] > svg, +[class*="vc-spotify-repeat"] > svg { + width: 22px; + height: 22px; +} +.vc-spotify-button svg path { + width: 100%; + height: 100%; +} +/* .vc-spotify-button:hover { + filter: brightness(1.3); +} */ + +.vc-spotify-shuffle-on, +.vc-spotify-repeat-context, +.vc-spotify-repeat-track, +.vc-spotify-shuffle-on:hover, +.vc-spotify-repeat-context:hover, +.vc-spotify-repeat-track:hover { + color: var(--vc-spotify-green); +} + +.vc-spotify-tooltip-text { + overflow: hidden; + white-space: nowrap; + padding-right: 0.2em; + max-width: 100%; +} +.vc-spotify-repeat-1 { + font-size: 70%; + position: absolute; + top: 50%; + left: 50%; + transform: translate(-50%, -50%); +} + +.vc-spotify-button-row { + justify-content: center; +} + +#vc-spotify-info-wrapper { + display: flex; + flex-direction: row; + align-items: center; + height: 3em; + gap: 0.5em; +} + +#vc-spotify-info-wrapper img { + height: 90%; + object-fit: contain; +} + +#vc-spotify-album-expanded-wrapper img { + width: 100%; + object-fit: contain; +} + +#vc-spotify-titles { + display: flex; + flex-direction: column; + padding: 0.2rem; + justify-content: center; + align-items: flex-start; + align-content: flex-start; + overflow: hidden; +} + +.vc-spotify-tooltip-text { + margin: unset; +} + +#vc-spotify-song-title { + color: var(--header-primary); + font-size: 14px; + font-weight: 600; +} +.vc-spotify-ellipoverflow { + white-space: nowrap; + overflow: hidden; + width: 100%; + text-overflow: ellipsis; +} + +.vc-spotify-artist, +.vc-spotify-album { + font-size: 12px; + text-decoration: none; + color: var(--header-secondary); +} + +.vc-spotify-comma { + color: var(--header-secondary); +} + +.vc-spotify-artist:hover, +#vc-spotify-album-title:hover, +#vc-spotify-song-title[role="link"]:hover { + text-decoration: underline; + cursor: pointer; +} + +#vc-spotify-album-image { + border-radius: 3px; +} + +#vc-spotify-album-image:hover { + filter: brightness(1.2); + cursor: pointer; +} + +#vc-spotify-progress-bar { + position: relative; + + color: var(--text-normal); + width: 100%; + margin: 0.5em 0; + margin-bottom: 5px; +} + +#vc-spotify-progress-bar > [class^="slider"] { + flex-grow: 1; + width: 100%; + padding: 0 !important; +} + +#vc-spotify-progress-bar > [class^="slider"] [class^="bar-"] { + height: 4px !important; +} +#vc-spotify-progress-bar > [class^="slider"] [class^="grabber"] { + /* these importants are neccessary, it applies a width and height through inline styles */ + height: 10px !important; + width: 10px !important; + background-color: var(--interactive-normal); + border-color: var(--interactive-normal); + color: var(--interactive-normal); +} + +#vc-spotify-progress-text { + margin: 0; +} + +.vc-spotify-progress-time { + font-size: 12px; + + top: 10px; + position: absolute; +} + +.vc-spotify-time-left { + left: 0; +} +.vc-spotify-time-right { + right: 0; +} +`});var W,Dd=m(()=>{"use strict";i();ze();Et();L();k();Fd();W=We(()=>{let e=document.createElement("style");e.innerText=Ed,document.head.appendChild(e);let{Store:t}=Uo,n=M("getActiveSocketAndDevice"),r=M("SpotifyAPIMarker"),s="https://api.spotify.com/v1/me/player";class a extends t{constructor(d,v){super(d,v)}mPosition=0;start=0;track=null;device=null;isPlaying=!1;repeat="off";shuffle=!1;volume=0;isSettingPosition=!1;openExternal(d){VencordNative.ipc.invoke(j.OPEN_EXTERNAL,"https://open.spotify.com"+d)}get position(){let d=this.mPosition;return this.isPlaying&&(d+=Date.now()-this.start),d}set position(d){this.mPosition=d,this.start=Date.now()}prev(){this.req("post","/previous")}next(){this.req("post","/next")}setVolume(d){this.req("put","/volume",{query:{volume_percent:Math.round(d)}}).then(()=>{this.volume=d,this.emitChange()})}setPlaying(d){this.req("put",d?"/play":"/pause")}setRepeat(d){this.req("put","/repeat",{query:{state:d}})}setShuffle(d){this.req("put","/shuffle",{query:{state:d}}).then(()=>{this.shuffle=d,this.emitChange()})}seek(d){return this.isSettingPosition?Promise.resolve():(this.isSettingPosition=!0,this.req("put","/seek",{query:{position_ms:Math.round(d)}}).catch(v=>{console.error("[VencordSpotifyControls] Failed to seek",v),this.isSettingPosition=!1}))}req(d,v,h={}){this.device?.is_active&&((h.query??={}).device_id=this.device.id);let{socket:g}=n.getActiveSocketAndDevice();return r[d](g.accountId,g.accessToken,{url:s+v,...h})}}let c=new a(I,{SPOTIFY_PLAYER_STATE(f){c.track=f.track,c.device=f.device??null,c.isPlaying=f.isPlaying??!1,c.volume=f.volumePercent??0,c.repeat=f.actual_repeat||"off",c.position=f.position??0,c.isSettingPosition=!1,c.emitChange()},SPOTIFY_SET_DEVICES({devices:f}){c.device=f.find(d=>d.is_active)??f[0]??null,c.emitChange()}});return c})});function Zs(e){let t=e/1e3/60,n=Math.floor(t),r=Math.floor((t-n)*60);return`${n.toString().padStart(2,"0")}:${r.toString().padStart(2,"0")}`}function Yt(e,t){return()=>o("svg",{className:ie(K("button-icon"),K(t)),height:"24",width:"24",viewBox:"0 0 24 24",fill:"currentColor","aria-label":t,focusable:!1},o("path",{d:e}))}function An(e){return o("button",{className:K("button"),...e},e.children)}function ug(){let[e,t,n]=Kt([W],()=>[W.isPlaying,W.shuffle,W.repeat]),[r,s]=(()=>{switch(n){case"off":return["context","repeat-off"];case"context":return["track","repeat-context"];case"track":return["off","repeat-track"];default:throw new Error(`Invalid repeat state ${n}`)}})();return o(Z,{className:K("button-row"),style:{gap:0}},o(An,{className:ie(K("button"),K(t?"shuffle-on":"shuffle-off")),onClick:()=>W.setShuffle(!t)},o(mg,null)),o(An,{onClick:()=>W.prev()},o(lg,null)),o(An,{onClick:()=>W.setPlaying(!e)},e?o(cg,null):o(ag,null)),o(An,{onClick:()=>W.next()},o(pg,null)),o(An,{className:ie(K("button"),K(s)),onClick:()=>W.setRepeat(r),style:{position:"relative"}},n==="track"&&o("span",{className:K("repeat-1")},"1"),o(dg,null)))}function gg(){let{duration:e}=W.track,[t,n,r]=Kt([W],()=>[W.mPosition,W.isSettingPosition,W.isPlaying]),[s,a]=b.useState(t);return b.useEffect(()=>{if(r&&!n){a(W.position);let c=setInterval(()=>{a(f=>f+1e3)},1e3);return()=>clearInterval(c)}},[t,n,r]),o("div",{id:K("progress-bar")},o(y.FormText,{variant:"text-xs/medium",className:K("progress-time")+" "+K("time-left"),"aria-label":"Progress"},Zs(s)),o(Nd,{minValue:0,maxValue:e,value:s,onChange:c=>{n||(a(c),fg(c))},renderValue:Zs}),o(y.FormText,{variant:"text-xs/medium",className:K("progress-time")+" "+K("time-right"),"aria-label":"Total Duration"},Zs(e)))}function hg({track:e}){let t=Kt([W],()=>W.volume);return o(ue.ContextMenu,{navId:"spotify-album-menu",onClose:()=>I.dispatch({type:"CONTEXT_MENU_CLOSE"}),"aria-label":"Spotify Album Menu"},o(ue.MenuItem,{key:"open-album",id:"open-album",label:"Open Album",action:()=>W.openExternal(`/album/${e.album.id}`)}),o(ue.MenuItem,{key:"view-cover",id:"view-cover",label:"View Album Cover",action:()=>Vencord.Plugins.plugins.ViewIcons.openImage(e.album.image.url)}),o(ue.MenuControlItem,{id:"spotify-volume",key:"spotify-volume",label:"Volume",control:(n,r)=>o(Nd,{...n,ref:r,value:t,minValue:0,maxValue:100,onChange:gt(s=>W.setVolume(s))})}))}function yg({track:e}){let t=e?.album?.image,[n,r]=b.useState(!1),s=o(l,null,t&&o("img",{id:K("album-image"),src:t.url,alt:"Album Image",onClick:()=>r(!n),onContextMenu:a=>{Yo.open(a,()=>o(hg,{track:e}))}}));return n&&t?o("div",{id:K("album-expanded-wrapper")},s):o("div",{id:K("info-wrapper")},s,o("div",{id:K("titles")},o(y.FormText,{variant:"text-sm/semibold",id:K("song-title"),className:K("ellipoverflow"),role:e.id?"link":void 0,title:e.name,onClick:e.id?()=>{W.openExternal(`/track/${e.id}`)}:void 0},e.name),e.artists.some(a=>a.name)&&o(y.FormText,{variant:"text-sm/normal",className:K("ellipoverflow")},"by\xA0",e.artists.map((a,c)=>o(b.Fragment,{key:a.name},o(Pe,{className:K("artist"),disabled:!a.id,href:`https://open.spotify.com/artist/${a.id}`,style:{fontSize:"inherit"},title:a.name},a.name),c!==e.artists.length-1&&o("span",{className:K("comma")},", ")))),e.album.name&&o(y.FormText,{variant:"text-sm/normal",className:K("ellipoverflow")},"on\xA0",o(Pe,{id:K("album-title"),href:`https://open.spotify.com/album/${e.album.id}`,target:"_blank",className:K("album"),disabled:!e.album.id,style:{fontSize:"inherit"},title:e.album.name},e.album.name))))}function Od(){let e=Kt([W],()=>W.track,null,(a,c)=>a?.id?a.id===c?.id:a?.name===c?.name),t=Kt([W],()=>W.device,null,(a,c)=>a?.id===c?.id),n=Kt([W],()=>W.isPlaying),[r,s]=b.useState(!1);return b.useEffect(()=>{if(s(!1),!n){let a=setTimeout(()=>s(!0),3e5);return()=>clearTimeout(a)}},[n]),!e||!t?.is_active||r?null:o(D,{fallback:()=>o(l,null,o(y.FormText,null,"Failed to render Spotify Modal :("),o(y.FormText,null,"Check the console for errors"))},o("div",{id:K("player")},o(yg,{track:e}),o(gg,null),o(ug,null)))}var K,Kt,ag,cg,lg,pg,dg,mg,fg,Nd,Bd=m(()=>{"use strict";i();ne();Ne();wt();yn();O();L();k();Dd();K=e=>`vc-spotify-${e}`;Kt=re("useStateFromStores");ag=Yt("M8 6.82v10.36c0 .79.87 1.27 1.54.84l8.14-5.18c.62-.39.62-1.29 0-1.69L9.54 5.98C8.87 5.55 8 6.03 8 6.82z","play"),cg=Yt("M8 19c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2s-2 .9-2 2v10c0 1.1.9 2 2 2zm6-12v10c0 1.1.9 2 2 2s2-.9 2-2V7c0-1.1-.9-2-2-2s-2 .9-2 2z","pause"),lg=Yt("M7 6c.55 0 1 .45 1 1v10c0 .55-.45 1-1 1s-1-.45-1-1V7c0-.55.45-1 1-1zm3.66 6.82l5.77 4.07c.66.47 1.58-.01 1.58-.82V7.93c0-.81-.91-1.28-1.58-.82l-5.77 4.07c-.57.4-.57 1.24 0 1.64z","previous"),pg=Yt("M7.58 16.89l5.77-4.07c.56-.4.56-1.24 0-1.63L7.58 7.11C6.91 6.65 6 7.12 6 7.93v8.14c0 .81.91 1.28 1.58.82zM16 7v10c0 .55.45 1 1 1s1-.45 1-1V7c0-.55-.45-1-1-1s-1 .45-1 1z","next"),dg=Yt("M7 7h10v1.79c0 .45.54.67.85.35l2.79-2.79c.2-.2.2-.51 0-.71l-2.79-2.79c-.31-.31-.85-.09-.85.36V5H6c-.55 0-1 .45-1 1v4c0 .55.45 1 1 1s1-.45 1-1V7zm10 10H7v-1.79c0-.45-.54-.67-.85-.35l-2.79 2.79c-.2.2-.2.51 0 .71l2.79 2.79c.31.31.85.09.85-.36V19h11c.55 0 1-.45 1-1v-4c0-.55-.45-1-1-1s-1 .45-1 1v3z","repeat"),mg=Yt("M10.59 9.17L6.12 4.7c-.39-.39-1.02-.39-1.41 0-.39.39-.39 1.02 0 1.41l4.46 4.46 1.42-1.4zm4.76-4.32l1.19 1.19L4.7 17.88c-.39.39-.39 1.02 0 1.41.39.39 1.02.39 1.41 0L17.96 7.46l1.19 1.19c.31.31.85.09.85-.36V4.5c0-.28-.22-.5-.5-.5h-3.79c-.45 0-.67.54-.36.85zm-.52 8.56l-1.41 1.41 3.13 3.13-1.2 1.2c-.31.31-.09.85.36.85h3.79c.28 0 .5-.22.5-.5v-3.79c0-.45-.54-.67-.85-.35l-1.19 1.19-3.13-3.14z","shuffle");fg=gt(e=>{W.seek(e)}),Nd=Q(()=>{let e=E.byCode("sliderContainer");return Ce(t=>t.render&&e(t.render))})});var Vs,$d=m(()=>{"use strict";i();x();T();Bd();Vs=u({name:"SpotifyControls",description:"Spotify Controls",authors:[p.Ven,p.afn,p.KraXen72],dependencies:["MenuItemDeobfuscatorAPI"],patches:[{find:"showTaglessAccountPanel:",replacement:{match:/return ?(.{0,30}\(.{1,3},\{[^}]+?,showTaglessAccountPanel:.+?\}\))/,replace:"return [Vencord.Plugins.plugins.SpotifyControls.renderPlayer(),$1]"}},{find:".PLAYER_DEVICES",replacement:{match:/get:(.{1,3})\.bind\(null,(.{1,6})\.get\)/,replace:"SpotifyAPIMarker:1,post:$1.bind(null,$2.post),$&"}},{find:'repeat:"off"!==',replacement:{match:/repeat:"off"!==(.{1,3}),/,replace:"actual_repeat:$1,$&"}}],renderPlayer:()=>o(Od,null)})});var ea,Ud=m(()=>{"use strict";i();R();x();T();X("SpotifyCrack","Ify");ea=u({name:"SpotifyCrack",description:"Free listen along, no auto-pausing in voice chat, and allows activity to continue playing when idling",authors:[p.Cyn,p.Nuckyz],patches:[{find:'dispatch({type:"SPOTIFY_PROFILE_UPDATE"',replacement:[{match:/(function\((.{1,2})\){)(.{1,6}dispatch\({type:"SPOTIFY_PROFILE_UPDATE")/,replace:(e,t,n,r)=>`${t}${n}.body.product="premium";${r}`}]},{find:'.displayName="SpotifyStore"',predicate:()=>S.plugins.SpotifyCrack.noSpotifyAutoPause,replacement:{match:/function (.{1,2})\(\).{0,200}SPOTIFY_AUTO_PAUSED\);.{0,}}}}/,replace:"function $1(){}"}},{find:'.displayName="SpotifyStore"',predicate:()=>S.plugins.SpotifyCrack.keepSpotifyActivityOnIdle,replacement:{match:/(shouldShowActivity=function\(\){.{1,50})&&!.{1,6}\.isIdle\(\)(.{0,}?})/,replace:(e,t,n)=>`${t}${n}`}}],options:{noSpotifyAutoPause:{description:"Disable Spotify auto-pause",type:3,default:!0,restartNeeded:!0},keepSpotifyActivityOnIdle:{description:"Keep Spotify activity playing when idling",type:3,default:!1,restartNeeded:!0}}})});function na(e,t){t={invalidEmojis:[],tts:!1,validNonShortcutEmojis:[],...t};let n=vg.getPendingReply(e);Hd.sendMessage(e,t,void 0,Hd.getSendMessageOptionsForReply(n)).then(()=>{n&&I.dispatch({type:"DELETE_PENDING_REPLY",channelId:e})})}var ta,Hd,vg,oa,jd=m(()=>{"use strict";i();be();R();x();T();L();k();ta=M("getPlayerState"),Hd=M("getSendMessageOptionsForReply","sendMessage"),vg=M("getPendingReply");X("SpotifyShareCommands","Sendify");oa=u({name:"SpotifyShareCommands",description:"Share your current Spotify track, album or artist via slash command (/track, /album, /artist)",authors:[p.katlyn],dependencies:["CommandsAPI"],commands:[{name:"track",description:"Send your current Spotify track to chat",inputType:0,options:[],execute:(e,t)=>{let n=ta.getTrack();if(n===null){U(t.channel.id,{content:"You're not listening to any music."});return}na(t.channel.id,{content:`https://open.spotify.com/track/${n.id}`})}},{name:"album",description:"Send your current Spotify album to chat",inputType:0,options:[],execute:(e,t)=>{let n=ta.getTrack();if(n===null){U(t.channel.id,{content:"You're not listening to any music."});return}na(t.channel.id,{content:`https://open.spotify.com/album/${n.album.id}`})}},{name:"artist",description:"Send your current Spotify artist to chat",inputType:0,options:[],execute:(e,t)=>{let n=ta.getTrack();if(n===null){U(t.channel.id,{content:"You're not listening to any music."});return}na(t.channel.id,{content:n.artists[0].external_urls.spotify})}}]})});var Gd={};ee(Gd,{default:()=>wg});function bg({emoji:e,prefix:t,log:n,delta:r,instance:s}){return o(b.Fragment,null,o("span",null,s.sinceStart.toFixed(3),"s"),o("span",null,s.sinceLast.toFixed(3),"s"),o("span",null,r?.toFixed(0)??""),o("span",null,o("pre",null,e," ",t??" ",n)))}function Sg({title:e,logs:t,traceEnd:n}){let r=t.find(c=>c.timestamp)?.timestamp??0,s=r,a=t.map(c=>{let f=c.timestamp??s,d=(f-r)/1e3,v=(f-s)/1e3;return s=f,{sinceStart:d,sinceLast:v}});return o(y.FormSection,{title:e,tag:"h1"},o("code",null,n&&o("div",{style:{color:"var(--header-primary)",marginBottom:5,userSelect:"text"}},"Trace ended at: ",new Date(n).toTimeString()),o("div",{style:{color:"var(--header-primary)",display:"grid",gridTemplateColumns:"repeat(3, auto) 1fr",gap:"2px 10px",userSelect:"text"}},o("span",null,"Start"),o("span",null,"Interval"),o("span",null,"Delta"),o("span",{style:{marginBottom:5}},"Event"),_n.logs.map((c,f)=>o(bg,{key:f,...c,instance:a[f]})))))}function xg({trace:e}){let t=e.split(` +`);return o(y.FormSection,{title:"Server Trace",tag:"h2"},o("code",null,o(Z,{flexDirection:"column",style:{color:"var(--header-primary)",gap:5,userSelect:"text"}},t.map(n=>o("span",null,n)))))}function Tg(){if(!_n?.logs)return o("div",null,"Loading...");let e=_n.logGroups.find(t=>t.serverTrace)?.serverTrace;return o(b.Fragment,null,o(Sg,{title:"Startup Timings",logs:_n.logs,traceEnd:_n.endTime_}),o("div",{style:{marginTop:5}},"\xA0"),e&&o(xg,{trace:e}))}var _n,wg,zd=m(()=>{"use strict";i();ne();Ne();L();k();_n=M("markWithDelta","markAndLog","markAt");wg=D.wrap(Tg)});var ra,Wd=m(()=>{"use strict";i();x();O();T();ra=u({name:"StartupTimings",description:"Adds Startup Timings to the Settings menu",authors:[p.Megu],patches:[{find:"PAYMENT_FLOW_MODAL_TEST_PAGE,",replacement:{match:/({section:[\w.]+?\.PAYMENT_FLOW_MODAL_TEST_PAGE,)/,replace:'{section:"StartupTimings",label:"Startup Timings",element:Vencord.Plugins.plugins.StartupTimings.StartupTimingPage},$1'}}],StartupTimingPage:Q(()=>(zd(),Ao(Gd)).default)})});var ia,qd=m(()=>{"use strict";i();pt();x();T();ia=u({name:"Unindent",description:"Trims leading indentation from codeblocks",authors:[p.Ven],dependencies:["MessageEventsAPI"],patches:[{find:"inQuote:",replacement:{match:/,content:([^,]+),inQuote/,replace:(e,t)=>`,content:Vencord.Plugins.plugins.Unindent.unindent(${t}),inQuote`}}],unindent(e){e=e.replace(/\t/g," ");let t=e.match(/^ *(?=\S)/gm)?.reduce((n,r)=>Math.min(n,r.length),1/0)??0;return t?e.replace(new RegExp(`^ {${t}}`,"gm"),""):e},unindentMsg(e){e.content=e.content.replace(/```(.|\n)*?```/g,t=>{let n=t.split(` +`);if(n.length<2)return t;let r="";return n[n.length-1]==="```"&&(r=n.pop()),`${n[0]} ${this.unindent(n.slice(1).join(` `))} -${o}`})},start(){this.preSend=W((e,t)=>this.unindentMsg(t)),this.preEdit=Re((e,t,n)=>this.unindentMsg(n))},stop(){H(this.preSend),ke(this.preEdit)}})});var go,Ca,ho,gi=a(()=>{"use strict";E();y();Ca="https://raw.githubusercontent.com/facebook/react/17.0.2/scripts/error-codes/codes.json",ho=c({name:"ReactErrorDecoder",description:'Replaces "Minifed React Error" with the actual error.',authors:[d.Cyn],patches:[{find:'"https://reactjs.org/docs/error-decoder.html?invariant="',replacement:{match:/(function .\(.\)){(for\(var .="https:\/\/reactjs\.org\/docs\/error-decoder\.html\?invariant="\+.,.=1;.`${t}{var decoded=Vencord.Plugins.plugins.ReactErrorDecoder.decodeError.apply(null, arguments);if(decoded)return decoded;${n}}`}}],async start(){go=await fetch(Ca).then(e=>e.json()).catch(e=>console.error(`[ReactErrorDecoder] Failed to fetch React error codes -`,e))},stop(){go=void 0},decodeError(e,...t){let n=0;return go?.[e]?.replace(/%s/g,()=>{let o=t[n];return n++,o})}})});function wa(e){return e.split(" ").map(t=>{let n=!1,o=t.toLowerCase();if(t.length<4)return t;for(let[r,i]of va)t.includes(r)&&(t=t.replace(r,i),n=!0);return o.includes("u")&&!o.includes("uwu")&&(t=t.replace("u","UwU"),n=!0),o.includes("o")&&!o.includes("owo")&&(t=t.replace("o","OwO"),n=!0),o.endsWith("y")&&t.length<7&&(t=t+" w"+t.slice(1),n=!0),n||(o.endsWith("n")||(t=t.replace("n","ny")),Math.floor(Math.random()*2)===1&&t.replace("s","sh"),Math.floor(Math.random()*5)===3&&!n&&(t=t[0]+"-"+t[0]+"-"+t),Math.floor(Math.random()*5)===3&&(t=t+" "+hi[Math.floor(Math.random()*hi.length)]),t=t.replaceAll("r","w").replaceAll("l","w")),t}).join(" ")}var hi,va,yo,yi=a(()=>{"use strict";re();y();hi=["owo","UwU",">w<","^w^","\u25CFw\u25CF","\u2606w\u2606","\u{1D5E8}\u{1D604}\u{1D5E8}","(\u15D2\u15E8\u15D5)","(\u25B0\u02D8v\u02D8\u25B0)","( \xB4 \u25BD ` ).\uFF61\uFF4F\u2661","*unbuttons shirt*",">3<",">:3",":3","murr~","\u2665(\u3002U \u03C9 U\u3002)","(\u02D8\u03B5\u02D8)","*screams*","*twerks*","*sweats*"],va=[["love","wuv"],["mr","mistuh"],["dog","doggo"],["cat","kitteh"],["hello","henwo"],["hell","heck"],["fuck","fwick"],["fuk","fwick"],["shit","shoot"],["friend","fwend"],["stop","stawp"],["god","gosh"],["dick","peepee"],["penis","bulge"],["damn","darn"]];yo=c({name:"UwUifier",description:"Simply uwuify commands",authors:[{name:"ECHO",id:712639419785412668n}],dependencies:["CommandsAPI"],commands:[{name:"uwuify",description:"uwuifies your messages",options:[ve],execute:e=>({content:wa(j(e,"message",""))})}]})});var bo,So,bi=a(()=>{"use strict";E();y();bo={},So=c({name:"vcDoubleClick",description:"Join VCs via DoubleClick instead of single click",authors:[d.Ven],patches:[{find:"VoiceChannel.renderPopout",replacement:{match:/onClick:function\(\)\{(e\.handleClick.+?)}/g,replace:"onClick:function(){Vencord.Plugins.plugins.vcDoubleClick.schedule(()=>{$1}, e)}"}},{find:'className:"channelMention",iconType:(',replacement:{match:/onClick:(.{1,3}),/,replace:"onClick:(_vcEv)=>_vcEv.detail>=2&&($1)(),"}}],schedule(e,t){let n=t.props.channel.id,o=bo[n]??={timeout:void 0,i:0};clearTimeout(o.timeout),++o.i>=2?(e(),delete bo[n]):o.timeout=setTimeout(()=>{delete bo[n]},500)}})});var Ra,ka,Et,xo,Si=a(()=>{"use strict";E();O();mt();y();A();v();Ra=C(e=>e.prototype?.render?.toString().includes("OPEN_ORIGINAL_IMAGE")),ka=te(()=>X(e=>e.type?.toString().includes("MASKED_LINK)"))),Et="Vencord.Plugins.plugins.ViewIcons.openImage(",xo=c({name:"ViewIcons",authors:[d.Ven],description:"Makes Avatars/Banners in user profiles clickable, and adds Guild Context Menu Entries to View Banner/Icon.",openImage(e){In(t=>Vencord.Webpack.Common.React.createElement(qe,{size:"dynamic",...t},Vencord.Webpack.Common.React.createElement(Ra,{shouldAnimate:!0,original:e,src:e,renderLinkComponent:n=>f.createElement(ka(),n)})))},patches:[{find:"onAddFriend:",replacement:{match:/\{src:(.{1,2}),avatarDecoration/g,replace:(e,t)=>`{src:${t},onClick:()=>${Et}${t}.replace(/\\?.+$/, "")+"?size=2048"),avatarDecoration`}},{find:"().popoutNoBannerPremium",replacement:{match:/style:.{0,10}\{\},(.{1,2})\)/,replace:(e,t)=>`onClick:${t}.backgroundImage&&(${t}.cursor="pointer",()=>${Et}${t}.backgroundImage.replace("url(", "").replace(/(\\?size=.+)?\\)/, "?size=2048"))),${e}`}},{find:'"GuildContextMenu:',replacement:[{match:/\w=(\w)\.id/,replace:(e,t)=>`_guild=${t},${e}`},{match:/(?<=createElement\((.{1,5}),\{id:"leave-guild".{0,100},)(.{1,2}\.createElement)\((.{1,5}),null,(.{1,2})\)(?=\)\}function)/,replace:(e,t,n,o,r)=>`${n}(${o},null,[_guild.icon&&${n}(${t},{id:"viewicons-copy-icon",label:"View Icon",action:()=>${Et}_guild.getIconURL(void 0,true)+"size=2048")}),_guild.banner&&${n}(${t},{id:"viewicons-copy-banner",label:"View Banner",action:()=>${Et}Vencord.Webpack.findByProps("getGuildBannerURL").getGuildBannerURL(_guild).replace(/\\?size=.+/, "?size=2048"))}),${r}])`}]}]})});var Eo,xi=a(()=>{"use strict";E();y();Eo=c({name:"Webhook Tags",description:"Changes the bot tag to say webhook for webhooks",authors:[d.Cyn],patches:[{find:'.BOT=0]="BOT"',replacement:[{match:/(.)\[.\.BOT=0\]="BOT";/,replace:(e,t)=>`${t}[${t}.WEBHOOK=99]="WEBHOOK";${e}`},{match:/case (.)\.BOT:default:(.)=/,replace:(e,t,n)=>`case ${t}.WEBHOOK:${n}="WEBHOOK";break;${e}`}]},{find:".Types.ORIGINAL_POSTER",replacement:{match:/return null==(.)\?null:.\.createElement\((.)\.Z/,replace:(e,t,n)=>`if(arguments[0].message.webhookId&&arguments[0].user.isNonUserBot()){${t}=${n}.Z.Types.WEBHOOK}${e}`}}]})});var V,Pt=a(()=>{Jo();Zo();er();tr();nr();or();rr();ir();sr();dr();pr();mr();ur();yr();Rr();kr();Ir();Mr();Br();Gr();jr();Hr();Kr();qr();Qr();Yr();Xr();Jr();Zr();ei();ti();ri();ii();ro();pi();mi();ui();fi();gi();yi();bi();Si();xi();V={[ln.name]:ln,[dn.name]:dn,[pn.name]:pn,[mn.name]:mn,[un.name]:un,[fn.name]:fn,[gn.name]:gn,[hn.name]:hn,[yn.name]:yn,[bn.name]:bn,[Sn.name]:Sn,[En.name]:En,[Pn.name]:Pn,[Fn.name]:Fn,[Dn.name]:Dn,[On.name]:On,[Ln.name]:Ln,[Un.name]:Un,[Vn.name]:Vn,[Gn.name]:Gn,[jn.name]:jn,[zn.name]:zn,[Wn.name]:Wn,[Hn.name]:Hn,[Kn.name]:Kn,[qn.name]:qn,[Qn.name]:Qn,[Yn.name]:Yn,[Xn.name]:Xn,[Jn.name]:Jn,[Zn.name]:Zn,[eo.name]:eo,[to.name]:to,[ao.name]:ao,[po.name]:po,[mo.name]:mo,[uo.name]:uo,[fo.name]:fo,[ho.name]:ho,[yo.name]:yo,[So.name]:So,[xo.name]:xo,[Eo.name]:Eo}});function Ei(e,t=e,n=""){return new Proxy(e,{get(o,r){let i=o[r];if(!(r in o)){if(n.startsWith("plugins.")){let l=n.slice(8);if(l in V){let m=V[l].options?.[r];if(!m)return i;if("default"in m)return m.default;if(m.type===4)return m.options.find(g=>g.default)?.value}}return i}return typeof i=="object"&&!Array.isArray(i)&&i!==null?Ei(i,t,`${n}${n&&"."}${r}`):i},set(o,r,i){if(o[r]===i)return!0;o[r]=i;let l=`${n}${n&&"."}${r}`;for(let m of Tt)(!m._path||m._path===l)&&m(i,l);return VencordNative.ipc.invoke(_.SET_SETTINGS,JSON.stringify(t,null,4)),!0}})}function _e(){let[,e]=f.useReducer(()=>({}),{});return f.useEffect(()=>(Tt.add(e),()=>void Tt.delete(e)),[]),P}function Ti(e,t){t._path=e,Tt.add(t)}var Po,$e,Tt,Pi,P,Fe=a(()=>{"use strict";Pt();Ue();O();y();v();Po={notifyAboutUpdates:!0,useQuickCss:!0,enableReactDevtools:!1,plugins:{}};for(let e in V)Po.plugins[e]={enabled:V[e].required??!1};try{$e=JSON.parse(VencordNative.ipc.sendSync(_.GET_SETTINGS)),Pe($e,Po)}catch(e){console.error("Corrupt settings file. ",e),$e=Pe({},Po)}Tt=new Set;Pi=$e,P=Ei($e)});var vo={};D(vo,{patches:()=>Ci,plugins:()=>Ia,startAllPlugins:()=>To,startPlugin:()=>Ct,stopPlugin:()=>Co});function To(){for(let e in V)P.plugins[e].enabled&&Ct(V[e])}function Ct(e){if(e.start){if(Z.info("Starting plugin",e.name),e.started)return Z.warn(`${e.name} already started`),!1;try{e.start(),e.started=!0}catch(t){return Z.error(`Failed to start ${e.name} -`,t),!1}}if(e.commands?.length){Z.info("Registering commands of plugin",e.name);for(let t of e.commands)try{$t(t,e.name)}catch(n){return Z.error(`Failed to register command ${t.name} -`,n),!1}}return!0}function Co(e){if(e.stop){if(Z.info("Stopping plugin",e.name),!e.started)return Z.warn(`${e.name} already stopped`),!1;try{e.stop(),e.started=!1}catch(t){return Z.error(`Failed to stop ${e.name} -`,t),!1}}if(e.commands?.length){Z.info("Unregistering commands of plugin",e.name);for(let t of e.commands)try{Gt(t.name)}catch(n){return Z.error(`Failed to unregister command ${t.name} -`,n),!1}}return!0}var Z,Ia,Ci,vt=a(()=>{"use strict";Pt();re();Fe();we();Z=new U("PluginManager","#a6d189"),Ia=V,Ci=[];for(let e of Object.values(V))if(e.patches&&P.plugins[e.name].enabled)for(let t of e.patches)t.plugin=e.name,Array.isArray(t.replacement)||(t.replacement=[t.replacement]),Ci.push(t)});var Ro={};D(Ro,{toggle:()=>wo});async function wo(e){Ae?Ae.disabled=!e:e&&(Ae=document.createElement("style"),Ae.id="vencord-custom-css",document.head.appendChild(Ae),VencordNative.ipc.on(_.QUICK_CSS_UPDATE,(t,n)=>Ae.innerText=n),Ae.innerText=await VencordNative.ipc.invoke(_.GET_QUICK_CSS))}var Ae,ko=a(()=>{"use strict";Fe();Ue();document.addEventListener("DOMContentLoaded",()=>{wo(P.useQuickCss),Ti("useQuickCss",wo)})});var _o={};D(_o,{UpdateLogger:()=>vi,changes:()=>Xe,checkForUpdates:()=>wi,getRepo:()=>ki,isNewer:()=>Io,isOutdated:()=>Je,rebuild:()=>Ii,update:()=>Ri,updateError:()=>Mo});async function Ge(e){let t=await e;if(t.ok)return t.value;throw Mo=t.error,t.error}async function wi(){return Xe=await Ge(VencordNative.ipc.invoke(_.GET_UPDATES)),Xe.some(e=>e.hash===Me)?(Io=!0,Je=!1):Je=Xe.length>0}async function Ri(){if(!Je)return!0;let e=await Ge(VencordNative.ipc.invoke(_.UPDATE));return e&&(Je=!1),e}function ki(){return Ge(VencordNative.ipc.invoke(_.GET_REPO))}async function Ii(){let e=await Ge(VencordNative.ipc.invoke(_.GET_HASHES));if(!await Ge(VencordNative.ipc.invoke(_.BUILD)))throw new Error("The Build failed. Please try manually building the new update");let t=await Ge(VencordNative.ipc.invoke(_.GET_HASHES));return e["patcher.js"]!==t["patcher.js"]||e["preload.js"]!==t["preload.js"]}var vi,Je,Io,Mo,Xe,wt=a(()=>{"use strict";Ye();Ue();we();vi=new U("Updater","white"),Je=!1,Io=!1});function Ma(){function e(t){try{let n=t[1],{subscriptions:o,listeners:r}=Vencord.Webpack,{patches:i}=Vencord.Plugins;for(let l in n){let m=n[l],g=m.toString().replaceAll(` -`,""),b=m,S=new Set;n[l]=function(s,p,T){try{m(s,p,T)}catch(w){if(m===b)throw w;return ee.error("Error in patched chunk",w),void b(s,p,T)}if(s.exports===window){Object.defineProperty(T.c,l,{value:T.c[l],enumerable:!1,configurable:!0,writable:!0});return}for(let w of r)try{w(p)}catch(x){ee.error("Error in webpack listener",x)}for(let[w,x]of o)try{if(w(p))o.delete(w),x(p);else if(typeof p=="object"){p.default&&w(p.default)&&(o.delete(w),x(p.default));for(let R in p)R.length<3&&p[R]&&w(p[R])&&(o.delete(w),x(p[R]))}}catch(R){ee.error("Error while firing callback for webpack chunk",R)}},n[l].toString=()=>m.toString(),n[l].original=b;for(let s=0;se,set:t=>e.original=t,configurable:!0})}var Mi,ee,_i=a(()=>{"use strict";E();we();A();ee=new U("WebpackInterceptor","#8caaee");Object.defineProperty(window,ie,{get:()=>Mi,set:e=>{e?.push!==Array.prototype.push&&(ee.info(`Patching ${ie}.push`),Mt(e),Ma(),delete window[ie],window[ie]=e),Mi=e},configurable:!0})});function Fo(e){return Vencord.Webpack.Common.React.createElement(ze,{className:e.className,style:{padding:"2em",backgroundColor:"#e7828430",borderColor:"#e78284",color:"var(--text-normal)",...e.style}},e.children)}var Ao=a(()=>{"use strict";v()});var _a,Fi,Ai,q,Ze=a(()=>{"use strict";we();v();Ao();_a="#e78284",Fi=new U("React ErrorBoundary",_a),Ai={},q=class extends f.Component{static wrap(t){return n=>Vencord.Webpack.Common.React.createElement(q,null,Vencord.Webpack.Common.React.createElement(t,{...n}))}state={error:Ai,stack:"",message:""};static getDerivedStateFromError(t){let n=t?.stack??"",o=t?.message||String(t);if(t instanceof Error&&n){let r=n.indexOf(` -`);r!==-1&&(o=n.slice(0,r),n=n.slice(r+1).replace(/https:\/\/\S+\/assets\//g,""))}return{error:t,stack:n,message:o}}componentDidCatch(t,n){this.props.onError?.(t,n),Fi.error(`A component threw an Error -`,t),Fi.error("Component Stack",n.componentStack)}render(){if(this.state.error===Ai)return this.props.children;if(this.props.fallback)return Vencord.Webpack.Common.React.createElement(this.props.fallback,{children:this.props.children,...this.state});let t=this.props.message||"An error occurred while rendering this Component. More info can be found below and in your console.";return Vencord.Webpack.Common.React.createElement(Fo,{style:{overflow:"hidden"}},Vencord.Webpack.Common.React.createElement("h1",null,"Oh no!"),Vencord.Webpack.Common.React.createElement("p",null,t),Vencord.Webpack.Common.React.createElement("code",null,this.state.message,!!this.state.stack&&Vencord.Webpack.Common.React.createElement("pre",{className:$.marginTop8},this.state.stack)))}}});function se(e){return e.style??={},e.style.flexDirection||=e.flexDirection,e.style.gap??="1em",e.style.display="flex",Vencord.Webpack.Common.React.createElement("div",{...e},e.children)}var et=a(()=>{"use strict"});function Ni(e){let t=new Na({username:e.name,id:He(),bot:!0});return I.dispatch({type:"USER_UPDATE",user:t}),t}function No({plugin:e,onRestartNeeded:t,onClose:n,transitionState:o}){let[r,i]=f.useState([]),l=_e().plugins[e.name],[m,g]=f.useState({}),[b,S]=f.useState({}),s=()=>Object.values(b).every(x=>!x);f.useEffect(()=>{(async()=>{for(let x of e.authors.slice(0,6)){let R=x.id?await Ft.fetchUser(`${x.id}`).catch(()=>null):Ni(x);i(Q=>[...Q,R||Ni(x)])}})()},[]);function p(){if(!e.options){n();return}let x=!1;for(let[R,Q]of Object.entries(m)){let N=e.options[R];l[R]=Q,N?.onChange?.(Q),N?.restartNeeded&&(x=!0)}x&&t(),n()}function T(){if(!l||!e.options)return Vencord.Webpack.Common.React.createElement(u.FormText,null,"There are no settings for this plugin.");let x=[];for(let[N,Y]of Object.entries(e.options)){let ae=function(je){g(Rt=>({...Rt,[N]:je}))},ge=function(je){S(Rt=>({...Rt,[N]:je}))};var R=ae,Q=ge;let ce={onChange:ae,pluginSettings:l,id:N,onError:ge};switch(Y.type){case 4:{x.push(Vencord.Webpack.Common.React.createElement(Pr,{key:N,option:Y,...ce}));break}case 0:{x.push(Vencord.Webpack.Common.React.createElement(vr,{key:N,option:Y,...ce}));break}case 1:case 2:{x.push(Vencord.Webpack.Common.React.createElement(xr,{key:N,option:Y,...ce}));break}case 3:{x.push(Vencord.Webpack.Common.React.createElement(br,{key:N,option:Y,...ce}));break}case 5:{x.push(Vencord.Webpack.Common.React.createElement(Cr,{key:N,option:Y,...ce}));break}}}return Vencord.Webpack.Common.React.createElement(se,{flexDirection:"column",style:{gap:12}},x)}function w(x,R){let Q=e.authors.length-R,N=e.authors.length-Q,Y=N+e.authors.length-R;return Vencord.Webpack.Common.React.createElement(Se,{text:e.authors.slice(N,Y).map(ae=>ae.name).join(", ")},({onMouseEnter:ae,onMouseLeave:ge})=>Vencord.Webpack.Common.React.createElement("div",{className:Aa.moreUsers,onMouseEnter:ae,onMouseLeave:ge},"+",Q))}return Vencord.Webpack.Common.React.createElement(qe,{transitionState:o,size:"medium"},Vencord.Webpack.Common.React.createElement(vn,null,Vencord.Webpack.Common.React.createElement(ne,{variant:"heading-md/bold"},e.name)),Vencord.Webpack.Common.React.createElement(wn,{style:{marginBottom:8,marginTop:8}},Vencord.Webpack.Common.React.createElement(u.FormSection,null,Vencord.Webpack.Common.React.createElement(u.FormTitle,{tag:"h3"},"About ",e.name),Vencord.Webpack.Common.React.createElement(u.FormText,null,e.description),Vencord.Webpack.Common.React.createElement("div",{style:{marginTop:8,marginBottom:8,width:"fit-content"}},Vencord.Webpack.Common.React.createElement(Fa,{users:r,count:e.authors.length,guildId:void 0,renderIcon:!1,max:6,showDefaultAvatarsForNullUsers:!0,showUserPopout:!0,renderMoreUsers:w}))),!!e.settingsAboutComponent&&Vencord.Webpack.Common.React.createElement("div",{style:{marginBottom:8}},Vencord.Webpack.Common.React.createElement(u.FormSection,null,Vencord.Webpack.Common.React.createElement(q,{message:"An error occurred while rendering this plugin's custom InfoComponent"},Vencord.Webpack.Common.React.createElement(e.settingsAboutComponent,null)))),Vencord.Webpack.Common.React.createElement(u.FormSection,null,Vencord.Webpack.Common.React.createElement(u.FormTitle,{tag:"h3"},"Settings"),T())),Vencord.Webpack.Common.React.createElement(Rn,null,Vencord.Webpack.Common.React.createElement(se,null,Vencord.Webpack.Common.React.createElement(M,{onClick:n,size:M.Sizes.SMALL,color:M.Colors.RED},"Exit Without Saving"),Vencord.Webpack.Common.React.createElement(Se,{text:"You must fix all errors before saving",shouldShow:!s()},({onMouseEnter:x,onMouseLeave:R})=>Vencord.Webpack.Common.React.createElement(M,{size:M.Sizes.SMALL,color:M.Colors.BRAND,onClick:p,onMouseEnter:x,onMouseLeave:R,disabled:!s()},"Save & Exit")))))}var Fa,Aa,Na,Di=a(()=>{"use strict";re();Fe();ue();mt();y();A();v();Ze();et();Nn();Fa=C(h.byCode("defaultRenderUser","showDefaultAvatarsForNullUsers")),Aa=C(h.byProps(["moreUsers","emptyUser","avatarContainer","clickableAvatar"])),Na=he(()=>F.getCurrentUser().constructor)});var Do,Oi,Li,Ui=a(()=>{"use strict";Do={marginTop:16,display:"grid",gridGap:16,gridTemplateColumns:"repeat(auto-fill, minmax(250px, 1fr))"},Oi={backgroundColor:"var(--background-modifier-selected)",color:"var(--interactive-active)",borderRadius:3,cursor:"pointer",display:"block",height:150,padding:10,width:"100%"},Li={gap:10,height:40,gridTemplateColumns:"1fr 150px",display:"grid"}});function La(e){B.show({message:e,type:B.Type.FAILURE,id:B.genId(),options:{position:B.Position.BOTTOM}})}function Vi({plugin:e,disabled:t,onRestartNeeded:n,onMouseEnter:o,onMouseLeave:r}){let i=_e().plugins[e.name];function l(){return i?.enabled||e.started}function m(){Qe.openModalLazy(async()=>b=>Vencord.Webpack.Common.React.createElement(No,{...b,plugin:e,onRestartNeeded:n}))}function g(){let b=l(),S=b?Co(e):Ct(e),s=b?"stop":"start";if(!S){La(`Failed to ${s} plugin: ${e.name}`);return}i.enabled=!i.enabled,e.patches&&n()}return Vencord.Webpack.Common.React.createElement(se,{style:Oi,flexDirection:"column",onClick:()=>m(),onMouseEnter:o,onMouseLeave:r},Vencord.Webpack.Common.React.createElement(ne,{variant:"text-md/bold"},e.name),Vencord.Webpack.Common.React.createElement(ne,{variant:"text-md/normal",style:{height:40,overflow:"hidden"}},e.description),Vencord.Webpack.Common.React.createElement(se,{flexDirection:"row-reverse",style:{marginTop:"auto",width:"100%",justifyContent:"space-between"}},Vencord.Webpack.Common.React.createElement(M,{onClick:b=>{b.preventDefault(),b.stopPropagation(),g()},disabled:t,color:l()?M.Colors.RED:M.Colors.GREEN},l()?"Disable":"Enable"),e.options&&Vencord.Webpack.Common.React.createElement(u.FormText,{style:{cursor:"pointer",margin:"auto 0 auto 10px"}},"Click to configure")))}function Ua(e){return Vencord.Webpack.Common.React.createElement(f.Fragment,null,Vencord.Webpack.Common.React.createElement(u.FormText,null,"This plugin is required by:"),e.map(t=>Vencord.Webpack.Common.React.createElement(u.FormText,{style:{margin:"0 auto"}},t)))}function Oo(e,t){return t[e]?.filter(n=>P.plugins[n].enabled)||[]}var Oa,Bi,$i,Gi=a(()=>{"use strict";Pt();Fe();vt();ue();dt();O();A();v();Ze();et();Di();Ui();Oa=C(h.byCode("optionClassName","popoutPosition","autoFocus","maxVisibleItems")),Bi=C(h.byProps(["inputDefault","inputWrapper"]));$i=q.wrap(function(){let t=_e(),n=f.useMemo(()=>new Ie,[]);f.useEffect(()=>()=>void(n.hasChanges&&Ee.show({title:"Restart required",body:Vencord.Webpack.Common.React.createElement(Vencord.Webpack.Common.React.Fragment,null,Vencord.Webpack.Common.React.createElement("p",null,"The following plugins require a restart:"),Vencord.Webpack.Common.React.createElement("div",null,n.map((s,p)=>Vencord.Webpack.Common.React.createElement(Vencord.Webpack.Common.React.Fragment,null,p>0&&", ",xe.parse("`"+s+"`"))))),confirmText:"Restart now",cancelText:"Later!",onConfirm:()=>location.reload()})),[]);let o=f.useMemo(()=>{let s={};for(let p in V){let T=V[p].dependencies;if(T)for(let w of T)s[w]??=[],s[w].push(p)}return s},[]);function r(s){return!!o[s.name]?.filter(T=>t.plugins[T].enabled)?.length}let i=f.useMemo(()=>Object.values(V).sort((s,p)=>s.name.localeCompare(p.name)),[]),[l,m]=f.useState({value:"",status:"all"}),g=s=>m(p=>({...p,value:s})),b=s=>m(p=>({...p,status:s})),S=s=>{let p=l.status==="enabled"||l.status==="all",T=l.status==="disabled"||l.status==="all",w=t.plugins[s.name]?.enabled||s.started;return(p&&w||T&&!w)&&(s.name.toLowerCase().includes(l.value.toLowerCase())||s.description.toLowerCase().includes(l.value.toLowerCase()))};return Vencord.Webpack.Common.React.createElement(u.FormSection,{tag:"h1",title:"Vencord"},Vencord.Webpack.Common.React.createElement(u.FormTitle,{tag:"h5",className:Te($.marginTop20,$.marginBottom8)},"Plugins"),Vencord.Webpack.Common.React.createElement("div",{style:Li},Vencord.Webpack.Common.React.createElement(de,{value:l.value,placeholder:"Search for a plugin...",onChange:g,style:{marginBottom:24}}),Vencord.Webpack.Common.React.createElement("div",{className:Bi.inputWrapper},Vencord.Webpack.Common.React.createElement(Oa,{className:Bi.inputDefault,options:[{label:"Show All",value:"all",default:!0},{label:"Show Enabled",value:"enabled"},{label:"Show Disabled",value:"disabled"}],serialize:s=>String(s),select:b,isSelected:s=>s===l.status,closeOnSelect:!0}))),Vencord.Webpack.Common.React.createElement("div",{style:Do},i?.length?i.filter(s=>!s.required&&!Oo(s.name,o).length&&S(s)).map(s=>{let T=o[s.name]?.filter(w=>t.plugins[w].enabled)?.length;return Vencord.Webpack.Common.React.createElement(Vi,{onRestartNeeded:()=>{n.handleChange(s.name)},disabled:s.required||!!T,plugin:s})}):Vencord.Webpack.Common.React.createElement(ne,{variant:"text-md/normal"},"No plugins meet search criteria.")),Vencord.Webpack.Common.React.createElement(u.FormDivider,null),Vencord.Webpack.Common.React.createElement(u.FormTitle,{tag:"h5",className:Te($.marginTop20,$.marginBottom8)},"Required Plugins"),Vencord.Webpack.Common.React.createElement("div",{style:Do},i?.length?i.filter(s=>s.required||Oo(s.name,o).length&&S(s)).map(s=>{let T=o[s.name]?.filter(x=>t.plugins[x].enabled)?.length,w=s.required?"This plugin is required for Vencord to function.":Ua(Oo(s.name,o));return Vencord.Webpack.Common.React.createElement(Se,{text:w},({onMouseLeave:x,onMouseEnter:R})=>Vencord.Webpack.Common.React.createElement(Vi,{onMouseLeave:x,onMouseEnter:R,onRestartNeeded:()=>{n.handleChange(s.name)},disabled:s.required||!!T,plugin:s}))}):Vencord.Webpack.Common.React.createElement(ne,{variant:"text-md/normal"},"No plugins meet search criteria.")))})});var ji,zi=a(()=>{"use strict";Fe();dt();Ue();O();v();Ze();et();ji=q.wrap(function(){let[t,,n]=pe(()=>VencordNative.ipc.invoke(_.GET_SETTINGS_DIR),"Loading..."),o=_e(),r=f.useMemo(()=>new Ie,[]);return f.useEffect(()=>()=>void(r.hasChanges&&Ee.show({title:"Restart required",body:Vencord.Webpack.Common.React.createElement(Vencord.Webpack.Common.React.Fragment,null,Vencord.Webpack.Common.React.createElement("p",null,"The following plugins require a restart:"),Vencord.Webpack.Common.React.createElement("div",null,r.map((i,l)=>Vencord.Webpack.Common.React.createElement(Vencord.Webpack.Common.React.Fragment,null,l>0&&", ",xe.parse("`"+i+"`"))))),confirmText:"Restart now",cancelText:"Later!",onConfirm:()=>location.reload()})),[]),Vencord.Webpack.Common.React.createElement(u.FormSection,{tag:"h1",title:"Vencord"},Vencord.Webpack.Common.React.createElement(u.FormTitle,{tag:"h5"},"Settings"),Vencord.Webpack.Common.React.createElement(u.FormText,null,"Settings Directory: ",Vencord.Webpack.Common.React.createElement("code",{style:{userSelect:"text",cursor:"text"}},t)),Vencord.Webpack.Common.React.createElement(se,{className:$.marginBottom20,style:{marginTop:8}},Vencord.Webpack.Common.React.createElement(M,{onClick:()=>VencordNative.ipc.send(_.OPEN_EXTERNAL,t),size:M.Sizes.SMALL,disabled:n},"Launch Directory"),Vencord.Webpack.Common.React.createElement(M,{onClick:()=>VencordNative.ipc.send(_.OPEN_EXTERNAL,t+"/quickCss.css"),size:M.Sizes.SMALL,disabled:t==="Loading..."},"Open QuickCSS File")),Vencord.Webpack.Common.React.createElement(u.FormDivider,null),Vencord.Webpack.Common.React.createElement(at,{value:o.useQuickCss,onChange:i=>o.useQuickCss=i,note:"Loads styles from your QuickCss file"},"Use QuickCss"),!1,!1)})});var Wi=a(()=>{"use strict"});var Hi,Ki=a(()=>{"use strict";Ye();O();wt();v();Ze();Ao();et();Wi();Hi=null});var qi={};D(qi,{PluginSettings:()=>$i,Settings:()=>ji,Updater:()=>Hi});var Qi=a(()=>{"use strict";Gi();zi();Ki()});async function Ba(){if(await kt,To(),Yi=await Promise.resolve().then(()=>(Qi(),qi)),!1)try{}catch(e){}}var Yi,K=a(()=>{"use strict";Xo();vt();ue();ko();wt();A();sn();Fe();vt();_i();ko();wt();A();v();Ba()});var Va={};D(Va,{Api:()=>an,Components:()=>Yi,PlainSettings:()=>Pi,Plugins:()=>vo,QuickCss:()=>Ro,Settings:()=>P,Updater:()=>_o,Util:()=>Mn,Webpack:()=>Nt});var nt,is=new Promise(e=>{setTimeout(()=>{new QWebChannel(qt.webChannelTransport,function(t){nt=t.objects.webclass,e()})})});async function Uo(){nt||await is}window.VencordNative={getVersions:()=>({}),ipc:{send:async(e,...t)=>{await Uo(),nt.vencordSend(e,t)},sendSync:(e,...t)=>{if(e==="VencordGetSettings")return window.discordScreenaudioVencordSettings||"{}";throw new Error("Synchroneous IPC not implemented")},on(e,t){},off(e,t){},invoke:async(e,...t)=>(await Uo(),e==="VencordSetSettings"&&(window.discordScreenaudioVencordSettings=t[0]),nt.vencordSend(e,t))}};K();return rs(Va);})(); +${r}`})},start(){this.preSend=$e((e,t)=>this.unindentMsg(t)),this.preEdit=Pt((e,t,n)=>this.unindentMsg(n))},stop(){Ue(this.preSend),kt(this.preEdit)}})});var sa,Pg,aa,Kd=m(()=>{"use strict";i();x();T();Pg="https://raw.githubusercontent.com/facebook/react/17.0.2/scripts/error-codes/codes.json",aa=u({name:"ReactErrorDecoder",description:'Replaces "Minifed React Error" with the actual error.',authors:[p.Cyn],patches:[{find:'"https://reactjs.org/docs/error-decoder.html?invariant="',replacement:{match:/(function .\(.\)){(for\(var .="https:\/\/reactjs\.org\/docs\/error-decoder\.html\?invariant="\+.,.=1;.`${t}{var decoded=Vencord.Plugins.plugins.ReactErrorDecoder.decodeError.apply(null, arguments);if(decoded)return decoded;${n}}`}}],async start(){sa=await fetch(Pg).then(e=>e.json()).catch(e=>console.error(`[ReactErrorDecoder] Failed to fetch React error codes +`,e))},stop(){sa=void 0},decodeError(e,...t){let n=0;return sa?.[e]?.replace(/%s/g,()=>{let r=t[n];return n++,r})}})});function Ig(e){return e.split(" ").map(t=>{let n=!1,r=t.toLowerCase();if(t.length<4)return t;for(let[s,a]of kg)t.includes(s)&&(t=t.replace(s,a),n=!0);return r.includes("u")&&!r.includes("uwu")&&(t=t.replace("u","UwU"),n=!0),r.includes("o")&&!r.includes("owo")&&(t=t.replace("o","OwO"),n=!0),r.endsWith("y")&&t.length<7&&(t=t+" w"+t.slice(1),n=!0),n||(r.endsWith("n")||(t=t.replace("n","ny")),Math.floor(Math.random()*2)===1&&t.replace("s","sh"),Math.floor(Math.random()*5)===3&&!n&&(t=t[0]+"-"+t[0]+"-"+t),Math.floor(Math.random()*5)===3&&(t=t+" "+Yd[Math.floor(Math.random()*Yd.length)]),t=t.replaceAll("r","w").replaceAll("l","w")),t}).join(" ")}var Yd,kg,ca,Qd=m(()=>{"use strict";i();be();x();T();Yd=["owo","UwU",">w<","^w^","\u25CFw\u25CF","\u2606w\u2606","\u{1D5E8}\u{1D604}\u{1D5E8}","(\u15D2\u15E8\u15D5)","(\u25B0\u02D8v\u02D8\u25B0)","( \xB4 \u25BD ` ).\uFF61\uFF4F\u2661","*unbuttons shirt*",">3<",">:3",":3","murr~","\u2665(\u3002U \u03C9 U\u3002)","(\u02D8\u03B5\u02D8)","*screams*","*twerks*","*sweats*"],kg=[["love","wuv"],["mr","mistuh"],["dog","doggo"],["cat","kitteh"],["hello","henwo"],["hell","heck"],["fuck","fwick"],["fuk","fwick"],["shit","shoot"],["friend","fwend"],["stop","stawp"],["god","gosh"],["dick","peepee"],["penis","bulge"],["damn","darn"]];ca=u({name:"UwUifier",description:"Simply uwuify commands",authors:[p.echo],dependencies:["CommandsAPI"],commands:[{name:"uwuify",description:"uwuifies your messages",options:[It],execute:e=>({content:Ig(ce(e,"message",""))})}]})});var la,pa,Jd=m(()=>{"use strict";i();R();x();T();k();la={};X("VoiceChatDoubleClick","vcDoubleClick");pa=u({name:"VoiceChatDoubleClick",description:"Join voice chats via double click instead of single click",authors:[p.Ven,p.D3SOX],patches:[{find:"VoiceChannel.renderPopout",replacement:[{match:/onClick:(.*)function\(\)\{(e\.handleClick.+?)}/g,replace:"onClick:$1function(){Vencord.Plugins.plugins.VoiceChatDoubleClick.schedule(()=>{$2}, e)}"},{match:/onClick:(.{0,15})this\.handleClick,/g,replace:"onClick:$1(...args)=>Vencord.Plugins.plugins.VoiceChatDoubleClick.schedule(()=>{this.handleClick(...args);}, args[0]),"}]},{find:'className:"channelMention",iconType:(',replacement:{match:/onClick:(.{1,3}),/,replace:"onClick:(_vcEv)=>(_vcEv.detail>=2||_vcEv.target.className.includes('MentionText'))&&($1)(),"}}],schedule(e,t){let n=t?.id??t.props.channel.id;if(pe.getVoiceChannelId()===n){e();return}let r=la[n]??={timeout:void 0,i:0};clearTimeout(r.timeout),++r.i>=2?(e(),delete la[n]):r.timeout=setTimeout(()=>{delete la[n]},500)}})});var Mg,Rg,Cg,Xd,da,Zd=m(()=>{"use strict";i();x();O();Ye();L();k();Mg=Q(()=>Ce(e=>e.prototype?.render?.toString().includes("OPEN_ORIGINAL_IMAGE"))),Rg=Q(()=>Ce(e=>e.type?.toString().includes("MASKED_LINK)"))),Cg=M("getGuildBannerURL"),Xd="Vencord.Plugins.plugins.ViewIcons.openImage(",da=new class{name="ViewIcons";authors=[p.Ven];description="Makes Avatars/Banners in user profiles clickable, and adds Guild Context Menu Entries to View Banner/Icon.";dependencies=["MenuItemDeobfuscatorAPI"];openImage(t){let n=new URL(t);n.searchParams.set("size","512"),t=n.toString(),we(r=>o(Be,{size:"dynamic",...r},o(Mg,{shouldAnimate:!0,original:t,src:t,renderLinkComponent:()=>o(Rg,null)})))}patches=[{find:"onAddFriend:",replacement:{match:/\{src:(.{1,2}),avatarDecoration/g,replace:(t,n)=>`{src:${n},onClick:()=>${Xd}${n}),avatarDecoration`}},{find:"().popoutNoBannerPremium",replacement:{match:/style:.{0,10}\{\},(.{1,2})\)/,replace:(t,n)=>`onClick:${n}.backgroundImage&&(${n}.cursor="pointer",()=>${Xd}${n}.backgroundImage.replace("url(", ""))),${t}`}},{find:'"GuildContextMenu:',replacement:[{match:/\w=(\w)\.id/,replace:"_guild=$1,$&"},{match:/(id:"leave-guild".{0,200}),(\(0,.{1,3}\.jsxs?\).{0,200}function)/,replace:"$1,Vencord.Plugins.plugins.ViewIcons.buildGuildContextMenuEntries(_guild),$2"}]}];buildGuildContextMenuEntries(t){return o(ue.MenuGroup,null,t.banner&&o(ue.MenuItem,{id:"view-banner",key:"view-banner",label:"View Banner",action:()=>this.openImage(Cg.getGuildBannerURL(t))}),t.icon&&o(ue.MenuItem,{id:"view-icon",key:"view-icon",label:"View Icon",action:()=>this.openImage(t.getIconURL(0,!0))}))}}});function _g(e){return Object.fromEntries(Object.entries(e).sort(([t],[n])=>t.localeCompare(n)))}function Lg(e){let t=_g(JSON.parse(JSON.stringify(e)));for(let r in t.author)switch(r){case"id":case"username":case"usernameNormalized":case"discriminator":case"avatar":case"bot":case"system":case"publicFlags":break;default:delete t.author[r]}let n=t;return delete n.editHistory,delete n.deleted,n.attachments?.forEach(r=>delete r.deleted),t}function Vd(e){return o("div",{style:{userSelect:"text"}},Ke.defaultRules.codeBlock.react(e,null,{}))}function Eg(e){e=Lg(e);let t=JSON.stringify(e,null,4),n=we(r=>o(D,null,o(Be,{...r,size:"large"},o(nt,null,o(y.FormTitle,{tag:"h1"},"View Raw"),o(cr,{onClick:()=>an(n)})),o(ot,{style:{padding:"1em"}},o(Z,{style:{marginBottom:"1em",marginTop:"1em"}},o(F,{onClick:()=>en(e.content,"Content copied to clipboard!")},"Copy Raw Content"),o(F,{onClick:()=>en(t,"Message data copied to clipboard!")},"Copy Message JSON")),!!e.content&&o(l,null,o(y.FormTitle,{tag:"h5"},"Content"),o(Vd,{content:e.content,lang:""}),o(y.FormDivider,{classes:V.marginBottom20})),o(y.FormTitle,{tag:"h5"},"Message Data"),o(Vd,{content:t,lang:"json"})))))}var Ag,ma,em=m(()=>{"use strict";i();fn();ne();Ne();x();O();Ye();T();k();Ag=()=>o("svg",{viewBox:"0 0 512.002 512.002",fill:"currentColor","aria-hidden":"true",width:"22",height:"22"},o("path",{d:"M462.002,92.002h-42.001V50c0-27.57-22.43-50-50-50h-320c-27.57,0-50,22.43-50,50v320.002c0,27.57,22.43,50,50,50h42.001 v42c0,27.57,22.43,50,50,50h320c27.57,0,50-22.43,50-50v-320C512.001,114.432,489.573,92.002,462.002,92.002z M50.001,400.002 c-16.542,0-30-13.458-30-30V50c0-16.542,13.458-30,30-30h320c16.542,0,30,13.458,30,30v320.002c0,16.542-13.458,30-30,30H50.001z M492.002,462.002c0,16.542-13.458,30-30,30h-320c-16.542,0-30-13.458-30-30v-42h257.999c27.57,0,50-22.43,50-50v-258h42.001 c16.542,0,30,13.458,30,30V462.002z"}),o("path",{d:"M462.024,457.002H170.98c-5.522,0-10,4.478-10,10c0,5.523,4.478,10,10,10h291.043c5.522,0,10-4.477,10-10 S467.546,457.002,462.024,457.002z"}),o("path",{d:"M142.25,457.002h-0.27c-5.522,0-10,4.478-10,10c0,5.523,4.478,10,10,10h0.27c5.523,0,10-4.477,10-10 S147.773,457.002,142.25,457.002z"}),o("path",{d:"M110.035,35h-0.27c-5.522,0-10,4.478-10,10s4.478,10,10,10h0.27c5.522,0,10-4.478,10-10S115.558,35,110.035,35z"}),o("path",{d:"M81.036,35H50.001c-5.522,0-10,4.478-10,10s4.478,10,10,10h31.034c5.523,0,10.001-4.478,10.001-10S86.558,35,81.036,35z"}),o("path",{d:"M122.084,246.829l-0.008-0.008l-14.8-30.002c5.407-2.305,10.07-5.975,13.466-10.537c3.725-5.006,5.931-11.08,5.931-17.604 c0-8.588-3.248-15.902-9.743-21.965c-3.196-2.992-6.739-5.242-10.627-6.744c-3.891-1.506-8.097-2.258-12.612-2.258H64.936 c-2.793,0-5.327,1.145-7.163,2.996c-1.832,1.85-2.968,4.396-2.968,7.205v82.777c0,2.896,1.137,5.338,2.893,7.105 c0.962,0.969,2.107,1.728,3.349,2.246c1.249,0.52,2.597,0.797,3.953,0.797c2.49,0,5.028-0.92,7.096-2.967 c1.004-0.99,1.761-2.09,2.271-3.297c0.516-1.221,0.771-2.516,0.771-3.885v-31.139h10.844l17.862,36.184l-0.004,0.005 c1.315,2.699,3.416,4.4,5.763,5.201c1.275,0.434,2.616,0.596,3.938,0.502c1.317-0.094,2.618-0.44,3.812-1.022 c2.307-1.123,4.237-3.123,5.179-5.881h0.002c0.45-1.307,0.639-2.609,0.564-3.904C123.023,249.327,122.684,248.058,122.084,246.829 z M106.124,190.85c-0.438,1.795-1.473,3.546-3.189,5.07c-1.205,1.039-2.538,1.838-3.996,2.395c-1.45,0.553-3.02,0.865-4.704,0.934 v-0.006H75.138v-21.221H93.69c3.19,0,5.9,0.893,7.984,2.328c1.83,1.26,3.187,2.939,3.96,4.791 C106.393,186.957,106.591,188.942,106.124,190.85z"}),o("path",{d:"M364.199,163.706c-1.12-2.354-3.136-4.285-5.777-5.254l-0.055-0.016c-2.721-0.916-5.49-0.688-7.823,0.439 c-2.349,1.135-4.243,3.172-5.193,5.861v0.008l-19.568,55.744l-19.571-55.816h-0.001c-0.705-2.352-2.14-4.141-3.935-5.322 c-1.589-1.047-3.458-1.609-5.345-1.656c-1.887-0.047-3.801,0.42-5.479,1.43c-1.938,1.164-3.553,3.031-4.445,5.637h0.002 l-19.564,55.73l-19.569-55.746l-0.008-0.016c-0.997-2.779-2.938-4.752-5.235-5.846c-1.222-0.584-2.552-0.918-3.899-0.99 c-1.34-0.074-2.701,0.115-3.991,0.578c-2.347,0.842-4.429,2.57-5.701,5.24c-1.206,2.529-1.354,5.119-0.441,7.766l0.005,0.009 l29.181,83.133l0.016,0.047c1.186,3.139,3.318,5.213,5.775,6.234c1.141,0.473,2.355,0.717,3.581,0.73 c1.219,0.016,2.438-0.197,3.595-0.635c2.602-0.982,4.914-3.084,6.238-6.268l0.039-0.109l19.595-55.779l20.043,56.877l0.047,0.125 c0.967,2.25,2.404,3.912,4.071,4.99c1.666,1.078,3.544,1.563,5.408,1.465c1.854-0.096,3.686-0.764,5.274-1.992 c1.666-1.289,3.059-3.191,3.899-5.686l29.251-83.133C365.546,168.825,365.317,166.053,364.199,163.706z"}),o("path",{d:"M226.7,247.37l-0.008-0.031l-8.818-21.24l-0.003,0.002l-25.528-61.617h0.001c-1.024-2.709-3.167-4.654-5.674-5.645 c-1.165-0.461-2.429-0.715-3.708-0.742c-1.28-0.027-2.565,0.178-3.773,0.635c-2.393,0.906-4.479,2.764-5.647,5.719l0.005,0.002 l-25.54,61.719h-0.003l-8.818,21.168v0.008c-1.076,2.607-1,5.383-0.008,7.783c0.994,2.408,2.91,4.433,5.51,5.527l0.038,0.023 c2.619,1.035,5.435,1.064,7.886,0.041c2.295-0.955,4.242-2.813,5.384-5.6l6.147-14.877h37.566l6.148,14.877 c1.175,2.844,3.171,4.674,5.459,5.609c1.261,0.518,2.601,0.752,3.932,0.73c1.324-0.021,2.642-0.295,3.865-0.801 c2.418-0.998,4.496-2.9,5.579-5.547l0.008-0.016C227.723,252.523,227.723,249.945,226.7,247.37z M172.552,219.938l10.344-25.01 l10.416,25.01H172.552z"}));ma=u({name:"ViewRaw",description:"Copy and view the raw content/data of any message.",authors:[p.KingFish,p.Ven],dependencies:["MessagePopoverAPI"],start(){Mt("ViewRaw",e=>({label:"View Raw (Left Click) / Copy Raw (Right Click)",icon:Ag,message:e,channel:ae.getChannel(e.channel_id),onClick:()=>Eg(e),onContextMenu:t=>{t.preventDefault(),t.stopPropagation(),en(e.content)}}))},stop(){Rt("CopyRawMessage")}})});var ua,tm=m(()=>{"use strict";i();Jn();x();T();ua=u({name:"VolumeBooster",authors:[p.Nuckyz],description:"Allows you to set the user and stream volume above the default maximum.",patches:[{find:".Messages.USER_VOLUME",replacement:{match:/maxValue:(.{1,2}\..{1,2})\?(\d+?):(\d+?),/,replace:(e,t,n,r)=>`maxValue:${t}?${n}*Vencord.Settings.plugins.VolumeBooster.multiplier:${r}*Vencord.Settings.plugins.VolumeBooster.multiplier,`}},{find:"currentVolume:",replacement:{match:/maxValue:(.{1,2}\..{1,2})\?(\d+?):(\d+?),/,replace:(e,t,n,r)=>`maxValue:${t}?${n}*Vencord.Settings.plugins.VolumeBooster.multiplier:${r}*Vencord.Settings.plugins.VolumeBooster.multiplier,`}}],options:{multiplier:{description:"Volume Multiplier",type:5,markers:Ot(1,5,1),default:2,stickToMarkers:!0}}})});var fa,nm=m(()=>{"use strict";i();x();T();fa=u({name:"WebContextMenus",description:"Re-adds some of context menu items missing on the web version of Discord, namely Copy/Open Link",authors:[p.Ven],target:"WEB",patches:[{find:"open-native-link",replacement:[{match:/if\(!\w\..{1,3}\|\|null==/,replace:"if(null=="},{match:/\w\.default\.copy/,replace:"Vencord.Webpack.Common.Clipboard.copy"}]}]})});var ga,om=m(()=>{"use strict";i();x();T();ga=u({name:"Webhook Tags",description:"Changes the bot tag to say webhook for webhooks",authors:[p.Cyn],patches:[{find:'.BOT=0]="BOT"',replacement:[{match:/(.)\[.\.BOT=0\]="BOT";/,replace:(e,t)=>`${t}[${t}.WEBHOOK=99]="WEBHOOK";${e}`},{match:/case (.)\.BOT:default:(.)=/,replace:(e,t,n)=>`case ${t}.WEBHOOK:${n}="WEBHOOK";break;${e}`}]},{find:".Types.ORIGINAL_POSTER",replacement:{match:/return null==(.)\?null:\(0,.{1,3}\.jsxs?\)\((.{1,3})\.Z/,replace:(e,t,n)=>`if(arguments[0].message.webhookId&&arguments[0].user.isNonUserBot()){${t}=${n}.Z.Types.WEBHOOK}${e}`}}]})});var Ln,ha=m(()=>{"use strict";i();Ln=class{constructor(t=1/0){this.maxSize=t}queue=[];promise;next(){let t=this.queue.shift();t?this.promise=Promise.resolve().then(t).finally(()=>this.next()):this.promise=void 0}run(){this.promise||this.next()}push(t){this.size>=this.maxSize&&this.queue.shift(),this.queue.push(t),this.run()}unshift(t){this.size>=this.maxSize&&this.queue.pop(),this.queue.unshift(t),this.run()}get size(){return this.queue.length}}});function Bg(e,t){let n=t.name+(t.id?`:${t.id}`:"");return Ho.get({url:`/channels/${e.channel_id}/messages/${e.id}/reactions/${n}`,query:{limit:100},oldFormErrors:!0}).then(r=>I.dispatch({type:"MESSAGE_REACTION_ADD_USERS",channelId:e.channel_id,messageId:e.id,users:r.body,emoji:t})).catch(console.error).finally(()=>Vt(250))}function $g(e,t){let n=`${e.id}:${t.name}:${t.id??""}`,r=Ng.__getLocalVars().reactions[n]??={fetched:!1,users:{}};return r.fetched||(Og.unshift(()=>Bg(e,t)),r.fetched=!0),r.users}function Ug(e){return function(n,r){return o(me,{text:e.slice(5).map(s=>s.username).join(", ")},({onMouseEnter:s,onMouseLeave:a})=>o("div",{className:Dg.moreUsers,onMouseEnter:s,onMouseLeave:a},"+",e.length-5))}}var Fg,Dg,Ng,Og,ya,rm=m(()=>{"use strict";i();ne();x();O();ha();T();L();k();Fg=Q(()=>xe("defaultRenderUser","showDefaultAvatarsForNullUsers")),Dg=M("moreUsers","emptyUser","avatarContainer","clickableAvatar"),Ng=M("getReactions"),Og=new Ln;ya=u({name:"WhoReacted",description:"Renders the Avatars of reactors",authors:[p.Ven],patches:[{find:",reactionRef:",replacement:{match:/((.)=(.{1,3})\.hideCount)(,.+?reactionCount.+?\}\))/,replace:"$1,whoReactedProps=$3$4,$2?null:Vencord.Plugins.plugins.WhoReacted.renderUsers(whoReactedProps)"}}],renderUsers(e){return e.message.reactions.length>10?null:o(D,{noop:!0},o(this._renderUsers,{...e}))},_renderUsers({message:e,emoji:t}){let n=ct();b.useEffect(()=>{let a=c=>{c.messageId===e.id&&n()};return I.subscribe("MESSAGE_REACTION_ADD_USERS",a),()=>I.unsubscribe("MESSAGE_REACTION_ADD_USERS",a)},[e.id]);let r=$g(e,t),s=Object.values(r).filter(Boolean);return o("div",{style:{marginLeft:"0.5em",transform:"scale(0.9)"}},o(Fg,{users:s,guildId:ae.getChannel(e.channel_id)?.guild_id,renderIcon:!1,max:5,showDefaultAvatarsForNullUsers:!0,showUserPopout:!0,renderMoreUsers:Ug(s)}))}})});var te,tn=m(()=>{i();$a();Ua();Ha();Wa();qa();Ya();Qa();Ja();Xa();Za();Va();oc();rc();ic();sc();ac();lc();pc();fc();gc();Sc();xc();Tc();Pc();kc();Cc();Uc();jc();Gc();zc();Yc();Qc();Jc();Xc();Zc();el();nl();il();al();ll();pl();dl();ml();ul();fl();gl();hl();yl();vl();bl();Sl();xl();Tl();wl();Il();Ml();Cl();Xi();Fl();zl();Wl();ql();ip();lp();zp();Ad();_d();Ld();$d();Ud();jd();Wd();qd();Kd();Qd();Jd();Zd();em();tm();nm();om();rm();te={[nr.name]:nr,[or.name]:or,[rr.name]:rr,[mr.name]:mr,[gr.name]:gr,[hr.name]:hr,[yr.name]:yr,[vr.name]:vr,[br.name]:br,[Sr.name]:Sr,[xr.name]:xr,[Ir.name]:Ir,[Mr.name]:Mr,[Rr.name]:Rr,[Cr.name]:Cr,[Ar.name]:Ar,[_r.name]:_r,[Lr.name]:Lr,[Ur.name]:Ur,[jr.name]:jr,[Yr.name]:Yr,[Qr.name]:Qr,[Jr.name]:Jr,[Vr.name]:Vr,[ti.name]:ti,[ni.name]:ni,[ii.name]:ii,[si.name]:si,[ai.name]:ai,[ci.name]:ci,[mi.name]:mi,[ui.name]:ui,[gi.name]:gi,[hi.name]:hi,[Si.name]:Si,[xi.name]:xi,[ki.name]:ki,[Mi.name]:Mi,[Ri.name]:Ri,[Ci.name]:Ci,[Ai.name]:Ai,[_i.name]:_i,[Fi.name]:Fi,[Di.name]:Di,[Ni.name]:Ni,[Oi.name]:Oi,[Bi.name]:Bi,[$i.name]:$i,[Ui.name]:Ui,[Hi.name]:Hi,[ji.name]:ji,[Gi.name]:Gi,[zi.name]:zi,[Wi.name]:Wi,[qi.name]:qi,[Ki.name]:Ki,[Yi.name]:Yi,[es.name]:es,[ts.name]:ts,[ns.name]:ns,[is.name]:is,[as.name]:as,[ds.name]:ds,[us.name]:us,[Cs.name]:Cs,[Ks.name]:Ks,[Js.name]:Js,[Xs.name]:Xs,[Vs.name]:Vs,[ea.name]:ea,[oa.name]:oa,[ra.name]:ra,[ia.name]:ia,[aa.name]:aa,[ca.name]:ca,[pa.name]:pa,[da.name]:da,[ma.name]:ma,[ua.name]:ua,[fa.name]:fa,[ga.name]:ga,[ya.name]:ya}});var ba={};ee(ba,{BadgePosition:()=>ur,addBadge:()=>Hg,inject:()=>Gg,removeBadge:()=>jg});function Hg(e){va.add(e)}function jg(e){return va.delete(e)}function Gg(e,t){for(let n of va)(!n.shouldShow||n.shouldShow(t))&&(n.position===0?e.unshift(n):e.push(n));return te.BadgeAPI.addDonorBadge(e,t.user.id),e}var ur,va,fr=m(()=>{"use strict";i();tn();ur=(n=>(n[n.START=0]="START",n[n.END=1]="END",n))(ur||{}),va=new Set});var Sa={};ee(Sa,{_modifyAccessories:()=>qg,accessories:()=>Ro,addAccessory:()=>zg,removeAccessory:()=>Wg});function zg(e,t,n){Ro.set(e,{callback:t,position:n})}function Wg(e){Ro.delete(e)}function qg(e,t){for(let n of Ro.values())e.splice(n.position!=null?n.position<0?e.length+n.position:n.position:e.length,0,n.callback(t));return e}var Ro,im=m(()=>{"use strict";i();Ro=new Map});var xa={};ee(xa,{Badges:()=>Vg,Commands:()=>Qg,DataStore:()=>Jg,MessageAccessories:()=>Xg,MessageEvents:()=>Kg,MessagePopover:()=>Zg,Notices:()=>Yg,ServerList:()=>eh});var Kg,Yg,Qg,Jg,Xg,Zg,Vg,eh,sm=m(()=>{"use strict";i();fr();be();$t();im();pt();fn();pn();mo();Kg=$r,Yg=kr,Qg=Kr,Jg=Bt,Xg=Sa,Zg=di,Vg=ba,eh=rs});function th(e,t,n){let r=t;if(t in e)return void n(e[r]);Object.defineProperty(e,t,{set(s){delete e[r],e[r]=s,n(s)},configurable:!0,enumerable:!1})}var am=m(()=>{"use strict";i()});var Ta={};ee(Ta,{ChangeList:()=>wn,Constants:()=>tr,Discord:()=>Ti,IpcEvents:()=>j,LazyComponent:()=>Q,Logger:()=>N,Modals:()=>dr,Queue:()=>Ln,checkIntersecting:()=>Jo,classes:()=>ie,copyWithToast:()=>en,debounce:()=>gt,humanFriendlyJoin:()=>Fm,isObject:()=>Nm,makeCodeblock:()=>Gn,makeLazy:()=>Fe,mergeDefaults:()=>xt,onceDefined:()=>th,parseUrl:()=>Qo,proxyLazy:()=>We,sleep:()=>Vt,suppressErrors:()=>Dm,useAwaiter:()=>ve,useForceUpdater:()=>ct});var cm=m(()=>{"use strict";i();vs();x();yn();wi();ze();le();O();Ye();am();Et();ha();});var Pa={};ee(Pa,{toggle:()=>wa});async function wa(e){_t?_t.disabled=!e:e&&(_t=document.createElement("style"),_t.id="vencord-custom-css",document.head.appendChild(_t),VencordNative.ipc.on(j.QUICK_CSS_UPDATE,(t,n)=>_t.innerText=n),_t.textContent=await VencordNative.ipc.invoke(j.GET_QUICK_CSS))}async function lm(){En||(En=document.createElement("style"),En.id="vencord-themes",document.head.appendChild(En));let{themeLinks:e}=S,t=e.map(n=>`@import url("${n.trim()}");`).join(` +`);En.textContent=t}var _t,En,ka=m(()=>{"use strict";i();R();ze();document.addEventListener("DOMContentLoaded",()=>{wa(S.useQuickCss),Zo("useQuickCss",wa),lm(),Zo("themeLinks",lm)})});function nh(){function e(t){try{let n=t[1],{subscriptions:r,listeners:s}=Vencord.Webpack,{patches:a}=Vencord.Plugins;for(let c in n){let f=n[c],d=f.toString().replaceAll(` +`,"");d.startsWith("function(")&&(d="0,"+d);let v=f,h=new Set,g=n[c]=function(w,P,B){try{f(w,P,B)}catch(_){if(f===v)throw _;return Lt.error("Error in patched chunk",_),void v(w,P,B)}if(w.exports===window){Object.defineProperty(B.c,c,{value:B.c[c],enumerable:!1,configurable:!0,writable:!0});return}for(let _ of s)try{_(P)}catch(oe){Lt.error("Error in webpack listener",oe)}for(let[_,oe]of r)try{if(_(P))r.delete(_),oe(P);else if(typeof P=="object"){P.default&&_(P.default)&&(r.delete(_),oe(P.default));for(let C in P)C.length<=3&&P[C]&&_(P[C])&&(r.delete(_),oe(P[C]))}}catch(C){Lt.error("Error while firing callback for webpack chunk",C)}};try{g.toString=()=>f.toString(),g.original=v}catch{}for(let w=0;we,set:t=>e.original=t,configurable:!0})}var pm,Lt,dm=m(()=>{"use strict";i();x();le();L();Lt=new N("WebpackInterceptor","#8caaee");Object.defineProperty(window,tt,{get:()=>pm,set:e=>{e?.push!==Array.prototype.push&&(Lt.info(`Patching ${tt}.push`),Do(e),nh(),delete window[tt],window[tt]=e),pm=e},configurable:!0})});var uC,mm,um=m(()=>{"use strict";i();yn();O();L();k();Zr();ne();uC=gt(function({find:e,setModule:t,setError:n}){let r=Oo(e),s=Object.keys(r),a=s.length;a===0?n("No match. Perhaps that module is lazy loaded?"):a!==1?n("Multiple matches. Please refine your filter"):t([s[0],r[s[0]]])}),mm=null});var fm={};ee(fm,{PatchHelper:()=>mm,PluginSettings:()=>So,VencordSettings:()=>Ms});var gm=m(()=>{"use strict";i();um();Is();Rs()});async function oh(){if(await Eo,Ss(),hm=await Promise.resolve().then(()=>(gm(),fm)),!1)try{}catch(e){}}var hm,Ys=m(()=>{"use strict";i();sm();bo();cm();ka();Tn();L();ka();dm();pn();R();bo();Tn();L();k();oh()});var rh={};ee(rh,{Api:()=>xa,Components:()=>hm,PlainSettings:()=>Oa,Plugins:()=>Ts,QuickCss:()=>Pa,Settings:()=>S,Updater:()=>hs,Util:()=>Ta,Webpack:()=>Bo});i();i();var Dn,wm=new Promise(e=>{setTimeout(()=>{new QWebChannel(qt.webChannelTransport,function(t){Dn=t.objects.webclass,e()})})});async function Ca(){Dn||await wm}window.VencordNative={getVersions:()=>({}),ipc:{send:async(e,...t)=>{await Ca(),Dn.vencordSend(e,t)},sendSync:(e,...t)=>{if(e==="VencordGetSettings")return window.discordScreenaudioVencordSettings||"{}";throw new Error("Synchroneous IPC not implemented")},on(e,t){},off(e,t){},invoke:async(e,...t)=>(await Ca(),e==="VencordSetSettings"&&(window.discordScreenaudioVencordSettings=t[0]),Dn.vencordSend(e,t))}};Ys();return Ao(rh);})(); //# sourceURL=VencordWeb /*! For license information please see browser.js.LEGAL.txt */