mirror of
https://github.com/zoriya/react-native-web.git
synced 2026-06-04 19:05:49 +00:00
[fix] ProgressBar & Switch for High Contrast mode
Prevent these controls from becoming invisible in Windows High Contrast mode by disabling forced color adjustment for these elements. Fix #1606
This commit is contained in:
@@ -71,12 +71,14 @@ ProgressBar.displayName = 'ProgressBar';
|
|||||||
|
|
||||||
const styles = StyleSheet.create({
|
const styles = StyleSheet.create({
|
||||||
track: {
|
track: {
|
||||||
|
forcedColorAdjust: 'none',
|
||||||
height: 5,
|
height: 5,
|
||||||
overflow: 'hidden',
|
overflow: 'hidden',
|
||||||
userSelect: 'none',
|
userSelect: 'none',
|
||||||
zIndex: 0
|
zIndex: 0
|
||||||
},
|
},
|
||||||
progress: {
|
progress: {
|
||||||
|
forcedColorAdjust: 'none',
|
||||||
height: '100%',
|
height: '100%',
|
||||||
zIndex: -1
|
zIndex: -1
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -145,6 +145,7 @@ const styles = StyleSheet.create({
|
|||||||
cursor: 'inherit'
|
cursor: 'inherit'
|
||||||
},
|
},
|
||||||
track: {
|
track: {
|
||||||
|
forcedColorAdjust: 'none',
|
||||||
...StyleSheet.absoluteFillObject,
|
...StyleSheet.absoluteFillObject,
|
||||||
height: '70%',
|
height: '70%',
|
||||||
margin: 'auto',
|
margin: 'auto',
|
||||||
@@ -152,6 +153,7 @@ const styles = StyleSheet.create({
|
|||||||
width: '100%'
|
width: '100%'
|
||||||
},
|
},
|
||||||
thumb: {
|
thumb: {
|
||||||
|
forcedColorAdjust: 'none',
|
||||||
alignSelf: 'flex-start',
|
alignSelf: 'flex-start',
|
||||||
borderRadius: '100%',
|
borderRadius: '100%',
|
||||||
boxShadow: thumbDefaultBoxShadow,
|
boxShadow: thumbDefaultBoxShadow,
|
||||||
|
|||||||
Reference in New Issue
Block a user