@tactics/toddle-styleguide 1.2.0 → 1.2.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/App.d.ts +1 -0
- package/package.json +1 -1
- package/src/components/atoms/animated-wave/animated-wave.component.d.ts +1 -0
- package/src/components/atoms/backdrop/backdrop.component.d.ts +1 -0
- package/src/components/atoms/background-gradient/background-gradient.component.d.ts +1 -0
- package/src/components/atoms/background-gradient/background-gradient.preview.d.ts +1 -0
- package/src/components/atoms/calendar/__snapshots__/calendar.test.js.snap +18 -18
- package/src/components/atoms/calendar/calendar.component.d.ts +1 -0
- package/src/components/atoms/calendar/calendar.preview.d.ts +1 -0
- package/src/components/atoms/check-switch/check-switch.component.d.ts +1 -0
- package/src/components/atoms/check-switch/check-switch.preview.d.ts +1 -0
- package/src/components/atoms/footer/footer.preview.d.ts +1 -0
- package/src/components/atoms/footer/footer.styles.js +2 -1
- package/src/components/atoms/heading-components/all-caps-heading/all-caps-heading.component.d.ts +1 -0
- package/src/components/atoms/heading-components/heading1/heading1.component.d.ts +1 -0
- package/src/components/atoms/heading-components/heading2/heading2.component.d.ts +1 -0
- package/src/components/atoms/heading-components/heading3/heading3.component.d.ts +1 -0
- package/src/components/atoms/heading-components/heading4/heading4.component.d.ts +1 -0
- package/src/components/atoms/heading-components/headings.preview.d.ts +1 -0
- package/src/components/atoms/image-bubble/image-bubble.component.d.ts +1 -0
- package/src/components/atoms/image-bubble/image-bubble.preview.d.ts +1 -0
- package/src/components/atoms/increment-input/increment-input.component.d.ts +1 -0
- package/src/components/atoms/increment-input/increment-input.preview.d.ts +1 -0
- package/src/components/atoms/logo/logo.component.d.ts +1 -0
- package/src/components/atoms/logo/logo.preview.d.ts +1 -0
- package/src/components/atoms/paragraph-components/paragraph/paragraph.component.d.ts +1 -0
- package/src/components/atoms/paragraph-components/paragraph-components.preview.d.ts +1 -0
- package/src/components/atoms/paragraph-components/small-text/small-text.component.d.ts +1 -0
- package/src/components/atoms/paragraph-components/tiny-text/tiny-text.component.d.ts +1 -0
- package/src/components/atoms/split-container/split-container.preview.d.ts +1 -0
- package/src/components/atoms/static-wave/static-wave.component.d.ts +1 -0
- package/src/components/atoms/text-input/text-input.component.d.ts +1 -0
- package/src/components/atoms/text-input/text-input.preview.d.ts +1 -0
- package/src/components/molecules/avatar/avatar.component.d.ts +3 -1
- package/src/components/molecules/avatar/avatar.component.tsx +26 -3
- package/src/components/molecules/avatar/avatar.preview.d.ts +1 -0
- package/src/components/molecules/blocked-message/blocked-message.component.d.ts +1 -0
- package/src/components/molecules/blocked-message/blocked-message.preview.d.ts +1 -0
- package/src/components/molecules/button/button.component.d.ts +1 -0
- package/src/components/molecules/button/button.preview.d.ts +1 -0
- package/src/components/molecules/calendar-select/calendar-select.component.d.ts +1 -0
- package/src/components/molecules/calendar-select/calendar-select.preview.d.ts +1 -0
- package/src/components/molecules/cancel-link/cancel-link.component.d.ts +1 -0
- package/src/components/molecules/cancel-link/cancel-link.preview.d.ts +1 -0
- package/src/components/molecules/checkbox/checkbox.component.d.ts +1 -0
- package/src/components/molecules/checkbox/checkbox.preview.d.ts +1 -0
- package/src/components/molecules/contact-role/contact-role.component.d.ts +1 -0
- package/src/components/molecules/contact-role/contact-role.preview.d.ts +1 -0
- package/src/components/molecules/date-input/date-input.component.d.ts +1 -0
- package/src/components/molecules/date-input/date-input.preview.d.ts +1 -0
- package/src/components/molecules/day/day.component.d.ts +1 -0
- package/src/components/molecules/default-select/default-select.component.d.ts +1 -0
- package/src/components/molecules/default-select/default-select.preview.d.ts +1 -0
- package/src/components/molecules/department_logo/department-logo.component.d.ts +1 -0
- package/src/components/molecules/department_logo/department-logo.preview.d.ts +1 -0
- package/src/components/molecules/failed-to-send/failed-bubble.component.d.ts +1 -0
- package/src/components/molecules/filter-range/__snapshots__/filter-range.test.js.snap +1 -1
- package/src/components/molecules/filter-range/filter-range.component.d.ts +1 -0
- package/src/components/molecules/filter-range/filter-range.preview.d.ts +1 -0
- package/src/components/molecules/filter-tab/filter-tab.component.d.ts +1 -0
- package/src/components/molecules/filter-tab/filter-tab.preview.d.ts +1 -0
- package/src/components/molecules/info/info.component.d.ts +1 -0
- package/src/components/molecules/info/info.preview.d.ts +1 -0
- package/src/components/molecules/language-button/language-button.component.d.ts +1 -0
- package/src/components/molecules/language-button/language-button.preview.d.ts +1 -0
- package/src/components/molecules/message-input/message-input.component.d.ts +1 -0
- package/src/components/molecules/message-input/message-input.preview.d.ts +1 -0
- package/src/components/molecules/more-info-button/more-info-button.component.d.ts +1 -0
- package/src/components/molecules/more-info-button/more-info-button.preview.d.ts +1 -0
- package/src/components/molecules/password-input/password-input.component.d.ts +1 -0
- package/src/components/molecules/password-input/password-input.preview.d.ts +1 -0
- package/src/components/molecules/pill/pill.component.d.ts +1 -0
- package/src/components/molecules/pill/pill.component.tsx +1 -1
- package/src/components/molecules/pill/pill.preview.d.ts +1 -0
- package/src/components/molecules/pressable-icon/pressable-icon.preview.d.ts +1 -0
- package/src/components/molecules/quick-filter/quick-filter.component.d.ts +1 -0
- package/src/components/molecules/quick-filter/quick-filter.component.tsx +4 -2
- package/src/components/molecules/quick-filter/quick-filter.preview.d.ts +1 -0
- package/src/components/molecules/quick-filter/quick-filter.preview.tsx +1 -1
- package/src/components/molecules/search-input/search.component.d.ts +1 -0
- package/src/components/molecules/search-input/search.preview.d.ts +1 -0
- package/src/components/molecules/select-link/select-link.component.d.ts +1 -0
- package/src/components/molecules/select-link/select-link.preview.d.ts +1 -0
- package/src/components/molecules/select-list-item/select-list-item-preview.d.ts +1 -0
- package/src/components/molecules/select-picker/select-picker.component.d.ts +1 -0
- package/src/components/molecules/select-picker/select-picker.preview.d.ts +1 -0
- package/src/components/molecules/send-bubble/send-text-bubble.component.d.ts +1 -0
- package/src/components/molecules/snackbar/snackbar.component.d.ts +1 -0
- package/src/components/molecules/snackbar/snackbar.preview.d.ts +1 -0
- package/src/components/molecules/swipe/swipe.preview.d.ts +1 -0
- package/src/components/molecules/tag/tag.component.d.ts +1 -0
- package/src/components/molecules/tag/tag.preview.d.ts +1 -0
- package/src/components/molecules/time-tracker/time-tracker.component.d.ts +1 -0
- package/src/components/molecules/time-tracker/time-tracker.preview.d.ts +1 -0
- package/src/components/molecules/timeline/timeline.component.d.ts +1 -0
- package/src/components/molecules/timeline/timeline.preview.d.ts +1 -0
- package/src/components/molecules/timestamp/timestamp.component.d.ts +1 -0
- package/src/components/molecules/wave-background/wave.component.d.ts +1 -0
- package/src/components/molecules/wave-background/wave.preview.d.ts +1 -0
- package/src/components/molecules/wide-button/wide-button.component.d.ts +1 -0
- package/src/components/molecules/wide-button/wide-button.preview.d.ts +1 -0
- package/src/components/organisms/child-list-item/child-list-item.component.d.ts +2 -1
- package/src/components/organisms/child-list-item/child-list-item.component.tsx +21 -3
- package/src/components/organisms/child-list-item/child-list-item.preview.d.ts +1 -0
- package/src/components/organisms/child-list-item/child-list-item.preview.tsx +6 -1
- package/src/components/organisms/contact-item/contact-item.component.d.ts +1 -0
- package/src/components/organisms/contact-item/contact-item.preview.d.ts +1 -0
- package/src/components/organisms/day-select/day-select.component.d.ts +1 -0
- package/src/components/organisms/day-select/day-select.preview.d.ts +1 -0
- package/src/components/organisms/loading-indicator/container.component.d.ts +1 -0
- package/src/components/organisms/loading-indicator/dot.component.d.ts +1 -0
- package/src/components/organisms/loading-indicator/loading-indicator.component.d.ts +1 -0
- package/src/components/organisms/loading-indicator/loading-indicator.preview.d.ts +1 -0
- package/src/components/organisms/my-child-list-item/my-child-list-item.component.d.ts +1 -0
- package/src/components/organisms/my-child-list-item/my-child-list-item.preview.d.ts +1 -0
- package/src/components/organisms/person-info-card/person-info-card.component.d.ts +1 -0
- package/src/components/organisms/person-info-card/person-info-card.preview.d.ts +1 -0
- package/src/components/organisms/text-bubble/text-bubble.component.d.ts +1 -0
- package/src/components/organisms/text-bubble/text-bubble.preview.d.ts +1 -0
- package/src/components/templates/modal/modal.preview.d.ts +1 -0
- package/src/components/templates/popover/components/modal/close/close.component.d.ts +1 -0
- package/src/components/templates/popover/components/modal/heading/heading.component.d.ts +1 -0
- package/src/components/templates/popover/popover.preview.d.ts +1 -0
- package/src/gradients/main/main.gradient.d.ts +1 -0
- package/src/icons/index.d.ts +1 -0
- package/src/icons/outline/calendar/calendar.icon.d.ts +1 -0
- package/src/icons/outline/chat/chat.icon.d.ts +1 -0
- package/src/icons/outline/chat-alt/chat-alt.icon.d.ts +1 -0
- package/src/icons/outline/check-circle/check-circle.icon.d.ts +1 -0
- package/src/icons/outline/chevron-left/chevron-left.icon.d.ts +1 -0
- package/src/icons/outline/chevron-right/chevron-right.icon.d.ts +1 -0
- package/src/icons/outline/clock/clock.icon.d.ts +1 -0
- package/src/icons/outline/cloud-download/cloud-download.icon.d.ts +1 -0
- package/src/icons/outline/currency-euro/currency-euro.icon.d.ts +1 -0
- package/src/icons/outline/document-text/document-text.icon.d.ts +1 -0
- package/src/icons/outline/exclamation/exclamation.icon.d.ts +1 -0
- package/src/icons/outline/exclamation-circle/exclamation-circle.icon.d.ts +1 -0
- package/src/icons/outline/eye/eye.icon.d.ts +1 -0
- package/src/icons/outline/eye-off/eye-off.icon.d.ts +1 -0
- package/src/icons/outline/filter/filter.icon.d.ts +1 -0
- package/src/icons/outline/information-circle/information-circle.icon.d.ts +1 -0
- package/src/icons/outline/logout/logout.icon.d.ts +1 -0
- package/src/icons/outline/mail/mail.icon.d.ts +1 -0
- package/src/icons/outline/mail-open/mail-open.icon.d.ts +1 -0
- package/src/icons/outline/menu/menu.icon.d.ts +1 -0
- package/src/icons/outline/minus-sm/minus-sm.icon.d.ts +1 -0
- package/src/icons/outline/office-building/office-building.icon.d.ts +1 -0
- package/src/icons/outline/outline-default.preview.d.ts +1 -0
- package/src/icons/outline/outline-grey.preview.d.ts +1 -0
- package/src/icons/outline/outline-white.preview.d.ts +1 -0
- package/src/icons/outline/outline.d.ts +1 -0
- package/src/icons/outline/paper-airplane/paper-airplane.icon.d.ts +1 -0
- package/src/icons/outline/paperclip/paperclip.icon.d.ts +1 -0
- package/src/icons/outline/pencil/pencil.icon.d.ts +1 -0
- package/src/icons/outline/phone/phone.icon.d.ts +1 -0
- package/src/icons/outline/plus/plus.icon.d.ts +1 -0
- package/src/icons/outline/plus-sm/plus-sm.icon.d.ts +1 -0
- package/src/icons/outline/qrcode/qrcode.icon.d.ts +1 -0
- package/src/icons/outline/refresh/refresh.icon.d.ts +1 -0
- package/src/icons/outline/search/search.icon.d.ts +1 -0
- package/src/icons/outline/selector/selector.icon.d.ts +1 -0
- package/src/icons/outline/sm-view-grid-add/sm-view-grid-add.icon.d.ts +1 -0
- package/src/icons/outline/status-online/status-online.icon.d.ts +1 -0
- package/src/icons/outline/thumb-up/thumb-up.icon.d.ts +1 -0
- package/src/icons/outline/trash/trash.icon.d.ts +1 -0
- package/src/icons/outline/user/user.icon.d.ts +1 -0
- package/src/icons/outline/user-group/user-group.icon.d.ts +1 -0
- package/src/icons/outline/users/users.icon.d.ts +1 -0
- package/src/icons/outline/xmark/xmark.icon.d.ts +1 -0
- package/src/icons/solid/calendar/calendar.icon.d.ts +1 -0
- package/src/icons/solid/chat/chat.icon.d.ts +1 -0
- package/src/icons/solid/chat-alt/chat-alt-solid.icon.d.ts +1 -0
- package/src/icons/solid/check-circle/check-circle.icon.d.ts +1 -0
- package/src/icons/solid/chevron-left/chevron-left.icon.d.ts +1 -0
- package/src/icons/solid/chevron-right/chevron-right.icon.d.ts +1 -0
- package/src/icons/solid/clock/clock-solid.icon.d.ts +1 -0
- package/src/icons/solid/cloud-download/cloud-download.icon.d.ts +1 -0
- package/src/icons/solid/currency-euro/currency-euro.icon.d.ts +1 -0
- package/src/icons/solid/document-text/document-text-solid.icon.d.ts +1 -0
- package/src/icons/solid/exclamation/exclamation.icon.d.ts +1 -0
- package/src/icons/solid/exclamation-circle/exclamation-circle.icon.d.ts +1 -0
- package/src/icons/solid/eye/eye.icon.d.ts +1 -0
- package/src/icons/solid/eye-off/eye-off.icon.d.ts +1 -0
- package/src/icons/solid/filter/filter.icon.d.ts +1 -0
- package/src/icons/solid/information-circle/information-circle-solid.icon.d.ts +1 -0
- package/src/icons/solid/logout/logout.icon.d.ts +1 -0
- package/src/icons/solid/mail/mail.icon.d.ts +1 -0
- package/src/icons/solid/mail-open/mail-open.icon.d.ts +1 -0
- package/src/icons/solid/menu/menu.icon.d.ts +1 -0
- package/src/icons/solid/minus-sm/minus-sm.icon.d.ts +1 -0
- package/src/icons/solid/office-building/office-building.icon.d.ts +1 -0
- package/src/icons/solid/paper-airplane/paper-airplane.icon.d.ts +1 -0
- package/src/icons/solid/paperclip/paperclip.icon.d.ts +1 -0
- package/src/icons/solid/pencil/pencil-solid.icon.d.ts +1 -0
- package/src/icons/solid/phone/phone-solid.icon.d.ts +1 -0
- package/src/icons/solid/plus/plus.icon.d.ts +1 -0
- package/src/icons/solid/plus-sm/plus-sm.icon.d.ts +1 -0
- package/src/icons/solid/qrcode/qrcode.icon.d.ts +1 -0
- package/src/icons/solid/refresh/refresh-solid.icon.d.ts +1 -0
- package/src/icons/solid/search/search.icon.d.ts +1 -0
- package/src/icons/solid/selector/selector.icon.d.ts +1 -0
- package/src/icons/solid/sm-view-grid-add/sm-view-grid-add.icon.d.ts +1 -0
- package/src/icons/solid/solid.d.ts +1 -0
- package/src/icons/solid/solid.preview.d.ts +1 -0
- package/src/icons/solid/status-online/status-online-solid.icon.d.ts +1 -0
- package/src/icons/solid/thumb-up/thumb-up.icon.d.ts +1 -0
- package/src/icons/solid/trash/trash-solid.icon.d.ts +1 -0
- package/src/icons/solid/user/user.icon.d.ts +1 -0
- package/src/icons/solid/user-group/user-group.icon.d.ts +1 -0
- package/src/icons/solid/users/users-solid.icon.d.ts +1 -0
- package/src/icons/solid/xmark/xmark.icon.d.ts +1 -0
- package/src/utilities/{text-color-handler/text-color-handler.d.ts → color-handler/color-handler.d.ts} +1 -1
- package/src/utilities/color-handler/color-handler.ts +36 -0
- package/src/utilities/toddle-datetime/toddle-datetime.preview.d.ts +1 -0
- package/src/utilities/text-color-handler/text-color-handler.tsx +0 -26
package/App.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1065,7 +1065,7 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
1065
1065
|
}
|
|
1066
1066
|
>
|
|
1067
1067
|
<View
|
|
1068
|
-
accessibilityLabel="
|
|
1068
|
+
accessibilityLabel=" Maandag 3 April 2023 "
|
|
1069
1069
|
accessibilityRole="button"
|
|
1070
1070
|
accessibilityState={
|
|
1071
1071
|
{
|
|
@@ -1097,10 +1097,6 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
1097
1097
|
style={
|
|
1098
1098
|
{
|
|
1099
1099
|
"alignItems": "center",
|
|
1100
|
-
"borderColor": "#7B93DB",
|
|
1101
|
-
"borderRadius": 21,
|
|
1102
|
-
"borderStyle": "solid",
|
|
1103
|
-
"borderWidth": 1,
|
|
1104
1100
|
"height": 42,
|
|
1105
1101
|
"justifyContent": "center",
|
|
1106
1102
|
"opacity": 1,
|
|
@@ -1120,9 +1116,6 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
1120
1116
|
"lineHeight": 22.4,
|
|
1121
1117
|
"marginTop": 4,
|
|
1122
1118
|
},
|
|
1123
|
-
{
|
|
1124
|
-
"color": "#7B93DB",
|
|
1125
|
-
},
|
|
1126
1119
|
]
|
|
1127
1120
|
}
|
|
1128
1121
|
>
|
|
@@ -1153,7 +1146,7 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
1153
1146
|
}
|
|
1154
1147
|
>
|
|
1155
1148
|
<View
|
|
1156
|
-
accessibilityLabel=" Dinsdag 4 April 2023 "
|
|
1149
|
+
accessibilityLabel="today Dinsdag 4 April 2023 "
|
|
1157
1150
|
accessibilityRole="button"
|
|
1158
1151
|
accessibilityState={
|
|
1159
1152
|
{
|
|
@@ -1185,6 +1178,10 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
1185
1178
|
style={
|
|
1186
1179
|
{
|
|
1187
1180
|
"alignItems": "center",
|
|
1181
|
+
"borderColor": "#7B93DB",
|
|
1182
|
+
"borderRadius": 21,
|
|
1183
|
+
"borderStyle": "solid",
|
|
1184
|
+
"borderWidth": 1,
|
|
1188
1185
|
"height": 42,
|
|
1189
1186
|
"justifyContent": "center",
|
|
1190
1187
|
"opacity": 1,
|
|
@@ -1204,6 +1201,9 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
1204
1201
|
"lineHeight": 22.4,
|
|
1205
1202
|
"marginTop": 4,
|
|
1206
1203
|
},
|
|
1204
|
+
{
|
|
1205
|
+
"color": "#7B93DB",
|
|
1206
|
+
},
|
|
1207
1207
|
]
|
|
1208
1208
|
}
|
|
1209
1209
|
>
|
|
@@ -4436,8 +4436,7 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
4436
4436
|
}
|
|
4437
4437
|
>
|
|
4438
4438
|
<View
|
|
4439
|
-
accessibilityLabel="
|
|
4440
|
-
accessibilityRole="button"
|
|
4439
|
+
accessibilityLabel=" Maandag 3 April 2023 "
|
|
4441
4440
|
accessibilityState={
|
|
4442
4441
|
{
|
|
4443
4442
|
"busy": undefined,
|
|
@@ -4468,10 +4467,6 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
4468
4467
|
style={
|
|
4469
4468
|
{
|
|
4470
4469
|
"alignItems": "center",
|
|
4471
|
-
"borderColor": "#7B93DB",
|
|
4472
|
-
"borderRadius": 21,
|
|
4473
|
-
"borderStyle": "solid",
|
|
4474
|
-
"borderWidth": 1,
|
|
4475
4470
|
"height": 42,
|
|
4476
4471
|
"justifyContent": "center",
|
|
4477
4472
|
"opacity": 1,
|
|
@@ -4492,7 +4487,7 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
4492
4487
|
"marginTop": 4,
|
|
4493
4488
|
},
|
|
4494
4489
|
{
|
|
4495
|
-
"color": "#
|
|
4490
|
+
"color": "#9AA5B1",
|
|
4496
4491
|
},
|
|
4497
4492
|
]
|
|
4498
4493
|
}
|
|
@@ -4524,7 +4519,8 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
4524
4519
|
}
|
|
4525
4520
|
>
|
|
4526
4521
|
<View
|
|
4527
|
-
accessibilityLabel=" Dinsdag 4 April 2023 "
|
|
4522
|
+
accessibilityLabel="today Dinsdag 4 April 2023 "
|
|
4523
|
+
accessibilityRole="button"
|
|
4528
4524
|
accessibilityState={
|
|
4529
4525
|
{
|
|
4530
4526
|
"busy": undefined,
|
|
@@ -4555,6 +4551,10 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
4555
4551
|
style={
|
|
4556
4552
|
{
|
|
4557
4553
|
"alignItems": "center",
|
|
4554
|
+
"borderColor": "#7B93DB",
|
|
4555
|
+
"borderRadius": 21,
|
|
4556
|
+
"borderStyle": "solid",
|
|
4557
|
+
"borderWidth": 1,
|
|
4558
4558
|
"height": 42,
|
|
4559
4559
|
"justifyContent": "center",
|
|
4560
4560
|
"opacity": 1,
|
|
@@ -4575,7 +4575,7 @@ exports[`Test for the calendar component renders a calendar where you can select
|
|
|
4575
4575
|
"marginTop": 4,
|
|
4576
4576
|
},
|
|
4577
4577
|
{
|
|
4578
|
-
"color": "#
|
|
4578
|
+
"color": "#7B93DB",
|
|
4579
4579
|
},
|
|
4580
4580
|
]
|
|
4581
4581
|
}
|
|
@@ -6,8 +6,9 @@ export const Stylesheet = (context) =>
|
|
|
6
6
|
StyleSheet.create({
|
|
7
7
|
container: {
|
|
8
8
|
flexDirection: 'row',
|
|
9
|
-
alignItems: 'center',
|
|
9
|
+
alignItems: Platform.OS === 'android' ? 'center' : 'flex-start',
|
|
10
10
|
justifyContent: 'center',
|
|
11
|
+
paddingTop: Platform.OS === 'android' ? 0 : Scale.m,
|
|
11
12
|
backgroundColor: context.colors.ui.xlightgrey,
|
|
12
13
|
borderTopColor: context.colors.ui.lightgrey,
|
|
13
14
|
borderStyle: 'solid',
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
1
2
|
import { ImageSourcePropType } from 'react-native';
|
|
2
3
|
import { Size } from '../../../types/size.enum';
|
|
3
4
|
import { Initials } from '../../../models/initials.model';
|
|
@@ -6,6 +7,7 @@ type AvatarProps = {
|
|
|
6
7
|
size: Size;
|
|
7
8
|
isBlocked?: boolean;
|
|
8
9
|
isActive?: boolean;
|
|
10
|
+
isLoading?: boolean;
|
|
9
11
|
};
|
|
10
|
-
declare const Avatar: ({ source, size, isBlocked, isActive }: AvatarProps) => JSX.Element;
|
|
12
|
+
declare const Avatar: ({ source, size, isBlocked, isActive, isLoading, }: AvatarProps) => JSX.Element;
|
|
11
13
|
export { Avatar as Avatar };
|
|
@@ -1,7 +1,13 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import {useContext} from 'react';
|
|
3
3
|
|
|
4
|
-
import {
|
|
4
|
+
import {
|
|
5
|
+
ActivityIndicator,
|
|
6
|
+
Image,
|
|
7
|
+
ImageSourcePropType,
|
|
8
|
+
ImageStyle,
|
|
9
|
+
View,
|
|
10
|
+
} from 'react-native';
|
|
5
11
|
import {ThemeCtx} from '../../../context/theme.context';
|
|
6
12
|
import {Stylesheet} from './avatar.styles';
|
|
7
13
|
import {Size} from '../../../types/size.enum';
|
|
@@ -14,9 +20,16 @@ type AvatarProps = {
|
|
|
14
20
|
size: Size;
|
|
15
21
|
isBlocked?: boolean;
|
|
16
22
|
isActive?: boolean;
|
|
23
|
+
isLoading?: boolean;
|
|
17
24
|
};
|
|
18
25
|
|
|
19
|
-
const Avatar = ({
|
|
26
|
+
const Avatar = ({
|
|
27
|
+
source,
|
|
28
|
+
size,
|
|
29
|
+
isBlocked,
|
|
30
|
+
isActive = true,
|
|
31
|
+
isLoading,
|
|
32
|
+
}: AvatarProps) => {
|
|
20
33
|
const Context = useContext(ThemeCtx);
|
|
21
34
|
const styles = Stylesheet(Context, size, isBlocked, isActive);
|
|
22
35
|
|
|
@@ -56,7 +69,17 @@ const Avatar = ({source, size, isBlocked, isActive = true}: AvatarProps) => {
|
|
|
56
69
|
};
|
|
57
70
|
|
|
58
71
|
return source instanceof Initials ? (
|
|
59
|
-
<View style={styles.container}>
|
|
72
|
+
<View style={styles.container}>
|
|
73
|
+
{isLoading ? (
|
|
74
|
+
<ActivityIndicator size={'small'} color={Context.colors.ui.white} />
|
|
75
|
+
) : (
|
|
76
|
+
renderText(size)
|
|
77
|
+
)}
|
|
78
|
+
</View>
|
|
79
|
+
) : isLoading ? (
|
|
80
|
+
<View style={styles.container}>
|
|
81
|
+
<ActivityIndicator size={'small'} color={Context.colors.ui.white} />
|
|
82
|
+
</View>
|
|
60
83
|
) : (
|
|
61
84
|
<View style={styles.container}>
|
|
62
85
|
{!isBlocked ? <MainGradient isActive={isActive} /> : null}
|
|
@@ -13,7 +13,6 @@ exports[`Filter range test renders a filter range slider 1`] = `
|
|
|
13
13
|
animationType="timing"
|
|
14
14
|
onLayout={[Function]}
|
|
15
15
|
onValueChange={[Function]}
|
|
16
|
-
step={1}
|
|
17
16
|
style={
|
|
18
17
|
[
|
|
19
18
|
{
|
|
@@ -52,6 +51,7 @@ exports[`Filter range test renders a filter range slider 1`] = `
|
|
|
52
51
|
"borderRadius": 50,
|
|
53
52
|
"height": 8,
|
|
54
53
|
},
|
|
54
|
+
undefined,
|
|
55
55
|
]
|
|
56
56
|
}
|
|
57
57
|
/>
|
|
@@ -6,7 +6,7 @@ import {ThemeCtx} from '../../../context/theme.context';
|
|
|
6
6
|
import {Stylesheet} from './pill.styles';
|
|
7
7
|
import {VisualState} from '../../../types/visual-state.enum';
|
|
8
8
|
import {TinyText} from '../../atoms/paragraph-components';
|
|
9
|
-
import {TextColorHandler} from '../../../utilities/
|
|
9
|
+
import {TextColorHandler} from '../../../utilities/color-handler/color-handler';
|
|
10
10
|
|
|
11
11
|
type PillProps = {
|
|
12
12
|
visualState: VisualState;
|
|
@@ -6,7 +6,7 @@ import {ThemeCtx} from '../../../context/theme.context';
|
|
|
6
6
|
import {VisualState} from '../../../types/visual-state.enum';
|
|
7
7
|
import {Stylesheet} from './quick-filter.styles';
|
|
8
8
|
import {Paragraph} from '../../atoms/paragraph-components';
|
|
9
|
-
import {TextColorHandler} from '../../../utilities/
|
|
9
|
+
import {TextColorHandler} from '../../../utilities/color-handler/color-handler';
|
|
10
10
|
|
|
11
11
|
type QuickFilterProps = {
|
|
12
12
|
id: string;
|
|
@@ -31,7 +31,9 @@ const QuickFilter = ({
|
|
|
31
31
|
return (
|
|
32
32
|
<Pressable onPress={() => onSelect(id)} style={styles.container}>
|
|
33
33
|
{isLoading ? (
|
|
34
|
-
<ActivityIndicator
|
|
34
|
+
<ActivityIndicator
|
|
35
|
+
color={TextColorHandler(visualState, isSelected, isLoading)}
|
|
36
|
+
/>
|
|
35
37
|
) : (
|
|
36
38
|
<Paragraph
|
|
37
39
|
bold={true}
|