Source:${t.source}`),a},fe={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(t,a){try{const n=await ge(),i=Date.now().toString();return _.sendMessage(a.channel.id,{content:x(n)},void 0,{nonce:i}),{type:4}}catch(n){return console.error("[CatFact] Error:",n),{type:4}}}},me={name:"dogfact",displayName:"dogfact",description:"Sends a dog fact.",displayDescription:"Sends a dog fact.",applicationId:"-1",inputType:1,type:1,execute:async function(t,a){try{const n=await ue(),i=Date.now().toString();return _.sendMessage(a.channel.id,{content:x(n)},void 0,{nonce:i}),{type:4}}catch(n){return console.error("[DogFact] Error:",n),{type:4}}}},he={name:"useless",displayName:"useless",description:"Sends a useless fact.",displayDescription:"Sends a useless fact.",applicationId:"-1",inputType:1,type:1,execute:async function(t,a){try{const n=await de(),i=Date.now().toString();return _.sendMessage(a.channel.id,{content:x(n)},void 0,{nonce:i}),{type:4}}catch(n){return console.error("[UselessFact] Error:",n),{type:4}}}},I={CONTENT:"This list is over 2000 characters. Send anyway?",CONFIRM:"Send",CANCEL:"Cancel"},Ce={DETAILED:"detailed"},V="",v={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."},j={SEMICOL:"; ",NEW_LINE:`
`},Re="Nothing to see here, huh...",F="github.com/fres621/vendetta-plugins",E={ENABLED:"\u2705",DISABLED:"\u274C",SELECTED:"\u2705",NOT_SELECTED:"\u274C"},be=m.findByProps("sendMessage","receiveMessage"),S=m.findByProps("sendBotMessage"),G=function(){try{return m.findByStoreName("UserStore").getCurrentUser()?.premiumType===2?4e3:2e3}catch{return 2e3}}(),z=function(t){return Object.keys(t).includes(F)},W=function(t){return Object.values(t).find(function(a){return a.id==F})?.enabled},K=function(t){return t.find(function(a){return a.name===Ce.DETAILED})?.value??!1},D=function(t){return!t||!Array.isArray(t)||t.length===0?"Unknown":t.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(j.SEMICOL)||"Unknown"},H=function(t){return t.join(j.NEW_LINE).trimEnd()},T=function(t){return H(t).length},B=async function(t,a){const n=Date.now().toString();await be.sendMessage(t,{content:H(a)},void 0,{nonce:n})},X=function(t,a){return[`**My${t}List|${a}${t}s**`,V]};async function Ee(t,a){try{const n=K(t),i=s.storage.themeListAlwaysDetailed??!1;if(!A.themes||typeof A.themes!="object"){const f=a.channel.id;return S.sendBotMessage(f,"No themes found or themes not loaded yet."),{type:4}}const r=Object.values(A.themes),d=a.channel.id,l=X("Theme",Object.keys(A.themes).length);if(r.length)for(const f of r){if(!f||typeof f!="object")continue;const{selected:g,data:p,id:R}=f,w=p?.name||"Unknown Theme",N=p?.description||"No description",M=p?.authors;n||i?l.push(`>**Name**:${w}`,`>**Selected**:${g?E.SELECTED:E.NOT_SELECTED}`,`>**Description**:${N}`,`>**Authors**:${D(M)}`,`>**[Install!](${R||"unknown"})**`,V):l.push(`>${g?E.SELECTED:E.NOT_SELECTED}**${w}**by${D(M)}`)}else l.push(Re);const o=T(l)>G;if(o&&!z(b.plugins))S.sendBotMessage(d,v.SLM_NOT_INSTALLED);else if(o&&!W(b.plugins))S.sendBotMessage(d,v.SLM_NOT_ENABLED);else{if(T(l)>2e3)return u.alerts.showConfirmationAlert({content:I.CONTENT,confirmText:I.CONFIRM,cancelText:I.CANCEL,onConfirm:async function(){return await B(d,l)}});await B(d,l)}}catch(n){return console.error("[ThemeList] Error:",n),{type:4}}}async function Ie(t,a){try{const n=K(t),i=s.storage.pluginListAlwaysDetailed??!1,r=a.channel.id;if(!b.plugins||typeof b.plugins!="object")return S.sendBotMessage(r,"No plugins found or plugins not loaded yet."),{type:4};const d=X("Plugin",Object.keys(b.plugins).length);for(const o of Object.values(b.plugins)){if(!o||typeof o!="object")continue;const{enabled:f,manifest:g,id:p}=o,R=g?.name||"Unknown Plugin",w=g?.description||"No description",N=g?.authors;n||i?d.push(`>**Name**:${R}`,`>**Status**:${f?E.ENABLED:E.DISABLED}`,`>**Description**:${w}`,`>**Authors**:${D(N)}`,`>**[Install!](${p||"unknown"})**`,V):d.push(`>${f?E.ENABLED:E.DISABLED}**${R}**by${D(N)}`)}const l=T(d)>G;if(l&&!z(b.plugins))S.sendBotMessage(r,v.SLM_NOT_INSTALLED);else if(l&&!W(b.plugins))S.sendBotMessage(r,v.SLM_NOT_ENABLED);else{if(T(d)>2e3)return u.alerts.showConfirmationAlert({content:I.CONTENT,confirmText:I.CONFIRM,cancelText:I.CANCEL,onConfirm:async function(){return await B(r,d)}});await B(r,d)}}catch(n){return console.error("[PluginList] Error:",n),{type:4}}}const Se={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:Ie,applicationId:"-1",inputType:1,type:1},we={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:Ee,applicationId:"-1",inputType:1,type:1
`)},void 0,{nonce:l}),{type:4}}}catch(n){return console.error("[Sysinfo] Error:",n),{type:4}}}const je={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},...ee.slice(0,-1).map(function(t){return{name:t,displayName:t,description:`Displaythe${t}section.Setdefaultinsettings.`,displayDescription:`Displaythe${t}section.Setdefaultinsettings.`,type:5,required:!1}})],execute:Ue,applicationId:"-1",inputType:1,type:1},te=m.findByProps("sendMessage","receiveMessage"),Fe=m.findByStoreName("SpotifyStore");async function Ge(t,a){return s.storage.enabledCommands?.spotifyTrack?L(a,function(n){return`https://open.spotify.com/track/${n.id}`}):{type:4}}async function ze(t,a){return s.storage.enabledCommands?.spotifyAlbum?L(a,function(n){return`https://open.spotify.com/album/${n.album.id}`}):{type:4}}async function We(t,a){return s.storage.enabledCommands?.spotifyArtists?L(a,function(n){return n.artists.map(function(i){return`[${i.name}](${i.external_urls.spotify})`}).join(`
`)}):{type:4}}async function Ke(t,a){return s.storage.enabledCommands?.spotifyCover?L(a,function(n){return n.album.image.url}):{type:4}}async function L(t,a){try{const n=t.channel.id,i=Fe?.getTrack?.();if(!i){const l=Date.now().toString();return te.sendMessage(n,{content:"You are not listening to any track."},void 0,{nonce:l}),{type:4}}const r=a(i),d=Date.now().toString();return te.sendMessage(n,{content:r},void 0,{nonce:d}),{type:4}}catch(n){return console.error("[Spotify Command] Error:",n),{type:4}}}const He={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:Ge},Xe={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:ze},qe={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:We},Ye={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},Qe=m.findByProps("sendMessage"),Ze={name:"gary",displayName:"gary",description:"Send a random Gary image to the channel.",displayDescription:"Send a random Gary image to the channel.",options:[],execute:async function(t,a){try{let n="gary";s.storage.garySettings?.useCatAPI?n="catapi":s.storage.garySettings?.useMinkerAPI?n="minker":s.storage.garySettings?.useGooberAPI&&(n="goober");const i=await pe(n);if(!i)return{type:4};const r=Date.now().toString();return Qe.sendMessage(a.channel.id,{content:i},void 0,{nonce:r}),{type:4}}catch(n){return console.error("[Gary] Error:",n),{type:4}}},applicationId:"-1",inputType:1,type:1},{ScrollView:O}=m.findByProps("ScrollView");m.findByProps("TableSwitchRow","TableRowGroup","Stack","TableRow");const{FormRow:y,FormSwitchRow:h}=le.Forms;function C({title:t,icon:a,children:n,padding:i=!1}){const r=e.stylesheet.createThemedStyleSheet({main:{backgroundColor:u.semanticColors.CARD_PRIMARY_BG,borderColor:u.semanticColors.BORDER_FAINT,borderWidth:1,borderRadius:16,overflow:"hidden",flex:1},titleContainer:{marginBottom:8,marginHorizontal:0,marginTop:8,gap:4,flexDirection:"row",alignItems:"center"},icon:{width:16,height:16,marginTop:1.5,tintColor:u.semanticColors.TEXT_MUTED},titleText:{fontSize:14,fontWeight:"600",color:u.semanticColors.TEXT_MUTED}});return e.React.createElement(e.ReactNative.View,{style:{marginHorizontal:16,marginTop:16}},t&&e.React.createElement(e.ReactNative.View,{style:r.titleContainer},a&&e.React.createElement(e.ReactNative.Image,{style:r.icon,source:a,resizeMode:"cover"}),e.React.createElement(e.ReactNative.Text,{style:r.titleText},t.toUpperCase())),e.React.createElement(e.ReactNative.View,{style:r.main},i?e.React.createElement(e.ReactNative.View,{style:{paddingHorizontal:16,paddingVertical:16}},n):n))}function Je(){const t=e.stylesheet.createThemedStyleSheet({container:{flexDirection:"column",alignItems:"center",paddingVertical:24,paddingHorizontal:16},title:{fontSize:28,fontWeight:"700",color:u.semanticColors.TEXT_NORMAL,marginBottom:4},subtitle:{fontSize:16,fontWeight:"500",color:u.semanticColors.TEXT_MUTED},iconContainer:{backgroundColor:u.semanticColors.BACKGROUND_SECONDARY,borderRadius:16,padding:12,marginBottom:16},icon:{width:32,height:32,tintColor:u.semanticColors.TEXT_NORMAL}});return e.React.createElement(e.ReactNative.View,{style:t.container},e.React.createElement(e.ReactNative.View,{style:t.iconContainer},e.React.createElement(e.ReactNative.Image,{source:c.getAssetIDByName("SettingsIcon"),style:t.icon})),e.React.createElement(e.ReactNative.Text,{style:t.title},"Commands"),e.React.createElement(e.ReactNative.Text,{style:t.subtitle},"A collection of useful commands"))}function et(){const t=e.stylesheet.createThemedStyleSheet({container:{flex:1,backgro
`,"Version 1.0.0",`
`,"Made with \u2764\uFE0F for the community"))))}function tt({forceRerender:t}){const a=e.stylesheet.createThemedStyleSheet({container:{flex:1,backgroundColor:u.semanticColors.BACKGROUND_PRIMARY},optionContainer:{flexDirection:"row",alignItems:"center",paddingVertical:16,paddingHorizontal:16,backgroundColor:u.semanticColors.CARD_PRIMARY_BG,borderRadius:12,marginHorizontal:16,marginVertical:4},selectedOption:{backgroundColor:u.semanticColors.BRAND_500_ALPHA,borderColor:u.semanticColors.BRAND_500,borderWidth:2},normalOption:{borderColor:u.semanticColors.BORDER_FAINT,borderWidth:1},radioButton:{width:20,height:20,borderRadius:10,borderWidth:2,borderColor:u.semanticColors.TEXT_MUTED,alignItems:"center",justifyContent:"center",marginRight:12},selectedRadio:{borderColor:u.semanticColors.BRAND_500},radioInner:{width:10,height:10,borderRadius:5,backgroundColor:u.semanticColors.BRAND_500},textContainer:{flex:1},optionTitle:{fontSize:16,fontWeight:"600",color:u.semanticColors.TEXT_NORMAL},optionDesc:{fontSize:14,color:u.semanticColors.TEXT_MUTED,marginTop:2},selectedText:{color:u.semanticColors.BRAND_500}}),n=[{value:"gary",title:"Gary API",desc:"Original Gary the cat images from api.garythe.cat",icon:c.getAssetIDByName("ic_cat")},{value:"catapi",title:"Cat API",desc:"Random cat pictures from thecatapi.com",icon:c.getAssetIDByName("ic_cat")},{value:"minker",title:"Minker API",desc:"Minky images from minky.materii.dev",icon:c.getAssetIDByName("ImageIcon")},{value:"goober",title:"Goober API",desc:"Goober images from api.garythe.cat/goober",icon:c.getAssetIDByName("ImageIcon")}],i=s.storage.garySettings?.imageSource||"gary";return e.React.createElement(e.ReactNative.View,{style:a.container},e.React.createElement(O,{style:{flex:1},contentContainerStyle:{paddingVertical:16,paddingBottom:38},showsVerticalScrollIndicator:!1},e.React.createElement(C,{title:"Image Source Selection",icon:c.getAssetIDByName("DownloadIcon"),padding:!0},e.React.createElement(e.ReactNative.Text,{style:{fontSize:14,color:u.semanticColors.TEXT_MUTED,marginBottom:16,textAlign:"center"}},"Choose which API the /gary command should use to fetch images.")),n.map(function(r){const d=i===r.value;return e.React.createElement(e.ReactNative.Pressable,{key:r.value,style:[a.optionContainer,d?a.selectedOption:a.normalOption],onPress:function(){s.storage.garySettings.imageSource=r.value,t()}},e.React.createElement(e.ReactNative.View,{style:[a.radioButton,d&&a.selectedRadio]},d&&e.React.createElement(e.ReactNative.View,{style:a.radioInner})),e.React.createElement(e.ReactNative.Image,{source:r.icon,style:{width:24,height:24,tintColor:d?u.semanticColors.BRAND_500:u.semanticColors.TEXT_MUTED,marginRight:12}}),e.React.createElement(e.ReactNative.View,{style:a.textContainer},e.React.createElement(e.ReactNative.Text,{style:[a.optionTitle,d&&a.selectedText]},r.title),e.React.createElement(e.ReactNative.Text,{style:a.optionDesc},r.desc)))}),e.React.createElement(C,{title:"Current Selection",icon:c.getAssetIDByName("CheckmarkIcon"),padding:!0},e.React.createElement(e.ReactNative.Text,{style:{fontSize:14,color:u.semanticColors.TEXT_NORMAL,textAlign:"center",fontWeight:"600"}},"Currently using: ",i==="gary"?"Gary API":i==="catapi"?"Cat API":i==="minker"?"Minker API":i==="goober"?"Goober API":"Gary API"))))}s.storage.factSettings||(s.storage.factSettings={sendAsReply:!0,includeCitation:!1}),s.storage.listSettings||(s.storage.listSettings={pluginListAlwaysDetailed:!1,themeListAlwaysDetailed:!1}),s.storage.garySettings||(s.storage.garySettings={imageSource:"gary"}),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,gary:!0}),s.storage.pendingRestart||(s.storage.pendingRestart=!1);function at(){ce.useProxy(s.storage);const[t,a]=e.React.useReducer(function(o){return o+1},0),n=e.NavigationNative.useNavigation(),i=e.stylesheet.createThemedStyleSheet({container:{flex:1,backgroundColor:u.semanticColors.BACKGR