Merge branch 'ui' into for_webui
This commit is contained in:
@@ -29,5 +29,6 @@
|
||||
position: absolute;
|
||||
bottom: 0.8rem;
|
||||
left: 1.2rem;
|
||||
font-size: 1.4rem;
|
||||
font-size: 1.2rem;
|
||||
color: var(--dark_400_color);
|
||||
}
|
||||
@@ -34,6 +34,12 @@ export const Vr = () => {
|
||||
|
||||
const { currentOverlayLargeLogSettings, setOverlayLargeLogSettings } = useOverlayLargeLogSettings();
|
||||
const { currentIsEnabledOverlayLargeLog, toggleIsEnabledOverlayLargeLog } = useIsEnabledOverlayLargeLog();
|
||||
|
||||
const restoreDefaultSettings = () => {
|
||||
setOverlaySmallLogSettings(ui_configs.overlay_small_log_default_settings);
|
||||
setOverlayLargeLogSettings(ui_configs.overlay_large_log_default_settings);
|
||||
};
|
||||
|
||||
return (
|
||||
<div className={styles.container}>
|
||||
<div className={styles.wrapper}>
|
||||
@@ -64,6 +70,12 @@ export const Vr = () => {
|
||||
)}
|
||||
</div>
|
||||
<CommonSettingsContainer />
|
||||
<button
|
||||
className={styles.restore_default_settings_button}
|
||||
onClick={restoreDefaultSettings}
|
||||
>
|
||||
{t("config_page.vr.restore_default_settings")}
|
||||
</button>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
@@ -196,4 +196,18 @@
|
||||
|
||||
.common_label {
|
||||
font-size: 1.4rem;
|
||||
}
|
||||
|
||||
.restore_default_settings_button {
|
||||
color: var(--dark_basic_text_color);
|
||||
font-size: 1.2rem;
|
||||
margin-top: 6rem;
|
||||
padding: 0.8rem;
|
||||
border-radius: 0.4rem;
|
||||
&:hover {
|
||||
background-color: var(--dark_775_color);
|
||||
}
|
||||
&:active {
|
||||
background-color: var(--dark_900_color);
|
||||
}
|
||||
}
|
||||
@@ -24,4 +24,5 @@
|
||||
.label {
|
||||
font-size: 1.2rem;
|
||||
color: var(--dark_basic_text_color);
|
||||
white-space: nowrap;
|
||||
}
|
||||
@@ -463,6 +463,8 @@ export const useReceiveRoutes = () => {
|
||||
"/get/data/mic_no_speech_prob": ()=>{}, // Not implemented on UI yet
|
||||
"/get/data/speaker_avg_logprob": ()=>{}, // Not implemented on UI yet
|
||||
"/get/data/speaker_no_speech_prob": ()=>{}, // Not implemented on UI yet
|
||||
"/get/data/convert_message_to_romaji": ()=>{}, // Not implemented on UI yet
|
||||
"/get/data/convert_message_to_hiragana": ()=>{}, // Not implemented on UI yet
|
||||
};
|
||||
|
||||
const error_routes = {
|
||||
|
||||
@@ -129,7 +129,8 @@ export const { atomInstance: Atom_TranscriptionSendStatus, useHook: useStore_Tra
|
||||
export const { atomInstance: Atom_TranscriptionReceiveStatus, useHook: useStore_TranscriptionReceiveStatus } = createAtomWithHook(false, "TranscriptionReceiveStatus", {is_state_ok: true});
|
||||
export const { atomInstance: Atom_ForegroundStatus, useHook: useStore_ForegroundStatus } = createAtomWithHook(false, "ForegroundStatus", {is_state_ok: true});
|
||||
|
||||
export const { atomInstance: Atom_MessageLogs, useHook: useStore_MessageLogs } = createAtomWithHook(generateTestData(20), "MessageLogs");
|
||||
export const { atomInstance: Atom_MessageLogs, useHook: useStore_MessageLogs } = createAtomWithHook([], "MessageLogs");
|
||||
// export const { atomInstance: Atom_MessageLogs, useHook: useStore_MessageLogs } = createAtomWithHook(generateTestData(20), "MessageLogs"); // For testing
|
||||
export const { atomInstance: Atom_MessageInputValue, useHook: useStore_MessageInputValue } = createAtomWithHook("", "MessageInputValue");
|
||||
export const { atomInstance: Atom_IsVisibleResendButton, useHook: useStore_IsVisibleResendButton } = createAtomWithHook(false, "IsVisibleResendButton");
|
||||
export const { atomInstance: Atom_IsAppliedInitMessageBoxHeight, useHook: useStore_IsAppliedInitMessageBoxHeight } = createAtomWithHook(false, "IsAppliedInitMessageBoxHeight");
|
||||
|
||||
@@ -15,6 +15,34 @@ export const ui_configs = {
|
||||
z_pos: { step: 0.05, min: -0.5, max: 1.5 },
|
||||
ui_scaling: { step: 10, min: 40, max: 200 },
|
||||
},
|
||||
|
||||
overlay_small_log_default_settings: {
|
||||
x_pos: 0.0,
|
||||
y_pos: 0.0,
|
||||
z_pos: 0.0,
|
||||
x_rotation: 0.0,
|
||||
y_rotation: 0.0,
|
||||
z_rotation: 0.0,
|
||||
display_duration: 5,
|
||||
fadeout_duration: 2,
|
||||
opacity: 1.0,
|
||||
ui_scaling: 1.0,
|
||||
tracker: "HMD",
|
||||
},
|
||||
overlay_large_log_default_settings: {
|
||||
x_pos: 0.0,
|
||||
y_pos: 0.0,
|
||||
z_pos: 0.0,
|
||||
x_rotation: 0.0,
|
||||
y_rotation: 0.0,
|
||||
z_rotation: 0.0,
|
||||
display_duration: 5,
|
||||
fadeout_duration: 2,
|
||||
opacity: 1.0,
|
||||
ui_scaling: 1.0,
|
||||
tracker: "LeftHand",
|
||||
},
|
||||
|
||||
selectable_ui_languages: [
|
||||
{id: "en", label: "English"},
|
||||
{id: "ja", label: "日本語"},
|
||||
|
||||
Reference in New Issue
Block a user