@@ -12,22 +12,56 @@ import type {RNTesterModuleExample} from '../../types/RNTesterTypes';
1212
1313import RNTesterText from '../../components/RNTesterText' ;
1414import * as React from 'react' ;
15- import { StyleSheet , View } from 'react-native' ;
15+ import { StyleSheet , Text , TextInput , View } from 'react-native' ;
1616
17+ // https://github.com/react/react-native/issues/60013
18+ // Change the OS text size while the app runs (Settings > Accessibility >
19+ // Display & Text Size > Larger Text, or
20+ // `xcrun simctl ui booted content_size accessibility-large`), then go back.
21+ // Expected: "word" stays red and in Courier in both inputs.
22+ // Actual on iOS: the single-line input draws all of its text in the default
23+ // color and font.
1724function Playground ( ) {
1825 return (
1926 < View style = { styles . container } >
2027 < RNTesterText >
21- Edit "RNTesterPlayground.js" to change this file
28+ Change the OS text size (Settings > Accessibility > Display &
29+ Text Size > Larger Text), then come back. "word" must stay
30+ red and in Courier in both inputs.
2231 </ RNTesterText >
32+ < RNTesterText > Single-line</ RNTesterText >
33+ < TextInput testID = "playground-singleline" style = { styles . input } >
34+ < Text >
35+ plain < Text style = { styles . word } > word</ Text > end
36+ </ Text >
37+ </ TextInput >
38+ < RNTesterText > Multiline</ RNTesterText >
39+ < TextInput
40+ testID = "playground-multiline"
41+ multiline = { true }
42+ style = { styles . input } >
43+ < Text >
44+ plain < Text style = { styles . word } > word</ Text > end
45+ </ Text >
46+ </ TextInput >
2347 </ View >
2448 ) ;
2549}
2650
2751const styles = StyleSheet . create ( {
2852 container : {
53+ gap : 12 ,
2954 padding : 10 ,
3055 } ,
56+ input : {
57+ borderWidth : 1 ,
58+ fontSize : 18 ,
59+ padding : 8 ,
60+ } ,
61+ word : {
62+ color : 'red' ,
63+ fontFamily : 'Courier' ,
64+ } ,
3165} ) ;
3266
3367export default {
0 commit comments