@terreno/ui 0.7.0 → 0.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/AiSuggestionBox.d.ts +6 -0
- package/dist/AiSuggestionBox.js +87 -0
- package/dist/AiSuggestionBox.js.map +1 -0
- package/dist/Common.d.ts +12 -0
- package/dist/Common.js.map +1 -1
- package/dist/TextField.js +46 -41
- package/dist/TextField.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/AiSuggestionBox.test.tsx +373 -0
- package/src/AiSuggestionBox.tsx +233 -0
- package/src/Common.ts +14 -0
- package/src/TextField.tsx +87 -70
- package/src/__snapshots__/AddressField.test.tsx.snap +208 -156
- package/src/__snapshots__/AiSuggestionBox.test.tsx.snap +1031 -0
- package/src/__snapshots__/CustomSelectField.test.tsx.snap +51 -38
- package/src/__snapshots__/EmailField.test.tsx.snap +111 -85
- package/src/__snapshots__/Field.test.tsx.snap +616 -460
- package/src/__snapshots__/MobileAddressAutoComplete.test.tsx.snap +51 -38
- package/src/__snapshots__/NumberField.test.tsx.snap +51 -38
- package/src/__snapshots__/PhoneNumberField.test.tsx.snap +264 -199
- package/src/__snapshots__/TapToEdit.test.tsx.snap +51 -38
- package/src/__snapshots__/TextArea.test.tsx.snap +255 -190
- package/src/__snapshots__/TextField.test.tsx.snap +264 -199
- package/src/__snapshots__/UnifiedAddressAutoComplete.test.tsx.snap +204 -152
- package/src/__snapshots__/WebAddressAutocomplete.test.tsx.snap +153 -114
- package/src/index.tsx +1 -0
- package/src/login/__snapshots__/LoginScreen.test.tsx.snap +104 -78
- package/src/signUp/__snapshots__/SignUpScreen.test.tsx.snap +156 -117
package/src/TextField.tsx
CHANGED
|
@@ -10,6 +10,7 @@ import {
|
|
|
10
10
|
View,
|
|
11
11
|
} from "react-native";
|
|
12
12
|
|
|
13
|
+
import {AiSuggestionBox} from "./AiSuggestionBox";
|
|
13
14
|
import type {TextFieldProps, TextStyleWithOutline} from "./Common";
|
|
14
15
|
import {FieldError, FieldHelperText, FieldTitle} from "./fieldElements";
|
|
15
16
|
import {Icon} from "./Icon";
|
|
@@ -79,6 +80,7 @@ export const TextField: FC<TextFieldProps> = ({
|
|
|
79
80
|
onSubmitEditing,
|
|
80
81
|
testID,
|
|
81
82
|
id,
|
|
83
|
+
aiSuggestion,
|
|
82
84
|
}) => {
|
|
83
85
|
const {theme} = useTheme();
|
|
84
86
|
|
|
@@ -147,87 +149,102 @@ export const TextField: FC<TextFieldProps> = ({
|
|
|
147
149
|
{Boolean(errorText) && <FieldError text={errorText!} />}
|
|
148
150
|
<View
|
|
149
151
|
style={{
|
|
150
|
-
alignItems: "center",
|
|
151
152
|
backgroundColor: disabled ? theme.surface.neutralLight : theme.surface.base,
|
|
152
153
|
borderColor,
|
|
153
154
|
borderRadius: 4,
|
|
154
155
|
borderWidth: focused ? 3 : 1,
|
|
155
|
-
flexDirection: "
|
|
156
|
+
flexDirection: "column",
|
|
157
|
+
gap: aiSuggestion ? 10 : 0,
|
|
156
158
|
overflow: "hidden",
|
|
157
159
|
paddingHorizontal: focused ? 10 : 12,
|
|
158
160
|
paddingVertical: focused ? 6 : 8,
|
|
159
161
|
}}
|
|
160
162
|
>
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
163
|
+
{Boolean(aiSuggestion) && (
|
|
164
|
+
<AiSuggestionBox
|
|
165
|
+
testID={testID ? `${testID}-ai-suggestion` : undefined}
|
|
166
|
+
{...aiSuggestion!}
|
|
167
|
+
/>
|
|
168
|
+
)}
|
|
169
|
+
<View
|
|
170
|
+
style={{
|
|
171
|
+
alignItems: "center",
|
|
172
|
+
flexDirection: "row",
|
|
173
|
+
}}
|
|
174
|
+
>
|
|
175
|
+
<TextInput
|
|
176
|
+
accessibilityHint="Enter text here"
|
|
177
|
+
accessibilityState={{disabled}}
|
|
178
|
+
aria-label="Text input field"
|
|
179
|
+
autoCapitalize={type === "text" ? "sentences" : "none"}
|
|
180
|
+
autoCorrect={shouldAutocorrect}
|
|
181
|
+
blurOnSubmit={blurOnSubmit}
|
|
182
|
+
enterKeyHint={returnKeyType}
|
|
183
|
+
keyboardType={keyboardType as KeyboardTypeOptions}
|
|
184
|
+
multiline={multiline}
|
|
185
|
+
nativeID={id}
|
|
186
|
+
numberOfLines={rows || 4}
|
|
187
|
+
onBlur={() => {
|
|
188
|
+
if (disabled) {
|
|
189
|
+
return;
|
|
190
|
+
}
|
|
191
|
+
let finalValue = value ?? "";
|
|
176
192
|
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
193
|
+
if (trimOnBlur && value) {
|
|
194
|
+
finalValue = finalValue.trim();
|
|
195
|
+
if (finalValue !== value) {
|
|
196
|
+
onChange(finalValue);
|
|
197
|
+
}
|
|
181
198
|
}
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
}
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
}
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
}
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
199
|
+
if (onBlur) {
|
|
200
|
+
onBlur(finalValue);
|
|
201
|
+
}
|
|
202
|
+
setFocused(false);
|
|
203
|
+
}}
|
|
204
|
+
onChangeText={onChange}
|
|
205
|
+
onContentSizeChange={(event) => {
|
|
206
|
+
if (!grow) {
|
|
207
|
+
return;
|
|
208
|
+
}
|
|
209
|
+
setHeight(event.nativeEvent.contentSize.height);
|
|
210
|
+
}}
|
|
211
|
+
onFocus={() => {
|
|
212
|
+
if (!disabled) {
|
|
213
|
+
setFocused(true);
|
|
214
|
+
}
|
|
215
|
+
if (onFocus) {
|
|
216
|
+
onFocus();
|
|
217
|
+
}
|
|
218
|
+
}}
|
|
219
|
+
onSubmitEditing={() => {
|
|
220
|
+
if (onEnter) {
|
|
221
|
+
onEnter();
|
|
222
|
+
}
|
|
223
|
+
if (onSubmitEditing) {
|
|
224
|
+
onSubmitEditing();
|
|
225
|
+
}
|
|
226
|
+
}}
|
|
227
|
+
placeholder={placeholder}
|
|
228
|
+
placeholderTextColor={theme.text.secondaryLight}
|
|
229
|
+
readOnly={disabled}
|
|
230
|
+
ref={(ref) => {
|
|
231
|
+
if (inputRef) {
|
|
232
|
+
inputRef(ref);
|
|
233
|
+
}
|
|
234
|
+
}}
|
|
235
|
+
secureTextEntry={type === "password"}
|
|
236
|
+
style={defaultTextInputStyles}
|
|
237
|
+
testID={testID}
|
|
238
|
+
textContentType={textContentType}
|
|
239
|
+
underlineColorAndroid="transparent"
|
|
240
|
+
value={value}
|
|
241
|
+
/>
|
|
242
|
+
{Boolean(iconName) && (
|
|
243
|
+
<Pressable aria-role="button" onPress={onIconClick}>
|
|
244
|
+
<Icon iconName={iconName!} size="md" />
|
|
245
|
+
</Pressable>
|
|
246
|
+
)}
|
|
247
|
+
</View>
|
|
231
248
|
</View>
|
|
232
249
|
{Boolean(helperText) && <FieldHelperText text={helperText!} />}
|
|
233
250
|
{/* {type === "numberRange" && value && (
|
|
@@ -28,57 +28,70 @@ exports[`AddressField renders correctly with default props 1`] = `
|
|
|
28
28
|
"children": [
|
|
29
29
|
{
|
|
30
30
|
"$$typeof": Symbol(react.test.json),
|
|
31
|
-
"children":
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
"
|
|
31
|
+
"children": [
|
|
32
|
+
{
|
|
33
|
+
"$$typeof": Symbol(react.test.json),
|
|
34
|
+
"children": null,
|
|
35
|
+
"props": {
|
|
36
|
+
"accessibilityHint": "Enter text here",
|
|
37
|
+
"accessibilityState": {
|
|
38
|
+
"disabled": undefined,
|
|
39
|
+
},
|
|
40
|
+
"aria-label": "Text input field",
|
|
41
|
+
"autoCapitalize": "sentences",
|
|
42
|
+
"autoCorrect": true,
|
|
43
|
+
"blurOnSubmit": true,
|
|
44
|
+
"enterKeyHint": undefined,
|
|
45
|
+
"keyboardType": "default",
|
|
46
|
+
"multiline": undefined,
|
|
47
|
+
"nativeID": undefined,
|
|
48
|
+
"numberOfLines": 1,
|
|
49
|
+
"onBlur": [Function],
|
|
50
|
+
"onChangeText": [Function],
|
|
51
|
+
"onContentSizeChange": [Function],
|
|
52
|
+
"onFocus": [Function],
|
|
53
|
+
"onSubmitEditing": [Function],
|
|
54
|
+
"placeholder": "Enter an address",
|
|
55
|
+
"placeholderTextColor": "#686868",
|
|
56
|
+
"readOnly": undefined,
|
|
57
|
+
"ref": [Function],
|
|
58
|
+
"secureTextEntry": false,
|
|
59
|
+
"style": {
|
|
60
|
+
"color": "#1C1C1C",
|
|
61
|
+
"flex": 1,
|
|
62
|
+
"fontFamily": "text",
|
|
63
|
+
"fontSize": 16,
|
|
64
|
+
"gap": 10,
|
|
65
|
+
"height": 20,
|
|
66
|
+
"paddingVertical": 0,
|
|
67
|
+
"width": "100%",
|
|
68
|
+
},
|
|
69
|
+
"testID": "test-address-address1",
|
|
70
|
+
"textContentType": "none",
|
|
71
|
+
"underlineColorAndroid": "transparent",
|
|
72
|
+
"value": "123 Main St",
|
|
73
|
+
},
|
|
74
|
+
"type": "TextInput",
|
|
36
75
|
},
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
"autoCorrect": true,
|
|
40
|
-
"blurOnSubmit": true,
|
|
41
|
-
"enterKeyHint": undefined,
|
|
42
|
-
"keyboardType": "default",
|
|
43
|
-
"multiline": undefined,
|
|
44
|
-
"nativeID": undefined,
|
|
45
|
-
"numberOfLines": 1,
|
|
46
|
-
"onBlur": [Function],
|
|
47
|
-
"onChangeText": [Function],
|
|
48
|
-
"onContentSizeChange": [Function],
|
|
49
|
-
"onFocus": [Function],
|
|
50
|
-
"onSubmitEditing": [Function],
|
|
51
|
-
"placeholder": "Enter an address",
|
|
52
|
-
"placeholderTextColor": "#686868",
|
|
53
|
-
"readOnly": undefined,
|
|
54
|
-
"ref": [Function],
|
|
55
|
-
"secureTextEntry": false,
|
|
76
|
+
],
|
|
77
|
+
"props": {
|
|
56
78
|
"style": {
|
|
57
|
-
"
|
|
58
|
-
"
|
|
59
|
-
"fontFamily": "text",
|
|
60
|
-
"fontSize": 16,
|
|
61
|
-
"gap": 10,
|
|
62
|
-
"height": 20,
|
|
63
|
-
"paddingVertical": 0,
|
|
64
|
-
"width": "100%",
|
|
79
|
+
"alignItems": "center",
|
|
80
|
+
"flexDirection": "row",
|
|
65
81
|
},
|
|
66
|
-
"testID":
|
|
67
|
-
"textContentType": "none",
|
|
68
|
-
"underlineColorAndroid": "transparent",
|
|
69
|
-
"value": "123 Main St",
|
|
82
|
+
"testID": undefined,
|
|
70
83
|
},
|
|
71
|
-
"type": "
|
|
84
|
+
"type": "View",
|
|
72
85
|
},
|
|
73
86
|
],
|
|
74
87
|
"props": {
|
|
75
88
|
"style": {
|
|
76
|
-
"alignItems": "center",
|
|
77
89
|
"backgroundColor": "#FFFFFF",
|
|
78
90
|
"borderColor": "#9A9A9A",
|
|
79
91
|
"borderRadius": 4,
|
|
80
92
|
"borderWidth": 1,
|
|
81
|
-
"flexDirection": "
|
|
93
|
+
"flexDirection": "column",
|
|
94
|
+
"gap": 0,
|
|
82
95
|
"overflow": "hidden",
|
|
83
96
|
"paddingHorizontal": 12,
|
|
84
97
|
"paddingVertical": 8,
|
|
@@ -132,57 +145,70 @@ exports[`AddressField renders correctly with default props 1`] = `
|
|
|
132
145
|
"children": [
|
|
133
146
|
{
|
|
134
147
|
"$$typeof": Symbol(react.test.json),
|
|
135
|
-
"children":
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
"
|
|
148
|
+
"children": [
|
|
149
|
+
{
|
|
150
|
+
"$$typeof": Symbol(react.test.json),
|
|
151
|
+
"children": null,
|
|
152
|
+
"props": {
|
|
153
|
+
"accessibilityHint": "Enter text here",
|
|
154
|
+
"accessibilityState": {
|
|
155
|
+
"disabled": undefined,
|
|
156
|
+
},
|
|
157
|
+
"aria-label": "Text input field",
|
|
158
|
+
"autoCapitalize": "sentences",
|
|
159
|
+
"autoCorrect": true,
|
|
160
|
+
"blurOnSubmit": true,
|
|
161
|
+
"enterKeyHint": undefined,
|
|
162
|
+
"keyboardType": "default",
|
|
163
|
+
"multiline": undefined,
|
|
164
|
+
"nativeID": "address2",
|
|
165
|
+
"numberOfLines": 1,
|
|
166
|
+
"onBlur": [Function],
|
|
167
|
+
"onChangeText": [Function],
|
|
168
|
+
"onContentSizeChange": [Function],
|
|
169
|
+
"onFocus": [Function],
|
|
170
|
+
"onSubmitEditing": [Function],
|
|
171
|
+
"placeholder": undefined,
|
|
172
|
+
"placeholderTextColor": "#686868",
|
|
173
|
+
"readOnly": undefined,
|
|
174
|
+
"ref": [Function],
|
|
175
|
+
"secureTextEntry": false,
|
|
176
|
+
"style": {
|
|
177
|
+
"color": "#1C1C1C",
|
|
178
|
+
"flex": 1,
|
|
179
|
+
"fontFamily": "text",
|
|
180
|
+
"fontSize": 16,
|
|
181
|
+
"gap": 10,
|
|
182
|
+
"height": 20,
|
|
183
|
+
"paddingVertical": 0,
|
|
184
|
+
"width": "100%",
|
|
185
|
+
},
|
|
186
|
+
"testID": "test-address-address2",
|
|
187
|
+
"textContentType": "none",
|
|
188
|
+
"underlineColorAndroid": "transparent",
|
|
189
|
+
"value": "Apt 4B",
|
|
190
|
+
},
|
|
191
|
+
"type": "TextInput",
|
|
140
192
|
},
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
"autoCorrect": true,
|
|
144
|
-
"blurOnSubmit": true,
|
|
145
|
-
"enterKeyHint": undefined,
|
|
146
|
-
"keyboardType": "default",
|
|
147
|
-
"multiline": undefined,
|
|
148
|
-
"nativeID": "address2",
|
|
149
|
-
"numberOfLines": 1,
|
|
150
|
-
"onBlur": [Function],
|
|
151
|
-
"onChangeText": [Function],
|
|
152
|
-
"onContentSizeChange": [Function],
|
|
153
|
-
"onFocus": [Function],
|
|
154
|
-
"onSubmitEditing": [Function],
|
|
155
|
-
"placeholder": undefined,
|
|
156
|
-
"placeholderTextColor": "#686868",
|
|
157
|
-
"readOnly": undefined,
|
|
158
|
-
"ref": [Function],
|
|
159
|
-
"secureTextEntry": false,
|
|
193
|
+
],
|
|
194
|
+
"props": {
|
|
160
195
|
"style": {
|
|
161
|
-
"
|
|
162
|
-
"
|
|
163
|
-
"fontFamily": "text",
|
|
164
|
-
"fontSize": 16,
|
|
165
|
-
"gap": 10,
|
|
166
|
-
"height": 20,
|
|
167
|
-
"paddingVertical": 0,
|
|
168
|
-
"width": "100%",
|
|
196
|
+
"alignItems": "center",
|
|
197
|
+
"flexDirection": "row",
|
|
169
198
|
},
|
|
170
|
-
"testID":
|
|
171
|
-
"textContentType": "none",
|
|
172
|
-
"underlineColorAndroid": "transparent",
|
|
173
|
-
"value": "Apt 4B",
|
|
199
|
+
"testID": undefined,
|
|
174
200
|
},
|
|
175
|
-
"type": "
|
|
201
|
+
"type": "View",
|
|
176
202
|
},
|
|
177
203
|
],
|
|
178
204
|
"props": {
|
|
179
205
|
"style": {
|
|
180
|
-
"alignItems": "center",
|
|
181
206
|
"backgroundColor": "#FFFFFF",
|
|
182
207
|
"borderColor": "#9A9A9A",
|
|
183
208
|
"borderRadius": 4,
|
|
184
209
|
"borderWidth": 1,
|
|
185
|
-
"flexDirection": "
|
|
210
|
+
"flexDirection": "column",
|
|
211
|
+
"gap": 0,
|
|
186
212
|
"overflow": "hidden",
|
|
187
213
|
"paddingHorizontal": 12,
|
|
188
214
|
"paddingVertical": 8,
|
|
@@ -236,57 +262,70 @@ exports[`AddressField renders correctly with default props 1`] = `
|
|
|
236
262
|
"children": [
|
|
237
263
|
{
|
|
238
264
|
"$$typeof": Symbol(react.test.json),
|
|
239
|
-
"children":
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
"
|
|
265
|
+
"children": [
|
|
266
|
+
{
|
|
267
|
+
"$$typeof": Symbol(react.test.json),
|
|
268
|
+
"children": null,
|
|
269
|
+
"props": {
|
|
270
|
+
"accessibilityHint": "Enter text here",
|
|
271
|
+
"accessibilityState": {
|
|
272
|
+
"disabled": undefined,
|
|
273
|
+
},
|
|
274
|
+
"aria-label": "Text input field",
|
|
275
|
+
"autoCapitalize": "sentences",
|
|
276
|
+
"autoCorrect": true,
|
|
277
|
+
"blurOnSubmit": true,
|
|
278
|
+
"enterKeyHint": undefined,
|
|
279
|
+
"keyboardType": "default",
|
|
280
|
+
"multiline": undefined,
|
|
281
|
+
"nativeID": "city",
|
|
282
|
+
"numberOfLines": 1,
|
|
283
|
+
"onBlur": [Function],
|
|
284
|
+
"onChangeText": [Function],
|
|
285
|
+
"onContentSizeChange": [Function],
|
|
286
|
+
"onFocus": [Function],
|
|
287
|
+
"onSubmitEditing": [Function],
|
|
288
|
+
"placeholder": undefined,
|
|
289
|
+
"placeholderTextColor": "#686868",
|
|
290
|
+
"readOnly": undefined,
|
|
291
|
+
"ref": [Function],
|
|
292
|
+
"secureTextEntry": false,
|
|
293
|
+
"style": {
|
|
294
|
+
"color": "#1C1C1C",
|
|
295
|
+
"flex": 1,
|
|
296
|
+
"fontFamily": "text",
|
|
297
|
+
"fontSize": 16,
|
|
298
|
+
"gap": 10,
|
|
299
|
+
"height": 20,
|
|
300
|
+
"paddingVertical": 0,
|
|
301
|
+
"width": "100%",
|
|
302
|
+
},
|
|
303
|
+
"testID": "test-address-city",
|
|
304
|
+
"textContentType": "none",
|
|
305
|
+
"underlineColorAndroid": "transparent",
|
|
306
|
+
"value": "Springfield",
|
|
307
|
+
},
|
|
308
|
+
"type": "TextInput",
|
|
244
309
|
},
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
"autoCorrect": true,
|
|
248
|
-
"blurOnSubmit": true,
|
|
249
|
-
"enterKeyHint": undefined,
|
|
250
|
-
"keyboardType": "default",
|
|
251
|
-
"multiline": undefined,
|
|
252
|
-
"nativeID": "city",
|
|
253
|
-
"numberOfLines": 1,
|
|
254
|
-
"onBlur": [Function],
|
|
255
|
-
"onChangeText": [Function],
|
|
256
|
-
"onContentSizeChange": [Function],
|
|
257
|
-
"onFocus": [Function],
|
|
258
|
-
"onSubmitEditing": [Function],
|
|
259
|
-
"placeholder": undefined,
|
|
260
|
-
"placeholderTextColor": "#686868",
|
|
261
|
-
"readOnly": undefined,
|
|
262
|
-
"ref": [Function],
|
|
263
|
-
"secureTextEntry": false,
|
|
310
|
+
],
|
|
311
|
+
"props": {
|
|
264
312
|
"style": {
|
|
265
|
-
"
|
|
266
|
-
"
|
|
267
|
-
"fontFamily": "text",
|
|
268
|
-
"fontSize": 16,
|
|
269
|
-
"gap": 10,
|
|
270
|
-
"height": 20,
|
|
271
|
-
"paddingVertical": 0,
|
|
272
|
-
"width": "100%",
|
|
313
|
+
"alignItems": "center",
|
|
314
|
+
"flexDirection": "row",
|
|
273
315
|
},
|
|
274
|
-
"testID":
|
|
275
|
-
"textContentType": "none",
|
|
276
|
-
"underlineColorAndroid": "transparent",
|
|
277
|
-
"value": "Springfield",
|
|
316
|
+
"testID": undefined,
|
|
278
317
|
},
|
|
279
|
-
"type": "
|
|
318
|
+
"type": "View",
|
|
280
319
|
},
|
|
281
320
|
],
|
|
282
321
|
"props": {
|
|
283
322
|
"style": {
|
|
284
|
-
"alignItems": "center",
|
|
285
323
|
"backgroundColor": "#FFFFFF",
|
|
286
324
|
"borderColor": "#9A9A9A",
|
|
287
325
|
"borderRadius": 4,
|
|
288
326
|
"borderWidth": 1,
|
|
289
|
-
"flexDirection": "
|
|
327
|
+
"flexDirection": "column",
|
|
328
|
+
"gap": 0,
|
|
290
329
|
"overflow": "hidden",
|
|
291
330
|
"paddingHorizontal": 12,
|
|
292
331
|
"paddingVertical": 8,
|
|
@@ -1119,57 +1158,70 @@ exports[`AddressField renders correctly with default props 1`] = `
|
|
|
1119
1158
|
"children": [
|
|
1120
1159
|
{
|
|
1121
1160
|
"$$typeof": Symbol(react.test.json),
|
|
1122
|
-
"children":
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
"
|
|
1161
|
+
"children": [
|
|
1162
|
+
{
|
|
1163
|
+
"$$typeof": Symbol(react.test.json),
|
|
1164
|
+
"children": null,
|
|
1165
|
+
"props": {
|
|
1166
|
+
"accessibilityHint": "Enter text here",
|
|
1167
|
+
"accessibilityState": {
|
|
1168
|
+
"disabled": undefined,
|
|
1169
|
+
},
|
|
1170
|
+
"aria-label": "Text input field",
|
|
1171
|
+
"autoCapitalize": "sentences",
|
|
1172
|
+
"autoCorrect": true,
|
|
1173
|
+
"blurOnSubmit": true,
|
|
1174
|
+
"enterKeyHint": undefined,
|
|
1175
|
+
"keyboardType": "default",
|
|
1176
|
+
"multiline": undefined,
|
|
1177
|
+
"nativeID": "zipcode",
|
|
1178
|
+
"numberOfLines": 1,
|
|
1179
|
+
"onBlur": [Function],
|
|
1180
|
+
"onChangeText": [Function],
|
|
1181
|
+
"onContentSizeChange": [Function],
|
|
1182
|
+
"onFocus": [Function],
|
|
1183
|
+
"onSubmitEditing": [Function],
|
|
1184
|
+
"placeholder": undefined,
|
|
1185
|
+
"placeholderTextColor": "#686868",
|
|
1186
|
+
"readOnly": undefined,
|
|
1187
|
+
"ref": [Function],
|
|
1188
|
+
"secureTextEntry": false,
|
|
1189
|
+
"style": {
|
|
1190
|
+
"color": "#1C1C1C",
|
|
1191
|
+
"flex": 1,
|
|
1192
|
+
"fontFamily": "text",
|
|
1193
|
+
"fontSize": 16,
|
|
1194
|
+
"gap": 10,
|
|
1195
|
+
"height": 20,
|
|
1196
|
+
"paddingVertical": 0,
|
|
1197
|
+
"width": "100%",
|
|
1198
|
+
},
|
|
1199
|
+
"testID": "test-address-zip",
|
|
1200
|
+
"textContentType": "none",
|
|
1201
|
+
"underlineColorAndroid": "transparent",
|
|
1202
|
+
"value": "62701",
|
|
1203
|
+
},
|
|
1204
|
+
"type": "TextInput",
|
|
1127
1205
|
},
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
"autoCorrect": true,
|
|
1131
|
-
"blurOnSubmit": true,
|
|
1132
|
-
"enterKeyHint": undefined,
|
|
1133
|
-
"keyboardType": "default",
|
|
1134
|
-
"multiline": undefined,
|
|
1135
|
-
"nativeID": "zipcode",
|
|
1136
|
-
"numberOfLines": 1,
|
|
1137
|
-
"onBlur": [Function],
|
|
1138
|
-
"onChangeText": [Function],
|
|
1139
|
-
"onContentSizeChange": [Function],
|
|
1140
|
-
"onFocus": [Function],
|
|
1141
|
-
"onSubmitEditing": [Function],
|
|
1142
|
-
"placeholder": undefined,
|
|
1143
|
-
"placeholderTextColor": "#686868",
|
|
1144
|
-
"readOnly": undefined,
|
|
1145
|
-
"ref": [Function],
|
|
1146
|
-
"secureTextEntry": false,
|
|
1206
|
+
],
|
|
1207
|
+
"props": {
|
|
1147
1208
|
"style": {
|
|
1148
|
-
"
|
|
1149
|
-
"
|
|
1150
|
-
"fontFamily": "text",
|
|
1151
|
-
"fontSize": 16,
|
|
1152
|
-
"gap": 10,
|
|
1153
|
-
"height": 20,
|
|
1154
|
-
"paddingVertical": 0,
|
|
1155
|
-
"width": "100%",
|
|
1209
|
+
"alignItems": "center",
|
|
1210
|
+
"flexDirection": "row",
|
|
1156
1211
|
},
|
|
1157
|
-
"testID":
|
|
1158
|
-
"textContentType": "none",
|
|
1159
|
-
"underlineColorAndroid": "transparent",
|
|
1160
|
-
"value": "62701",
|
|
1212
|
+
"testID": undefined,
|
|
1161
1213
|
},
|
|
1162
|
-
"type": "
|
|
1214
|
+
"type": "View",
|
|
1163
1215
|
},
|
|
1164
1216
|
],
|
|
1165
1217
|
"props": {
|
|
1166
1218
|
"style": {
|
|
1167
|
-
"alignItems": "center",
|
|
1168
1219
|
"backgroundColor": "#FFFFFF",
|
|
1169
1220
|
"borderColor": "#9A9A9A",
|
|
1170
1221
|
"borderRadius": 4,
|
|
1171
1222
|
"borderWidth": 1,
|
|
1172
|
-
"flexDirection": "
|
|
1223
|
+
"flexDirection": "column",
|
|
1224
|
+
"gap": 0,
|
|
1173
1225
|
"overflow": "hidden",
|
|
1174
1226
|
"paddingHorizontal": 12,
|
|
1175
1227
|
"paddingVertical": 8,
|