File tree Expand file tree Collapse file tree 4 files changed +85
-54
lines changed
packages/react-native-web/src Expand file tree Collapse file tree 4 files changed +85
-54
lines changed Original file line number Diff line number Diff line change @@ -66,7 +66,10 @@ const CheckBox: React.AbstractComponent<
66
66
checked : value ,
67
67
disabled : disabled ,
68
68
onChange : handleChange ,
69
- readOnly : readOnly || ariaReadOnly || other . accessibilityReadOnly ,
69
+ readOnly :
70
+ readOnly === true ||
71
+ ariaReadOnly === true ||
72
+ other . accessibilityReadOnly === true ,
70
73
ref : forwardedRef ,
71
74
style : [ styles . nativeControl , styles . cursorInherit ] ,
72
75
type : 'checkbox'
Original file line number Diff line number Diff line change @@ -135,7 +135,7 @@ const TextInput: React.AbstractComponent<
135
135
placeholderTextColor,
136
136
readOnly = false ,
137
137
returnKeyType,
138
- rows = 1 ,
138
+ rows,
139
139
secureTextEntry = false ,
140
140
selection,
141
141
selectTextOnFocus,
@@ -389,18 +389,14 @@ const TextInput: React.AbstractComponent<
389
389
if ( editable != null ) {
390
390
warnOnce ( 'editable' , 'editable is deprecated. Use readOnly.' ) ;
391
391
}
392
- supportedProps . readOnly = readOnly || ! editable ;
392
+ supportedProps . readOnly = readOnly === true || editable === false ;
393
393
if ( numberOfLines != null ) {
394
394
warnOnce (
395
395
'numberOfLines' ,
396
396
'TextInput numberOfLines is deprecated. Use rows.'
397
397
) ;
398
398
}
399
- supportedProps . rows = multiline
400
- ? rows != null
401
- ? rows
402
- : numberOfLines
403
- : undefined ;
399
+ supportedProps . rows = multiline ? ( rows != null ? rows : numberOfLines ) : 1 ;
404
400
supportedProps . spellCheck = spellCheck != null ? spellCheck : autoCorrect ;
405
401
supportedProps . style = [
406
402
{ '--placeholderTextColor' : placeholderTextColor } ,
Original file line number Diff line number Diff line change @@ -71,7 +71,7 @@ describe('modules/createDOMProps', () => {
71
71
expect ( _props ) . toMatchInlineSnapshot ( `
72
72
{
73
73
"aria-activedescendant": "activedescendant",
74
- "aria-atomic": true ,
74
+ "aria-atomic": "activedescendant" ,
75
75
"aria-autocomplete": "list",
76
76
"aria-busy": true,
77
77
"aria-checked": true,
@@ -112,6 +112,7 @@ describe('modules/createDOMProps', () => {
112
112
"aria-setsize": 5,
113
113
"aria-sort": "ascending",
114
114
"aria-valuemax": 5,
115
+ "aria-valuemin": 0,
115
116
"aria-valuenow": 3,
116
117
"aria-valuetext": "3",
117
118
"className": "className",
You can’t perform that action at this time.
0 commit comments