Skip to content

Commit 0798ec8

Browse files
Abbondanzofacebook-github-bot
authored andcommitted
Add Switch screenshot coverage for props reconciliation (#58470)
Summary: Add Jest E2E screenshot coverage for transparent Android `Switch` thumbs under the baseline and props update reconciliation configurations. Register reconciliation as an explicit opt-in config and apply its flags through the pre-startup feature flag provider. Changelog: [Internal] Differential Revision: D117232722
1 parent e15b667 commit 0798ec8

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

packages/rn-tester/js/examples/Switch/SwitchExample.js

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -267,6 +267,15 @@ class ContainerBackgroundColorStyleExample extends React.Component<
267267
}
268268
}
269269

270+
function TransparentExample() {
271+
return (
272+
<View>
273+
<Switch value thumbColor="transparent" />
274+
<Switch value thumbColor="#FF000000" />
275+
</View>
276+
);
277+
}
278+
270279
exports.title = 'Switch';
271280
exports.documentationURL = 'https://reactnative.dev/docs/switch';
272281
exports.category = 'UI';
@@ -320,6 +329,13 @@ exports.examples = [
320329
return <ContainerBackgroundColorStyleExample />;
321330
},
322331
},
332+
{
333+
title: 'The switch thumb renders transparent',
334+
name: 'transparent-thumb-color',
335+
render(): React.MixedElement {
336+
return <TransparentExample />;
337+
},
338+
},
323339
] as Array<RNTesterModuleExample>;
324340

325341
if (Platform.OS === 'ios') {

0 commit comments

Comments
 (0)