vd-plugins/Commands/index.js
2025-09-30 17:04:23 +00:00

8 lines
23 KiB
JavaScript

(function(B,se,s,f,L,h,N,o,oe,re,ie){"use strict";const ce=async function(){const e=await(await fetch("https://uselessfacts.jsph.pl/api/v2/facts/random")).json();return{text:e.text,source:e.source,language:e.language}},le=async function(){return{text:(await(await fetch("https://dogapi.dog/api/v2/facts?limit=1")).json()).data[0].attributes.body}},de=async function(){const e=await(await fetch("https://catfact.ninja/fact")).json();return{text:e.fact,length:e.length}},ue=async function(e){return await(await fetch(`https://api.obamabot.me/v2/image/petpet?image=${e.replace("webp","png")}`)).json()},P=f.findByProps("sendMessage"),U=function(e){let a=e.text;return s.storage.factSettings?.includeCitation&&e.source&&(a+=`
Source: ${e.source}`),a},pe={name:"catfact",displayName:"catfact",description:"Sends a random cat fact.",displayDescription:"Sends a random cat fact.",applicationId:"-1",inputType:1,type:1,execute:async function(e,a){try{const t=await de(),n=Date.now().toString();return P.sendMessage(a.channel.id,{content:U(t)},void 0,{nonce:n}),{type:4}}catch(t){return console.error("[CatFact] Error:",t),{type:4}}}},fe={name:"dogfact",displayName:"dogfact",description:"Sends a dog fact.",displayDescription:"Sends a dog fact.",applicationId:"-1",inputType:1,type:1,execute:async function(e,a){try{const t=await le(),n=Date.now().toString();return P.sendMessage(a.channel.id,{content:U(t)},void 0,{nonce:n}),{type:4}}catch(t){return console.error("[DogFact] Error:",t),{type:4}}}},ye={name:"useless",displayName:"useless",description:"Sends a useless fact.",displayDescription:"Sends a useless fact.",applicationId:"-1",inputType:1,type:1,execute:async function(e,a){try{const t=await ce(),n=Date.now().toString();return P.sendMessage(a.channel.id,{content:U(t)},void 0,{nonce:n}),{type:4}}catch(t){return console.error("[UselessFact] Error:",t),{type:4}}}},w={CONTENT:"This list is over 2000 characters. Send anyway?",CONFIRM:"Send",CANCEL:"Cancel"},me={DETAILED:"detailed"},_="",D={SLM_NOT_INSTALLED:"This list is over 2000 characters. Install the Split Large Messages plugin to send it.",SLM_NOT_ENABLED:"This list is over 2000 characters. Enable the Split Large Messages plugin to send it."},x={SEMICOL:"; ",NEW_LINE:`
`},ge="Nothing to see here, huh...",j="github.com/fres621/vendetta-plugins",b={ENABLED:"\u2705",DISABLED:"\u274C",SELECTED:"\u2705",NOT_SELECTED:"\u274C"},he=f.findByProps("sendMessage","receiveMessage"),S=f.findByProps("sendBotMessage"),F=function(){try{return f.findByStoreName("UserStore").getCurrentUser()?.premiumType===2?4e3:2e3}catch{return 2e3}}(),V=function(e){return Object.keys(e).includes(j)},K=function(e){return Object.values(e).find(function(a){return a.id==j})?.enabled},W=function(e){return e.find(function(a){return a.name===me.DETAILED})?.value??!1},$=function(e){return!e||!Array.isArray(e)||e.length===0?"Unknown":e.filter(function(a){return a&&(typeof a=="string"||typeof a=="object"&&a.name)}).map(function(a){return typeof a=="string"?a:a.name||"Unknown"}).join(x.SEMICOL)||"Unknown"},q=function(e){return e.join(x.NEW_LINE).trimEnd()},A=function(e){return q(e).length},k=async function(e,a){const t=Date.now().toString();await he.sendMessage(e,{content:q(a)},void 0,{nonce:t})},G=function(e,a){return[`**My ${e} List | ${a} ${e}s**`,_]};async function be(e,a){try{const t=W(e),n=s.storage.themeListAlwaysDetailed??!1;if(!L.themes||typeof L.themes!="object"){const p=a.channel.id;return S.sendBotMessage(p,"No themes found or themes not loaded yet."),{type:4}}const r=Object.values(L.themes),c=a.channel.id,i=G("Theme",Object.keys(L.themes).length);if(r.length)for(const p of r){if(!p||typeof p!="object")continue;const{selected:l,data:d,id:m}=p,E=d?.name||"Unknown Theme",v=d?.description||"No description",M=d?.authors;t||n?i.push(`> **Name**: ${E}`,`> **Selected**: ${l?b.SELECTED:b.NOT_SELECTED}`,`> **Description**: ${v}`,`> **Authors**: ${$(M)}`,`> **[Install!](${m||"unknown"})**`,_):i.push(`> ${l?b.SELECTED:b.NOT_SELECTED} **${E}** by ${$(M)}`)}else i.push(ge);const u=A(i)>F;if(u&&!V(h.plugins))S.sendBotMessage(c,D.SLM_NOT_INSTALLED);else if(u&&!K(h.plugins))S.sendBotMessage(c,D.SLM_NOT_ENABLED);else{if(A(i)>2e3)return N.alerts.showConfirmationAlert({content:w.CONTENT,confirmText:w.CONFIRM,cancelText:w.CANCEL,onConfirm:async function(){return await k(c,i)}});await k(c,i)}}catch(t){return console.error("[ThemeList] Error:",t),{type:4}}}async function Ce(e,a){try{const t=W(e),n=s.storage.pluginListAlwaysDetailed??!1,r=a.channel.id;if(!h.plugins||typeof h.plugins!="object")return S.sendBotMessage(r,"No plugins found or plugins not loaded yet."),{type:4};const c=G("Plugin",Object.keys(h.plugins).length);for(const u of Object.values(h.plugins)){if(!u||typeof u!="object")continue;const{enabled:p,manifest:l,id:d}=u,m=l?.name||"Unknown Plugin",E=l?.description||"No description",v=l?.authors;t||n?c.push(`> **Name**: ${m}`,`> **Status**: ${p?b.ENABLED:b.DISABLED}`,`> **Description**: ${E}`,`> **Authors**: ${$(v)}`,`> **[Install!](${d||"unknown"})**`,_):c.push(`> ${p?b.ENABLED:b.DISABLED} **${m}** by ${$(v)}`)}const i=A(c)>F;if(i&&!V(h.plugins))S.sendBotMessage(r,D.SLM_NOT_INSTALLED);else if(i&&!K(h.plugins))S.sendBotMessage(r,D.SLM_NOT_ENABLED);else{if(A(c)>2e3)return N.alerts.showConfirmationAlert({content:w.CONTENT,confirmText:w.CONFIRM,cancelText:w.CANCEL,onConfirm:async function(){return await k(r,c)}});await k(r,c)}}catch(t){return console.error("[PluginList] Error:",t),{type:4}}}const we={name:"plugin-list",displayName:"plugin list",description:"Send your plugin list to the current channel",displayDescription:"Send your plugin list to the current channel",options:[{name:"detailed",description:"Whether to send a list with detailed information.",type:5,required:!1,displayName:"detailed",displayDescription:"Whether to send a list with detailed information."}],execute:Ce,applicationId:"-1",inputType:1,type:1},Se={name:"theme-list",displayName:"theme list",description:"Send your theme list to the current channel",displayDescription:"Send your theme list to the current channel",options:[{name:"detailed",description:"Whether to send a list with detailed information.",type:5,required:!1,displayName:"detailed",displayDescription:"Whether to send a list with detailed information."}],execute:be,applicationId:"-1",inputType:1,type:1},Ee=f.findByStoreName("UserStore"),ve=f.findByProps("sendMessage"),Le={name:"petpet",displayName:"petpet",description:"PetPet someone",displayDescription:"PetPet someone",options:[{name:"user",description:"The user(or their id) to be patted",type:6,required:!0,displayName:"user",displayDescription:"The user(or their id) to be patted"}],execute:async function(e,a){try{const t=(await Ee.getUser(e[0].value)).getAvatarURL(512),n=await ue(t),r=Date.now().toString();return ve.sendMessage(a.channel.id,{content:n.url},void 0,{nonce:r}),{type:4}}catch(t){return console.error("[PetPet] Error:",t),{type:4}}},applicationId:"-1",inputType:1,type:1},Ne=f.findByProps("sendMessage"),De=f.findByProps("sendBotMessage","sendMessage","receiveMessage"),H=async function(e){const a="https://konachan.com/post.json",t=e?"rating:explicit":"rating:safe",n=Math.floor(Math.random()*100);try{const r=await(await fetch(`${a}?tags=${t}&limit=1&page=${n}`)).json();return!Array.isArray(r)||r.length===0?null:r[0].file_url}catch(r){return console.error("[KonoChan Randomizer] Error fetching image:",r),null}},Y=function(){return N.alerts.showConfirmationAlert({title:"NSFW Content Warning",content:"NSFW content can only be sent in NSFW channels!",confirmText:"Okay",cancelText:null,confirmColor:"brand",isDismissable:!0})},z={name:"nsfw",description:"Include NSFW content?",type:5,required:!1,displayName:"nsfw",displayDescription:"Include NSFW content?"},$e={name:"konoself",displayName:"konoself",description:"Fetch a random image from KonoChan for yourself.",displayDescription:"Fetch a random image from KonoChan for yourself.",options:[z],execute:async function(e,a){try{const t=new Map(e.map(function(r){return[r.name,r]})).get("nsfw")?.value||!1;if(t&&!a.channel.nsfw)return Y(),{type:4};const n=await H(t);return n?(De.sendBotMessage(a.channel.id,`Here's your random image: ${n}`),{type:4}):{type:4}}catch(t){return console.error("[KonoSelf] Error:",t),{type:4}}},applicationId:"-1",inputType:1,type:1},Ae={name:"konosend",displayName:"konosend",description:"Fetch a random image from KonoChan and send it to the channel.",displayDescription:"Fetch a random image from KonoChan and send it to the channel.",options:[z],execute:async function(e,a){try{const t=new Map(e.map(function(c){return[c.name,c]})).get("nsfw")?.value||!1;if(t&&!a.channel.nsfw)return Y(),{type:4};const n=await H(t);if(!n)return{type:4};const r=Date.now().toString();return Ne.sendMessage(a.channel.id,{content:n},void 0,{nonce:r}),{type:4}}catch(t){return console.error("[KonoSend] Error:",t),{type:4}}},applicationId:"-1",inputType:1,type:1},X=f.findByProps("getAPIBaseURL","get"),ke=f.findByProps("sendMessage"),T=async function(e,a,t){const n=a?`&author_id=${a}`:"",r=t?`&channel_id=${t}`:"",c=a?"":"&min_id=0";return(await X.get({url:`/guilds/${e}/messages/search`,query:`include_nsfw=true${n}${r}${c}&sort_by=timestamp&sort_order=asc&offset=0`})).body.messages[0][0]},J=async function(e,a){const t=a?`&author_id=${a}`:"",n=a?"":"&min_id=0";return(await X.get({url:`/channels/${e}/messages/search`,query:`&sort_by=timestamp&sort_order=asc&offset=0${t}${n}`})).body.messages[0][0]},Te={name:"firstmessage",displayName:"firstmessage",description:"Tired of scrolling to first message?",displayDescription:"Tired of scrolling to first message?",options:[{name:"user",displayName:"user",description:"Target user to get their first message in this server/dm",displayDescription:"Target user to get their first message in this server/dm",type:6,required:!1},{name:"channel",displayName:"channel",description:"Target channel to get first message of",displayDescription:"Target channel to get first message of",type:7,required:!1},{name:"send",displayName:"send",description:"Whether to send the resulting url",displayDescription:"Whether to send the resulting url",type:5,required:!1}],execute:async function(e,a){try{const t=new Map(e.map(function(m){return[m.name,m]})),n=t.get("user")?.value,r=t.get("channel")?.value,c=t.get("send")?.value,i=a.guild?.id,u=a.channel.id,p=a.channel.type===1;let l="https://discord.com/channels/",d;if(!n&&!r)p?(d=await J(u),l+=`@me/${u}/${d.id}`):(d=await T(i),l+=`${i}/${d.channel_id}/${d.id}`);else if(n)p?(d=await J(u,n),l+=`@me/${u}/${d.id}`):(d=await T(i,n),l+=`${i}/${d.channel_id}/${d.id}`);else if(r){if(p)return{type:4};d=await T(i,null,r),l+=`${i}/${r}/${d.id}`}else{if(p)return{type:4};d=await T(i,n,r),l+=`${i}/${r}/${d.id}`}if(c){const m=Date.now().toString();return ke.sendMessage(a.channel.id,{content:l},void 0,{nonce:m}),{type:4}}else return o.url.openDeeplink(l),{type:4}}catch(t){return console.error("[FirstMessage] Error:",t),{type:4}}},applicationId:"-1",inputType:1,type:1},Re=f.findByProps("sendMessage"),Me=f.findByProps("sendBotMessage","sendMessage","receiveMessage");function Ie(){let{height:e,width:a,scale:t}=o.ReactNative.Dimensions.get("screen");return e*=t,a*=t,{width:a,height:e}}function Be(){try{const e=f.findByProps("memory");if(!e)return{cpuCoreCount:"N/A",cpuPerc:"N/A",memUsage:"N/A",netInfo:"N/A"};const{cpuCoreCount:a,cpuPercentage:t,memory:n}=e,r=t?t.toFixed(2)+"%":"N/A",c=n?parseFloat((n/1e3).toPrecision(3))+" MB":"N/A";let i="N/A";try{const u=f.findByProps("useNetInfo");if(u){const p=Object.values(u.fetch()).filter(function(l){return l?.type})[0];if(p){const{type:l,details:d}=p;i={wifi:"WiFi",ethernet:"Ethernet",other:"Unknown",bluetooth:"Bluetooth",wimax:"WiMAX",vpn:"VPN",cellular:d?.cellularGeneration?.toUpperCase()||"Cellular"}[l]??l}}}catch(u){console.warn("Network info unavailable:",u)}return{cpuCoreCount:a,cpuPerc:r,memUsage:c,netInfo:i}}catch(e){return console.warn("Hardware info unavailable:",e),{cpuCoreCount:"N/A",cpuPerc:"N/A",memUsage:"N/A",netInfo:"N/A"}}}function Pe(){try{const{NativeModules:e}=o.ReactNative;return(e.InfoDictionaryManager??e.RTNClientInfoManager)||{}}catch(e){return console.warn("Discord info unavailable:",e),{}}}function Ue(){try{const{cpuCoreCount:e,cpuPerc:a,memUsage:t,netInfo:n}=Be(),r=Pe(),{vendetta:c,discord:i,react:u,hermes:p,os:l,device:d}=oe.getDebugInfo(),{version:m,bytecodeVersion:E}=p||{},{version:v,nativeVersion:M}=u||{},{name:ee,version:Ze,sdk:te}=l||{},{manufacturer:et,brand:ne,model:ae,codename:tt}=d||{},{version:nt}=c||{},{version:at,build:st}=i||{},{ReleaseChannel:ot}=r,rt=ee=="iOS"?tt:`${ne} ${ae}`,{width:it,height:ct}=Ie();let I={Device:{Device:rt||"Unknown",Model:ae||"Unknown",Manufacturer:et||"Unknown",Brand:ne||"Unknown",Display:`${it}x${ct}`},Hardware:{"CPU Cores":e||"N/A",Network:n},Software:{OS:ee||"Unknown",Version:Ze||"Unknown"},Discord:{Branch:ot||"Unknown",Version:at||"Unknown",Build:st||"Unknown",Vendetta:nt||"Unknown","CPU Usage":a,"Memory Usage":t},React:{Version:v||"Unknown","Hermes Bytecode":E||"Unknown",Hermes:m||"Unknown",Native:M||"Unknown"}};return window.enmity&&(I.Discord.Enmity=window.enmity.version),window.aliucord&&(I.Discord.Aliucord=window.aliucord.version),te&&(I.Software["SDK Version"]=te),I}catch(e){throw console.error("Error generating system info:",e),e}}const Q=["device","hardware","software","discord","react","ephemeral"];for(const e of Q)s.storage[e]===void 0&&(s.storage[e]=!0);function _e(e,a){try{let t=[`__System Information__
`];const n=Ue();Object.keys(n).forEach(function(i){const u=s.storage[i.toLowerCase()],p=e.find(function(l){return l.name==i.toLowerCase()})?.value??u;(p||u)&&!(u&&!p)&&(t.push(`[**${i}**]`),Object.keys(n[i]).forEach(function(l){t.push(`> ${l}: ${n[i][l]}`)}))});const r=s.storage.ephemeral,c=e.find(function(i){return i.name=="ephemeral"})?.value??r;if((c||r)&&!(r&&!c))return Me.sendBotMessage(a.channel.id,t.join(`
`)),{type:4};{const i=Date.now().toString();return Re.sendMessage(a.channel.id,{content:t.join(`
`)},void 0,{nonce:i}),{type:4}}}catch(t){return console.error("[Sysinfo] Error:",t),{type:4}}}const Oe={name:"sysinfo",displayName:"sysinfo",description:"Display system information",displayDescription:"Display system information",options:[{name:"ephemeral",displayName:"ephemeral",description:"Keep sysinfo ephemeral (default: true)",displayDescription:"Keep sysinfo ephemeral (default: true)",type:5,required:!1},...Q.slice(0,-1).map(function(e){return{name:e,displayName:e,description:`Display the ${e} section. Set default in settings.`,displayDescription:`Display the ${e} section. Set default in settings.`,type:5,required:!1}})],execute:_e,applicationId:"-1",inputType:1,type:1},Z=f.findByProps("sendMessage","receiveMessage"),xe=f.findByStoreName("SpotifyStore");async function je(e,a){return s.storage.enabledCommands?.spotifyTrack?R(a,function(t){return`https://open.spotify.com/track/${t.id}`}):{type:4}}async function Fe(e,a){return s.storage.enabledCommands?.spotifyAlbum?R(a,function(t){return`https://open.spotify.com/album/${t.album.id}`}):{type:4}}async function Ve(e,a){return s.storage.enabledCommands?.spotifyArtists?R(a,function(t){return t.artists.map(function(n){return`[${n.name}](${n.external_urls.spotify})`}).join(`
`)}):{type:4}}async function Ke(e,a){return s.storage.enabledCommands?.spotifyCover?R(a,function(t){return t.album.image.url}):{type:4}}async function R(e,a){try{const t=e.channel.id,n=xe?.getTrack?.();if(!n){const i=Date.now().toString();return Z.sendMessage(t,{content:"You are not listening to any track."},void 0,{nonce:i}),{type:4}}const r=a(n),c=Date.now().toString();return Z.sendMessage(t,{content:r},void 0,{nonce:c}),{type:4}}catch(t){return console.error("[Spotify Command] Error:",t),{type:4}}}const We={name:"spotify track",displayName:"spotify track",description:"Sends your current Spotify track",displayDescription:"Sends your current Spotify track",applicationId:"-1",inputType:1,type:1,execute:je},qe={name:"spotify album",displayName:"spotify album",description:"Sends your current track's album",displayDescription:"Sends your current track's album",applicationId:"-1",inputType:1,type:1,execute:Fe},Ge={name:"spotify artists",displayName:"spotify artists",description:"Sends your current track's artists",displayDescription:"Sends your current track's artists",applicationId:"-1",inputType:1,type:1,execute:Ve},He={name:"spotify cover",displayName:"spotify cover",description:"Sends your current track's cover",displayDescription:"Sends your current track's cover",applicationId:"-1",inputType:1,type:1,execute:Ke},{ScrollView:Ye}=f.findByProps("ScrollView"),{TableRowGroup:g,TableSwitchRow:y,Stack:ze,TableRow:C}=f.findByProps("TableSwitchRow","TableRowGroup","Stack","TableRow");s.storage.factSettings||(s.storage.factSettings={sendAsReply:!0,includeCitation:!1}),s.storage.listSettings||(s.storage.listSettings={pluginListAlwaysDetailed:!1,themeListAlwaysDetailed:!1}),s.storage.enabledCommands||(s.storage.enabledCommands={catfact:!0,dogfact:!0,useless:!0,petpet:!0,pluginList:!0,themeList:!0,konoself:!0,konosend:!0,firstmessage:!0,sysinfo:!0,spotifyTrack:!0,spotifyAlbum:!0,spotifyArtists:!0,spotifyCover:!0}),s.storage.pendingRestart||(s.storage.pendingRestart=!1);function Xe(){re.useProxy(s.storage);const[e,a]=o.React.useReducer(function(n){return n+1},0);o.React.useEffect(function(){return function(){s.storage.pendingRestart&&(s.storage.pendingRestart=!1,N.alerts.showConfirmationAlert({title:"Restart Required",content:"You have made changes to commands. Please restart Discord to apply these changes.",confirmText:"Okay",cancelText:null}))}},[]);const t=function(n,r){s.storage.enabledCommands[n]=r,s.storage.pendingRestart=!0,a()};return o.React.createElement(ie.View,{style:{flex:1}},o.React.createElement(Ye,{style:{flex:1},contentContainerStyle:{paddingBottom:38}},o.React.createElement(ze,{spacing:8},o.React.createElement(g,{title:"Facts Commands"},o.React.createElement(y,{label:"Send as Reply",subLabel:"Send facts as a reply to the command message",value:s.storage.factSettings?.sendAsReply??!0,onValueChange:function(n){s.storage.factSettings.sendAsReply=n,a()}}),o.React.createElement(y,{label:"Include Source Citation",subLabel:"Include the source of facts when available",value:s.storage.factSettings?.includeCitation??!1,onValueChange:function(n){s.storage.factSettings.includeCitation=n,a()}}),o.React.createElement(y,{label:"/catfact",subLabel:"Get random cat facts",value:s.storage.enabledCommands?.catfact??!0,onValueChange:function(n){return t("catfact",n)}}),o.React.createElement(y,{label:"/dogfact",subLabel:"Get random dog facts",value:s.storage.enabledCommands?.dogfact??!0,onValueChange:function(n){return t("dogfact",n)}}),o.React.createElement(y,{label:"/useless",subLabel:"Get random useless facts",value:s.storage.enabledCommands?.useless??!0,onValueChange:function(n){return t("useless",n)}})),o.React.createElement(g,{title:"List Commands"},o.React.createElement(y,{label:"Always Send Detailed Plugin List",subLabel:"Always use detailed mode when listing plugins",value:s.storage.listSettings?.pluginListAlwaysDetailed??!1,onValueChange:function(n){s.storage.listSettings.pluginListAlwaysDetailed=n,a()}}),o.React.createElement(y,{label:"Always Send Detailed Theme List",subLabel:"Always use detailed mode when listing themes",value:s.storage.listSettings?.themeListAlwaysDetailed??!1,onValueChange:function(n){s.storage.listSettings.themeListAlwaysDetailed=n,a()}}),o.React.createElement(y,{label:"/plugin-list",subLabel:"List all installed plugins",value:s.storage.enabledCommands?.pluginList??!0,onValueChange:function(n){return t("pluginList",n)}}),o.React.createElement(y,{label:"/theme-list",subLabel:"List all installed themes",value:s.storage.enabledCommands?.themeList??!0,onValueChange:function(n){return t("themeList",n)}})),o.React.createElement(g,{title:"Petpet Commands"},o.React.createElement(y,{label:"/petpet",subLabel:"Create pet-pet GIF of a user",value:s.storage.enabledCommands?.petpet??!0,onValueChange:function(n){return t("petpet",n)}})),o.React.createElement(g,{title:"KonoChan Commands"},o.React.createElement(y,{label:"/konoself",subLabel:"Get random image from KonoChan (private)",value:s.storage.enabledCommands?.konoself??!0,onValueChange:function(n){return t("konoself",n)}}),o.React.createElement(y,{label:"/konosend",subLabel:"Send random image from KonoChan to channel",value:s.storage.enabledCommands?.konosend??!0,onValueChange:function(n){return t("konosend",n)}})),o.React.createElement(g,{title:"Message Commands"},o.React.createElement(y,{label:"/firstmessage",subLabel:"Get the first message in a channel",value:s.storage.enabledCommands?.firstmessage??!0,onValueChange:function(n){return t("firstmessage",n)}})),o.React.createElement(g,{title:"System Commands"},o.React.createElement(y,{label:"/sysinfo",subLabel:"Display system information",value:s.storage.enabledCommands?.sysinfo??!0,onValueChange:function(n){return t("sysinfo",n)}})),o.React.createElement(g,{title:"Spotify Commands"},o.React.createElement(y,{label:"/spotify track",subLabel:"Share your current Spotify track",value:s.storage.enabledCommands?.spotifyTrack??!0,onValueChange:function(n){return t("spotifyTrack",n)}}),o.React.createElement(y,{label:"/spotify album",subLabel:"Share your current track's album",value:s.storage.enabledCommands?.spotifyAlbum??!0,onValueChange:function(n){return t("spotifyAlbum",n)}}),o.React.createElement(y,{label:"/spotify artists",subLabel:"Share your current track's artists",value:s.storage.enabledCommands?.spotifyArtists??!0,onValueChange:function(n){return t("spotifyArtists",n)}}),o.React.createElement(y,{label:"/spotify cover",subLabel:"Share your current track's cover",value:s.storage.enabledCommands?.spotifyCover??!0,onValueChange:function(n){return t("spotifyCover",n)}})),o.React.createElement(g,{title:"Credits"},o.React.createElement(C,{label:"Facts Commands",subLabel:"by jdev082"}),o.React.createElement(C,{label:"List Commands",subLabel:"by Kitomanari"}),o.React.createElement(C,{label:"PetPet Command",subLabel:"by wolfieeee"}),o.React.createElement(C,{label:"KonoChan Commands",subLabel:"by btmc727 & Rico040"}),o.React.createElement(C,{label:"FirstMessage Command",subLabel:"by sapphire"}),o.React.createElement(C,{label:"Sysinfo Command",subLabel:"by mugman"}),o.React.createElement(C,{label:"Spotify Commands",subLabel:"by Kitomanari"})),o.React.createElement(g,{title:"About"},o.React.createElement(C,{label:"Commands",subLabel:"A collection of commands"})))))}s.storage.factSettings||(s.storage.factSettings={sendAsReply:!0,includeCitation:!1}),s.storage.listSettings||(s.storage.listSettings={pluginListAlwaysDetailed:!1,themeListAlwaysDetailed:!1}),s.storage.enabledCommands||(s.storage.enabledCommands={catfact:!0,dogfact:!0,useless:!0,petpet:!0,pluginList:!0,themeList:!0,konoself:!0,konosend:!0,firstmessage:!0,sysinfo:!0,spotifyTrack:!0,spotifyAlbum:!0,spotifyArtists:!0,spotifyCover:!0});const Je={catfact:pe,dogfact:fe,useless:ye,petpet:Le,pluginList:we,themeList:Se,konoself:$e,konosend:Ae,firstmessage:Te,sysinfo:Oe,spotifyTrack:We,spotifyAlbum:qe,spotifyArtists:Ge,spotifyCover:He};let O=[];var Qe={onLoad:function(){console.log("[All-In-One Commands] Loading plugin...");for(const[e,a]of Object.entries(Je))s.storage.enabledCommands[e]&&O.push(se.registerCommand(a));console.log("[All-In-One Commands] Plugin loaded successfully!")},onUnload:function(){console.log("[All-In-One Commands] Unloading plugin..."),O.forEach(function(e){return e()}),O=[],console.log("[All-In-One Commands] Plugin unloaded successfully!")},settings:Xe};return B.default=Qe,Object.defineProperty(B,"__esModule",{value:!0}),B})({},vendetta.commands,vendetta.plugin,vendetta.metro,vendetta.themes,vendetta.plugins,vendetta.ui,vendetta.metro.common,vendetta.debug,vendetta.storage,vendetta.metro.common.ReactNative);