From 3d4a4843c161c4c7df023c0aa4e879771d1adc14 Mon Sep 17 00:00:00 2001 From: kmmiio99o <164557248+kmmiio99o@users.noreply.github.com> Date: Sat, 27 Sep 2025 20:45:03 +0200 Subject: [PATCH] deploy --- all-in-one/index.js | 6 +++--- all-in-one/manifest.json | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/all-in-one/index.js b/all-in-one/index.js index ae32505..21e4a18 100644 --- a/all-in-one/index.js +++ b/all-in-one/index.js @@ -1,4 +1,4 @@ -(function(D,P,a,p,ce,T,m,u,i,j,l,O){"use strict";const M=p.findByProps("sendMessage"),r=async function(t,n,s,e){if(!n)return{type:4};const o={content:n,...s&&e?.factSettings?.sendAsReply?{messageReference:{messageId:s}}:{}};return await M.sendMessage(t,o,void 0,{nonce:(Date.now()*4194304).toString()}),{type:4}},V=async function(){const t=await(await fetch("https://uselessfacts.jsph.pl/api/v2/facts/random")).json();return{text:t.text,source:t.source,language:t.language}},W=async function(){return{text:(await(await fetch("https://dogapi.dog/api/v2/facts?limit=1")).json()).data[0].attributes.body}},K=async function(){const t=await(await fetch("https://catfact.ninja/fact")).json();return{text:t.fact,length:t.length}},G=async function(t){return await(await fetch(`https://api.obamabot.me/v2/image/petpet?image=${t.replace("webp","png")}`)).json()},A=function(t){let n=t.text;return a.storage.factSettings?.includeCitation&&t.source&&(n+=` +(function(E,j,a,h,re,v,m,u,i,M,l,V){"use strict";const W=h.findByProps("sendMessage"),r=async function(t,n,s,e){if(!n)return{type:4};const o={content:n,...s&&e?.factSettings?.sendAsReply?{messageReference:{messageId:s}}:{}};return await W.sendMessage(t,o,void 0,{nonce:(Date.now()*4194304).toString()}),{type:4}},K=async function(){const t=await(await fetch("https://uselessfacts.jsph.pl/api/v2/facts/random")).json();return{text:t.text,source:t.source,language:t.language}},G=async function(){return{text:(await(await fetch("https://dogapi.dog/api/v2/facts?limit=1")).json()).data[0].attributes.body}},q=async function(){const t=await(await fetch("https://catfact.ninja/fact")).json();return{text:t.fact,length:t.length}},U=async function(t){return await(await fetch(`https://api.obamabot.me/v2/image/petpet?image=${t.replace("webp","png")}`)).json()},T=function(t){let n=t.text;return a.storage.factSettings?.includeCitation&&t.source&&(n+=` -Source: ${t.source}`),n},q={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,n){const s=await K();return r(n.channel.id,A(s),n.message?.id,a.storage)}},U={name:"dogfact",displayName:"dogfact",description:"Sends a dog fact.",displayDescription:"Sends a dog fact.",applicationId:"-1",inputType:1,type:1,execute:async function(t,n){const s=await W();return r(n.channel.id,A(s),n.message?.id,a.storage)}},z={name:"useless",displayName:"useless",description:"Sends a useless fact.",displayDescription:"Sends a useless fact.",applicationId:"-1",inputType:1,type:1,execute:async function(t,n){const s=await V();return r(n.channel.id,A(s),n.message?.id,a.storage)}},h="https://vd-plugins.github.io/proxy/actuallythesun.github.io/vendetta-plugins/SplitLargeMessages/",d={ENABLED:"\u{1F7E2}",DISABLED:"\u{1F534}",SELECTED:"\u{1F536}",NOT_SELECTED:"\u{1F537}"},y=function(t){return t.map(function(n){return n.name}).join(", ")},f=function(t){return t.join(` -`).trimEnd()},N=function(t){return f(t).length},R=function(){return Object.keys(m.plugins).includes(h)},I=function(){return Object.values(m.plugins).find(function(t){return t.id===h})?.enabled??!1},$=function(){return u.alerts.showConfirmationAlert({title:"Large Message Warning",content:"This list is too long to send! Would you like to install the Split Large Messages plugin?",confirmText:"Install Plugin",cancelText:"Cancel",confirmColor:"brand",onConfirm:function(){i.openURL(h)}})},x=function(){return u.alerts.showConfirmationAlert({title:"Plugin Disabled",content:"The Split Large Messages plugin is installed but disabled. Would you like to enable it now?",confirmText:"Enable Plugin",cancelText:"Cancel",confirmColor:"brand",onConfirm:function(){const t=Object.values(m.plugins).find(function(n){return n.id===h});t&&(t.enabled=!0)}})};async function H(t,n){const s=a.storage.listSettings?.pluginListAlwaysDetailed??!1,e=[`**My Plugin List | ${Object.keys(m.plugins).length} Plugins**`,""];for(const o of Object.values(m.plugins)){const{enabled:b,manifest:C,id:v}=o,{name:w,description:S,authors:L}=C;t||s?e.push(`> **Name**: ${w}`,`> **Status**: ${b?d.ENABLED:d.DISABLED}`,`> **Description**: ${S}`,`> **Authors**: ${y(L)}`,`> **[Install!](${v})**`,""):e.push(`> ${b?d.ENABLED:d.DISABLED} **${w}** by ${y(L)}`)}return N(e)>2e3?R()?I()?u.alerts.showConfirmationAlert({title:"Large Message",content:"This list is over 2000 characters. Send anyway?",confirmText:"Send",cancelText:"Cancel",onConfirm:function(){return r(n.channel.id,f(e))}}):x():$():r(n.channel.id,f(e))}async function J(t,n){const s=a.storage.themeListAlwaysDetailed??!1,e=[`**My Theme List | ${Object.keys(T.themes).length} Themes**`,""],o=Object.values(T.themes);if(o.length)for(const b of o){const{selected:C,data:v,id:w}=b,{name:S,description:L,authors:F}=v;t||s?e.push(`> **Name**: ${S}`,`> **Selected**: ${C?d.SELECTED:d.NOT_SELECTED}`,`> **Description**: ${L}`,`> **Authors**: ${y(F)}`,`> **[Install!](${w})**`,""):e.push(`> ${C?d.SELECTED:d.NOT_SELECTED} **${S}** by ${y(F)}`)}else e.push("Nothing to see here, huh...");return N(e)>2e3?R()?I()?u.alerts.showConfirmationAlert({title:"Large Message",content:"This list is over 2000 characters. Send anyway?",confirmText:"Send",cancelText:"Cancel",onConfirm:function(){return r(n.channel.id,f(e))}}):x():$():r(n.channel.id,f(e))}const Q={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:async function(t,n){const s=t.find(function(e){return e.name==="detailed"})?.value??!1;return H(s,n)},applicationId:"-1",inputType:1,type:1},X={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:async function(t,n){const s=t.find(function(e){return e.name==="detailed"})?.value??!1;return J(s,n)},applicationId:"-1",inputType:1,type:1},Y=p.findByStoreName("UserStore"),Z={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(t,n){const s=(await Y.getUser(t[0].value)).getAvatarURL(512),e=await G(s);return r(n.channel.id,e.url,n.message?.id)},applicationId:"-1",inputType:1,type:1},k=async function(t){const n="https://konachan.com/post.json",s=t?"rating:explicit":"rating:safe",e=Math.floor(Math.random()*100);try{const o=await(await fetch(`${n}?tags=${s}&limit=1&page=${e}`)).json();return!Array.isArray(o)||o.length===0?null:o[0].file_url}catch(o){return console.error("[KonoChan Randomizer] Error fetching image:",o),null}},B={name:"nsfw",description:"Include NSFW content?",type:5,required:!1,displayName:"nsfw",displayDescription:"Include NSFW content?"},_=function(){return u.alerts.showConfirmationAlert({title:"NSFW Content Warning",content:"NSFW content can only be sent in NSFW channels!",confirmText:"Okay",cancelText:null,confirmColor:"brand",isDismissable:!0})},ee={name:"konoself",displayName:"konoself",description:"Fetch a random image from KonoChan for yourself.",displayDescription:"Fetch a random image from KonoChan for yourself.",options:[B],execute:async function(t,n){const s=new Map(t.map(function(o){return[o.name,o]})).get("nsfw")?.value||!1;if(s&&!n.channel.nsfw)return _(),{type:4};const e=await k(s);return e?{type:4,data:{content:`Here's your random image: ${e}`,flags:64}}:{type:4,data:{content:"No image found. Try again later.",flags:64}}},applicationId:"-1",inputType:1,type:1},te={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:[B],execute:async function(t,n){const s=new Map(t.map(function(o){return[o.name,o]})).get("nsfw")?.value||!1;if(s&&!n.channel.nsfw)return _(),{type:4};const e=await k(s);return e?r(n.channel.id,e):r(n.channel.id,"No image found. Try again later.")},applicationId:"-1",inputType:1,type:1},{ScrollView:ne}=p.findByProps("ScrollView"),{TableRowGroup:g,TableSwitchRow:c,Stack:ae}=p.findByProps("TableSwitchRow","TableRowGroup","Stack");a.storage.factSettings||(a.storage.factSettings={sendAsReply:!0,includeCitation:!1}),a.storage.listSettings||(a.storage.listSettings={pluginListAlwaysDetailed:!1,themeListAlwaysDetailed:!1}),a.storage.enabledCommands||(a.storage.enabledCommands={catfact:!0,dogfact:!0,useless:!0,petpet:!0,pluginList:!0,themeList:!0,konoself:!0,konosend:!0});const se=function(t,n){return u.alerts.showConfirmationAlert({title:"Restart Required",content:`${n?"Enabling":"Disabling"} the ${t} command requires a Discord restart to take effect. Would you like to restart now?`,confirmText:"Restart",cancelText:"Later",confirmColor:"brand",onConfirm:function(){a.storage.enabledCommands[t]=n,window.enmity.plugins.reload("vendetta")},onCancel:function(){a.storage.enabledCommands[t]=!n}})};function ie(){j.useProxy(a.storage);const[t,n]=i.React.useReducer(function(e){return e+1},0),s=function(e,o){se(e,o),n()};return i.React.createElement(O.View,{style:{flex:1}},i.React.createElement(ne,{style:{flex:1}},i.React.createElement(ae,{spacing:8},i.React.createElement(g,{title:"Facts Commands"},i.React.createElement(c,{label:"Send as Reply",subLabel:"Send facts as a reply to the command message",icon:l.getAssetIDByName("ic_reply_24px"),value:a.storage.factSettings.sendAsReply,onValueChange:function(e){a.storage.factSettings.sendAsReply=e,n()}}),i.React.createElement(c,{label:"Include Source Citation",subLabel:"Include the source of facts when available",icon:l.getAssetIDByName("ic_info"),value:a.storage.factSettings.includeCitation,onValueChange:function(e){a.storage.factSettings.includeCitation=e,n()}}),i.React.createElement(c,{label:"/catfact",subLabel:"Get random cat facts",icon:l.getAssetIDByName("ic_info"),value:a.storage.enabledCommands.catfact,onValueChange:function(e){return s("catfact",e)}}),i.React.createElement(c,{label:"/dogfact",subLabel:"Get random dog facts",icon:l.getAssetIDByName("ic_info"),value:a.storage.enabledCommands.dogfact,onValueChange:function(e){return s("dogfact",e)}}),i.React.createElement(c,{label:"/useless",subLabel:"Get random useless facts",icon:l.getAssetIDByName("ic_info"),value:a.storage.enabledCommands.useless,onValueChange:function(e){return s("useless",e)}})),i.React.createElement(g,{title:"List Commands"},i.React.createElement(c,{label:"Always Send Detailed Plugin List",subLabel:"Always use detailed mode when listing plugins",icon:l.getAssetIDByName("ic_message_copy"),value:a.storage.listSettings.pluginListAlwaysDetailed,onValueChange:function(e){a.storage.listSettings.pluginListAlwaysDetailed=e,n()}}),i.React.createElement(c,{label:"Always Send Detailed Theme List",subLabel:"Always use detailed mode when listing themes",icon:l.getAssetIDByName("ic_theme"),value:a.storage.listSettings.themeListAlwaysDetailed,onValueChange:function(e){a.storage.listSettings.themeListAlwaysDetailed=e,n()}}),i.React.createElement(c,{label:"/plugin-list",subLabel:"List all installed plugins",icon:l.getAssetIDByName("ic_plugins"),value:a.storage.enabledCommands.pluginList,onValueChange:function(e){return s("pluginList",e)}}),i.React.createElement(c,{label:"/theme-list",subLabel:"List all installed themes",icon:l.getAssetIDByName("ic_theme"),value:a.storage.enabledCommands.themeList,onValueChange:function(e){return s("themeList",e)}})),i.React.createElement(g,{title:"Image Commands"},i.React.createElement(c,{label:"/petpet",subLabel:"Create pet-pet GIF of a user",icon:l.getAssetIDByName("ic_image"),value:a.storage.enabledCommands.petpet,onValueChange:function(e){return s("petpet",e)}})),i.React.createElement(g,{title:"KonoChan Commands"},i.React.createElement(c,{label:"/konoself",subLabel:"Get random image from KonoChan (private)",icon:l.getAssetIDByName("ic_image"),value:a.storage.enabledCommands.konoself,onValueChange:function(e){return s("konoself",e)}}),i.React.createElement(c,{label:"/konosend",subLabel:"Send random image from KonoChan to channel",icon:l.getAssetIDByName("ic_image"),value:a.storage.enabledCommands.konosend,onValueChange:function(e){return s("konosend",e)}})),i.React.createElement(g,{title:"About"},i.React.createElement(c,{label:"All-In-One Commands",subLabel:"A collection of useful commands",icon:l.getAssetIDByName("ic_badge_staff"),value:!0,disabled:!0})))))}a.storage.factSettings||(a.storage.factSettings={sendAsReply:!0,includeCitation:!1}),a.storage.listSettings||(a.storage.listSettings={pluginListAlwaysDetailed:!1,themeListAlwaysDetailed:!1}),a.storage.enabledCommands||(a.storage.enabledCommands={catfact:!0,dogfact:!0,useless:!0,petpet:!0,pluginList:!0,themeList:!0,konoself:!0,konosend:!0});const oe={catfact:q,dogfact:U,useless:z,petpet:Z,pluginList:Q,themeList:X,konoself:ee,konosend:te};let E=[];var le={onLoad:function(){console.log("[All-In-One Commands] Loading plugin...");for(const[t,n]of Object.entries(oe))a.storage.enabledCommands[t]&&E.push(P.registerCommand(n));console.log("[All-In-One Commands] Plugin loaded successfully!")},onUnload:function(){console.log("[All-In-One Commands] Unloading plugin..."),E.forEach(function(t){return t()}),E=[],console.log("[All-In-One Commands] Plugin unloaded successfully!")},settings:ie};return D.default=le,Object.defineProperty(D,"__esModule",{value:!0}),D})({},vendetta.commands,vendetta.plugin,vendetta.metro,vendetta.ui.toasts,vendetta.themes,vendetta.plugins,vendetta.ui,vendetta.metro.common,vendetta.storage,vendetta.ui.assets,vendetta.metro.common.ReactNative); +Source: ${t.source}`),n},H={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,n){const s=await q();return r(n.channel.id,T(s),n.message?.id,a.storage)}},z={name:"dogfact",displayName:"dogfact",description:"Sends a dog fact.",displayDescription:"Sends a dog fact.",applicationId:"-1",inputType:1,type:1,execute:async function(t,n){const s=await G();return r(n.channel.id,T(s),n.message?.id,a.storage)}},J={name:"useless",displayName:"useless",description:"Sends a useless fact.",displayDescription:"Sends a useless fact.",applicationId:"-1",inputType:1,type:1,execute:async function(t,n){const s=await K();return r(n.channel.id,T(s),n.message?.id,a.storage)}},y="https://vd-plugins.github.io/proxy/actuallythesun.github.io/vendetta-plugins/SplitLargeMessages/",d={ENABLED:"\u{1F7E2}",DISABLED:"\u{1F534}",SELECTED:"\u{1F536}",NOT_SELECTED:"\u{1F537}"},b=function(t){return t.map(function(n){return n.name}).join(", ")},f=function(t){return t.join(` +`).trimEnd()},I=function(t){return f(t).length},$=function(){return Object.keys(m.plugins).includes(y)},x=function(){return Object.values(m.plugins).find(function(t){return t.id===y})?.enabled??!1},k=function(){return u.alerts.showConfirmationAlert({title:"Large Message Warning",content:"This list is too long to send! Would you like to install the Split Large Messages plugin?",confirmText:"Install Plugin",cancelText:"Cancel",confirmColor:"brand",onConfirm:function(){i.openURL(y)}})},B=function(){return u.alerts.showConfirmationAlert({title:"Plugin Disabled",content:"The Split Large Messages plugin is installed but disabled. Would you like to enable it now?",confirmText:"Enable Plugin",cancelText:"Cancel",confirmColor:"brand",onConfirm:function(){const t=Object.values(m.plugins).find(function(n){return n.id===y});t&&(t.enabled=!0)}})};async function Q(t,n){const s=a.storage.listSettings?.pluginListAlwaysDetailed??!1,e=[`**My Plugin List | ${Object.keys(m.plugins).length} Plugins**`,""];for(const o of Object.values(m.plugins)){const{enabled:S,manifest:w,id:N}=o,{name:L,description:A,authors:D}=w;t||s?e.push(`> **Name**: ${L}`,`> **Status**: ${S?d.ENABLED:d.DISABLED}`,`> **Description**: ${A}`,`> **Authors**: ${b(D)}`,`> **[Install!](${N})**`,""):e.push(`> ${S?d.ENABLED:d.DISABLED} **${L}** by ${b(D)}`)}return I(e)>2e3?$()?x()?u.alerts.showConfirmationAlert({title:"Large Message",content:"This list is over 2000 characters. Send anyway?",confirmText:"Send",cancelText:"Cancel",onConfirm:function(){return r(n.channel.id,f(e))}}):B():k():r(n.channel.id,f(e))}async function X(t,n){const s=a.storage.themeListAlwaysDetailed??!1,e=[`**My Theme List | ${Object.keys(v.themes).length} Themes**`,""],o=Object.values(v.themes);if(o.length)for(const S of o){const{selected:w,data:N,id:L}=S,{name:A,description:D,authors:O}=N;t||s?e.push(`> **Name**: ${A}`,`> **Selected**: ${w?d.SELECTED:d.NOT_SELECTED}`,`> **Description**: ${D}`,`> **Authors**: ${b(O)}`,`> **[Install!](${L})**`,""):e.push(`> ${w?d.SELECTED:d.NOT_SELECTED} **${A}** by ${b(O)}`)}else e.push("Nothing to see here, huh...");return I(e)>2e3?$()?x()?u.alerts.showConfirmationAlert({title:"Large Message",content:"This list is over 2000 characters. Send anyway?",confirmText:"Send",cancelText:"Cancel",onConfirm:function(){return r(n.channel.id,f(e))}}):B():k():r(n.channel.id,f(e))}const Y={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:async function(t,n){const s=t.find(function(e){return e.name==="detailed"})?.value??!1;return Q(s,n)},applicationId:"-1",inputType:1,type:1},Z={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:async function(t,n){const s=t.find(function(e){return e.name==="detailed"})?.value??!1;return X(s,n)},applicationId:"-1",inputType:1,type:1},ee=h.findByStoreName("UserStore"),te={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(t,n){const s=(await ee.getUser(t[0].value)).getAvatarURL(512),e=await U(s);return r(n.channel.id,e.url,n.message?.id)},applicationId:"-1",inputType:1,type:1},P=async function(t){const n="https://konachan.com/post.json",s=t?"rating:explicit":"rating:safe",e=Math.floor(Math.random()*100);try{const o=await(await fetch(`${n}?tags=${s}&limit=1&page=${e}`)).json();return!Array.isArray(o)||o.length===0?null:o[0].file_url}catch(o){return console.error("[KonoChan Randomizer] Error fetching image:",o),null}},_={name:"nsfw",description:"Include NSFW content?",type:5,required:!1,displayName:"nsfw",displayDescription:"Include NSFW content?"},F=function(){return u.alerts.showConfirmationAlert({title:"NSFW Content Warning",content:"NSFW content can only be sent in NSFW channels!",confirmText:"Okay",cancelText:null,confirmColor:"brand",isDismissable:!0})},ne={name:"konoself",displayName:"konoself",description:"Fetch a random image from KonoChan for yourself.",displayDescription:"Fetch a random image from KonoChan for yourself.",options:[_],execute:async function(t,n){const s=new Map(t.map(function(o){return[o.name,o]})).get("nsfw")?.value||!1;if(s&&!n.channel.nsfw)return F(),{type:4};const e=await P(s);return e?{type:4,data:{content:`Here's your random image: ${e}`,flags:64}}:{type:4,data:{content:"No image found. Try again later.",flags:64}}},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:[_],execute:async function(t,n){const s=new Map(t.map(function(o){return[o.name,o]})).get("nsfw")?.value||!1;if(s&&!n.channel.nsfw)return F(),{type:4};const e=await P(s);return e?r(n.channel.id,e):r(n.channel.id,"No image found. Try again later.")},applicationId:"-1",inputType:1,type:1},{ScrollView:se}=h.findByProps("ScrollView"),{TableRowGroup:g,TableSwitchRow:c,Stack:ie,TableRow:p}=h.findByProps("TableSwitchRow","TableRowGroup","Stack","TableRow");a.storage.factSettings||(a.storage.factSettings={sendAsReply:!0,includeCitation:!1}),a.storage.listSettings||(a.storage.listSettings={pluginListAlwaysDetailed:!1,themeListAlwaysDetailed:!1}),a.storage.enabledCommands||(a.storage.enabledCommands={catfact:!0,dogfact:!0,useless:!0,petpet:!0,pluginList:!0,themeList:!0,konoself:!0,konosend:!0}),a.storage.pendingRestart||(a.storage.pendingRestart=!1);const C={PETPET:"wolfieeee",FACTS:"jdev082",LISTS:"Kitomanari",KONOCHAN:["btmc727","Rico040"]};function oe(){M.useProxy(a.storage);const[t,n]=i.React.useReducer(function(e){return e+1},0);i.React.useEffect(function(){return function(){a.storage.pendingRestart&&u.alerts.showConfirmationAlert({title:"Restart Required",content:"Command changes require Discord to restart. Would you like to restart now?",confirmText:"Restart",cancelText:"Later",confirmColor:"brand",onConfirm:function(){window.enmity.plugins.reload("vendetta")}})}},[]);const s=function(e,o){a.storage.enabledCommands[e]=o,a.storage.pendingRestart=!0,n()};return i.React.createElement(V.View,{style:{flex:1}},i.React.createElement(se,{style:{flex:1}},i.React.createElement(ie,{spacing:8},i.React.createElement(g,{title:"Facts Commands"},i.React.createElement(c,{label:"Send as Reply",subLabel:"Send facts as a reply to the command message",icon:l.getAssetIDByName("ic_reply_24px"),value:a.storage.factSettings.sendAsReply,onValueChange:function(e){a.storage.factSettings.sendAsReply=e,n()}}),i.React.createElement(c,{label:"Include Source Citation",subLabel:"Include the source of facts when available",icon:l.getAssetIDByName("ic_info"),value:a.storage.factSettings.includeCitation,onValueChange:function(e){a.storage.factSettings.includeCitation=e,n()}}),i.React.createElement(p,{label:"Credits",subLabel:`Facts commands by ${C.FACTS}`,icon:l.getAssetIDByName("ic_info")}),i.React.createElement(c,{label:"/catfact",subLabel:"Get random cat facts",icon:l.getAssetIDByName("ic_info"),value:a.storage.enabledCommands.catfact,onValueChange:function(e){return s("catfact",e)}}),i.React.createElement(c,{label:"/dogfact",subLabel:"Get random dog facts",icon:l.getAssetIDByName("ic_info"),value:a.storage.enabledCommands.dogfact,onValueChange:function(e){return s("dogfact",e)}}),i.React.createElement(c,{label:"/useless",subLabel:"Get random useless facts",icon:l.getAssetIDByName("ic_info"),value:a.storage.enabledCommands.useless,onValueChange:function(e){return s("useless",e)}})),i.React.createElement(g,{title:"List Commands"},i.React.createElement(c,{label:"Always Send Detailed Plugin List",subLabel:"Always use detailed mode when listing plugins",icon:l.getAssetIDByName("ic_message_copy"),value:a.storage.listSettings.pluginListAlwaysDetailed,onValueChange:function(e){a.storage.listSettings.pluginListAlwaysDetailed=e,n()}}),i.React.createElement(c,{label:"Always Send Detailed Theme List",subLabel:"Always use detailed mode when listing themes",icon:l.getAssetIDByName("ic_theme"),value:a.storage.listSettings.themeListAlwaysDetailed,onValueChange:function(e){a.storage.listSettings.themeListAlwaysDetailed=e,n()}}),i.React.createElement(p,{label:"Credits",subLabel:`List commands by ${C.LISTS}`,icon:l.getAssetIDByName("ic_info")}),i.React.createElement(c,{label:"/plugin-list",subLabel:"List all installed plugins",icon:l.getAssetIDByName("ic_plugins"),value:a.storage.enabledCommands.pluginList,onValueChange:function(e){return s("pluginList",e)}}),i.React.createElement(c,{label:"/theme-list",subLabel:"List all installed themes",icon:l.getAssetIDByName("ic_theme"),value:a.storage.enabledCommands.themeList,onValueChange:function(e){return s("themeList",e)}})),i.React.createElement(g,{title:"Image Commands"},i.React.createElement(p,{label:"Credits",subLabel:`PetPet command by ${C.PETPET}`,icon:l.getAssetIDByName("ic_info")}),i.React.createElement(c,{label:"/petpet",subLabel:"Create pet-pet GIF of a user",icon:l.getAssetIDByName("ic_image"),value:a.storage.enabledCommands.petpet,onValueChange:function(e){return s("petpet",e)}})),i.React.createElement(g,{title:"KonoChan Commands"},i.React.createElement(p,{label:"Credits",subLabel:`KonoChan commands by ${C.KONOCHAN.join(" & ")}`,icon:l.getAssetIDByName("ic_info")}),i.React.createElement(c,{label:"/konoself",subLabel:"Get random image from KonoChan (private)",icon:l.getAssetIDByName("ic_image"),value:a.storage.enabledCommands.konoself,onValueChange:function(e){return s("konoself",e)}}),i.React.createElement(c,{label:"/konosend",subLabel:"Send random image from KonoChan to channel",icon:l.getAssetIDByName("ic_image"),value:a.storage.enabledCommands.konosend,onValueChange:function(e){return s("konosend",e)}})),i.React.createElement(g,{title:"About"},i.React.createElement(p,{label:"All-In-One Commands",subLabel:"A collection of useful commands",icon:l.getAssetIDByName("ic_badge_staff")})))))}a.storage.factSettings||(a.storage.factSettings={sendAsReply:!0,includeCitation:!1}),a.storage.listSettings||(a.storage.listSettings={pluginListAlwaysDetailed:!1,themeListAlwaysDetailed:!1}),a.storage.enabledCommands||(a.storage.enabledCommands={catfact:!0,dogfact:!0,useless:!0,petpet:!0,pluginList:!0,themeList:!0,konoself:!0,konosend:!0});const le={catfact:H,dogfact:z,useless:J,petpet:te,pluginList:Y,themeList:Z,konoself:ne,konosend:ae};let R=[];var ce={onLoad:function(){console.log("[All-In-One Commands] Loading plugin...");for(const[t,n]of Object.entries(le))a.storage.enabledCommands[t]&&R.push(j.registerCommand(n));console.log("[All-In-One Commands] Plugin loaded successfully!")},onUnload:function(){console.log("[All-In-One Commands] Unloading plugin..."),R.forEach(function(t){return t()}),R=[],console.log("[All-In-One Commands] Plugin unloaded successfully!")},settings:oe};return E.default=ce,Object.defineProperty(E,"__esModule",{value:!0}),E})({},vendetta.commands,vendetta.plugin,vendetta.metro,vendetta.ui.toasts,vendetta.themes,vendetta.plugins,vendetta.ui,vendetta.metro.common,vendetta.storage,vendetta.ui.assets,vendetta.metro.common.ReactNative); diff --git a/all-in-one/manifest.json b/all-in-one/manifest.json index 1b9335c..8ed9067 100644 --- a/all-in-one/manifest.json +++ b/all-in-one/manifest.json @@ -1 +1 @@ -{"authors":[{"name":"kmmiio99o","id":"879393496627306587"}],"main":"index.js","name":"All Commands","description":"A collection of useful commands including facts, petpet, and more.","vendetta":{"icon":"ic_badge_staff","original":"plugins/all-in-one"},"version":"1.0.0","hash":"aade3e9f666cef572e58cf26b93b7f29069019bc42c6ef6c430ef64376e99103"} \ No newline at end of file +{"authors":[{"name":"kmmiio99o","id":"879393496627306587"}],"main":"index.js","name":"All Commands","description":"A collection of useful commands including facts, petpet, and more.","vendetta":{"icon":"ic_badge_staff","original":"plugins/all-in-one"},"version":"1.0.0","hash":"1f95253dc6a330da270f15d3b7b4c271c3706c69b09fcd2700d029b6125f7870"} \ No newline at end of file