summaryrefslogtreecommitdiff
path: root/src/components/GameConfigurationControls.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/GameConfigurationControls.tsx')
-rw-r--r--src/components/GameConfigurationControls.tsx9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/components/GameConfigurationControls.tsx b/src/components/GameConfigurationControls.tsx
index 34b82c5..58ccd02 100644
--- a/src/components/GameConfigurationControls.tsx
+++ b/src/components/GameConfigurationControls.tsx
@@ -1,12 +1,16 @@
import { ConfigurationData } from "../config/configSchema";
+import type { GameTarget } from "../hooks/useGameConfiguration";
import { ConfigurationSection } from "./ConfigurationSection";
import { FpsMultiplierControl } from "./FpsMultiplierControl";
+import { WorkaroundsSection } from "./WorkaroundsSection";
interface Props {
config: ConfigurationData;
onConfigChange: (fieldName: keyof ConfigurationData, value: boolean | number | string | string[]) => Promise<void>;
autoFocusFpsMultiplier?: boolean;
onFpsMultiplierFocused?: () => void;
+ showWorkarounds?: boolean;
+ workaroundTarget?: Pick<GameTarget, "appid" | "nonSteam">;
}
export function GameConfigurationControls({
@@ -14,6 +18,8 @@ export function GameConfigurationControls({
onConfigChange,
autoFocusFpsMultiplier,
onFpsMultiplierFocused,
+ showWorkarounds = false,
+ workaroundTarget,
}: Props) {
return (
<>
@@ -24,6 +30,9 @@ export function GameConfigurationControls({
onAutoFocus={onFpsMultiplierFocused}
/>
<ConfigurationSection config={config} onConfigChange={onConfigChange} />
+ {showWorkarounds && workaroundTarget && (
+ <WorkaroundsSection appId={workaroundTarget.appid} nonSteam={workaroundTarget.nonSteam} />
+ )}
</>
);
}