@terreno/ui 0.6.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/README.md +5 -5
- 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 +13 -0
- package/dist/Common.js.map +1 -1
- package/dist/CommonIconTypes.d.ts +1 -1
- package/dist/FlatList.js.map +1 -1
- package/dist/GPTChat.d.ts +2 -1
- package/dist/GPTChat.js +14 -4
- package/dist/GPTChat.js.map +1 -1
- package/dist/Page.js +2 -1
- package/dist/Page.js.map +1 -1
- package/dist/ScrollView.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/dist/login/LoginScreen.js +1 -1
- package/dist/login/LoginScreen.js.map +1 -1
- package/dist/signUp/SignUpScreen.js +1 -1
- package/dist/signUp/SignUpScreen.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 +15 -0
- package/src/CommonIconTypes.ts +1 -1
- package/src/FlatList.tsx +1 -0
- package/src/GPTChat.tsx +40 -2
- package/src/Page.tsx +20 -9
- package/src/ScrollView.tsx +1 -0
- package/src/TextField.tsx +88 -69
- package/src/__snapshots__/AddressField.test.tsx.snap +208 -152
- package/src/__snapshots__/AiSuggestionBox.test.tsx.snap +1031 -0
- package/src/__snapshots__/CustomSelectField.test.tsx.snap +51 -37
- package/src/__snapshots__/EmailField.test.tsx.snap +111 -83
- package/src/__snapshots__/Field.test.tsx.snap +616 -448
- package/src/__snapshots__/MobileAddressAutoComplete.test.tsx.snap +51 -37
- package/src/__snapshots__/NumberField.test.tsx.snap +51 -37
- package/src/__snapshots__/Page.test.tsx.snap +15 -20
- package/src/__snapshots__/PhoneNumberField.test.tsx.snap +264 -194
- package/src/__snapshots__/TapToEdit.test.tsx.snap +51 -37
- package/src/__snapshots__/TextArea.test.tsx.snap +255 -185
- package/src/__snapshots__/TextField.test.tsx.snap +264 -194
- package/src/__snapshots__/UnifiedAddressAutoComplete.test.tsx.snap +204 -148
- package/src/__snapshots__/WebAddressAutocomplete.test.tsx.snap +153 -111
- package/src/index.tsx +1 -0
- package/src/login/LoginScreen.tsx +1 -0
- package/src/login/__snapshots__/LoginScreen.test.tsx.snap +104 -76
- package/src/signUp/SignUpScreen.tsx +1 -0
- package/src/signUp/__snapshots__/SignUpScreen.test.tsx.snap +156 -114
|
@@ -28,56 +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
|
-
"numberOfLines": 1,
|
|
45
|
-
"onBlur": [Function],
|
|
46
|
-
"onChangeText": [Function],
|
|
47
|
-
"onContentSizeChange": [Function],
|
|
48
|
-
"onFocus": [Function],
|
|
49
|
-
"onSubmitEditing": [Function],
|
|
50
|
-
"placeholder": "Enter an address",
|
|
51
|
-
"placeholderTextColor": "#686868",
|
|
52
|
-
"readOnly": undefined,
|
|
53
|
-
"ref": [Function],
|
|
54
|
-
"secureTextEntry": false,
|
|
76
|
+
],
|
|
77
|
+
"props": {
|
|
55
78
|
"style": {
|
|
56
|
-
"
|
|
57
|
-
"
|
|
58
|
-
"fontFamily": "text",
|
|
59
|
-
"fontSize": 16,
|
|
60
|
-
"gap": 10,
|
|
61
|
-
"height": 20,
|
|
62
|
-
"paddingVertical": 0,
|
|
63
|
-
"width": "100%",
|
|
79
|
+
"alignItems": "center",
|
|
80
|
+
"flexDirection": "row",
|
|
64
81
|
},
|
|
65
|
-
"testID":
|
|
66
|
-
"textContentType": "none",
|
|
67
|
-
"underlineColorAndroid": "transparent",
|
|
68
|
-
"value": "123 Main St",
|
|
82
|
+
"testID": undefined,
|
|
69
83
|
},
|
|
70
|
-
"type": "
|
|
84
|
+
"type": "View",
|
|
71
85
|
},
|
|
72
86
|
],
|
|
73
87
|
"props": {
|
|
74
88
|
"style": {
|
|
75
|
-
"alignItems": "center",
|
|
76
89
|
"backgroundColor": "#FFFFFF",
|
|
77
90
|
"borderColor": "#9A9A9A",
|
|
78
91
|
"borderRadius": 4,
|
|
79
92
|
"borderWidth": 1,
|
|
80
|
-
"flexDirection": "
|
|
93
|
+
"flexDirection": "column",
|
|
94
|
+
"gap": 0,
|
|
81
95
|
"overflow": "hidden",
|
|
82
96
|
"paddingHorizontal": 12,
|
|
83
97
|
"paddingVertical": 8,
|
|
@@ -131,56 +145,70 @@ exports[`AddressField renders correctly with default props 1`] = `
|
|
|
131
145
|
"children": [
|
|
132
146
|
{
|
|
133
147
|
"$$typeof": Symbol(react.test.json),
|
|
134
|
-
"children":
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
"
|
|
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",
|
|
139
192
|
},
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
"autoCorrect": true,
|
|
143
|
-
"blurOnSubmit": true,
|
|
144
|
-
"enterKeyHint": undefined,
|
|
145
|
-
"keyboardType": "default",
|
|
146
|
-
"multiline": undefined,
|
|
147
|
-
"numberOfLines": 1,
|
|
148
|
-
"onBlur": [Function],
|
|
149
|
-
"onChangeText": [Function],
|
|
150
|
-
"onContentSizeChange": [Function],
|
|
151
|
-
"onFocus": [Function],
|
|
152
|
-
"onSubmitEditing": [Function],
|
|
153
|
-
"placeholder": undefined,
|
|
154
|
-
"placeholderTextColor": "#686868",
|
|
155
|
-
"readOnly": undefined,
|
|
156
|
-
"ref": [Function],
|
|
157
|
-
"secureTextEntry": false,
|
|
193
|
+
],
|
|
194
|
+
"props": {
|
|
158
195
|
"style": {
|
|
159
|
-
"
|
|
160
|
-
"
|
|
161
|
-
"fontFamily": "text",
|
|
162
|
-
"fontSize": 16,
|
|
163
|
-
"gap": 10,
|
|
164
|
-
"height": 20,
|
|
165
|
-
"paddingVertical": 0,
|
|
166
|
-
"width": "100%",
|
|
196
|
+
"alignItems": "center",
|
|
197
|
+
"flexDirection": "row",
|
|
167
198
|
},
|
|
168
|
-
"testID":
|
|
169
|
-
"textContentType": "none",
|
|
170
|
-
"underlineColorAndroid": "transparent",
|
|
171
|
-
"value": "Apt 4B",
|
|
199
|
+
"testID": undefined,
|
|
172
200
|
},
|
|
173
|
-
"type": "
|
|
201
|
+
"type": "View",
|
|
174
202
|
},
|
|
175
203
|
],
|
|
176
204
|
"props": {
|
|
177
205
|
"style": {
|
|
178
|
-
"alignItems": "center",
|
|
179
206
|
"backgroundColor": "#FFFFFF",
|
|
180
207
|
"borderColor": "#9A9A9A",
|
|
181
208
|
"borderRadius": 4,
|
|
182
209
|
"borderWidth": 1,
|
|
183
|
-
"flexDirection": "
|
|
210
|
+
"flexDirection": "column",
|
|
211
|
+
"gap": 0,
|
|
184
212
|
"overflow": "hidden",
|
|
185
213
|
"paddingHorizontal": 12,
|
|
186
214
|
"paddingVertical": 8,
|
|
@@ -234,56 +262,70 @@ exports[`AddressField renders correctly with default props 1`] = `
|
|
|
234
262
|
"children": [
|
|
235
263
|
{
|
|
236
264
|
"$$typeof": Symbol(react.test.json),
|
|
237
|
-
"children":
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
"
|
|
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",
|
|
242
309
|
},
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
"autoCorrect": true,
|
|
246
|
-
"blurOnSubmit": true,
|
|
247
|
-
"enterKeyHint": undefined,
|
|
248
|
-
"keyboardType": "default",
|
|
249
|
-
"multiline": undefined,
|
|
250
|
-
"numberOfLines": 1,
|
|
251
|
-
"onBlur": [Function],
|
|
252
|
-
"onChangeText": [Function],
|
|
253
|
-
"onContentSizeChange": [Function],
|
|
254
|
-
"onFocus": [Function],
|
|
255
|
-
"onSubmitEditing": [Function],
|
|
256
|
-
"placeholder": undefined,
|
|
257
|
-
"placeholderTextColor": "#686868",
|
|
258
|
-
"readOnly": undefined,
|
|
259
|
-
"ref": [Function],
|
|
260
|
-
"secureTextEntry": false,
|
|
310
|
+
],
|
|
311
|
+
"props": {
|
|
261
312
|
"style": {
|
|
262
|
-
"
|
|
263
|
-
"
|
|
264
|
-
"fontFamily": "text",
|
|
265
|
-
"fontSize": 16,
|
|
266
|
-
"gap": 10,
|
|
267
|
-
"height": 20,
|
|
268
|
-
"paddingVertical": 0,
|
|
269
|
-
"width": "100%",
|
|
313
|
+
"alignItems": "center",
|
|
314
|
+
"flexDirection": "row",
|
|
270
315
|
},
|
|
271
|
-
"testID":
|
|
272
|
-
"textContentType": "none",
|
|
273
|
-
"underlineColorAndroid": "transparent",
|
|
274
|
-
"value": "Springfield",
|
|
316
|
+
"testID": undefined,
|
|
275
317
|
},
|
|
276
|
-
"type": "
|
|
318
|
+
"type": "View",
|
|
277
319
|
},
|
|
278
320
|
],
|
|
279
321
|
"props": {
|
|
280
322
|
"style": {
|
|
281
|
-
"alignItems": "center",
|
|
282
323
|
"backgroundColor": "#FFFFFF",
|
|
283
324
|
"borderColor": "#9A9A9A",
|
|
284
325
|
"borderRadius": 4,
|
|
285
326
|
"borderWidth": 1,
|
|
286
|
-
"flexDirection": "
|
|
327
|
+
"flexDirection": "column",
|
|
328
|
+
"gap": 0,
|
|
287
329
|
"overflow": "hidden",
|
|
288
330
|
"paddingHorizontal": 12,
|
|
289
331
|
"paddingVertical": 8,
|
|
@@ -1116,56 +1158,70 @@ exports[`AddressField renders correctly with default props 1`] = `
|
|
|
1116
1158
|
"children": [
|
|
1117
1159
|
{
|
|
1118
1160
|
"$$typeof": Symbol(react.test.json),
|
|
1119
|
-
"children":
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
"
|
|
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",
|
|
1124
1205
|
},
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
"autoCorrect": true,
|
|
1128
|
-
"blurOnSubmit": true,
|
|
1129
|
-
"enterKeyHint": undefined,
|
|
1130
|
-
"keyboardType": "default",
|
|
1131
|
-
"multiline": undefined,
|
|
1132
|
-
"numberOfLines": 1,
|
|
1133
|
-
"onBlur": [Function],
|
|
1134
|
-
"onChangeText": [Function],
|
|
1135
|
-
"onContentSizeChange": [Function],
|
|
1136
|
-
"onFocus": [Function],
|
|
1137
|
-
"onSubmitEditing": [Function],
|
|
1138
|
-
"placeholder": undefined,
|
|
1139
|
-
"placeholderTextColor": "#686868",
|
|
1140
|
-
"readOnly": undefined,
|
|
1141
|
-
"ref": [Function],
|
|
1142
|
-
"secureTextEntry": false,
|
|
1206
|
+
],
|
|
1207
|
+
"props": {
|
|
1143
1208
|
"style": {
|
|
1144
|
-
"
|
|
1145
|
-
"
|
|
1146
|
-
"fontFamily": "text",
|
|
1147
|
-
"fontSize": 16,
|
|
1148
|
-
"gap": 10,
|
|
1149
|
-
"height": 20,
|
|
1150
|
-
"paddingVertical": 0,
|
|
1151
|
-
"width": "100%",
|
|
1209
|
+
"alignItems": "center",
|
|
1210
|
+
"flexDirection": "row",
|
|
1152
1211
|
},
|
|
1153
|
-
"testID":
|
|
1154
|
-
"textContentType": "none",
|
|
1155
|
-
"underlineColorAndroid": "transparent",
|
|
1156
|
-
"value": "62701",
|
|
1212
|
+
"testID": undefined,
|
|
1157
1213
|
},
|
|
1158
|
-
"type": "
|
|
1214
|
+
"type": "View",
|
|
1159
1215
|
},
|
|
1160
1216
|
],
|
|
1161
1217
|
"props": {
|
|
1162
1218
|
"style": {
|
|
1163
|
-
"alignItems": "center",
|
|
1164
1219
|
"backgroundColor": "#FFFFFF",
|
|
1165
1220
|
"borderColor": "#9A9A9A",
|
|
1166
1221
|
"borderRadius": 4,
|
|
1167
1222
|
"borderWidth": 1,
|
|
1168
|
-
"flexDirection": "
|
|
1223
|
+
"flexDirection": "column",
|
|
1224
|
+
"gap": 0,
|
|
1169
1225
|
"overflow": "hidden",
|
|
1170
1226
|
"paddingHorizontal": 12,
|
|
1171
1227
|
"paddingVertical": 8,
|