diff --git a/src/lang/en.ts b/src/lang/en.ts index bc12e38e..027f1f3e 100644 --- a/src/lang/en.ts +++ b/src/lang/en.ts @@ -630,8 +630,8 @@ export const languageEnglish = { error: "Error", input: "Input", select: "Select", - lowLevelAccessConfirm: "This character uses Low Level Access. which means this character can access the AI model and your storage directly. do you really want to import this character?", - triggerLowLevelOnly: "This trigger only works with Low Level Access. to enable this trigger, enable Low Level Access in advanced settings in the character.", + lowLevelAccessConfirm: "This content uses Low Level Access. which means this content can access the AI model and your storage directly. do you really want to import this content?", + triggerLowLevelOnly: "This trigger only works with Low Level Access. to enable this trigger, enable Low Level Access in advanced settings in the character or module.", truthy: "Truthy", extractRegex: "Extract Text with Regex", runImgGen: "Run Image Generation", diff --git a/src/ts/process/modules.ts b/src/ts/process/modules.ts index afb292e7..a192d696 100644 --- a/src/ts/process/modules.ts +++ b/src/ts/process/modules.ts @@ -1,5 +1,5 @@ import { language } from "src/lang" -import { alertError, alertNormal } from "../alert" +import { alertConfirm, alertError, alertNormal } from "../alert" import { DataBase, setDatabase, type customscript, type loreBook, type triggerscript } from "../storage/database" import { downloadFile } from "../storage/globalApi" import { get } from "svelte/store" @@ -45,6 +45,13 @@ export async function importModule(){ return } importData.id = v4() + + if(importData.lowLevelAccess){ + const conf = await alertConfirm(language.lowLevelAccessConfirm) + if(!conf){ + return false + } + } db.modules.push(importData) setDatabase(db) return