Merge branch 'update_notification_ui' into develop

This commit is contained in:
Sakamoto Shiina
2025-06-21 09:44:03 +09:00
16 changed files with 463 additions and 149 deletions

View File

@@ -269,6 +269,9 @@ config_page:
websocket_port: websocket_port:
label: "WebSocket Port" label: "WebSocket Port"
notifications:
save_success: "Settings have been saved"
plugin_notifications: plugin_notifications:
downloading: Downloading the plugin. downloading: Downloading the plugin.
downloaded_success: Downloaded successfully. downloaded_success: Downloaded successfully.

View File

@@ -269,6 +269,9 @@ config_page:
websocket_port: websocket_port:
label: "WebSocket Port" label: "WebSocket Port"
notifications:
save_success: "設定を保存しました。"
plugin_notifications: plugin_notifications:
downloading: プラグインをダウンロード中。 downloading: プラグインをダウンロード中。
downloaded_success: プラグインのダウンロードが完了しました。 downloaded_success: プラグインのダウンロードが完了しました。

View File

@@ -110,4 +110,35 @@
min-width: 2.8rem; min-width: 2.8rem;
justify-content: center; justify-content: center;
align-items: center; align-items: center;
}
@keyframes fade_in {
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}
@keyframes fade_out {
0% {
opacity: 1;
}
100% {
opacity: 0;
}
}
.fade_in {
opacity: 0;
animation-name: fade_in;
animation-duration: 0.1s;
animation-timing-function: ease-out;
animation-fill-mode: forwards;
}
.fade_out {
opacity: 1;
animation-name: fade_out;
animation-duration: 0.1s;
animation-timing-function: ease-in;
animation-fill-mode: forwards;
} }

View File

@@ -1,5 +1,5 @@
import React, { useEffect, useState } from "react"; import React, { useEffect, useState } from "react";
import { ToastContainer, toast, Bounce } from "react-toastify"; import { ToastContainer, toast, cssTransition } from "react-toastify";
import clsx from "clsx"; import clsx from "clsx";
import "./ReactToastifyOverrideClass.scss"; import "./ReactToastifyOverrideClass.scss";
@@ -13,6 +13,13 @@ import ErrorSvg from "@images/error.svg?react";
import { useNotificationStatus } from "@logics_common"; import { useNotificationStatus } from "@logics_common";
const CustomTransition = cssTransition({
enter: "fade_in",
exit: "fade_out",
collapse: false,
});
export const SnackbarController = () => { export const SnackbarController = () => {
const { currentNotificationStatus, closeNotification } = useNotificationStatus(); const { currentNotificationStatus, closeNotification } = useNotificationStatus();
const [containerKey, setContainerKey] = useState(0); const [containerKey, setContainerKey] = useState(0);
@@ -28,56 +35,50 @@ export const SnackbarController = () => {
} }
); );
let hideDuration = 5000; let hide_duration = 5000;
if (settings.options?.hide_duration === null) { if (settings.options?.hide_duration === null) {
hideDuration = false; hide_duration = false;
} else if (Number(settings.options?.hide_duration)) { } else if (Number(settings.options?.hide_duration)) {
hideDuration = Number(settings.options?.hide_duration); hide_duration = Number(settings.options?.hide_duration);
} }
useEffect(() => { useEffect(() => {
if (!settings.is_open) return; if (!settings.is_open) return;
const message_text = settings.message; const message_text = settings.message;
const category_id = settings.category_id ? settings.category_id : message_text;
if (toast.isActive(message_text)) { const to_hide_progress_bar = (settings.options?.to_hide_progress_bar === true) ? true : false;
setContainerKey(prevKey => prevKey + 1);
const asyncShowNotification = async () => {
setTimeout(() => { setTimeout(() => {
toast(message_text, { toast(message_text, {
toastId: message_text, toastId: category_id,
type: settings.status, type: settings.status,
autoClose: hideDuration, autoClose: hide_duration,
transition: Bounce, transition: CustomTransition,
toastClassName: snackbar_classname, toastClassName: snackbar_classname,
hideProgressBar: to_hide_progress_bar,
progressClassName: styles.toast_progress, progressClassName: styles.toast_progress,
closeButton: <CloseButtonContainer />, closeButton: <CloseButtonContainer />,
onClose: () => { onClose: () => {
closeNotification(); closeNotification();
}, },
}); });
}, 50); }, 100);
} else { };
toast(message_text, {
toastId: message_text, setContainerKey(prevKey => prevKey + 1);
type: settings.status, asyncShowNotification();
autoClose: hideDuration,
transition: Bounce, }, [settings]);
toastClassName: snackbar_classname,
progressClassName: styles.toast_progress,
closeButton: <CloseButtonContainer />,
onClose: () => {
closeNotification();
},
});
}
}, [settings, hideDuration, closeNotification, snackbar_classname]);
return ( return (
<ToastContainer <ToastContainer
key={containerKey} key={containerKey}
position="bottom-left" position="bottom-left"
transition={Bounce} transition={CustomTransition}
hideProgressBar={false} hideProgressBar={false}
newestOnTop={false} newestOnTop={false}
closeOnClick={false} closeOnClick={false}

View File

@@ -119,13 +119,13 @@ export const _useBackendErrorHandling = () => {
case "/set/data/deepl_auth_key": case "/set/data/deepl_auth_key":
if (message === "DeepL auth key length is not correct") { if (message === "DeepL auth key length is not correct") {
updateDeepLAuthKey(data); updateDeepLAuthKey(data);
showNotification_Error(t("common_error.deepl_auth_key_invalid_length")); showNotification_Error(t("common_error.deepl_auth_key_invalid_length"), { category_id: "deepl_auth_key" });
} else if (message === "Authentication failure of deepL auth key") { } else if (message === "Authentication failure of deepL auth key") {
updateDeepLAuthKey(data); updateDeepLAuthKey(data);
showNotification_Error(t("common_error.deepl_auth_key_failed_authentication")); showNotification_Error(t("common_error.deepl_auth_key_failed_authentication"), { category_id: "deepl_auth_key" });
} else { // Exception } else { // Exception
updateDeepLAuthKey(data); updateDeepLAuthKey(data);
showNotification_Error(message); showNotification_Error(message, { category_id: "deepl_auth_key" });
} }
return; return;

View File

@@ -1,15 +1,15 @@
import { useStore_NotificationStatus } from "@store"; import { useStore_NotificationStatus } from "@store";
import { useI18n } from "@useI18n";
export const useNotificationStatus = () => { export const useNotificationStatus = () => {
const { currentNotificationStatus, updateNotificationStatus } = useStore_NotificationStatus(); const { currentNotificationStatus, updateNotificationStatus } = useStore_NotificationStatus();
const { t } = useI18n();
const generateRandomKey = () => Math.random();
const showNotification_Warning = (message, options = {}) => { const showNotification_Warning = (message, options = {}) => {
updateNotificationStatus({ updateNotificationStatus({
status: "warning", status: "warning",
is_open: true, is_open: true,
key: generateRandomKey(), category_id: (options.category_id) ? options.category_id : null,
message: message, message: message,
options: options, options: options,
}); });
@@ -19,7 +19,7 @@ export const useNotificationStatus = () => {
updateNotificationStatus({ updateNotificationStatus({
status: "error", status: "error",
is_open: true, is_open: true,
key: generateRandomKey(), category_id: (options.category_id) ? options.category_id : null,
message: message, message: message,
options: options, options: options,
}); });
@@ -29,12 +29,23 @@ export const useNotificationStatus = () => {
updateNotificationStatus({ updateNotificationStatus({
status: "success", status: "success",
is_open: true, is_open: true,
key: generateRandomKey(), category_id: (options.category_id) ? options.category_id : null,
message: message, message: message,
options: options, options: options,
}); });
}; };
const showNotification_SaveSuccess = (options = {}) => {
options = { hide_duration: 1000, to_hide_progress_bar: true, ...options };
updateNotificationStatus({
status: "success",
is_open: true,
category_id: "save_success",
message: t("config_page.notifications.save_success"),
options: options,
});
};
const closeNotification = () => { const closeNotification = () => {
updateNotificationStatus((prev) => ({ updateNotificationStatus((prev) => ({
...prev.data, ...prev.data,
@@ -49,6 +60,7 @@ export const useNotificationStatus = () => {
showNotification_Warning, showNotification_Warning,
showNotification_Error, showNotification_Error,
showNotification_Success, showNotification_Success,
showNotification_SaveSuccess,
closeNotification, closeNotification,
}; };
}; };

View File

@@ -10,7 +10,7 @@ import { useNotificationStatus } from "@logics_common";
export const useAdvancedSettings = () => { export const useAdvancedSettings = () => {
const { asyncStdoutToPython } = useStdoutToPython(); const { asyncStdoutToPython } = useStdoutToPython();
const { showNotification_Error } = useNotificationStatus(); const { showNotification_Error, showNotification_SaveSuccess } = useNotificationStatus();
// OSC IP Address // OSC IP Address
const { currentOscIpAddress, updateOscIpAddress, pendingOscIpAddress } = useStore_OscIpAddress(); const { currentOscIpAddress, updateOscIpAddress, pendingOscIpAddress } = useStore_OscIpAddress();
@@ -32,6 +32,11 @@ export const useAdvancedSettings = () => {
asyncStdoutToPython("/set/data/osc_ip_address", osc_ip_address); asyncStdoutToPython("/set/data/osc_ip_address", osc_ip_address);
}; };
const setSuccessOscIpAddress = (osc_ip_address) => {
updateOscIpAddress(osc_ip_address);
showNotification_SaveSuccess();
};
// OSC Port // OSC Port
const getOscPort = () => { const getOscPort = () => {
pendingOscPort(); pendingOscPort();
@@ -43,12 +48,17 @@ export const useAdvancedSettings = () => {
asyncStdoutToPython("/set/data/osc_port", osc_port); asyncStdoutToPython("/set/data/osc_port", osc_port);
}; };
const saveErrorOscPort = ({data, message, _result}) => { const setSuccessOscPort = (osc_port) => {
updateOscPort(osc_port);
showNotification_SaveSuccess();
};
const saveErrorOscPort = ({ data, message, _result }) => {
updateOscPort(d => d.data); updateOscPort(d => d.data);
showNotification_Error(_result); showNotification_Error(_result);
}; };
// WebSocket // WebSocket Enable
const getEnableWebsocket = () => { const getEnableWebsocket = () => {
pendingEnableWebsocket(); pendingEnableWebsocket();
asyncStdoutToPython("/get/data/websocket_server"); asyncStdoutToPython("/get/data/websocket_server");
@@ -63,7 +73,12 @@ export const useAdvancedSettings = () => {
} }
}; };
const setSuccessEnableWebsocket = (is_enabled) => {
updateEnableWebsocket(is_enabled);
showNotification_SaveSuccess();
};
// WebSocket Host
const getWebsocketHost = () => { const getWebsocketHost = () => {
pendingWebsocketHost(); pendingWebsocketHost();
asyncStdoutToPython("/get/data/websocket_host"); asyncStdoutToPython("/get/data/websocket_host");
@@ -74,7 +89,12 @@ export const useAdvancedSettings = () => {
asyncStdoutToPython("/set/data/websocket_host", websocket_host); asyncStdoutToPython("/set/data/websocket_host", websocket_host);
}; };
const setSuccessWebsocketHost = (websocket_host) => {
updateWebsocketHost(websocket_host);
showNotification_SaveSuccess();
};
// WebSocket Port
const getWebsocketPort = () => { const getWebsocketPort = () => {
pendingWebsocketPort(); pendingWebsocketPort();
asyncStdoutToPython("/get/data/websocket_port"); asyncStdoutToPython("/get/data/websocket_port");
@@ -85,6 +105,10 @@ export const useAdvancedSettings = () => {
asyncStdoutToPython("/set/data/websocket_port", websocket_port); asyncStdoutToPython("/set/data/websocket_port", websocket_port);
}; };
const setSuccessWebsocketPort = (websocket_port) => {
updateWebsocketPort(websocket_port);
showNotification_SaveSuccess();
};
return { return {
// OSC IP Address // OSC IP Address
@@ -92,28 +116,35 @@ export const useAdvancedSettings = () => {
getOscIpAddress, getOscIpAddress,
updateOscIpAddress, updateOscIpAddress,
setOscIpAddress, setOscIpAddress,
setSuccessOscIpAddress,
// OSC Port // OSC Port
currentOscPort, currentOscPort,
getOscPort, getOscPort,
updateOscPort, updateOscPort,
setOscPort, setOscPort,
setSuccessOscPort,
saveErrorOscPort, saveErrorOscPort,
// WebSocket // WebSocket Enable
currentEnableWebsocket, currentEnableWebsocket,
updateEnableWebsocket,
getEnableWebsocket, getEnableWebsocket,
updateEnableWebsocket,
toggleEnableWebsocket, toggleEnableWebsocket,
setSuccessEnableWebsocket,
// WebSocket Host
currentWebsocketHost, currentWebsocketHost,
updateWebsocketHost,
getWebsocketHost, getWebsocketHost,
updateWebsocketHost,
setWebsocketHost, setWebsocketHost,
setSuccessWebsocketHost,
// WebSocket Port
currentWebsocketPort, currentWebsocketPort,
updateWebsocketPort,
getWebsocketPort, getWebsocketPort,
updateWebsocketPort,
setWebsocketPort, setWebsocketPort,
setSuccessWebsocketPort,
}; };
}; };

View File

@@ -8,9 +8,13 @@ import {
useStore_Transparency, useStore_Transparency,
} from "@store"; } from "@store";
import { useStdoutToPython } from "@useStdoutToPython"; import { useStdoutToPython } from "@useStdoutToPython";
import { useI18n } from "@useI18n";
import { useNotificationStatus } from "@logics_common";
export const useAppearance = () => { export const useAppearance = () => {
const { t } = useI18n();
const { asyncStdoutToPython } = useStdoutToPython(); const { asyncStdoutToPython } = useStdoutToPython();
const { showNotification_SaveSuccess } = useNotificationStatus();
// UI Language // UI Language
const { currentUiLanguage, updateUiLanguage, pendingUiLanguage } = useStore_UiLanguage(); const { currentUiLanguage, updateUiLanguage, pendingUiLanguage } = useStore_UiLanguage();
@@ -39,6 +43,11 @@ export const useAppearance = () => {
asyncStdoutToPython("/set/data/ui_language", selected_ui_language); asyncStdoutToPython("/set/data/ui_language", selected_ui_language);
}; };
const setSuccessUiLanguage = (selected_ui_language) => {
updateUiLanguage(selected_ui_language);
showNotification_SaveSuccess();
};
// UI Scaling // UI Scaling
const getUiScaling = () => { const getUiScaling = () => {
pendingUiScaling(); pendingUiScaling();
@@ -50,6 +59,11 @@ export const useAppearance = () => {
asyncStdoutToPython("/set/data/ui_scaling", selected_ui_scaling); asyncStdoutToPython("/set/data/ui_scaling", selected_ui_scaling);
}; };
const setSuccessUiScaling = (selected_ui_scaling) => {
updateUiScaling(selected_ui_scaling);
showNotification_SaveSuccess();
};
// Message Log Ui Scaling // Message Log Ui Scaling
const getMessageLogUiScaling = () => { const getMessageLogUiScaling = () => {
pendingMessageLogUiScaling(); pendingMessageLogUiScaling();
@@ -61,6 +75,11 @@ export const useAppearance = () => {
asyncStdoutToPython("/set/data/textbox_ui_scaling", selected_ui_scaling); asyncStdoutToPython("/set/data/textbox_ui_scaling", selected_ui_scaling);
}; };
const setSuccessMessageLogUiScaling = (selected_ui_scaling) => {
updateMessageLogUiScaling(selected_ui_scaling);
showNotification_SaveSuccess();
};
// Send Message Button Type // Send Message Button Type
const getSendMessageButtonType = () => { const getSendMessageButtonType = () => {
pendingSendMessageButtonType(); pendingSendMessageButtonType();
@@ -72,6 +91,11 @@ export const useAppearance = () => {
asyncStdoutToPython("/set/data/send_message_button_type", send_message_button_type); asyncStdoutToPython("/set/data/send_message_button_type", send_message_button_type);
}; };
const setSuccessSendMessageButtonType = (send_message_button_type) => {
updateSendMessageButtonType(send_message_button_type);
showNotification_SaveSuccess();
};
// Show Resend Button // Show Resend Button
const getShowResendButton = () => { const getShowResendButton = () => {
pendingShowResendButton(); pendingShowResendButton();
@@ -86,6 +110,10 @@ export const useAppearance = () => {
asyncStdoutToPython("/set/enable/show_resend_button"); asyncStdoutToPython("/set/enable/show_resend_button");
} }
}; };
const setSuccessShowResendButton = (to_show) => {
updateShowResendButton(to_show);
showNotification_SaveSuccess();
};
// Selected Font Family // Selected Font Family
const getSelectedFontFamily = () => { const getSelectedFontFamily = () => {
@@ -98,6 +126,11 @@ export const useAppearance = () => {
asyncStdoutToPython("/set/data/font_family", selected_font_family); asyncStdoutToPython("/set/data/font_family", selected_font_family);
}; };
const setSuccessSelectedFontFamily = (selected_font_family) => {
updateSelectedFontFamily(selected_font_family);
showNotification_SaveSuccess();
};
// Transparency // Transparency
const getTransparency = () => { const getTransparency = () => {
pendingTransparency(); pendingTransparency();
@@ -109,6 +142,11 @@ export const useAppearance = () => {
asyncStdoutToPython("/set/data/transparency", selected_transparency); asyncStdoutToPython("/set/data/transparency", selected_transparency);
}; };
const setSuccessTransparency = (selected_transparency) => {
updateTransparency(selected_transparency);
showNotification_SaveSuccess();
};
return { return {
// UI Language // UI Language
@@ -116,23 +154,27 @@ export const useAppearance = () => {
getUiLanguage, getUiLanguage,
updateUiLanguage, updateUiLanguage,
setUiLanguage, setUiLanguage,
setSuccessUiLanguage,
// UI Scaling // UI Scaling
currentUiScaling, currentUiScaling,
getUiScaling, getUiScaling,
updateUiScaling, updateUiScaling,
setUiScaling, setUiScaling,
setSuccessUiScaling,
// Message Log Ui Scaling // Message Log Ui Scaling
currentMessageLogUiScaling, currentMessageLogUiScaling,
getMessageLogUiScaling, getMessageLogUiScaling,
updateMessageLogUiScaling, updateMessageLogUiScaling,
setMessageLogUiScaling, setMessageLogUiScaling,
setSuccessMessageLogUiScaling,
// Send Message Button Type // Send Message Button Type
currentSendMessageButtonType, currentSendMessageButtonType,
getSendMessageButtonType, getSendMessageButtonType,
setSendMessageButtonType, setSendMessageButtonType,
setSuccessSendMessageButtonType,
updateSendMessageButtonType, updateSendMessageButtonType,
// Show Resend Button // Show Resend Button
@@ -140,17 +182,20 @@ export const useAppearance = () => {
getShowResendButton, getShowResendButton,
updateShowResendButton, updateShowResendButton,
toggleShowResendButton, toggleShowResendButton,
setSuccessShowResendButton,
// Selected Font Family // Selected Font Family
currentSelectedFontFamily, currentSelectedFontFamily,
getSelectedFontFamily, getSelectedFontFamily,
updateSelectedFontFamily, updateSelectedFontFamily,
setSelectedFontFamily, setSelectedFontFamily,
setSuccessSelectedFontFamily,
// Transparency // Transparency
currentTransparency, currentTransparency,
getTransparency, getTransparency,
updateTransparency, updateTransparency,
setTransparency, setTransparency,
setSuccessTransparency,
}; };
}; };

View File

@@ -18,9 +18,11 @@ import {
} from "@store"; } from "@store";
import { useStdoutToPython } from "@useStdoutToPython"; import { useStdoutToPython } from "@useStdoutToPython";
import { arrayToObject } from "@utils"; import { arrayToObject } from "@utils";
import { useNotificationStatus } from "@logics_common";
export const useDevice = () => { export const useDevice = () => {
const { asyncStdoutToPython } = useStdoutToPython(); const { asyncStdoutToPython } = useStdoutToPython();
const { showNotification_SaveSuccess } = useNotificationStatus();
const { currentEnableAutoMicSelect, updateEnableAutoMicSelect, pendingEnableAutoMicSelect } = useStore_EnableAutoMicSelect(); const { currentEnableAutoMicSelect, updateEnableAutoMicSelect, pendingEnableAutoMicSelect } = useStore_EnableAutoMicSelect();
const { currentEnableAutoSpeakerSelect, updateEnableAutoSpeakerSelect, pendingEnableAutoSpeakerSelect } = useStore_EnableAutoSpeakerSelect(); const { currentEnableAutoSpeakerSelect, updateEnableAutoSpeakerSelect, pendingEnableAutoSpeakerSelect } = useStore_EnableAutoSpeakerSelect();
@@ -34,11 +36,11 @@ export const useDevice = () => {
const { currentSelectedSpeakerDevice, updateSelectedSpeakerDevice, pendingSelectedSpeakerDevice } = useStore_SelectedSpeakerDevice(); const { currentSelectedSpeakerDevice, updateSelectedSpeakerDevice, pendingSelectedSpeakerDevice } = useStore_SelectedSpeakerDevice();
const { updateMicThreshold, currentMicThreshold } = useStore_MicThreshold(); const { currentMicThreshold, updateMicThreshold } = useStore_MicThreshold();
const { updateEnableAutomaticMicThreshold, currentEnableAutomaticMicThreshold, pendingEnableAutomaticMicThreshold } = useStore_EnableAutomaticMicThreshold(); const { currentEnableAutomaticMicThreshold, updateEnableAutomaticMicThreshold, pendingEnableAutomaticMicThreshold } = useStore_EnableAutomaticMicThreshold();
const { updateSpeakerThreshold, currentSpeakerThreshold } = useStore_SpeakerThreshold(); const { currentSpeakerThreshold, updateSpeakerThreshold } = useStore_SpeakerThreshold();
const { updateEnableAutomaticSpeakerThreshold, currentEnableAutomaticSpeakerThreshold, pendingEnableAutomaticSpeakerThreshold } = useStore_EnableAutomaticSpeakerThreshold(); const { currentEnableAutomaticSpeakerThreshold, updateEnableAutomaticSpeakerThreshold, pendingEnableAutomaticSpeakerThreshold } = useStore_EnableAutomaticSpeakerThreshold();
// Auto Select (Mic) // Auto Select (Mic)
const getEnableAutoMicSelect = () => { const getEnableAutoMicSelect = () => {
@@ -54,6 +56,12 @@ export const useDevice = () => {
asyncStdoutToPython("/set/enable/auto_mic_select"); asyncStdoutToPython("/set/enable/auto_mic_select");
} }
}; };
const setSuccessEnableAutoMicSelect = (enabled) => {
updateEnableAutoMicSelect(enabled);
showNotification_SaveSuccess();
};
// Auto Select (Speaker) // Auto Select (Speaker)
const getEnableAutoSpeakerSelect = () => { const getEnableAutoSpeakerSelect = () => {
pendingEnableAutoSpeakerSelect(); pendingEnableAutoSpeakerSelect();
@@ -69,6 +77,10 @@ export const useDevice = () => {
} }
}; };
const setSuccessEnableAutoSpeakerSelect = (enabled) => {
updateEnableAutoSpeakerSelect(enabled);
showNotification_SaveSuccess();
};
// List (Mic device) // List (Mic device)
const getMicDeviceList = () => { const getMicDeviceList = () => {
@@ -79,6 +91,7 @@ export const useDevice = () => {
const updateMicDeviceList_FromBackend = (payload) => { const updateMicDeviceList_FromBackend = (payload) => {
updateMicDeviceList(arrayToObject(payload)); updateMicDeviceList(arrayToObject(payload));
}; };
// List (Mic host) // List (Mic host)
const getMicHostList = () => { const getMicHostList = () => {
pendingMicHostList(); pendingMicHostList();
@@ -88,6 +101,7 @@ export const useDevice = () => {
const updateMicHostList_FromBackend = (payload) => { const updateMicHostList_FromBackend = (payload) => {
updateMicHostList(arrayToObject(payload)); updateMicHostList(arrayToObject(payload));
}; };
// List (Speaker device) // List (Speaker device)
const getSpeakerDeviceList = () => { const getSpeakerDeviceList = () => {
pendingSpeakerDeviceList(); pendingSpeakerDeviceList();
@@ -98,7 +112,6 @@ export const useDevice = () => {
updateSpeakerDeviceList(arrayToObject(payload)); updateSpeakerDeviceList(arrayToObject(payload));
}; };
// Selected (Mic host) // Selected (Mic host)
const getSelectedMicHost = () => { const getSelectedMicHost = () => {
pendingSelectedMicHost(); pendingSelectedMicHost();
@@ -109,6 +122,12 @@ export const useDevice = () => {
pendingSelectedMicHost(); pendingSelectedMicHost();
asyncStdoutToPython("/set/data/selected_mic_host", selected_mic_host); asyncStdoutToPython("/set/data/selected_mic_host", selected_mic_host);
}; };
const setSuccessSelectedMicHost = (payload) => {
updateSelectedMicHostAndDevice(payload); // Receive host and device from backend.
showNotification_SaveSuccess();
};
// Selected (Mic device) // Selected (Mic device)
const getSelectedMicDevice = () => { const getSelectedMicDevice = () => {
pendingSelectedMicDevice(); pendingSelectedMicDevice();
@@ -120,11 +139,16 @@ export const useDevice = () => {
asyncStdoutToPython("/set/data/selected_mic_device", selected_mic_device); asyncStdoutToPython("/set/data/selected_mic_device", selected_mic_device);
}; };
// Selected (Mic and Host) const setSuccessSelectedMicDevice = (selected_mic_device) => {
updateSelectedMicDevice(selected_mic_device);
showNotification_SaveSuccess();
};
// Selected (Mic Device and Host)
const updateSelectedMicHostAndDevice = (payload) => { const updateSelectedMicHostAndDevice = (payload) => {
updateSelectedMicHost(payload.host); updateSelectedMicHost(payload.host);
updateSelectedMicDevice(payload.device); updateSelectedMicDevice(payload.device);
}; }
// Selected (Speaker device) // Selected (Speaker device)
const getSelectedSpeakerDevice = () => { const getSelectedSpeakerDevice = () => {
@@ -137,6 +161,10 @@ export const useDevice = () => {
asyncStdoutToPython("/set/data/selected_speaker_device", selected_speaker_device); asyncStdoutToPython("/set/data/selected_speaker_device", selected_speaker_device);
}; };
const setSuccessSelectedSpeakerDevice = (selected_speaker_device) => {
updateSelectedSpeakerDevice(selected_speaker_device);
showNotification_SaveSuccess();
};
// Threshold (Mic) // Threshold (Mic)
const getMicThreshold = () => { const getMicThreshold = () => {
@@ -147,6 +175,11 @@ export const useDevice = () => {
asyncStdoutToPython("/set/data/mic_threshold", mic_threshold); asyncStdoutToPython("/set/data/mic_threshold", mic_threshold);
}; };
const setSuccessMicThreshold = (mic_threshold) => {
updateMicThreshold(mic_threshold);
showNotification_SaveSuccess();
};
const getEnableAutomaticMicThreshold = () => { const getEnableAutomaticMicThreshold = () => {
pendingEnableAutomaticMicThreshold(); pendingEnableAutomaticMicThreshold();
asyncStdoutToPython("/get/data/mic_automatic_threshold"); asyncStdoutToPython("/get/data/mic_automatic_threshold");
@@ -160,6 +193,12 @@ export const useDevice = () => {
asyncStdoutToPython("/set/enable/mic_automatic_threshold"); asyncStdoutToPython("/set/enable/mic_automatic_threshold");
} }
}; };
const setSuccessEnableAutomaticMicThreshold = (enabled) => {
updateEnableAutomaticMicThreshold(enabled);
showNotification_SaveSuccess();
};
// Threshold (Speaker) // Threshold (Speaker)
const getSpeakerThreshold = () => { const getSpeakerThreshold = () => {
asyncStdoutToPython("/get/data/speaker_threshold"); asyncStdoutToPython("/get/data/speaker_threshold");
@@ -169,6 +208,11 @@ export const useDevice = () => {
asyncStdoutToPython("/set/data/speaker_threshold", speaker_threshold); asyncStdoutToPython("/set/data/speaker_threshold", speaker_threshold);
}; };
const setSuccessSpeakerThreshold = (speaker_threshold) => {
updateSpeakerThreshold(speaker_threshold);
showNotification_SaveSuccess();
};
const getEnableAutomaticSpeakerThreshold = () => { const getEnableAutomaticSpeakerThreshold = () => {
pendingEnableAutomaticSpeakerThreshold(); pendingEnableAutomaticSpeakerThreshold();
asyncStdoutToPython("/get/data/speaker_automatic_threshold"); asyncStdoutToPython("/get/data/speaker_automatic_threshold");
@@ -183,19 +227,23 @@ export const useDevice = () => {
} }
}; };
const setSuccessEnableAutomaticSpeakerThreshold = (enabled) => {
updateEnableAutomaticSpeakerThreshold(enabled);
showNotification_SaveSuccess();
};
return { return {
currentEnableAutoMicSelect, currentEnableAutoMicSelect,
getEnableAutoMicSelect, getEnableAutoMicSelect,
updateEnableAutoMicSelect, updateEnableAutoMicSelect,
toggleEnableAutoMicSelect, toggleEnableAutoMicSelect,
setSuccessEnableAutoMicSelect,
currentEnableAutoSpeakerSelect, currentEnableAutoSpeakerSelect,
getEnableAutoSpeakerSelect, getEnableAutoSpeakerSelect,
updateEnableAutoSpeakerSelect, updateEnableAutoSpeakerSelect,
toggleEnableAutoSpeakerSelect, toggleEnableAutoSpeakerSelect,
setSuccessEnableAutoSpeakerSelect,
currentMicDeviceList, currentMicDeviceList,
getMicDeviceList, getMicDeviceList,
@@ -212,46 +260,47 @@ export const useDevice = () => {
updateSpeakerDeviceList, updateSpeakerDeviceList,
updateSpeakerDeviceList_FromBackend, updateSpeakerDeviceList_FromBackend,
currentSelectedMicHost, currentSelectedMicHost,
getSelectedMicHost, getSelectedMicHost,
updateSelectedMicHost, updateSelectedMicHost,
setSelectedMicHost, setSelectedMicHost,
setSuccessSelectedMicHost,
currentSelectedMicDevice, currentSelectedMicDevice,
getSelectedMicDevice, getSelectedMicDevice,
updateSelectedMicDevice, updateSelectedMicDevice,
setSelectedMicDevice, setSelectedMicDevice,
setSuccessSelectedMicDevice,
updateSelectedMicHostAndDevice, updateSelectedMicHostAndDevice,
currentSelectedSpeakerDevice, currentSelectedSpeakerDevice,
getSelectedSpeakerDevice, getSelectedSpeakerDevice,
updateSelectedSpeakerDevice, updateSelectedSpeakerDevice,
setSelectedSpeakerDevice, setSelectedSpeakerDevice,
setSuccessSelectedSpeakerDevice,
currentMicThreshold, currentMicThreshold,
getMicThreshold, getMicThreshold,
setMicThreshold, setMicThreshold,
updateMicThreshold, updateMicThreshold,
setSuccessMicThreshold,
currentEnableAutomaticMicThreshold, currentEnableAutomaticMicThreshold,
getEnableAutomaticMicThreshold, getEnableAutomaticMicThreshold,
toggleEnableAutomaticMicThreshold, toggleEnableAutomaticMicThreshold,
updateEnableAutomaticMicThreshold, updateEnableAutomaticMicThreshold,
setSuccessEnableAutomaticMicThreshold,
currentSpeakerThreshold, currentSpeakerThreshold,
getSpeakerThreshold, getSpeakerThreshold,
setSpeakerThreshold, setSpeakerThreshold,
updateSpeakerThreshold, updateSpeakerThreshold,
setSuccessSpeakerThreshold,
currentEnableAutomaticSpeakerThreshold, currentEnableAutomaticSpeakerThreshold,
getEnableAutomaticSpeakerThreshold, getEnableAutomaticSpeakerThreshold,
toggleEnableAutomaticSpeakerThreshold, toggleEnableAutomaticSpeakerThreshold,
updateEnableAutomaticSpeakerThreshold, updateEnableAutomaticSpeakerThreshold,
setSuccessEnableAutomaticSpeakerThreshold,
}; };
}; };

View File

@@ -20,7 +20,7 @@ export const useHotkeys = () => {
pendingHotkeys(); pendingHotkeys();
asyncStdoutToPython("/get/data/hotkeys"); asyncStdoutToPython("/get/data/hotkeys");
}; };
const { showNotification_Success, showNotification_Error, closeNotification } = useNotificationStatus(); const { showNotification_SaveSuccess, showNotification_Error, closeNotification } = useNotificationStatus();
const setHotkeys = (hotkeys) => { const setHotkeys = (hotkeys) => {
pendingHotkeys(); pendingHotkeys();
@@ -106,11 +106,17 @@ export const useHotkeys = () => {
} }
}; };
const setSuccessHotkeys = (hotkeys) => {
updateHotkeys(hotkeys);
showNotification_SaveSuccess();
};
return { return {
currentHotkeys, currentHotkeys,
getHotkeys, getHotkeys,
updateHotkeys, updateHotkeys,
setHotkeys, setHotkeys,
setSuccessHotkeys,
registerShortcuts, registerShortcuts,
unregisterAll, unregisterAll,
}; };

View File

@@ -8,6 +8,7 @@ import {
useStore_EnableSendReceivedMessageToVrc, useStore_EnableSendReceivedMessageToVrc,
} from "@store"; } from "@store";
import { useStdoutToPython } from "@useStdoutToPython"; import { useStdoutToPython } from "@useStdoutToPython";
import { useNotificationStatus } from "@logics_common";
export const useOthers = () => { export const useOthers = () => {
const { asyncStdoutToPython } = useStdoutToPython(); const { asyncStdoutToPython } = useStdoutToPython();
@@ -29,6 +30,7 @@ export const useOthers = () => {
// Send Received Message To VRC // Send Received Message To VRC
const { currentEnableSendReceivedMessageToVrc, updateEnableSendReceivedMessageToVrc, pendingEnableSendReceivedMessageToVrc } = useStore_EnableSendReceivedMessageToVrc(); const { currentEnableSendReceivedMessageToVrc, updateEnableSendReceivedMessageToVrc, pendingEnableSendReceivedMessageToVrc } = useStore_EnableSendReceivedMessageToVrc();
const { showNotification_SaveSuccess } = useNotificationStatus();
// Auto Clear Message Input Box // Auto Clear Message Input Box
const getEnableAutoClearMessageInputBox = () => { const getEnableAutoClearMessageInputBox = () => {
@@ -45,6 +47,11 @@ export const useOthers = () => {
} }
}; };
const setSuccessEnableAutoClearMessageInputBox = (enabled) => {
updateEnableAutoClearMessageInputBox(enabled);
showNotification_SaveSuccess();
};
// Send Only Translated Messages // Send Only Translated Messages
const getEnableSendOnlyTranslatedMessages = () => { const getEnableSendOnlyTranslatedMessages = () => {
pendingEnableSendOnlyTranslatedMessages(); pendingEnableSendOnlyTranslatedMessages();
@@ -60,6 +67,11 @@ export const useOthers = () => {
} }
}; };
const setSuccessEnableSendOnlyTranslatedMessages = (enabled) => {
updateEnableSendOnlyTranslatedMessages(enabled);
showNotification_SaveSuccess();
};
// Auto Export Message Logs // Auto Export Message Logs
const getEnableAutoExportMessageLogs = () => { const getEnableAutoExportMessageLogs = () => {
pendingEnableAutoExportMessageLogs(); pendingEnableAutoExportMessageLogs();
@@ -75,6 +87,11 @@ export const useOthers = () => {
} }
}; };
const setSuccessEnableAutoExportMessageLogs = (enabled) => {
updateEnableAutoExportMessageLogs(enabled);
showNotification_SaveSuccess();
};
// VRC Mic Mute Sync // VRC Mic Mute Sync
const getEnableVrcMicMuteSync = () => { const getEnableVrcMicMuteSync = () => {
pendingEnableVrcMicMuteSync(); pendingEnableVrcMicMuteSync();
@@ -90,10 +107,9 @@ export const useOthers = () => {
} }
}; };
const updateEnableVrcMicMuteSync_FromBackend = (payload) => { const setSuccessEnableVrcMicMuteSync = (is_enabled) => {
updateEnableVrcMicMuteSync((old_value) => { updateEnableVrcMicMuteSync(old => ({ ...old.data, is_enabled: is_enabled }));
return {...old_value.data, is_enabled: payload}; showNotification_SaveSuccess();
});
}; };
// Send Message To VRCT // Send Message To VRCT
@@ -111,6 +127,11 @@ export const useOthers = () => {
} }
}; };
const setSuccessEnableSendMessageToVrc = (enabled) => {
updateEnableSendMessageToVrc(enabled);
showNotification_SaveSuccess();
};
// Sounds // Sounds
// Notification VRC SFX // Notification VRC SFX
const getEnableNotificationVrcSfx = () => { const getEnableNotificationVrcSfx = () => {
@@ -127,6 +148,11 @@ export const useOthers = () => {
} }
}; };
const setSuccessEnableNotificationVrcSfx = (enabled) => {
updateEnableNotificationVrcSfx(enabled);
showNotification_SaveSuccess();
};
// Speaker2Chatbox // Speaker2Chatbox
// Send Received Message To VRC // Send Received Message To VRC
const getEnableSendReceivedMessageToVrc = () => { const getEnableSendReceivedMessageToVrc = () => {
@@ -143,37 +169,46 @@ export const useOthers = () => {
} }
}; };
const setSuccessEnableSendReceivedMessageToVrc = (enabled) => {
updateEnableSendReceivedMessageToVrc(enabled);
showNotification_SaveSuccess();
};
return { return {
// Auto Clear Message Input Box // Auto Clear Message Input Box
currentEnableAutoClearMessageInputBox, currentEnableAutoClearMessageInputBox,
getEnableAutoClearMessageInputBox, getEnableAutoClearMessageInputBox,
toggleEnableAutoClearMessageInputBox, toggleEnableAutoClearMessageInputBox,
updateEnableAutoClearMessageInputBox, updateEnableAutoClearMessageInputBox,
setSuccessEnableAutoClearMessageInputBox,
// Send Only Translated Messages // Send Only Translated Messages
currentEnableSendOnlyTranslatedMessages, currentEnableSendOnlyTranslatedMessages,
getEnableSendOnlyTranslatedMessages, getEnableSendOnlyTranslatedMessages,
toggleEnableSendOnlyTranslatedMessages, toggleEnableSendOnlyTranslatedMessages,
updateEnableSendOnlyTranslatedMessages, updateEnableSendOnlyTranslatedMessages,
setSuccessEnableSendOnlyTranslatedMessages,
// Auto Export Message Logs // Auto Export Message Logs
currentEnableAutoExportMessageLogs, currentEnableAutoExportMessageLogs,
getEnableAutoExportMessageLogs, getEnableAutoExportMessageLogs,
toggleEnableAutoExportMessageLogs, toggleEnableAutoExportMessageLogs,
updateEnableAutoExportMessageLogs, updateEnableAutoExportMessageLogs,
setSuccessEnableAutoExportMessageLogs,
// VRC Mic Mute Sync // VRC Mic Mute Sync
currentEnableVrcMicMuteSync, currentEnableVrcMicMuteSync,
getEnableVrcMicMuteSync, getEnableVrcMicMuteSync,
toggleEnableVrcMicMuteSync, toggleEnableVrcMicMuteSync,
updateEnableVrcMicMuteSync, updateEnableVrcMicMuteSync,
updateEnableVrcMicMuteSync_FromBackend, setSuccessEnableVrcMicMuteSync,
// Send Message To VRCT // Send Message To VRCT
currentEnableSendMessageToVrc, currentEnableSendMessageToVrc,
getEnableSendMessageToVrc, getEnableSendMessageToVrc,
toggleEnableSendMessageToVrc, toggleEnableSendMessageToVrc,
updateEnableSendMessageToVrc, updateEnableSendMessageToVrc,
setSuccessEnableSendMessageToVrc,
// Sounds // Sounds
// Notification VRC SFX // Notification VRC SFX
@@ -181,6 +216,7 @@ export const useOthers = () => {
getEnableNotificationVrcSfx, getEnableNotificationVrcSfx,
toggleEnableNotificationVrcSfx, toggleEnableNotificationVrcSfx,
updateEnableNotificationVrcSfx, updateEnableNotificationVrcSfx,
setSuccessEnableNotificationVrcSfx,
// Speaker2Chatbox // Speaker2Chatbox
// Send Received Message To VRC // Send Received Message To VRC
@@ -188,5 +224,6 @@ export const useOthers = () => {
getEnableSendReceivedMessageToVrc, getEnableSendReceivedMessageToVrc,
toggleEnableSendReceivedMessageToVrc, toggleEnableSendReceivedMessageToVrc,
updateEnableSendReceivedMessageToVrc, updateEnableSendReceivedMessageToVrc,
setSuccessEnableSendReceivedMessageToVrc,
}; };
}; };

View File

@@ -37,7 +37,7 @@ const PLUGIN_LIST_URL = getPluginsList();
export const usePlugins = () => { export const usePlugins = () => {
const { t, i18n } = useI18n(); const { t, i18n } = useI18n();
const { showNotification_Success, showNotification_Error } = useNotificationStatus(); const { showNotification_SaveSuccess, showNotification_Success, showNotification_Error } = useNotificationStatus();
const { asyncStdoutToPython } = useStdoutToPython(); const { asyncStdoutToPython } = useStdoutToPython();
const { currentFetchedPluginsInfo, updateFetchedPluginsInfo, pendingFetchedPluginsInfo, errorFetchedPluginsInfo } = useStore_FetchedPluginsInfo(); const { currentFetchedPluginsInfo, updateFetchedPluginsInfo, pendingFetchedPluginsInfo, errorFetchedPluginsInfo } = useStore_FetchedPluginsInfo();
@@ -283,6 +283,10 @@ export const usePlugins = () => {
}; };
const toggleSavedPluginsStatus = (target_plugin_id) => { const toggleSavedPluginsStatus = (target_plugin_id) => {
const successPluginNotification = (message) => showNotification_Success(message, {
hide_duration: 1000,
category_id: "to_enable_plugin"
});
const is_exists = currentSavedPluginsStatus.data.some( const is_exists = currentSavedPluginsStatus.data.some(
(d) => d.plugin_id === target_plugin_id (d) => d.plugin_id === target_plugin_id
); );
@@ -292,8 +296,8 @@ export const usePlugins = () => {
if (d.plugin_id === target_plugin_id) { if (d.plugin_id === target_plugin_id) {
d.is_enabled = !d.is_enabled; d.is_enabled = !d.is_enabled;
(d.is_enabled) (d.is_enabled)
? showNotification_Success(t("plugin_notifications.is_enabled")) ? successPluginNotification(t("plugin_notifications.is_enabled"))
: showNotification_Success(t("plugin_notifications.is_disabled")); : successPluginNotification(t("plugin_notifications.is_disabled"));
} }
return d; return d;
}); });
@@ -303,7 +307,7 @@ export const usePlugins = () => {
plugin_id: target_plugin_id, plugin_id: target_plugin_id,
is_enabled: true, is_enabled: true,
}); });
showNotification_Success(t("plugin_notifications.is_enabled")) successPluginNotification(t("plugin_notifications.is_enabled"))
} }
// 「currentPluginsData.data」でis_downloadedがtrueのものだけ残す // 「currentPluginsData.data」でis_downloadedがtrueのものだけ残す
@@ -371,6 +375,10 @@ export const usePlugins = () => {
}); });
} }
const setSuccessSavedPluginsStatus = (plugins_status) => {
updateSavedPluginsStatus(plugins_status);
showNotification_SaveSuccess();
};
return { return {
@@ -385,6 +393,7 @@ export const usePlugins = () => {
currentSavedPluginsStatus, currentSavedPluginsStatus,
updateSavedPluginsStatus, updateSavedPluginsStatus,
setSuccessSavedPluginsStatus,
currentPluginsData, currentPluginsData,
updatePluginsData, updatePluginsData,

View File

@@ -17,9 +17,11 @@ import {
} from "@store"; } from "@store";
import { useStdoutToPython } from "@useStdoutToPython"; import { useStdoutToPython } from "@useStdoutToPython";
import { transformToIndexedArray } from "@utils"; import { transformToIndexedArray } from "@utils";
import { useNotificationStatus } from "@logics_common";
export const useTranscription = () => { export const useTranscription = () => {
const { asyncStdoutToPython } = useStdoutToPython(); const { asyncStdoutToPython } = useStdoutToPython();
const { showNotification_SaveSuccess } = useNotificationStatus();
// Mic // Mic
const { currentMicRecordTimeout, updateMicRecordTimeout, pendingMicRecordTimeout } = useStore_MicRecordTimeout(); const { currentMicRecordTimeout, updateMicRecordTimeout, pendingMicRecordTimeout } = useStore_MicRecordTimeout();
@@ -39,7 +41,6 @@ export const useTranscription = () => {
const { currentSelectableWhisperComputeDeviceList, updateSelectableWhisperComputeDeviceList, pendingSelectableWhisperComputeDeviceList } = useStore_SelectableWhisperComputeDeviceList(); const { currentSelectableWhisperComputeDeviceList, updateSelectableWhisperComputeDeviceList, pendingSelectableWhisperComputeDeviceList } = useStore_SelectableWhisperComputeDeviceList();
const { currentSelectedWhisperComputeDevice, updateSelectedWhisperComputeDevice, pendingSelectedWhisperComputeDevice } = useStore_SelectedWhisperComputeDevice(); const { currentSelectedWhisperComputeDevice, updateSelectedWhisperComputeDevice, pendingSelectedWhisperComputeDevice } = useStore_SelectedWhisperComputeDevice();
// Mic // Mic
const getMicRecordTimeout = () => { const getMicRecordTimeout = () => {
pendingMicRecordTimeout(); pendingMicRecordTimeout();
@@ -51,6 +52,10 @@ export const useTranscription = () => {
asyncStdoutToPython("/set/data/mic_record_timeout", selected_mic_record_timeout); asyncStdoutToPython("/set/data/mic_record_timeout", selected_mic_record_timeout);
}; };
const setSuccessMicRecordTimeout = (value) => {
updateMicRecordTimeout(value);
showNotification_SaveSuccess();
};
const getMicPhraseTimeout = () => { const getMicPhraseTimeout = () => {
pendingMicPhraseTimeout(); pendingMicPhraseTimeout();
@@ -62,6 +67,10 @@ export const useTranscription = () => {
asyncStdoutToPython("/set/data/mic_phrase_timeout", selected_mic_phrase_timeout); asyncStdoutToPython("/set/data/mic_phrase_timeout", selected_mic_phrase_timeout);
}; };
const setSuccessMicPhraseTimeout = (value) => {
updateMicPhraseTimeout(value);
showNotification_SaveSuccess();
};
const getMicMaxWords = () => { const getMicMaxWords = () => {
pendingMicMaxWords(); pendingMicMaxWords();
@@ -73,6 +82,11 @@ export const useTranscription = () => {
asyncStdoutToPython("/set/data/mic_max_phrases", selected_mic_max_phrases); asyncStdoutToPython("/set/data/mic_max_phrases", selected_mic_max_phrases);
}; };
const setSuccessMicMaxWords = (value) => {
updateMicMaxWords(value);
showNotification_SaveSuccess();
};
const getMicWordFilterList = () => { const getMicWordFilterList = () => {
pendingMicWordFilterList(); pendingMicWordFilterList();
asyncStdoutToPython("/get/data/mic_word_filter"); asyncStdoutToPython("/get/data/mic_word_filter");
@@ -83,7 +97,7 @@ export const useTranscription = () => {
asyncStdoutToPython("/set/data/mic_word_filter", selected_mic_word_filter); asyncStdoutToPython("/set/data/mic_word_filter", selected_mic_word_filter);
}; };
const updateMicWordFilterList_FromBackend = (payload) => { const setSuccessMicWordFilterList = (payload) => {
updateMicWordFilterList((prev_list) => { updateMicWordFilterList((prev_list) => {
const updated_list = [...prev_list.data]; const updated_list = [...prev_list.data];
for (const value of payload) { for (const value of payload) {
@@ -96,6 +110,7 @@ export const useTranscription = () => {
} }
return updated_list; return updated_list;
}); });
showNotification_SaveSuccess();
}; };
// Speaker // Speaker
@@ -109,6 +124,10 @@ export const useTranscription = () => {
asyncStdoutToPython("/set/data/speaker_record_timeout", selected_speaker_record_timeout); asyncStdoutToPython("/set/data/speaker_record_timeout", selected_speaker_record_timeout);
}; };
const setSuccessSpeakerRecordTimeout = (value) => {
updateSpeakerRecordTimeout(value);
showNotification_SaveSuccess();
};
const getSpeakerPhraseTimeout = () => { const getSpeakerPhraseTimeout = () => {
pendingSpeakerPhraseTimeout(); pendingSpeakerPhraseTimeout();
@@ -120,6 +139,10 @@ export const useTranscription = () => {
asyncStdoutToPython("/set/data/speaker_phrase_timeout", selected_speaker_phrase_timeout); asyncStdoutToPython("/set/data/speaker_phrase_timeout", selected_speaker_phrase_timeout);
}; };
const setSuccessSpeakerPhraseTimeout = (value) => {
updateSpeakerPhraseTimeout(value);
showNotification_SaveSuccess();
};
const getSpeakerMaxWords = () => { const getSpeakerMaxWords = () => {
pendingSpeakerMaxWords(); pendingSpeakerMaxWords();
@@ -131,6 +154,10 @@ export const useTranscription = () => {
asyncStdoutToPython("/set/data/speaker_max_phrases", selected_speaker_max_phrases); asyncStdoutToPython("/set/data/speaker_max_phrases", selected_speaker_max_phrases);
}; };
const setSuccessSpeakerMaxWords = (value) => {
updateSpeakerMaxWords(value);
showNotification_SaveSuccess();
};
// Transcription Engines // Transcription Engines
// Transcription Engines (Google / Whisper) // Transcription Engines (Google / Whisper)
@@ -144,6 +171,10 @@ export const useTranscription = () => {
asyncStdoutToPython("/set/data/selected_transcription_engine", selected_transcription_engine); asyncStdoutToPython("/set/data/selected_transcription_engine", selected_transcription_engine);
}; };
const setSuccessSelectedTranscriptionEngine = (engine) => {
updateSelectedTranscriptionEngine(engine);
showNotification_SaveSuccess();
};
// Transcription Engines (Weight Type List) // Transcription Engines (Weight Type List)
const updateDownloadedWhisperWeightTypeStatus = (downloaded_weight_type_status) => { const updateDownloadedWhisperWeightTypeStatus = (downloaded_weight_type_status) => {
@@ -199,6 +230,10 @@ export const useTranscription = () => {
asyncStdoutToPython("/set/data/whisper_weight_type", selected_whisper_weight_type); asyncStdoutToPython("/set/data/whisper_weight_type", selected_whisper_weight_type);
}; };
const setSuccessSelectedWhisperWeightType = (wt) => {
updateSelectedWhisperWeightType(wt);
showNotification_SaveSuccess();
};
// Transcription Engines (Compute Device List) // Transcription Engines (Compute Device List)
const getSelectableWhisperComputeDeviceList = () => { const getSelectableWhisperComputeDeviceList = () => {
@@ -221,50 +256,62 @@ export const useTranscription = () => {
asyncStdoutToPython("/set/data/selected_transcription_compute_device", selected_transcription_compute_device); asyncStdoutToPython("/set/data/selected_transcription_compute_device", selected_transcription_compute_device);
}; };
const setSuccessSelectedWhisperComputeDevice = (dev) => {
updateSelectedWhisperComputeDevice(dev);
showNotification_SaveSuccess();
};
return { return {
// Mic // Mic
currentMicRecordTimeout, currentMicRecordTimeout,
getMicRecordTimeout, getMicRecordTimeout,
updateMicRecordTimeout, updateMicRecordTimeout,
setMicRecordTimeout, setMicRecordTimeout,
setSuccessMicRecordTimeout,
currentMicPhraseTimeout, currentMicPhraseTimeout,
getMicPhraseTimeout, getMicPhraseTimeout,
updateMicPhraseTimeout, updateMicPhraseTimeout,
setMicPhraseTimeout, setMicPhraseTimeout,
setSuccessMicPhraseTimeout,
currentMicMaxWords, currentMicMaxWords,
getMicMaxWords, getMicMaxWords,
updateMicMaxWords, updateMicMaxWords,
setMicMaxWords, setMicMaxWords,
setSuccessMicMaxWords,
currentMicWordFilterList, currentMicWordFilterList,
getMicWordFilterList, getMicWordFilterList,
updateMicWordFilterList, updateMicWordFilterList,
setMicWordFilterList, setMicWordFilterList,
updateMicWordFilterList_FromBackend, setSuccessMicWordFilterList,
// Speaker // Speaker
currentSpeakerRecordTimeout, currentSpeakerRecordTimeout,
getSpeakerRecordTimeout, getSpeakerRecordTimeout,
updateSpeakerRecordTimeout, updateSpeakerRecordTimeout,
setSpeakerRecordTimeout, setSpeakerRecordTimeout,
setSuccessSpeakerRecordTimeout,
currentSpeakerPhraseTimeout, currentSpeakerPhraseTimeout,
getSpeakerPhraseTimeout, getSpeakerPhraseTimeout,
updateSpeakerPhraseTimeout, updateSpeakerPhraseTimeout,
setSpeakerPhraseTimeout, setSpeakerPhraseTimeout,
setSuccessSpeakerPhraseTimeout,
currentSpeakerMaxWords, currentSpeakerMaxWords,
getSpeakerMaxWords, getSpeakerMaxWords,
updateSpeakerMaxWords, updateSpeakerMaxWords,
setSpeakerMaxWords, setSpeakerMaxWords,
setSuccessSpeakerMaxWords,
// Transcription Engines // Transcription Engines
currentSelectedTranscriptionEngine, currentSelectedTranscriptionEngine,
getSelectedTranscriptionEngine, getSelectedTranscriptionEngine,
updateSelectedTranscriptionEngine, updateSelectedTranscriptionEngine,
setSelectedTranscriptionEngine, setSelectedTranscriptionEngine,
setSuccessSelectedTranscriptionEngine,
currentWhisperWeightTypeStatus, currentWhisperWeightTypeStatus,
updateWhisperWeightTypeStatus, updateWhisperWeightTypeStatus,
@@ -278,6 +325,7 @@ export const useTranscription = () => {
getSelectedWhisperWeightType, getSelectedWhisperWeightType,
updateSelectedWhisperWeightType, updateSelectedWhisperWeightType,
setSelectedWhisperWeightType, setSelectedWhisperWeightType,
setSuccessSelectedWhisperWeightType,
currentSelectableWhisperComputeDeviceList, currentSelectableWhisperComputeDeviceList,
getSelectableWhisperComputeDeviceList, getSelectableWhisperComputeDeviceList,
@@ -288,5 +336,6 @@ export const useTranscription = () => {
getSelectedWhisperComputeDevice, getSelectedWhisperComputeDevice,
updateSelectedWhisperComputeDevice, updateSelectedWhisperComputeDevice,
setSelectedWhisperComputeDevice, setSelectedWhisperComputeDevice,
setSuccessSelectedWhisperComputeDevice,
}; };
}; };

View File

@@ -13,7 +13,7 @@ import { useNotificationStatus } from "@logics_common";
export const useTranslation = () => { export const useTranslation = () => {
const { t } = useI18n(); const { t } = useI18n();
const { asyncStdoutToPython } = useStdoutToPython(); const { asyncStdoutToPython } = useStdoutToPython();
const { showNotification_Success, showNotification_Error } = useNotificationStatus(); const { showNotification_SaveSuccess } = useNotificationStatus();
const { currentCTranslate2WeightTypeStatus, updateCTranslate2WeightTypeStatus, pendingCTranslate2WeightTypeStatus } = useStore_CTranslate2WeightTypeStatus(); const { currentCTranslate2WeightTypeStatus, updateCTranslate2WeightTypeStatus, pendingCTranslate2WeightTypeStatus } = useStore_CTranslate2WeightTypeStatus();
const { currentSelectedCTranslate2WeightType, updateSelectedCTranslate2WeightType, pendingSelectedCTranslate2WeightType } = useStore_SelectedCTranslate2WeightType(); const { currentSelectedCTranslate2WeightType, updateSelectedCTranslate2WeightType, pendingSelectedCTranslate2WeightType } = useStore_SelectedCTranslate2WeightType();
@@ -74,6 +74,11 @@ export const useTranslation = () => {
asyncStdoutToPython("/set/data/ctranslate2_weight_type", selected_ctranslate2_weight_type); asyncStdoutToPython("/set/data/ctranslate2_weight_type", selected_ctranslate2_weight_type);
}; };
const setSuccessSelectedCTranslate2WeightType = (selected_ctranslate2_weight_type) => {
updateSelectedCTranslate2WeightType(selected_ctranslate2_weight_type);
showNotification_SaveSuccess();
};
const getSelectableCTranslate2ComputeDeviceList = () => { const getSelectableCTranslate2ComputeDeviceList = () => {
pendingSelectableCTranslate2ComputeDeviceList(); pendingSelectableCTranslate2ComputeDeviceList();
@@ -95,6 +100,11 @@ export const useTranslation = () => {
asyncStdoutToPython("/set/data/selected_translation_compute_device", selected_translation_compute_device); asyncStdoutToPython("/set/data/selected_translation_compute_device", selected_translation_compute_device);
}; };
const setSuccessSelectedCTranslate2ComputeDevice = (selected_translation_compute_device) => {
updateSelectedCTranslate2ComputeDevice(selected_translation_compute_device);
showNotification_SaveSuccess();
};
const getDeepLAuthKey = () => { const getDeepLAuthKey = () => {
pendingDeepLAuthKey(); pendingDeepLAuthKey();
@@ -106,17 +116,18 @@ export const useTranslation = () => {
asyncStdoutToPython("/set/data/deepl_auth_key", selected_deepl_auth_key); asyncStdoutToPython("/set/data/deepl_auth_key", selected_deepl_auth_key);
}; };
const setSuccessDeepLAuthKey = (data) => {
updateDeepLAuthKey(data);
showNotification_SaveSuccess(t("config_page.translation.deepl_auth_key.auth_key_success"), { category_id: "deepl_auth_key" });
};
const deleteDeepLAuthKey = () => { const deleteDeepLAuthKey = () => {
pendingDeepLAuthKey(); pendingDeepLAuthKey();
asyncStdoutToPython("/delete/data/deepl_auth_key"); asyncStdoutToPython("/delete/data/deepl_auth_key");
}; };
const deletedDeepLAuthKey = () => {
updateDeepLAuthKey("");
};
const savedDeepLAuthKey = (data) => { const deleteSuccessDeepLAuthKey = () => {
updateDeepLAuthKey(data); updateDeepLAuthKey("");
showNotification_Success(t("config_page.translation.deepl_auth_key.auth_key_success"));
}; };
@@ -133,6 +144,7 @@ export const useTranslation = () => {
getSelectedCTranslate2WeightType, getSelectedCTranslate2WeightType,
updateSelectedCTranslate2WeightType, updateSelectedCTranslate2WeightType,
setSelectedCTranslate2WeightType, setSelectedCTranslate2WeightType,
setSuccessSelectedCTranslate2WeightType,
currentSelectableCTranslate2ComputeDeviceList, currentSelectableCTranslate2ComputeDeviceList,
getSelectableCTranslate2ComputeDeviceList, getSelectableCTranslate2ComputeDeviceList,
@@ -143,13 +155,14 @@ export const useTranslation = () => {
getSelectedCTranslate2ComputeDevice, getSelectedCTranslate2ComputeDevice,
updateSelectedCTranslate2ComputeDevice, updateSelectedCTranslate2ComputeDevice,
setSelectedCTranslate2ComputeDevice, setSelectedCTranslate2ComputeDevice,
setSuccessSelectedCTranslate2ComputeDevice,
currentDeepLAuthKey, currentDeepLAuthKey,
getDeepLAuthKey, getDeepLAuthKey,
updateDeepLAuthKey, updateDeepLAuthKey,
setDeepLAuthKey, setDeepLAuthKey,
deleteDeepLAuthKey, deleteDeepLAuthKey,
deletedDeepLAuthKey, deleteSuccessDeepLAuthKey,
savedDeepLAuthKey, setSuccessDeepLAuthKey,
}; };
}; };

View File

@@ -6,9 +6,11 @@ import {
useStore_OverlayShowOnlyTranslatedMessages, useStore_OverlayShowOnlyTranslatedMessages,
} from "@store"; } from "@store";
import { useStdoutToPython } from "@useStdoutToPython"; import { useStdoutToPython } from "@useStdoutToPython";
import { useNotificationStatus } from "@logics_common";
export const useVr = () => { export const useVr = () => {
const { asyncStdoutToPython } = useStdoutToPython(); const { asyncStdoutToPython } = useStdoutToPython();
const { showNotification_SaveSuccess } = useNotificationStatus();
const { currentIsEnabledOverlaySmallLog, updateIsEnabledOverlaySmallLog, pendingIsEnabledOverlaySmallLog } = useStore_IsEnabledOverlaySmallLog(); const { currentIsEnabledOverlaySmallLog, updateIsEnabledOverlaySmallLog, pendingIsEnabledOverlaySmallLog } = useStore_IsEnabledOverlaySmallLog();
const { currentIsEnabledOverlayLargeLog, updateIsEnabledOverlayLargeLog, pendingIsEnabledOverlayLargeLog } = useStore_IsEnabledOverlayLargeLog(); const { currentIsEnabledOverlayLargeLog, updateIsEnabledOverlayLargeLog, pendingIsEnabledOverlayLargeLog } = useStore_IsEnabledOverlayLargeLog();
@@ -16,7 +18,6 @@ export const useVr = () => {
const { currentOverlayLargeLogSettings, updateOverlayLargeLogSettings, pendingOverlayLargeLogSettings } = useStore_OverlayLargeLogSettings(); const { currentOverlayLargeLogSettings, updateOverlayLargeLogSettings, pendingOverlayLargeLogSettings } = useStore_OverlayLargeLogSettings();
const { currentOverlayShowOnlyTranslatedMessages, updateOverlayShowOnlyTranslatedMessages, pendingOverlayShowOnlyTranslatedMessages } = useStore_OverlayShowOnlyTranslatedMessages(); const { currentOverlayShowOnlyTranslatedMessages, updateOverlayShowOnlyTranslatedMessages, pendingOverlayShowOnlyTranslatedMessages } = useStore_OverlayShowOnlyTranslatedMessages();
const getIsEnabledOverlaySmallLog = () => { const getIsEnabledOverlaySmallLog = () => {
pendingIsEnabledOverlaySmallLog(); pendingIsEnabledOverlaySmallLog();
asyncStdoutToPython("/get/data/overlay_small_log"); asyncStdoutToPython("/get/data/overlay_small_log");
@@ -31,6 +32,10 @@ export const useVr = () => {
} }
}; };
const setSuccessIsEnabledOverlaySmallLog = (enabled) => {
updateIsEnabledOverlaySmallLog(enabled);
showNotification_SaveSuccess();
};
const getIsEnabledOverlayLargeLog = () => { const getIsEnabledOverlayLargeLog = () => {
pendingIsEnabledOverlayLargeLog(); pendingIsEnabledOverlayLargeLog();
@@ -46,6 +51,10 @@ export const useVr = () => {
} }
}; };
const setSuccessIsEnabledOverlayLargeLog = (enabled) => {
updateIsEnabledOverlayLargeLog(enabled);
showNotification_SaveSuccess();
};
const getOverlaySmallLogSettings = () => { const getOverlaySmallLogSettings = () => {
// pendingOverlaySmallLogSettings(); // pendingOverlaySmallLogSettings();
@@ -57,6 +66,10 @@ export const useVr = () => {
asyncStdoutToPython("/set/data/overlay_small_log_settings", overlay_small_log_settings); asyncStdoutToPython("/set/data/overlay_small_log_settings", overlay_small_log_settings);
}; };
const setSuccessOverlaySmallLogSettings = (settings) => {
updateOverlaySmallLogSettings(settings);
showNotification_SaveSuccess();
};
const getOverlayLargeLogSettings = () => { const getOverlayLargeLogSettings = () => {
// pendingOverlayLargeLogSettings(); // pendingOverlayLargeLogSettings();
@@ -68,6 +81,10 @@ export const useVr = () => {
asyncStdoutToPython("/set/data/overlay_large_log_settings", overlay_large_log_settings); asyncStdoutToPython("/set/data/overlay_large_log_settings", overlay_large_log_settings);
}; };
const setSuccessOverlayLargeLogSettings = (settings) => {
updateOverlayLargeLogSettings(settings);
showNotification_SaveSuccess();
};
const getOverlayShowOnlyTranslatedMessages = () => { const getOverlayShowOnlyTranslatedMessages = () => {
pendingOverlayShowOnlyTranslatedMessages(); pendingOverlayShowOnlyTranslatedMessages();
@@ -83,37 +100,45 @@ export const useVr = () => {
} }
}; };
const setSuccessOverlayShowOnlyTranslatedMessages = (enabled) => {
updateOverlayShowOnlyTranslatedMessages(enabled);
showNotification_SaveSuccess();
};
const sendTextToOverlay = (text) => { const sendTextToOverlay = (text) => {
asyncStdoutToPython("/run/send_text_overlay", text); asyncStdoutToPython("/run/send_text_overlay", text);
}; };
return { return {
currentIsEnabledOverlaySmallLog, currentIsEnabledOverlaySmallLog,
getIsEnabledOverlaySmallLog, getIsEnabledOverlaySmallLog,
updateIsEnabledOverlaySmallLog,
toggleIsEnabledOverlaySmallLog, toggleIsEnabledOverlaySmallLog,
updateIsEnabledOverlaySmallLog,
setSuccessIsEnabledOverlaySmallLog,
currentIsEnabledOverlayLargeLog, currentIsEnabledOverlayLargeLog,
getIsEnabledOverlayLargeLog, getIsEnabledOverlayLargeLog,
updateIsEnabledOverlayLargeLog,
toggleIsEnabledOverlayLargeLog, toggleIsEnabledOverlayLargeLog,
updateIsEnabledOverlayLargeLog,
setSuccessIsEnabledOverlayLargeLog,
currentOverlaySmallLogSettings, currentOverlaySmallLogSettings,
getOverlaySmallLogSettings, getOverlaySmallLogSettings,
updateOverlaySmallLogSettings, updateOverlaySmallLogSettings,
setOverlaySmallLogSettings, setOverlaySmallLogSettings,
setSuccessOverlaySmallLogSettings,
currentOverlayLargeLogSettings, currentOverlayLargeLogSettings,
getOverlayLargeLogSettings, getOverlayLargeLogSettings,
updateOverlayLargeLogSettings, updateOverlayLargeLogSettings,
setOverlayLargeLogSettings, setOverlayLargeLogSettings,
setSuccessOverlayLargeLogSettings,
currentOverlayShowOnlyTranslatedMessages, currentOverlayShowOnlyTranslatedMessages,
getOverlayShowOnlyTranslatedMessages, getOverlayShowOnlyTranslatedMessages,
updateOverlayShowOnlyTranslatedMessages,
toggleOverlayShowOnlyTranslatedMessages, toggleOverlayShowOnlyTranslatedMessages,
updateOverlayShowOnlyTranslatedMessages,
setSuccessOverlayShowOnlyTranslatedMessages,
sendTextToOverlay, sendTextToOverlay,
}; };

View File

@@ -92,25 +92,25 @@ export const ROUTE_META_LIST = [
// Config Page // Config Page
// Device // Device
{ endpoint: "/get/data/auto_mic_select", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutoMicSelect" }, { endpoint: "/get/data/auto_mic_select", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutoMicSelect" },
{ endpoint: "/set/enable/auto_mic_select", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutoMicSelect" }, { endpoint: "/set/enable/auto_mic_select", ns: configs, hook_name: "useDevice", method_name: "setSuccessEnableAutoMicSelect" },
{ endpoint: "/set/disable/auto_mic_select", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutoMicSelect" }, { endpoint: "/set/disable/auto_mic_select", ns: configs, hook_name: "useDevice", method_name: "setSuccessEnableAutoMicSelect" },
{ endpoint: "/get/data/auto_speaker_select", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutoSpeakerSelect" }, { endpoint: "/get/data/auto_speaker_select", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutoSpeakerSelect" },
{ endpoint: "/set/enable/auto_speaker_select", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutoSpeakerSelect" }, { endpoint: "/set/enable/auto_speaker_select", ns: configs, hook_name: "useDevice", method_name: "setSuccessEnableAutoSpeakerSelect" },
{ endpoint: "/set/disable/auto_speaker_select", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutoSpeakerSelect" }, { endpoint: "/set/disable/auto_speaker_select", ns: configs, hook_name: "useDevice", method_name: "setSuccessEnableAutoSpeakerSelect" },
// Device (Mic) // Device (Mic)
{ endpoint: "/get/data/mic_host_list", ns: configs, hook_name: "useDevice", method_name: "updateMicHostList_FromBackend" }, { endpoint: "/get/data/mic_host_list", ns: configs, hook_name: "useDevice", method_name: "updateMicHostList_FromBackend" },
{ endpoint: "/run/mic_host_list", ns: configs, hook_name: "useDevice", method_name: "updateMicHostList_FromBackend" }, { endpoint: "/run/mic_host_list", ns: configs, hook_name: "useDevice", method_name: "updateMicHostList_FromBackend" },
{ endpoint: "/get/data/selected_mic_host", ns: configs, hook_name: "useDevice", method_name: "updateSelectedMicHost" }, { endpoint: "/get/data/selected_mic_host", ns: configs, hook_name: "useDevice", method_name: "updateSelectedMicHost" },
{ endpoint: "/set/data/selected_mic_host", ns: configs, hook_name: "useDevice", method_name: "updateSelectedMicHostAndDevice" }, { endpoint: "/set/data/selected_mic_host", ns: configs, hook_name: "useDevice", method_name: "setSuccessSelectedMicHost" },
{ endpoint: "/get/data/mic_device_list", ns: configs, hook_name: "useDevice", method_name: "updateMicDeviceList_FromBackend" }, { endpoint: "/get/data/mic_device_list", ns: configs, hook_name: "useDevice", method_name: "updateMicDeviceList_FromBackend" },
{ endpoint: "/run/mic_device_list", ns: configs, hook_name: "useDevice", method_name: "updateMicDeviceList_FromBackend" }, { endpoint: "/run/mic_device_list", ns: configs, hook_name: "useDevice", method_name: "updateMicDeviceList_FromBackend" },
{ endpoint: "/get/data/selected_mic_device", ns: configs, hook_name: "useDevice", method_name: "updateSelectedMicDevice" }, { endpoint: "/get/data/selected_mic_device", ns: configs, hook_name: "useDevice", method_name: "updateSelectedMicDevice" },
{ endpoint: "/set/data/selected_mic_device", ns: configs, hook_name: "useDevice", method_name: "updateSelectedMicDevice" }, { endpoint: "/set/data/selected_mic_device", ns: configs, hook_name: "useDevice", method_name: "setSuccessSelectedMicDevice" },
{ endpoint: "/run/selected_mic_device", ns: configs, hook_name: "useDevice", method_name: "updateSelectedMicHostAndDevice" }, { endpoint: "/run/selected_mic_device", ns: configs, hook_name: "useDevice", method_name: "updateSelectedMicHostAndDevice" },
@@ -119,54 +119,54 @@ export const ROUTE_META_LIST = [
{ endpoint: "/run/speaker_device_list", ns: configs, hook_name: "useDevice", method_name: "updateSpeakerDeviceList_FromBackend" }, { endpoint: "/run/speaker_device_list", ns: configs, hook_name: "useDevice", method_name: "updateSpeakerDeviceList_FromBackend" },
{ endpoint: "/get/data/selected_speaker_device", ns: configs, hook_name: "useDevice", method_name: "updateSelectedSpeakerDevice" }, { endpoint: "/get/data/selected_speaker_device", ns: configs, hook_name: "useDevice", method_name: "updateSelectedSpeakerDevice" },
{ endpoint: "/set/data/selected_speaker_device", ns: configs, hook_name: "useDevice", method_name: "updateSelectedSpeakerDevice" }, { endpoint: "/set/data/selected_speaker_device", ns: configs, hook_name: "useDevice", method_name: "setSuccessSelectedSpeakerDevice" },
{ endpoint: "/run/selected_speaker_device", ns: configs, hook_name: "useDevice", method_name: "updateSelectedSpeakerDevice" }, { endpoint: "/run/selected_speaker_device", ns: configs, hook_name: "useDevice", method_name: "updateSelectedSpeakerDevice" },
// Device (Threshold) // Device (Threshold)
{ endpoint: "/get/data/mic_threshold", ns: configs, hook_name: "useDevice", method_name: "updateMicThreshold" }, { endpoint: "/get/data/mic_threshold", ns: configs, hook_name: "useDevice", method_name: "updateMicThreshold" },
{ endpoint: "/set/data/mic_threshold", ns: configs, hook_name: "useDevice", method_name: "updateMicThreshold" }, { endpoint: "/set/data/mic_threshold", ns: configs, hook_name: "useDevice", method_name: "setSuccessMicThreshold" },
{ endpoint: "/get/data/speaker_threshold", ns: configs, hook_name: "useDevice", method_name: "updateSpeakerThreshold" }, { endpoint: "/get/data/speaker_threshold", ns: configs, hook_name: "useDevice", method_name: "updateSpeakerThreshold" },
{ endpoint: "/set/data/speaker_threshold", ns: configs, hook_name: "useDevice", method_name: "updateSpeakerThreshold" }, { endpoint: "/set/data/speaker_threshold", ns: configs, hook_name: "useDevice", method_name: "setSuccessSpeakerThreshold" },
{ endpoint: "/get/data/mic_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutomaticMicThreshold" }, { endpoint: "/get/data/mic_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutomaticMicThreshold" },
{ endpoint: "/set/enable/mic_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutomaticMicThreshold" }, { endpoint: "/set/enable/mic_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "setSuccessEnableAutomaticMicThreshold" },
{ endpoint: "/set/disable/mic_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutomaticMicThreshold" }, { endpoint: "/set/disable/mic_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "setSuccessEnableAutomaticMicThreshold" },
{ endpoint: "/get/data/speaker_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutomaticSpeakerThreshold" }, { endpoint: "/get/data/speaker_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutomaticSpeakerThreshold" },
{ endpoint: "/set/enable/speaker_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutomaticSpeakerThreshold" }, { endpoint: "/set/enable/speaker_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "setSuccessEnableAutomaticSpeakerThreshold" },
{ endpoint: "/set/disable/speaker_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "updateEnableAutomaticSpeakerThreshold" }, { endpoint: "/set/disable/speaker_automatic_threshold", ns: configs, hook_name: "useDevice", method_name: "setSuccessEnableAutomaticSpeakerThreshold" },
// Appearance // Appearance
{ endpoint: "/get/data/ui_language", ns: configs, hook_name: "useAppearance", method_name: "updateUiLanguage" }, { endpoint: "/get/data/ui_language", ns: configs, hook_name: "useAppearance", method_name: "updateUiLanguage" },
{ endpoint: "/set/data/ui_language", ns: configs, hook_name: "useAppearance", method_name: "updateUiLanguage" }, { endpoint: "/set/data/ui_language", ns: configs, hook_name: "useAppearance", method_name: "setSuccessUiLanguage" },
{ endpoint: "/get/data/ui_scaling", ns: configs, hook_name: "useAppearance", method_name: "updateUiScaling" }, { endpoint: "/get/data/ui_scaling", ns: configs, hook_name: "useAppearance", method_name: "updateUiScaling" },
{ endpoint: "/set/data/ui_scaling", ns: configs, hook_name: "useAppearance", method_name: "updateUiScaling" }, { endpoint: "/set/data/ui_scaling", ns: configs, hook_name: "useAppearance", method_name: "setSuccessUiScaling" },
{ endpoint: "/get/data/textbox_ui_scaling", ns: configs, hook_name: "useAppearance", method_name: "updateMessageLogUiScaling" }, { endpoint: "/get/data/textbox_ui_scaling", ns: configs, hook_name: "useAppearance", method_name: "updateMessageLogUiScaling" },
{ endpoint: "/set/data/textbox_ui_scaling", ns: configs, hook_name: "useAppearance", method_name: "updateMessageLogUiScaling" }, { endpoint: "/set/data/textbox_ui_scaling", ns: configs, hook_name: "useAppearance", method_name: "setSuccessMessageLogUiScaling" },
{ endpoint: "/get/data/send_message_button_type", ns: configs, hook_name: "useAppearance", method_name: "updateSendMessageButtonType" }, { endpoint: "/get/data/send_message_button_type", ns: configs, hook_name: "useAppearance", method_name: "updateSendMessageButtonType" },
{ endpoint: "/set/data/send_message_button_type", ns: configs, hook_name: "useAppearance", method_name: "updateSendMessageButtonType" }, { endpoint: "/set/data/send_message_button_type", ns: configs, hook_name: "useAppearance", method_name: "setSuccessSendMessageButtonType" },
{ endpoint: "/get/data/show_resend_button", ns: configs, hook_name: "useAppearance", method_name: "updateShowResendButton" }, { endpoint: "/get/data/show_resend_button", ns: configs, hook_name: "useAppearance", method_name: "updateShowResendButton" },
{ endpoint: "/set/enable/show_resend_button", ns: configs, hook_name: "useAppearance", method_name: "updateShowResendButton" }, { endpoint: "/set/enable/show_resend_button", ns: configs, hook_name: "useAppearance", method_name: "setSuccessShowResendButton" },
{ endpoint: "/set/disable/show_resend_button", ns: configs, hook_name: "useAppearance", method_name: "updateShowResendButton" }, { endpoint: "/set/disable/show_resend_button", ns: configs, hook_name: "useAppearance", method_name: "setSuccessShowResendButton" },
{ endpoint: "/get/data/font_family", ns: configs, hook_name: "useAppearance", method_name: "updateSelectedFontFamily" }, { endpoint: "/get/data/font_family", ns: configs, hook_name: "useAppearance", method_name: "updateSelectedFontFamily" },
{ endpoint: "/set/data/font_family", ns: configs, hook_name: "useAppearance", method_name: "updateSelectedFontFamily" }, { endpoint: "/set/data/font_family", ns: configs, hook_name: "useAppearance", method_name: "setSuccessSelectedFontFamily" },
{ endpoint: "/get/data/transparency", ns: configs, hook_name: "useAppearance", method_name: "updateTransparency" }, { endpoint: "/get/data/transparency", ns: configs, hook_name: "useAppearance", method_name: "updateTransparency" },
{ endpoint: "/set/data/transparency", ns: configs, hook_name: "useAppearance", method_name: "updateTransparency" }, { endpoint: "/set/data/transparency", ns: configs, hook_name: "useAppearance", method_name: "setSuccessTransparency" },
// Translation // Translation
{ endpoint: "/get/data/deepl_auth_key", ns: configs, hook_name: "useTranslation", method_name: "updateDeepLAuthKey" }, { endpoint: "/get/data/deepl_auth_key", ns: configs, hook_name: "useTranslation", method_name: "updateDeepLAuthKey" },
{ endpoint: "/set/data/deepl_auth_key", ns: configs, hook_name: "useTranslation", method_name: "savedDeepLAuthKey" }, { endpoint: "/set/data/deepl_auth_key", ns: configs, hook_name: "useTranslation", method_name: "setSuccessDeepLAuthKey" },
{ endpoint: "/delete/data/deepl_auth_key", ns: configs, hook_name: "useTranslation", method_name: "deletedDeepLAuthKey" }, { endpoint: "/delete/data/deepl_auth_key", ns: configs, hook_name: "useTranslation", method_name: "deleteSuccessDeepLAuthKey" },
// Translation (AI Models) // Translation (AI Models)
{ endpoint: "/get/data/ctranslate2_weight_type", ns: configs, hook_name: "useTranslation", method_name: "updateSelectedCTranslate2WeightType" }, { endpoint: "/get/data/ctranslate2_weight_type", ns: configs, hook_name: "useTranslation", method_name: "updateSelectedCTranslate2WeightType" },
{ endpoint: "/set/data/ctranslate2_weight_type", ns: configs, hook_name: "useTranslation", method_name: "updateSelectedCTranslate2WeightType" }, { endpoint: "/set/data/ctranslate2_weight_type", ns: configs, hook_name: "useTranslation", method_name: "setSuccessSelectedCTranslate2WeightType" },
{ endpoint: "/get/data/selectable_ctranslate2_weight_type_dict", ns: configs, hook_name: "useTranslation", method_name: "updateDownloadedCTranslate2WeightTypeStatus" }, { endpoint: "/get/data/selectable_ctranslate2_weight_type_dict", ns: configs, hook_name: "useTranslation", method_name: "updateDownloadedCTranslate2WeightTypeStatus" },
@@ -177,39 +177,39 @@ export const ROUTE_META_LIST = [
{ endpoint: "/get/data/translation_compute_device_list", ns: configs, hook_name: "useTranslation", method_name: "updateSelectableCTranslate2ComputeDeviceList_FromBackend" }, { endpoint: "/get/data/translation_compute_device_list", ns: configs, hook_name: "useTranslation", method_name: "updateSelectableCTranslate2ComputeDeviceList_FromBackend" },
{ endpoint: "/get/data/selected_translation_compute_device", ns: configs, hook_name: "useTranslation", method_name: "updateSelectedCTranslate2ComputeDevice" }, { endpoint: "/get/data/selected_translation_compute_device", ns: configs, hook_name: "useTranslation", method_name: "updateSelectedCTranslate2ComputeDevice" },
{ endpoint: "/set/data/selected_translation_compute_device", ns: configs, hook_name: "useTranslation", method_name: "updateSelectedCTranslate2ComputeDevice" }, { endpoint: "/set/data/selected_translation_compute_device", ns: configs, hook_name: "useTranslation", method_name: "setSuccessSelectedCTranslate2ComputeDevice" },
// Transcription // Transcription
// Transcription (Mic) // Transcription (Mic)
{ endpoint: "/get/data/mic_record_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateMicRecordTimeout" }, { endpoint: "/get/data/mic_record_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateMicRecordTimeout" },
{ endpoint: "/set/data/mic_record_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateMicRecordTimeout" }, { endpoint: "/set/data/mic_record_timeout", ns: configs, hook_name: "useTranscription", method_name: "setSuccessMicRecordTimeout" },
{ endpoint: "/get/data/mic_phrase_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateMicPhraseTimeout" }, { endpoint: "/get/data/mic_phrase_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateMicPhraseTimeout" },
{ endpoint: "/set/data/mic_phrase_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateMicPhraseTimeout" }, { endpoint: "/set/data/mic_phrase_timeout", ns: configs, hook_name: "useTranscription", method_name: "setSuccessMicPhraseTimeout" },
{ endpoint: "/get/data/mic_max_phrases", ns: configs, hook_name: "useTranscription", method_name: "updateMicMaxWords" }, { endpoint: "/get/data/mic_max_phrases", ns: configs, hook_name: "useTranscription", method_name: "updateMicMaxWords" },
{ endpoint: "/set/data/mic_max_phrases", ns: configs, hook_name: "useTranscription", method_name: "updateMicMaxWords" }, { endpoint: "/set/data/mic_max_phrases", ns: configs, hook_name: "useTranscription", method_name: "setSuccessMicMaxWords" },
{ endpoint: "/get/data/mic_word_filter", ns: configs, hook_name: "useTranscription", method_name: "updateMicWordFilterList_FromBackend" }, { endpoint: "/get/data/mic_word_filter", ns: configs, hook_name: "useTranscription", method_name: "updateMicWordFilterList" },
{ endpoint: "/set/data/mic_word_filter", ns: configs, hook_name: "useTranscription", method_name: "updateMicWordFilterList_FromBackend" }, { endpoint: "/set/data/mic_word_filter", ns: configs, hook_name: "useTranscription", method_name: "setSuccessMicWordFilterList" },
// Transcription (Speaker) // Transcription (Speaker)
{ endpoint: "/get/data/speaker_record_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateSpeakerRecordTimeout" }, { endpoint: "/get/data/speaker_record_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateSpeakerRecordTimeout" },
{ endpoint: "/set/data/speaker_record_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateSpeakerRecordTimeout" }, { endpoint: "/set/data/speaker_record_timeout", ns: configs, hook_name: "useTranscription", method_name: "setSuccessSpeakerRecordTimeout" },
{ endpoint: "/get/data/speaker_phrase_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateSpeakerPhraseTimeout" }, { endpoint: "/get/data/speaker_phrase_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateSpeakerPhraseTimeout" },
{ endpoint: "/set/data/speaker_phrase_timeout", ns: configs, hook_name: "useTranscription", method_name: "updateSpeakerPhraseTimeout" }, { endpoint: "/set/data/speaker_phrase_timeout", ns: configs, hook_name: "useTranscription", method_name: "setSuccessSpeakerPhraseTimeout" },
{ endpoint: "/get/data/speaker_max_phrases", ns: configs, hook_name: "useTranscription", method_name: "updateSpeakerMaxWords" }, { endpoint: "/get/data/speaker_max_phrases", ns: configs, hook_name: "useTranscription", method_name: "updateSpeakerMaxWords" },
{ endpoint: "/set/data/speaker_max_phrases", ns: configs, hook_name: "useTranscription", method_name: "updateSpeakerMaxWords" }, { endpoint: "/set/data/speaker_max_phrases", ns: configs, hook_name: "useTranscription", method_name: "setSuccessSpeakerMaxWords" },
// Transcription (AI Models) // Transcription (AI Models)
{ endpoint: "/get/data/selected_transcription_engine", ns: configs, hook_name: "useTranscription", method_name: "updateSelectedTranscriptionEngine" }, { endpoint: "/get/data/selected_transcription_engine", ns: configs, hook_name: "useTranscription", method_name: "updateSelectedTranscriptionEngine" },
{ endpoint: "/set/data/selected_transcription_engine", ns: configs, hook_name: "useTranscription", method_name: "updateSelectedTranscriptionEngine" }, { endpoint: "/set/data/selected_transcription_engine", ns: configs, hook_name: "useTranscription", method_name: "setSuccessSelectedTranscriptionEngine" },
{ endpoint: "/get/data/whisper_weight_type", ns: configs, hook_name: "useTranscription", method_name: "updateSelectedWhisperWeightType" }, { endpoint: "/get/data/whisper_weight_type", ns: configs, hook_name: "useTranscription", method_name: "updateSelectedWhisperWeightType" },
{ endpoint: "/set/data/whisper_weight_type", ns: configs, hook_name: "useTranscription", method_name: "updateSelectedWhisperWeightType" }, { endpoint: "/set/data/whisper_weight_type", ns: configs, hook_name: "useTranscription", method_name: "setSuccessSelectedWhisperWeightType" },
{ endpoint: "/get/data/selectable_whisper_weight_type_dict", ns: configs, hook_name: "useTranscription", method_name: "updateDownloadedWhisperWeightTypeStatus" }, { endpoint: "/get/data/selectable_whisper_weight_type_dict", ns: configs, hook_name: "useTranscription", method_name: "updateDownloadedWhisperWeightTypeStatus" },
@@ -219,84 +219,84 @@ export const ROUTE_META_LIST = [
{ endpoint: "/get/data/transcription_compute_device_list", ns: configs, hook_name: "useTranscription", method_name: "updateSelectableWhisperComputeDeviceList_FromBackend" }, { endpoint: "/get/data/transcription_compute_device_list", ns: configs, hook_name: "useTranscription", method_name: "updateSelectableWhisperComputeDeviceList_FromBackend" },
{ endpoint: "/get/data/selected_transcription_compute_device", ns: configs, hook_name: "useTranscription", method_name: "updateSelectedWhisperComputeDevice" }, { endpoint: "/get/data/selected_transcription_compute_device", ns: configs, hook_name: "useTranscription", method_name: "updateSelectedWhisperComputeDevice" },
{ endpoint: "/set/data/selected_transcription_compute_device", ns: configs, hook_name: "useTranscription", method_name: "updateSelectedWhisperComputeDevice" }, { endpoint: "/set/data/selected_transcription_compute_device", ns: configs, hook_name: "useTranscription", method_name: "setSuccessSelectedWhisperComputeDevice" },
// VR // VR
{ endpoint: "/get/data/overlay_small_log", ns: configs, hook_name: "useVr", method_name: "updateIsEnabledOverlaySmallLog" }, { endpoint: "/get/data/overlay_small_log", ns: configs, hook_name: "useVr", method_name: "updateIsEnabledOverlaySmallLog" },
{ endpoint: "/set/enable/overlay_small_log", ns: configs, hook_name: "useVr", method_name: "updateIsEnabledOverlaySmallLog" }, { endpoint: "/set/enable/overlay_small_log", ns: configs, hook_name: "useVr", method_name: "setSuccessIsEnabledOverlaySmallLog" },
{ endpoint: "/set/disable/overlay_small_log", ns: configs, hook_name: "useVr", method_name: "updateIsEnabledOverlaySmallLog" }, { endpoint: "/set/disable/overlay_small_log", ns: configs, hook_name: "useVr", method_name: "setSuccessIsEnabledOverlaySmallLog" },
{ endpoint: "/get/data/overlay_small_log_settings", ns: configs, hook_name: "useVr", method_name: "updateOverlaySmallLogSettings" }, { endpoint: "/get/data/overlay_small_log_settings", ns: configs, hook_name: "useVr", method_name: "updateOverlaySmallLogSettings" },
{ endpoint: "/set/data/overlay_small_log_settings", ns: configs, hook_name: "useVr", method_name: "updateOverlaySmallLogSettings" }, { endpoint: "/set/data/overlay_small_log_settings", ns: configs, hook_name: "useVr", method_name: "setSuccessOverlaySmallLogSettings" },
{ endpoint: "/get/data/overlay_large_log", ns: configs, hook_name: "useVr", method_name: "updateIsEnabledOverlayLargeLog" }, { endpoint: "/get/data/overlay_large_log", ns: configs, hook_name: "useVr", method_name: "updateIsEnabledOverlayLargeLog" },
{ endpoint: "/set/enable/overlay_large_log", ns: configs, hook_name: "useVr", method_name: "updateIsEnabledOverlayLargeLog" }, { endpoint: "/set/enable/overlay_large_log", ns: configs, hook_name: "useVr", method_name: "setSuccessIsEnabledOverlayLargeLog" },
{ endpoint: "/set/disable/overlay_large_log", ns: configs, hook_name: "useVr", method_name: "updateIsEnabledOverlayLargeLog" }, { endpoint: "/set/disable/overlay_large_log", ns: configs, hook_name: "useVr", method_name: "setSuccessIsEnabledOverlayLargeLog" },
{ endpoint: "/get/data/overlay_large_log_settings", ns: configs, hook_name: "useVr", method_name: "updateOverlayLargeLogSettings" }, { endpoint: "/get/data/overlay_large_log_settings", ns: configs, hook_name: "useVr", method_name: "updateOverlayLargeLogSettings" },
{ endpoint: "/set/data/overlay_large_log_settings", ns: configs, hook_name: "useVr", method_name: "updateOverlayLargeLogSettings" }, { endpoint: "/set/data/overlay_large_log_settings", ns: configs, hook_name: "useVr", method_name: "setSuccessOverlayLargeLogSettings" },
{ endpoint: "/get/data/overlay_show_only_translated_messages", ns: configs, hook_name: "useVr", method_name: "updateOverlayShowOnlyTranslatedMessages" }, { endpoint: "/get/data/overlay_show_only_translated_messages", ns: configs, hook_name: "useVr", method_name: "updateOverlayShowOnlyTranslatedMessages" },
{ endpoint: "/set/enable/overlay_show_only_translated_messages", ns: configs, hook_name: "useVr", method_name: "updateOverlayShowOnlyTranslatedMessages" }, { endpoint: "/set/enable/overlay_show_only_translated_messages", ns: configs, hook_name: "useVr", method_name: "setSuccessOverlayShowOnlyTranslatedMessages" },
{ endpoint: "/set/disable/overlay_show_only_translated_messages", ns: configs, hook_name: "useVr", method_name: "updateOverlayShowOnlyTranslatedMessages" }, { endpoint: "/set/disable/overlay_show_only_translated_messages", ns: configs, hook_name: "useVr", method_name: "setSuccessOverlayShowOnlyTranslatedMessages" },
{ endpoint: "/run/send_text_overlay", ns: null, hook_name: null, method_name: null }, { endpoint: "/run/send_text_overlay", ns: null, hook_name: null, method_name: null },
// Others // Others
{ endpoint: "/get/data/auto_clear_message_box", ns: configs, hook_name: "useOthers", method_name: "updateEnableAutoClearMessageInputBox" }, { endpoint: "/get/data/auto_clear_message_box", ns: configs, hook_name: "useOthers", method_name: "updateEnableAutoClearMessageInputBox" },
{ endpoint: "/set/enable/auto_clear_message_box", ns: configs, hook_name: "useOthers", method_name: "updateEnableAutoClearMessageInputBox" }, { endpoint: "/set/enable/auto_clear_message_box", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableAutoClearMessageInputBox" },
{ endpoint: "/set/disable/auto_clear_message_box", ns: configs, hook_name: "useOthers", method_name: "updateEnableAutoClearMessageInputBox" }, { endpoint: "/set/disable/auto_clear_message_box", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableAutoClearMessageInputBox" },
{ endpoint: "/get/data/send_only_translated_messages", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendOnlyTranslatedMessages" }, { endpoint: "/get/data/send_only_translated_messages", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendOnlyTranslatedMessages" },
{ endpoint: "/set/enable/send_only_translated_messages", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendOnlyTranslatedMessages" }, { endpoint: "/set/enable/send_only_translated_messages", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableSendOnlyTranslatedMessages" },
{ endpoint: "/set/disable/send_only_translated_messages", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendOnlyTranslatedMessages" }, { endpoint: "/set/disable/send_only_translated_messages", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableSendOnlyTranslatedMessages" },
{ endpoint: "/get/data/logger_feature", ns: configs, hook_name: "useOthers", method_name: "updateEnableAutoExportMessageLogs" }, { endpoint: "/get/data/logger_feature", ns: configs, hook_name: "useOthers", method_name: "updateEnableAutoExportMessageLogs" },
{ endpoint: "/set/enable/logger_feature", ns: configs, hook_name: "useOthers", method_name: "updateEnableAutoExportMessageLogs" }, { endpoint: "/set/enable/logger_feature", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableAutoExportMessageLogs" },
{ endpoint: "/set/disable/logger_feature", ns: configs, hook_name: "useOthers", method_name: "updateEnableAutoExportMessageLogs" }, { endpoint: "/set/disable/logger_feature", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableAutoExportMessageLogs" },
{ endpoint: "/get/data/vrc_mic_mute_sync", ns: configs, hook_name: "useOthers", method_name: "updateEnableVrcMicMuteSync_FromBackend" }, { endpoint: "/get/data/vrc_mic_mute_sync", ns: configs, hook_name: "useOthers", method_name: "updateEnableVrcMicMuteSync_FromBackend" },
{ endpoint: "/set/enable/vrc_mic_mute_sync", ns: configs, hook_name: "useOthers", method_name: "updateEnableVrcMicMuteSync_FromBackend" }, { endpoint: "/set/enable/vrc_mic_mute_sync", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableVrcMicMuteSync" },
{ endpoint: "/set/disable/vrc_mic_mute_sync", ns: configs, hook_name: "useOthers", method_name: "updateEnableVrcMicMuteSync_FromBackend" }, { endpoint: "/set/disable/vrc_mic_mute_sync", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableVrcMicMuteSync" },
{ endpoint: "/get/data/send_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendMessageToVrc" }, { endpoint: "/get/data/send_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendMessageToVrc" },
{ endpoint: "/set/enable/send_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendMessageToVrc" }, { endpoint: "/set/enable/send_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableSendMessageToVrc" },
{ endpoint: "/set/disable/send_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendMessageToVrc" }, { endpoint: "/set/disable/send_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableSendMessageToVrc" },
{ endpoint: "/get/data/send_received_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendReceivedMessageToVrc" }, { endpoint: "/get/data/send_received_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendReceivedMessageToVrc" },
{ endpoint: "/set/enable/send_received_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendReceivedMessageToVrc" }, { endpoint: "/set/enable/send_received_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableSendReceivedMessageToVrc" },
{ endpoint: "/set/disable/send_received_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "updateEnableSendReceivedMessageToVrc" }, { endpoint: "/set/disable/send_received_message_to_vrc", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableSendReceivedMessageToVrc" },
{ endpoint: "/get/data/notification_vrc_sfx", ns: configs, hook_name: "useOthers", method_name: "updateEnableNotificationVrcSfx" }, { endpoint: "/get/data/notification_vrc_sfx", ns: configs, hook_name: "useOthers", method_name: "updateEnableNotificationVrcSfx" },
{ endpoint: "/set/enable/notification_vrc_sfx", ns: configs, hook_name: "useOthers", method_name: "updateEnableNotificationVrcSfx" }, { endpoint: "/set/enable/notification_vrc_sfx", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableNotificationVrcSfx" },
{ endpoint: "/set/disable/notification_vrc_sfx", ns: configs, hook_name: "useOthers", method_name: "updateEnableNotificationVrcSfx" }, { endpoint: "/set/disable/notification_vrc_sfx", ns: configs, hook_name: "useOthers", method_name: "setSuccessEnableNotificationVrcSfx" },
// Hotkeys // Hotkeys
{ endpoint: "/get/data/hotkeys", ns: configs, hook_name: "useHotkeys", method_name: "updateHotkeys" }, { endpoint: "/get/data/hotkeys", ns: configs, hook_name: "useHotkeys", method_name: "updateHotkeys" },
{ endpoint: "/set/data/hotkeys", ns: configs, hook_name: "useHotkeys", method_name: "updateHotkeys" }, { endpoint: "/set/data/hotkeys", ns: configs, hook_name: "useHotkeys", method_name: "setSuccessHotkeys" },
// Plugins // Plugins
{ endpoint: "/get/data/plugins_status", ns: configs, hook_name: "usePlugins", method_name: "updateSavedPluginsStatus" }, { endpoint: "/get/data/plugins_status", ns: configs, hook_name: "usePlugins", method_name: "updateSavedPluginsStatus" },
{ endpoint: "/set/data/plugins_status", ns: configs, hook_name: "usePlugins", method_name: "updateSavedPluginsStatus" }, { endpoint: "/set/data/plugins_status", ns: configs, hook_name: "usePlugins", method_name: "setSuccessSavedPluginsStatus" },
// Advanced Settings // Advanced Settings
{ endpoint: "/get/data/osc_ip_address", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateOscIpAddress" }, { endpoint: "/get/data/osc_ip_address", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateOscIpAddress" },
{ endpoint: "/set/data/osc_ip_address", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateOscIpAddress" }, { endpoint: "/set/data/osc_ip_address", ns: configs, hook_name: "useAdvancedSettings", method_name: "setSuccessOscIpAddress" },
{ endpoint: "/get/data/osc_port", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateOscPort" }, { endpoint: "/get/data/osc_port", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateOscPort" },
{ endpoint: "/set/data/osc_port", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateOscPort" }, { endpoint: "/set/data/osc_port", ns: configs, hook_name: "useAdvancedSettings", method_name: "setSuccessOscPort" },
{ endpoint: "/get/data/websocket_server", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateEnableWebsocket" }, { endpoint: "/get/data/websocket_server", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateEnableWebsocket" },
{ endpoint: "/set/enable/websocket_server", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateEnableWebsocket" }, { endpoint: "/set/enable/websocket_server", ns: configs, hook_name: "useAdvancedSettings", method_name: "setSuccessEnableWebsocket" },
{ endpoint: "/set/disable/websocket_server", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateEnableWebsocket" }, { endpoint: "/set/disable/websocket_server", ns: configs, hook_name: "useAdvancedSettings", method_name: "setSuccessEnableWebsocket" },
{ endpoint: "/get/data/websocket_host", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateWebsocketHost" }, { endpoint: "/get/data/websocket_host", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateWebsocketHost" },
{ endpoint: "/set/data/websocket_host", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateWebsocketHost" }, { endpoint: "/set/data/websocket_host", ns: configs, hook_name: "useAdvancedSettings", method_name: "setSuccessWebsocketHost" },
{ endpoint: "/get/data/websocket_port", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateWebsocketPort" }, { endpoint: "/get/data/websocket_port", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateWebsocketPort" },
{ endpoint: "/set/data/websocket_port", ns: configs, hook_name: "useAdvancedSettings", method_name: "updateWebsocketPort" }, { endpoint: "/set/data/websocket_port", ns: configs, hook_name: "useAdvancedSettings", method_name: "setSuccessWebsocketPort" },
// Not Implemented Yet... // Not Implemented Yet...