File tree Expand file tree Collapse file tree 1 file changed +1
-7
lines changed
apps/fluent-tester/src/TestComponents/ColorTokens Expand file tree Collapse file tree 1 file changed +1
-7
lines changed Original file line number Diff line number Diff line change @@ -53,11 +53,6 @@ const styles = StyleSheet.create({
53
53
colorDescriptionNamePadding : { paddingRight : 5 } ,
54
54
} ) ;
55
55
56
- const getSwatchColorStyle = ( colorName : string , colorValue : ColorValue ) : ViewStyle => {
57
- styles [ colorName ] = styles [ colorName ] || { backgroundColor : colorValue } ;
58
- return styles [ colorName ] ;
59
- } ;
60
-
61
56
type ColorTokenProps = { colorValue : ColorValue ; colorName : string } ;
62
57
const ColorToken : React . FunctionComponent < ColorTokenProps > = ( p : ColorTokenProps ) => {
63
58
if ( p . colorValue === undefined ) {
@@ -68,7 +63,7 @@ const ColorToken: React.FunctionComponent<ColorTokenProps> = (p: ColorTokenProps
68
63
return (
69
64
< View style = { styles . swatchItem } >
70
65
< View
71
- style = { [ getSwatchColorStyle ( p . colorName , p . colorValue ) , themedStyles . swatch ] }
66
+ style = { [ { backgroundColor : p . colorValue } , themedStyles . swatch ] }
72
67
/* For Android E2E testing purposes, testProps must be passed in after accessibilityLabel. */
73
68
{ ...testProps ( COLORTOKENS_TEST_COMPONENT ) }
74
69
/>
@@ -89,7 +84,6 @@ const getSwatch = (item) => {
89
84
90
85
const AliasColorTokensSwatchList : React . FunctionComponent = ( ) => {
91
86
const theme = useTheme ( ) ;
92
-
93
87
const aliasColorTokens = theme . colors ;
94
88
95
89
const aggregator = React . useCallback (
You can’t perform that action at this time.
0 commit comments