Merge branch 'kwaroran:main' into patch-23

This commit is contained in:
Bo26fhmC5M
2025-02-08 14:48:56 +09:00
committed by GitHub
5 changed files with 28 additions and 6 deletions

View File

@@ -24,6 +24,7 @@ export interface RisuModule{
backgroundEmbedding?:string
assets?:[string,string,string][]
namespace?:string
customModuleToggle?:string
}
export async function exportModule(module:RisuModule, arg:{
@@ -352,6 +353,20 @@ export function getModuleRegexScripts() {
return customscripts
}
export function getModuleToggles() {
const modules = getModules()
let costomModuleToggles: string = ''
for (const module of modules) {
if(!module){
continue
}
if (module.customModuleToggle) {
costomModuleToggles += '\n' + module.customModuleToggle + '\n'
}
}
return costomModuleToggles
}
export async function applyModule() {
const sel = await alertModuleSelect()
if (!sel) {