VCNarrator Migrate Settings

This commit is contained in:
thororen1234 2025-03-04 08:35:35 -05:00
parent 1630db4736
commit cb2dfd926e
No known key found for this signature in database
2 changed files with 101 additions and 146 deletions

View file

@ -10,7 +10,6 @@ import { Margins } from "@utils/margins";
import { wordsToTitle } from "@utils/text";
import definePlugin, {
OptionType,
PluginOptionsItem,
} from "@utils/types";
import { findByPropsLazy } from "@webpack";
import {
@ -232,10 +231,9 @@ const settings = definePluginSettings({
export default definePlugin({
name: "VcNarratorCustom",
description:
"Announces when users join, leave, or move voice channels via narrator. TikTok TTS version; speechSynthesis is pretty boring. Ported from https://github.com/Loukious/Vencord",
description: "Announces when users join, leave, or move voice channels via narrator. TikTok TTS version; speechSynthesis is pretty boring. Ported from https://github.com/Loukious/Vencord",
authors: [Devs.Ven, Devs.Nyako, EquicordDevs.Loukios, EquicordDevs.examplegit],
settings,
flux: {
VOICE_STATE_UPDATES({ voiceStates }: { voiceStates: VoiceState[]; }) {
const myGuildId = SelectedGuildStore.getGuildId();
@ -297,13 +295,10 @@ export default definePlugin({
},
},
optionsCache: null as Record<string, PluginOptionsItem> | null,
settings,
settingsAboutComponent({ tempSettings: s }) {
const types = useMemo(
() =>
Object.keys(settings.store)
Object.keys(settings.store!)
.filter(k => k.endsWith("Message"))
.map(k => k.slice(0, -7)),
[]