Skip to content

Commit 4bf83f3

Browse files
authored
Fix badge colors and example screen (#2392)
1 parent a1aec1a commit 4bf83f3

File tree

3 files changed

+10
-7
lines changed

3 files changed

+10
-7
lines changed

demo/src/screens/__tests__/__snapshots__/AvatarScreen.spec.js.snap

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1796,7 +1796,9 @@ exports[`AvatarScreen renders screen 1`] = `
17961796
}
17971797
style={
17981798
Array [
1799-
undefined,
1799+
Object {
1800+
"tintColor": "#FFFFFF",
1801+
},
18001802
undefined,
18011803
undefined,
18021804
undefined,

demo/src/screens/componentScreens/BadgesScreen.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,18 +21,18 @@ export default class BadgesScreen extends Component {
2121

2222
customElement1 = (
2323
<View row>
24-
<Image source={bell}/>
25-
<Image source={bell}/>
24+
<Image tintColor={Colors.$iconDefaultLight} source={bell}/>
25+
<Image tintColor={Colors.$iconDefaultLight} source={bell}/>
2626
</View>
2727
);
2828

2929
customElement2 = (
3030
<View row>
31-
<Image source={bell}/>
32-
<Text white text90>
31+
<Image tintColor={Colors.$iconSuccessLight} source={bell}/>
32+
<Text $textSuccessLight text90>
3333
37
3434
</Text>
35-
<Image source={bell}/>
35+
<Image tintColor={Colors.$iconSuccessLight} source={bell}/>
3636
</View>
3737
);
3838

@@ -152,7 +152,7 @@ export default class BadgesScreen extends Component {
152152
</Text>
153153
<View row spread marginH-50>
154154
<Badge marginR-10 label={'17'} customElement={this.customElement1}/>
155-
<Badge marginR-10 customElement={this.customElement2} backgroundColor={Colors.$backgroundNeutralHeavy}/>
155+
<Badge marginR-10 customElement={this.customElement2} backgroundColor={Colors.$backgroundDisabled}/>
156156
</View>
157157
</ScrollView>
158158
</View>

src/components/badge/index.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -229,6 +229,7 @@ class Badge extends PureComponent<BadgeProps> {
229229
<Image
230230
source={icon!}
231231
resizeMode="contain"
232+
tintColor={Colors.$iconDefaultLight}
232233
//@ts-ignore
233234
borderColor={borderColor}
234235
{...iconProps}

0 commit comments

Comments
 (0)