@terreno/ui 0.0.16 → 0.0.18

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 (46) hide show
  1. package/dist/Button.js +7 -9
  2. package/dist/Button.js.map +1 -1
  3. package/dist/Common.d.ts +39 -0
  4. package/dist/TerrenoProvider.js +1 -1
  5. package/dist/TerrenoProvider.js.map +1 -1
  6. package/dist/Toast.js +2 -3
  7. package/dist/Toast.js.map +1 -1
  8. package/dist/ToastNotifications.d.ts +144 -0
  9. package/dist/ToastNotifications.js +387 -0
  10. package/dist/ToastNotifications.js.map +1 -0
  11. package/dist/UserInactivity.d.ts +28 -0
  12. package/dist/UserInactivity.js +100 -0
  13. package/dist/UserInactivity.js.map +1 -0
  14. package/dist/index.d.ts +1 -0
  15. package/dist/index.js +1 -0
  16. package/dist/index.js.map +1 -1
  17. package/package.json +1 -2
  18. package/src/Button.tsx +20 -37
  19. package/src/Common.ts +45 -0
  20. package/src/DateTimeActionSheet.test.tsx +53 -4
  21. package/src/MobileAddressAutoComplete.test.tsx +47 -4
  22. package/src/ModalSheet.test.tsx +37 -5
  23. package/src/PickerSelect.test.tsx +41 -5
  24. package/src/Signature.test.tsx +21 -4
  25. package/src/SignatureField.test.tsx +49 -5
  26. package/src/SplitPage.test.tsx +71 -4
  27. package/src/TerrenoProvider.tsx +1 -1
  28. package/src/Toast.tsx +2 -3
  29. package/src/ToastNotifications.test.tsx +645 -0
  30. package/src/ToastNotifications.tsx +746 -0
  31. package/src/UnifiedAddressAutoComplete.test.tsx +43 -5
  32. package/src/UserInactivity.test.tsx +96 -0
  33. package/src/UserInactivity.tsx +129 -0
  34. package/src/WebAddressAutocomplete.test.tsx +22 -4
  35. package/src/__snapshots__/Button.test.tsx.snap +0 -347
  36. package/src/__snapshots__/DateTimeActionSheet.test.tsx.snap +11 -0
  37. package/src/__snapshots__/MobileAddressAutoComplete.test.tsx.snap +230 -0
  38. package/src/__snapshots__/ModalSheet.test.tsx.snap +37 -0
  39. package/src/__snapshots__/PickerSelect.test.tsx.snap +798 -11
  40. package/src/__snapshots__/Signature.test.tsx.snap +67 -0
  41. package/src/__snapshots__/SignatureField.test.tsx.snap +129 -21
  42. package/src/__snapshots__/SplitPage.test.tsx.snap +686 -0
  43. package/src/__snapshots__/UnifiedAddressAutoComplete.test.tsx.snap +377 -0
  44. package/src/__snapshots__/UserInactivity.test.tsx.snap +108 -0
  45. package/src/__snapshots__/WebAddressAutocomplete.test.tsx.snap +238 -0
  46. package/src/index.tsx +1 -0
@@ -0,0 +1,686 @@
1
+ // Bun Snapshot v1, https://bun.sh/docs/test/snapshots
2
+
3
+ exports[`SplitPage renders correctly with renderContent 1`] = `
4
+ {
5
+ "$$typeof": Symbol(react.test.json),
6
+ "children": [
7
+ {
8
+ "$$typeof": Symbol(react.test.json),
9
+ "children": [
10
+ {
11
+ "$$typeof": Symbol(react.test.json),
12
+ "children": [
13
+ {
14
+ "$$typeof": Symbol(react.test.json),
15
+ "children": [
16
+ {
17
+ "$$typeof": Symbol(react.test.json),
18
+ "children": [
19
+ {
20
+ "$$typeof": Symbol(react.test.json),
21
+ "children": [
22
+ {
23
+ "$$typeof": Symbol(react.test.json),
24
+ "children": null,
25
+ "props": {
26
+ "style": undefined,
27
+ "testID": "item-1",
28
+ },
29
+ "type": "View",
30
+ },
31
+ ],
32
+ "props": {
33
+ "accessibilityHint": "",
34
+ "aria-label": "Select",
35
+ "aria-role": "button",
36
+ "onLayout": undefined,
37
+ "onPointerEnter": [Function: AsyncFunction],
38
+ "onPointerLeave": [Function: AsyncFunction],
39
+ "onPress": [Function: AsyncFunction],
40
+ "style": {
41
+ "accessibilityHint": "",
42
+ "accessibilityLabel": "Select",
43
+ },
44
+ "testID": undefined,
45
+ },
46
+ "type": "Pressable",
47
+ },
48
+ {
49
+ "$$typeof": Symbol(react.test.json),
50
+ "children": [
51
+ {
52
+ "$$typeof": Symbol(react.test.json),
53
+ "children": null,
54
+ "props": {
55
+ "style": undefined,
56
+ "testID": "item-2",
57
+ },
58
+ "type": "View",
59
+ },
60
+ ],
61
+ "props": {
62
+ "accessibilityHint": "",
63
+ "aria-label": "Select",
64
+ "aria-role": "button",
65
+ "onLayout": undefined,
66
+ "onPointerEnter": [Function: AsyncFunction],
67
+ "onPointerLeave": [Function: AsyncFunction],
68
+ "onPress": [Function: AsyncFunction],
69
+ "style": {
70
+ "accessibilityHint": "",
71
+ "accessibilityLabel": "Select",
72
+ },
73
+ "testID": undefined,
74
+ },
75
+ "type": "Pressable",
76
+ },
77
+ ],
78
+ "props": {
79
+ "extraData": undefined,
80
+ "nestedScrollEnabled": true,
81
+ },
82
+ "type": "FlatList",
83
+ },
84
+ ],
85
+ "props": {
86
+ "style": {
87
+ "display": "flex",
88
+ "flexDirection": "column",
89
+ "flexGrow": 1,
90
+ "flexShrink": 0,
91
+ "height": "100%",
92
+ "maxWidth": "100%",
93
+ "width": "100%",
94
+ },
95
+ "testID": undefined,
96
+ },
97
+ "type": "View",
98
+ },
99
+ ],
100
+ "props": {
101
+ "onPointerEnter": [Function: AsyncFunction],
102
+ "onPointerLeave": [Function: AsyncFunction],
103
+ "style": {
104
+ "avoidKeyboard": true,
105
+ "backgroundColor": "#D9D9D9",
106
+ "display": "flex",
107
+ "flex": undefined,
108
+ "flexDirection": "row",
109
+ "height": "100%",
110
+ "keyboardOffset": undefined,
111
+ "padding": 8,
112
+ "width": "100%",
113
+ },
114
+ "testID": undefined,
115
+ },
116
+ "type": "View",
117
+ },
118
+ ],
119
+ "props": {
120
+ "style": {
121
+ "display": "flex",
122
+ "flex": 1,
123
+ },
124
+ },
125
+ "type": "SafeAreaView",
126
+ },
127
+ ],
128
+ "props": {
129
+ "behavior": "padding",
130
+ "keyboardVerticalOffset": undefined,
131
+ "style": {
132
+ "display": "flex",
133
+ "flex": 1,
134
+ },
135
+ },
136
+ "type": "KeyboardAvoidingView",
137
+ }
138
+ `;
139
+
140
+ exports[`SplitPage renders correctly with children 1`] = `
141
+ {
142
+ "$$typeof": Symbol(react.test.json),
143
+ "children": [
144
+ {
145
+ "$$typeof": Symbol(react.test.json),
146
+ "children": [
147
+ {
148
+ "$$typeof": Symbol(react.test.json),
149
+ "children": [
150
+ {
151
+ "$$typeof": Symbol(react.test.json),
152
+ "children": [
153
+ {
154
+ "$$typeof": Symbol(react.test.json),
155
+ "children": [
156
+ {
157
+ "$$typeof": Symbol(react.test.json),
158
+ "children": [
159
+ {
160
+ "$$typeof": Symbol(react.test.json),
161
+ "children": null,
162
+ "props": {
163
+ "style": undefined,
164
+ "testID": "item-1",
165
+ },
166
+ "type": "View",
167
+ },
168
+ ],
169
+ "props": {
170
+ "accessibilityHint": "",
171
+ "aria-label": "Select",
172
+ "aria-role": "button",
173
+ "onLayout": undefined,
174
+ "onPointerEnter": [Function: AsyncFunction],
175
+ "onPointerLeave": [Function: AsyncFunction],
176
+ "onPress": [Function: AsyncFunction],
177
+ "style": {
178
+ "accessibilityHint": "",
179
+ "accessibilityLabel": "Select",
180
+ },
181
+ "testID": undefined,
182
+ },
183
+ "type": "Pressable",
184
+ },
185
+ {
186
+ "$$typeof": Symbol(react.test.json),
187
+ "children": [
188
+ {
189
+ "$$typeof": Symbol(react.test.json),
190
+ "children": null,
191
+ "props": {
192
+ "style": undefined,
193
+ "testID": "item-2",
194
+ },
195
+ "type": "View",
196
+ },
197
+ ],
198
+ "props": {
199
+ "accessibilityHint": "",
200
+ "aria-label": "Select",
201
+ "aria-role": "button",
202
+ "onLayout": undefined,
203
+ "onPointerEnter": [Function: AsyncFunction],
204
+ "onPointerLeave": [Function: AsyncFunction],
205
+ "onPress": [Function: AsyncFunction],
206
+ "style": {
207
+ "accessibilityHint": "",
208
+ "accessibilityLabel": "Select",
209
+ },
210
+ "testID": undefined,
211
+ },
212
+ "type": "Pressable",
213
+ },
214
+ ],
215
+ "props": {
216
+ "extraData": undefined,
217
+ "nestedScrollEnabled": true,
218
+ },
219
+ "type": "FlatList",
220
+ },
221
+ ],
222
+ "props": {
223
+ "style": {
224
+ "display": "flex",
225
+ "flexDirection": "column",
226
+ "flexGrow": 1,
227
+ "flexShrink": 0,
228
+ "height": "100%",
229
+ "maxWidth": "100%",
230
+ "width": "100%",
231
+ },
232
+ "testID": undefined,
233
+ },
234
+ "type": "View",
235
+ },
236
+ ],
237
+ "props": {
238
+ "onPointerEnter": [Function: AsyncFunction],
239
+ "onPointerLeave": [Function: AsyncFunction],
240
+ "style": {
241
+ "avoidKeyboard": true,
242
+ "backgroundColor": "#D9D9D9",
243
+ "display": "flex",
244
+ "flex": undefined,
245
+ "flexDirection": "row",
246
+ "height": "100%",
247
+ "keyboardOffset": undefined,
248
+ "padding": 8,
249
+ "width": "100%",
250
+ },
251
+ "testID": undefined,
252
+ },
253
+ "type": "View",
254
+ },
255
+ ],
256
+ "props": {
257
+ "style": {
258
+ "display": "flex",
259
+ "flex": 1,
260
+ },
261
+ },
262
+ "type": "SafeAreaView",
263
+ },
264
+ ],
265
+ "props": {
266
+ "behavior": "padding",
267
+ "keyboardVerticalOffset": undefined,
268
+ "style": {
269
+ "display": "flex",
270
+ "flex": 1,
271
+ },
272
+ },
273
+ "type": "KeyboardAvoidingView",
274
+ }
275
+ `;
276
+
277
+ exports[`SplitPage renders with loading state 1`] = `
278
+ {
279
+ "$$typeof": Symbol(react.test.json),
280
+ "children": [
281
+ {
282
+ "$$typeof": Symbol(react.test.json),
283
+ "children": [
284
+ {
285
+ "$$typeof": Symbol(react.test.json),
286
+ "children": [
287
+ {
288
+ "$$typeof": Symbol(react.test.json),
289
+ "children": [
290
+ {
291
+ "$$typeof": Symbol(react.test.json),
292
+ "children": [
293
+ {
294
+ "$$typeof": Symbol(react.test.json),
295
+ "children": [
296
+ {
297
+ "$$typeof": Symbol(react.test.json),
298
+ "children": null,
299
+ "props": {
300
+ "style": undefined,
301
+ "testID": "item-1",
302
+ },
303
+ "type": "View",
304
+ },
305
+ ],
306
+ "props": {
307
+ "accessibilityHint": "",
308
+ "aria-label": "Select",
309
+ "aria-role": "button",
310
+ "onLayout": undefined,
311
+ "onPointerEnter": [Function: AsyncFunction],
312
+ "onPointerLeave": [Function: AsyncFunction],
313
+ "onPress": [Function: AsyncFunction],
314
+ "style": {
315
+ "accessibilityHint": "",
316
+ "accessibilityLabel": "Select",
317
+ },
318
+ "testID": undefined,
319
+ },
320
+ "type": "Pressable",
321
+ },
322
+ {
323
+ "$$typeof": Symbol(react.test.json),
324
+ "children": [
325
+ {
326
+ "$$typeof": Symbol(react.test.json),
327
+ "children": null,
328
+ "props": {
329
+ "style": undefined,
330
+ "testID": "item-2",
331
+ },
332
+ "type": "View",
333
+ },
334
+ ],
335
+ "props": {
336
+ "accessibilityHint": "",
337
+ "aria-label": "Select",
338
+ "aria-role": "button",
339
+ "onLayout": undefined,
340
+ "onPointerEnter": [Function: AsyncFunction],
341
+ "onPointerLeave": [Function: AsyncFunction],
342
+ "onPress": [Function: AsyncFunction],
343
+ "style": {
344
+ "accessibilityHint": "",
345
+ "accessibilityLabel": "Select",
346
+ },
347
+ "testID": undefined,
348
+ },
349
+ "type": "Pressable",
350
+ },
351
+ ],
352
+ "props": {
353
+ "extraData": undefined,
354
+ "nestedScrollEnabled": true,
355
+ },
356
+ "type": "FlatList",
357
+ },
358
+ ],
359
+ "props": {
360
+ "style": {
361
+ "display": "flex",
362
+ "flexDirection": "column",
363
+ "flexGrow": 1,
364
+ "flexShrink": 0,
365
+ "height": "100%",
366
+ "maxWidth": "100%",
367
+ "width": "100%",
368
+ },
369
+ "testID": undefined,
370
+ },
371
+ "type": "View",
372
+ },
373
+ ],
374
+ "props": {
375
+ "onPointerEnter": [Function: AsyncFunction],
376
+ "onPointerLeave": [Function: AsyncFunction],
377
+ "style": {
378
+ "avoidKeyboard": true,
379
+ "backgroundColor": "#D9D9D9",
380
+ "display": "flex",
381
+ "flex": undefined,
382
+ "flexDirection": "row",
383
+ "height": "100%",
384
+ "keyboardOffset": undefined,
385
+ "padding": 8,
386
+ "width": "100%",
387
+ },
388
+ "testID": undefined,
389
+ },
390
+ "type": "View",
391
+ },
392
+ ],
393
+ "props": {
394
+ "style": {
395
+ "display": "flex",
396
+ "flex": 1,
397
+ },
398
+ },
399
+ "type": "SafeAreaView",
400
+ },
401
+ ],
402
+ "props": {
403
+ "behavior": "padding",
404
+ "keyboardVerticalOffset": undefined,
405
+ "style": {
406
+ "display": "flex",
407
+ "flex": 1,
408
+ },
409
+ },
410
+ "type": "KeyboardAvoidingView",
411
+ }
412
+ `;
413
+
414
+ exports[`SplitPage renders with custom color 1`] = `
415
+ {
416
+ "$$typeof": Symbol(react.test.json),
417
+ "children": [
418
+ {
419
+ "$$typeof": Symbol(react.test.json),
420
+ "children": [
421
+ {
422
+ "$$typeof": Symbol(react.test.json),
423
+ "children": [
424
+ {
425
+ "$$typeof": Symbol(react.test.json),
426
+ "children": [
427
+ {
428
+ "$$typeof": Symbol(react.test.json),
429
+ "children": [
430
+ {
431
+ "$$typeof": Symbol(react.test.json),
432
+ "children": [
433
+ {
434
+ "$$typeof": Symbol(react.test.json),
435
+ "children": null,
436
+ "props": {
437
+ "style": undefined,
438
+ "testID": "item-1",
439
+ },
440
+ "type": "View",
441
+ },
442
+ ],
443
+ "props": {
444
+ "accessibilityHint": "",
445
+ "aria-label": "Select",
446
+ "aria-role": "button",
447
+ "onLayout": undefined,
448
+ "onPointerEnter": [Function: AsyncFunction],
449
+ "onPointerLeave": [Function: AsyncFunction],
450
+ "onPress": [Function: AsyncFunction],
451
+ "style": {
452
+ "accessibilityHint": "",
453
+ "accessibilityLabel": "Select",
454
+ },
455
+ "testID": undefined,
456
+ },
457
+ "type": "Pressable",
458
+ },
459
+ {
460
+ "$$typeof": Symbol(react.test.json),
461
+ "children": [
462
+ {
463
+ "$$typeof": Symbol(react.test.json),
464
+ "children": null,
465
+ "props": {
466
+ "style": undefined,
467
+ "testID": "item-2",
468
+ },
469
+ "type": "View",
470
+ },
471
+ ],
472
+ "props": {
473
+ "accessibilityHint": "",
474
+ "aria-label": "Select",
475
+ "aria-role": "button",
476
+ "onLayout": undefined,
477
+ "onPointerEnter": [Function: AsyncFunction],
478
+ "onPointerLeave": [Function: AsyncFunction],
479
+ "onPress": [Function: AsyncFunction],
480
+ "style": {
481
+ "accessibilityHint": "",
482
+ "accessibilityLabel": "Select",
483
+ },
484
+ "testID": undefined,
485
+ },
486
+ "type": "Pressable",
487
+ },
488
+ ],
489
+ "props": {
490
+ "extraData": undefined,
491
+ "nestedScrollEnabled": true,
492
+ },
493
+ "type": "FlatList",
494
+ },
495
+ ],
496
+ "props": {
497
+ "style": {
498
+ "display": "flex",
499
+ "flexDirection": "column",
500
+ "flexGrow": 1,
501
+ "flexShrink": 0,
502
+ "height": "100%",
503
+ "maxWidth": "100%",
504
+ "width": "100%",
505
+ },
506
+ "testID": undefined,
507
+ },
508
+ "type": "View",
509
+ },
510
+ ],
511
+ "props": {
512
+ "onPointerEnter": [Function: AsyncFunction],
513
+ "onPointerLeave": [Function: AsyncFunction],
514
+ "style": {
515
+ "avoidKeyboard": true,
516
+ "backgroundColor": "#0E9DCD",
517
+ "display": "flex",
518
+ "flex": undefined,
519
+ "flexDirection": "row",
520
+ "height": "100%",
521
+ "keyboardOffset": undefined,
522
+ "padding": 8,
523
+ "width": "100%",
524
+ },
525
+ "testID": undefined,
526
+ },
527
+ "type": "View",
528
+ },
529
+ ],
530
+ "props": {
531
+ "style": {
532
+ "display": "flex",
533
+ "flex": 1,
534
+ },
535
+ },
536
+ "type": "SafeAreaView",
537
+ },
538
+ ],
539
+ "props": {
540
+ "behavior": "padding",
541
+ "keyboardVerticalOffset": undefined,
542
+ "style": {
543
+ "display": "flex",
544
+ "flex": 1,
545
+ },
546
+ },
547
+ "type": "KeyboardAvoidingView",
548
+ }
549
+ `;
550
+
551
+ exports[`SplitPage renders with tabs when more than 2 children 1`] = `
552
+ {
553
+ "$$typeof": Symbol(react.test.json),
554
+ "children": [
555
+ {
556
+ "$$typeof": Symbol(react.test.json),
557
+ "children": [
558
+ {
559
+ "$$typeof": Symbol(react.test.json),
560
+ "children": [
561
+ {
562
+ "$$typeof": Symbol(react.test.json),
563
+ "children": [
564
+ {
565
+ "$$typeof": Symbol(react.test.json),
566
+ "children": [
567
+ {
568
+ "$$typeof": Symbol(react.test.json),
569
+ "children": [
570
+ {
571
+ "$$typeof": Symbol(react.test.json),
572
+ "children": null,
573
+ "props": {
574
+ "style": undefined,
575
+ "testID": "item-1",
576
+ },
577
+ "type": "View",
578
+ },
579
+ ],
580
+ "props": {
581
+ "accessibilityHint": "",
582
+ "aria-label": "Select",
583
+ "aria-role": "button",
584
+ "onLayout": undefined,
585
+ "onPointerEnter": [Function: AsyncFunction],
586
+ "onPointerLeave": [Function: AsyncFunction],
587
+ "onPress": [Function: AsyncFunction],
588
+ "style": {
589
+ "accessibilityHint": "",
590
+ "accessibilityLabel": "Select",
591
+ },
592
+ "testID": undefined,
593
+ },
594
+ "type": "Pressable",
595
+ },
596
+ {
597
+ "$$typeof": Symbol(react.test.json),
598
+ "children": [
599
+ {
600
+ "$$typeof": Symbol(react.test.json),
601
+ "children": null,
602
+ "props": {
603
+ "style": undefined,
604
+ "testID": "item-2",
605
+ },
606
+ "type": "View",
607
+ },
608
+ ],
609
+ "props": {
610
+ "accessibilityHint": "",
611
+ "aria-label": "Select",
612
+ "aria-role": "button",
613
+ "onLayout": undefined,
614
+ "onPointerEnter": [Function: AsyncFunction],
615
+ "onPointerLeave": [Function: AsyncFunction],
616
+ "onPress": [Function: AsyncFunction],
617
+ "style": {
618
+ "accessibilityHint": "",
619
+ "accessibilityLabel": "Select",
620
+ },
621
+ "testID": undefined,
622
+ },
623
+ "type": "Pressable",
624
+ },
625
+ ],
626
+ "props": {
627
+ "extraData": undefined,
628
+ "nestedScrollEnabled": true,
629
+ },
630
+ "type": "FlatList",
631
+ },
632
+ ],
633
+ "props": {
634
+ "style": {
635
+ "display": "flex",
636
+ "flexDirection": "column",
637
+ "flexGrow": 1,
638
+ "flexShrink": 0,
639
+ "height": "100%",
640
+ "maxWidth": "100%",
641
+ "width": "100%",
642
+ },
643
+ "testID": undefined,
644
+ },
645
+ "type": "View",
646
+ },
647
+ ],
648
+ "props": {
649
+ "onPointerEnter": [Function: AsyncFunction],
650
+ "onPointerLeave": [Function: AsyncFunction],
651
+ "style": {
652
+ "avoidKeyboard": true,
653
+ "backgroundColor": "#D9D9D9",
654
+ "display": "flex",
655
+ "flex": undefined,
656
+ "flexDirection": "row",
657
+ "height": "100%",
658
+ "keyboardOffset": undefined,
659
+ "padding": 8,
660
+ "width": "100%",
661
+ },
662
+ "testID": undefined,
663
+ },
664
+ "type": "View",
665
+ },
666
+ ],
667
+ "props": {
668
+ "style": {
669
+ "display": "flex",
670
+ "flex": 1,
671
+ },
672
+ },
673
+ "type": "SafeAreaView",
674
+ },
675
+ ],
676
+ "props": {
677
+ "behavior": "padding",
678
+ "keyboardVerticalOffset": undefined,
679
+ "style": {
680
+ "display": "flex",
681
+ "flex": 1,
682
+ },
683
+ },
684
+ "type": "KeyboardAvoidingView",
685
+ }
686
+ `;