mirror of
https://github.com/upscayl/upscayl.git
synced 2024-11-27 17:00:52 +01:00
Add batch mode localstorage
This commit is contained in:
parent
3865e1fed0
commit
58c6e8f9ec
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "upscayl",
|
||||
"private": true,
|
||||
"version": "2.0.1",
|
||||
"version": "2.5.0",
|
||||
"productName": "Upscayl",
|
||||
"homepage": "https://github.com/TGS963/upscayl",
|
||||
"contributors": [
|
||||
|
@ -6,3 +6,5 @@ export const customModelsPathAtom = atomWithStorage<string | null>(
|
||||
);
|
||||
|
||||
export const scaleAtom = atomWithStorage<"2" | "3" | "4">("scale", "4");
|
||||
|
||||
export const batchModeAtom = atomWithStorage<boolean>("batchMode", false);
|
||||
|
@ -175,6 +175,7 @@ function LeftPaneImageSteps({
|
||||
<input
|
||||
type="checkbox"
|
||||
className="toggle"
|
||||
checked={batchMode}
|
||||
onClick={handleBatchMode}></input>
|
||||
<p
|
||||
className="mr-1 inline-block cursor-help text-sm"
|
||||
|
@ -12,7 +12,11 @@ import SettingsTab from "../components/SettingsTab";
|
||||
import { useAtom } from "jotai";
|
||||
import { logAtom } from "../atoms/logAtom";
|
||||
import { modelsListAtom } from "../atoms/modelsListAtom";
|
||||
import { customModelsPathAtom, scaleAtom } from "../atoms/userSettingsAtom";
|
||||
import {
|
||||
batchModeAtom,
|
||||
customModelsPathAtom,
|
||||
scaleAtom,
|
||||
} from "../atoms/userSettingsAtom";
|
||||
|
||||
const Home = () => {
|
||||
// STATES
|
||||
@ -24,7 +28,7 @@ const Home = () => {
|
||||
const [model, setModel] = useState("realesrgan-x4plus");
|
||||
const [loaded, setLoaded] = useState(false);
|
||||
const [version, setVersion] = useState("");
|
||||
const [batchMode, setBatchMode] = useState(false);
|
||||
const [batchMode, setBatchMode] = useAtom(batchModeAtom);
|
||||
const [batchFolderPath, setBatchFolderPath] = useState("");
|
||||
const [upscaledBatchFolderPath, setUpscaledBatchFolderPath] = useState("");
|
||||
const [doubleUpscayl, setDoubleUpscayl] = useState(false);
|
||||
|
Loading…
Reference in New Issue
Block a user