color diy

This commit is contained in:
Gabe Yuan
2023-08-08 16:41:47 +08:00
parent ac761481ba
commit 94fd2b3c62
8 changed files with 47 additions and 19 deletions

View File

@@ -78,9 +78,11 @@ export function useRules() {
toLang,
textStyle,
transOpen,
bgColor,
}) => ({
pattern,
selector: typeof selector === "string" ? selector : "",
bgColor: typeof bgColor === "string" ? bgColor : "",
translator: matchValue([GLOBAL_KEY, ...OPT_TRANS_ALL], translator),
fromLang: matchValue([GLOBAL_KEY, ...fromLangs], fromLang),
toLang: matchValue([GLOBAL_KEY, ...toLangs], toLang),