@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.
Files changed (52) hide show
  1. package/README.md +5 -5
  2. package/dist/AiSuggestionBox.d.ts +6 -0
  3. package/dist/AiSuggestionBox.js +87 -0
  4. package/dist/AiSuggestionBox.js.map +1 -0
  5. package/dist/Common.d.ts +13 -0
  6. package/dist/Common.js.map +1 -1
  7. package/dist/CommonIconTypes.d.ts +1 -1
  8. package/dist/FlatList.js.map +1 -1
  9. package/dist/GPTChat.d.ts +2 -1
  10. package/dist/GPTChat.js +14 -4
  11. package/dist/GPTChat.js.map +1 -1
  12. package/dist/Page.js +2 -1
  13. package/dist/Page.js.map +1 -1
  14. package/dist/ScrollView.js.map +1 -1
  15. package/dist/TextField.js +46 -41
  16. package/dist/TextField.js.map +1 -1
  17. package/dist/index.d.ts +1 -0
  18. package/dist/index.js +1 -0
  19. package/dist/index.js.map +1 -1
  20. package/dist/login/LoginScreen.js +1 -1
  21. package/dist/login/LoginScreen.js.map +1 -1
  22. package/dist/signUp/SignUpScreen.js +1 -1
  23. package/dist/signUp/SignUpScreen.js.map +1 -1
  24. package/package.json +1 -1
  25. package/src/AiSuggestionBox.test.tsx +373 -0
  26. package/src/AiSuggestionBox.tsx +233 -0
  27. package/src/Common.ts +15 -0
  28. package/src/CommonIconTypes.ts +1 -1
  29. package/src/FlatList.tsx +1 -0
  30. package/src/GPTChat.tsx +40 -2
  31. package/src/Page.tsx +20 -9
  32. package/src/ScrollView.tsx +1 -0
  33. package/src/TextField.tsx +88 -69
  34. package/src/__snapshots__/AddressField.test.tsx.snap +208 -152
  35. package/src/__snapshots__/AiSuggestionBox.test.tsx.snap +1031 -0
  36. package/src/__snapshots__/CustomSelectField.test.tsx.snap +51 -37
  37. package/src/__snapshots__/EmailField.test.tsx.snap +111 -83
  38. package/src/__snapshots__/Field.test.tsx.snap +616 -448
  39. package/src/__snapshots__/MobileAddressAutoComplete.test.tsx.snap +51 -37
  40. package/src/__snapshots__/NumberField.test.tsx.snap +51 -37
  41. package/src/__snapshots__/Page.test.tsx.snap +15 -20
  42. package/src/__snapshots__/PhoneNumberField.test.tsx.snap +264 -194
  43. package/src/__snapshots__/TapToEdit.test.tsx.snap +51 -37
  44. package/src/__snapshots__/TextArea.test.tsx.snap +255 -185
  45. package/src/__snapshots__/TextField.test.tsx.snap +264 -194
  46. package/src/__snapshots__/UnifiedAddressAutoComplete.test.tsx.snap +204 -148
  47. package/src/__snapshots__/WebAddressAutocomplete.test.tsx.snap +153 -111
  48. package/src/index.tsx +1 -0
  49. package/src/login/LoginScreen.tsx +1 -0
  50. package/src/login/__snapshots__/LoginScreen.test.tsx.snap +104 -76
  51. package/src/signUp/SignUpScreen.tsx +1 -0
  52. package/src/signUp/__snapshots__/SignUpScreen.test.tsx.snap +156 -114
@@ -24,56 +24,70 @@ exports[`UnifiedAddressAutoCompleteField renders correctly without Google API ke
24
24
  "children": [
25
25
  {
26
26
  "$$typeof": Symbol(react.test.json),
27
- "children": null,
28
- "props": {
29
- "accessibilityHint": "Enter text here",
30
- "accessibilityState": {
31
- "disabled": undefined,
27
+ "children": [
28
+ {
29
+ "$$typeof": Symbol(react.test.json),
30
+ "children": null,
31
+ "props": {
32
+ "accessibilityHint": "Enter text here",
33
+ "accessibilityState": {
34
+ "disabled": undefined,
35
+ },
36
+ "aria-label": "Text input field",
37
+ "autoCapitalize": "sentences",
38
+ "autoCorrect": true,
39
+ "blurOnSubmit": true,
40
+ "enterKeyHint": undefined,
41
+ "keyboardType": "default",
42
+ "multiline": undefined,
43
+ "nativeID": 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,
55
+ "style": {
56
+ "color": "#1C1C1C",
57
+ "flex": 1,
58
+ "fontFamily": "text",
59
+ "fontSize": 16,
60
+ "gap": 10,
61
+ "height": 20,
62
+ "paddingVertical": 0,
63
+ "width": "100%",
64
+ },
65
+ "testID": undefined,
66
+ "textContentType": "none",
67
+ "underlineColorAndroid": "transparent",
68
+ "value": "",
69
+ },
70
+ "type": "TextInput",
32
71
  },
33
- "aria-label": "Text input field",
34
- "autoCapitalize": "sentences",
35
- "autoCorrect": true,
36
- "blurOnSubmit": true,
37
- "enterKeyHint": undefined,
38
- "keyboardType": "default",
39
- "multiline": undefined,
40
- "numberOfLines": 1,
41
- "onBlur": [Function],
42
- "onChangeText": [Function],
43
- "onContentSizeChange": [Function],
44
- "onFocus": [Function],
45
- "onSubmitEditing": [Function],
46
- "placeholder": "Enter an address",
47
- "placeholderTextColor": "#686868",
48
- "readOnly": undefined,
49
- "ref": [Function],
50
- "secureTextEntry": false,
72
+ ],
73
+ "props": {
51
74
  "style": {
52
- "color": "#1C1C1C",
53
- "flex": 1,
54
- "fontFamily": "text",
55
- "fontSize": 16,
56
- "gap": 10,
57
- "height": 20,
58
- "paddingVertical": 0,
59
- "width": "100%",
75
+ "alignItems": "center",
76
+ "flexDirection": "row",
60
77
  },
61
78
  "testID": undefined,
62
- "textContentType": "none",
63
- "underlineColorAndroid": "transparent",
64
- "value": "",
65
79
  },
66
- "type": "TextInput",
80
+ "type": "View",
67
81
  },
68
82
  ],
69
83
  "props": {
70
84
  "style": {
71
- "alignItems": "center",
72
85
  "backgroundColor": "#FFFFFF",
73
86
  "borderColor": "#9A9A9A",
74
87
  "borderRadius": 4,
75
88
  "borderWidth": 1,
76
- "flexDirection": "row",
89
+ "flexDirection": "column",
90
+ "gap": 0,
77
91
  "overflow": "hidden",
78
92
  "paddingHorizontal": 12,
79
93
  "paddingVertical": 8,
@@ -118,56 +132,70 @@ exports[`UnifiedAddressAutoCompleteField renders with input value 1`] = `
118
132
  "children": [
119
133
  {
120
134
  "$$typeof": Symbol(react.test.json),
121
- "children": null,
122
- "props": {
123
- "accessibilityHint": "Enter text here",
124
- "accessibilityState": {
125
- "disabled": undefined,
135
+ "children": [
136
+ {
137
+ "$$typeof": Symbol(react.test.json),
138
+ "children": null,
139
+ "props": {
140
+ "accessibilityHint": "Enter text here",
141
+ "accessibilityState": {
142
+ "disabled": undefined,
143
+ },
144
+ "aria-label": "Text input field",
145
+ "autoCapitalize": "sentences",
146
+ "autoCorrect": true,
147
+ "blurOnSubmit": true,
148
+ "enterKeyHint": undefined,
149
+ "keyboardType": "default",
150
+ "multiline": undefined,
151
+ "nativeID": undefined,
152
+ "numberOfLines": 1,
153
+ "onBlur": [Function],
154
+ "onChangeText": [Function],
155
+ "onContentSizeChange": [Function],
156
+ "onFocus": [Function],
157
+ "onSubmitEditing": [Function],
158
+ "placeholder": "Enter an address",
159
+ "placeholderTextColor": "#686868",
160
+ "readOnly": undefined,
161
+ "ref": [Function],
162
+ "secureTextEntry": false,
163
+ "style": {
164
+ "color": "#1C1C1C",
165
+ "flex": 1,
166
+ "fontFamily": "text",
167
+ "fontSize": 16,
168
+ "gap": 10,
169
+ "height": 20,
170
+ "paddingVertical": 0,
171
+ "width": "100%",
172
+ },
173
+ "testID": undefined,
174
+ "textContentType": "none",
175
+ "underlineColorAndroid": "transparent",
176
+ "value": "123 Main St",
177
+ },
178
+ "type": "TextInput",
126
179
  },
127
- "aria-label": "Text input field",
128
- "autoCapitalize": "sentences",
129
- "autoCorrect": true,
130
- "blurOnSubmit": true,
131
- "enterKeyHint": undefined,
132
- "keyboardType": "default",
133
- "multiline": undefined,
134
- "numberOfLines": 1,
135
- "onBlur": [Function],
136
- "onChangeText": [Function],
137
- "onContentSizeChange": [Function],
138
- "onFocus": [Function],
139
- "onSubmitEditing": [Function],
140
- "placeholder": "Enter an address",
141
- "placeholderTextColor": "#686868",
142
- "readOnly": undefined,
143
- "ref": [Function],
144
- "secureTextEntry": false,
180
+ ],
181
+ "props": {
145
182
  "style": {
146
- "color": "#1C1C1C",
147
- "flex": 1,
148
- "fontFamily": "text",
149
- "fontSize": 16,
150
- "gap": 10,
151
- "height": 20,
152
- "paddingVertical": 0,
153
- "width": "100%",
183
+ "alignItems": "center",
184
+ "flexDirection": "row",
154
185
  },
155
186
  "testID": undefined,
156
- "textContentType": "none",
157
- "underlineColorAndroid": "transparent",
158
- "value": "123 Main St",
159
187
  },
160
- "type": "TextInput",
188
+ "type": "View",
161
189
  },
162
190
  ],
163
191
  "props": {
164
192
  "style": {
165
- "alignItems": "center",
166
193
  "backgroundColor": "#FFFFFF",
167
194
  "borderColor": "#9A9A9A",
168
195
  "borderRadius": 4,
169
196
  "borderWidth": 1,
170
- "flexDirection": "row",
197
+ "flexDirection": "column",
198
+ "gap": 0,
171
199
  "overflow": "hidden",
172
200
  "paddingHorizontal": 12,
173
201
  "paddingVertical": 8,
@@ -212,56 +240,70 @@ exports[`UnifiedAddressAutoCompleteField renders disabled state 1`] = `
212
240
  "children": [
213
241
  {
214
242
  "$$typeof": Symbol(react.test.json),
215
- "children": null,
216
- "props": {
217
- "accessibilityHint": "Enter text here",
218
- "accessibilityState": {
219
- "disabled": true,
243
+ "children": [
244
+ {
245
+ "$$typeof": Symbol(react.test.json),
246
+ "children": null,
247
+ "props": {
248
+ "accessibilityHint": "Enter text here",
249
+ "accessibilityState": {
250
+ "disabled": true,
251
+ },
252
+ "aria-label": "Text input field",
253
+ "autoCapitalize": "sentences",
254
+ "autoCorrect": true,
255
+ "blurOnSubmit": true,
256
+ "enterKeyHint": undefined,
257
+ "keyboardType": "default",
258
+ "multiline": undefined,
259
+ "nativeID": undefined,
260
+ "numberOfLines": 1,
261
+ "onBlur": [Function],
262
+ "onChangeText": [Function],
263
+ "onContentSizeChange": [Function],
264
+ "onFocus": [Function],
265
+ "onSubmitEditing": [Function],
266
+ "placeholder": "Enter an address",
267
+ "placeholderTextColor": "#686868",
268
+ "readOnly": true,
269
+ "ref": [Function],
270
+ "secureTextEntry": false,
271
+ "style": {
272
+ "color": "#1C1C1C",
273
+ "flex": 1,
274
+ "fontFamily": "text",
275
+ "fontSize": 16,
276
+ "gap": 10,
277
+ "height": 20,
278
+ "paddingVertical": 0,
279
+ "width": "100%",
280
+ },
281
+ "testID": undefined,
282
+ "textContentType": "none",
283
+ "underlineColorAndroid": "transparent",
284
+ "value": "",
285
+ },
286
+ "type": "TextInput",
220
287
  },
221
- "aria-label": "Text input field",
222
- "autoCapitalize": "sentences",
223
- "autoCorrect": true,
224
- "blurOnSubmit": true,
225
- "enterKeyHint": undefined,
226
- "keyboardType": "default",
227
- "multiline": undefined,
228
- "numberOfLines": 1,
229
- "onBlur": [Function],
230
- "onChangeText": [Function],
231
- "onContentSizeChange": [Function],
232
- "onFocus": [Function],
233
- "onSubmitEditing": [Function],
234
- "placeholder": "Enter an address",
235
- "placeholderTextColor": "#686868",
236
- "readOnly": true,
237
- "ref": [Function],
238
- "secureTextEntry": false,
288
+ ],
289
+ "props": {
239
290
  "style": {
240
- "color": "#1C1C1C",
241
- "flex": 1,
242
- "fontFamily": "text",
243
- "fontSize": 16,
244
- "gap": 10,
245
- "height": 20,
246
- "paddingVertical": 0,
247
- "width": "100%",
291
+ "alignItems": "center",
292
+ "flexDirection": "row",
248
293
  },
249
294
  "testID": undefined,
250
- "textContentType": "none",
251
- "underlineColorAndroid": "transparent",
252
- "value": "",
253
295
  },
254
- "type": "TextInput",
296
+ "type": "View",
255
297
  },
256
298
  ],
257
299
  "props": {
258
300
  "style": {
259
- "alignItems": "center",
260
301
  "backgroundColor": "#D9D9D9",
261
302
  "borderColor": "#4E4E4E",
262
303
  "borderRadius": 4,
263
304
  "borderWidth": 1,
264
- "flexDirection": "row",
305
+ "flexDirection": "column",
306
+ "gap": 0,
265
307
  "overflow": "hidden",
266
308
  "paddingHorizontal": 12,
267
309
  "paddingVertical": 8,
@@ -306,56 +348,70 @@ exports[`UnifiedAddressAutoCompleteField renders with invalid Google API key (fa
306
348
  "children": [
307
349
  {
308
350
  "$$typeof": Symbol(react.test.json),
309
- "children": null,
310
- "props": {
311
- "accessibilityHint": "Enter text here",
312
- "accessibilityState": {
313
- "disabled": undefined,
351
+ "children": [
352
+ {
353
+ "$$typeof": Symbol(react.test.json),
354
+ "children": null,
355
+ "props": {
356
+ "accessibilityHint": "Enter text here",
357
+ "accessibilityState": {
358
+ "disabled": undefined,
359
+ },
360
+ "aria-label": "Text input field",
361
+ "autoCapitalize": "sentences",
362
+ "autoCorrect": true,
363
+ "blurOnSubmit": true,
364
+ "enterKeyHint": undefined,
365
+ "keyboardType": "default",
366
+ "multiline": undefined,
367
+ "nativeID": undefined,
368
+ "numberOfLines": 1,
369
+ "onBlur": [Function],
370
+ "onChangeText": [Function],
371
+ "onContentSizeChange": [Function],
372
+ "onFocus": [Function],
373
+ "onSubmitEditing": [Function],
374
+ "placeholder": "Enter an address",
375
+ "placeholderTextColor": "#686868",
376
+ "readOnly": undefined,
377
+ "ref": [Function],
378
+ "secureTextEntry": false,
379
+ "style": {
380
+ "color": "#1C1C1C",
381
+ "flex": 1,
382
+ "fontFamily": "text",
383
+ "fontSize": 16,
384
+ "gap": 10,
385
+ "height": 20,
386
+ "paddingVertical": 0,
387
+ "width": "100%",
388
+ },
389
+ "testID": undefined,
390
+ "textContentType": "none",
391
+ "underlineColorAndroid": "transparent",
392
+ "value": "",
393
+ },
394
+ "type": "TextInput",
314
395
  },
315
- "aria-label": "Text input field",
316
- "autoCapitalize": "sentences",
317
- "autoCorrect": true,
318
- "blurOnSubmit": true,
319
- "enterKeyHint": undefined,
320
- "keyboardType": "default",
321
- "multiline": undefined,
322
- "numberOfLines": 1,
323
- "onBlur": [Function],
324
- "onChangeText": [Function],
325
- "onContentSizeChange": [Function],
326
- "onFocus": [Function],
327
- "onSubmitEditing": [Function],
328
- "placeholder": "Enter an address",
329
- "placeholderTextColor": "#686868",
330
- "readOnly": undefined,
331
- "ref": [Function],
332
- "secureTextEntry": false,
396
+ ],
397
+ "props": {
333
398
  "style": {
334
- "color": "#1C1C1C",
335
- "flex": 1,
336
- "fontFamily": "text",
337
- "fontSize": 16,
338
- "gap": 10,
339
- "height": 20,
340
- "paddingVertical": 0,
341
- "width": "100%",
399
+ "alignItems": "center",
400
+ "flexDirection": "row",
342
401
  },
343
402
  "testID": undefined,
344
- "textContentType": "none",
345
- "underlineColorAndroid": "transparent",
346
- "value": "",
347
403
  },
348
- "type": "TextInput",
404
+ "type": "View",
349
405
  },
350
406
  ],
351
407
  "props": {
352
408
  "style": {
353
- "alignItems": "center",
354
409
  "backgroundColor": "#FFFFFF",
355
410
  "borderColor": "#9A9A9A",
356
411
  "borderRadius": 4,
357
412
  "borderWidth": 1,
358
- "flexDirection": "row",
413
+ "flexDirection": "column",
414
+ "gap": 0,
359
415
  "overflow": "hidden",
360
416
  "paddingHorizontal": 12,
361
417
  "paddingVertical": 8,