diff options
| author | xXJSONDeruloXx <danielhimebauch@gmail.com> | 2025-07-17 23:23:03 -0400 |
|---|---|---|
| committer | xXJSONDeruloXx <danielhimebauch@gmail.com> | 2025-07-17 23:23:03 -0400 |
| commit | 0670041467ca5625d93e3e4dbc2f738da24d88b4 (patch) | |
| tree | e4a0bdd982856c489899cd30cc8487b3430ae6c2 /src/components | |
| parent | f2870ff308131a0a4c970edf36bb88aac10a6175 (diff) | |
| download | decky-lsfg-vk-0670041467ca5625d93e3e4dbc2f738da24d88b4.tar.gz decky-lsfg-vk-0670041467ca5625d93e3e4dbc2f738da24d88b4.zip | |
add experimental toggles
Diffstat (limited to 'src/components')
| -rw-r--r-- | src/components/ConfigurationSection.tsx | 46 | ||||
| -rw-r--r-- | src/components/Content.tsx | 4 | ||||
| -rw-r--r-- | src/components/UsageInstructions.tsx | 4 | ||||
| -rw-r--r-- | src/components/index.ts | 2 |
4 files changed, 51 insertions, 5 deletions
diff --git a/src/components/ConfigurationSection.tsx b/src/components/ConfigurationSection.tsx index deb8fba..76b9bc2 100644 --- a/src/components/ConfigurationSection.tsx +++ b/src/components/ConfigurationSection.tsx @@ -1,4 +1,4 @@ -import { PanelSectionRow, ToggleField, SliderField, TextField } from "@decky/ui"; +import { PanelSectionRow, ToggleField, SliderField, Dropdown } from "@decky/ui"; import { ConfigurationData } from "../config/configSchema"; interface ConfigurationSectionProps { @@ -93,6 +93,50 @@ export function ConfigurationSection({ onChange={(value) => onConfigChange('hdr_mode', value)} /> </PanelSectionRow> + + {/* Experimental Features Section */} + <PanelSectionRow> + <div + style={{ + fontSize: "14px", + fontWeight: "bold", + marginTop: "24px", + marginBottom: "8px", + borderBottom: "1px solid rgba(255, 165, 0, 0.4)", + paddingBottom: "4px", + color: "rgba(255, 165, 0, 0.9)" + }} + > + ⚠️ Experimental Features + </div> + </PanelSectionRow> + + <PanelSectionRow> + <Dropdown + menuLabel="Present Mode" + selectedOption={config.experimental_present_mode} + onChange={(value) => onConfigChange('experimental_present_mode', value.data)} + rgOptions={[ + { data: "", label: "Default (FIFO)" }, + { data: "fifo", label: "FIFO" }, + { data: "vsync", label: "VSync" }, + { data: "mailbox", label: "Mailbox" }, + { data: "immediate", label: "Immediate" } + ]} + /> + </PanelSectionRow> + + <PanelSectionRow> + <SliderField + label={`FPS Limit${config.experimental_fps_limit > 0 ? ` (${config.experimental_fps_limit} FPS)` : ' (Off)'}`} + description="Base framerate cap for DXVK games, before frame multiplier (0 = disabled)" + value={config.experimental_fps_limit} + min={0} + max={60} + step={1} + onChange={(value) => onConfigChange('experimental_fps_limit', value)} + /> + </PanelSectionRow> </> ); } diff --git a/src/components/Content.tsx b/src/components/Content.tsx index 613e722..ae64931 100644 --- a/src/components/Content.tsx +++ b/src/components/Content.tsx @@ -5,7 +5,7 @@ import { useInstallationActions } from "../hooks/useInstallationActions"; import { StatusDisplay } from "./StatusDisplay"; import { InstallationButton } from "./InstallationButton"; import { ConfigurationSection } from "./ConfigurationSection"; -import { UsageInstructions } from "./UsageInstructions"; +// import { UsageInstructions } from "./UsageInstructions"; import { WikiButton } from "./WikiButton"; import { ClipboardButton } from "./ClipboardButton"; import { PluginUpdateChecker } from "./PluginUpdateChecker"; @@ -74,7 +74,7 @@ export function Content() { /> )} - <UsageInstructions config={config} /> + {/* <UsageInstructions config={config} /> */} <WikiButton /> <ClipboardButton /> diff --git a/src/components/UsageInstructions.tsx b/src/components/UsageInstructions.tsx index ac721c7..d156f9d 100644 --- a/src/components/UsageInstructions.tsx +++ b/src/components/UsageInstructions.tsx @@ -54,7 +54,9 @@ export function UsageInstructions({ config }: UsageInstructionsProps) { • Multiplier: ${config.multiplier}x • Flow Scale: ${Math.round(config.flow_scale * 100)}% • Performance Mode: ${config.performance_mode ? "Yes" : "No"} -• HDR Mode: ${config.hdr_mode ? "Yes" : "No"}`} +• HDR Mode: ${config.hdr_mode ? "Yes" : "No"} +• Present Mode: ${config.experimental_present_mode || "Default (FIFO)"} +• FPS Limit: ${config.experimental_fps_limit > 0 ? `${config.experimental_fps_limit} FPS` : "Off"}`} </div> </PanelSectionRow> diff --git a/src/components/index.ts b/src/components/index.ts index d26159d..ab7a117 100644 --- a/src/components/index.ts +++ b/src/components/index.ts @@ -2,7 +2,7 @@ export { Content } from "./Content"; export { StatusDisplay } from "./StatusDisplay"; export { InstallationButton } from "./InstallationButton"; export { ConfigurationSection } from "./ConfigurationSection"; -export { UsageInstructions } from "./UsageInstructions"; +// export { UsageInstructions } from "./UsageInstructions"; export { WikiButton } from "./WikiButton"; export { ClipboardButton } from "./ClipboardButton"; export { PluginUpdateChecker } from "./PluginUpdateChecker"; |
