"use strict";varVencord=(()=>{varzT=Object.create;varYi=Object.defineProperty;varjT=Object.getOwnPropertyDescriptor;varWT=Object.getOwnPropertyNames;varqT=Object.getPrototypeOf,KT=Object.prototype.hasOwnProperty;varOf=(e=>typeofrequire<"u"?require:typeofProxy<"u"?newProxy(e,{get:(t,n)=>(typeofrequire<"u"?require:t)[n]}):e)(function(e){if(typeofrequire<"u")returnrequire.apply(this,arguments);thrownewError('Dynamic require of "'+e+'" is not supported')});varm=(e,t)=>()=>(e&&(t=e(e=0)),t);varLr=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),ge=(e,t)=>{for(varnint)Yi(e,n,{get:t[n],enumerable:!0})},_f=(e,t,n,r)=>{if(t&&typeoft=="object"||typeoft=="function")for(letiofWT(t))!KT.call(e,i)&&i!==n&&Yi(e,i,{get:()=>t[i],enumerable:!(r=jT(t,i))||r.enumerable});returne};varal=(e,t,n)=>(n=e!=null?zT(qT(e)):{},_f(t||!e||!e.__esModule?Yi(n,"default",{value:e,enumerable:!0}):n,e)),Lo=e=>_f(Yi({},"__esModule",{value:!0}),e);vard,o,a=m(()=>{"use strict";d=Symbol.for("react.fragment"),o=(...e)=>(o=Vencord.Webpack.Common.React.createElement)(...e)});varIn={};ge(In,{clear:()=>QT,createStore:()=>Ff,del:()=>XT,delMany:()=>JT,entries:()=>tx,get:()=>Qe,getMany:()=>ZT,keys:()=>VT,promisifyRequest:()=>vt,set:()=>Ve,setMany:()=>YT,update:()=>Eo,values:()=>ex});functionvt(e){returnnewPromise((t,n)=>{e.oncomplete=e.onsuccess=()=>t(e.result),e.onabort=e.onerror=()=>n(e.error)})}functionFf(e,t){letn=indexedDB.open(e);n.onupgradeneeded=()=>n.result.createObjectStore(t);letr=vt(n);return(i,s)=>r.then(l=>s(l.transaction(t,i).objectStore(t)))}functionon(){returnll||(ll=Ff("VencordData","VencordStore")),ll}functionQe(e,t=on()){returnt("readonly",n=>vt(n.get(e)))}functionVe(e,t,n=on()){returnn("readwrite",r=>(r.put(t,e),vt(r.transaction)))}functionYT(e,t=on()){returnt("readwrite",n=>(e.forEach(r=>n.put(r[1],r[0])),vt(n.transaction)))}functionZT(e,t=on()){returnt("readonly",n=>Promise.all(e.map(r=>vt(n.get(r)))))}functionEo(e,t,n=on()){returnn("readwrite",r=>newPromise((i,s)=>{r.get(e).onsuccess=function(){try{r.put(t(this.result),e),i(vt(r.transaction))}catch(l){s(l)}}}))}functionXT(e,t=on()){returnt("readwrite",n=>(n.delete(e),vt(n.transaction)))}functionJT(e,t=on()){returnt("readwrite",n=>(e.forEach(r=>n.delete(r)),vt(n.transaction)))}functionQT(e=on()){returne("readwrite",t=>(t.clear(),vt(t.transaction)))}functioncl(e,t){returne.openCursor().onsuccess=function(){!this.result||(t(this.result),this.result.continue())},vt(e.transaction)}functionVT(e=on()){returne("readonly",t=>{if(t.getAllKeys)returnvt(t.getAllKeys());letn=[];returncl(t,r=>n.push(r.key)).then(()=>n)})}functionex(e=on()){returne("readonly",t=>{if(t.getAll)returnvt(t.getAll());letn=[];returncl(t,r=>n.push(r.value)).then(()=>n)})}functiontx(e=on()){returne("readonly",t=>{if(t.getAll&&t.getAllKeys)returnPromise.all([vt(t.getAllKeys()),vt(t.getAll())]).then(([r,i])=>r.map((s,l)=>[s,i[l]]));letn=[];returne("readonly",r=>cl(r,i=>n.push([i.key,i.value])).then(()=>n))})}varll,Cn=m(()=>{"use strict";a();});varEr,ul=m(()=>{"use strict";a();Er=class{set=newSet;getchangeCount(){returnthis.set.size}gethasChanges(){returnthis.changeCount>0}handleChange(t){this.set.delete(t)||this.set.add(t)}add(t){returnthis.set.add(t)}remove(t){returnthis.set.delete(t)}getChanges(){returnthis.set.values()}map(t){return[...this.getChanges()].map(t)}}});varrn,Dr=m(()=>{a();rn="bea7a17"});varZi,$f=m(()=>{a();Zi="Vendicated/Vencord"});varqt,nx,pl,Xi,p,dl,w=m(()=>{"use strict";a();Dr();$f();qt="webpackChunkdiscord_app",nx="Vencord.Webpack.Common.React",pl=`Vencord/${rn}${Zi?` (https://github.com/${Zi})`:""}`,Xi="1026515880080842772",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
`;return(0,eval)(n)}var ml,ts,fl,Gt,Un,K,Gf,gl,Ht,Or,os,Hf,O=m(()=>{"use strict";a();sn();be();es();ml=new Y("Webpack"),fl=new Promise(e=>ts=e),K={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},byStoreName:e=>t=>t.constructor?.displayName===e},Gf=new Map,gl=new Set;Ht=an("find",function(t,n=!0,r=!1){if(typeof t!="function")throw new Error("Invalid filter. Expected a function got "+typeof t);for(let i in Un){let s=Un[i];if(!!s?.exports){if(t(s.exports))return r?[s.exports,Number(i)]:s.exports;if(typeof s.exports=="object"){if(s.exports.default&&t(s.exports.default)){let l=n?s.exports.default:s.exports;return r?[l,Number(i)]:l}for(let l in s.exports)if(l.length<=3){let c=s.exports[l];if(c&&t(c))return r?[c,Number(i)]:c}}}}if(!r){let i=new Error("Didn't find module matching this filter");ml.warn(i)}return r?[null,null]:null});Or=an("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 Ht(t[0]);let r=t,i=0,s=Array(n);e:for(let l in Un){let c=Un[l];if(!!c?.exports)for(let u=0;u<n;u++){let h=r[u];if(h!==void 0){if(h(c.exports)){if(s[u]=c.exports,r[u]=void 0,++i===n)break e;break}if(typeof c.exports=="object"){if(c.exports.default&&h(c.exports.default)){if(s[u]=c.exports.default,r[u]=void 0,++i===n)break e;break}for(let f in c.exports)if(f.length<=3){let y=c.exports[f];if(y&&h(y)){if(s[u]=y,r[u]=void 0,++i===n)break e;continue e}}}}}}if(i!==n){let l=new Error(`Got${n}filters,butonlyfound${i}modules!`);ml.warn(l)}return s}),os=an("findModuleId",function(t){for(let r in Gt.m)if(Gt.m[r].toString().includes(t))return Number(r);let n=new Error(`Didn'tfindmodulewithcode:
`+t);return ml.warn(n),null}),Hf=an("mapMangledModule",function(t,n){let r={},i=os(t);if(i===null)return r;let s=Gt(i);e:for(let l in s){let c=s[l];for(let u in n)if(n[u](c)){r[u]=c;continue e}}return r})});var rs,mt,zf=m(()=>{"use strict";a();O();rs=P("image","modal"),mt=P("buttonWrapper","buttonContent")});function Do(e,t){for(let n in t){let r=t[n];typeof r=="object"&&!Array.isArray(r)?(e[n]??={},Do(e[n],r)):e[n]??=r}return e}function J(...e){return e.filter(Boolean).join(" ")}function so(e){return new Promise(t=>setTimeout(t,e))}function Yt(e,t="Copied to clipboard!"){Kt.SUPPORTS_COPY?Kt.copy(e):t="Your browser does not support copying to clipboard",X.show({message:t,id:X.genId(),type:X.Type.SUCCESS})}function lx(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}function vl(e){try{return new URL(e)}catch{return null}}function is(e){return e}var Sl,cx,_r,fe=m(()=>{"use strict";a();T();w();Sl=e=>{let t=e.getBoundingClientRect(),n=Math.max(document.documentElement.clientHeight,window.innerHeight);return!(t.bottom<0||t.top-n>=0)};cx=navigator.userAgent.includes("Mobi"),_r=e=>Object.hasOwn(dl,e)});function ot(e,t){let n=Object.assign({fallbackValue:null,deps:[],onError:null},t),[r,i]=V({value:n.fallbackValue,error:null,pending:!0});return rt(()=>{let s=!0;return r.pending||i({...r,pending:!0}),e().then(l=>{!s||(i({value:l,error:null,pending:!1}),n.onSuccess?.(l))}).catch(l=>{!s||(i({value:null,error:l,pending:!1}),n.onError?.(l))}),()=>void(s=!1)},n.deps),[r.value,r.error,r.pending]}function Lt(e){let t=rr(n=>n+1,0);return e?t:t[1]}function re(e){let t=$n(e);return n=>{let r=t();return o(r,{...n})}}var bl,ve=m(()=>{"use strict";a();T();sn();fe();bl=(e=!1)=>{let t=I.useRef(null),[n,r]=V(!1);return[s=>{t.current?.disconnect(),t.current=null,s&&(Sl(s)&&(r(!0),e)||(t.current=new IntersectionObserver(l=>{for(let c of l)c.target===s&&(c.isIntersecting&&e?(r(!0),t.current?.disconnect(),t.current=null):r(c.isIntersecting))}),t.current.observe(s)))},n]}});function ss(e,t){let n=function(){throw new Error(`Vencordcouldnotfindthe${e}Component`)},r=re(()=>n);return Ye(t,i=>{n=i,Object.assign(r,i)}),r}function St(e,t){Ye(K.byStoreName(e),t)}var Tl=m(()=>{"use strict";a();ve();O()});var v,Et,N,ft,W,Re,as,Q,ln,ls,Oo,Zt,Br,jf,Wf,cs,us,ps,ds,Fr,xl,kn,ux,qf=m(()=>{"use strict";a();O();Tl();v={},xl=ss("MaskedLink",e=>e?.type?.toString().includes("MASKED_LINK)")),kn=ss("Timestamp",K.byCode(".Messages.MESSAGE_EDITED_TIMESTAMP_A11Y_LABEL.format")),ux=ss("Flex",["Justify","Align","Wrap"]);Ye("FormItem",e=>{({useToken:Fr,Card:Et,Button:N,FormSwitch:ft,Tooltip:W,TextInput:Re,TextArea:as,Text:Q,Select:ln,SearchableSelect:ls,Slider:Oo,ButtonLooks:Zt,TabBar:Wf,Popout:Br,Dialog:jf,Paginator:cs,ScrollerThin:us,Clickable:ps,Avatar:ds}=e),v=e})});var L,cn,Kf=m(()=>{"use strict";a();O();L={};Ye("MenuItem",e=>L=e);cn=Ke('type:"CONTEXT_MENU_OPEN"',{open:K.byCode("stopPropagation"),openLazy:e=>e.toString().length<50,close:K.byCode("CONTEXT_MENU_CLOSE")})});var I,V,rt,zt,Xt,rr,Yf,_o,Zf=m(()=>{"use strict";a();O();_o=P("createPortal","render");Ye("useState",e=>{I=e,{useEffect:rt,useState:V,useMemo:zt,useRef:Xt,useReducer:rr,useCallback:Yf}=I})});var wl,un,Pl,je,ms,$r,ao,px,ue,F,Pe,lo,Z,Ae,et,pn,Ur,Ml,Fe,Xf=m(()=>{"use strict";a();O();Tl();wl=P("connectStores"),Pl=P("openPrivateChannel"),Ml=Ke('"MaskedLinkStore"',{openUntrustedLink:K.byCode(".apply(this,arguments)")}),Fe=ce("useStateFromStores");St("UserStore",e=>F=e);St("ChannelStore",e=>Z=e);St("SelectedChannelStore",e=>Pe=e);St("SelectedGuildStore",e=>lo=e);St("GuildStore",e=>ue=e);St("GuildMemberStore",e=>Ae=e);St("RelationshipStore",e=>et=e);St("PermissionStore",e=>je=e);St("PresenceStore",e=>ao=e);St("ReadStateStore",e=>$r=e);St("GuildChannelStore",e=>ms=e);St("MessageStore",e=>un=e);St("WindowStore",e=>Ur=e);St("EmojiStore",e=>pn=e)});var Jf={};var Qf=m(()=>{"use strict";a()});var Vf={};var eg=m(()=>{"use strict";a()});var tg={};var ng=m(()=>{"use strict";a()});function fs(e,t=og.MESSAGE){X.show({id:X.genId(),message:e,type:t})}var E,Il,Dt,Jt,Bo,it,ir,Ie,bt,og,dx,X,Rn,Kt,Gr,gs,An,rg=m(()=
`);if(r.shift()!=="id,tooltip,image"){new Y("BadgeAPI").error("Invalid badges.csv file!");return}for(let i of r){let[s,l,c]=i.split(",");(Hl[s]??=[]).push({image:c,description:l})}}var Ax,Lx,Hl,zl,fg=m(()=>{"use strict";a();Ps();Gl();ie();wt();Ul();w();be();Xe();fe();Ze();b();T();Ax="https://cdn.discordapp.com/attachments/1033680203433660458/1092089947126780035/favicon.png",Lx={description:"Vencord Contributor",image:Ax,position:0,props:{style:{borderRadius:"50%",transform:"scale(0.9)"}},shouldShow:({user:e})=>_r(e.id),link:"https://github.com/Vendicated/Vencord"},Hl={};zl=g({name:"BadgeAPI",description:"API to add badges to users.",authors:[p.Megu,p.Ven,p.TheSun],required:!0,patches:[{find:"Messages.PROFILE_USER_BADGES,role:",replacement:[{match:/&&(\i)\.push\(\{id:"premium".+?\}\);/,replace:"$&$1.unshift(...Vencord.Api.Badges._getBadges(arguments[0]));"},{match:/alt:" ","aria-hidden":!0,src:(?=(\i)\.src)/g,replace:"...$1.props,$& $1.image??"},{match:/children:function(?<=(\i)\.(?:tooltip|description),spacing:\d.+?)/g,replace:"children:$1.component ? () => $self.renderBadgeComponent($1) : function"},{match:/onClick:function(?=.{0,200}href:(\i)\.link)/,replace:"onClick:$1.onClick??function"}]}],toolboxActions:{async"Refetch Badges"(){await mg(!0),X.show({id:X.genId(),message:"Successfully refetched badges!",type:X.Type.SUCCESS})}},async start(){Vencord.Api.Badges.addBadge(Lx),await mg()},renderBadgeComponent:A.wrap(e=>{let t=e.component;return o(t,{...e})},{noop:!0}),getDonorBadges(e){return Hl[e]?.map(t=>({...t,position:0,props:{style:{borderRadius:"50%",transform:"scale(0.9)"}},onClick(){let n=Ce(r=>o(A,{noop:!0,onError:()=>{Gn(n),VencordNative.native.openExternal("https://github.com/sponsors/Vendicated")}},o(dn.ModalRoot,{...r},o(dn.ModalHeader,null,o(le,{style:{width:"100%",justifyContent:"center"}},o(v.FormTitle,{tag:"h2",style:{width:"100%",textAlign:"center",margin:0}},o(xs,null),"Vencord Donor"))),o(dn.ModalContent,null,o(le,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(v.FormText,null,"This Badge is a special perk for Vencord Donors"),o(v.FormText,{className:G.top20},"Please consider supporting the development of Vencord by becoming a donor. It would mean a lot!!"))),o(dn.ModalFooter,null,o(le,{style:{width:"100%",justifyContent:"center"}},o(Zr,null))))))}}))}})});var jl,gg=m(()=>{"use strict";a();w();b();jl=g({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 Wl,hg=m(()=>{"use strict";a();w();b();Wl=g({name:"ContextMenuAPI",description:"API for adding/removing items to/from context menus.",authors:[p.Nuckyz,p.Ven],required:!0,patches:[{find:"\u266B (\u3064\uFF61\u25D5\u203F\u203F\u25D5\uFF61)\u3064 \u266A",replacement:{match:/(?<=function \i\((\i)\){)(?=var \i,\i=\i\.navId)/,replace:(e,t)=>`Vencord.Api.ContextMenu._patchContextMenu(${t});`}},{find:".Menu,{",all:!0,replacement:{match:/Menu,{(?<=\.jsxs?\)\(\i\.Menu,{)/g,replace:"$&contextMenuApiArguments:typeof arguments!=='undefined'?arguments:[],"}}]})});var ql,yg=m(()=>{"use strict";a();w();b();ql=g({name:"MemberListDecoratorsAPI",description:"API to add decorators to member list (both in servers and DMs)",authors:[p.TheSun],patches:[{find:"lostPermissionTooltipText,",replacement:{match:/Fragment,{children:\[(.{30,80})\]/,replace:"Fragment,{children:Vencord.Api.MemberListDecorators.__addDecoratorsToList(this.props).conca
`,e)}cw=At(async()=>{M.cloud.settingsSync&&M.cloud.authenticated&&(await ur(),delete $o.Vencord_settingsDirty)},6e4),_s=new Set,nh={};En=go,M=wc(go)});function Fs(){window.VencordDesktopNative.app.relaunch()}var ri=m(()=>{"use strict";a()});var rh=m(()=>{});var Ic={};ge(Ic,{UpdateLogger:()=>ih,changes:()=>$s,checkForUpdates:()=>ah,getRepo:()=>pw,isNewer:()=>Mc,isOutdated:()=>ho,maybePromptToUpdate:()=>ii,update:()=>lh,updateError:()=>sh});async function Us(e){let t=await e;if(t.ok)return t.value;throw sh=t.error,t.error}async function ah(){return $s=await Us(VencordNative.updater.getUpdates()),$s.some(e=>e.hash===rn)?(Mc=!0,ho=!1):ho=$s.length>0}async function lh(){if(!ho)return!0;let e=await Us(VencordNative.updater.update());if(e&&(ho=!1,!await Us(VencordNative.updater.rebuild())))throw new Error("The Build failed. Please try manually building the new update");return e}async function ii(e,t=!1){return;try{if(await ah()){let r=confirm(e);if(r&&Mc)return alert("Your local copy has more recent commits. Please stash or reset them.");r&&(await lh(),Fs())}}catch(n){ih.error(n),alert("That also failed :( Try updating or re-installing with the installer!")}}var ih,ho,Mc,sh,$s,pw,dr=m(()=>{"use strict";a();Dr();be();ri();ih=new Y("Updater","white"),ho=!1,Mc=!1;pw=()=>Us(VencordNative.updater.getRepo())});function ch(){ii("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?")}var uh=m(()=>{"use strict";a();dr()});function Dn({title:e,children:t}){return o(v.FormSection,null,o(Q,{variant:"heading-lg/semibold",tag:"h2",className:G.bottom16},e),t)}function On(e,t){return A.wrap(e,{message:`Failedtorenderthe${t}tab.Ifthisissuepersists,tryusingtheinstallertoreinstall!`,onError:dw})}var dw,Go=m(()=>{"use strict";a();rh();ie();uh();Xe();El();T();dw=Ll(ch)});var mh={};ge(mh,{default:()=>yw});function fw(){let[e,,t]=ot(VencordNative.settings.getSettingsDir,{fallbackValue:"Loading..."}),n=st(),r=I.useMemo(()=>Math.random()>.5?dh:mw,[]),i=navigator.platform.toLowerCase().startsWith("win"),s=navigator.platform.toLowerCase().startsWith("mac"),l=[{key:"useQuickCss",title:"Enable Custom CSS",note:"Loads your Custom CSS"},!1,!1,!1,!1,!1,!1];return o(Dn,{title:"Vencord Settings"},o(hw,{image:r}),o(v.FormSection,{title:"Quick Actions"},o(Et,{className:ph("quick-actions-card")},o(I.Fragment,null,!1,o(N,{onClick:()=>VencordNative.quickCss.openEditor(),size:N.Sizes.SMALL,disabled:e==="Loading..."},"Open QuickCSS File"),!1,o(N,{onClick:()=>VencordNative.native.openExternal("https://github.com/Vendicated/Vencord"),size:N.Sizes.SMALL,disabled:t},"Open in GitHub")))),o(v.FormDivider,null),o(v.FormSection,{className:G.top16,title:"Settings",tag:"h5"},o(v.FormText,{className:G.bottom20},'Hint: You can change the position of this settings section in the settings of the "Settings" plugin!'),l.map(c=>c&&o(ft,{key:c.key,value:n[c.key],onChange:u=>n[c.key]=u,note:c.note},c.title))),typeof Notification<"u"&&o(gw,{settings:n.notifications}))}function gw({settings:e}){return o(d,null,o(v.FormTitle,{tag:"h5"},"Notification Style"),e.useNative!=="never"&&Notification?.permission==="denied"&&o(qn,{style:{padding:"1em"},className:G.bottom8},o(v.FormTitle,{tag:"h5"},"Desktop Notification Permission denied"),o(v.FormText,null,"You have denied Notification Permissions. Thus, Desktop notifications will not work!")),o(v.FormText,{className:G.bottom8},"Some plugins may show you notifications. These come in two styles:",o("ul",null,o("li",null,o("strong",null,"Vencord Notifications"),": These are in-app notifications"),o("li",null,o("strong",null,"Desktop Notifications"),": Native Desktop notifications (like when you get a ping)"))),o(ln,{placeholder:"Notification Style",options:[{label:"Only use Desktop notifications when Discord is not focused",value:"not-focused",default:!0},{label:"Always use Desktop notifications",value:"always"},{label:"Always use Vencord notifications",value:"never"}],closeOnSelect:!0,select:t=>e.useNative=t,isSelected:t=>t===e.useNative,serialize:is}),o
${Kr(l)}`,author:{username:"Vencord"}})};try{let i=e.execute(t,n);return i instanceof Promise?i.catch(r):i}catch(i){return r(i)}}});var $c,Ah=m(()=>{a();(window.VencordStyles??=new Map).set("src/components/PluginSettings/userPopoutHideBotTag.css",{name:"src/components/PluginSettings/userPopoutHideBotTag.css",source:`[class|="userPopoutOuter"][class*="botTag"]{
display:none;
}
`,classNames:{},dom:null});$c="src/components/PluginSettings/userPopoutHideBotTag.css"});function Uc(e){let t=new Iw({username:e.username,id:e.id??Ec(),avatar:e.avatar,bot:!0});return E.dispatch({type:"USER_UPDATE",user:t}),t}function Gc({plugin:e,onRestartNeeded:t,onClose:n,transitionState:r}){let[i,s]=I.useState([]),l=st().plugins[e.name],[c,u]=I.useState({}),[h,f]=I.useState({}),[y,S]=I.useState(null),x=()=>Object.values(h).every(B=>!B),R=Boolean(l&&e.options);I.useEffect(()=>{Je($c);let B;return(async()=>{for(let q of e.authors.slice(0,6)){let ee=q.id?await Rn.fetchUser(`${q.id}`).then(j=>(B=j,Uc(j))).catch(()=>Uc({username:q.name})):Uc({username:q.name});s(j=>[...j,ee])}})(),()=>{Mt($c),B&&E.dispatch({type:"USER_UPDATE",user:B})}},[]);async function C(){if(!e.options){n();return}if(e.beforeSave){let q=await Promise.resolve(e.beforeSave(c));if(q!==!0){S(q);return}}let B=!1;for(let[q,ee]of Object.entries(c)){let j=e.options[q];l[q]=ee,j?.onChange?.(ee),j?.restartNeeded&&(B=!0)}B&&t(),n()}function _(){if(!R||!e.options)return o(v.FormText,null,"There are no settings for this plugin.");{let B=Object.entries(e.options).map(([q,ee])=>{if(ee.hidden)return null;function j(U){u(Ne=>({...Ne,[q]:U}))}function z(U){f(Ne=>({...Ne,[q]:U}))}let te=Cw[ee.type];return o(te,{id:q,key:q,option:ee,onChange:j,onError:z,pluginSettings:l,definedSettings:e.settings})});return o(le,{flexDirection:"column",style:{gap:12,marginBottom:16}},B)}}function $(B,q){let ee=e.authors.length-q,j=e.authors.length-ee,z=j+e.authors.length-q;return o(W,{text:e.authors.slice(j,z).map(te=>te.name).join(", ")},({onMouseEnter:te,onMouseLeave:U})=>o("div",{className:Mw.moreUsers,onMouseEnter:te,onMouseLeave:U},"+",ee))}return o(Le,{transitionState:r,size:"medium",className:"vc-text-selectable"},o($e,{separator:!1},o(Q,{variant:"heading-lg/semibold",style:{flexGrow:1}},e.name),o(xt,{onClick:n})),o(Ue,null,o(v.FormSection,null,o(v.FormTitle,{tag:"h3"},"About ",e.name),o(v.FormText,null,e.description),o(v.FormTitle,{tag:"h3",style:{marginTop:8,marginBottom:0}},"Authors"),o("div",{style:{width:"fit-content",marginBottom:8}},o(Pw,{users:i,count:e.authors.length,guildId:void 0,renderIcon:!1,max:6,showDefaultAvatarsForNullUsers:!0,showUserPopout:!0,renderMoreUsers:$}))),!!e.settingsAboutComponent&&o("div",{className:J(G.bottom8,"vc-text-selectable")},o(v.FormSection,null,o(A,{message:"An error occurred while rendering this plugin's custom InfoComponent"},o(e.settingsAboutComponent,{tempSettings:c})))),o(v.FormSection,null,o(v.FormTitle,{tag:"h3"},"Settings"),_())),R&&o(Tt,null,o(le,{flexDirection:"column",style:{width:"100%"}},o(le,{style:{marginLeft:"auto"}},o(N,{onClick:n,size:N.Sizes.SMALL,color:N.Colors.WHITE,look:N.Looks.LINK},"Cancel"),o(W,{text:"You must fix all errors before saving",shouldShow:!x()},({onMouseEnter:B,onMouseLeave:q})=>o(N,{size:N.Sizes.SMALL,color:N.Colors.BRAND,onClick:C,onMouseEnter:B,onMouseLeave:q,disabled:!x()},"Save & Close"))),y&&o(Q,{variant:"text-md/semibold",style:{color:"var(--text-danger)"}},"Error while saving: ",y))))}var Pw,Mw,Iw,Cw,Lh=m(()=>{"use strict";a();_t();D();Ge();ie();wt();sn();Xe();fe();Ze();ve();b();O();T();Hs();Ah();Pw=re(()=>ze("defaultRenderUser","showDefaultAvatarsForNullUsers")),Mw=P("moreUsers","emptyUser","avatarContainer","clickableAvatar"),Iw=dt(()=>F.getCurrentUser().constructor);Cw={[0]:Ch,[1]:Ac,[2]:Ac,[3]:Sh,[4]:Ph,[5]:Ih,[6]:Th}});var Eh=m(()=>{});function Dh({checked:e,onChange:t,disabled:n}){return o("div",null,o("div",{className:J(js.container,"default-colors",e?js.checked:void 0),style:{backgroundColor:e?Hc:zc,opacity:n?.3:1}},o("svg",{className:js.slider+" vc-switch-slider",viewBox:"0 0 28 20",preserveAspectRatio:"xMinYMid meet","aria-hidden":"true",style:{transform:e?"translateX(12px)":"translateX(-3px)"}},o("rect",{fill:"white",x:"4",y:"0",height:"20",width:"20",rx:"10"}),o("svg",{viewBox:"0 0 20 20",fill:"none"},e?o(d,null,o("path",{fill:Hc,d:"M7.89561 14.8538L6.30462 13.2629L14.3099 5.25755L15.9009 6.84854L7.89561 14.8538Z"}),o("path",{fill:Hc,d:"M4.08643 11.0903L5.67742 9.49929L9.4485 13.2704L
`,s),!1}}if(r?.length){jt.info("Registering commands of plugin",n);for(let s of r)try{fr(s,n)}catch(l){return jt.error(`Failedtoregistercommand${s.name}
`,l),!1}}if(i)for(let s in i)E.subscribe(s,i[s]);return!0},e=>`startPlugin${e.name}`),Kc=an("stopPlugin",function(t){let{name:n,commands:r,flux:i}=t;if(t.stop){if(jt.info("Stopping plugin",n),!t.started)return jt.warn(`${n}alreadystopped`),!1;try{t.stop(),t.started=!1}catch(s){return jt.error(`Failedtostop${n}
`,s),!1}}if(r?.length){jt.info("Unregistering commands of plugin",n);for(let s of r)try{li(s.name)}catch(l){return jt.error(`Failedtounregistercommand${s.name}
`,l),!1}}if(i)for(let s in i)E.unsubscribe(s,i[s]);return!0},e=>`stopPlugin${e.name}`)});function Ew(e){X.show({message:e,type:X.Type.FAILURE,id:X.genId(),options:{position:X.Position.BOTTOM}})}function Dw({required:e}){return o(Et,{className:vn("info-card",{"restart-card":e})},e?o(d,null,o(v.FormTitle,{tag:"h5"},"Restart required!"),o(v.FormText,{className:vn("dep-text")},"Restart now to apply new plugins and their settings"),o(N,{color:N.Colors.YELLOW,onClick:()=>location.reload()},"Restart")):o(d,null,o(v.FormTitle,{tag:"h5"},"Plugin Management"),o(v.FormText,null,"Press the cog wheel or info icon to get more info on a plugin"),o(v.FormText,null,"Plugins with a cog wheel have settings you can modify!")))}function Uh({plugin:e,disabled:t,onRestartNeeded:n,onMouseEnter:r,onMouseLeave:i,isNew:s}){let l=M.plugins[e.name],c=()=>l.enabled??!1;function u(){Hr(async()=>f=>o(Gc,{...f,plugin:e,onRestartNeeded:()=>n(e.name)}))}function h(){let f=c();if(!f){let{restartNeeded:S,failures:x}=Ws(e);if(x.length){Fh.error(`Failedtostartdependenciesfor${e.name}:${x.join(", ")}`),ai("Failed to start dependencies: "+x.join(", "),"Close",()=>null);return}else if(S){l.enabled=!0,n(e.name);return}}if(e.patches?.length){l.enabled=!f,n(e.name);return}if(f&&!e.started){l.enabled=!f;return}if(!(f?Kc(e):ci(e))){l.enabled=!1;let S=`Errorwhile${f?"stopping":"starting"}plugin${e.name}`;Fh.error(S),Ew(S);return}l.enabled=!f}return o(le,{className:vn("card",{"card-disabled":t}),flexDirection:"column",onMouseEnter:r,onMouseLeave:i},o("div",{className:vn("card-header")},o(Q,{variant:"text-md/bold",className:vn("name")},e.name,s&&o(yh,{text:"NEW",color:"#ED4245"})),o("button",{role:"switch",onClick:()=>u(),className:J(Rw.button,vn("info-button"))},e.options?o(Aw,null):o(Lw,{width:"24",height:"24"})),o(Dh,{checked:c(),onChange:h,disabled:t})),o(Q,{className:vn("note"),variant:"text-sm/normal"},e.description))}function Zc(){let e=st(),t=I.useMemo(()=>new Er,[]);I.useEffect(()=>()=>void(t.hasChanges&&bt.show({title:"Restart required",body:o(d,null,o("p",null,"The following plugins require a restart:"),o("div",null,t.map((S,x)=>o(d,null,x>0&&", ",Ie.parse("`"+S+"`"))))),confirmText:"Restart now",cancelText:"Later!",onConfirm:()=>location.reload()})),[]);let n=I.useMemo(()=>{let S={};for(let x in Te){let R=Te[x].dependencies;if(R)for(let C of R)S[C]??=[],S[C].push(x)}return S},[]),r=I.useMemo(()=>Object.values(Te).sort((S,x)=>S.name.localeCompare(x.name)),[]),[i,s]=I.useState({value:"",status:0}),l=S=>s(x=>({...x,value:S})),c=S=>s(x=>({...x,status:S})),u=S=>{let x=e.plugins[S.name]?.enabled;if(x&&i.status===2||!x&&i.status===1)return!1;if(!i.value.length)return!0;let R=i.value.toLowerCase();return S.name.toLowerCase().includes(R)||S.description.toLowerCase().includes(R)||S.tags?.some(C=>C.toLowerCase().includes(R))},[h]=ot(()=>Qe("Vencord_existingPlugins").then(S=>{let x=Date.now()/1e3,R={},C=Object.values(r).map($=>$.name),_=[];for(let{name:$}of r)(R[$]=S?.[$]??x)+60*60*24*2>x&&_.push($);return Ve("Vencord_existingPlugins",R),window._.isEqual(_,C)?[]:_})),f,y;if(r?.length){f=[],y=[];for(let S of r){if(!S.options&&S.name.endsWith("API")&&i.value!=="API"||!u(S))continue;if(S.required||n[S.name]?.some(R=>e.plugins[R].enabled)){let R=S.required?"This plugin is required for Vencord to function.":Ow(n[S.name]?.filter(C=>e.plugins[C].enabled));y.push(o(W,{text:R,key:S.name},({onMouseLeave:C,onMouseEnter:_})=>o(Uh,{onMouseLeave:C,onMouseEnter:_,onRestartNeeded:$=>t.handleChange($),disabled:!0,plugin:S})))}else f.push(o(Uh,{onRestartNeeded:R=>t.handleChange(R),disabled:!1,plugin:S,isNew:h?.includes(S.name),key:S.name}))}}else f=y=o(Q,{variant:"text-md/normal"},"No plugins meet search criteria.");return o(Dn,{title:"Plugins"},o(Dw,{required:t.hasChanges}),o(v.FormTitle,{tag:"h5",className:J(G.top20,G.bottom8)},"Filters"),o("div",{className:vn("filter-controls")},o(Re,{autoFocus:!0,value:i.value,placeholder:"Search for a plugin...",onChange:l,className:G.bottom20}),o("div",{className:$h.inputWrapper},o(ln,{className:$h.inputDefault,options:[{label:"Show All
`));function r(){e.themeLinks=[...new Set(t.trim().split(/\n+/).map(i=>i.trim()).filter(Boolean))]}return o(Dn,{title:"Themes"},o(Et,{className:"vc-settings-card vc-text-selectable"},o(v.FormTitle,{tag:"h5"},"Paste links to .theme.css files here"),o(v.FormText,null,"One link per line"),o(v.FormText,null,o("strong",null,"Make sure to use the raw links or github.io links!")),o(v.FormDivider,{className:G.top8+" "+G.bottom8}),o(v.FormTitle,{tag:"h5"},"Find Themes:"),o("div",{style:{marginBottom:".5em"}},o(at,{style:{marginRight:".5em"},href:"https://betterdiscord.app/themes"},"BetterDiscord Themes"),o(at,{href:"https://github.com/search?q=discord+theme"},"GitHub")),o(v.FormText,null,'If using the BD site, click on "Source" somewhere below the Download button'),o(v.FormText,null,'In the GitHub repository of your theme, find X.theme.css, click on it, then click the "Raw" button'),o(v.FormText,null,"If the theme has configuration that requires you to edit the file:",o("ul",null,o("li",null,"\u2022 Make a ",o(at,{href:"https://github.com/signup"},"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(v.FormTitle,{tag:"h5"},"Themes"),o(as,{value:t,onChange:n,className:`${Bw.textarea}vc-settings-theme-links`,placeholder:"Theme Links",spellCheck:!1,onBlur:r}),o($w,{themeLinks:e.themeLinks}))}var Bw,Gw,Wh=m(()=>{"use strict";a();D();bo();Xe();ve();O();T();Go();Bw=ke(e=>typeof e.textarea=="string");Gw=On(Uw,"Themes")});function Ks({value:e,onChange:t,validate:n}){let[r,i]=I.useState(e),[s,l]=I.useState();function c(u){i(u);let h=n(u);h===!0?(l(void 0),t(u)):l(h)}return o(d,null,o(Re,{type:"text",value:r,onChange:c,error:s}))}var Xc=m(()=>{"use strict";a();T()});var qh={};ge(qh,{default:()=>qw});function Hw(e){try{return new URL(e),!0}catch{return"Invalid URL"}}async function zw(){let e=await fetch(new URL("/v1/",fo()),{method:"DELETE",headers:new Headers({Authorization:await cr()})});if(!e.ok){Es.error(`Failedtoerasedata,APIreturned${e.status}`),he({title:"Cloud Integrations",body:`Couldnoterasealldata(APIreturned${e.status}),pleasecontactsupport.`,color:"var(--red-360)"});return}M.cloud.authenticated=!1,await bc(),he({title:"Cloud Integrations",body:"Successfully erased all data.",color:"var(--green-360)"})}function jw(){let{cloud:e}=st(["cloud.authenticated","cloud.settingsSync"]),t=e.authenticated&&e.settingsSync;return o(v.FormSection,{title:"Settings Sync",className:G.top16},o(v.FormText,{variant:"text-md/normal",className:G.bottom20},"Synchronize your settings to the cloud. This allows easy synchronization across multiple devices with minimal effort."),o(ft,{key:"cloud-sync",disabled:!e.authenticated,value:e.settingsSync,onChange:n=>{e.settingsSync=n}},"Settings Sync"),o("div",{className:"vc-cloud-settings-sync-grid"},o(N,{size:N.Sizes.SMALL,disabled:!t,onClick:()=>ur(!0)},"Sync to Cloud"),o(W,{text:"This will overwrite your local settings with the ones on the cloud. Use wisely!"},({onMouseLeave:n,onMouseEnter:r})=>o(N,{onMouseLeave:n,onMouseEnter:r,size:N.Sizes.SMALL,color:N.Colors.RED,disabled:!t,onClick:()=>Os(!0,!0)},"Sync from Cloud")),o(N,{size:N.Sizes.SMALL,color:N.Colors.RED,disabled:!t,onClick:()=>eh()},"Delete Cloud Settings")))}function Ww(){let e=st(["cloud.authenticated","cloud.url"]);return o(Dn,{title:"Vencord Cloud"},o(v.FormSection,{title:"Cloud Settings",className:G.top16},o(v.FormText,{variant:"text-md/normal",className:G.bottom20},"Vencord comes with a cloud integration that adds goodies like settings sync across devices. It ",o(at,{href:"https://vencord.dev/cloud/privacy"},"respects your privacy"),", and the ",o(at,{href:"https://github.com/Vencord/Backend"},"source code")," is AGPL 3.0 licensed so you can host it yourself."),o(ft,{key:"backend",value:e.cloud.authenticated,onChange:t=>{t&&Yg(),t||(e.cloud.authenticated=t)},note:"This will request authorization if you have not yet set up cloud integrations."},"Enable Cloud Integrations"),o(v.FormTitle,{tag:"
`}var pi,pu,Ny=m(()=>{"use strict";a();D();w();b();pu=g({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:Cy}},start(){pi=document.createElement("style"),pi.id="VcBlurNsfw",document.head.appendChild(pi),Cy()},stop(){pi?.remove()}})});function o2(e){let t=M.plugins.CallTimer.format==="human",n=f=>t?f:f.toString().padStart(2,"0"),r=f=>t?f:"",i=t?" ":":",s=Math.floor(e/864e5),l=Math.floor(e%864e5/36e5),c=Math.floor(e%864e5%36e5/6e4),u=Math.floor(e%864e5%36e5%6e4/1e3),h="";return s&&(h+=`${s}d`),(l||h)&&(h+=`${n(l)}${r("h")}${i}`),(c||h||!t)&&(h+=`${n(c)}${r("m")}${i}`),h+=`${n(u)}${r("s")}`,h}var du,ky=m(()=>{"use strict";a();D();ie();w();b();T();du=g({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:"[$&, $self.renderTimer(this.props.channel.id)]"}}],renderTimer(e){return o(A,{noop:!0},o(this.Timer,{channelId:e}))},Timer({channelId:e}){let[t,n]=I.useState(0),r=I.useMemo(()=>Date.now(),[e]);return I.useEffect(()=>{let i=setInterval(()=>n(Date.now()-r),1e3);return()=>{clearInterval(i),n(0)}},[e]),o("p",{style:{margin:0}},"Connected for ",o2(t))}})});var Su={};ge(Su,{_handleClick:()=>s2,_handlePreEdit:()=>i2,_handlePreSend:()=>r2,addClickListener:()=>yu,addPreEditListener:()=>Jn,addPreSendListener:()=>lt,removeClickListener:()=>vu,removePreEditListener:()=>Qn,removePreSendListener:()=>ct});async function r2(e,t,n,r){n.replyOptions=r;for(let i of fu)try{let s=await i(e,t,n);if(s&&s.cancel===!0)return!0}catch(s){mu.error(`MessageSendHandler:Listenerencounteredanunknownerror
`,s)}return!1}async function i2(e,t,n){for(let r of gu)try{await r(e,t,n)}catch(i){mu.error(`MessageEditHandler:Listenerencounteredanunknownerror
`,i)}}function lt(e){return fu.add(e),e}function Jn(e){return gu.add(e),e}function ct(e){return fu.delete(e)}function Qn(e){return gu.delete(e)}function s2(e,t,n){e=un.getMessage(t.id,e.id)??e;for(let r of hu)try{r(e,t,n)}catch(i){mu.error(`MessageClickHandler:Listenerencounteredanunknownerror
`,i)}}function yu(e){return hu.add(e),e}function vu(e){return hu.delete(e)}var mu,fu,gu,hu,Sn=m(()=>{"use strict";a();be();T();mu=new Y("MessageEvents","#e5c890"),fu=new Set,gu=new Set;hu=new Set});var Ry,Ay=m(()=>{"use strict";a();Ry=["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","igshid"]});var Ly,a2,bu,Ey=m(()=>{"use strict";a();Sn();w();b();Ay();Ly=/[\\^$.*+?()[\]{}|]/g,a2=RegExp(Ly.source),bu=g({name:"ClearURLs",description:"Removes tracking garbage from URLs",authors:[p.adryd],dependencies:["MessageEventsAPI"],escapeRegExp(e){return e&&a2.test(e)?e.replace(Ly,"\\$&"):e||""},createRules(){let e=Ry;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 i=new RegExp("^(www\\.)?"+this.escapeRegExp(n[1]).replace(/\\\./,"\\.").replace(/^\\\*\\\./,"(.+?\\.)?").replace(/\\\*/,".+?")+"$"),s=i.toString();this.hostRules.set(s,i),this.rulesByHost.get(s)==null&&this.rulesByHost.set(s,new Set),this.rulesByHost.get(s).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,i,s)=>{this.removeParam(n,i,s)})}),this.hostRules.forEach((n,r)=>{!n.test(t.hostname)||this.rulesByHost.get(r).forEach(i=>{t.searchParams.forEach((s,l,c)=>{this.removeParam(i,l,c)})})}),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=lt((e,t)=>this.onSend(t)),this.preEdit=Jn((e,t,n)=>this.onSend(n))},stop(){ct(this.preSend),Qn(this.preEdit)}})});var Tu,Dy=m(()=>{"use strict";a();w();b();Tu=g({name:"ColorSighted",description:"Removes the colorblind-friendly icons from statuses, just like 2015-2017 Discord",authors:[p.lewisakura],patches:[{find:"Masks.STATUS_ONLINE",replacement:{match:/Masks\.STATUS_(?:IDLE|DND|STREAMING|OFFLINE)/g,replace:"Masks.STATUS_ONLINE"}},{find:".AVATAR_STATUS_MOBILE_16;",replacement:{match:/(\.fromIsMobile,.+?)\i.status/,replace:(e,t)=>`${t}"online"`}}]})});var l2,xu,Oy=m(()=>{"use strict";a();w();ri();Wr();b();O();O();T();l2=e=>()=>{throw new Error(`'${e}'isDiscordDesktoponly.`)},xu=g({name:"ConsoleShortcuts",description:"Adds shorter Aliases for many things on th
`,u),l[0]}})();return c&&s&&r.set(s,c),c}}let t;return{wp:Vencord.Webpack,wpc:Gt.c,wreq:Gt,wpsearch:hl,wpex:yl,wpexs:n=>Vencord.Webpack.extract(Vencord.Webpack.findModuleId(n)),find:e(n=>n),findAll:or,findByProps:e(K.byProps),findAllByProps:(...n)=>or(K.byProps(...n)),findByCode:e(K.byCode),findAllByCode:n=>or(K.byCode(n)),findStore:e(K.byStoreName),PluginsApi:Vencord.Plugins,plugins:Vencord.Plugins.plugins,React:I,Settings:Vencord.Settings,Api:Vencord.Api,reload:()=>location.reload(),restart:l2("restart"),canonicalizeMatch:Uo,canonicalizeReplace:Ts,canonicalizeReplacement:jr,fakeRender:(n,r)=>{let i=t?.deref(),s=i?.closed===!1?i:window.open("about:blank","Fake Render","popup,width=500,height=500");t=new WeakRef(s),s.focus(),_o.render(I.createElement(n,r),s.document.body)}}},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 To,wu,Pu,Js,Mu,Iu,_y=m(()=>{"use strict";a();uo();D();w();be();Ze();b();dr();T();To=new Y("CrashHandler"),wu=k({attemptToPreventCrashes:{type:3,description:"Whether to attempt to prevent Discord crashes.",default:!0},attemptToNavigateToHome:{type:3,description:"Whether to attempt to navigate to the home when preventing Discord crashes.",default:!1}}),Pu=0,Js=0,Mu=!1,Iu=g({name:"CrashHandler",description:"Utility plugin for handling and possibly recovering from Crashes without a restart",authors:[p.Nuckyz],enabledByDefault:!0,popAllModals:void 0,settings:wu,patches:[{find:".Messages.ERRORS_UNEXPECTED_CRASH",replacement:{match:/(?=this\.setState\()/,replace:"$self.handleCrash(this)||"}},{find:'dispatch({type:"MODAL_POP_ALL"})',replacement:{match:/"MODAL_POP_ALL".+?};(?<=(\i)=function.+?)/,replace:(e,t)=>`${e}$self.popAllModals=${t};`}}],handleCrash(e){if(Date.now()-Js<=1e3&&!Mu)return!0;if(Mu=!1,++Pu>5){try{he({color:"#eed202",title:"Discord has crashed!",body:"Awn :( Discord has crashed more than five times, not attempting to recover.",noPersist:!0})}catch{}return Js=Date.now(),!1}setTimeout(()=>Pu--,6e4);try{return Pu===1&&ii("Uh oh, Discord has just crashed... but good news, there is a Vencord update available that might fix this issue! Would you like to update now?",!0),wu.store.attemptToPreventCrashes?(this.handlePreventCrash(e),!0):!1}catch(t){return To.error("Failed to handle crash",t),!1}finally{Js=Date.now()}},handlePreventCrash(e){if(Date.now()-Js>=1e3)try{he({color:"#eed202",title:"Discord has crashed!",body:"Attempting to recover...",noPersist:!0})}catch{}try{E.dispatch({type:"CONTEXT_MENU_CLOSE"})}catch(t){To.debug("Failed to close open context menu.",t)}try{this.popAllModals?.()}catch(t){To.debug("Failed to close old modals.",t)}try{kl()}catch(t){To.debug("Failed to close all open modals.",t)}try{E.dispatch({type:"USER_PROFILE_MODAL_CLOSE"})}catch(t){To.debug("Failed to close user popout.",t)}try{E.dispatch({type:"LAYER_POP_ALL"})}catch(t){To.debug("Failed to pop all layers.",t)}if(wu.store.attemptToNavigateToHome)try{Gr.transitionTo("/channels/@me")}catch(t){To.debug("Failed to navigate to home",t)}try{Mu=!0,e.forceUpdate()}catch(t){To.debug("Failed to update crash handler component.",t)}}})});async function By(e){return(await d2.getAsset(Vs.store.appID,[e,void 0]))[0]}async function $y(){let{appID:e,appName:t,details:n,state:r,type:i,startTime:s,endTime:l,imageBig:c,imageBigTooltip:u,imageSmall:h,imageSmallTooltip:f,buttonOneText:y,buttonOneURL:S,buttonTwoText:x,buttonTwoURL:R}=Vs.store;if(!t)return;let C={application_id:e||"0",name:t,state:r,details:n,type:i,flags:1<<0};s&&(C.timestamps={start:s},l&&(C.timestamps.end=l)),y&&(C.buttons=[y,x].filter(vs),C.metadata={button_urls:[S,R].filter(vs)}),c&&(C.assets={large_image:await By(c),large_text:u}),h&&(C.assets={...C.assets,small_image:await By(h),small_text:f});for(let _ in C){if(_==="type")continue;let $=C[_];(!$||$.length===0)&&delete C[_]}return C}async function di(e){let t=await $y();E.dispatch({type:"LOCAL_ACTIVITY_UPDATE",activity:e?null:t,socketId:"CustomRPC"})}var c2,u2,p2,d2,Qt,Fy,Qs,m2
`.trim().replace(/\s+/g," ")})}},{name:"view friend invites",description:"View a list of all generated friend invites.",inputType:3,execute:async(e,t)=>{let r=(await zu.getAllFriendInvites()).map(i=>`
`)||"You have no active friend invites!"})}},{name:"revoke friend invites",description:"Revokes all generated friend invites.",inputType:3,execute:async(e,t)=>(await zu.revokeFriendInvites(),void oe(t.channel.id,{content:"All friend invites have been revoked."}))}]})});var qu={};ge(qu,{getSettingStore:()=>mv,getSettingStoreLazy:()=>Wu});function mv(e,t){if(!M.plugins.SettingsStoreAPI.enabled)throw new Error("Cannot use SettingsStoreAPI without setting as dependency.");return L2?.find(n=>n?.settingsStoreApiGroup===e&&n?.settingsStoreApiName===t)}function Wu(e,t){return dt(()=>mv(e,t))}var L2,Ku=m(()=>{"use strict";a();sn();be();O();D();L2=dt(()=>{let e=os('"textAndImages","renderSpoilers"');if(e==null)return new Y("SettingsStoreAPI").error("Didn't find stores module.");let t=Gt(e);if(t!=null)return Object.values(t).filter(n=>n?.settingsStoreApiGroup)})});var Yu,fv=m(()=>{a();(window.VencordStyles??=new Map).set("src/plugins/gameActivityToggle/style.css",{name:"src/plugins/gameActivityToggle/style.css",source:`[class*="withTagAsButton"]{
min-width:88px;
}
`,classNames:{},dom:null});Yu="src/plugins/gameActivityToggle/style.css"});function D2(e){return function(){return o("svg",{width:"24",height:"24",viewBox:"0 96 960 960"},o("path",{fill:"currentColor",d:"M182 856q-51 0-79-35.5T82 734l42-300q9-60 53.5-99T282 296h396q60 0 104.5 39t53.5 99l42 300q7 51-21 86.5T778 856q-21 0-39-7.5T706 826l-90-90H344l-90 90q-15 15-33 22.5t-39 7.5Zm498-240q17 0 28.5-11.5T720 576q0-17-11.5-28.5T680 536q-17 0-28.5 11.5T640 576q0 17 11.5 28.5T680 616Zm-80-120q17 0 28.5-11.5T640 456q0-17-11.5-28.5T600 416q-17 0-28.5 11.5T560 456q0 17 11.5 28.5T600 496ZM310 616h60v-70h70v-60h-70v-70h-60v70h-70v60h70v70Z"}),!e&&o("line",{x1:"920",y1:"280",x2:"40",y2:"880",stroke:"var(--status-danger)","stroke-width":"80"}))}}function O2(){let e=gv?.useSetting();return o(E2,{tooltipText:e?"Disable Game Activity":"Enable Game Activity",icon:D2(e),role:"switch","aria-checked":!e,onClick:()=>gv?.updateSetting(t=>!t)})}var gv,E2,Zu,hv=m(()=>{"use strict";a();Ku();Ge();ie();w();b();O();fv();gv=Wu("status","showCurrentGame"),E2=ce("Button.Sizes.NONE,disabled:");Zu=g({name:"GameActivityToggle",description:"Adds a button next to the mic and deafen button to toggle game activity.",authors:[p.Nuckyz],dependencies:["SettingsStoreAPI"],patches:[{find:".Messages.ACCOUNT_SPEAKING_WHILE_MUTED",replacement:{match:/this\.renderNameZone\(\).+?children:\[/,replace:"$&$self.GameActivityToggleButton(),"}}],GameActivityToggleButton:A.wrap(O2,{noop:!0}),start(){Je(Yu)},stop(){Mt(Yu)}})});var _2,Xu,yv=m(()=>{"use strict";a();w();tt();b();O();_2=Ke('name:"expression-picker-last-active-view"',{close:K.byCode("activeView:null","setState")}),Xu=g({name:"GifPaste",description:"Makes picking a gif in the gif picker insert a link into the chatbox instead of instantly sending it",authors:[p.Ven],patches:[{find:".handleSelectGIF=",replacement:{match:/\.handleSelectGIF=function.+?\{/,replace:".handleSelectGIF=function(gif){return $self.handleSelect(gif);"}}],handleSelect(e){e&&(Hn(e.url+" "),_2.close())}})});var Ju={};ge(Ju,{_buildPopoverElements:()=>F2,addButton:()=>bn,buttons:()=>ra,removeButton:()=>Tn});function bn(e,t){ra.set(e,t)}function Tn(e){ra.delete(e)}function F2(e,t){let n=[];for(let[r,i]of ra.entries())try{let s=i(e);s&&(s.key??=r,n.push(t(s)))}catch(s){B2.error(`[${r}]`,s)}return n}var B2,ra,Ko=m(()=>{"use strict";a();be();B2=new Y("MessagePopover"),ra=new Map});var gi,Sv,hi,vv,$2,Qu,bv=m(()=>{"use strict";a();Cn();Ko();_n();w();b();T();Sv="HideAttachments_HiddenIds",hi=new Set,vv=()=>Qe(Sv).then(e=>(hi=e??new Set,hi)),$2=e=>Ve(Sv,e),Qu=g({name:"HideAttachments",description:"Hide attachments and Embeds for individual messages via hover button",authors:[p.Ven],dependencies:["MessagePopoverAPI"],async start(){gi=document.createElement("style"),gi.id="VencordHideAttachments",document.head.appendChild(gi),await vv(),await this.buildCss(),bn("HideAttachments",e=>{if(!e.attachments.length&&!e.embeds.length)return null;let t=hi.has(e.id);return{label:t?"Show Attachments":"Hide Attachments",icon:t?Zs:Xs,message:e,channel:Z.getChannel(e.channel_id),onClick:()=>this.toggleHide(e.id)}})},stop(){gi.remove(),hi.clear(),Tn("HideAttachments")},async buildCss(){let e=[...hi].map(t=>`#message-accessories-${t}`).join(",");gi.textContent=`
`,classNames:{},dom:null});sp="src/plugins/imageZoom/styles.css"});var xe,Nv,ap,ip=m(()=>{"use strict";a();Pt();D();Ge();Hs();w();nr();b();T();Iv();np();Cv();xe=k({saveZoomValues:{type:3,description:"Whether to save zoom and lens size values",default:!0},preventCarouselFromClosingOnClick:{type:3,description:"Allow the image modal in the image slideshow thing / carousel to remain open when clicking on the image",default:!0},invertScroll:{type:3,description:"Invert scroll",default:!0},nearestNeighbour:{type:3,description:"Use Nearest Neighbour Interpolation when scaling images",default:!1},square:{type:3,description:"Make the lens square",default:!1},zoom:{description:"Zoom of the lens",type:5,markers:mr(1,50,4),default:2,stickToMarkers:!1},size:{description:"Radius / Size of the lens",type:5,markers:mr(50,1e3,50),default:100,stickToMarkers:!1},zoomSpeed:{description:"How fast the zoom / lens size changes",type:5,markers:mr(.1,5,.2),default:.5,stickToMarkers:!1}}),Nv=e=>()=>{e.push(o(L.MenuGroup,{id:"image-zoom"},o(L.MenuCheckboxItem,{id:"vc-square",label:"Square Lens",checked:xe.store.square,action:()=>{xe.store.square=!xe.store.square,cn.close()}}),o(L.MenuControlItem,{id:"vc-zoom",label:"Zoom",control:(t,n)=>o(L.MenuSliderControl,{ref:n,...t,minValue:1,maxValue:50,value:xe.store.zoom,onChange:At(r=>xe.store.zoom=r,100)})}),o(L.MenuControlItem,{id:"vc-size",label:"Lens Size",control:(t,n)=>o(L.MenuSliderControl,{ref:n,...t,minValue:50,maxValue:1e3,value:xe.store.size,onChange:At(r=>xe.store.size=r,100)})}),o(L.MenuControlItem,{id:"vc-zoom-speed",label:"Zoom Speed",control:(t,n)=>o(L.MenuSliderControl,{ref:n,...t,minValue:.1,maxValue:5,value:xe.store.zoomSpeed,onChange:At(r=>xe.store.zoomSpeed=r,100),renderValue:r=>`${r.toFixed(3)}x`})})))},ap=g({name:"ImageZoom",description:"Lets you zoom in to images and gifs. Use scroll wheel to zoom in and shift + scroll wheel to increase lens radius / size",authors:[p.Aria],tags:["ImageUtilities"],patches:[{find:'"renderLinkComponent","maxWidth"',replacement:{match:/(return\(.{1,100}\(\)\.wrapper.{1,100})(src)/,replace:`$1id:'${yi}',$2`}},{find:"handleImageLoad=",replacement:[{match:/(render=function\(\){.{1,500}limitResponsiveWidth.{1,600})onMouseEnter:/,replace:"$1...$self.makeProps(this),onMouseEnter:"},{match:/componentDidMount=function\(\){/,replace:"$&$self.renderMagnifier(this);"},{match:/componentWillUnmount=function\(\){/,replace:"$&$self.unMountMagnifier();"}]},{find:".carouselModal,",replacement:{match:/onClick:(\i),/,replace:"onClick:$self.settings.store.preventCarouselFromClosingOnClick ? () => {} : $1,"}}],settings:xe,currentMagnifierElement:null,element:null,Magnifier:rp,root:null,makeProps(e){return{onMouseOver:()=>this.onMouseOver(e),onMouseOut:()=>this.onMouseOut(e),onMouseDown:t=>this.onMouseDown(t,e),onMouseUp:()=>this.onMouseUp(e),id:e.props.id}},renderMagnifier(e){e.props.id===yi&&(this.currentMagnifierElement||(this.currentMagnifierElement=o(rp,{size:xe.store.size,zoom:xe.store.zoom,instance:e}),this.root=_o.createRoot(this.element),this.root.render(this.currentMagnifierElement)))},unMountMagnifier(){this.root?.unmount(),this.currentMagnifierElement=null,this.root=null},onMouseOver(e){e.setState(t=>({...t,mouseOver:!0}))},onMouseOut(e){e.setState(t=>({...t,mouseOver:!1}))},onMouseDown(e,t){e.button===0&&t.setState(n=>({...n,mouseDown:!0}))},onMouseUp(e){e.setState(t=>({...t,mouseDown:!1}))},start(){Je(sp),pe("image-context",Nv),this.element=document.createElement("div"),this.element.classList.add("MagnifierContainer"),document.body.appendChild(this.element)},stop(){Mt(sp),this.root&&this.root.unmount(),this.element?.remove(),de("image-context",Nv)}})});function K2(e){let t=e?.message?.content,[n,r]=I.useState("password");return o(Le,{...e},o($e,null,o(v.FormTitle,{tag:"h4"},"Decrypt Message")),o(Ue,null,o(v.FormTitle,{tag:"h5",style:{marginTop:"10px"}},"Secret"),o(Re,{defaultValue:t,disabled:!0}),o(v.FormTitle,{tag:"h5"},"Password"),o(Re,{style:{marginBottom:"20px"},onChange:r})),o(Tt,null,o(N,{color:N.Colors.GREEN,onClick:()=>{let i=lp(t,n,!0);!i||!e?.messag
`,classNames:{},dom:null});Mp="src/plugins/messageLogger/deleteStyleText.css"});function e1(){M.plugins.MessageLogger.deleteStyle==="text"?(Je(Mp),Mt(Pp)):(Mt(Mp),Je(Pp))}var SP,t1,n1,o1,Ip,r1=m(()=>{"use strict";a();Jv();Pt();D();Ge();ie();w();be();b();O();T();Qv();Vv();SP=P("edited","communicationDisabled","isSystemMessage");t1="ml-remove-history",n1="ml-toggle-style",o1=(e,t)=>()=>{let{message:n}=t,{deleted:r,editHistory:i,id:s,channel_id:l}=n;if(!r&&!i?.length)return;e:{if(!r)break e;let c=document.getElementById(`chat-messages-${l}-${s}`);if(!c)break e;e.push(o(L.MenuItem,{id:n1,key:n1,label:"Toggle Deleted Highlight",action:()=>c.classList.toggle("messagelogger-deleted")}))}e.push(o(L.MenuItem,{id:t1,key:t1,label:"Remove Message History",color:"danger",action:()=>{r?E.dispatch({type:"MESSAGE_DELETE",channelId:l,id:s,mlDeleted:!0}):n.editHistory=[]}}))},Ip=g({name:"MessageLogger",description:"Temporarily logs deleted and edited messages.",authors:[p.rushii,p.Ven],start(){e1(),pe("message",o1)},stop(){de("message",o1)},renderEdit(e){return o(A,{noop:!0},o("div",{className:"messagelogger-edited"},Ie.parse(e.content),o(kn,{timestamp:e.timestamp,isEdited:!0,isInline:!1},o("span",{className:SP.edited}," ","(",it.Messages.MESSAGE_EDITED,")"))))},makeEdit(e,t){return{timestamp:Jt?.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:()=>e1()},ignoreBots:{type:3,description:"Whether to ignore messages by bots",default:!1},ignoreSelf:{type:3,description:"Whether to ignore messages by yourself",default:!1},ignoreUsers:{type:0,description:"Comma-separated list of user IDs to ignore",default:""}},handleDelete(e,t,n){try{let u=function(h){let f=e.get(h);if(!f)return;let y=64;t.mlDeleted||(f.flags&y)===y||i&&f.author?.bot||s&&f.author?.id===c||l.includes(f.author?.id)?e=e.remove(h):e=e.update(h,x=>x.set("deleted",!0).set("attachments",x.attachments.map(R=>(R.deleted=!0,R))))};var r=u;if(e==null||!n&&!e.has(t.id))return e;let{ignoreBots:i,ignoreSelf:s,ignoreUsers:l}=M.plugins.MessageLogger,c=F.getCurrentUser().id;n?t.ids.forEach(u):u(t.id)}catch(i){new Y("MessageLogger").error("Error during handleDelete",i)}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 = $self.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 = $self.handleDelete(cache, $1, true); $2commit(cache);},"},{match:/(MESSAGE_UPDATE:function\((\w)\).+?)\.update\((\w)/,replace:"$1.update($3,m => (($2.message.flags & 64) === 64 || (Vencord.Settings.plugins.MessageLogger.ignoreBots && $2.message.author?.bot) || (Vencord.Settings.plugins.MessageLogger.ignoreSelf && $2.message.author?.id === Vencord.Webpack.Common.UserStore.getCurrentUser().id)) ? m : $2.message.content !== m.editHistory?.[0]?.content && $2.message.content !== m.content ? m.set('editHistory',[...(m.editHistory || []), $self.makeEdit($2.message, m)]) : m).update($3"},{match:/(?<=getLastEditableMessage=.{0,200}\.find\(\(function\((\i)\)\{)return/,replace:"return !$1.deleted &&"}]},{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]
`)}):(oe(n.channel.id,{author:Bn,content:`${xo}Thetag**${e.name}**doesnotexistanymore!PleasereloadurDiscordtofix:)`}),{content:`/${e.name}`}),[bP]:!0},"CustomTags")}var xo,pa,bP,Bn,ua,ca,TP,xP,Cp,s1=m(()=>{"use strict";a();_t();Cn();D();w();b();xo="<:luna:1035316192220553236>",pa="MessageTags_TAGS",bP=Symbol("MessageTags"),Bn={id:"821472922140803112",bot:!1},ua=()=>Qe(pa).then(e=>e??[]),ca=e=>Qe(pa).then(t=>(t??[]).find(n=>n.name===e)??null),TP=async e=>{let t=await ua();return t.push(e),Ve(pa,t),t},xP=async e=>{let t=await ua();return t=await t.filter(n=>n.name!==e),Ve(pa,t),t};Cp=g({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 ua())i1(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=Oe(e[0].options,"tag-name",""),r=Oe(e[0].options,"message","");if(await ca(n))return oe(t.channel.id,{author:Bn,content:`${xo}ATagwiththename**${n}**alreadyexists!`});let i={name:n,enabled:!0,message:r};i1(i),await TP(i),oe(t.channel.id,{author:Bn,content:`${xo}Successfullycreatedthetag**${n}**!`});break}case"delete":{let n=Oe(e[0].options,"tag-name","");if(!await ca(n))return oe(t.channel.id,{author:Bn,content:`${xo}ATagwiththename**${n}**doesnotexist!`});li(n),await xP(n),oe(t.channel.id,{author:Bn,content:`${xo}Successfullydeletedthetag**${n}**!`});break}case"list":{oe(t.channel.id,{author:Bn,embeds:[{title:"All Tags:",description:(await ua()).map(n=>`\`${n.name}\`: ${n.message.slice(0,72).replaceAll("\\n"," ")}${n.message.length>72?"...":""}`).join(`
`)||`${xo}Woops!Therearenotagsyet,use\`/tags create\` to create one!`,color:14122879,type:"rich"}]});break}case"preview":{letn=Oe(e[0].options,"tag-name",""),r=awaitca(n);if(!r)returnoe(t.channel.id,{author:Bn,content:`${xo} A Tag with the name **${n}** does not exist!`});oe(t.channel.id,{author:Bn,content:r.message.replaceAll("\\n",`
`)});break}default:{oe(t.channel.id,{author:Bn,content:"Invalid sub-command"});break}}}}]})});function wP(e){let t="";for(let n=0;n<e.length;n++)t+=n%2?e[n].toUpperCase():e[n].toLowerCase();return t}var Np,a1=m(()=>{"use strict";a();_t();w();b();Np=g({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:[So],inputType:3,execute:(e,t)=>{let n=Oe(e,"message","");oe(t.channel.id,{content:n})}},{name:"lenny",description:"Sends a lenny face",options:[So],execute:e=>({content:Oe(e,"message","")+" ( \u0361\xB0 \u035C\u0296 \u0361\xB0)"})},{name:"mock",description:"mOcK PeOpLe",options:[Ho],execute:e=>({content:wP(Oe(e,"message",""))})}]})});var kp,l1=m(()=>{"use strict";a();_t();w();b();kp=g({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)>"},{name:"blush",description:"\u0AEE\u02F6\u1D54\u1D55\u1D54\u02F6\u10D0"},{name:"confused",description:"(\u2022\u0E34_\u2022\u0E34)?"},{name:"sleeping",description:"(\u1D17_\u1D17)"},{name:"laughing",description:"o(\u2267\u25BD\u2266)o"}].map(e=>({...e,options:[So],execute:t=>({content:Oe(t,"message","")+e.description})}))})});function CP(e){wo.store.tagSettings??=Rp;let[t,n]=V(wo.store.tagSettings),r=i=>{n(i),e.setValue(i)};return o(le,{flexDirection:"column"},vr.map(i=>o(Et,{style:{padding:"1em1em0"}},o(v.FormTitle,{style:{width:"fit-content"}},o(W,{text:i.description},({onMouseEnter:s,onMouseLeave:l})=>o("div",{onMouseEnter:s,onMouseLeave:l},i.displayName,"Tag",o(Vn,{type:Vn.Types[i.name]})))),o(Re,{type:"text",value:t[i.name]?.text??i.displayName,placeholder:`Text on tag (default: ${i.displayName})`,onChange:s=>{t[i.name].text=s,r(t)},className:G.bottom16}),o(ft,{value:t[i.name]?.showInChat??!0,onChange:s=>{t[i.name].showInChat=s,r(t)},hideBorder:!0},"Showinmessages"),o(ft,{value:t[i.name]?.showInNotChat??!0,onChange:s=>{t[i.name].showInNotChat=s,r(t)},hideBorder:!0},"Showinmemberlistandprofiles"))))}var PP,MP,IP,Vn,c1,vr,Rp,wo,Ap,u1=m(()=>{"usestrict";a();D();wt();w();Xe();b();O();T();PP="1081004946872352958",MP=P("computePermissions","canEveryoneRole"),IP=P("SEND_MESSAGES","VIEW_CREATOR_MONETIZATION_ANALYTICS"),Vn=ke(e=>e.Types?.[0]==="BOT"),c1=(e,t)=>!!e?.webhookId&&t.isNonUserBot(),vr=[{name:"WEBHOOK",displayName:"Webhook",description:"Messagessentbywebhooks",condition:c1},{name:"OWNER",displayName:"Owner",description:"Ownstheserver",condition:(e,t,n)=>ue.getGuild(n?.guild_id)?.ownerId===t.id},{name:"ADMINISTRATOR",displayName:"Admin",description:"Hastheadministratorpermission",permissions:["ADMINISTRATOR"]},{name:"MODERATOR_STAFF",displayName:"Staff",description:"Canmanagetheserver,channelsorroles",permissions:["MANAGE_GUILD","MANAGE_CHANNELS","MANAGE_ROLES"]},{name:"MODERATOR",displayName:"Mod",description:"Canmanagemessagesorkick/banpeople",permissions:["MANAGE_MESSAGES","KICK_MEMBERS","BAN_MEMBERS"]},{name:"VOICE_MODERATOR",displayName:"VCMod",description:"Canmanagevoicechats",permissions:["MOVE_MEMBERS","MUTE_MEMBERS","DEAFEN_MEMBERS"]}],Rp=Object.fromEntries(vr.map(({name:e,displayName:t})=>[e,{text:t,showInChat:!0,showInNotChat:!0}]));wo=k({dontShowForBots:{description:"Don'tshowextratagsforbots(excludingwebhooks)",type:3},dontShowBotTag:{description:"Onlyshowextratagsforbots/Hide[BOT]text",type:3},tagSettings:{type:6,component:CP,description:"fillme"}}),Ap=g({name:"MoreUserTags",description:"Addstagsforwebhooksandmoderativeroles(owner,admin,etc.)",authors:[p.Cyn,p.TheSun,p.RyanCaoDev,p.LordElias],settings:wo,pa
`,s),"Failed to fetch user. Check the console for more info."}}return null}var U1,JP,QP,ya,VP,eM,tM,nM,nd,H1=m(()=>{"use strict";a();_t();w();mi();sn();b();O();U1=0,JP=20,QP=128,ya=10,VP=$n(()=>Promise.all(Array.from({length:ya},(e,t)=>G1(`https://raw.githubusercontent.com/VenPlugs/petpet/main/frames/pet${t}.gif`)))),eM=ce(".USER("),tM=ce("UPLOAD_FILE_LIMIT_ERROR"),nM=P("getUploads");nd=g({name:"petpet",description:"Adds a /petpet slash command to create headpet gifs from any image",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:i}=await ta(),s=await VP(),l=Oe(e,"no-server-pfp",!1);try{var c=await oM(e,t,l);if(!c)throw"No Image specified!"}catch(C){oe(t.channel.id,{content:String(C)});return}let u=await G1(c),h=Oe(e,"delay",JP),f=Oe(e,"resolution",QP),y=new n,S=document.createElement("canvas");S.width=S.height=f;let x=S.getContext("2d");for(let C=0;C<ya;C++){x.clearRect(0,0,S.width,S.height);let _=C<ya/2?C:ya-C,$=.8+_*.02,B=.8-_*.05,q=(1-$)*.5+.1,ee=1-B-.08;x.drawImage(u,q*f,ee*f,$*f,B*f),x.drawImage(s[C],0,0,f,f);let{data:j}=x.getImageData(0,0,f,f),z=r(j,256),te=i(j,z);y.writeFrame(te,f,f,{transparent:!0,palette:z,delay:h})}y.finish();let R=new File([y.bytesView()],"petpet.gif",{type:"image/gif"});setTimeout(()=>tM([R],t.channel,U1),10)}}]})});function W1(){return st(["plugins.PinDMs.pinnedDMs"]),va()}function br(e){return va().has(e)}function q1(e){let t=va();t.delete(e)||t.add(e),j1([...t])}function rd(){return va(),Mi.store.pinOrder===0?rM.getPrivateChannelIds().filter(br):Fn}function K1(e){return rd()[e]}function id(e,t){let n=z1(),r=n.indexOf(e),i=r+t;[n[r],n[i]]=[n[i],n[r]],j1(n)}var Mi,rM,Fn,od,z1,j1,iM,va,sd=m(()=>{"use strict";a();D();b();O();Mi=k({pinOrder:{type:4,description:"Which order should pinned DMs be displayed in?",options:[{label:"Most recent message",value:0,default:!0},{label:"Custom (right click channels to reorder)",value:1}]}}),rM=ae("PrivateChannelSortStore"),z1=()=>(M.plugins.PinDMs.pinnedDMs||void 0)?.split(","),j1=e=>{od=void 0,M.plugins.PinDMs.pinnedDMs=e.join(",")},iM=()=>(Fn=z1()??[],od=new Set(Fn)),va=()=>od??iM()});function Y1(e){let t=br(e),n=t&&Mi.store.pinOrder===1;return o(d,null,o(L.MenuItem,{id:"pin-dm",label:t?"Unpin DM":"Pin DM",action:()=>q1(e)}),n&&Fn[0]!==e&&o(L.MenuItem,{id:"move-pin-up",label:"Move Pin Up",action:()=>id(e,-1)}),n&&Fn[Fn.length-1]!==e&&o(L.MenuItem,{id:"move-pin-down",label:"Move Pin Down",action:()=>id(e,1)}))}function J1(){pe("gdm-context",Z1),pe("user-context",X1)}function Q1(){de("gdm-context",Z1),de("user-context",X1)}var Z1,X1,V1=m(()=>{"use strict";a();Pt();T();sd();Z1=(e,t)=>()=>{let n=nt("leave-channel",e);n&&n.unshift(Y1(t.channel.id))},X1=(e,t)=>()=>{let n=nt("close-dm",e);if(n){let r=n.findIndex(i=>i?.props?.id==="close-dm");n.splice(r,0,Y1(t.channel.id))}}});var ad,eS=m(()=>{"use strict";a();w();b();V1();sd();ad=g({name:"PinDMs",description:"Allows you to pin private channels to the top of your DM list. To pin/unpin or reorder pins, right click DMs",authors:[p.Ven,p.Strencher],settings:Mi,start:J1,stop:Q1,usePinCount(e){let t=W1();return e.length?[t.size]:[]},getChannel(e,t){return e[K1(t)]},isPinned:br,getSnapshot:rd,getScrollOffset(e,t,n,r,i){return br(e)?t*(Fn.indexOf(e)+r)+n:(t+n)*2+t*Fn.length+i},patches:[{find:".privateChannelsHeaderContainer,",replacement:[{match:/privateChannelIds:(\i),/,replace:"privateChann
`,e))},stop(){Cd=void 0},decodeError(e,...t){let n=0;return Cd?.[e]?.replace(/%s/g,()=>{let r=t[n];return n++,r})}})});var Rd={};ge(Rd,{ServerListRenderPosition:()=>ka,addServerListElement:()=>Ii,removeServerListElement:()=>Ci,renderAll:()=>AM});function kd(e){return e===0?kM:RM}function Ii(e,t){kd(e).add(t)}function Ci(e,t){kd(e).delete(t)}var NM,ka,kM,RM,AM,Ra=m(()=>{"use strict";a();be();NM=new Y("ServerListAPI"),ka=(n=>(n[n.Above=0]="Above",n[n.In=1]="In",n))(ka||{}),kM=new Set,RM=new Set;AM=e=>{let t=[];for(let n of kd(e))try{t.unshift(n())}catch(r){NM.error("Failed to render server list element:",r)}return t}});function LM(){let e=[];Object.values(ue.getGuilds()).forEach(t=>{ms.getChannels(t.id).SELECTABLE.forEach(n=>{!$r.hasUnread(n.channel.id)||e.push({channelId:n.channel.id,messageId:$r.lastMessageId(n.channel.id),readStateType:0})})}),E.dispatch({type:"BULK_ACK",context:"APP",channels:e})}var EM,Ad,AS=m(()=>{"use strict";a();Ra();w();b();T();EM=()=>o(N,{onClick:LM,size:N.Sizes.MIN,color:N.Colors.BRAND,style:{marginTop:"2px",marginBottom:"8px",marginLeft:"9px"}},"Read all"),Ad=g({name:"ReadAllNotificationsButton",description:"Read all server notifications with a single button click!",authors:[p.kemo],dependencies:["ServerListAPI"],renderReadAllButton:()=>o(EM,null),start(){Ii(0,this.renderReadAllButton)},stop(){Ci(0,this.renderReadAllButton)}})});var Bt,Aa=m(()=>{"use strict";a();D();b();Bt=k({notices:{type:3,description:"Also show a notice at the top of your screen when removed (use this if you don't want to miss any notifications).",default:!1},offlineRemovals:{type:3,description:"Notify you when starting discord if you were removed while offline.",default:!0},friends:{type:3,description:"Notify when a friend removes you",default:!0},friendRequestCancels:{type:3,description:"Notify when a friend request is cancelled",default:!0},servers:{type:3,description:"Notify when removed from a server",default:!0},groups:{type:3,description:"Notify when removed from a group chat",default:!0}})});var Ld=m(()=>{"use strict";a()});async function _M(){Nt.delMany(["relationship-notifier-guilds","relationship-notifier-groups","relationship-notifier-friends"])}async function Ed(){await _M();let[e,t,n]=await Nt.getMany([LS(),ES(),DS()]);if(await Promise.all([Ea(),Da(),Ni()]),Bt.store.offlineRemovals){if(Bt.store.groups&&t?.size)for(let[r,i]of t)wr.has(r)||to(`Youarenolongerinthegroup${i.name}.`,i.iconURL);if(Bt.store.servers&&e?.size)for(let[r,i]of e)xr.has(r)||to(`Youarenolongerintheserver${i.name}.`,i.iconURL);if(Bt.store.friends&&n?.friends.length)for(let r of n.friends){if(Xo.friends.includes(r))continue;let i=await Rn.fetchUser(r).catch(()=>{});i&&to(`Youarenolongerfriendswith${zn(i)}.`,i.getAvatarURL(void 0,void 0,!1),()=>mn(i.id))}if(Bt.store.friendRequestCancels&&n?.requests?.length)for(let r of n.requests){if(Xo.requests.includes(r)||[1,2,4].includes(et.getRelationshipType(r)))continue;let i=await Rn.fetchUser(r).catch(()=>{});i&&to(`Friendrequestfrom${zn(i)}hasbeenrevoked.`,i.getAvatarURL(void 0,void 0,!1),()=>mn(i.id))}}}function to(e,t,n){Bt.store.notices&&La.showNotice(e,"OK",()=>La.popNotice()),he({title:"Relationship Notifier",body:e,icon:t,onClick:n})}function OS(e){return xr.get(e)}function Dd(e){xr.delete(e),Ea()}async function Ea(){xr.clear();let e=F.getCurrentUser().id;for(let[t,{name:n,icon:r}]of Object.entries(ue.getGuilds()))Ae.isMember(t,e)&&xr.set(t,{id:t,name:n,iconURL:r&&`https://cdn.discordapp.com/icons/${t}/${r}.png`});await Nt.set(LS(),xr)}function _S(e){return wr.get(e)}function Od(e){wr.delete(e),Da()}async function Da(){wr.clear();for(let{type:e,id:t,name:n,rawRecipients:r,icon:i}of Z.getSortedPrivateChannels())e===3&&wr.set(t,{id:t,name:n||r.map(s=>s.username).join(", "),iconURL:i&&`https://cdn.discordapp.com/channel-icons/${t}/${i}.png`});await Nt.set(ES(),wr)}async function Ni(){Xo.friends=[],Xo.requests=[];let e=et.getRelationships();for(let t in e)switch(e[t]){case 1:Xo.friends.push(t);break;case 3:Xo.requests.push(t);break}await Nt.set(DS(),Xo)}var xr,wr,Xo,LS,ES,
`,classNames:{},dom:null});Bi="src/plugins/shikiCodeblocks/devicon.css"});var Fi=m(()=>{"use strict";a()});var aI,Co,vm=m(()=>{"use strict";a();D();Ge();fe();Wn();b();_i();gm();ym();Fi();aI=Object.keys(oo),Co=k({theme:{type:4,description:"Default themes",options:aI.map(e=>({label:jn(_l(e)),value:oo[e],default:oo[e]===oo.DarkPlus})),onChange:se.setTheme},customTheme:{type:0,description:"A link to a custom vscode theme",placeholder:oo.MaterialCandy,onChange:e=>{se.setTheme(e||Co.store.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"?Mt(Bi):Je(Bi)}},bgOpacity:{type:5,description:"Background opacity",markers:[0,20,40,60,80,100],default:100,componentProps:{stickToMarkers:!1,onValueRender:null}}},{theme:{disabled(){return!!this.store.customTheme}},customTheme:{isValid(e){if(!e)return!0;let t=vl(e);return t?t.pathname.endsWith(".json")?!0:"Must be a json file":"Must be a valid URL"}}})});function F0(e,t){let n=Co.use(e),[r,i]=I.useState(!1),s={...n,...t},l=s.customTheme||s.theme;if(t){let c=se.currentThemeUrl&&l&&l!==se.currentThemeUrl,u=Object.keys(t).length===0;r&&(!c||u)&&i(!1),!r&&c&&(i(!0),se.setTheme(l))}return{...s,isThemeLoading:l!==se.currentThemeUrl}}var $0=m(()=>{"use strict";a();T();_i();vm()});function U0(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 G0=m(()=>{"use strict";a()});var wn,H0,$i=m(()=>{"use strict";a();Ge();T();Ha();Fi();wn=Ee("shiki-"),H0=({lang:e,tryHljs:t})=>{let n=e?Bo?.getLanguage?.(e):null,i=(e?Qo(e):null)?.name;switch(t){case"ALWAYS":return!0;case"PRIMARY":return!!n||e==="";case"SECONDARY":return!i&&!!n;case"NEVER":return!1;default:return!1}}});function z0(e){let[t,n]=I.useState(!1);function r(i){Kt.copy(i),n(!0),setTimeout(()=>{n(!1)},e)}return[t,r]}var j0=m(()=>{"use strict";a();T()});function W0({content:e,...t}){let[n,r]=z0(1e3);return o("button",{...t,style:{...t.style,cursor:n?"default":void 0},onClick:()=>r(e)},n?"Copied!":"Copy")}var q0=m(()=>{"use strict";a();j0()});function K0({content:e,theme:t}){let n=[];return Kt.SUPPORTS_COPY&&n.push(o(W0,{content:e,className:wn("btn"),style:{backgroundColor:t.accentBgColor,color:t.accentFgColor}})),o("div",{className:wn("btns")},n)}var Y0=m(()=>{"use strict";a();T();$i();q0()});var Z0,X0=m(()=>{"use strict";a();T();$i();Z0=({theme:e,useHljs:t,lang:n,content:r,tokens:i})=>{let s;if(t)try{let{value:c}=Bo.highlight(n,r,!0);s=c.split(`
`.trim().replaceAll("```\n","```")}}}],flux:{async CHANNEL_SELECT({channelId:e}){if(e===Xi&&!_r(F.getCurrentUser().id)&&ho&&rn!==await Nt.get(Bb)){let t=()=>Nt.set(Bb,rn);bt.show({title:"Hold on!",body:o("div",null,o(v.FormText,null,"You are using an outdated version of Vencord! Chances are, your issue is already fixed."),o(v.FormText,null,"Please first update using the Updater Page in Settings, or use the VencordInstaller (Update Vencord Button) to do so, in case you can't access the Updater page.")),onCancel:t,onConfirm:t})}}}})});function zb(e){let t=e.match(/^(\/)?(.+?)(?:\/([gimsuy]*))?$/);return t?new RegExp(t[2],t[3]?.split("").filter((n,r,i)=>i.indexOf(n)===r).join("")??"g"):new RegExp(e)}function QI(e){try{return zb(e),null}catch(t){return o("span",{style:{color:"var(--text-danger)"}},String(t))}}function zm({initialValue:e,onChange:t,placeholder:n}){let[r,i]=V(e);return o(Re,{placeholder:n,value:r,onChange:i,spellCheck:!1,onBlur:()=>r!==e&&t(r)})}function $b({title:e,rulesArray:t,rulesKey:n,update:r}){let i=e==="Using Regex";async function s(c){t.splice(c,1),await Nt.set(n,t),r()}async function l(c,u,h){u===t.length-1&&t.push(Hb()),t[u][h]=c,t[u].find===""&&t[u].replace===""&&t[u].onlyIfIncludes===""&&u!==t.length-1&&t.splice(u,1),await Nt.set(n,t),r()}return o(d,null,o(v.FormTitle,{tag:"h4"},e),o(le,{flexDirection:"column",style:{gap:"0.5em"}},t.map((c,u)=>o(I.Fragment,{key:`${c.find}-${u}`},o(le,{flexDirection:"row",style:{gap:0}},o(le,{flexDirection:"row",style:{flexGrow:1,gap:"0.5em"}},o(zm,{placeholder:"Find",initialValue:c.find,onChange:h=>l(h,u,"find")}),o(zm,{placeholder:"Replace",initialValue:c.replace,onChange:h=>l(h,u,"replace")}),o(zm,{placeholder:"Only if includes",initialValue:c.onlyIfIncludes,onChange:h=>l(h,u,"onlyIfIncludes")})),o(N,{size:N.Sizes.MIN,onClick:()=>s(u),style:{background:"none",...u===t.length-1?{visibility:"hidden",pointerEvents:"none"}:{}}},o("svg",{width:"24",height:"24",viewBox:"0 0 24 24"},o("title",null,"Delete Rule"),o("path",{fill:"var(--status-danger)",d:"M15 3.999V2H9V3.999H3V5.999H21V3.999H15Z"}),o("path",{fill:"var(--status-danger)",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"})))),i&&QI(c.find)))))}function VI(){let[e,t]=V("");return o(d,null,o(v.FormTitle,{tag:"h4"},"Test Rules"),o(Re,{placeholder:"Type a message",onChange:t}),o(Re,{placeholder:"Message with rules applied",editable:!1,value:jb(e)}))}function jb(e){if(e.length===0)return e;if(e=" "+e+" ",Ka)for(let t of Ka)!t.find||!t.replace||t.onlyIfIncludes&&!e.includes(t.onlyIfIncludes)||(e=e.replaceAll(t.find,t.replace.replaceAll("\\n",`
`)));if(Ya){for(let t of Ya)if(!(!t.find||!t.replace)&&!(t.onlyIfIncludes&&!e.includes(t.onlyIfIncludes)))try{let n=zb(t.find);e=e.replace(n,t.replace.replaceAll("\\n",`
`))}catch{new Y("TextReplace").error(`Invalidregex:${t.find}`)}}return e=e.trim(),e}var Ub,Gb,Hb,qa,Ka,Ya,JI,eC,jm,Wb=m(()=>{"use strict";a();ki();Sn();D();wt();w();be();ve();b();T();Ub="TextReplace_rulesString",Gb="TextReplace_rulesRegex",Hb=()=>({find:"",replace:"",onlyIfIncludes:""}),qa=()=>[Hb()],Ka=qa(),Ya=qa(),JI=k({replace:{type:6,description:"",component:()=>{let e=Lt();return o(d,null,o($b,{title:"Using String",rulesArray:Ka,rulesKey:Ub,update:e}),o($b,{title:"Using Regex",rulesArray:Ya,rulesKey:Gb,update:e}),o(VI,null))}}});eC="1102784112584040479",jm=g({name:"TextReplace",description:"Replace text in your messages. You can find pre-made rules in the #textreplace-rules channel in Vencord's Server",authors:[p.AutumnVN,p.TheKodeToad],dependencies:["MessageEventsAPI"],settings:JI,async start(){Ka=await Nt.get(Ub)??qa(),Ya=await Nt.get(Gb)??qa(),this.preSend=lt((e,t)=>{e!==eC&&(t.content=jb(t.content))})},stop(){ct(this.preSend)}})});var Wm,qb=m(()=>{"use strict";a();w();b();Wm=g({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 Kb=m(()=>{});var ht,Hi=m(()=>{"use strict";a();D();b();ht=k({receivedInput:{type:0,description:"Input language for received messages",default:"auto",hidden:!0},receivedOutput:{type:0,description:"Output language for received messages",default:"en",hidden:!0},sentInput:{type:0,description:"Input language for sent messages",default:"auto",hidden:!0},sentOutput:{type:0,description:"Output language for sent messages",default:"en",hidden:!0},autoTranslate:{type:3,description:"Automatically translate your messages before sending. You can also shift/right click the translate button to toggle this",default:!1}})});var Za,qm=m(()=>{"use strict";a();Za={auto:"Detect language",af:"Afrikaans",sq:"Albanian",am:"Amharic",ar:"Arabic",hy:"Armenian",as:"Assamese",ay:"Aymara",az:"Azerbaijani",bm:"Bambara",eu:"Basque",be:"Belarusian",bn:"Bengali",bho:"Bhojpuri",bs:"Bosnian",bg:"Bulgarian",ca:"Catalan",ceb:"Cebuano",ny:"Chichewa","zh-CN":"Chinese (Simplified)","zh-TW":"Chinese (Traditional)",co:"Corsican",hr:"Croatian",cs:"Czech",da:"Danish",dv:"Dhivehi",doi:"Dogri",nl:"Dutch",en:"English",eo:"Esperanto",et:"Estonian",ee:"Ewe",tl:"Filipino",fi:"Finnish",fr:"French",fy:"Frisian",gl:"Galician",ka:"Georgian",de:"German",el:"Greek",gn:"Guarani",gu:"Gujarati",ht:"Haitian Creole",ha:"Hausa",haw:"Hawaiian",iw:"Hebrew",hi:"Hindi",hmn:"Hmong",hu:"Hungarian",is:"Icelandic",ig:"Igbo",ilo:"Ilocano",id:"Indonesian",ga:"Irish",it:"Italian",ja:"Japanese",jw:"Javanese",kn:"Kannada",kk:"Kazakh",km:"Khmer",rw:"Kinyarwanda",gom:"Konkani",ko:"Korean",kri:"Krio",ku:"Kurdish (Kurmanji)",ckb:"Kurdish (Sorani)",ky:"Kyrgyz",lo:"Lao",la:"Latin",lv:"Latvian",ln:"Lingala",lt:"Lithuanian",lg:"Luganda",lb:"Luxembourgish",mk:"Macedonian",mai:"Maithili",mg:"Malagasy",ms:"Malay",ml:"Malayalam",mt:"Maltese",mi:"Maori",mr:"Marathi","mni-Mtei":"Meiteilon (Manipuri)",lus:"Mizo",mn:"Mongolian",my:"Myanmar (Burmese)",ne:"Nepali",no:"Norwegian",or:"Odia (Oriya)",om:"Oromo",ps:"Pashto",fa:"Persian",pl:"Polish",pt:"Portuguese",pa:"Punjabi",qu:"Quechua",ro:"Romanian",ru:"Russian",sm:"Samoan",sa:"Sanskrit",gd:"Scots Gaelic",nso:"Sepedi",sr:"Serbian",st:"Sesotho",sn:"Shona",sd:"Sindhi",si:"Sinhala",sk:"Slovak",sl:"Slovenian",so:"Somali",es:"Spanish",su:"Sundanese",sw:"Swahili",sv:"Swedish",tg:"Tajik",ta:"Tamil",tt:"Tatar",te:"Telugu",th:"Thai",ti:"Tigrinya",ts:"Tsonga",tr:"Turkish",tk:"Turkmen",ak:"Twi",uk:"Ukrainian",ur:"Urdu",ug:"Uyghur",uz:"Uzbek",vi:"Vietnamese",cy:"Welsh",xh:"Xhosa",yi:"Yiddish",yo:"Yoruba",zu:"Zulu"}});async function zi(e,t){let n=ht.store[e+"Input"],r=ht.store[e+"Output"],i="https://translate.googleapis.com/translate_a/single?"+new URLSearchParams({client:"gtx",sl:n,tl:r,dt:"t",dj:"1",source:"input",q:t}),s=await fetch(i);if(!s.ok)throw new Error(`Failedtotranslate"${t}"(
${r}`})},start(){this.preSend=lt((e,t)=>this.unindentMsg(t)),this.preEdit=Jn((e,t,n)=>this.unindentMsg(n))},stop(){ct(this.preSend),Qn(this.preEdit)}})});var of,rT,rf,iT=m(()=>{"use strict";a();Pt();_n();w();b();T();of=1<<2,rT=(e,{channel:t,message:{author:n,embeds:r,flags:i,id:s}})=>()=>{let l=(i&of)!==0;if(!l&&!r.length)return;let c=t.isPrivate()||!!(je.getChannelPermissions({id:t.id})&An.EMBED_LINKS);if(n.id===F.getCurrentUser().id&&!c)return;let u=nt("delete",e),h=u?.findIndex(f=>f?.props?.id==="delete");!h||!u||u.splice(h-1,0,o(L.MenuItem,{id:"unsuppress-embeds",key:"unsuppress-embeds",label:l?"Unsuppress Embeds":"Suppress Embeds",color:l?void 0:"danger",icon:l?Zs:Xs,action:()=>Dt.patch({url:`/channels/${t.id}/messages/${s}`,body:{flags:l?i&~of:i|of}})}))},rf=g({name:"UnsuppressEmbeds",authors:[p.rad,p.HypedDomi],description:"Allows you to unsuppress embeds in messages",start(){pe("message",rT)},stop(){de("message",rT)}})});var sf,sT=m(()=>{"use strict";a();_t();zs();w();b();sf=g({name:"UrbanDictionary",description:"Search for a word on Urban Dictionary via /urban slash command",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 n=encodeURIComponent(e[0].value),{list:[r]}=await(await fetch(`https://api.urbandictionary.com/v0/define?term=${n}`)).json();if(!r)return void oe(t.channel.id,{content:"No results found."});let i=s=>s.replaceAll(`\r
`,`
`).replace(/([*>_`~\\])/gsi,"\\$1").replace(/\[(.+?)\]/g,(l,c)=>`[${c}](https://www.urbandictionary.com/define.php?term=${encodeURIComponent(c)} "Define '${c}' on Urban Dictionary")`).trim();returnvoidoe(t.channel.id,{embeds:[{type:"rich",author:{name:`Uploaded by "${r.author}"`,url:`https://www.urbandictionary.com/author.php?author=${encodeURIComponent(r.author)}`},title:r.word,url:`https://www.urbandictionary.com/define.php?term=${encodeURIComponent(r.word)}`,description:i(r.definition),fields:[{name:"Example",value:i(r.example)},{name:"Want more definitions?",value:`Check out [more definitions](https://www.urbandictionary.com/define.php?term=${n} "Define "${e[0].value}" on Urban Dictionary") on Urban Dictionary.`}],color:16750848,footer:{text:`\u{1F44D} ${r.thumbs_up.toString()} | \u{1F44E} ${r.thumbs_down.toString()}`,icon_url:"https://www.urbandictionary.com/favicon.ico"},timestamp:newDate(r.written_on).toISOString()}]})}catch(n){oe(t.channel.id,{content:`Something went wrong: \`${n}\``})}}}]})});varaT=m(()=>{});varuC,pC,dC,lT,cT=m(()=>{"use strict";a();aT();O();T();uC=P("selectChannel","selectVoiceChannel"),pC=ce(".lastSection",".children"),dC=1n<<20n,lT=({channel:e,label:t,showHeader:n})=>o(pC,null,n&&o(v.FormTitle,{className:"vc-uvs-header"},"In a voice channel"),o(N,{className:"vc-uvs-button",color:N.Colors.TRANSPARENT,size:N.Sizes.SMALL,onClick:()=>{je.can(dC,e)?uC.selectVoiceChannel(e.id):X.show({message:"Insufficient permissions to enter the channel.",id:"user-voice-show-insufficient-permissions",type:X.Type.FAILURE,options:{position:X.Position.BOTTOM}})}},t))});varmC,fC,af,uT,lf,pT=m(()=>{"use strict";a();D();ie();w();b();O();T();cT();mC=ae("VoiceStateStore"),fC=P("section","lastSection"),af=k({showInUserProfileModal:{type:3,description:"Show a user's voice channel in their profile modal",default:!0},showVoiceChannelSectionHeader:{type:3,description:'Whether to show "IN A VOICE CHANNEL" above the join button',default:!0}}),uT=A.wrap(({user:e})=>{let{channelId:t}=mC.getVoiceStateForUser(e.id)??{};if(!t)returnnull;letn=Z.getChannel(t),r=ue.getGuild(n.guild_id);if(!r)returnnull;leti=`${r.name} | ${n.name}`;returno(lT,{channel:n,label:i,showHeader:af.store.showVoiceChannelSectionHeader})}),lf=g({name:"UserVoiceShow",description:"Shows whether a User is currently in a voice channel somewhere in their profile",authors:[p.LordElias],settings:af,patchModal({user:e}){returnaf.store.showInUserProfileModal?o("div",{className:"vc-uvs-modal-margin"},o(uT,{user:e})):null},patchPopout:({user:e})=>{lett=e.id===F.getCurrentUser().id;returno("div",{className:t?`vc-uvs-popout-margin ${fC.lastSection}`:""},o(uT,{user:e}))},patches:[{find:".showCopiableUsername",replacement:{match:/\(0,\w\.jsx\)\(\w{2},{user:\w,setNote/,replace:"$self.patchPopout(arguments[0]),$&"}},{find:".USER_PROFILE_MODAL",replacement:{match:/\(\)\.body.+?displayProfile:\i}\),/,replace:"$&$self.patchModal(arguments[0]),"}}]})});vardT,mT=m(()=>{a();(window.VencordStyles??=newMap).set("src/plugins/usrbg/index.css",{name:"src/plugins/usrbg/index.css",source:`:is([class*="userProfile"], [class*="userPopout"]) [class*="bannerPremium"] {
`,classNames:{},dom:null});dT="src/plugins/usrbg/index.css"});var gC,Vo,Qa,cf,fT=m(()=>{"use strict";a();D();Ge();bo();w();b();mT();gC="https://raw.githubusercontent.com/AutumnVN/usrbg/main/usrbg.json",Vo={},Qa=k({nitroFirst:{description:"Banner to use if both Nitro and USRBG banners are present",type:4,options:[{label:"Nitro banner",value:!0,default:!0},{label:"USRBG banner",value:!1}]},voiceBackground:{description:"Use USRBG banners as voice chat backgrounds",type:3,default:!0,restartNeeded:!0}}),cf=g({name:"USRBG",description:"Displays user banners from USRBG, allowing anyone to get a banner without Nitro",authors:[p.AutumnVN,p.pylix,p.TheKodeToad],settings:Qa,patches:[{find:".NITRO_BANNER,",replacement:[{match:/(\i)\.premiumType/,replace:"$self.premiumHook($1)||$&"},{match:/(\i)\.bannerSrc,/,replace:"$self.useBannerHook($1),"},{match:/\?\(0,\i\.jsx\)\(\i,{type:\i,shown/,replace:"&&$self.shouldShowBadge(arguments[0])$&"}]},{find:'"data-selenium-video-tile":',predicate:()=>Qa.store.voiceBackground,replacement:[{match:/(\i)\.style,/,replace:"$self.voiceBackgroundHook($1),"}]}],settingsAboutComponent:()=>o(at,{href:"https://github.com/AutumnVN/usrbg#how-to-request-your-own-usrbg-banner"},"CLICK HERE TO GET YOUR OWN BANNER"),voiceBackgroundHook({className:e,participantUserId:t}){if(e.includes("tile-")&&Vo[t])return{backgroundImage:`url(${Vo[t]})`,backgroundSize:"cover",backgroundPosition:"center",backgroundRepeat:"no-repeat"}},useBannerHook({displayProfile:e,user:t}){if(!(e?.banner&&Qa.store.nitroFirst)&&Vo[t.id])return Vo[t.id]},premiumHook({userId:e}){if(Vo[e])return 2},shouldShowBadge({displayProfile:e,user:t}){return e?.banner&&(!Vo[t.id]||Qa.store.nitroFirst)},async start(){Je(dT);let e=await fetch(gC);e.ok&&(Vo=await e.json())}})});function vC(e){let t=Math.floor(Math.random()*e.length);return e[t]}function hT(e){e=e.toLowerCase();for(let t of yC)e=e.replaceAll(t[0],t[1]);return e=e.replaceAll(/([ \t\n])n/g,"$1ny").replaceAll(/[lr]/g,"w").replaceAll(/([ \t\n])([a-z])/g,(t,n,r)=>Math.random()<.5?`${n}${r}-${r}`:`${n}${r}`).replaceAll(/([^.,!][.,!])([ \t\n])/g,(t,n,r)=>`${n}${vC(hC)}${r}`),e}var hC,yC,gT,uf,yT=m(()=>{"use strict";a();_t();Sn();D();w();b();hC=["rawr x3","OwO","UwU","o.O","-.-",">w<","(\u2445\u02D8\uA4B3\u02D8)","(\uA20D\u1D17\uA20D)","(\u02D8\u03C9\u02D8)","(U \u1D55 U\u2741)","\u03C3\u03C9\u03C3","\xF2\u03C9\xF3","(///\u02EC///\u273F)","(U \uFE4F U)","( \u0361o \u03C9 \u0361o )","\u0298w\u0298",":3",":3","XD","nyaa~~","mya",">_<","\u{1F633}","\u{1F97A}","\u{1F633}\u{1F633}\u{1F633}","rawr","^^","^^;;","(\u02C6 \uFECC \u02C6)\u2661","^\u2022\uFECC\u2022^","/(^\u2022\u03C9\u2022^)","(\u273Fo\u03C9o)"],yC=[["small","smol"],["cute","kawaii~"],["fluff","floof"],["love","luv"],["stupid","baka"],["what","nani"],["meow","nya~"],["hello","hewwo"]],gT=k({uwuEveryMessage:{description:"Make every single message uwuified",type:3,default:!1,restartNeeded:!1}});uf=g({name:"UwUifier",description:"Simply uwuify commands",authors:[p.echo,p.skyevg,p.PandaNinjas],dependencies:["CommandsAPI","MessageEventsAPI"],settings:gT,commands:[{name:"uwuify",description:"uwuifies your messages",options:[Ho],execute:e=>({content:hT(Oe(e,"message",""))})}],onSend(e){gT.store.uwuEveryMessage&&(e.content=hT(e.content))},start(){this.preSend=lt((e,t)=>this.onSend(t)),this.preEdit=Jn((e,t,n)=>this.onSend(n))},stop(){ct(this.preSend),Qn(this.preEdit)}})});function bC({data:e,UserMention:t,RoleMention:n,parse:r,props:i}){let[s,l]=V(e.userId);if(s)return o(t,{className:"mention",userId:s,channelId:e.channelId,inlinePreview:i.noStyleAndInteraction,key:i.key});let c=r(e.content,i);return o(n,{...e,inlinePreview:i.formatInline},o("span",{onMouseEnter:()=>{let u=c?.[0]?.props?.children;if(typeof u!="string")return;let h=u.match(/<@!?(\d+)>/)?.[1];if(!h||Va.has(h))return;if(F.getUser(h))return l(h);let f=()=>{Va.add(h),vT.unshift(()=>SC(h).then(()=>{l(h),Va.delete(h)}).catch(y=>{y?.status===429&&(vT.unshift(()=>so(1e3).then(f)),Va.delete(h))}).finally(()=>so(300)))};f()}},c))}var Va,vT,SC,pf,ST=m(()=>{"use strict";a();ie();w();fe();ar();b();O()
`);qi.textContent=t}var Ro,qi,Rf=m(()=>{"use strict";a();D();document.addEventListener("DOMContentLoaded",()=>{Nf(M.useQuickCss),Bs("useQuickCss",Nf),FT(),Bs("themeLinks",FT)})});var Af={};ge(Af,{Common:()=>Cl,_initWebpack:()=>ns,_resolveReady:()=>ts,addListener:()=>ix,cache:()=>Un,extract:()=>yl,filters:()=>K,find:()=>Ht,findAll:()=>or,findBulk:()=>Or,findByCode:()=>ze,findByCodeLazy:()=>ce,findByProps:()=>Nn,findByPropsLazy:()=>P,findLazy:()=>ke,findModuleId:()=>os,findStore:()=>rx,findStoreLazy:()=>ae,listeners:()=>gl,mapMangledModule:()=>Hf,mapMangledModuleLazy:()=>Ke,onceReady:()=>fl,removeListener:()=>sx,search:()=>hl,subscriptions:()=>Gf,waitFor:()=>Ye,wreq:()=>Gt});var il=m(()=>{"use strict";a();T();O()});function UT(){function e(t){try{let n=t[1],{subscriptions:r,listeners:i}=Vencord.Webpack,{patches:s}=Vencord.Plugins;for(let l in n){let c=n[l],u=c.toString().replaceAll(`
`,"");u.startsWith("function(")&&(u="0,"+u);let h=c,f=new Set,y=n[l]=function(S,x,R){try{c(S,x,R)}catch(_){if(c===h)throw _;return Ao.error("Error in patched chunk",_),void h(S,x,R)}if(S.exports===window){Object.defineProperty(R.c,l,{value:R.c[l],enumerable:!1,configurable:!0,writable:!0});return}let C=Number(l);for(let _ of i)try{_(x,C)}catch($){Ao.error("Error in webpack listener",$)}for(let[_,$]of r)try{if(_(x))r.delete(_),$(x,C);else if(typeof x=="object"){x.default&&_(x.default)&&(r.delete(_),$(x.default,C));for(let B in x)B.length<=3&&x[B]&&_(x[B])&&(r.delete(_),$(x[B],C))}}catch(B){Ao.error("Error while firing callback for webpack chunk",B)}};try{y.toString=()=>c.toString(),y.original=h}catch{}for(let S=0;S<s.length;S++){let x=s[S],R=an(`patchby${x.plugin}`,(C,_)=>u.replace(C,_));if(!(x.predicate&&!x.predicate())&&u.includes(x.find)){f.add(x.plugin);for(let C of x.replacement){if(C.predicate&&!C.predicate())continue;let _=c,$=u;jr(C,x.plugin);try{let B=R(C.match,C.replace);B===u&&!x.noWarn?Ao.warn(`Patchby${x.plugin}hadnoeffect(Moduleidis${l}):${C.match}`):(u=B,c=(0,eval)(`// Webpack Module ${l} - Patched by ${[...f].join(", ")}
${B}
//# sourceURL=WebpackModule${l}`))}catch(B){Ao.error(`Patch by ${x.plugin} errored (Module id is ${l}): ${C.match}
`,B),u=$,c=_,f.delete(x.plugin)}}x.all||s.splice(S--,1)}}}}catch(n){Ao.error("Error in handlePush",n)}return e.original.call(window[qt],t)}e.original=window[qt].push,Object.defineProperty(window[qt],"push",{get:()=>e,set:t=>e.original=t,configurable:!0})}var $T,Ao,GT=m(()=>{"use strict";a();w();be();Wr();es();il();Ao=new Y("WebpackInterceptor","#8caaee");window[qt]?(Ao.info(`Patching${qt}.push(wasalreadyexistant,likelyfromcache!)`),ns(window[qt]),UT()):Object.defineProperty(window,qt,{get:()=>$T,set:e=>{e?.push!==Array.prototype.push&&(Ao.info(`Patching${qt}.push`),ns(e),UT(),delete window[qt],window[qt]=e),$T=e},configurable:!0})});async function nN(){M.cloud.settingsSync&&M.cloud.authenticated&&($o.Vencord_settingsDirty?(await ur(),delete $o.Vencord_settingsDirty):await Os(!1)&&he({title:"Cloud Settings",body:"Your settings have been updated! Click here to restart to fully apply changes!",color:"var(--green-360)",onClick:Fs}))}async function oN(){if(await fl,qc(),nN(),!1)try{}catch(e){}}var Lm=m(()=>{"use strict";a();ki();qs();Fl();Rf();dr();il();Rf();GT();uo();D();qs();bs();ri();oi();dr();il();T();oN()});var rN={};ge(rN,{Api:()=>Cf,PlainSettings:()=>En,Plugins:()=>Yc,QuickCss:()=>kf,Settings:()=>M,Updater:()=>Ic,Util:()=>Bl,Webpack:()=>Af});a();a();a();var Bf=`<!DOCTYPEhtml>
`;Cn();Fl();tt();var{localStorage:lg}=window,cg=new Set;var Nx=async()=>{},kx=At(e=>VencordNative.quickCss.set(e));window.VencordNative={native:{getVersions:()=>({}),openExternal:async e=>void open(e,"_blank")},updater:{getRepo:async()=>({ok:!0,value:"https://github.com/Vendicated/Vencord"}),getUpdates:async()=>({ok:!0,value:[]}),update:async()=>({ok:!0,value:!1}),rebuild:async()=>({ok:!0,value:!0})},quickCss:{get:()=>Qe("VencordQuickCss").then(e=>e??""),set:async e=>{await Ve("VencordQuickCss",e),cg.forEach(t=>t(e))},addChangeListener(e){cg.add(e)},openFile:Nx,async openEditor(){let e=`popup,width=${Math.min(window.innerWidth,1e3)},height=${Math.min(window.innerHeight,1e3)}`,t=open("about:blank","VencordQuickCss",e);if(!t){alert("Failed to open QuickCSS popup. Make sure to allow popups!");return}t.setCss=kx,t.getCurrentCss=()=>VencordNative.quickCss.get(),t.getTheme=()=>zr()===2?"vs-light":"vs-dark",t.document.write(Bf)}},settings:{get:()=>lg.getItem("VencordSettings")||"{}",set:async e=>lg.setItem("VencordSettings",e),getSettingsDir:async()=>"LocalStorage"}};Lm();return Lo(rN);})();