Skip to content
Snippets Groups Projects
Unverified Commit d982b83e authored by GyDi's avatar GyDi
Browse files

feat: change type

parent cc0e930d
No related branches found
No related tags found
No related merge requests found
...@@ -26,7 +26,7 @@ const SettingVerge = ({ onError }: Props) => { ...@@ -26,7 +26,7 @@ const SettingVerge = ({ onError }: Props) => {
const { const {
theme_mode: mode = "light", theme_mode: mode = "light",
theme_blur: blur = false, theme_blur: blur = false,
enable_self_startup: startup = false, enable_auto_launch: startup = false,
enable_system_proxy: proxy = false, enable_system_proxy: proxy = false,
} = vergeConfig ?? {}; } = vergeConfig ?? {};
...@@ -72,14 +72,14 @@ const SettingVerge = ({ onError }: Props) => { ...@@ -72,14 +72,14 @@ const SettingVerge = ({ onError }: Props) => {
</SettingItem> </SettingItem>
<SettingItem> <SettingItem>
<ListItemText primary="Self Startup" /> <ListItemText primary="Auto Launch" />
<GuardState <GuardState
value={startup} value={startup}
valueProps="checked" valueProps="checked"
onCatch={onError} onCatch={onError}
onFormat={onSwitchFormat} onFormat={onSwitchFormat}
onChange={(e) => onChangeData({ enable_self_startup: e })} onChange={(e) => onChangeData({ enable_auto_launch: e })}
onGuard={(e) => patchVergeConfig({ enable_self_startup: e })} onGuard={(e) => patchVergeConfig({ enable_auto_launch: e })}
> >
<Switch edge="end" /> <Switch edge="end" />
</GuardState> </GuardState>
......
...@@ -111,7 +111,7 @@ export namespace CmdType { ...@@ -111,7 +111,7 @@ export namespace CmdType {
export interface VergeConfig { export interface VergeConfig {
theme_mode?: "light" | "dark"; theme_mode?: "light" | "dark";
theme_blur?: boolean; theme_blur?: boolean;
enable_self_startup?: boolean; enable_auto_launch?: boolean;
enable_system_proxy?: boolean; enable_system_proxy?: boolean;
} }
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment