@hero-design/rn 8.0.0-rc.0 → 8.0.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/.eslintrc.js +2 -1
- package/.turbo/turbo-build.log +9 -9
- package/assets/fonts/{RebondGrotesque-Regular.otf → RebondGrotesque.otf} +0 -0
- package/assets/fonts/hero-icons-mobile.ttf +0 -0
- package/es/index.js +437 -617
- package/lib/assets/fonts/hero-icons-mobile.ttf +0 -0
- package/lib/index.js +436 -616
- package/package.json +9 -7
- package/src/components/Alert/StyledAlert.tsx +2 -3
- package/src/components/Alert/__tests__/__snapshots__/index.spec.tsx.snap +6 -12
- package/src/components/Alert/index.tsx +3 -23
- package/src/components/BottomSheet/StyledBottomSheet.tsx +0 -1
- package/src/components/BottomSheet/__tests__/__snapshots__/index.spec.tsx.snap +4 -6
- package/src/components/Box/__tests__/__snapshots__/index.spec.tsx.snap +4 -26
- package/src/components/Button/Button.tsx +7 -16
- package/src/components/Button/StyledButton.tsx +0 -46
- package/src/components/Button/__tests__/Button.spec.tsx +10 -11
- package/src/components/Button/__tests__/StyledButton.spec.tsx +0 -3
- package/src/components/Button/__tests__/__snapshots__/StyledButton.spec.tsx.snap +0 -91
- package/src/components/Card/StyledCard.tsx +2 -11
- package/src/components/Card/__tests__/StyledCard.spec.tsx +2 -14
- package/src/components/Card/__tests__/__snapshots__/StyledCard.spec.tsx.snap +0 -32
- package/src/components/Card/__tests__/__snapshots__/index.spec.tsx.snap +0 -4
- package/src/components/Card/__tests__/index.spec.tsx +1 -13
- package/src/components/Card/index.tsx +5 -26
- package/src/components/DatePicker/DatePickerAndroid.tsx +4 -0
- package/src/components/DatePicker/DatePickerIOS.tsx +9 -11
- package/src/components/DatePicker/__tests__/DatePicker.spec.tsx +4 -0
- package/src/components/DatePicker/__tests__/DatePickerAndroid.spec.tsx +4 -0
- package/src/components/DatePicker/__tests__/__snapshots__/DatePickerAndroid.spec.tsx.snap +3 -0
- package/src/components/DatePicker/__tests__/__snapshots__/DatePickerIOS.spec.tsx.snap +31 -12
- package/src/components/DatePicker/types.ts +8 -0
- package/src/components/Empty/__tests__/__snapshots__/index.spec.tsx.snap +2 -2
- package/src/components/Icon/HeroIcon/glyphMap.json +1 -1
- package/src/components/Icon/IconList.ts +0 -8
- package/src/components/List/__tests__/__snapshots__/ListItem.spec.tsx.snap +5 -7
- package/src/components/Progress/ProgressCircle.tsx +1 -1
- package/src/components/Select/Footer.tsx +2 -7
- package/src/components/Select/MultiSelect/__tests__/__snapshots__/index.spec.tsx.snap +120 -50
- package/src/components/Select/MultiSelect/index.tsx +1 -20
- package/src/components/Select/SingleSelect/__tests__/__snapshots__/index.spec.tsx.snap +5 -0
- package/src/components/Select/SingleSelect/index.tsx +5 -24
- package/src/components/Select/StyledSelect.tsx +1 -12
- package/src/components/Select/types.ts +1 -11
- package/src/components/Switch/StyledSwitch.tsx +7 -12
- package/src/components/Switch/__tests__/StyledSwitch.spec.tsx +2 -2
- package/src/components/Switch/__tests__/__snapshots__/StyledSwitch.spec.tsx.snap +10 -15
- package/src/components/Switch/__tests__/__snapshots__/index.spec.tsx.snap +8 -12
- package/src/components/Switch/index.tsx +6 -22
- package/src/components/Tabs/ScrollableTabs.tsx +1 -6
- package/src/components/Tabs/TabWithBadge.tsx +1 -15
- package/src/components/Tabs/__tests__/ScrollableTabs.spec.tsx +3 -1
- package/src/components/Tabs/__tests__/TabWithBadge.spec.tsx +0 -12
- package/src/components/Tabs/__tests__/__snapshots__/ScrollableTabs.spec.tsx.snap +4 -3
- package/src/components/Tabs/__tests__/__snapshots__/TabWithBadge.spec.tsx.snap +0 -70
- package/src/components/Tabs/__tests__/__snapshots__/index.spec.tsx.snap +1 -2
- package/src/components/Tabs/__tests__/index.spec.tsx +3 -1
- package/src/components/Tabs/index.tsx +12 -24
- package/src/components/Tag/StyledTag.tsx +0 -1
- package/src/components/Tag/__tests__/Tag.spec.tsx +0 -9
- package/src/components/Tag/__tests__/__snapshots__/Tag.spec.tsx.snap +0 -40
- package/src/components/Tag/index.tsx +3 -16
- package/src/components/TextInput/__tests__/__snapshots__/index.spec.tsx.snap +12 -0
- package/src/components/TextInput/__tests__/index.spec.tsx +4 -2
- package/src/components/TextInput/index.tsx +7 -1
- package/src/components/TimePicker/TimePickerIOS.tsx +5 -11
- package/src/components/TimePicker/__tests__/__snapshots__/TimePickerAndroid.spec.tsx.snap +1 -0
- package/src/components/TimePicker/__tests__/__snapshots__/TimePickerIOS.spec.tsx.snap +31 -12
- package/src/components/Typography/Text/__tests__/__snapshots__/StyledText.spec.tsx.snap +1 -1
- package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +9 -72
- package/src/theme/components/bottomSheet.ts +2 -3
- package/src/theme/components/select.ts +1 -5
- package/src/theme/components/switch.ts +4 -14
- package/src/theme/components/tag.ts +0 -2
- package/src/theme/global/colors/swag.ts +1 -20
- package/src/theme/global/colors/types.ts +1 -58
- package/src/theme/global/typography.ts +1 -1
- package/src/utils/hooks.ts +1 -1
- package/types/components/Accordion/AccordionItem.d.ts +0 -0
- package/types/components/Accordion/StyledAccordion.d.ts +0 -0
- package/types/components/Accordion/index.d.ts +0 -0
- package/types/components/Alert/StyledAlert.d.ts +0 -1
- package/types/components/Alert/index.d.ts +1 -6
- package/types/components/Attachment/StyledAttachment.d.ts +0 -0
- package/types/components/Attachment/index.d.ts +0 -0
- package/types/components/Avatar/Avatar.d.ts +0 -0
- package/types/components/Avatar/AvatarStack/StyledAvatarStack.d.ts +0 -0
- package/types/components/Avatar/AvatarStack/index.d.ts +0 -0
- package/types/components/Avatar/AvatarStack/utils.d.ts +0 -0
- package/types/components/Avatar/StyledAvatar.d.ts +0 -0
- package/types/components/Avatar/index.d.ts +0 -0
- package/types/components/Badge/Status.d.ts +0 -0
- package/types/components/Badge/StyledBadge.d.ts +0 -0
- package/types/components/Badge/index.d.ts +0 -0
- package/types/components/BottomNavigation/StyledBottomNavigation.d.ts +0 -0
- package/types/components/BottomNavigation/index.d.ts +0 -0
- package/types/components/BottomSheet/Footer.d.ts +0 -0
- package/types/components/BottomSheet/Header.d.ts +0 -0
- package/types/components/BottomSheet/StyledBottomSheet.d.ts +0 -0
- package/types/components/BottomSheet/index.d.ts +0 -0
- package/types/components/Box/StyledBox.d.ts +0 -0
- package/types/components/Box/config.d.ts +0 -0
- package/types/components/Box/index.d.ts +0 -0
- package/types/components/Box/types.d.ts +0 -0
- package/types/components/Button/Button.d.ts +2 -3
- package/types/components/Button/IconButton.d.ts +0 -0
- package/types/components/Button/LoadingIndicator/StyledLoadingIndicator.d.ts +0 -0
- package/types/components/Button/LoadingIndicator/index.d.ts +0 -0
- package/types/components/Button/StyledButton.d.ts +1 -1
- package/types/components/Button/UtilityButton/StyledUtilityButton.d.ts +0 -0
- package/types/components/Button/UtilityButton/index.d.ts +0 -0
- package/types/components/Button/index.d.ts +0 -0
- package/types/components/Calendar/CalendarRowItem.d.ts +0 -0
- package/types/components/Calendar/StyledCalendar.d.ts +0 -0
- package/types/components/Calendar/helpers.d.ts +0 -0
- package/types/components/Calendar/index.d.ts +0 -0
- package/types/components/Card/DataCard/StyledDataCard.d.ts +0 -0
- package/types/components/Card/DataCard/index.d.ts +0 -0
- package/types/components/Card/StyledCard.d.ts +1 -8
- package/types/components/Card/index.d.ts +2 -8
- package/types/components/Checkbox/StyledCheckbox.d.ts +0 -0
- package/types/components/Checkbox/index.d.ts +0 -0
- package/types/components/Collapse/StyledCollapse.d.ts +0 -0
- package/types/components/Collapse/index.d.ts +0 -0
- package/types/components/ContentNavigator/StyledContentNavigator.d.ts +0 -0
- package/types/components/ContentNavigator/index.d.ts +0 -0
- package/types/components/DatePicker/DatePickerAndroid.d.ts +1 -1
- package/types/components/DatePicker/DatePickerIOS.d.ts +1 -1
- package/types/components/DatePicker/StyledDatePicker.d.ts +0 -0
- package/types/components/DatePicker/index.d.ts +0 -0
- package/types/components/DatePicker/types.d.ts +8 -0
- package/types/components/Divider/StyledDivider.d.ts +0 -0
- package/types/components/Divider/index.d.ts +0 -0
- package/types/components/Drawer/DragableDrawer/helpers.d.ts +0 -0
- package/types/components/Drawer/DragableDrawer/index.d.ts +0 -0
- package/types/components/Drawer/StyledDrawer.d.ts +0 -0
- package/types/components/Drawer/index.d.ts +0 -0
- package/types/components/Empty/StyledEmpty.d.ts +0 -0
- package/types/components/Empty/index.d.ts +0 -0
- package/types/components/FAB/ActionGroup/ActionItem.d.ts +0 -0
- package/types/components/FAB/ActionGroup/StyledActionGroup.d.ts +0 -0
- package/types/components/FAB/ActionGroup/StyledActionItem.d.ts +0 -0
- package/types/components/FAB/ActionGroup/index.d.ts +0 -0
- package/types/components/FAB/AnimatedFABIcon.d.ts +0 -0
- package/types/components/FAB/FAB.d.ts +0 -0
- package/types/components/FAB/StyledFAB.d.ts +0 -0
- package/types/components/FAB/index.d.ts +0 -0
- package/types/components/Icon/AnimatedIcon.d.ts +0 -0
- package/types/components/Icon/HeroIcon/index.d.ts +0 -0
- package/types/components/Icon/IconList.d.ts +1 -1
- package/types/components/Icon/index.d.ts +1 -1
- package/types/components/Icon/utils.d.ts +1 -1
- package/types/components/Image/index.d.ts +0 -0
- package/types/components/List/BasicListItem.d.ts +0 -0
- package/types/components/List/ListItem.d.ts +0 -0
- package/types/components/List/StyledBasicListItem.d.ts +0 -0
- package/types/components/List/StyledListItem.d.ts +0 -0
- package/types/components/List/index.d.ts +0 -0
- package/types/components/PinInput/PinCell.d.ts +0 -0
- package/types/components/PinInput/StyledPinInput.d.ts +0 -0
- package/types/components/PinInput/index.d.ts +0 -0
- package/types/components/Progress/ProgressBar.d.ts +0 -0
- package/types/components/Progress/ProgressCircle.d.ts +0 -0
- package/types/components/Progress/StyledProgressBar.d.ts +0 -0
- package/types/components/Progress/StyledProgressCircle.d.ts +0 -0
- package/types/components/Progress/__tests__/index.spec.d.ts +0 -0
- package/types/components/Progress/constants.d.ts +0 -0
- package/types/components/Progress/index.d.ts +0 -0
- package/types/components/Progress/types.d.ts +0 -0
- package/types/components/Radio/Radio.d.ts +0 -0
- package/types/components/Radio/RadioGroup.d.ts +0 -0
- package/types/components/Radio/StyledRadio.d.ts +0 -0
- package/types/components/Radio/index.d.ts +0 -0
- package/types/components/Radio/types.d.ts +0 -0
- package/types/components/RefreshControl/index.d.ts +0 -0
- package/types/components/RichTextEditor/EditorEvent.d.ts +0 -0
- package/types/components/RichTextEditor/EditorToolbar.d.ts +0 -0
- package/types/components/RichTextEditor/MentionList.d.ts +0 -0
- package/types/components/RichTextEditor/RichTextEditor.d.ts +0 -0
- package/types/components/RichTextEditor/StyledRichTextEditor.d.ts +0 -0
- package/types/components/RichTextEditor/StyledToolbar.d.ts +0 -0
- package/types/components/RichTextEditor/__mocks__/heroEditorApp.d.ts +0 -0
- package/types/components/RichTextEditor/constants.d.ts +0 -0
- package/types/components/RichTextEditor/heroEditorApp.d.ts +0 -0
- package/types/components/RichTextEditor/index.d.ts +0 -0
- package/types/components/RichTextEditor/types.d.ts +0 -0
- package/types/components/RichTextEditor/utils/events.d.ts +0 -0
- package/types/components/RichTextEditor/utils/rnWebView.d.ts +0 -0
- package/types/components/SectionHeading/StyledHeading.d.ts +0 -0
- package/types/components/SectionHeading/index.d.ts +0 -0
- package/types/components/Select/BaseOptionList.d.ts +0 -0
- package/types/components/Select/Footer.d.ts +0 -0
- package/types/components/Select/MultiSelect/Option.d.ts +0 -0
- package/types/components/Select/MultiSelect/OptionList.d.ts +0 -0
- package/types/components/Select/MultiSelect/index.d.ts +1 -1
- package/types/components/Select/SingleSelect/Option.d.ts +0 -0
- package/types/components/Select/SingleSelect/OptionList.d.ts +0 -0
- package/types/components/Select/SingleSelect/StyledSingleSelect.d.ts +0 -0
- package/types/components/Select/SingleSelect/index.d.ts +1 -1
- package/types/components/Select/StyledSelect.d.ts +1 -5
- package/types/components/Select/helpers.d.ts +0 -0
- package/types/components/Select/index.d.ts +1 -1
- package/types/components/Select/types.d.ts +1 -11
- package/types/components/Slider/index.d.ts +0 -0
- package/types/components/Spinner/AnimatedSpinner.d.ts +0 -0
- package/types/components/Spinner/StyledSpinner.d.ts +0 -0
- package/types/components/Spinner/index.d.ts +0 -0
- package/types/components/Swipeable/StyledSwipeable.d.ts +0 -0
- package/types/components/Swipeable/SwipeableAction.d.ts +0 -0
- package/types/components/Swipeable/index.d.ts +0 -0
- package/types/components/Switch/SelectorSwitch/Option.d.ts +0 -0
- package/types/components/Switch/SelectorSwitch/StyledSelectorSwitch.d.ts +0 -0
- package/types/components/Switch/SelectorSwitch/index.d.ts +0 -0
- package/types/components/Switch/StyledSwitch.d.ts +0 -4
- package/types/components/Switch/index.d.ts +1 -6
- package/types/components/Tabs/ActiveTabIndicator.d.ts +0 -0
- package/types/components/Tabs/ScrollableTabs.d.ts +0 -0
- package/types/components/Tabs/StyledScrollableTabs.d.ts +0 -0
- package/types/components/Tabs/StyledTabs.d.ts +0 -0
- package/types/components/Tabs/TabWithBadge.d.ts +1 -2
- package/types/components/Tabs/index.d.ts +2 -3
- package/types/components/Tabs/utils.d.ts +0 -0
- package/types/components/Tag/StyledTag.d.ts +1 -1
- package/types/components/Tag/index.d.ts +2 -2
- package/types/components/TextInput/StyledTextInput.d.ts +0 -0
- package/types/components/TextInput/index.d.ts +0 -0
- package/types/components/TimePicker/StyledTimePicker.d.ts +0 -0
- package/types/components/TimePicker/TimePickerAndroid.d.ts +0 -0
- package/types/components/TimePicker/TimePickerIOS.d.ts +0 -0
- package/types/components/TimePicker/index.d.ts +0 -0
- package/types/components/TimePicker/types.d.ts +0 -0
- package/types/components/Toast/StyledToast.d.ts +0 -0
- package/types/components/Toast/Toast.d.ts +0 -0
- package/types/components/Toast/ToastContainer.d.ts +0 -0
- package/types/components/Toast/ToastContext.d.ts +0 -0
- package/types/components/Toast/ToastProvider.d.ts +0 -0
- package/types/components/Toast/index.d.ts +0 -0
- package/types/components/Toast/types.d.ts +0 -0
- package/types/components/Toolbar/StyledToolbar.d.ts +0 -0
- package/types/components/Toolbar/ToolbarGroup.d.ts +0 -0
- package/types/components/Toolbar/ToolbarItem.d.ts +0 -0
- package/types/components/Toolbar/index.d.ts +0 -0
- package/types/components/Typography/Text/StyledText.d.ts +0 -0
- package/types/components/Typography/Text/index.d.ts +0 -0
- package/types/components/Typography/index.d.ts +0 -0
- package/types/index.d.ts +0 -0
- package/types/testHelpers/renderWithTheme.d.ts +0 -0
- package/types/theme/ThemeProvider.d.ts +0 -0
- package/types/theme/ThemeSwitcher.d.ts +0 -0
- package/types/theme/components/accordion.d.ts +0 -0
- package/types/theme/components/alert.d.ts +0 -0
- package/types/theme/components/attachment.d.ts +0 -0
- package/types/theme/components/avatar.d.ts +0 -0
- package/types/theme/components/badge.d.ts +0 -0
- package/types/theme/components/bottomNavigation.d.ts +0 -0
- package/types/theme/components/bottomSheet.d.ts +0 -1
- package/types/theme/components/button.d.ts +0 -0
- package/types/theme/components/calendar.d.ts +0 -0
- package/types/theme/components/card.d.ts +0 -0
- package/types/theme/components/checkbox.d.ts +0 -0
- package/types/theme/components/contentNavigator.d.ts +0 -0
- package/types/theme/components/datePicker.d.ts +0 -0
- package/types/theme/components/divider.d.ts +0 -0
- package/types/theme/components/drawer.d.ts +0 -0
- package/types/theme/components/empty.d.ts +0 -0
- package/types/theme/components/fab.d.ts +0 -0
- package/types/theme/components/icon.d.ts +0 -0
- package/types/theme/components/image.d.ts +0 -0
- package/types/theme/components/list.d.ts +0 -0
- package/types/theme/components/pinInput.d.ts +0 -0
- package/types/theme/components/progress.d.ts +0 -0
- package/types/theme/components/radio.d.ts +0 -0
- package/types/theme/components/refreshControl.d.ts +0 -0
- package/types/theme/components/richTextEditor.d.ts +0 -0
- package/types/theme/components/sectionHeading.d.ts +0 -0
- package/types/theme/components/select.d.ts +0 -3
- package/types/theme/components/slider.d.ts +0 -0
- package/types/theme/components/spinner.d.ts +0 -0
- package/types/theme/components/swipeable.d.ts +0 -0
- package/types/theme/components/switch.d.ts +4 -14
- package/types/theme/components/tabs.d.ts +0 -0
- package/types/theme/components/tag.d.ts +0 -2
- package/types/theme/components/textInput.d.ts +0 -0
- package/types/theme/components/timePicker.d.ts +0 -0
- package/types/theme/components/toast.d.ts +0 -0
- package/types/theme/components/toolbar.d.ts +0 -0
- package/types/theme/components/typography.d.ts +0 -0
- package/types/theme/getTheme.d.ts +0 -0
- package/types/theme/global/borders.d.ts +0 -0
- package/types/theme/global/colors/eBens.d.ts +0 -0
- package/types/theme/global/colors/global.d.ts +0 -0
- package/types/theme/global/colors/jobs.d.ts +0 -0
- package/types/theme/global/colors/swag.d.ts +0 -0
- package/types/theme/global/colors/types.d.ts +1 -52
- package/types/theme/global/colors/wallet.d.ts +0 -0
- package/types/theme/global/colors/work.d.ts +0 -0
- package/types/theme/global/index.d.ts +0 -47
- package/types/theme/global/scale.d.ts +0 -0
- package/types/theme/global/sizes.d.ts +0 -0
- package/types/theme/global/space.d.ts +0 -0
- package/types/theme/global/typography.d.ts +0 -0
- package/types/theme/index.d.ts +0 -0
- package/types/types.d.ts +0 -0
- package/types/utils/functions.d.ts +0 -0
- package/types/utils/helpers.d.ts +0 -0
- package/types/utils/hooks.d.ts +0 -0
- package/types/utils/scale.d.ts +0 -0
- package/.expo/README.md +0 -15
- package/.expo/packager-info.json +0 -10
- package/.expo/prebuild/cached-packages.json +0 -4
- package/.expo/settings.json +0 -10
- package/.expo/xcodebuild-error.log +0 -2
- package/.expo/xcodebuild.log +0 -11199
- package/.turbo/turbo-build:types.log +0 -2
- package/.turbo/turbo-build:watch.log +0 -1
- package/.turbo/turbo-lint.log +0 -96
- package/.turbo/turbo-test.log +0 -909
- package/src/components/Select/__tests__/StyledSelect.spec.tsx +0 -14
- package/src/components/Select/__tests__/__snapshots__/StyledSelect.spec.tsx.snap +0 -29
- package/src/theme/__tests__/ensureCompatibleWithV7.spec.tsx +0 -13
- package/src/theme/global/colors/legacySystemPalette.ts +0 -53
- package/types/components/Accordion/utils.d.ts +0 -1
- package/types/components/Select/StyledOptionList.d.ts +0 -12
- package/types/theme/global/colors/legacySystemPalette.d.ts +0 -3
- package/types/theme/utils.d.ts +0 -2
|
@@ -8,11 +8,10 @@ exports[`StyledKnot renders correct style 1`] = `
|
|
|
8
8
|
Object {
|
|
9
9
|
"backgroundColor": "#ffffff",
|
|
10
10
|
"borderRadius": 999,
|
|
11
|
-
"height":
|
|
12
|
-
"width":
|
|
11
|
+
"height": 16,
|
|
12
|
+
"width": 16,
|
|
13
13
|
}
|
|
14
14
|
}
|
|
15
|
-
themeSize="medium"
|
|
16
15
|
/>
|
|
17
16
|
`;
|
|
18
17
|
|
|
@@ -24,15 +23,14 @@ exports[`StyledWrapper renders correct style with variant checked 1`] = `
|
|
|
24
23
|
"backgroundColor": "#401960",
|
|
25
24
|
"borderRadius": 999,
|
|
26
25
|
"display": "flex",
|
|
27
|
-
"height":
|
|
26
|
+
"height": 24,
|
|
28
27
|
"justifyContent": "center",
|
|
29
28
|
"paddingHorizontal": 4,
|
|
30
|
-
"width":
|
|
29
|
+
"width": 48,
|
|
31
30
|
},
|
|
32
31
|
undefined,
|
|
33
32
|
]
|
|
34
33
|
}
|
|
35
|
-
themeSize="medium"
|
|
36
34
|
themeVariant="checked"
|
|
37
35
|
/>
|
|
38
36
|
`;
|
|
@@ -45,15 +43,14 @@ exports[`StyledWrapper renders correct style with variant disabled-checked 1`] =
|
|
|
45
43
|
"backgroundColor": "#ece8ef",
|
|
46
44
|
"borderRadius": 999,
|
|
47
45
|
"display": "flex",
|
|
48
|
-
"height":
|
|
46
|
+
"height": 24,
|
|
49
47
|
"justifyContent": "center",
|
|
50
48
|
"paddingHorizontal": 4,
|
|
51
|
-
"width":
|
|
49
|
+
"width": 48,
|
|
52
50
|
},
|
|
53
51
|
undefined,
|
|
54
52
|
]
|
|
55
53
|
}
|
|
56
|
-
themeSize="medium"
|
|
57
54
|
themeVariant="disabled-checked"
|
|
58
55
|
/>
|
|
59
56
|
`;
|
|
@@ -66,15 +63,14 @@ exports[`StyledWrapper renders correct style with variant disabled-unchecked 1`]
|
|
|
66
63
|
"backgroundColor": "#bfc1c5",
|
|
67
64
|
"borderRadius": 999,
|
|
68
65
|
"display": "flex",
|
|
69
|
-
"height":
|
|
66
|
+
"height": 24,
|
|
70
67
|
"justifyContent": "center",
|
|
71
68
|
"paddingHorizontal": 4,
|
|
72
|
-
"width":
|
|
69
|
+
"width": 48,
|
|
73
70
|
},
|
|
74
71
|
undefined,
|
|
75
72
|
]
|
|
76
73
|
}
|
|
77
|
-
themeSize="medium"
|
|
78
74
|
themeVariant="disabled-unchecked"
|
|
79
75
|
/>
|
|
80
76
|
`;
|
|
@@ -87,15 +83,14 @@ exports[`StyledWrapper renders correct style with variant unchecked 1`] = `
|
|
|
87
83
|
"backgroundColor": "#808f91",
|
|
88
84
|
"borderRadius": 999,
|
|
89
85
|
"display": "flex",
|
|
90
|
-
"height":
|
|
86
|
+
"height": 24,
|
|
91
87
|
"justifyContent": "center",
|
|
92
88
|
"paddingHorizontal": 4,
|
|
93
|
-
"width":
|
|
89
|
+
"width": 48,
|
|
94
90
|
},
|
|
95
91
|
undefined,
|
|
96
92
|
]
|
|
97
93
|
}
|
|
98
|
-
themeSize="medium"
|
|
99
94
|
themeVariant="unchecked"
|
|
100
95
|
/>
|
|
101
96
|
`;
|
|
@@ -22,16 +22,15 @@ exports[`Switch renders correctly 1`] = `
|
|
|
22
22
|
"backgroundColor": "#808f91",
|
|
23
23
|
"borderRadius": 999,
|
|
24
24
|
"display": "flex",
|
|
25
|
-
"height":
|
|
25
|
+
"height": 24,
|
|
26
26
|
"justifyContent": "center",
|
|
27
27
|
"paddingHorizontal": 4,
|
|
28
|
-
"width":
|
|
28
|
+
"width": 48,
|
|
29
29
|
},
|
|
30
30
|
undefined,
|
|
31
31
|
]
|
|
32
32
|
}
|
|
33
33
|
testID="switch"
|
|
34
|
-
themeSize="medium"
|
|
35
34
|
themeVariant="unchecked"
|
|
36
35
|
>
|
|
37
36
|
<View
|
|
@@ -41,12 +40,11 @@ exports[`Switch renders correctly 1`] = `
|
|
|
41
40
|
Object {
|
|
42
41
|
"backgroundColor": "#ffffff",
|
|
43
42
|
"borderRadius": 999,
|
|
44
|
-
"height":
|
|
43
|
+
"height": 16,
|
|
45
44
|
"left": 0,
|
|
46
|
-
"width":
|
|
45
|
+
"width": 16,
|
|
47
46
|
}
|
|
48
47
|
}
|
|
49
|
-
themeSize="medium"
|
|
50
48
|
/>
|
|
51
49
|
</View>
|
|
52
50
|
`;
|
|
@@ -73,16 +71,15 @@ exports[`Switch trigger press function correctly 1`] = `
|
|
|
73
71
|
"backgroundColor": "#808f91",
|
|
74
72
|
"borderRadius": 999,
|
|
75
73
|
"display": "flex",
|
|
76
|
-
"height":
|
|
74
|
+
"height": 24,
|
|
77
75
|
"justifyContent": "center",
|
|
78
76
|
"paddingHorizontal": 4,
|
|
79
|
-
"width":
|
|
77
|
+
"width": 48,
|
|
80
78
|
},
|
|
81
79
|
undefined,
|
|
82
80
|
]
|
|
83
81
|
}
|
|
84
82
|
testID="switch"
|
|
85
|
-
themeSize="medium"
|
|
86
83
|
themeVariant="unchecked"
|
|
87
84
|
>
|
|
88
85
|
<View
|
|
@@ -92,12 +89,11 @@ exports[`Switch trigger press function correctly 1`] = `
|
|
|
92
89
|
Object {
|
|
93
90
|
"backgroundColor": "#ffffff",
|
|
94
91
|
"borderRadius": 999,
|
|
95
|
-
"height":
|
|
92
|
+
"height": 16,
|
|
96
93
|
"left": 0,
|
|
97
|
-
"width":
|
|
94
|
+
"width": 16,
|
|
98
95
|
}
|
|
99
96
|
}
|
|
100
|
-
themeSize="medium"
|
|
101
97
|
/>
|
|
102
98
|
</View>
|
|
103
99
|
`;
|
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
import { useTheme } from '@emotion/react';
|
|
2
|
-
import React, {
|
|
2
|
+
import React, { useEffect, useState } from 'react';
|
|
3
3
|
|
|
4
4
|
import { Animated, Easing, TouchableWithoutFeedback } from 'react-native';
|
|
5
5
|
|
|
6
6
|
import type { ReactElement } from 'react';
|
|
7
7
|
import type { StyleProp, ViewStyle } from 'react-native';
|
|
8
|
-
import { StyledKnot, StyledWrapper, Variant } from './StyledSwitch';
|
|
9
8
|
import SelectorSwitch from './SelectorSwitch';
|
|
10
|
-
import {
|
|
9
|
+
import { StyledKnot, StyledWrapper, Variant } from './StyledSwitch';
|
|
11
10
|
|
|
12
11
|
export interface SwitchProps {
|
|
13
12
|
/**
|
|
@@ -22,11 +21,6 @@ export interface SwitchProps {
|
|
|
22
21
|
* Event handler.
|
|
23
22
|
*/
|
|
24
23
|
onPress?: () => void;
|
|
25
|
-
/**
|
|
26
|
-
* Size of the switch
|
|
27
|
-
* size is deprecated and will be removed in the next major release.
|
|
28
|
-
*/
|
|
29
|
-
size?: 'small' | 'medium';
|
|
30
24
|
/**
|
|
31
25
|
* Additional style.
|
|
32
26
|
*/
|
|
@@ -51,28 +45,18 @@ const getVariant = ({
|
|
|
51
45
|
};
|
|
52
46
|
|
|
53
47
|
const Switch = ({
|
|
54
|
-
size: _size,
|
|
55
48
|
disabled = false,
|
|
56
49
|
checked = false,
|
|
57
50
|
onPress,
|
|
58
51
|
style,
|
|
59
52
|
testID,
|
|
60
53
|
}: SwitchProps): ReactElement => {
|
|
61
|
-
const size: SwitchProps['size'] = _size === undefined ? 'medium' : _size;
|
|
62
|
-
|
|
63
54
|
const theme = useTheme();
|
|
64
55
|
const variant = getVariant({ disabled, checked });
|
|
65
56
|
|
|
66
|
-
useDeprecation(
|
|
67
|
-
"Switch's size prop will be removed in the next major release.",
|
|
68
|
-
_size !== undefined
|
|
69
|
-
);
|
|
70
|
-
|
|
71
57
|
const offset = checked
|
|
72
|
-
? (theme.__hd__.switch.sizes.
|
|
73
|
-
|
|
74
|
-
2 +
|
|
75
|
-
theme.__hd__.switch.sizes.thumbs[size] / 2
|
|
58
|
+
? (theme.__hd__.switch.sizes.width - theme.__hd__.switch.sizes.thumb) / 2 +
|
|
59
|
+
theme.__hd__.switch.sizes.thumb / 2
|
|
76
60
|
: 0;
|
|
77
61
|
|
|
78
62
|
const [animatedOffset] = useState(() => new Animated.Value(offset));
|
|
@@ -90,8 +74,8 @@ const Switch = ({
|
|
|
90
74
|
onPress={onPress}
|
|
91
75
|
disabled={disabled}
|
|
92
76
|
>
|
|
93
|
-
<StyledWrapper themeVariant={variant}
|
|
94
|
-
<StyledKnot
|
|
77
|
+
<StyledWrapper themeVariant={variant} style={style}>
|
|
78
|
+
<StyledKnot style={{ left: animatedOffset }} />
|
|
95
79
|
</StyledWrapper>
|
|
96
80
|
</TouchableWithoutFeedback>
|
|
97
81
|
);
|
|
@@ -130,7 +130,6 @@ const ScrollableTab = ({
|
|
|
130
130
|
testID,
|
|
131
131
|
activeItem,
|
|
132
132
|
inactiveItem: originalInactiveItem,
|
|
133
|
-
showBadge,
|
|
134
133
|
badge,
|
|
135
134
|
} = tab;
|
|
136
135
|
const active = selectedTabKey === key;
|
|
@@ -174,11 +173,7 @@ const ScrollableTab = ({
|
|
|
174
173
|
/>
|
|
175
174
|
</HeaderTabItemOutlineWrapper>
|
|
176
175
|
<HeaderTabItemWrapper>
|
|
177
|
-
<TabWithBadge
|
|
178
|
-
showBadge={showBadge}
|
|
179
|
-
config={badge}
|
|
180
|
-
tabItem={tabItem}
|
|
181
|
-
/>
|
|
176
|
+
<TabWithBadge config={badge} tabItem={tabItem} />
|
|
182
177
|
</HeaderTabItemWrapper>
|
|
183
178
|
</HeaderTabItem>
|
|
184
179
|
</TouchableWithoutFeedback>
|
|
@@ -17,27 +17,13 @@ export type CounterBadgeType = {
|
|
|
17
17
|
export type BadgeConfigType = StatusBadgeType | CounterBadgeType;
|
|
18
18
|
|
|
19
19
|
interface TabWithBadgeProps {
|
|
20
|
-
showBadge?: boolean;
|
|
21
20
|
config?: BadgeConfigType;
|
|
22
21
|
tabItem: ReactNode;
|
|
23
22
|
}
|
|
24
23
|
|
|
25
|
-
const TabWithBadge = ({
|
|
24
|
+
const TabWithBadge = ({ config, tabItem }: TabWithBadgeProps) => {
|
|
26
25
|
const theme = useTheme();
|
|
27
26
|
|
|
28
|
-
// Deprecated. To be removed.
|
|
29
|
-
if (showBadge !== undefined) {
|
|
30
|
-
return (
|
|
31
|
-
<Badge.Status
|
|
32
|
-
testID="deprecated-badge"
|
|
33
|
-
visible={showBadge}
|
|
34
|
-
style={{ paddingHorizontal: theme.space.small }}
|
|
35
|
-
>
|
|
36
|
-
{tabItem}
|
|
37
|
-
</Badge.Status>
|
|
38
|
-
);
|
|
39
|
-
}
|
|
40
|
-
|
|
41
27
|
if (!config) return <View>{tabItem}</View>;
|
|
42
28
|
|
|
43
29
|
if (config.type === 'status') {
|
|
@@ -12,18 +12,6 @@ const counterBadge = {
|
|
|
12
12
|
} as const;
|
|
13
13
|
|
|
14
14
|
describe('TabWithBadge', () => {
|
|
15
|
-
it.each`
|
|
16
|
-
showBadge
|
|
17
|
-
${true}
|
|
18
|
-
${false}
|
|
19
|
-
`('renders correctly when showBadge prop is available', ({ showBadge }) => {
|
|
20
|
-
const { toJSON } = renderWithTheme(
|
|
21
|
-
<TabWithBadge showBadge={showBadge} tabItem="Tab Item" />
|
|
22
|
-
);
|
|
23
|
-
|
|
24
|
-
expect(toJSON()).toMatchSnapshot();
|
|
25
|
-
});
|
|
26
|
-
|
|
27
15
|
it('renders nothing config is not available', () => {
|
|
28
16
|
const { toJSON } = renderWithTheme(<TabWithBadge tabItem="Tab Item" />);
|
|
29
17
|
|
|
@@ -148,12 +148,14 @@ exports[`Tabs.Scroll renders correctly 1`] = `
|
|
|
148
148
|
},
|
|
149
149
|
Object {
|
|
150
150
|
"activeItem": "home",
|
|
151
|
+
"badge": Object {
|
|
152
|
+
"type": "status",
|
|
153
|
+
},
|
|
151
154
|
"component": <Text>
|
|
152
155
|
Home Screen
|
|
153
156
|
</Text>,
|
|
154
157
|
"inactiveItem": "home-outlined",
|
|
155
158
|
"key": "home",
|
|
156
|
-
"showBadge": true,
|
|
157
159
|
},
|
|
158
160
|
Object {
|
|
159
161
|
"activeItem": "calendar",
|
|
@@ -467,10 +469,9 @@ exports[`Tabs.Scroll renders correctly 1`] = `
|
|
|
467
469
|
<View
|
|
468
470
|
style={
|
|
469
471
|
Object {
|
|
470
|
-
"paddingHorizontal":
|
|
472
|
+
"paddingHorizontal": 4,
|
|
471
473
|
}
|
|
472
474
|
}
|
|
473
|
-
testID="deprecated-badge"
|
|
474
475
|
>
|
|
475
476
|
<HeroIcon
|
|
476
477
|
name="home-outlined"
|
|
@@ -1,75 +1,5 @@
|
|
|
1
1
|
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
2
|
|
|
3
|
-
exports[`TabWithBadge renders correctly when showBadge prop is available 1`] = `
|
|
4
|
-
<View
|
|
5
|
-
style={
|
|
6
|
-
Object {
|
|
7
|
-
"paddingHorizontal": 8,
|
|
8
|
-
}
|
|
9
|
-
}
|
|
10
|
-
testID="deprecated-badge"
|
|
11
|
-
>
|
|
12
|
-
Tab Item
|
|
13
|
-
<View
|
|
14
|
-
collapsable={false}
|
|
15
|
-
nativeID="animatedComponent"
|
|
16
|
-
style={
|
|
17
|
-
Object {
|
|
18
|
-
"backgroundColor": "#de350b",
|
|
19
|
-
"borderRadius": 999,
|
|
20
|
-
"height": 8,
|
|
21
|
-
"opacity": 1,
|
|
22
|
-
"position": "absolute",
|
|
23
|
-
"right": -2,
|
|
24
|
-
"top": -2,
|
|
25
|
-
"transform": Array [
|
|
26
|
-
Object {
|
|
27
|
-
"scale": 1,
|
|
28
|
-
},
|
|
29
|
-
],
|
|
30
|
-
"width": 8,
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
themeIntent="danger"
|
|
34
|
-
/>
|
|
35
|
-
</View>
|
|
36
|
-
`;
|
|
37
|
-
|
|
38
|
-
exports[`TabWithBadge renders correctly when showBadge prop is available 2`] = `
|
|
39
|
-
<View
|
|
40
|
-
style={
|
|
41
|
-
Object {
|
|
42
|
-
"paddingHorizontal": 8,
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
testID="deprecated-badge"
|
|
46
|
-
>
|
|
47
|
-
Tab Item
|
|
48
|
-
<View
|
|
49
|
-
collapsable={false}
|
|
50
|
-
nativeID="animatedComponent"
|
|
51
|
-
style={
|
|
52
|
-
Object {
|
|
53
|
-
"backgroundColor": "#de350b",
|
|
54
|
-
"borderRadius": 999,
|
|
55
|
-
"height": 8,
|
|
56
|
-
"opacity": 0,
|
|
57
|
-
"position": "absolute",
|
|
58
|
-
"right": -2,
|
|
59
|
-
"top": -2,
|
|
60
|
-
"transform": Array [
|
|
61
|
-
Object {
|
|
62
|
-
"scale": 0.5,
|
|
63
|
-
},
|
|
64
|
-
],
|
|
65
|
-
"width": 8,
|
|
66
|
-
}
|
|
67
|
-
}
|
|
68
|
-
themeIntent="danger"
|
|
69
|
-
/>
|
|
70
|
-
</View>
|
|
71
|
-
`;
|
|
72
|
-
|
|
73
3
|
exports[`TabWithBadge renders correctly with counter badge config 1`] = `
|
|
74
4
|
<View
|
|
75
5
|
style={
|
|
@@ -1,26 +1,25 @@
|
|
|
1
|
-
import React, { useEffect } from 'react';
|
|
2
|
-
import { Animated, TouchableWithoutFeedback, View } from 'react-native';
|
|
3
|
-
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
4
1
|
import { useTheme } from '@emotion/react';
|
|
5
|
-
import PagerView from 'react-native-pager-view';
|
|
6
2
|
import type { ReactNode } from 'react';
|
|
7
|
-
import
|
|
3
|
+
import React, { useEffect } from 'react';
|
|
4
|
+
import type { StyleProp, ViewProps, ViewStyle } from 'react-native';
|
|
5
|
+
import { Animated, TouchableWithoutFeedback, View } from 'react-native';
|
|
8
6
|
import type { PagerViewOnPageScrollEventData } from 'react-native-pager-view';
|
|
7
|
+
import PagerView from 'react-native-pager-view';
|
|
8
|
+
import { useSafeAreaInsets } from 'react-native-safe-area-context';
|
|
9
|
+
import { IconName } from '../Icon';
|
|
9
10
|
import Typography from '../Typography';
|
|
11
|
+
import ActiveTabIndicator from './ActiveTabIndicator';
|
|
12
|
+
import ScrollableTabs from './ScrollableTabs';
|
|
10
13
|
import {
|
|
11
14
|
ContentWrapper,
|
|
12
|
-
|
|
15
|
+
HeaderTab,
|
|
13
16
|
HeaderTabItem,
|
|
17
|
+
HeaderTabWrapper,
|
|
14
18
|
TabContainer,
|
|
15
19
|
TabScreen,
|
|
16
|
-
HeaderTab,
|
|
17
20
|
} from './StyledTabs';
|
|
18
|
-
import ActiveTabIndicator from './ActiveTabIndicator';
|
|
19
|
-
import ScrollableTabs from './ScrollableTabs';
|
|
20
|
-
import TabWithBadge from './TabWithBadge';
|
|
21
21
|
import type { BadgeConfigType } from './TabWithBadge';
|
|
22
|
-
import
|
|
23
|
-
import { useDeprecation } from '../../utils/hooks';
|
|
22
|
+
import TabWithBadge from './TabWithBadge';
|
|
24
23
|
|
|
25
24
|
export type ItemType =
|
|
26
25
|
| string
|
|
@@ -33,7 +32,6 @@ export type TabType = {
|
|
|
33
32
|
inactiveItem?: ItemType;
|
|
34
33
|
component: ReactNode;
|
|
35
34
|
testID?: string;
|
|
36
|
-
showBadge?: boolean;
|
|
37
35
|
badge?: BadgeConfigType;
|
|
38
36
|
};
|
|
39
37
|
|
|
@@ -114,11 +112,6 @@ const Tabs = ({
|
|
|
114
112
|
swipeEnabled = true,
|
|
115
113
|
testID: componentTestID,
|
|
116
114
|
}: TabsProps): JSX.Element => {
|
|
117
|
-
useDeprecation(
|
|
118
|
-
"Tabs' showBadge will be removed in the next major release. Please use badge prop instead.",
|
|
119
|
-
tabs.some((item) => item.showBadge !== undefined)
|
|
120
|
-
);
|
|
121
|
-
|
|
122
115
|
const theme = useTheme();
|
|
123
116
|
const insets = useSafeAreaInsets();
|
|
124
117
|
const pagerViewRef = React.useRef<PagerView>(null);
|
|
@@ -157,7 +150,6 @@ const Tabs = ({
|
|
|
157
150
|
testID,
|
|
158
151
|
activeItem,
|
|
159
152
|
inactiveItem: originalInactiveItem,
|
|
160
|
-
showBadge,
|
|
161
153
|
badge,
|
|
162
154
|
} = tab;
|
|
163
155
|
|
|
@@ -178,11 +170,7 @@ const Tabs = ({
|
|
|
178
170
|
testID={testID}
|
|
179
171
|
>
|
|
180
172
|
<HeaderTabItem>
|
|
181
|
-
<TabWithBadge
|
|
182
|
-
showBadge={showBadge}
|
|
183
|
-
config={badge}
|
|
184
|
-
tabItem={tabItem}
|
|
185
|
-
/>
|
|
173
|
+
<TabWithBadge config={badge} tabItem={tabItem} />
|
|
186
174
|
</HeaderTabItem>
|
|
187
175
|
</TouchableWithoutFeedback>
|
|
188
176
|
);
|
|
@@ -40,15 +40,6 @@ describe('Tag', () => {
|
|
|
40
40
|
expect(getByText('INFO')).toBeDefined();
|
|
41
41
|
});
|
|
42
42
|
|
|
43
|
-
it('has default style when intent is default', () => {
|
|
44
|
-
const { getByText, toJSON } = renderWithTheme(
|
|
45
|
-
<Tag content="DEFAULT" intent="default" />
|
|
46
|
-
);
|
|
47
|
-
|
|
48
|
-
expect(toJSON()).toMatchSnapshot();
|
|
49
|
-
expect(getByText('DEFAULT')).toBeDefined();
|
|
50
|
-
});
|
|
51
|
-
|
|
52
43
|
it('has archived style when intent is archived', () => {
|
|
53
44
|
const { getByText, toJSON } = renderWithTheme(
|
|
54
45
|
<Tag content="ARCHIVED" intent="archived" />
|
|
@@ -120,46 +120,6 @@ exports[`Tag has danger style when intent is danger 1`] = `
|
|
|
120
120
|
</View>
|
|
121
121
|
`;
|
|
122
122
|
|
|
123
|
-
exports[`Tag has default style when intent is default 1`] = `
|
|
124
|
-
<View
|
|
125
|
-
style={
|
|
126
|
-
Array [
|
|
127
|
-
Object {
|
|
128
|
-
"backgroundColor": undefined,
|
|
129
|
-
"borderColor": "#001f23",
|
|
130
|
-
"borderRadius": 4,
|
|
131
|
-
"borderWidth": 1,
|
|
132
|
-
"paddingHorizontal": 8,
|
|
133
|
-
"paddingVertical": 2,
|
|
134
|
-
},
|
|
135
|
-
undefined,
|
|
136
|
-
]
|
|
137
|
-
}
|
|
138
|
-
themeIntent="default"
|
|
139
|
-
themeVariant="outlined"
|
|
140
|
-
>
|
|
141
|
-
<Text
|
|
142
|
-
style={
|
|
143
|
-
Array [
|
|
144
|
-
Object {
|
|
145
|
-
"color": "#001f23",
|
|
146
|
-
"fontFamily": "BeVietnamPro-SemiBold",
|
|
147
|
-
"fontSize": 12,
|
|
148
|
-
"includeFontPadding": false,
|
|
149
|
-
"textAlign": "center",
|
|
150
|
-
"textAlignVertical": "center",
|
|
151
|
-
},
|
|
152
|
-
undefined,
|
|
153
|
-
]
|
|
154
|
-
}
|
|
155
|
-
themeIntent="default"
|
|
156
|
-
themeVariant="outlined"
|
|
157
|
-
>
|
|
158
|
-
DEFAULT
|
|
159
|
-
</Text>
|
|
160
|
-
</View>
|
|
161
|
-
`;
|
|
162
|
-
|
|
163
123
|
exports[`Tag has info style when intent is info 1`] = `
|
|
164
124
|
<View
|
|
165
125
|
style={
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import React, { ReactElement } from 'react';
|
|
2
|
-
import type { StyleProp,
|
|
3
|
-
import {
|
|
4
|
-
import { StyledView, StyledText } from './StyledTag';
|
|
2
|
+
import type { StyleProp, ViewProps, ViewStyle } from 'react-native';
|
|
3
|
+
import { StyledText, StyledView } from './StyledTag';
|
|
5
4
|
|
|
6
5
|
interface TagProps extends ViewProps {
|
|
7
6
|
/**
|
|
@@ -11,14 +10,7 @@ interface TagProps extends ViewProps {
|
|
|
11
10
|
/**
|
|
12
11
|
* Visual intent color to apply to Tag.
|
|
13
12
|
*/
|
|
14
|
-
intent?:
|
|
15
|
-
| 'primary'
|
|
16
|
-
| 'default' // Will be deprecated in the future
|
|
17
|
-
| 'info'
|
|
18
|
-
| 'success'
|
|
19
|
-
| 'warning'
|
|
20
|
-
| 'danger'
|
|
21
|
-
| 'archived';
|
|
13
|
+
intent?: 'primary' | 'info' | 'success' | 'warning' | 'danger' | 'archived';
|
|
22
14
|
/**
|
|
23
15
|
* Tag variant.
|
|
24
16
|
*/
|
|
@@ -41,11 +33,6 @@ const Tag = ({
|
|
|
41
33
|
testID,
|
|
42
34
|
...nativeProps
|
|
43
35
|
}: TagProps): JSX.Element => {
|
|
44
|
-
useDeprecation(
|
|
45
|
-
"Tag's default intent is deprecated and will be removed in the next major release.\nPlease use primary intent instead.",
|
|
46
|
-
intent !== 'default'
|
|
47
|
-
);
|
|
48
|
-
|
|
49
36
|
return (
|
|
50
37
|
<StyledView
|
|
51
38
|
{...nativeProps}
|