@hero-design/rn 7.22.2 → 7.23.0
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/.turbo/turbo-build.log +3 -3
- package/es/index.js +2395 -1880
- package/lib/index.js +2395 -1878
- package/package.json +6 -6
- package/src/components/Accordion/AccordionItem.tsx +1 -1
- package/src/components/Accordion/__tests__/__snapshots__/AccordionItem.spec.tsx.snap +8 -8
- package/src/components/Accordion/__tests__/__snapshots__/index.spec.tsx.snap +12 -12
- package/src/components/Avatar/__tests__/__snapshots__/StyledAvatar.spec.tsx.snap +3 -3
- package/src/components/Avatar/__tests__/__snapshots__/index.spec.tsx.snap +2 -2
- package/src/components/BottomNavigation/__tests__/__snapshots__/index.spec.tsx.snap +2 -2
- package/src/components/Box/StyledBox.tsx +1 -2
- package/src/components/Button/LoadingIndicator/__tests__/__snapshots__/StyledLoadingIndicator.spec.tsx.snap +2 -2
- package/src/components/Button/LoadingIndicator/__tests__/__snapshots__/index.spec.tsx.snap +6 -6
- package/src/components/Button/__tests__/__snapshots__/StyledButton.spec.tsx.snap +24 -24
- package/src/components/Calendar/__tests__/__snapshots__/CalendarRowItem.spec.tsx.snap +6 -6
- package/src/components/Card/DataCard/__tests__/__snapshots__/StyledDataCard.spec.tsx.snap +3 -3
- package/src/components/Card/DataCard/__tests__/__snapshots__/index.spec.tsx.snap +2 -2
- package/src/components/Card/__tests__/__snapshots__/StyledCard.spec.tsx.snap +1 -1
- package/src/components/Card/__tests__/__snapshots__/index.spec.tsx.snap +1 -1
- package/src/components/Checkbox/__tests__/__snapshots__/StyledCheckbox.spec.tsx.snap +2 -2
- package/src/components/Checkbox/__tests__/__snapshots__/index.spec.tsx.snap +5 -5
- package/src/components/ContentNavigator/__tests__/__snapshots__/index.spec.tsx.snap +2 -2
- package/src/components/DatePicker/__tests__/__snapshots__/DatePickerAndroid.spec.tsx.snap +18 -4
- package/src/components/DatePicker/__tests__/__snapshots__/DatePickerIOS.spec.tsx.snap +19 -5
- package/src/components/Drawer/__tests__/__snapshots__/index.spec.tsx.snap +3 -3
- package/src/components/FAB/ActionGroup/__tests__/__snapshots__/index.spec.tsx.snap +10 -10
- package/src/components/Icon/HeroIcon/index.tsx +2 -0
- package/src/components/Icon/__tests__/__snapshots__/index.spec.tsx.snap +1 -1
- package/src/components/Icon/index.tsx +1 -0
- package/src/components/List/__tests__/__snapshots__/BasicListItem.spec.tsx.snap +2 -2
- package/src/components/List/__tests__/__snapshots__/ListItem.spec.tsx.snap +12 -12
- package/src/components/List/__tests__/__snapshots__/StyledBasicListItem.spec.tsx.snap +2 -2
- package/src/components/List/__tests__/__snapshots__/StyledListItem.spec.tsx.snap +4 -4
- package/src/components/PinInput/__tests__/__snapshots__/PinCell.spec.tsx.snap +6 -6
- package/src/components/PinInput/__tests__/__snapshots__/index.spec.tsx.snap +21 -21
- package/src/components/Progress/__tests__/__snapshots__/index.spec.js.snap +5 -5
- package/src/components/Radio/__tests__/__snapshots__/Radio.spec.tsx.snap +1 -1
- package/src/components/Radio/__tests__/__snapshots__/RadioGroup.spec.tsx.snap +1 -1
- package/src/components/RefreshControl/__tests__/__snapshots__/index.spec.tsx.snap +69 -0
- package/src/components/RefreshControl/__tests__/index.spec.tsx +55 -0
- package/src/components/RefreshControl/index.tsx +23 -0
- package/src/components/RichTextEditor/MentionList.tsx +25 -4
- package/src/components/RichTextEditor/RichTextEditor.tsx +3 -1
- package/src/components/RichTextEditor/__tests__/EditorToolbar.spec.tsx +1 -1
- package/src/components/RichTextEditor/__tests__/MentionList.spec.tsx +6 -6
- package/src/components/RichTextEditor/__tests__/__snapshots__/RichTextEditor.spec.tsx.snap +38 -10
- package/src/components/SectionHeading/__tests__/__snapshots__/index.spec.tsx.snap +1 -1
- package/src/components/Select/MultiSelect/__tests__/__snapshots__/Option.spec.tsx.snap +1 -1
- package/src/components/Select/MultiSelect/__tests__/__snapshots__/OptionList.spec.tsx.snap +13 -9
- package/src/components/Select/MultiSelect/__tests__/__snapshots__/index.spec.tsx.snap +108 -38
- package/src/components/Select/MultiSelect/index.tsx +1 -1
- package/src/components/Select/SingleSelect/__tests__/__snapshots__/Option.spec.tsx.snap +1 -1
- package/src/components/Select/SingleSelect/__tests__/__snapshots__/OptionList.spec.tsx.snap +12 -8
- package/src/components/Select/SingleSelect/__tests__/__snapshots__/index.spec.tsx.snap +99 -29
- package/src/components/Select/SingleSelect/index.tsx +1 -1
- package/src/components/Select/__tests__/__snapshots__/StyledSelect.spec.tsx.snap +1 -1
- package/src/components/Select/types.ts +1 -3
- package/src/components/Slider/__tests__/__snapshots__/index.spec.tsx.snap +3 -3
- package/src/components/Spinner/StyledSpinner.tsx +8 -4
- package/src/components/Spinner/__tests__/__snapshots__/AnimatedSpinner.spec.tsx.snap +8 -4
- package/src/components/Spinner/__tests__/__snapshots__/StyledSpinner.spec.tsx.snap +32 -16
- package/src/components/Spinner/__tests__/__snapshots__/index.spec.tsx.snap +8 -4
- package/src/components/Switch/__tests__/__snapshots__/StyledSwitch.spec.tsx.snap +3 -3
- package/src/components/Tabs/ScrollableTabs.tsx +2 -5
- package/src/components/Tabs/__tests__/__snapshots__/ScrollableTabs.spec.tsx.snap +1 -1
- package/src/components/Tag/__tests__/__snapshots__/Tag.spec.tsx.snap +1 -1
- package/src/components/TextInput/StyledTextInput.tsx +16 -11
- package/src/components/TextInput/__tests__/StyledTextInput.spec.tsx +3 -3
- package/src/components/TextInput/__tests__/__snapshots__/StyledTextInput.spec.tsx.snap +46 -28
- package/src/components/TextInput/__tests__/__snapshots__/index.spec.tsx.snap +246 -64
- package/src/components/TextInput/index.tsx +21 -4
- package/src/components/TimePicker/__tests__/__snapshots__/TimePickerAndroid.spec.tsx.snap +18 -4
- package/src/components/TimePicker/__tests__/__snapshots__/TimePickerIOS.spec.tsx.snap +19 -5
- package/src/components/Toast/ToastProvider.tsx +2 -4
- package/src/components/Toast/__tests__/index.spec.tsx +138 -0
- package/src/components/Toolbar/ToolbarItem.tsx +1 -1
- package/src/components/Toolbar/__tests__/__snapshots__/ToolbarGroup.spec.tsx.snap +12 -12
- package/src/components/Toolbar/__tests__/__snapshots__/ToolbarItem.spec.tsx.snap +6 -6
- package/src/components/Typography/Text/StyledText.tsx +1 -0
- package/src/components/Typography/Text/__tests__/__snapshots__/StyledText.spec.tsx.snap +3 -3
- package/src/components/Typography/Text/index.tsx +1 -0
- package/src/index.ts +4 -0
- package/src/theme/ThemeSwitcher.tsx +9 -2
- package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +101 -88
- package/src/theme/components/accordion.ts +1 -1
- package/src/theme/components/alert.ts +4 -4
- package/src/theme/components/avatar.ts +2 -2
- package/src/theme/components/badge.ts +6 -6
- package/src/theme/components/bottomNavigation.ts +2 -2
- package/src/theme/components/bottomSheet.ts +3 -3
- package/src/theme/components/button.ts +20 -20
- package/src/theme/components/calendar.ts +4 -4
- package/src/theme/components/card.ts +5 -5
- package/src/theme/components/checkbox.ts +1 -1
- package/src/theme/components/divider.ts +1 -1
- package/src/theme/components/drawer.ts +4 -4
- package/src/theme/components/empty.ts +3 -4
- package/src/theme/components/fab.ts +7 -7
- package/src/theme/components/icon.ts +4 -3
- package/src/theme/components/list.ts +6 -7
- package/src/theme/components/pinInput.ts +4 -4
- package/src/theme/components/progress.ts +3 -3
- package/src/theme/components/refreshControl.ts +11 -0
- package/src/theme/components/richTextEditor.ts +9 -8
- package/src/theme/components/sectionHeading.ts +1 -1
- package/src/theme/components/select.ts +1 -1
- package/src/theme/components/slider.ts +3 -3
- package/src/theme/components/spinner.ts +1 -4
- package/src/theme/components/switch.ts +7 -7
- package/src/theme/components/tabs.ts +5 -5
- package/src/theme/components/tag.ts +12 -12
- package/src/theme/components/textInput.ts +38 -38
- package/src/theme/components/toast.ts +6 -6
- package/src/theme/components/toolbar.ts +3 -2
- package/src/theme/components/typography.ts +4 -3
- package/src/theme/getTheme.ts +3 -0
- package/src/theme/global/colors/global.ts +32 -0
- package/src/theme/global/colors/jobs.ts +18 -0
- package/src/theme/global/colors/legacySystemPalette.ts +53 -0
- package/src/theme/global/colors/swag.ts +21 -35
- package/src/theme/global/colors/types.ts +46 -27
- package/src/theme/global/colors/work.ts +10 -9
- package/src/theme/global/index.ts +8 -1
- package/src/theme/index.ts +6 -1
- package/src/utils/__tests__/helpers.spec.ts +27 -0
- package/src/utils/helpers.ts +21 -0
- package/tsconfig.prod.json +4 -0
- package/types/components/Icon/HeroIcon/index.d.ts +1 -1
- package/types/components/Icon/index.d.ts +1 -1
- package/types/components/RefreshControl/index.d.ts +5 -0
- package/types/components/RichTextEditor/MentionList.d.ts +7 -3
- package/types/components/RichTextEditor/index.d.ts +1 -1
- package/types/components/Select/types.d.ts +1 -3
- package/types/components/TextInput/StyledTextInput.d.ts +9 -3
- package/types/components/Toolbar/ToolbarItem.d.ts +1 -1
- package/types/components/Typography/Text/StyledText.d.ts +1 -1
- package/types/components/Typography/Text/index.d.ts +1 -1
- package/types/index.d.ts +3 -2
- package/types/theme/ThemeSwitcher.d.ts +1 -1
- package/types/theme/components/empty.d.ts +0 -1
- package/types/theme/components/icon.d.ts +1 -0
- package/types/theme/components/refreshControl.d.ts +7 -0
- package/types/theme/components/richTextEditor.d.ts +4 -3
- package/types/theme/components/spinner.d.ts +1 -4
- package/types/theme/components/toolbar.d.ts +1 -0
- package/types/theme/components/typography.d.ts +1 -0
- package/types/theme/getTheme.d.ts +2 -0
- package/types/theme/global/colors/global.d.ts +3 -0
- package/types/theme/global/colors/jobs.d.ts +3 -0
- package/types/theme/global/colors/legacySystemPalette.d.ts +3 -0
- package/types/theme/global/colors/types.d.ts +41 -21
- package/types/theme/global/index.d.ts +30 -21
- package/types/theme/index.d.ts +2 -2
- package/types/utils/helpers.d.ts +2 -0
- package/src/components/Box/__tests__/helpers.spec.ts +0 -14
- package/src/components/Box/helpers.ts +0 -10
- package/types/components/Accordion/__tests__/AccordionItem.spec.d.ts +0 -1
- package/types/components/Accordion/__tests__/StyledAccordion.spec.d.ts +0 -1
- package/types/components/Accordion/__tests__/index.spec.d.ts +0 -1
- package/types/components/Alert/__tests__/index.spec.d.ts +0 -1
- package/types/components/Avatar/__tests__/StyledAvatar.spec.d.ts +0 -1
- package/types/components/Avatar/__tests__/index.spec.d.ts +0 -1
- package/types/components/Badge/__tests__/Badge.spec.d.ts +0 -1
- package/types/components/Badge/__tests__/Status.spec.d.ts +0 -1
- package/types/components/BottomNavigation/__tests__/index.spec.d.ts +0 -1
- package/types/components/BottomSheet/__tests__/index.spec.d.ts +0 -1
- package/types/components/Box/__tests__/helpers.spec.d.ts +0 -1
- package/types/components/Box/__tests__/index.spec.d.ts +0 -1
- package/types/components/Box/helpers.d.ts +0 -1
- package/types/components/Button/LoadingIndicator/__tests__/StyledLoadingIndicator.spec.d.ts +0 -1
- package/types/components/Button/LoadingIndicator/__tests__/index.spec.d.ts +0 -1
- package/types/components/Button/UtilityButton/__tests__/index.spec.d.ts +0 -1
- package/types/components/Button/__tests__/Button.spec.d.ts +0 -1
- package/types/components/Button/__tests__/IconButton.spec.d.ts +0 -1
- package/types/components/Button/__tests__/StyledButton.spec.d.ts +0 -1
- package/types/components/Calendar/__tests__/CalendarRowItem.spec.d.ts +0 -1
- package/types/components/Calendar/__tests__/helper.spec.d.ts +0 -1
- package/types/components/Calendar/__tests__/index.spec.d.ts +0 -1
- package/types/components/Card/DataCard/__tests__/StyledDataCard.spec.d.ts +0 -1
- package/types/components/Card/DataCard/__tests__/index.spec.d.ts +0 -1
- package/types/components/Card/__tests__/StyledCard.spec.d.ts +0 -1
- package/types/components/Card/__tests__/index.spec.d.ts +0 -1
- package/types/components/Checkbox/__tests__/StyledCheckbox.spec.d.ts +0 -1
- package/types/components/Checkbox/__tests__/index.spec.d.ts +0 -1
- package/types/components/Collapse/__tests__/StyledCollapse.spec.d.ts +0 -1
- package/types/components/Collapse/__tests__/index.spec.d.ts +0 -1
- package/types/components/ContentNavigator/__tests__/StyledContentNavigator.spec.d.ts +0 -1
- package/types/components/ContentNavigator/__tests__/index.spec.d.ts +0 -1
- package/types/components/DatePicker/__tests__/DatePicker.spec.d.ts +0 -1
- package/types/components/DatePicker/__tests__/DatePickerAndroid.spec.d.ts +0 -1
- package/types/components/DatePicker/__tests__/DatePickerIOS.spec.d.ts +0 -1
- package/types/components/Divider/__tests__/StyledDivider.spec.d.ts +0 -1
- package/types/components/Drawer/DragableDrawer/__tests__/helpers.spec.d.ts +0 -1
- package/types/components/Drawer/DragableDrawer/__tests__/index.spec.d.ts +0 -1
- package/types/components/Drawer/__tests__/index.spec.d.ts +0 -1
- package/types/components/Empty/__tests__/index.spec.d.ts +0 -1
- package/types/components/FAB/ActionGroup/__tests__/index.spec.d.ts +0 -1
- package/types/components/FAB/__tests__/AnimatedFABIcon.spec.d.ts +0 -1
- package/types/components/FAB/__tests__/StyledFAB.spec.d.ts +0 -1
- package/types/components/FAB/__tests__/index.spec.d.ts +0 -1
- package/types/components/Icon/__tests__/index.spec.d.ts +0 -1
- package/types/components/Image/__tests__/index.spec.d.ts +0 -1
- package/types/components/List/__tests__/BasicListItem.spec.d.ts +0 -1
- package/types/components/List/__tests__/ListItem.spec.d.ts +0 -1
- package/types/components/List/__tests__/StyledBasicListItem.spec.d.ts +0 -1
- package/types/components/List/__tests__/StyledListItem.spec.d.ts +0 -1
- package/types/components/PinInput/__tests__/PinCell.spec.d.ts +0 -1
- package/types/components/PinInput/__tests__/StyledPinInput.spec.d.ts +0 -1
- package/types/components/PinInput/__tests__/index.spec.d.ts +0 -1
- package/types/components/Radio/__tests__/Radio.spec.d.ts +0 -1
- package/types/components/Radio/__tests__/RadioGroup.spec.d.ts +0 -1
- package/types/components/RichTextEditor/__tests__/EditorToolbar.spec.d.ts +0 -1
- package/types/components/RichTextEditor/__tests__/MentionList.spec.d.ts +0 -1
- package/types/components/RichTextEditor/__tests__/RichTextEditor.spec.d.ts +0 -1
- package/types/components/SectionHeading/__tests__/StyledHeading.spec.d.ts +0 -1
- package/types/components/SectionHeading/__tests__/index.spec.d.ts +0 -1
- package/types/components/Select/MultiSelect/__tests__/Option.spec.d.ts +0 -1
- package/types/components/Select/MultiSelect/__tests__/OptionList.spec.d.ts +0 -1
- package/types/components/Select/MultiSelect/__tests__/index.spec.d.ts +0 -1
- package/types/components/Select/SingleSelect/__tests__/Option.spec.d.ts +0 -1
- package/types/components/Select/SingleSelect/__tests__/OptionList.spec.d.ts +0 -1
- package/types/components/Select/SingleSelect/__tests__/index.spec.d.ts +0 -1
- package/types/components/Select/__tests__/StyledSelect.spec.d.ts +0 -1
- package/types/components/Select/__tests__/helpers.spec.d.ts +0 -1
- package/types/components/Slider/__tests__/index.spec.d.ts +0 -1
- package/types/components/Spinner/__tests__/AnimatedSpinner.spec.d.ts +0 -1
- package/types/components/Spinner/__tests__/StyledSpinner.spec.d.ts +0 -1
- package/types/components/Spinner/__tests__/index.spec.d.ts +0 -1
- package/types/components/Switch/SelectorSwitch/__tests__/Option.spec.d.ts +0 -1
- package/types/components/Switch/SelectorSwitch/__tests__/index.spec.d.ts +0 -1
- package/types/components/Switch/__tests__/StyledSwitch.spec.d.ts +0 -1
- package/types/components/Switch/__tests__/index.spec.d.ts +0 -1
- package/types/components/Tabs/__tests__/ScrollableTabs.spec.d.ts +0 -1
- package/types/components/Tabs/__tests__/TabWithBadge.spec.d.ts +0 -1
- package/types/components/Tabs/__tests__/index.spec.d.ts +0 -1
- package/types/components/Tag/__tests__/Tag.spec.d.ts +0 -1
- package/types/components/TextInput/__tests__/StyledTextInput.spec.d.ts +0 -1
- package/types/components/TextInput/__tests__/index.spec.d.ts +0 -1
- package/types/components/TimePicker/__tests__/TimePicker.spec.d.ts +0 -1
- package/types/components/TimePicker/__tests__/TimePickerAndroid.spec.d.ts +0 -1
- package/types/components/TimePicker/__tests__/TimePickerIOS.spec.d.ts +0 -1
- package/types/components/Toast/__tests__/Toast.spec.d.ts +0 -1
- package/types/components/Toast/__tests__/ToastContainer.spec.d.ts +0 -1
- package/types/components/Toolbar/__tests__/ToolbarGroup.spec.d.ts +0 -1
- package/types/components/Toolbar/__tests__/ToolbarItem.spec.d.ts +0 -1
- package/types/components/Typography/Text/__tests__/StyledText.spec.d.ts +0 -1
- package/types/components/Typography/Text/__tests__/index.spec.d.ts +0 -1
- package/types/theme/__tests__/index.spec.d.ts +0 -1
- package/types/utils/__tests__/scale.spec.d.ts +0 -1
|
@@ -21,7 +21,7 @@ exports[`StyledWrapper renders correct style with variant checked 1`] = `
|
|
|
21
21
|
style={
|
|
22
22
|
Array [
|
|
23
23
|
Object {
|
|
24
|
-
"backgroundColor": "#
|
|
24
|
+
"backgroundColor": "#401960",
|
|
25
25
|
"borderRadius": 999,
|
|
26
26
|
"display": "flex",
|
|
27
27
|
"height": 32,
|
|
@@ -42,7 +42,7 @@ exports[`StyledWrapper renders correct style with variant disabled-checked 1`] =
|
|
|
42
42
|
style={
|
|
43
43
|
Array [
|
|
44
44
|
Object {
|
|
45
|
-
"backgroundColor": "#
|
|
45
|
+
"backgroundColor": "#a08cb0",
|
|
46
46
|
"borderRadius": 999,
|
|
47
47
|
"display": "flex",
|
|
48
48
|
"height": 32,
|
|
@@ -63,7 +63,7 @@ exports[`StyledWrapper renders correct style with variant disabled-unchecked 1`]
|
|
|
63
63
|
style={
|
|
64
64
|
Array [
|
|
65
65
|
Object {
|
|
66
|
-
"backgroundColor": "#
|
|
66
|
+
"backgroundColor": "#bfc1c5",
|
|
67
67
|
"borderRadius": 999,
|
|
68
68
|
"display": "flex",
|
|
69
69
|
"height": 32,
|
|
@@ -101,12 +101,9 @@ const ScrollableTab = ({
|
|
|
101
101
|
|
|
102
102
|
return (
|
|
103
103
|
<TabContainer style={containerStyle} testID={componentTestID}>
|
|
104
|
-
<HeaderTabWrapper
|
|
105
|
-
themeInsets={insets}
|
|
106
|
-
style={barStyle}
|
|
107
|
-
testID={componentTestID ? `${componentTestID}-tab-bar` : undefined}
|
|
108
|
-
>
|
|
104
|
+
<HeaderTabWrapper themeInsets={insets} style={barStyle}>
|
|
109
105
|
<FlatList<TabType>
|
|
106
|
+
testID={componentTestID ? `${componentTestID}-tab-bar` : undefined}
|
|
110
107
|
ref={flatListRef}
|
|
111
108
|
horizontal
|
|
112
109
|
data={tabs}
|
|
@@ -10,19 +10,9 @@ export type Variant =
|
|
|
10
10
|
| 'readonly'
|
|
11
11
|
| 'error';
|
|
12
12
|
|
|
13
|
-
const StyledContainer = styled(View)
|
|
14
|
-
themeVariant: Variant;
|
|
15
|
-
}>(({ theme, themeVariant }) => ({
|
|
13
|
+
const StyledContainer = styled(View)(({ theme }) => ({
|
|
16
14
|
width: '100%',
|
|
17
15
|
marginVertical: theme.__hd__.textInput.space.containerMarginVertical,
|
|
18
|
-
borderWidth:
|
|
19
|
-
themeVariant === 'focused'
|
|
20
|
-
? theme.__hd__.textInput.borderWidths.container.focused
|
|
21
|
-
: theme.__hd__.textInput.borderWidths.container.normal,
|
|
22
|
-
borderRadius: theme.__hd__.textInput.radii.container,
|
|
23
|
-
borderColor:
|
|
24
|
-
theme.__hd__.textInput.colors.borders[themeVariant] ??
|
|
25
|
-
theme.__hd__.textInput.colors.borders.default,
|
|
26
16
|
}));
|
|
27
17
|
|
|
28
18
|
const StyledLabelContainer = styled(View)(({ theme }) => ({
|
|
@@ -107,6 +97,20 @@ const StyledTextInput = styled(TextInput)(({ theme }) => ({
|
|
|
107
97
|
marginHorizontal: theme.__hd__.textInput.space.inputHorizontalMargin,
|
|
108
98
|
}));
|
|
109
99
|
|
|
100
|
+
const StyledBorderBackDrop = styled(View)<{
|
|
101
|
+
themeVariant: Variant;
|
|
102
|
+
}>(({ theme, themeVariant }) => ({
|
|
103
|
+
...StyleSheet.absoluteFillObject,
|
|
104
|
+
borderWidth:
|
|
105
|
+
themeVariant === 'focused'
|
|
106
|
+
? theme.__hd__.textInput.borderWidths.container.focused
|
|
107
|
+
: theme.__hd__.textInput.borderWidths.container.normal,
|
|
108
|
+
borderRadius: theme.__hd__.textInput.radii.container,
|
|
109
|
+
borderColor:
|
|
110
|
+
theme.__hd__.textInput.colors.borders[themeVariant] ??
|
|
111
|
+
theme.__hd__.textInput.colors.borders.default,
|
|
112
|
+
}));
|
|
113
|
+
|
|
110
114
|
const StyledTextInputContainer = styled(View)(({ theme }) => ({
|
|
111
115
|
flexDirection: 'row',
|
|
112
116
|
alignItems: 'center',
|
|
@@ -147,5 +151,6 @@ export {
|
|
|
147
151
|
StyledTextInputAndLabelContainer,
|
|
148
152
|
StyledLabelContainerInsideTextInput,
|
|
149
153
|
StyledErrorAndHelpTextContainer,
|
|
154
|
+
StyledBorderBackDrop,
|
|
150
155
|
StyledErrorAndMaxLengthContainer,
|
|
151
156
|
};
|
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
StyledAsteriskLabel,
|
|
11
11
|
StyledLabelContainer,
|
|
12
12
|
StyledLabelInsideTextInput,
|
|
13
|
-
|
|
13
|
+
StyledBorderBackDrop,
|
|
14
14
|
} from '../StyledTextInput';
|
|
15
15
|
|
|
16
16
|
describe('Label', () => {
|
|
@@ -133,7 +133,7 @@ describe('StyledHelperText', () => {
|
|
|
133
133
|
});
|
|
134
134
|
});
|
|
135
135
|
|
|
136
|
-
describe('
|
|
136
|
+
describe('StyledBorderBackDrop', () => {
|
|
137
137
|
it.each`
|
|
138
138
|
themeVariant
|
|
139
139
|
${'default'}
|
|
@@ -146,7 +146,7 @@ describe('StyledContainer', () => {
|
|
|
146
146
|
'renders correctly with themeVariant $themeVariant',
|
|
147
147
|
({ themeVariant }): void => {
|
|
148
148
|
const { toJSON } = renderWithTheme(
|
|
149
|
-
<
|
|
149
|
+
<StyledBorderBackDrop themeVariant={themeVariant} />
|
|
150
150
|
);
|
|
151
151
|
|
|
152
152
|
expect(toJSON()).toMatchSnapshot();
|
|
@@ -153,7 +153,7 @@ exports[`Label renders correctly with themeVariant readonly 1`] = `
|
|
|
153
153
|
},
|
|
154
154
|
Array [
|
|
155
155
|
Object {
|
|
156
|
-
"color": "#
|
|
156
|
+
"color": "#bfc1c5",
|
|
157
157
|
},
|
|
158
158
|
undefined,
|
|
159
159
|
],
|
|
@@ -362,7 +362,7 @@ exports[`LabelInsideTextInput renders correctly with themeVariant readonly 1`] =
|
|
|
362
362
|
Object {
|
|
363
363
|
"alignContent": "center",
|
|
364
364
|
"alignItems": "center",
|
|
365
|
-
"color": "#
|
|
365
|
+
"color": "#bfc1c5",
|
|
366
366
|
"fontSize": 14,
|
|
367
367
|
"textAlignVertical": "center",
|
|
368
368
|
},
|
|
@@ -392,7 +392,7 @@ exports[`StyledAsteriskLabel renders correctly with themeVariant default 1`] = `
|
|
|
392
392
|
},
|
|
393
393
|
Array [
|
|
394
394
|
Object {
|
|
395
|
-
"color": "#
|
|
395
|
+
"color": "#f46363",
|
|
396
396
|
},
|
|
397
397
|
undefined,
|
|
398
398
|
],
|
|
@@ -448,7 +448,7 @@ exports[`StyledAsteriskLabel renders correctly with themeVariant error 1`] = `
|
|
|
448
448
|
},
|
|
449
449
|
Array [
|
|
450
450
|
Object {
|
|
451
|
-
"color": "#
|
|
451
|
+
"color": "#f46363",
|
|
452
452
|
},
|
|
453
453
|
undefined,
|
|
454
454
|
],
|
|
@@ -476,7 +476,7 @@ exports[`StyledAsteriskLabel renders correctly with themeVariant filled 1`] = `
|
|
|
476
476
|
},
|
|
477
477
|
Array [
|
|
478
478
|
Object {
|
|
479
|
-
"color": "#
|
|
479
|
+
"color": "#f46363",
|
|
480
480
|
},
|
|
481
481
|
undefined,
|
|
482
482
|
],
|
|
@@ -504,7 +504,7 @@ exports[`StyledAsteriskLabel renders correctly with themeVariant focused 1`] = `
|
|
|
504
504
|
},
|
|
505
505
|
Array [
|
|
506
506
|
Object {
|
|
507
|
-
"color": "#
|
|
507
|
+
"color": "#f46363",
|
|
508
508
|
},
|
|
509
509
|
undefined,
|
|
510
510
|
],
|
|
@@ -547,7 +547,7 @@ exports[`StyledAsteriskLabel renders correctly with themeVariant readonly 1`] =
|
|
|
547
547
|
</Text>
|
|
548
548
|
`;
|
|
549
549
|
|
|
550
|
-
exports[`
|
|
550
|
+
exports[`StyledBorderBackDrop renders correctly with themeVariant default 1`] = `
|
|
551
551
|
<View
|
|
552
552
|
style={
|
|
553
553
|
Array [
|
|
@@ -555,8 +555,11 @@ exports[`StyledContainer renders correctly with themeVariant default 1`] = `
|
|
|
555
555
|
"borderColor": "#001f23",
|
|
556
556
|
"borderRadius": 8,
|
|
557
557
|
"borderWidth": 1,
|
|
558
|
-
"
|
|
559
|
-
"
|
|
558
|
+
"bottom": 0,
|
|
559
|
+
"left": 0,
|
|
560
|
+
"position": "absolute",
|
|
561
|
+
"right": 0,
|
|
562
|
+
"top": 0,
|
|
560
563
|
},
|
|
561
564
|
undefined,
|
|
562
565
|
]
|
|
@@ -565,7 +568,7 @@ exports[`StyledContainer renders correctly with themeVariant default 1`] = `
|
|
|
565
568
|
/>
|
|
566
569
|
`;
|
|
567
570
|
|
|
568
|
-
exports[`
|
|
571
|
+
exports[`StyledBorderBackDrop renders correctly with themeVariant disabled 1`] = `
|
|
569
572
|
<View
|
|
570
573
|
style={
|
|
571
574
|
Array [
|
|
@@ -573,8 +576,11 @@ exports[`StyledContainer renders correctly with themeVariant disabled 1`] = `
|
|
|
573
576
|
"borderColor": "#bfc1c5",
|
|
574
577
|
"borderRadius": 8,
|
|
575
578
|
"borderWidth": 1,
|
|
576
|
-
"
|
|
577
|
-
"
|
|
579
|
+
"bottom": 0,
|
|
580
|
+
"left": 0,
|
|
581
|
+
"position": "absolute",
|
|
582
|
+
"right": 0,
|
|
583
|
+
"top": 0,
|
|
578
584
|
},
|
|
579
585
|
undefined,
|
|
580
586
|
]
|
|
@@ -583,16 +589,19 @@ exports[`StyledContainer renders correctly with themeVariant disabled 1`] = `
|
|
|
583
589
|
/>
|
|
584
590
|
`;
|
|
585
591
|
|
|
586
|
-
exports[`
|
|
592
|
+
exports[`StyledBorderBackDrop renders correctly with themeVariant error 1`] = `
|
|
587
593
|
<View
|
|
588
594
|
style={
|
|
589
595
|
Array [
|
|
590
596
|
Object {
|
|
591
|
-
"borderColor": "#
|
|
597
|
+
"borderColor": "#f46363",
|
|
592
598
|
"borderRadius": 8,
|
|
593
599
|
"borderWidth": 1,
|
|
594
|
-
"
|
|
595
|
-
"
|
|
600
|
+
"bottom": 0,
|
|
601
|
+
"left": 0,
|
|
602
|
+
"position": "absolute",
|
|
603
|
+
"right": 0,
|
|
604
|
+
"top": 0,
|
|
596
605
|
},
|
|
597
606
|
undefined,
|
|
598
607
|
]
|
|
@@ -601,7 +610,7 @@ exports[`StyledContainer renders correctly with themeVariant error 1`] = `
|
|
|
601
610
|
/>
|
|
602
611
|
`;
|
|
603
612
|
|
|
604
|
-
exports[`
|
|
613
|
+
exports[`StyledBorderBackDrop renders correctly with themeVariant filled 1`] = `
|
|
605
614
|
<View
|
|
606
615
|
style={
|
|
607
616
|
Array [
|
|
@@ -609,8 +618,11 @@ exports[`StyledContainer renders correctly with themeVariant filled 1`] = `
|
|
|
609
618
|
"borderColor": "#001f23",
|
|
610
619
|
"borderRadius": 8,
|
|
611
620
|
"borderWidth": 1,
|
|
612
|
-
"
|
|
613
|
-
"
|
|
621
|
+
"bottom": 0,
|
|
622
|
+
"left": 0,
|
|
623
|
+
"position": "absolute",
|
|
624
|
+
"right": 0,
|
|
625
|
+
"top": 0,
|
|
614
626
|
},
|
|
615
627
|
undefined,
|
|
616
628
|
]
|
|
@@ -619,7 +631,7 @@ exports[`StyledContainer renders correctly with themeVariant filled 1`] = `
|
|
|
619
631
|
/>
|
|
620
632
|
`;
|
|
621
633
|
|
|
622
|
-
exports[`
|
|
634
|
+
exports[`StyledBorderBackDrop renders correctly with themeVariant focused 1`] = `
|
|
623
635
|
<View
|
|
624
636
|
style={
|
|
625
637
|
Array [
|
|
@@ -627,8 +639,11 @@ exports[`StyledContainer renders correctly with themeVariant focused 1`] = `
|
|
|
627
639
|
"borderColor": "#001f23",
|
|
628
640
|
"borderRadius": 8,
|
|
629
641
|
"borderWidth": 2,
|
|
630
|
-
"
|
|
631
|
-
"
|
|
642
|
+
"bottom": 0,
|
|
643
|
+
"left": 0,
|
|
644
|
+
"position": "absolute",
|
|
645
|
+
"right": 0,
|
|
646
|
+
"top": 0,
|
|
632
647
|
},
|
|
633
648
|
undefined,
|
|
634
649
|
]
|
|
@@ -637,7 +652,7 @@ exports[`StyledContainer renders correctly with themeVariant focused 1`] = `
|
|
|
637
652
|
/>
|
|
638
653
|
`;
|
|
639
654
|
|
|
640
|
-
exports[`
|
|
655
|
+
exports[`StyledBorderBackDrop renders correctly with themeVariant readonly 1`] = `
|
|
641
656
|
<View
|
|
642
657
|
style={
|
|
643
658
|
Array [
|
|
@@ -645,8 +660,11 @@ exports[`StyledContainer renders correctly with themeVariant readonly 1`] = `
|
|
|
645
660
|
"borderColor": "#808f91",
|
|
646
661
|
"borderRadius": 8,
|
|
647
662
|
"borderWidth": 1,
|
|
648
|
-
"
|
|
649
|
-
"
|
|
663
|
+
"bottom": 0,
|
|
664
|
+
"left": 0,
|
|
665
|
+
"position": "absolute",
|
|
666
|
+
"right": 0,
|
|
667
|
+
"top": 0,
|
|
650
668
|
},
|
|
651
669
|
undefined,
|
|
652
670
|
]
|
|
@@ -668,7 +686,7 @@ exports[`StyledErrorMessage renders correctly 1`] = `
|
|
|
668
686
|
},
|
|
669
687
|
Array [
|
|
670
688
|
Object {
|
|
671
|
-
"color": "#
|
|
689
|
+
"color": "#f46363",
|
|
672
690
|
"fontSize": 12,
|
|
673
691
|
"marginLeft": 4,
|
|
674
692
|
},
|
|
@@ -816,7 +834,7 @@ exports[`StyledMaxLengthMessage renders correctly with themeVariant error 1`] =
|
|
|
816
834
|
Array [
|
|
817
835
|
Object {
|
|
818
836
|
"alignSelf": "flex-end",
|
|
819
|
-
"color": "#
|
|
837
|
+
"color": "#f46363",
|
|
820
838
|
"flex": 1,
|
|
821
839
|
"flexGrow": 1,
|
|
822
840
|
"fontSize": 12,
|
|
@@ -918,7 +936,7 @@ exports[`StyledMaxLengthMessage renders correctly with themeVariant readonly 1`]
|
|
|
918
936
|
Array [
|
|
919
937
|
Object {
|
|
920
938
|
"alignSelf": "flex-end",
|
|
921
|
-
"color": "#
|
|
939
|
+
"color": "#bfc1c5",
|
|
922
940
|
"flex": 1,
|
|
923
941
|
"flexGrow": 1,
|
|
924
942
|
"fontSize": 12,
|