mirror of https://github.com/jetkvm/kvm.git
Compare commits
No commits in common. "8c88f72ba41f364874934ed506868440ecb13713" and "bce968000c0b74015c56ec162d712e22e27dcb39" have entirely different histories.
8c88f72ba4
...
bce968000c
|
|
@ -10,5 +10,5 @@
|
|||
]
|
||||
},
|
||||
"git.ignoreLimitWarning": true,
|
||||
"cmake.sourceDirectory": "internal/native/cgo"
|
||||
"cmake.sourceDirectory": "/workspaces/kvm-sleep-mode/internal/native/cgo"
|
||||
}
|
||||
|
|
@ -31,7 +31,6 @@ export default function SettingsAdvancedRoute() {
|
|||
const [appVersion, setAppVersion] = useState<string>("");
|
||||
const [systemVersion, setSystemVersion] = useState<string>("");
|
||||
const [resetConfig, setResetConfig] = useState(false);
|
||||
const [versionChangeAcknowledged, setVersionChangeAcknowledged] = useState(false);
|
||||
|
||||
const settings = useSettingsStore();
|
||||
|
||||
|
|
@ -204,7 +203,7 @@ export default function SettingsAdvancedRoute() {
|
|||
const pageParams = new URLSearchParams();
|
||||
pageParams.set("downgrade", "true");
|
||||
pageParams.set("resetConfig", resetConfig.toString());
|
||||
pageParams.set("components", updateTarget === "both" ? "app,system" : updateTarget);
|
||||
pageParams.set("components", updateTarget == "both" ? "app,system" : updateTarget);
|
||||
|
||||
// Navigate to update page
|
||||
navigateTo(`/settings/general/update?${pageParams.toString()}`);
|
||||
|
|
@ -357,14 +356,6 @@ export default function SettingsAdvancedRoute() {
|
|||
/>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<CheckboxWithLabel
|
||||
label="I understand version changes may break my device and require factory reset"
|
||||
checked={versionChangeAcknowledged}
|
||||
onChange={e => setVersionChangeAcknowledged(e.target.checked)}
|
||||
/>
|
||||
</div>
|
||||
|
||||
<Button
|
||||
size="SM"
|
||||
theme="primary"
|
||||
|
|
@ -372,8 +363,7 @@ export default function SettingsAdvancedRoute() {
|
|||
disabled={
|
||||
(updateTarget === "app" && !appVersion) ||
|
||||
(updateTarget === "system" && !systemVersion) ||
|
||||
(updateTarget === "both" && (!appVersion || !systemVersion)) ||
|
||||
!versionChangeAcknowledged
|
||||
(updateTarget === "both" && (!appVersion || !systemVersion))
|
||||
}
|
||||
onClick={handleVersionUpdate}
|
||||
/>
|
||||
|
|
|
|||
|
|
@ -14,7 +14,8 @@ import { m } from "@localizations/messages.js";
|
|||
export default function SettingsGeneralUpdateRoute() {
|
||||
const navigate = useNavigate();
|
||||
const location = useLocation();
|
||||
const [searchParams] = useSearchParams();
|
||||
//@ts-ignore
|
||||
const [searchParams, setSearchParams] = useSearchParams();
|
||||
const { updateSuccess } = location.state || {};
|
||||
|
||||
const { setModalView, otaState } = useUpdateStore();
|
||||
|
|
|
|||
Loading…
Reference in New Issue