mirror of
https://github.com/upscayl/upscayl.git
synced 2026-04-03 03:00:13 -04:00
Fix batch upscale scale
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import React from "react";
|
||||
import React, { useEffect } from "react";
|
||||
|
||||
type ToggleOverwriteProps = {
|
||||
overwrite: boolean;
|
||||
@@ -6,6 +6,13 @@ type ToggleOverwriteProps = {
|
||||
};
|
||||
|
||||
const ToggleOverwrite = ({ overwrite, setOverwrite }: ToggleOverwriteProps) => {
|
||||
useEffect(() => {
|
||||
if (!localStorage.getItem("overwrite")) {
|
||||
localStorage.setItem("overwrite", JSON.stringify(overwrite));
|
||||
} else {
|
||||
setOverwrite(localStorage.getItem("overwrite"));
|
||||
}
|
||||
}, []);
|
||||
return (
|
||||
<div className="flex flex-col gap-2">
|
||||
<p className="text-sm font-medium">OVERWRITE PREVIOUS UPSCALE</p>
|
||||
|
||||
@@ -670,7 +670,7 @@ const Home = () => {
|
||||
All done!
|
||||
</p>
|
||||
<button
|
||||
className="bg-gradient-blue rounded-lg p-3 font-medium text-white/90 transition-colors"
|
||||
className="btn bg-gradient-blue rounded-lg p-3 font-medium text-white/90 transition-colors"
|
||||
onClick={openFolderHandler}>
|
||||
Open Upscayled Folder
|
||||
</button>
|
||||
|
||||
Reference in New Issue
Block a user