From 5827537998597a496fc9f53c0521ce264dfe8276 Mon Sep 17 00:00:00 2001 From: 2hwk Date: Sun, 24 Apr 2022 17:38:06 +0800 Subject: [PATCH] fix(isis): do not adjust opacity of bg elements (#7103) --- src/instruments/src/ISIS/AutoBrightness.tsx | 23 +++++++++++--------- src/instruments/src/ISIS/ISISDisplayUnit.tsx | 2 +- 2 files changed, 14 insertions(+), 11 deletions(-) diff --git a/src/instruments/src/ISIS/AutoBrightness.tsx b/src/instruments/src/ISIS/AutoBrightness.tsx index 5c4f15e1547..3ecbe5dbbae 100644 --- a/src/instruments/src/ISIS/AutoBrightness.tsx +++ b/src/instruments/src/ISIS/AutoBrightness.tsx @@ -20,7 +20,6 @@ export const AutoBrightness: React.FC = ({ bugsActive, chil const [targetBrightness, setTargetBrightness] = useState(isDaytimeRef.current ? dayBrightness : nightBrightness); const [currentBrightness, setCurrentBrightness] = useSimVar('L:A32NX_BARO_BRIGHTNESS', 'number', 10000); - const [homeCockpit] = useSimVar('L:A32NX_HOME_COCKPIT_ENABLED', 'bool', 200); const isBrightnessUpPressed = useRef(false); const isBrightnessDownPressed = useRef(false); @@ -89,16 +88,20 @@ export const AutoBrightness: React.FC = ({ bugsActive, chil { additionalDeps: [currentBrightness, targetBrightness], runOnStart: false }, ); - if (homeCockpit) { - return ( - - {children} - - ); - } - return ( - + + {children} ); diff --git a/src/instruments/src/ISIS/ISISDisplayUnit.tsx b/src/instruments/src/ISIS/ISISDisplayUnit.tsx index 936c7fe3418..6dd653e38f9 100644 --- a/src/instruments/src/ISIS/ISISDisplayUnit.tsx +++ b/src/instruments/src/ISIS/ISISDisplayUnit.tsx @@ -58,7 +58,7 @@ export const ISISDisplayUnit: React.FC = ({ indicatedAirsp if (state === DisplayUnitState.Selftest) { return ( <> - + ATT