@hero-design/rn 8.70.0 → 8.72.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/CHANGELOG.md +29 -0
- package/es/index.js +402 -219
- package/lib/index.js +402 -219
- package/package.json +1 -1
- 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/Badge/StyledBadge.tsx +17 -2
- package/src/components/Badge/__tests__/Badge.spec.tsx +15 -0
- package/src/components/Badge/__tests__/__snapshots__/Badge.spec.tsx.snap +187 -0
- package/src/components/Badge/index.tsx +20 -36
- package/src/components/Badge/types.ts +55 -0
- package/src/components/Button/LoadingIndicator/__tests__/__snapshots__/StyledLoadingIndicator.spec.tsx.snap +3 -3
- package/src/components/Button/LoadingIndicator/__tests__/__snapshots__/index.spec.tsx.snap +9 -9
- package/src/components/Button/__tests__/__snapshots__/Button.spec.tsx.snap +7 -7
- package/src/components/Button/__tests__/__snapshots__/StyledButton.spec.tsx.snap +6 -6
- package/src/components/Chip/StyledChip.tsx +44 -8
- package/src/components/Chip/__tests__/__snapshots__/index.spec.tsx.snap +212 -2
- package/src/components/Chip/__tests__/index.spec.tsx +2 -0
- package/src/components/Chip/index.tsx +1 -1
- package/src/components/FAB/FAB.tsx +6 -1
- package/src/components/FAB/Pair/StyledFAB.tsx +19 -0
- package/src/components/FAB/Pair/__tests__/__snapshots__/index.spec.tsx.snap +276 -0
- package/src/components/FAB/Pair/__tests__/index.spec.tsx +39 -0
- package/src/components/FAB/Pair/index.tsx +46 -0
- package/src/components/FAB/__tests__/__snapshots__/index.spec.tsx.snap +31 -14
- package/src/components/FAB/index.tsx +3 -1
- package/src/components/Progress/ProgressStep.tsx +3 -1
- package/src/components/Progress/StyledStep.tsx +13 -11
- package/src/components/Progress/__tests__/__snapshots__/index.spec.js.snap +215 -4
- package/src/components/Progress/__tests__/index.spec.js +16 -4
- package/src/components/Search/SearchOneLine.tsx +7 -1
- package/src/components/Search/SearchSuffixIcon.tsx +12 -1
- package/src/components/Search/SearchTwoLine.tsx +7 -1
- package/src/components/Search/StyledSearch.tsx +42 -16
- package/src/components/Search/__tests__/SearchOneLine.spec.tsx +30 -0
- package/src/components/Search/__tests__/SearchTwoLine.spec.tsx +15 -0
- package/src/components/Search/__tests__/__snapshots__/SearchOneLine.spec.tsx.snap +166 -10
- package/src/components/Search/__tests__/__snapshots__/SearchSuffixIcon.spec.tsx.snap +3 -0
- package/src/components/Search/__tests__/__snapshots__/SearchTwoLine.spec.tsx.snap +182 -2
- package/src/components/Switch/__tests__/__snapshots__/StyledSwitch.spec.tsx.snap +1 -1
- package/src/components/Tabs/__tests__/__snapshots__/ScrollableTabs.spec.tsx.snap +9 -0
- package/src/components/Tabs/__tests__/__snapshots__/ScrollableTabsHeader.spec.tsx.snap +6 -0
- package/src/components/Tabs/__tests__/__snapshots__/TabWithBadge.spec.tsx.snap +3 -0
- package/src/components/Tabs/__tests__/__snapshots__/index.spec.tsx.snap +9 -0
- package/src/components/Toolbar/StyledToolbar.tsx +11 -0
- package/src/components/Toolbar/ToolbarItem.tsx +3 -3
- package/src/components/Toolbar/__tests__/__snapshots__/ToolbarItem.spec.tsx.snap +24 -4
- package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +50 -9
- package/src/theme/components/badge.ts +10 -1
- package/src/theme/components/button.ts +2 -2
- package/src/theme/components/chip.ts +4 -0
- package/src/theme/components/fab.ts +3 -0
- package/src/theme/components/search.ts +30 -5
- package/src/theme/components/switch.ts +2 -2
- package/src/theme/components/toolbar.ts +1 -1
- package/stats/8.71.0/rn-stats.html +4842 -0
- package/stats/8.72.0/rn-stats.html +4844 -0
- package/types/components/Badge/StyledBadge.d.ts +9 -1
- package/types/components/Badge/index.d.ts +3 -34
- package/types/components/Badge/types.d.ts +53 -0
- package/types/components/Chip/StyledChip.d.ts +1 -1
- package/types/components/Chip/index.d.ts +1 -1
- package/types/components/FAB/Pair/StyledFAB.d.ts +12 -0
- package/types/components/FAB/Pair/index.d.ts +16 -0
- package/types/components/FAB/index.d.ts +1 -0
- package/types/components/Progress/StyledStep.d.ts +2 -0
- package/types/components/Search/SearchOneLine.d.ts +5 -0
- package/types/components/Search/SearchTwoLine.d.ts +5 -0
- package/types/components/Search/StyledSearch.d.ts +7 -2
- package/types/components/Toolbar/StyledToolbar.d.ts +9 -2
- package/types/theme/components/badge.d.ts +8 -0
- package/types/theme/components/chip.d.ts +4 -0
- package/types/theme/components/fab.d.ts +3 -0
- package/types/theme/components/search.d.ts +31 -5
package/es/index.js
CHANGED
|
@@ -2307,7 +2307,8 @@ var getBadgeTheme = function getBadgeTheme(theme) {
|
|
|
2307
2307
|
success: theme.colors.onSuccessSurface,
|
|
2308
2308
|
warning: theme.colors.onWarningSurface,
|
|
2309
2309
|
archived: theme.colors.onArchivedSurface,
|
|
2310
|
-
text: theme.colors.onDarkGlobalSurface
|
|
2310
|
+
text: theme.colors.onDarkGlobalSurface,
|
|
2311
|
+
border: theme.colors.defaultGlobalSurface
|
|
2311
2312
|
};
|
|
2312
2313
|
var fonts = {
|
|
2313
2314
|
medium: theme.fonts.neutral.regular,
|
|
@@ -2315,7 +2316,11 @@ var getBadgeTheme = function getBadgeTheme(theme) {
|
|
|
2315
2316
|
};
|
|
2316
2317
|
var fontSizes = {
|
|
2317
2318
|
medium: theme.fontSizes.small,
|
|
2318
|
-
small: 8
|
|
2319
|
+
small: 8,
|
|
2320
|
+
icon: {
|
|
2321
|
+
medium: theme.fontSizes.small,
|
|
2322
|
+
small: 8
|
|
2323
|
+
}
|
|
2319
2324
|
};
|
|
2320
2325
|
var lineHeights = {
|
|
2321
2326
|
medium: theme.lineHeights.small,
|
|
@@ -2333,6 +2338,9 @@ var getBadgeTheme = function getBadgeTheme(theme) {
|
|
|
2333
2338
|
statusHeight: theme.sizes.small,
|
|
2334
2339
|
statusWidth: theme.sizes.small
|
|
2335
2340
|
};
|
|
2341
|
+
var borderWidths = {
|
|
2342
|
+
"default": theme.borderWidths.medium
|
|
2343
|
+
};
|
|
2336
2344
|
var space = {
|
|
2337
2345
|
medium: {
|
|
2338
2346
|
horizontalPadding: theme.space.small
|
|
@@ -2349,7 +2357,8 @@ var getBadgeTheme = function getBadgeTheme(theme) {
|
|
|
2349
2357
|
fontSizes: fontSizes,
|
|
2350
2358
|
sizes: sizes,
|
|
2351
2359
|
space: space,
|
|
2352
|
-
lineHeights: lineHeights
|
|
2360
|
+
lineHeights: lineHeights,
|
|
2361
|
+
borderWidths: borderWidths
|
|
2353
2362
|
};
|
|
2354
2363
|
};
|
|
2355
2364
|
|
|
@@ -2454,7 +2463,7 @@ var getButtonTheme = function getButtonTheme(theme) {
|
|
|
2454
2463
|
};
|
|
2455
2464
|
var colors = {
|
|
2456
2465
|
primary: theme.colors.primary,
|
|
2457
|
-
secondary: theme.colors.
|
|
2466
|
+
secondary: theme.colors.mutedOnDefaultGlobalSurface,
|
|
2458
2467
|
danger: theme.colors.onErrorSurface,
|
|
2459
2468
|
defaultText: theme.colors.onDefaultGlobalSurface,
|
|
2460
2469
|
disabledText: theme.colors.disabledOnDefaultGlobalSurface,
|
|
@@ -2471,7 +2480,7 @@ var getButtonTheme = function getButtonTheme(theme) {
|
|
|
2471
2480
|
outlinedSecondary: theme.colors.highlightedSurface,
|
|
2472
2481
|
outlineDanger: theme.colors.errorSurface,
|
|
2473
2482
|
textPrimary: theme.colors.highlightedSurface,
|
|
2474
|
-
textSecondary: theme.colors.
|
|
2483
|
+
textSecondary: theme.colors.neutralGlobalSurface,
|
|
2475
2484
|
textDanger: theme.colors.errorSurface
|
|
2476
2485
|
}
|
|
2477
2486
|
};
|
|
@@ -2636,11 +2645,15 @@ var getChipTheme = function getChipTheme(theme) {
|
|
|
2636
2645
|
outlinedDefaultBackground: theme.colors.defaultGlobalSurface,
|
|
2637
2646
|
outlinedSelectedBackground: theme.colors.secondaryOutline,
|
|
2638
2647
|
outlinedSelectedBorder: theme.colors.primaryOutline,
|
|
2639
|
-
outlinedDefaultBorder: theme.colors.disabledOnDefaultGlobalSurface
|
|
2648
|
+
outlinedDefaultBorder: theme.colors.disabledOnDefaultGlobalSurface,
|
|
2649
|
+
compactDefaultBackground: theme.colors.defaultGlobalSurface,
|
|
2650
|
+
compactSelectedBackground: theme.colors.neutralGlobalSurface
|
|
2640
2651
|
};
|
|
2641
2652
|
var space = {
|
|
2642
2653
|
wrapperHorizontalPadding: theme.space.smallMedium,
|
|
2643
2654
|
wrapperVerticalPadding: theme.space.small,
|
|
2655
|
+
compactWrapperHorizontalPadding: theme.space.small,
|
|
2656
|
+
compactWrapperVerticalPadding: theme.space.xsmall,
|
|
2644
2657
|
iconWrapperHorizontalMargin: theme.space.small,
|
|
2645
2658
|
outlinedSelectedMarginTop: -theme.space.xxsmall
|
|
2646
2659
|
};
|
|
@@ -2834,7 +2847,9 @@ var getFABTheme = function getFABTheme(theme) {
|
|
|
2834
2847
|
width: theme.sizes.xxxxxlarge,
|
|
2835
2848
|
height: theme.sizes.xxxxxlarge,
|
|
2836
2849
|
iconContainerWidth: theme.sizes.large,
|
|
2837
|
-
iconContainerHeight: theme.sizes.large
|
|
2850
|
+
iconContainerHeight: theme.sizes.large,
|
|
2851
|
+
fabPairHeight: theme.sizes.xxxlarge,
|
|
2852
|
+
fabPairIconOnlyWidth: theme.sizes.xxxlarge
|
|
2838
2853
|
};
|
|
2839
2854
|
var fonts = {
|
|
2840
2855
|
actionItemText: theme.fonts.neutral.regular,
|
|
@@ -2864,7 +2879,8 @@ var getFABTheme = function getFABTheme(theme) {
|
|
|
2864
2879
|
buttonMarginTop: theme.space.large,
|
|
2865
2880
|
buttonMarginRight: theme.space.large,
|
|
2866
2881
|
containerPadding: theme.space.large - theme.space.xsmall,
|
|
2867
|
-
titleMarginHorizontal: theme.space.small
|
|
2882
|
+
titleMarginHorizontal: theme.space.small,
|
|
2883
|
+
fabPairMarginRight: theme.space.small
|
|
2868
2884
|
};
|
|
2869
2885
|
var radii = {
|
|
2870
2886
|
actionItem: theme.radii.rounded
|
|
@@ -3351,9 +3367,9 @@ var getSwitchTheme = function getSwitchTheme(theme) {
|
|
|
3351
3367
|
checked: theme.colors.primary,
|
|
3352
3368
|
unchecked: theme.colors.inactiveOnDefaultGlobalSurface,
|
|
3353
3369
|
'disabled-checked': theme.colors.highlightedSurface,
|
|
3354
|
-
'disabled-unchecked': theme.colors.
|
|
3370
|
+
'disabled-unchecked': theme.colors.mutedOnDefaultGlobalSurface
|
|
3355
3371
|
},
|
|
3356
|
-
thumb: theme.colors.
|
|
3372
|
+
thumb: theme.colors.onDarkGlobalSurface,
|
|
3357
3373
|
selector: {
|
|
3358
3374
|
background: theme.colors.defaultGlobalSurface,
|
|
3359
3375
|
textBackground: theme.colors.decorativePrimarySurface
|
|
@@ -3624,7 +3640,7 @@ var getToolbarTheme = function getToolbarTheme(theme) {
|
|
|
3624
3640
|
background: theme.colors.defaultGlobalSurface,
|
|
3625
3641
|
border: theme.colors.secondaryOutline,
|
|
3626
3642
|
primary: theme.colors.primary,
|
|
3627
|
-
secondary: theme.colors.
|
|
3643
|
+
secondary: theme.colors.mutedOnDefaultGlobalSurface,
|
|
3628
3644
|
info: theme.colors.info,
|
|
3629
3645
|
success: theme.colors.success,
|
|
3630
3646
|
danger: theme.colors.warning,
|
|
@@ -3828,15 +3844,32 @@ var getTypographyTheme = function getTypographyTheme(theme) {
|
|
|
3828
3844
|
|
|
3829
3845
|
var getSearchTheme = function getSearchTheme(theme) {
|
|
3830
3846
|
var colors = {
|
|
3831
|
-
|
|
3832
|
-
|
|
3847
|
+
basic: {
|
|
3848
|
+
containerBackground: theme.colors.neutralGlobalSurface,
|
|
3849
|
+
border: theme.colors.neutralGlobalSurface,
|
|
3850
|
+
focusedBorder: theme.colors.primaryOutline
|
|
3851
|
+
},
|
|
3852
|
+
reversed: {
|
|
3853
|
+
containerBackground: theme.colors.defaultGlobalSurface,
|
|
3854
|
+
border: theme.colors.secondaryOutline,
|
|
3855
|
+
focusedBorder: theme.colors.primaryOutline
|
|
3856
|
+
},
|
|
3857
|
+
suffixBackground: theme.colors.defaultGlobalSurface,
|
|
3833
3858
|
text: theme.colors.onDefaultGlobalSurface,
|
|
3834
|
-
|
|
3859
|
+
shadow: theme.colors.primaryOutline
|
|
3860
|
+
};
|
|
3861
|
+
var shadows = {
|
|
3862
|
+
offset: theme.shadows["default"].shadowOffset,
|
|
3863
|
+
opacity: theme.shadows["default"].shadowOpacity,
|
|
3864
|
+
radius: theme.shadows["default"].shadowRadius,
|
|
3865
|
+
elevation: theme.shadows["default"].elevation,
|
|
3866
|
+
color: theme.shadows["default"].shadowColor
|
|
3835
3867
|
};
|
|
3836
3868
|
var space = {
|
|
3837
3869
|
containerHorizontalPadding: theme.space.small,
|
|
3838
3870
|
containerVerticalPadding: theme.space.small,
|
|
3839
3871
|
inputHorizontalMargin: theme.space.small,
|
|
3872
|
+
inputVerticalPadding: theme.space.xxsmall,
|
|
3840
3873
|
prefixHorizontalPadding: theme.space.xsmall,
|
|
3841
3874
|
surfixPadding: theme.space.small,
|
|
3842
3875
|
badgeTop: -theme.space.xxsmall,
|
|
@@ -3850,8 +3883,14 @@ var getSearchTheme = function getSearchTheme(theme) {
|
|
|
3850
3883
|
};
|
|
3851
3884
|
var borderWidths = {
|
|
3852
3885
|
container: {
|
|
3853
|
-
|
|
3854
|
-
|
|
3886
|
+
basic: {
|
|
3887
|
+
normal: theme.borderWidths.medium,
|
|
3888
|
+
focused: theme.borderWidths.medium
|
|
3889
|
+
},
|
|
3890
|
+
reversed: {
|
|
3891
|
+
normal: theme.borderWidths.base,
|
|
3892
|
+
focused: theme.borderWidths.medium
|
|
3893
|
+
}
|
|
3855
3894
|
}
|
|
3856
3895
|
};
|
|
3857
3896
|
var radii = {
|
|
@@ -3868,7 +3907,8 @@ var getSearchTheme = function getSearchTheme(theme) {
|
|
|
3868
3907
|
fontSizes: fontSizes,
|
|
3869
3908
|
borderWidths: borderWidths,
|
|
3870
3909
|
radii: radii,
|
|
3871
|
-
sizes: sizes
|
|
3910
|
+
sizes: sizes,
|
|
3911
|
+
shadows: shadows
|
|
3872
3912
|
};
|
|
3873
3913
|
};
|
|
3874
3914
|
|
|
@@ -7001,7 +7041,7 @@ var StyledText$3 = index$9(Text$1)(function (_ref) {
|
|
|
7001
7041
|
});
|
|
7002
7042
|
});
|
|
7003
7043
|
|
|
7004
|
-
var _excluded$
|
|
7044
|
+
var _excluded$H = ["children", "fontSize", "fontWeight", "intent", "typeface", "allowFontScaling"];
|
|
7005
7045
|
var Text = function Text(_ref) {
|
|
7006
7046
|
var children = _ref.children,
|
|
7007
7047
|
_ref$fontSize = _ref.fontSize,
|
|
@@ -7014,7 +7054,7 @@ var Text = function Text(_ref) {
|
|
|
7014
7054
|
typeface = _ref$typeface === void 0 ? 'neutral' : _ref$typeface,
|
|
7015
7055
|
_ref$allowFontScaling = _ref.allowFontScaling,
|
|
7016
7056
|
allowFontScaling = _ref$allowFontScaling === void 0 ? false : _ref$allowFontScaling,
|
|
7017
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
7057
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$H);
|
|
7018
7058
|
useDeprecation('Typography.Text is deprecated and will be removed in the next major release, please refer to https://design.employmenthero.com/mobile/Components/typography for the appropriate alternatives.');
|
|
7019
7059
|
return /*#__PURE__*/React__default.createElement(StyledText$3, _extends$1({}, nativeProps, {
|
|
7020
7060
|
themeFontSize: fontSize,
|
|
@@ -7044,7 +7084,7 @@ var StyledCaption = index$9(Text$1)(function (_ref) {
|
|
|
7044
7084
|
};
|
|
7045
7085
|
});
|
|
7046
7086
|
|
|
7047
|
-
var _excluded$
|
|
7087
|
+
var _excluded$G = ["children", "fontWeight", "intent", "allowFontScaling"];
|
|
7048
7088
|
var Caption = function Caption(_ref) {
|
|
7049
7089
|
var children = _ref.children,
|
|
7050
7090
|
_ref$fontWeight = _ref.fontWeight,
|
|
@@ -7053,7 +7093,7 @@ var Caption = function Caption(_ref) {
|
|
|
7053
7093
|
intent = _ref$intent === void 0 ? 'body' : _ref$intent,
|
|
7054
7094
|
_ref$allowFontScaling = _ref.allowFontScaling,
|
|
7055
7095
|
allowFontScaling = _ref$allowFontScaling === void 0 ? false : _ref$allowFontScaling,
|
|
7056
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
7096
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$G);
|
|
7057
7097
|
return /*#__PURE__*/React__default.createElement(StyledCaption, _extends$1({}, nativeProps, {
|
|
7058
7098
|
themeFontWeight: fontWeight,
|
|
7059
7099
|
themeIntent: intent,
|
|
@@ -7061,7 +7101,7 @@ var Caption = function Caption(_ref) {
|
|
|
7061
7101
|
}), children);
|
|
7062
7102
|
};
|
|
7063
7103
|
|
|
7064
|
-
var StyledLabel = index$9(Text$1)(function (_ref) {
|
|
7104
|
+
var StyledLabel$1 = index$9(Text$1)(function (_ref) {
|
|
7065
7105
|
var themeIntent = _ref.themeIntent,
|
|
7066
7106
|
theme = _ref.theme;
|
|
7067
7107
|
return {
|
|
@@ -7072,15 +7112,15 @@ var StyledLabel = index$9(Text$1)(function (_ref) {
|
|
|
7072
7112
|
};
|
|
7073
7113
|
});
|
|
7074
7114
|
|
|
7075
|
-
var _excluded$
|
|
7115
|
+
var _excluded$F = ["children", "intent", "allowFontScaling"];
|
|
7076
7116
|
var Label = function Label(_ref) {
|
|
7077
7117
|
var children = _ref.children,
|
|
7078
7118
|
_ref$intent = _ref.intent,
|
|
7079
7119
|
intent = _ref$intent === void 0 ? 'body' : _ref$intent,
|
|
7080
7120
|
_ref$allowFontScaling = _ref.allowFontScaling,
|
|
7081
7121
|
allowFontScaling = _ref$allowFontScaling === void 0 ? false : _ref$allowFontScaling,
|
|
7082
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
7083
|
-
return /*#__PURE__*/React__default.createElement(StyledLabel, _extends$1({}, nativeProps, {
|
|
7122
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$F);
|
|
7123
|
+
return /*#__PURE__*/React__default.createElement(StyledLabel$1, _extends$1({}, nativeProps, {
|
|
7084
7124
|
themeIntent: intent,
|
|
7085
7125
|
allowFontScaling: allowFontScaling
|
|
7086
7126
|
}), children);
|
|
@@ -7100,7 +7140,7 @@ var StyledTitle$1 = index$9(Text$1)(function (_ref) {
|
|
|
7100
7140
|
};
|
|
7101
7141
|
});
|
|
7102
7142
|
|
|
7103
|
-
var _excluded$
|
|
7143
|
+
var _excluded$E = ["children", "intent", "allowFontScaling", "level", "typeface"];
|
|
7104
7144
|
var Title = function Title(_ref) {
|
|
7105
7145
|
var children = _ref.children,
|
|
7106
7146
|
_ref$intent = _ref.intent,
|
|
@@ -7111,7 +7151,7 @@ var Title = function Title(_ref) {
|
|
|
7111
7151
|
level = _ref$level === void 0 ? 'h1' : _ref$level,
|
|
7112
7152
|
_ref$typeface = _ref.typeface,
|
|
7113
7153
|
typeface = _ref$typeface === void 0 ? 'neutral' : _ref$typeface,
|
|
7114
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
7154
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$E);
|
|
7115
7155
|
return /*#__PURE__*/React__default.createElement(StyledTitle$1, _extends$1({}, nativeProps, {
|
|
7116
7156
|
themeLevel: level,
|
|
7117
7157
|
themeTypeface: typeface,
|
|
@@ -7146,7 +7186,7 @@ var StyledBody$1 = index$9(Text$1)(function (_ref) {
|
|
|
7146
7186
|
};
|
|
7147
7187
|
});
|
|
7148
7188
|
|
|
7149
|
-
var _excluded$
|
|
7189
|
+
var _excluded$D = ["children", "intent", "allowFontScaling", "typeface", "variant"];
|
|
7150
7190
|
var Body = function Body(_ref) {
|
|
7151
7191
|
var children = _ref.children,
|
|
7152
7192
|
_ref$intent = _ref.intent,
|
|
@@ -7157,7 +7197,7 @@ var Body = function Body(_ref) {
|
|
|
7157
7197
|
typeface = _ref$typeface === void 0 ? 'neutral' : _ref$typeface,
|
|
7158
7198
|
_ref$variant = _ref.variant,
|
|
7159
7199
|
variant = _ref$variant === void 0 ? 'regular' : _ref$variant,
|
|
7160
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
7200
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$D);
|
|
7161
7201
|
return /*#__PURE__*/React__default.createElement(StyledBody$1, _extends$1({}, nativeProps, {
|
|
7162
7202
|
themeTypeface: typeface,
|
|
7163
7203
|
themeIntent: intent,
|
|
@@ -7724,10 +7764,10 @@ var StyledHeroIcon = index$9(HeroIcon)(function (_ref) {
|
|
|
7724
7764
|
};
|
|
7725
7765
|
});
|
|
7726
7766
|
|
|
7727
|
-
var _excluded$
|
|
7767
|
+
var _excluded$C = ["style"];
|
|
7728
7768
|
var AnimatedIcon = function AnimatedIcon(_ref) {
|
|
7729
7769
|
var style = _ref.style,
|
|
7730
|
-
otherProps = _objectWithoutProperties(_ref, _excluded$
|
|
7770
|
+
otherProps = _objectWithoutProperties(_ref, _excluded$C);
|
|
7731
7771
|
var rotateAnimation = useRef(new Animated.Value(0));
|
|
7732
7772
|
useEffect(function () {
|
|
7733
7773
|
var animation = Animated.loop(Animated.timing(rotateAnimation.current, {
|
|
@@ -7825,14 +7865,14 @@ var AccordionItem = function AccordionItem(_ref) {
|
|
|
7825
7865
|
variant: "regular-bold"
|
|
7826
7866
|
}, header) : header, /*#__PURE__*/React__default.createElement(Icon, {
|
|
7827
7867
|
icon: open ? 'arrow-up' : 'arrow-down',
|
|
7828
|
-
intent: "
|
|
7868
|
+
intent: "primary",
|
|
7829
7869
|
size: "small"
|
|
7830
7870
|
})), /*#__PURE__*/React__default.createElement(StyledCollapse, {
|
|
7831
7871
|
open: open
|
|
7832
7872
|
}, content));
|
|
7833
7873
|
};
|
|
7834
7874
|
|
|
7835
|
-
var _excluded$
|
|
7875
|
+
var _excluded$B = ["key"];
|
|
7836
7876
|
var Accordion = function Accordion(_ref) {
|
|
7837
7877
|
var items = _ref.items,
|
|
7838
7878
|
activeItemKey = _ref.activeItemKey,
|
|
@@ -7853,7 +7893,7 @@ var Accordion = function Accordion(_ref) {
|
|
|
7853
7893
|
testID: testID
|
|
7854
7894
|
}, items.map(function (_ref2, index) {
|
|
7855
7895
|
var key = _ref2.key,
|
|
7856
|
-
props = _objectWithoutProperties(_ref2, _excluded$
|
|
7896
|
+
props = _objectWithoutProperties(_ref2, _excluded$B);
|
|
7857
7897
|
var open = _activeItemKey === key;
|
|
7858
7898
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, {
|
|
7859
7899
|
key: key
|
|
@@ -7888,7 +7928,7 @@ var IconContainer$1 = index$9(View)(function (_ref2) {
|
|
|
7888
7928
|
paddingLeft: theme.__hd__.alert.space.iconLeftPadding
|
|
7889
7929
|
};
|
|
7890
7930
|
});
|
|
7891
|
-
var StyledIcon$
|
|
7931
|
+
var StyledIcon$2 = index$9(Icon)(function (_ref3) {
|
|
7892
7932
|
var theme = _ref3.theme,
|
|
7893
7933
|
themeIntent = _ref3.themeIntent;
|
|
7894
7934
|
return {
|
|
@@ -7947,7 +7987,7 @@ var AlertIcon = function AlertIcon(_ref) {
|
|
|
7947
7987
|
intent = _ref.intent;
|
|
7948
7988
|
return icon ? /*#__PURE__*/React__default.createElement(IconContainer$1, {
|
|
7949
7989
|
testID: "alert-left-icon"
|
|
7950
|
-
}, /*#__PURE__*/React__default.createElement(StyledIcon$
|
|
7990
|
+
}, /*#__PURE__*/React__default.createElement(StyledIcon$2, {
|
|
7951
7991
|
icon: icon,
|
|
7952
7992
|
size: "small",
|
|
7953
7993
|
themeIntent: intent
|
|
@@ -7988,7 +8028,7 @@ var Alert = function Alert(_ref2) {
|
|
|
7988
8028
|
}, typeof actionLabel === 'string' ? /*#__PURE__*/React__default.createElement(StyledBody, {
|
|
7989
8029
|
variant: "small-bold",
|
|
7990
8030
|
themeIntent: intent
|
|
7991
|
-
}, actionLabel) : /*#__PURE__*/React__default.createElement(StyledIcon$
|
|
8031
|
+
}, actionLabel) : /*#__PURE__*/React__default.createElement(StyledIcon$2, {
|
|
7992
8032
|
icon: "cancel",
|
|
7993
8033
|
size: "small",
|
|
7994
8034
|
themeIntent: intent
|
|
@@ -8347,7 +8387,7 @@ var borderWidths = {
|
|
|
8347
8387
|
var config = _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({}, colors), space), radii), borderWidths);
|
|
8348
8388
|
var flexPropsKey = ['alignContent', 'alignItems', 'alignSelf', 'display', 'flex', 'flexBasis', 'flexDirection', 'flexGrow', 'flexShrink', 'flexWrap', 'justifyContent'];
|
|
8349
8389
|
|
|
8350
|
-
var _excluded$
|
|
8390
|
+
var _excluded$A = ["theme"];
|
|
8351
8391
|
var getThemeValue = function getThemeValue(theme, key, props) {
|
|
8352
8392
|
var propConfig = config[key];
|
|
8353
8393
|
var propValue = props[key];
|
|
@@ -8374,18 +8414,18 @@ var mapStylePropToThemeValue = function mapStylePropToThemeValue(theme, props) {
|
|
|
8374
8414
|
var configKeys = Object.keys(config);
|
|
8375
8415
|
var StyledBox = index$9(View)(function (_ref5) {
|
|
8376
8416
|
var theme = _ref5.theme,
|
|
8377
|
-
otherProps = _objectWithoutProperties(_ref5, _excluded$
|
|
8417
|
+
otherProps = _objectWithoutProperties(_ref5, _excluded$A);
|
|
8378
8418
|
var styleProps = pick(configKeys, otherProps);
|
|
8379
8419
|
var flexProps = pick(_toConsumableArray(flexPropsKey), otherProps);
|
|
8380
8420
|
return _objectSpread2(_objectSpread2({}, mapStylePropToThemeValue(theme, styleProps)), flexProps);
|
|
8381
8421
|
});
|
|
8382
8422
|
|
|
8383
|
-
var _excluded$
|
|
8423
|
+
var _excluded$z = ["children", "style", "testID"];
|
|
8384
8424
|
var Box = function Box(_ref) {
|
|
8385
8425
|
var children = _ref.children,
|
|
8386
8426
|
style = _ref.style,
|
|
8387
8427
|
testID = _ref.testID,
|
|
8388
|
-
otherProps = _objectWithoutProperties(_ref, _excluded$
|
|
8428
|
+
otherProps = _objectWithoutProperties(_ref, _excluded$z);
|
|
8389
8429
|
return /*#__PURE__*/React__default.createElement(StyledBox, _extends$1({}, otherProps, {
|
|
8390
8430
|
style: style,
|
|
8391
8431
|
testID: testID
|
|
@@ -8566,6 +8606,7 @@ var StyledView$2 = index$9(Animated.View)(function (_ref) {
|
|
|
8566
8606
|
var themeIntent = _ref.themeIntent,
|
|
8567
8607
|
themePadding = _ref.themePadding,
|
|
8568
8608
|
themeSize = _ref.themeSize,
|
|
8609
|
+
themeVariant = _ref.themeVariant,
|
|
8569
8610
|
theme = _ref.theme;
|
|
8570
8611
|
return {
|
|
8571
8612
|
height: theme.__hd__.badge.sizes[themeSize].height,
|
|
@@ -8574,7 +8615,9 @@ var StyledView$2 = index$9(Animated.View)(function (_ref) {
|
|
|
8574
8615
|
justifyContent: 'center',
|
|
8575
8616
|
backgroundColor: theme.__hd__.badge.colors[themeIntent],
|
|
8576
8617
|
borderRadius: theme.radii.rounded,
|
|
8577
|
-
paddingHorizontal: themePadding === 'wideContent' ? theme.__hd__.badge.space[themeSize].horizontalPadding : undefined
|
|
8618
|
+
paddingHorizontal: themePadding === 'wideContent' ? theme.__hd__.badge.space[themeSize].horizontalPadding : undefined,
|
|
8619
|
+
borderWidth: theme.__hd__.badge.borderWidths["default"],
|
|
8620
|
+
borderColor: themeVariant === 'outlined' ? theme.__hd__.badge.colors.border : theme.__hd__.badge.colors[themeIntent]
|
|
8578
8621
|
};
|
|
8579
8622
|
});
|
|
8580
8623
|
var StyledText$1 = index$9(Typography.Caption)(function (_ref2) {
|
|
@@ -8603,8 +8646,15 @@ var StyledStatus = index$9(Animated.View)(function (_ref3) {
|
|
|
8603
8646
|
borderRadius: theme.radii.rounded
|
|
8604
8647
|
};
|
|
8605
8648
|
});
|
|
8649
|
+
var StyledIcon$1 = index$9(Icon)(function (_ref4) {
|
|
8650
|
+
var themeSize = _ref4.themeSize,
|
|
8651
|
+
theme = _ref4.theme;
|
|
8652
|
+
return {
|
|
8653
|
+
fontSize: theme.__hd__.badge.fontSizes[themeSize]
|
|
8654
|
+
};
|
|
8655
|
+
});
|
|
8606
8656
|
|
|
8607
|
-
var _excluded$
|
|
8657
|
+
var _excluded$y = ["children", "visible", "intent", "style", "testID"];
|
|
8608
8658
|
var Status = function Status(_ref) {
|
|
8609
8659
|
var children = _ref.children,
|
|
8610
8660
|
_ref$visible = _ref.visible,
|
|
@@ -8613,7 +8663,7 @@ var Status = function Status(_ref) {
|
|
|
8613
8663
|
intent = _ref$intent === void 0 ? 'danger' : _ref$intent,
|
|
8614
8664
|
style = _ref.style,
|
|
8615
8665
|
testID = _ref.testID,
|
|
8616
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
8666
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$y);
|
|
8617
8667
|
var _React$useRef = React__default.useRef(new Animated.Value(visible ? 1 : 0)),
|
|
8618
8668
|
opacity = _React$useRef.current;
|
|
8619
8669
|
var isFirstRendering = React__default.useRef(true);
|
|
@@ -8646,7 +8696,7 @@ var Status = function Status(_ref) {
|
|
|
8646
8696
|
}));
|
|
8647
8697
|
};
|
|
8648
8698
|
|
|
8649
|
-
var _excluded$
|
|
8699
|
+
var _excluded$x = ["content", "visible", "max", "intent", "style", "testID", "size", "variant", "icon"];
|
|
8650
8700
|
var DEFAULT_MAX_NUMBER = 99;
|
|
8651
8701
|
var getPaddingState = function getPaddingState(content) {
|
|
8652
8702
|
return content.length > 1 ? 'wideContent' : 'narrowContent';
|
|
@@ -8663,7 +8713,10 @@ var Badge = function Badge(_ref) {
|
|
|
8663
8713
|
testID = _ref.testID,
|
|
8664
8714
|
_ref$size = _ref.size,
|
|
8665
8715
|
size = _ref$size === void 0 ? 'medium' : _ref$size,
|
|
8666
|
-
|
|
8716
|
+
_ref$variant = _ref.variant,
|
|
8717
|
+
variant = _ref$variant === void 0 ? 'filled' : _ref$variant,
|
|
8718
|
+
icon = _ref.icon,
|
|
8719
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$x);
|
|
8667
8720
|
var _React$useRef = React__default.useRef(new Animated.Value(visible ? 1 : 0)),
|
|
8668
8721
|
opacity = _React$useRef.current;
|
|
8669
8722
|
var isFirstRendering = React__default.useRef(true);
|
|
@@ -8679,11 +8732,18 @@ var Badge = function Badge(_ref) {
|
|
|
8679
8732
|
useNativeDriver: true
|
|
8680
8733
|
}).start();
|
|
8681
8734
|
}, [visible, opacity]);
|
|
8682
|
-
var
|
|
8735
|
+
var isIconBadge = !!icon;
|
|
8736
|
+
var content = useMemo(function () {
|
|
8737
|
+
if (isIconBadge) {
|
|
8738
|
+
return '';
|
|
8739
|
+
}
|
|
8740
|
+
return typeof originalContent === 'number' && originalContent > max ? "".concat(max, "+") : String(originalContent);
|
|
8741
|
+
}, [isIconBadge, originalContent, max]);
|
|
8683
8742
|
return /*#__PURE__*/React__default.createElement(StyledView$2, _extends$1({}, nativeProps, {
|
|
8684
8743
|
themeIntent: intent,
|
|
8685
8744
|
themePadding: getPaddingState(content),
|
|
8686
8745
|
themeSize: size,
|
|
8746
|
+
themeVariant: variant,
|
|
8687
8747
|
style: [{
|
|
8688
8748
|
opacity: opacity,
|
|
8689
8749
|
transform: [{
|
|
@@ -8694,7 +8754,11 @@ var Badge = function Badge(_ref) {
|
|
|
8694
8754
|
}]
|
|
8695
8755
|
}, style],
|
|
8696
8756
|
testID: testID
|
|
8697
|
-
}), /*#__PURE__*/React__default.createElement(
|
|
8757
|
+
}), isIconBadge ? /*#__PURE__*/React__default.createElement(StyledIcon$1, {
|
|
8758
|
+
icon: icon,
|
|
8759
|
+
themeSize: size,
|
|
8760
|
+
intent: "text-inverted"
|
|
8761
|
+
}) : /*#__PURE__*/React__default.createElement(StyledText$1, {
|
|
8698
8762
|
themeSize: size
|
|
8699
8763
|
}, content));
|
|
8700
8764
|
};
|
|
@@ -8753,7 +8817,7 @@ var StyledBottomBarText = index$9(Typography.Caption)(function (_ref3) {
|
|
|
8753
8817
|
};
|
|
8754
8818
|
});
|
|
8755
8819
|
|
|
8756
|
-
var _excluded$
|
|
8820
|
+
var _excluded$w = ["onTabPress", "renderActiveTabOnly", "selectedTabKey", "tabs"];
|
|
8757
8821
|
var getInactiveIcon = function getInactiveIcon(icon) {
|
|
8758
8822
|
var inactiveIcon = "".concat(icon, "-outlined");
|
|
8759
8823
|
return isHeroIcon(inactiveIcon) ? inactiveIcon : icon;
|
|
@@ -8764,7 +8828,7 @@ var BottomNavigation = function BottomNavigation(_ref) {
|
|
|
8764
8828
|
renderActiveTabOnly = _ref$renderActiveTabO === void 0 ? false : _ref$renderActiveTabO,
|
|
8765
8829
|
selectedTabKey = _ref.selectedTabKey,
|
|
8766
8830
|
tabs = _ref.tabs,
|
|
8767
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
8831
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$w);
|
|
8768
8832
|
var insets = useSafeAreaInsets();
|
|
8769
8833
|
/**
|
|
8770
8834
|
* List of loaded tabs, tabs will be loaded when navigated to.
|
|
@@ -8850,13 +8914,13 @@ var StyledDivider = index$9(View)(function (_ref) {
|
|
|
8850
8914
|
}, horizontalMargin), verticalMargin);
|
|
8851
8915
|
});
|
|
8852
8916
|
|
|
8853
|
-
var _excluded$
|
|
8917
|
+
var _excluded$v = ["marginHorizontal", "marginVertical", "style", "testID"];
|
|
8854
8918
|
var Divider = function Divider(_ref) {
|
|
8855
8919
|
var marginHorizontal = _ref.marginHorizontal,
|
|
8856
8920
|
marginVertical = _ref.marginVertical,
|
|
8857
8921
|
style = _ref.style,
|
|
8858
8922
|
testID = _ref.testID,
|
|
8859
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
8923
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$v);
|
|
8860
8924
|
return /*#__PURE__*/React__default.createElement(StyledDivider, _extends$1({}, nativeProps, {
|
|
8861
8925
|
themeMarginHorizontal: marginHorizontal,
|
|
8862
8926
|
themeMarginVertical: marginVertical,
|
|
@@ -9012,7 +9076,7 @@ var StyledLoadingDot = index$9(View)(function (_ref) {
|
|
|
9012
9076
|
}, themeStyling());
|
|
9013
9077
|
});
|
|
9014
9078
|
|
|
9015
|
-
var _excluded$
|
|
9079
|
+
var _excluded$u = ["count", "size", "testID", "themeVariant"];
|
|
9016
9080
|
var AnimatedLoadingIndicatorWrapper = Animated.createAnimatedComponent(StyledLoadingIndicatorWrapper);
|
|
9017
9081
|
var AnimatedLoadingDot = Animated.createAnimatedComponent(StyledLoadingDot);
|
|
9018
9082
|
var renderDotComponent = function renderDotComponent(_ref) {
|
|
@@ -9044,7 +9108,7 @@ var LoadingIndicator = function LoadingIndicator(_ref2) {
|
|
|
9044
9108
|
size = _ref2$size === void 0 ? 12 : _ref2$size,
|
|
9045
9109
|
testID = _ref2.testID,
|
|
9046
9110
|
themeVariant = _ref2.themeVariant,
|
|
9047
|
-
nativeProps = _objectWithoutProperties(_ref2, _excluded$
|
|
9111
|
+
nativeProps = _objectWithoutProperties(_ref2, _excluded$u);
|
|
9048
9112
|
var progressAnimation = useRef(new Animated.Value(0));
|
|
9049
9113
|
useEffect(function () {
|
|
9050
9114
|
var animation = Animated.loop(Animated.timing(progressAnimation.current, {
|
|
@@ -9487,11 +9551,11 @@ var Header = function Header(_ref) {
|
|
|
9487
9551
|
}))) : null), showDivider ? /*#__PURE__*/React__default.createElement(Divider, null) : null);
|
|
9488
9552
|
};
|
|
9489
9553
|
|
|
9490
|
-
var _excluded$
|
|
9554
|
+
var _excluded$t = ["scrollEventThrottle"];
|
|
9491
9555
|
var BottomSheetScrollView = function BottomSheetScrollView(_ref) {
|
|
9492
9556
|
var _ref$scrollEventThrot = _ref.scrollEventThrottle,
|
|
9493
9557
|
scrollEventThrottle = _ref$scrollEventThrot === void 0 ? 100 : _ref$scrollEventThrot,
|
|
9494
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
9558
|
+
props = _objectWithoutProperties(_ref, _excluded$t);
|
|
9495
9559
|
var _useContext = useContext(BottomSheetContext),
|
|
9496
9560
|
setInternalShowDivider = _useContext.setInternalShowDivider;
|
|
9497
9561
|
var onScrollBeginDrag = useCallback(function (e) {
|
|
@@ -12308,12 +12372,12 @@ var Indicator = index$9(View)(function (_ref2) {
|
|
|
12308
12372
|
};
|
|
12309
12373
|
});
|
|
12310
12374
|
|
|
12311
|
-
var _excluded$
|
|
12375
|
+
var _excluded$s = ["intent", "children"];
|
|
12312
12376
|
var DataCard = function DataCard(_ref) {
|
|
12313
12377
|
var _ref$intent = _ref.intent,
|
|
12314
12378
|
intent = _ref$intent === void 0 ? 'info' : _ref$intent,
|
|
12315
12379
|
children = _ref.children,
|
|
12316
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
12380
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$s);
|
|
12317
12381
|
return /*#__PURE__*/React__default.createElement(StyledDataCard, nativeProps, /*#__PURE__*/React__default.createElement(Indicator, {
|
|
12318
12382
|
themeIntent: intent,
|
|
12319
12383
|
testID: "data-card-indicator"
|
|
@@ -12332,13 +12396,13 @@ var StyledCard$1 = index$9(View)(function (_ref) {
|
|
|
12332
12396
|
});
|
|
12333
12397
|
});
|
|
12334
12398
|
|
|
12335
|
-
var _excluded$
|
|
12399
|
+
var _excluded$r = ["intent", "children", "variant"];
|
|
12336
12400
|
var Card = function Card(_ref) {
|
|
12337
12401
|
var intent = _ref.intent,
|
|
12338
12402
|
children = _ref.children,
|
|
12339
12403
|
_ref$variant = _ref.variant,
|
|
12340
12404
|
variant = _ref$variant === void 0 ? 'basic' : _ref$variant,
|
|
12341
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
12405
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$r);
|
|
12342
12406
|
return /*#__PURE__*/React__default.createElement(StyledCard$1, _extends$1({}, nativeProps, {
|
|
12343
12407
|
themeIntent: intent,
|
|
12344
12408
|
themeVariant: variant
|
|
@@ -12600,7 +12664,7 @@ var CardCarousel = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
12600
12664
|
});
|
|
12601
12665
|
CardCarousel.displayName = 'CardCarousel';
|
|
12602
12666
|
|
|
12603
|
-
var _excluded$
|
|
12667
|
+
var _excluded$q = ["rounded", "size", "testID", "style"];
|
|
12604
12668
|
var Image = function Image(_ref) {
|
|
12605
12669
|
var _ref$rounded = _ref.rounded,
|
|
12606
12670
|
rounded = _ref$rounded === void 0 ? false : _ref$rounded,
|
|
@@ -12608,7 +12672,7 @@ var Image = function Image(_ref) {
|
|
|
12608
12672
|
size = _ref$size === void 0 ? '6xlarge' : _ref$size,
|
|
12609
12673
|
testID = _ref.testID,
|
|
12610
12674
|
style = _ref.style,
|
|
12611
|
-
imageNativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
12675
|
+
imageNativeProps = _objectWithoutProperties(_ref, _excluded$q);
|
|
12612
12676
|
var theme = useTheme();
|
|
12613
12677
|
var imageSize = theme.__hd__.image.sizes[size];
|
|
12614
12678
|
return /*#__PURE__*/React__default.createElement(Image$1, _extends$1({
|
|
@@ -12742,7 +12806,7 @@ var CarouselItem = function CarouselItem(_ref) {
|
|
|
12742
12806
|
}, heading), !!body && /*#__PURE__*/React__default.createElement(Typography.Body, null, body)));
|
|
12743
12807
|
};
|
|
12744
12808
|
|
|
12745
|
-
var _excluded$
|
|
12809
|
+
var _excluded$p = ["items", "onItemIndexChange", "renderActions", "selectedItemIndex", "style", "shouldShowPagination", "testID", "pageControlPosition"];
|
|
12746
12810
|
function useStateFromProp(initialValue) {
|
|
12747
12811
|
var _useState = useState(initialValue),
|
|
12748
12812
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -12769,7 +12833,7 @@ var Carousel = function Carousel(_ref) {
|
|
|
12769
12833
|
testID = _ref.testID,
|
|
12770
12834
|
_ref$pageControlPosit = _ref.pageControlPosition,
|
|
12771
12835
|
pageControlPosition = _ref$pageControlPosit === void 0 ? 'top' : _ref$pageControlPosit,
|
|
12772
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
12836
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$p);
|
|
12773
12837
|
useDeprecation("shouldShowPagination prop has been deprecated", shouldShowPagination !== noop);
|
|
12774
12838
|
useDeprecation("The use of 'pageControlPosition == bottom' has been deprecated", pageControlPosition === 'bottom');
|
|
12775
12839
|
var theme = useTheme();
|
|
@@ -12886,6 +12950,7 @@ var StyledChipWrapper = index$9(TouchableOpacity)(function (_ref) {
|
|
|
12886
12950
|
theme = _ref.theme;
|
|
12887
12951
|
var getShadowStyles = function getShadowStyles() {
|
|
12888
12952
|
switch (themeVariant) {
|
|
12953
|
+
case 'compact':
|
|
12889
12954
|
case 'filled':
|
|
12890
12955
|
return _objectSpread2({}, theme.__hd__.chip.shadows.filledWrapper);
|
|
12891
12956
|
case 'outlined':
|
|
@@ -12901,6 +12966,7 @@ var StyledChipWrapper = index$9(TouchableOpacity)(function (_ref) {
|
|
|
12901
12966
|
borderWidth: themeSelected ? theme.__hd__.chip.sizes.outlinedSelectedBorder : theme.__hd__.chip.sizes.outlinedDefaultBorder
|
|
12902
12967
|
};
|
|
12903
12968
|
}
|
|
12969
|
+
case 'compact':
|
|
12904
12970
|
case 'filled':
|
|
12905
12971
|
{
|
|
12906
12972
|
return {
|
|
@@ -12919,9 +12985,17 @@ var StyledChipWrapper = index$9(TouchableOpacity)(function (_ref) {
|
|
|
12919
12985
|
};
|
|
12920
12986
|
}
|
|
12921
12987
|
case 'filled':
|
|
12922
|
-
|
|
12923
|
-
|
|
12924
|
-
|
|
12988
|
+
{
|
|
12989
|
+
return {
|
|
12990
|
+
backgroundColor: theme.__hd__.chip.colors.secondaryBackground
|
|
12991
|
+
};
|
|
12992
|
+
}
|
|
12993
|
+
case 'compact':
|
|
12994
|
+
{
|
|
12995
|
+
return {
|
|
12996
|
+
backgroundColor: theme.__hd__.chip.colors.compactSelectedBackground
|
|
12997
|
+
};
|
|
12998
|
+
}
|
|
12925
12999
|
}
|
|
12926
13000
|
} else {
|
|
12927
13001
|
switch (themeVariant) {
|
|
@@ -12932,25 +13006,49 @@ var StyledChipWrapper = index$9(TouchableOpacity)(function (_ref) {
|
|
|
12932
13006
|
};
|
|
12933
13007
|
}
|
|
12934
13008
|
case 'filled':
|
|
13009
|
+
{
|
|
13010
|
+
return {
|
|
13011
|
+
backgroundColor: theme.__hd__.chip.colors.filledBackground
|
|
13012
|
+
};
|
|
13013
|
+
}
|
|
13014
|
+
case 'compact':
|
|
13015
|
+
{
|
|
13016
|
+
return {
|
|
13017
|
+
backgroundColor: theme.__hd__.chip.colors.compactDefaultBackground
|
|
13018
|
+
};
|
|
13019
|
+
}
|
|
13020
|
+
}
|
|
13021
|
+
}
|
|
13022
|
+
};
|
|
13023
|
+
var getPaddingStyles = function getPaddingStyles() {
|
|
13024
|
+
switch (themeVariant) {
|
|
13025
|
+
case 'compact':
|
|
13026
|
+
{
|
|
12935
13027
|
return {
|
|
12936
|
-
|
|
13028
|
+
paddingHorizontal: theme.__hd__.chip.space.compactWrapperHorizontalPadding,
|
|
13029
|
+
paddingVertical: theme.__hd__.chip.space.compactWrapperVerticalPadding
|
|
12937
13030
|
};
|
|
12938
|
-
|
|
13031
|
+
}
|
|
13032
|
+
default:
|
|
13033
|
+
{
|
|
13034
|
+
return {
|
|
13035
|
+
paddingHorizontal: theme.__hd__.chip.space.wrapperHorizontalPadding,
|
|
13036
|
+
paddingVertical: theme.__hd__.chip.space.wrapperVerticalPadding
|
|
13037
|
+
};
|
|
13038
|
+
}
|
|
12939
13039
|
}
|
|
12940
13040
|
};
|
|
12941
|
-
return _objectSpread2(_objectSpread2(_objectSpread2({
|
|
13041
|
+
return _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({
|
|
12942
13042
|
alignSelf: 'flex-start',
|
|
12943
13043
|
flexDirection: 'row',
|
|
12944
13044
|
alignItems: 'center',
|
|
12945
13045
|
justifyContent: 'center',
|
|
12946
13046
|
borderRadius: theme.__hd__.chip.radii.wrapper,
|
|
12947
|
-
|
|
12948
|
-
|
|
12949
|
-
marginTop: themeSelected ? theme.__hd__.chip.space.outlinedSelectedMarginTop : undefined
|
|
12950
|
-
}, getShadowStyles()), getBorderStyles()), getBackgroundStyles());
|
|
13047
|
+
marginTop: themeSelected && themeVariant === 'outlined' ? theme.__hd__.chip.space.outlinedSelectedMarginTop : undefined
|
|
13048
|
+
}, getShadowStyles()), getBorderStyles()), getPaddingStyles()), getBackgroundStyles());
|
|
12951
13049
|
});
|
|
12952
13050
|
|
|
12953
|
-
var _excluded$
|
|
13051
|
+
var _excluded$o = ["label", "variant", "selected", "icon", "onPress", "showSelectedIcon"];
|
|
12954
13052
|
var Chip = function Chip(_ref) {
|
|
12955
13053
|
var label = _ref.label,
|
|
12956
13054
|
_ref$variant = _ref.variant,
|
|
@@ -12961,7 +13059,7 @@ var Chip = function Chip(_ref) {
|
|
|
12961
13059
|
onPress = _ref.onPress,
|
|
12962
13060
|
_ref$showSelectedIcon = _ref.showSelectedIcon,
|
|
12963
13061
|
showSelectedIcon = _ref$showSelectedIcon === void 0 ? true : _ref$showSelectedIcon,
|
|
12964
|
-
otherProps = _objectWithoutProperties(_ref, _excluded$
|
|
13062
|
+
otherProps = _objectWithoutProperties(_ref, _excluded$o);
|
|
12965
13063
|
var shouldShowSelectedIcon = variant === 'outlined' && selected && showSelectedIcon;
|
|
12966
13064
|
return /*#__PURE__*/React__default.createElement(StyledChipWrapper, _extends$1({
|
|
12967
13065
|
onPress: onPress,
|
|
@@ -13202,7 +13300,7 @@ var StyledErrorAndMaxLengthContainer = index$9(View)(function () {
|
|
|
13202
13300
|
};
|
|
13203
13301
|
});
|
|
13204
13302
|
|
|
13205
|
-
var _excluded$
|
|
13303
|
+
var _excluded$n = ["label", "prefix", "suffix", "style", "textStyle", "testID", "accessibilityLabelledBy", "error", "required", "editable", "disabled", "loading", "maxLength", "hideCharacterCount", "helpText", "value", "defaultValue", "renderInputValue", "allowFontScaling", "variant"];
|
|
13206
13304
|
var getState$2 = function getState(_ref) {
|
|
13207
13305
|
var disabled = _ref.disabled,
|
|
13208
13306
|
error = _ref.error,
|
|
@@ -13314,7 +13412,7 @@ var TextInput = /*#__PURE__*/forwardRef(function (_ref8, ref) {
|
|
|
13314
13412
|
allowFontScaling = _ref8$allowFontScalin === void 0 ? false : _ref8$allowFontScalin,
|
|
13315
13413
|
_ref8$variant = _ref8.variant,
|
|
13316
13414
|
variant = _ref8$variant === void 0 ? 'text' : _ref8$variant,
|
|
13317
|
-
nativeProps = _objectWithoutProperties(_ref8, _excluded$
|
|
13415
|
+
nativeProps = _objectWithoutProperties(_ref8, _excluded$n);
|
|
13318
13416
|
var displayText = getDisplayText(value, defaultValue);
|
|
13319
13417
|
var isEmptyValue = displayText.length === 0;
|
|
13320
13418
|
var _React$useState = React__default.useState({
|
|
@@ -13859,11 +13957,11 @@ var DatePickerIOS = function DatePickerIOS(_ref) {
|
|
|
13859
13957
|
}))));
|
|
13860
13958
|
};
|
|
13861
13959
|
|
|
13862
|
-
var _excluded$
|
|
13960
|
+
var _excluded$m = ["variant"];
|
|
13863
13961
|
var DatePicker = function DatePicker(_ref) {
|
|
13864
13962
|
var _ref$variant = _ref.variant,
|
|
13865
13963
|
variant = _ref$variant === void 0 ? 'default' : _ref$variant,
|
|
13866
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
13964
|
+
props = _objectWithoutProperties(_ref, _excluded$m);
|
|
13867
13965
|
if (variant === 'calendar') {
|
|
13868
13966
|
return /*#__PURE__*/React__default.createElement(DatePickerCalendar, props);
|
|
13869
13967
|
}
|
|
@@ -14417,7 +14515,7 @@ var Portal$1 = Object.assign(Portal, {
|
|
|
14417
14515
|
Host: PortalHost
|
|
14418
14516
|
});
|
|
14419
14517
|
|
|
14420
|
-
var _excluded$
|
|
14518
|
+
var _excluded$l = ["visible"];
|
|
14421
14519
|
var DEFAULT_BACKDROP_OPACITY = 0.4;
|
|
14422
14520
|
var DEFAULT_ANIMATION_CONFIG = {
|
|
14423
14521
|
easing: Easing.inOut(Easing.cubic),
|
|
@@ -14513,7 +14611,7 @@ var Modal = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
14513
14611
|
var ModalWrapper = function ModalWrapper(_ref3) {
|
|
14514
14612
|
var _ref3$visible = _ref3.visible,
|
|
14515
14613
|
visible = _ref3$visible === void 0 ? true : _ref3$visible,
|
|
14516
|
-
props = _objectWithoutProperties(_ref3, _excluded$
|
|
14614
|
+
props = _objectWithoutProperties(_ref3, _excluded$l);
|
|
14517
14615
|
var modalRef = useRef(null);
|
|
14518
14616
|
var _useState = useState(visible),
|
|
14519
14617
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -14623,7 +14721,7 @@ var StyledErrorDescription = index$9(Typography.Body)(function (_ref9) {
|
|
|
14623
14721
|
};
|
|
14624
14722
|
});
|
|
14625
14723
|
|
|
14626
|
-
var _excluded$
|
|
14724
|
+
var _excluded$k = ["variant", "title", "description", "image", "testID", "ctaText", "onCtaPress", "secondaryCtaText", "onSecondaryCtaPress"],
|
|
14627
14725
|
_excluded2 = ["visible", "variant", "title", "description", "image", "testID", "ctaText", "onCtaPress", "secondaryCtaText", "onSecondaryCtaPress"];
|
|
14628
14726
|
var renderImage$1 = function renderImage(image) {
|
|
14629
14727
|
if ( /*#__PURE__*/isValidElement(image)) {
|
|
@@ -14649,7 +14747,7 @@ var ErrorPage = function ErrorPage(_ref) {
|
|
|
14649
14747
|
onCtaPress = _ref.onCtaPress,
|
|
14650
14748
|
secondaryCtaText = _ref.secondaryCtaText,
|
|
14651
14749
|
onSecondaryCtaPress = _ref.onSecondaryCtaPress,
|
|
14652
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
14750
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$k);
|
|
14653
14751
|
var showCta = ctaText && onCtaPress !== undefined;
|
|
14654
14752
|
var showSecondaryCta = secondaryCtaText && onSecondaryCtaPress !== undefined;
|
|
14655
14753
|
var showButtonContainer = showCta || showSecondaryCta;
|
|
@@ -14762,8 +14860,35 @@ var ErrorComponent = function ErrorComponent(_ref2) {
|
|
|
14762
14860
|
}, nativeProps));
|
|
14763
14861
|
};
|
|
14764
14862
|
|
|
14863
|
+
var StyledActionItem = index$9(TouchableHighlight)(function (_ref) {
|
|
14864
|
+
var theme = _ref.theme;
|
|
14865
|
+
return {
|
|
14866
|
+
padding: theme.__hd__.fab.space.actionItemPadding,
|
|
14867
|
+
margin: theme.__hd__.fab.space.actionItemMargin,
|
|
14868
|
+
marginRight: theme.__hd__.fab.space.actionItemMarginRight,
|
|
14869
|
+
backgroundColor: theme.__hd__.fab.colors.actionItemBackground,
|
|
14870
|
+
borderRadius: theme.__hd__.fab.radii.actionItem,
|
|
14871
|
+
flexDirection: 'row',
|
|
14872
|
+
alignItems: 'center',
|
|
14873
|
+
alignSelf: 'flex-end',
|
|
14874
|
+
overflow: 'hidden'
|
|
14875
|
+
};
|
|
14876
|
+
});
|
|
14877
|
+
var StyledActionItemText = index$9(Typography.Body)(function (_ref2) {
|
|
14878
|
+
var theme = _ref2.theme;
|
|
14879
|
+
return {
|
|
14880
|
+
color: theme.__hd__.fab.colors.actionItemText
|
|
14881
|
+
};
|
|
14882
|
+
});
|
|
14883
|
+
var StyledIcon = index$9(Icon)(function (_ref3) {
|
|
14884
|
+
var theme = _ref3.theme;
|
|
14885
|
+
return {
|
|
14886
|
+
color: theme.__hd__.fab.colors.actionItemText
|
|
14887
|
+
};
|
|
14888
|
+
});
|
|
14889
|
+
|
|
14765
14890
|
var AnimatedTouchableHighlight = Animated.createAnimatedComponent(TouchableHighlight);
|
|
14766
|
-
var StyledFAB$
|
|
14891
|
+
var StyledFAB$2 = index$9(AnimatedTouchableHighlight)(function (_ref) {
|
|
14767
14892
|
var theme = _ref.theme,
|
|
14768
14893
|
themeActive = _ref.themeActive;
|
|
14769
14894
|
return {
|
|
@@ -14810,11 +14935,52 @@ var StyledIconContainer = index$9(Box)(function (_ref4) {
|
|
|
14810
14935
|
};
|
|
14811
14936
|
});
|
|
14812
14937
|
|
|
14813
|
-
var
|
|
14938
|
+
var ActionItem = function ActionItem(_ref) {
|
|
14939
|
+
var icon = _ref.icon,
|
|
14940
|
+
title = _ref.title,
|
|
14941
|
+
onPress = _ref.onPress,
|
|
14942
|
+
style = _ref.style,
|
|
14943
|
+
testID = _ref.testID,
|
|
14944
|
+
index = _ref.index,
|
|
14945
|
+
_ref$active = _ref.active,
|
|
14946
|
+
active = _ref$active === void 0 ? false : _ref$active;
|
|
14947
|
+
var theme = useTheme();
|
|
14948
|
+
var animatedValue = React__default.useRef(new Animated.Value(0));
|
|
14949
|
+
var translateY = animatedValue.current.interpolate({
|
|
14950
|
+
inputRange: [0, 1],
|
|
14951
|
+
outputRange: [50, 0]
|
|
14952
|
+
});
|
|
14953
|
+
React__default.useEffect(function () {
|
|
14954
|
+
Animated.spring(animatedValue.current, {
|
|
14955
|
+
toValue: active ? 1 : 0,
|
|
14956
|
+
useNativeDriver: Platform.OS !== 'web',
|
|
14957
|
+
delay: index * 30,
|
|
14958
|
+
speed: 10,
|
|
14959
|
+
bounciness: 10
|
|
14960
|
+
}).start();
|
|
14961
|
+
}, [active, index]);
|
|
14962
|
+
return /*#__PURE__*/React__default.createElement(Animated.View, {
|
|
14963
|
+
style: {
|
|
14964
|
+
transform: [{
|
|
14965
|
+
translateY: translateY
|
|
14966
|
+
}]
|
|
14967
|
+
}
|
|
14968
|
+
}, /*#__PURE__*/React__default.createElement(StyledActionItem, {
|
|
14969
|
+
underlayColor: theme.__hd__.fab.colors.actionItemPressedBackground,
|
|
14970
|
+
style: style,
|
|
14971
|
+
onPress: onPress,
|
|
14972
|
+
testID: testID
|
|
14973
|
+
}, /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(StyledIconContainer, null, /*#__PURE__*/React__default.createElement(StyledIcon, {
|
|
14974
|
+
size: "xsmall",
|
|
14975
|
+
icon: icon
|
|
14976
|
+
})), /*#__PURE__*/React__default.createElement(StyledActionItemText, null, title))));
|
|
14977
|
+
};
|
|
14978
|
+
|
|
14979
|
+
var _excluded$j = ["active"];
|
|
14814
14980
|
var AnimatedIcons = Animated.createAnimatedComponent(StyledFABIcon);
|
|
14815
14981
|
var AnimatedFABIcon = function AnimatedFABIcon(_ref) {
|
|
14816
14982
|
var active = _ref.active,
|
|
14817
|
-
iconProps = _objectWithoutProperties(_ref, _excluded$
|
|
14983
|
+
iconProps = _objectWithoutProperties(_ref, _excluded$j);
|
|
14818
14984
|
var rotateAnimation = useRef(new Animated.Value(active ? 1 : 0));
|
|
14819
14985
|
useEffect(function () {
|
|
14820
14986
|
var animation = Animated.spring(rotateAnimation.current, {
|
|
@@ -14854,13 +15020,15 @@ var IconOnlyContent = function IconOnlyContent(_ref) {
|
|
|
14854
15020
|
return /*#__PURE__*/React__default.createElement(StyledIconContainer, null, /*#__PURE__*/React__default.createElement(AnimatedFABIcon, {
|
|
14855
15021
|
active: active,
|
|
14856
15022
|
icon: icon,
|
|
14857
|
-
testID: "animated-fab-icon"
|
|
15023
|
+
testID: "animated-fab-icon",
|
|
15024
|
+
size: "xsmall"
|
|
14858
15025
|
}));
|
|
14859
15026
|
}
|
|
14860
|
-
return /*#__PURE__*/React__default.createElement(StyledFABIcon, {
|
|
15027
|
+
return /*#__PURE__*/React__default.createElement(StyledIconContainer, null, /*#__PURE__*/React__default.createElement(StyledFABIcon, {
|
|
15028
|
+
size: "xsmall",
|
|
14861
15029
|
icon: icon,
|
|
14862
15030
|
testID: "styled-fab-icon"
|
|
14863
|
-
});
|
|
15031
|
+
}));
|
|
14864
15032
|
};
|
|
14865
15033
|
var IconWithTextContent = function IconWithTextContent(_ref2) {
|
|
14866
15034
|
var icon = _ref2.icon,
|
|
@@ -14958,7 +15126,7 @@ var FAB$1 = /*#__PURE__*/forwardRef(function (_ref3, ref) {
|
|
|
14958
15126
|
}
|
|
14959
15127
|
};
|
|
14960
15128
|
}, []);
|
|
14961
|
-
return /*#__PURE__*/React__default.createElement(StyledFAB$
|
|
15129
|
+
return /*#__PURE__*/React__default.createElement(StyledFAB$2, {
|
|
14962
15130
|
onLayout: function onLayout(event) {
|
|
14963
15131
|
return !hasSetButtonWidth && !active && setButtonWidth(event.nativeEvent.layout.width);
|
|
14964
15132
|
},
|
|
@@ -14994,74 +15162,6 @@ var FAB$1 = /*#__PURE__*/forwardRef(function (_ref3, ref) {
|
|
|
14994
15162
|
});
|
|
14995
15163
|
FAB$1.displayName = 'FAB';
|
|
14996
15164
|
|
|
14997
|
-
var StyledActionItem = index$9(TouchableHighlight)(function (_ref) {
|
|
14998
|
-
var theme = _ref.theme;
|
|
14999
|
-
return {
|
|
15000
|
-
padding: theme.__hd__.fab.space.actionItemPadding,
|
|
15001
|
-
margin: theme.__hd__.fab.space.actionItemMargin,
|
|
15002
|
-
marginRight: theme.__hd__.fab.space.actionItemMarginRight,
|
|
15003
|
-
backgroundColor: theme.__hd__.fab.colors.actionItemBackground,
|
|
15004
|
-
borderRadius: theme.__hd__.fab.radii.actionItem,
|
|
15005
|
-
flexDirection: 'row',
|
|
15006
|
-
alignItems: 'center',
|
|
15007
|
-
alignSelf: 'flex-end',
|
|
15008
|
-
overflow: 'hidden'
|
|
15009
|
-
};
|
|
15010
|
-
});
|
|
15011
|
-
var StyledActionItemText = index$9(Typography.Body)(function (_ref2) {
|
|
15012
|
-
var theme = _ref2.theme;
|
|
15013
|
-
return {
|
|
15014
|
-
color: theme.__hd__.fab.colors.actionItemText
|
|
15015
|
-
};
|
|
15016
|
-
});
|
|
15017
|
-
var StyledIcon = index$9(Icon)(function (_ref3) {
|
|
15018
|
-
var theme = _ref3.theme;
|
|
15019
|
-
return {
|
|
15020
|
-
color: theme.__hd__.fab.colors.actionItemText
|
|
15021
|
-
};
|
|
15022
|
-
});
|
|
15023
|
-
|
|
15024
|
-
var ActionItem = function ActionItem(_ref) {
|
|
15025
|
-
var icon = _ref.icon,
|
|
15026
|
-
title = _ref.title,
|
|
15027
|
-
onPress = _ref.onPress,
|
|
15028
|
-
style = _ref.style,
|
|
15029
|
-
testID = _ref.testID,
|
|
15030
|
-
index = _ref.index,
|
|
15031
|
-
_ref$active = _ref.active,
|
|
15032
|
-
active = _ref$active === void 0 ? false : _ref$active;
|
|
15033
|
-
var theme = useTheme();
|
|
15034
|
-
var animatedValue = React__default.useRef(new Animated.Value(0));
|
|
15035
|
-
var translateY = animatedValue.current.interpolate({
|
|
15036
|
-
inputRange: [0, 1],
|
|
15037
|
-
outputRange: [50, 0]
|
|
15038
|
-
});
|
|
15039
|
-
React__default.useEffect(function () {
|
|
15040
|
-
Animated.spring(animatedValue.current, {
|
|
15041
|
-
toValue: active ? 1 : 0,
|
|
15042
|
-
useNativeDriver: Platform.OS !== 'web',
|
|
15043
|
-
delay: index * 30,
|
|
15044
|
-
speed: 10,
|
|
15045
|
-
bounciness: 10
|
|
15046
|
-
}).start();
|
|
15047
|
-
}, [active, index]);
|
|
15048
|
-
return /*#__PURE__*/React__default.createElement(Animated.View, {
|
|
15049
|
-
style: {
|
|
15050
|
-
transform: [{
|
|
15051
|
-
translateY: translateY
|
|
15052
|
-
}]
|
|
15053
|
-
}
|
|
15054
|
-
}, /*#__PURE__*/React__default.createElement(StyledActionItem, {
|
|
15055
|
-
underlayColor: theme.__hd__.fab.colors.actionItemPressedBackground,
|
|
15056
|
-
style: style,
|
|
15057
|
-
onPress: onPress,
|
|
15058
|
-
testID: testID
|
|
15059
|
-
}, /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(StyledIconContainer, null, /*#__PURE__*/React__default.createElement(StyledIcon, {
|
|
15060
|
-
size: "xsmall",
|
|
15061
|
-
icon: icon
|
|
15062
|
-
})), /*#__PURE__*/React__default.createElement(StyledActionItemText, null, title))));
|
|
15063
|
-
};
|
|
15064
|
-
|
|
15065
15165
|
var StyledContainer$3 = index$9(View)({
|
|
15066
15166
|
position: 'absolute',
|
|
15067
15167
|
left: 0,
|
|
@@ -15085,7 +15185,7 @@ var StyledActionGroupContainer = index$9(Animated.View)({
|
|
|
15085
15185
|
justifyContent: 'flex-end',
|
|
15086
15186
|
width: '70%'
|
|
15087
15187
|
});
|
|
15088
|
-
var StyledFAB = index$9(FAB$1)(function (_ref) {
|
|
15188
|
+
var StyledFAB$1 = index$9(FAB$1)(function (_ref) {
|
|
15089
15189
|
var theme = _ref.theme;
|
|
15090
15190
|
return {
|
|
15091
15191
|
marginRight: theme.__hd__.fab.space.buttonMarginRight,
|
|
@@ -15162,7 +15262,7 @@ var ActionGroup = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
15162
15262
|
testID: testID,
|
|
15163
15263
|
pointerEvents: "box-none",
|
|
15164
15264
|
style: style
|
|
15165
|
-
}, /*#__PURE__*/React__default.createElement(Animated.View, null, /*#__PURE__*/React__default.createElement(StyledFAB, {
|
|
15265
|
+
}, /*#__PURE__*/React__default.createElement(Animated.View, null, /*#__PURE__*/React__default.createElement(StyledFAB$1, {
|
|
15166
15266
|
key: "fab",
|
|
15167
15267
|
testID: "fab",
|
|
15168
15268
|
icon: fabIcon,
|
|
@@ -15200,7 +15300,7 @@ var ActionGroup = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
15200
15300
|
index: active ? index : items.length - index,
|
|
15201
15301
|
active: active
|
|
15202
15302
|
}));
|
|
15203
|
-
}))), active && /*#__PURE__*/React__default.createElement(StyledFAB
|
|
15303
|
+
}))), active && /*#__PURE__*/React__default.createElement(StyledFAB$1
|
|
15204
15304
|
// This FAB is moved up a bit compared to the original FAB,
|
|
15205
15305
|
// set marginBottom to negative value to compensate for it
|
|
15206
15306
|
, {
|
|
@@ -15218,8 +15318,51 @@ var ActionGroup = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
15218
15318
|
});
|
|
15219
15319
|
ActionGroup.displayName = 'FAB.ActionGroup';
|
|
15220
15320
|
|
|
15321
|
+
var StyledFABPairWrapper = index$9(Box)({
|
|
15322
|
+
flexDirection: 'row',
|
|
15323
|
+
justifyContent: 'center',
|
|
15324
|
+
alignItems: 'center'
|
|
15325
|
+
});
|
|
15326
|
+
var StyledFAB = index$9(FAB$1)(function (_ref) {
|
|
15327
|
+
var theme = _ref.theme,
|
|
15328
|
+
_ref$iconOnly = _ref.iconOnly,
|
|
15329
|
+
iconOnly = _ref$iconOnly === void 0 ? false : _ref$iconOnly,
|
|
15330
|
+
_ref$isLast = _ref.isLast,
|
|
15331
|
+
isLast = _ref$isLast === void 0 ? false : _ref$isLast;
|
|
15332
|
+
return {
|
|
15333
|
+
height: theme.__hd__.fab.sizes.fabPairHeight,
|
|
15334
|
+
width: iconOnly ? theme.__hd__.fab.sizes.fabPairIconOnlyWidth : undefined,
|
|
15335
|
+
marginRight: isLast ? undefined : theme.__hd__.fab.space.fabPairMarginRight
|
|
15336
|
+
};
|
|
15337
|
+
});
|
|
15338
|
+
|
|
15339
|
+
var _excluded$i = ["fabConfig", "onCancel"];
|
|
15340
|
+
var Pair = function Pair(_ref) {
|
|
15341
|
+
var fabConfig = _ref.fabConfig,
|
|
15342
|
+
onCancel = _ref.onCancel,
|
|
15343
|
+
props = _objectWithoutProperties(_ref, _excluded$i);
|
|
15344
|
+
var icon = fabConfig.icon,
|
|
15345
|
+
title = fabConfig.title,
|
|
15346
|
+
onPress = fabConfig.onPress,
|
|
15347
|
+
testID = fabConfig.testID;
|
|
15348
|
+
return /*#__PURE__*/React__default.createElement(StyledFABPairWrapper, props, /*#__PURE__*/React__default.createElement(StyledFAB, {
|
|
15349
|
+
icon: "cancel",
|
|
15350
|
+
onPress: onCancel,
|
|
15351
|
+
testID: "fab-pair-cancel",
|
|
15352
|
+
iconOnly: true
|
|
15353
|
+
}), /*#__PURE__*/React__default.createElement(StyledFAB, {
|
|
15354
|
+
icon: icon,
|
|
15355
|
+
title: title,
|
|
15356
|
+
onPress: onPress,
|
|
15357
|
+
testID: testID,
|
|
15358
|
+
iconOnly: !title,
|
|
15359
|
+
isLast: true
|
|
15360
|
+
}));
|
|
15361
|
+
};
|
|
15362
|
+
|
|
15221
15363
|
var FAB = Object.assign(FAB$1, {
|
|
15222
|
-
ActionGroup: ActionGroup
|
|
15364
|
+
ActionGroup: ActionGroup,
|
|
15365
|
+
Pair: Pair
|
|
15223
15366
|
});
|
|
15224
15367
|
|
|
15225
15368
|
var ToastContainerWrapper = index$9(View)(function (_ref) {
|
|
@@ -16063,7 +16206,7 @@ var StyledStrokeEnd = index$9(View)(function (_ref6) {
|
|
|
16063
16206
|
};
|
|
16064
16207
|
});
|
|
16065
16208
|
|
|
16066
|
-
var _excluded$
|
|
16209
|
+
var _excluded$h = ["value", "renderValue", "intent", "style", "testID"];
|
|
16067
16210
|
var HalfCircle = function HalfCircle(_ref) {
|
|
16068
16211
|
var type = _ref.type,
|
|
16069
16212
|
themeIntent = _ref.themeIntent;
|
|
@@ -16084,7 +16227,7 @@ var ProgressCircle = function ProgressCircle(_ref2) {
|
|
|
16084
16227
|
intent = _ref2$intent === void 0 ? 'primary' : _ref2$intent,
|
|
16085
16228
|
style = _ref2.style,
|
|
16086
16229
|
testID = _ref2.testID,
|
|
16087
|
-
nativeProps = _objectWithoutProperties(_ref2, _excluded$
|
|
16230
|
+
nativeProps = _objectWithoutProperties(_ref2, _excluded$h);
|
|
16088
16231
|
var theme = useTheme$1();
|
|
16089
16232
|
var radius = theme.__hd__.progress.sizes.circleDiameter / 2;
|
|
16090
16233
|
var progressAnimatedValue = useRef(new Animated.Value(0));
|
|
@@ -16200,14 +16343,14 @@ var StyledInner = index$9(Animated.View)(function (_ref2) {
|
|
|
16200
16343
|
};
|
|
16201
16344
|
});
|
|
16202
16345
|
|
|
16203
|
-
var _excluded$
|
|
16346
|
+
var _excluded$g = ["value", "intent", "style", "testID"];
|
|
16204
16347
|
var ProgressBar = function ProgressBar(_ref) {
|
|
16205
16348
|
var value = _ref.value,
|
|
16206
16349
|
_ref$intent = _ref.intent,
|
|
16207
16350
|
intent = _ref$intent === void 0 ? 'primary' : _ref$intent,
|
|
16208
16351
|
style = _ref.style,
|
|
16209
16352
|
testID = _ref.testID,
|
|
16210
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
16353
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$g);
|
|
16211
16354
|
var _useState = useState(0),
|
|
16212
16355
|
_useState2 = _slicedToArray(_useState, 2),
|
|
16213
16356
|
width = _useState2[0],
|
|
@@ -16281,12 +16424,13 @@ var StyledSingleStepContainer = index$9(Box)(function (_ref2) {
|
|
|
16281
16424
|
};
|
|
16282
16425
|
});
|
|
16283
16426
|
var StyledSingleStep = index$9(Box)(function (_ref3) {
|
|
16284
|
-
var theme = _ref3.theme
|
|
16427
|
+
var theme = _ref3.theme,
|
|
16428
|
+
themeState = _ref3.themeState;
|
|
16285
16429
|
return {
|
|
16286
16430
|
height: theme.__hd__.progress.sizes.stepHeight,
|
|
16287
16431
|
borderRadius: theme.__hd__.progress.radii["default"],
|
|
16288
16432
|
backgroundColor: theme.__hd__.progress.colors.step.complete,
|
|
16289
|
-
width: '70%',
|
|
16433
|
+
width: themeState === 'complete' ? '100%' : '70%',
|
|
16290
16434
|
position: 'absolute',
|
|
16291
16435
|
top: 0,
|
|
16292
16436
|
left: 0,
|
|
@@ -16295,7 +16439,7 @@ var StyledSingleStep = index$9(Box)(function (_ref3) {
|
|
|
16295
16439
|
};
|
|
16296
16440
|
});
|
|
16297
16441
|
|
|
16298
|
-
var _excluded$
|
|
16442
|
+
var _excluded$f = ["steps", "current", "onLayout"];
|
|
16299
16443
|
var getStepState = function getStepState(current, index) {
|
|
16300
16444
|
if (index < current) {
|
|
16301
16445
|
return 'complete';
|
|
@@ -16309,7 +16453,7 @@ var ProgressStep = function ProgressStep(_ref) {
|
|
|
16309
16453
|
var steps = _ref.steps,
|
|
16310
16454
|
current = _ref.current,
|
|
16311
16455
|
onLayout = _ref.onLayout,
|
|
16312
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
16456
|
+
props = _objectWithoutProperties(_ref, _excluded$f);
|
|
16313
16457
|
var theme = useTheme$1();
|
|
16314
16458
|
var _React$useState = React__default.useState(0),
|
|
16315
16459
|
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
@@ -16328,7 +16472,9 @@ var ProgressStep = function ProgressStep(_ref) {
|
|
|
16328
16472
|
return width;
|
|
16329
16473
|
}, [containerWidth, steps, theme]);
|
|
16330
16474
|
if (steps === 1) {
|
|
16331
|
-
return /*#__PURE__*/React__default.createElement(StyledSingleStepContainer, props, /*#__PURE__*/React__default.createElement(StyledSingleStep,
|
|
16475
|
+
return /*#__PURE__*/React__default.createElement(StyledSingleStepContainer, props, /*#__PURE__*/React__default.createElement(StyledSingleStep, {
|
|
16476
|
+
themeState: current >= steps ? 'complete' : 'incomplete'
|
|
16477
|
+
}));
|
|
16332
16478
|
}
|
|
16333
16479
|
return /*#__PURE__*/React__default.createElement(StyledStepContainer, _extends$1({}, props, {
|
|
16334
16480
|
onLayout: onContainerLayout
|
|
@@ -16488,14 +16634,14 @@ var AnimatedSpinner = function AnimatedSpinner(_ref) {
|
|
|
16488
16634
|
}, dotProps))));
|
|
16489
16635
|
};
|
|
16490
16636
|
|
|
16491
|
-
var _excluded$
|
|
16637
|
+
var _excluded$e = ["testID", "size", "intent"];
|
|
16492
16638
|
var Spinner = function Spinner(_ref) {
|
|
16493
16639
|
var testID = _ref.testID,
|
|
16494
16640
|
_ref$size = _ref.size,
|
|
16495
16641
|
size = _ref$size === void 0 ? 'medium' : _ref$size,
|
|
16496
16642
|
_ref$intent = _ref.intent,
|
|
16497
16643
|
intent = _ref$intent === void 0 ? 'primary' : _ref$intent,
|
|
16498
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
16644
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$e);
|
|
16499
16645
|
return /*#__PURE__*/React__default.createElement(StyledView$1, nativeProps, /*#__PURE__*/React__default.createElement(StyledSpinnerContainer, {
|
|
16500
16646
|
testID: testID
|
|
16501
16647
|
}, /*#__PURE__*/React__default.createElement(AnimatedSpinner, {
|
|
@@ -16528,7 +16674,7 @@ var SwipeableAction = function SwipeableAction(_ref) {
|
|
|
16528
16674
|
}, children);
|
|
16529
16675
|
};
|
|
16530
16676
|
|
|
16531
|
-
var _excluded$
|
|
16677
|
+
var _excluded$d = ["children", "state", "onStateChange", "leftActions", "leftActionsWidth", "rightActions", "rightActionsWidth", "variant"];
|
|
16532
16678
|
var renderActions = function renderActions(actions, width, progress, direction) {
|
|
16533
16679
|
var trans = progress.interpolate({
|
|
16534
16680
|
inputRange: [0, 1],
|
|
@@ -16557,7 +16703,7 @@ var Swipeable = function Swipeable(_ref) {
|
|
|
16557
16703
|
rightActionsWidth = _ref.rightActionsWidth,
|
|
16558
16704
|
_ref$variant = _ref.variant,
|
|
16559
16705
|
variant = _ref$variant === void 0 ? 'card' : _ref$variant,
|
|
16560
|
-
swipeableProps = _objectWithoutProperties(_ref, _excluded$
|
|
16706
|
+
swipeableProps = _objectWithoutProperties(_ref, _excluded$d);
|
|
16561
16707
|
var theme = useTheme();
|
|
16562
16708
|
var _useWindowDimensions = useWindowDimensions(),
|
|
16563
16709
|
width = _useWindowDimensions.width;
|
|
@@ -16908,7 +17054,7 @@ var StyledSectionList = index$9(SectionList)(function (_ref4) {
|
|
|
16908
17054
|
};
|
|
16909
17055
|
});
|
|
16910
17056
|
|
|
16911
|
-
var _excluded$
|
|
17057
|
+
var _excluded$c = ["keyExtractor", "loading", "onEndReached", "onQueryChange", "sections", "renderItem", "sectionListRef"];
|
|
16912
17058
|
var BaseOptionList = function BaseOptionList(_ref) {
|
|
16913
17059
|
var keyExtractor = _ref.keyExtractor,
|
|
16914
17060
|
loading = _ref.loading,
|
|
@@ -16917,7 +17063,7 @@ var BaseOptionList = function BaseOptionList(_ref) {
|
|
|
16917
17063
|
sections = _ref.sections,
|
|
16918
17064
|
renderItem = _ref.renderItem,
|
|
16919
17065
|
sectionListRef = _ref.sectionListRef,
|
|
16920
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
17066
|
+
rest = _objectWithoutProperties(_ref, _excluded$c);
|
|
16921
17067
|
var theme = useTheme$1();
|
|
16922
17068
|
var _useState = useState(false),
|
|
16923
17069
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -16987,7 +17133,7 @@ var Option$2 = function Option(_ref) {
|
|
|
16987
17133
|
return highlighted === true ? /*#__PURE__*/React__default.createElement(List.Item, props) : /*#__PURE__*/React__default.createElement(List.BasicItem, props);
|
|
16988
17134
|
};
|
|
16989
17135
|
|
|
16990
|
-
var _excluded$
|
|
17136
|
+
var _excluded$b = ["keyExtractor", "loading", "onEndReached", "onPress", "onQueryChange", "sections", "renderOption", "value", "sectionListRef"];
|
|
16991
17137
|
var OptionList$1 = function OptionList(_ref) {
|
|
16992
17138
|
var keyExtractor = _ref.keyExtractor,
|
|
16993
17139
|
loading = _ref.loading,
|
|
@@ -16998,7 +17144,7 @@ var OptionList$1 = function OptionList(_ref) {
|
|
|
16998
17144
|
renderOption = _ref.renderOption,
|
|
16999
17145
|
value = _ref.value,
|
|
17000
17146
|
sectionListRef = _ref.sectionListRef,
|
|
17001
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
17147
|
+
rest = _objectWithoutProperties(_ref, _excluded$b);
|
|
17002
17148
|
var renderItem = function renderItem(info) {
|
|
17003
17149
|
var item = info.item;
|
|
17004
17150
|
var selected = value.includes(info.item.value);
|
|
@@ -17189,7 +17335,7 @@ var StyledOptionList = index$9(BaseOptionList)(function (_ref) {
|
|
|
17189
17335
|
};
|
|
17190
17336
|
});
|
|
17191
17337
|
|
|
17192
|
-
var _excluded$
|
|
17338
|
+
var _excluded$a = ["keyExtractor", "loading", "onEndReached", "onPress", "onQueryChange", "sections", "renderOption", "value", "sectionListRef"];
|
|
17193
17339
|
var OptionList = function OptionList(_ref) {
|
|
17194
17340
|
var keyExtractor = _ref.keyExtractor,
|
|
17195
17341
|
loading = _ref.loading,
|
|
@@ -17200,7 +17346,7 @@ var OptionList = function OptionList(_ref) {
|
|
|
17200
17346
|
renderOption = _ref.renderOption,
|
|
17201
17347
|
value = _ref.value,
|
|
17202
17348
|
sectionListRef = _ref.sectionListRef,
|
|
17203
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
17349
|
+
rest = _objectWithoutProperties(_ref, _excluded$a);
|
|
17204
17350
|
var renderItem = function renderItem(info) {
|
|
17205
17351
|
var item = info.item;
|
|
17206
17352
|
var selected = item.value === value;
|
|
@@ -17368,7 +17514,7 @@ var StyledGradientContainer = index$9(Box)(function (_ref2) {
|
|
|
17368
17514
|
};
|
|
17369
17515
|
});
|
|
17370
17516
|
|
|
17371
|
-
var _excluded$
|
|
17517
|
+
var _excluded$9 = ["intent", "variant", "style", "onLayout"];
|
|
17372
17518
|
var AnimatedLinearGradient = Animated.createAnimatedComponent(LinearGradient);
|
|
17373
17519
|
var gradientPositions = {
|
|
17374
17520
|
start: {
|
|
@@ -17400,7 +17546,7 @@ var Skeleton = function Skeleton(_ref) {
|
|
|
17400
17546
|
variant = _ref$variant === void 0 ? 'rounded' : _ref$variant,
|
|
17401
17547
|
style = _ref.style,
|
|
17402
17548
|
onLayout = _ref.onLayout,
|
|
17403
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
17549
|
+
props = _objectWithoutProperties(_ref, _excluded$9);
|
|
17404
17550
|
var theme = useTheme();
|
|
17405
17551
|
var colors = useMemo(function () {
|
|
17406
17552
|
return getGradientColors(theme, intent);
|
|
@@ -17532,7 +17678,7 @@ var StyledSuccessModal = index$9(ModalWrapper)({
|
|
|
17532
17678
|
width: '100%'
|
|
17533
17679
|
});
|
|
17534
17680
|
|
|
17535
|
-
var _excluded$
|
|
17681
|
+
var _excluded$8 = ["variant", "title", "description", "image", "testID", "ctaText", "onCtaPress", "secondaryCtaText", "onSecondaryCtaPress"];
|
|
17536
17682
|
var renderImage = function renderImage(image) {
|
|
17537
17683
|
if ( /*#__PURE__*/isValidElement(image)) {
|
|
17538
17684
|
return /*#__PURE__*/React__default.cloneElement(image, {
|
|
@@ -17558,7 +17704,7 @@ var SuccessPage = function SuccessPage(_ref) {
|
|
|
17558
17704
|
onCtaPress = _ref$onCtaPress === void 0 ? noop$1 : _ref$onCtaPress,
|
|
17559
17705
|
secondaryCtaText = _ref.secondaryCtaText,
|
|
17560
17706
|
onSecondaryCtaPress = _ref.onSecondaryCtaPress,
|
|
17561
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
17707
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$8);
|
|
17562
17708
|
var showSecondaryButton = secondaryCtaText && onSecondaryCtaPress;
|
|
17563
17709
|
return /*#__PURE__*/React__default.createElement(StyledSuccessContainer, _extends$1({
|
|
17564
17710
|
testID: testID,
|
|
@@ -18576,7 +18722,7 @@ var StyledText = index$9(Typography.Caption)(function (_ref2) {
|
|
|
18576
18722
|
};
|
|
18577
18723
|
});
|
|
18578
18724
|
|
|
18579
|
-
var _excluded$
|
|
18725
|
+
var _excluded$7 = ["content", "variant", "intent", "style", "testID"];
|
|
18580
18726
|
var Tag = function Tag(_ref) {
|
|
18581
18727
|
var content = _ref.content,
|
|
18582
18728
|
_ref$variant = _ref.variant,
|
|
@@ -18585,7 +18731,7 @@ var Tag = function Tag(_ref) {
|
|
|
18585
18731
|
intent = _ref$intent === void 0 ? 'primary' : _ref$intent,
|
|
18586
18732
|
style = _ref.style,
|
|
18587
18733
|
testID = _ref.testID,
|
|
18588
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
18734
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$7);
|
|
18589
18735
|
useDeprecation("Tag's variant prop is deprecated and will be removed in the next major release. Please remove it.", variant !== undefined);
|
|
18590
18736
|
return /*#__PURE__*/React__default.createElement(StyledView, _extends$1({}, nativeProps, {
|
|
18591
18737
|
themeIntent: intent,
|
|
@@ -18814,6 +18960,13 @@ var IconButtonLabel = index$9(Typography.Body)(function (_ref5) {
|
|
|
18814
18960
|
marginLeft: theme.__hd__.toolbar.space.iconButtonLabelMarginLeft
|
|
18815
18961
|
};
|
|
18816
18962
|
});
|
|
18963
|
+
var StyledLabel = index$9(Typography.Body)(function (_ref6) {
|
|
18964
|
+
var theme = _ref6.theme,
|
|
18965
|
+
intent = _ref6.intent;
|
|
18966
|
+
return {
|
|
18967
|
+
color: intent === 'secondary' ? theme.__hd__.toolbar.colors.secondary : theme.__hd__.typography.colors[intent]
|
|
18968
|
+
};
|
|
18969
|
+
});
|
|
18817
18970
|
|
|
18818
18971
|
var IconItem = function IconItem(_ref) {
|
|
18819
18972
|
var icon = _ref.icon,
|
|
@@ -18848,7 +19001,7 @@ var ToolbarItemContent = function ToolbarItemContent(_ref2) {
|
|
|
18848
19001
|
});
|
|
18849
19002
|
}
|
|
18850
19003
|
if (label) {
|
|
18851
|
-
return /*#__PURE__*/React__default.createElement(
|
|
19004
|
+
return /*#__PURE__*/React__default.createElement(StyledLabel, {
|
|
18852
19005
|
variant: "regular-bold",
|
|
18853
19006
|
intent: disabled ? 'disabled' : intent,
|
|
18854
19007
|
allowFontScaling: false,
|
|
@@ -18903,10 +19056,10 @@ var ToolbarGroup = function ToolbarGroup(_ref) {
|
|
|
18903
19056
|
}));
|
|
18904
19057
|
};
|
|
18905
19058
|
|
|
18906
|
-
var _excluded$
|
|
19059
|
+
var _excluded$6 = ["children"];
|
|
18907
19060
|
var Toolbar = function Toolbar(_ref) {
|
|
18908
19061
|
var children = _ref.children,
|
|
18909
|
-
rest = _objectWithoutProperties(_ref, _excluded$
|
|
19062
|
+
rest = _objectWithoutProperties(_ref, _excluded$6);
|
|
18910
19063
|
return /*#__PURE__*/React__default.createElement(ToolbarWrapper, rest, children);
|
|
18911
19064
|
};
|
|
18912
19065
|
var index$1 = Object.assign(Toolbar, {
|
|
@@ -18925,7 +19078,7 @@ var StyledIconWrapper = index$9(AnimatedBox)(function (_ref) {
|
|
|
18925
19078
|
};
|
|
18926
19079
|
});
|
|
18927
19080
|
|
|
18928
|
-
var _excluded$
|
|
19081
|
+
var _excluded$5 = ["options", "value", "onChange", "readonly", "disabled"];
|
|
18929
19082
|
var Rate = function Rate(_ref) {
|
|
18930
19083
|
var options = _ref.options,
|
|
18931
19084
|
value = _ref.value,
|
|
@@ -18934,7 +19087,7 @@ var Rate = function Rate(_ref) {
|
|
|
18934
19087
|
readonly = _ref$readonly === void 0 ? false : _ref$readonly,
|
|
18935
19088
|
_ref$disabled = _ref.disabled,
|
|
18936
19089
|
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
18937
|
-
otherProps = _objectWithoutProperties(_ref, _excluded$
|
|
19090
|
+
otherProps = _objectWithoutProperties(_ref, _excluded$5);
|
|
18938
19091
|
var valueIndex = useMemo(function () {
|
|
18939
19092
|
return options.findIndex(function (item) {
|
|
18940
19093
|
return item.value === value;
|
|
@@ -36325,30 +36478,30 @@ function AnimatedScroller(_ref) {
|
|
|
36325
36478
|
}));
|
|
36326
36479
|
}
|
|
36327
36480
|
|
|
36328
|
-
var _excluded$
|
|
36481
|
+
var _excluded$4 = ["fabProps"];
|
|
36329
36482
|
var ScrollViewWithFAB = function ScrollViewWithFAB(_ref) {
|
|
36330
36483
|
var fabProps = _ref.fabProps,
|
|
36331
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
36484
|
+
props = _objectWithoutProperties(_ref, _excluded$4);
|
|
36332
36485
|
return /*#__PURE__*/React__default.createElement(AnimatedScroller, {
|
|
36333
36486
|
ScrollComponent: /*#__PURE__*/React__default.createElement(ScrollView, props),
|
|
36334
36487
|
fabProps: fabProps
|
|
36335
36488
|
});
|
|
36336
36489
|
};
|
|
36337
36490
|
|
|
36338
|
-
var _excluded$
|
|
36491
|
+
var _excluded$3 = ["fabProps"];
|
|
36339
36492
|
function FlatListWithFAB(_ref) {
|
|
36340
36493
|
var fabProps = _ref.fabProps,
|
|
36341
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
36494
|
+
props = _objectWithoutProperties(_ref, _excluded$3);
|
|
36342
36495
|
return /*#__PURE__*/React__default.createElement(AnimatedScroller, {
|
|
36343
36496
|
ScrollComponent: /*#__PURE__*/React__default.createElement(FlatList, props),
|
|
36344
36497
|
fabProps: fabProps
|
|
36345
36498
|
});
|
|
36346
36499
|
}
|
|
36347
36500
|
|
|
36348
|
-
var _excluded$
|
|
36501
|
+
var _excluded$2 = ["fabProps"];
|
|
36349
36502
|
function SectionListWithFAB(_ref) {
|
|
36350
36503
|
var fabProps = _ref.fabProps,
|
|
36351
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
36504
|
+
props = _objectWithoutProperties(_ref, _excluded$2);
|
|
36352
36505
|
return /*#__PURE__*/React__default.createElement(AnimatedScroller, {
|
|
36353
36506
|
ScrollComponent: /*#__PURE__*/React__default.createElement(SectionList, props),
|
|
36354
36507
|
fabProps: fabProps
|
|
@@ -36360,20 +36513,30 @@ var StyledContainer = index$9(View)(function () {
|
|
|
36360
36513
|
width: '100%'
|
|
36361
36514
|
};
|
|
36362
36515
|
});
|
|
36516
|
+
var getBorderWidth = function getBorderWidth(theme, themeFocused, themeVariant) {
|
|
36517
|
+
return themeFocused ? theme.__hd__.search.borderWidths.container[themeVariant].focused : theme.__hd__.search.borderWidths.container[themeVariant].normal;
|
|
36518
|
+
};
|
|
36363
36519
|
var StyledInputContainer = index$9(View)(function (_ref) {
|
|
36364
36520
|
var theme = _ref.theme,
|
|
36365
|
-
themeFocused = _ref.themeFocused
|
|
36366
|
-
|
|
36521
|
+
themeFocused = _ref.themeFocused,
|
|
36522
|
+
themeVariant = _ref.themeVariant;
|
|
36523
|
+
var borderWidth = getBorderWidth(theme, themeFocused, themeVariant);
|
|
36524
|
+
return _objectSpread2({
|
|
36367
36525
|
flexDirection: 'row',
|
|
36368
36526
|
alignItems: 'center',
|
|
36369
|
-
paddingHorizontal: theme.__hd__.search.space.containerHorizontalPadding,
|
|
36370
|
-
paddingVertical: theme.__hd__.search.space.containerVerticalPadding,
|
|
36371
|
-
backgroundColor: theme.__hd__.search.colors.containerBackground,
|
|
36527
|
+
paddingHorizontal: theme.__hd__.search.space.containerHorizontalPadding - borderWidth,
|
|
36528
|
+
paddingVertical: theme.__hd__.search.space.containerVerticalPadding - borderWidth,
|
|
36529
|
+
backgroundColor: theme.__hd__.search.colors[themeVariant].containerBackground,
|
|
36372
36530
|
height: 56,
|
|
36373
36531
|
borderRadius: theme.__hd__.search.radii.container,
|
|
36374
|
-
borderWidth:
|
|
36375
|
-
borderColor: themeFocused ? theme.__hd__.search.colors.
|
|
36376
|
-
}
|
|
36532
|
+
borderWidth: borderWidth,
|
|
36533
|
+
borderColor: themeFocused ? theme.__hd__.search.colors[themeVariant].focusedBorder : theme.__hd__.search.colors[themeVariant].border
|
|
36534
|
+
}, themeVariant === 'reversed' && {
|
|
36535
|
+
elevation: theme.__hd__.search.shadows.elevation,
|
|
36536
|
+
shadowOffset: theme.__hd__.search.shadows.offset,
|
|
36537
|
+
shadowOpacity: theme.__hd__.search.shadows.opacity,
|
|
36538
|
+
shadowRadius: theme.__hd__.search.shadows.radius
|
|
36539
|
+
});
|
|
36377
36540
|
});
|
|
36378
36541
|
var StyledAffixContainer = index$9(View)(function (_ref2) {
|
|
36379
36542
|
var theme = _ref2.theme;
|
|
@@ -36389,7 +36552,7 @@ var StyledSuffixContainer = index$9(View)(function (_ref3) {
|
|
|
36389
36552
|
alignItems: 'center',
|
|
36390
36553
|
width: theme.__hd__.search.sizes.surfixSize,
|
|
36391
36554
|
height: theme.__hd__.search.sizes.surfixSize,
|
|
36392
|
-
backgroundColor: theme.__hd__.search.colors.
|
|
36555
|
+
backgroundColor: theme.__hd__.search.colors.suffixBackground,
|
|
36393
36556
|
borderRadius: theme.__hd__.search.radii.surfix
|
|
36394
36557
|
};
|
|
36395
36558
|
});
|
|
@@ -36415,7 +36578,8 @@ var StyledHandlerContainer = index$9(View)(function (_ref5) {
|
|
|
36415
36578
|
alignItems: 'flex-start',
|
|
36416
36579
|
flexGrow: 1,
|
|
36417
36580
|
height: '100%',
|
|
36418
|
-
marginHorizontal: theme.__hd__.search.space.inputHorizontalMargin
|
|
36581
|
+
marginHorizontal: theme.__hd__.search.space.inputHorizontalMargin,
|
|
36582
|
+
paddingVertical: theme.__hd__.search.space.inputVerticalPadding
|
|
36419
36583
|
};
|
|
36420
36584
|
});
|
|
36421
36585
|
var StyledBadge = index$9(Badge$1)(function (_ref6) {
|
|
@@ -36454,12 +36618,15 @@ var SearchTwoLine = function SearchTwoLine(props) {
|
|
|
36454
36618
|
style = props.style,
|
|
36455
36619
|
label = props.label,
|
|
36456
36620
|
content = props.content,
|
|
36457
|
-
testID = props.testID
|
|
36621
|
+
testID = props.testID,
|
|
36622
|
+
_props$variant = props.variant,
|
|
36623
|
+
variant = _props$variant === void 0 ? 'basic' : _props$variant;
|
|
36458
36624
|
return /*#__PURE__*/React__default.createElement(StyledContainer, {
|
|
36459
36625
|
style: style,
|
|
36460
36626
|
testID: testID
|
|
36461
36627
|
}, /*#__PURE__*/React__default.createElement(StyledInputContainer, {
|
|
36462
|
-
themeFocused: false
|
|
36628
|
+
themeFocused: false,
|
|
36629
|
+
themeVariant: variant
|
|
36463
36630
|
}, renderPrefix({
|
|
36464
36631
|
prefix: prefix
|
|
36465
36632
|
}), /*#__PURE__*/React__default.createElement(StyledHandlerContainer, null, /*#__PURE__*/React__default.createElement(Typography.Caption, {
|
|
@@ -36469,7 +36636,7 @@ var SearchTwoLine = function SearchTwoLine(props) {
|
|
|
36469
36636
|
})));
|
|
36470
36637
|
};
|
|
36471
36638
|
|
|
36472
|
-
var _excluded = ["prefix", "suffix", "style", "allowFontScaling", "accessibilityLabelledBy", "editable", "maxLength", "value", "defaultValue", "placeholder", "disabled", "testID"];
|
|
36639
|
+
var _excluded$1 = ["prefix", "suffix", "style", "allowFontScaling", "accessibilityLabelledBy", "editable", "maxLength", "value", "defaultValue", "placeholder", "disabled", "testID", "variant"];
|
|
36473
36640
|
var getState = function getState(_ref) {
|
|
36474
36641
|
var disabled = _ref.disabled,
|
|
36475
36642
|
editable = _ref.editable,
|
|
@@ -36509,7 +36676,9 @@ var SearchOneLine = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
36509
36676
|
_props$disabled = props.disabled,
|
|
36510
36677
|
disabled = _props$disabled === void 0 ? false : _props$disabled,
|
|
36511
36678
|
testID = props.testID,
|
|
36512
|
-
|
|
36679
|
+
_props$variant = props.variant,
|
|
36680
|
+
variant = _props$variant === void 0 ? 'basic' : _props$variant,
|
|
36681
|
+
nativeProps = _objectWithoutProperties(props, _excluded$1);
|
|
36513
36682
|
var _React$useState = React__default.useState(false),
|
|
36514
36683
|
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
36515
36684
|
isFocused = _React$useState2[0],
|
|
@@ -36556,7 +36725,8 @@ var SearchOneLine = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
36556
36725
|
testID: testID,
|
|
36557
36726
|
style: style
|
|
36558
36727
|
}, /*#__PURE__*/React__default.createElement(StyledInputContainer, {
|
|
36559
|
-
themeFocused: isFocused
|
|
36728
|
+
themeFocused: isFocused,
|
|
36729
|
+
themeVariant: variant
|
|
36560
36730
|
}, renderPrefix({
|
|
36561
36731
|
prefix: prefix
|
|
36562
36732
|
}), renderInput({
|
|
@@ -36592,6 +36762,23 @@ var SearchOneLine = /*#__PURE__*/forwardRef(function (props, ref) {
|
|
|
36592
36762
|
})));
|
|
36593
36763
|
});
|
|
36594
36764
|
|
|
36765
|
+
var _excluded = ["content", "icon"];
|
|
36766
|
+
var renderBadge = function renderBadge(props) {
|
|
36767
|
+
var content = props.content,
|
|
36768
|
+
icon = props.icon,
|
|
36769
|
+
rest = _objectWithoutProperties(props, _excluded);
|
|
36770
|
+
if (content) return /*#__PURE__*/React__default.createElement(StyledBadge, _extends$1({
|
|
36771
|
+
intent: "primary",
|
|
36772
|
+
content: content,
|
|
36773
|
+
size: "small"
|
|
36774
|
+
}, rest));
|
|
36775
|
+
if (icon) return /*#__PURE__*/React__default.createElement(StyledBadge, _extends$1({
|
|
36776
|
+
intent: "primary",
|
|
36777
|
+
icon: icon,
|
|
36778
|
+
size: "small"
|
|
36779
|
+
}, rest));
|
|
36780
|
+
return null;
|
|
36781
|
+
};
|
|
36595
36782
|
var SearchSuffixIcon = function SearchSuffixIcon(props) {
|
|
36596
36783
|
var suffix = props.suffix,
|
|
36597
36784
|
testID = props.testID,
|
|
@@ -36600,11 +36787,7 @@ var SearchSuffixIcon = function SearchSuffixIcon(props) {
|
|
|
36600
36787
|
return /*#__PURE__*/React__default.createElement(StyledSuffixContainer, {
|
|
36601
36788
|
testID: testID,
|
|
36602
36789
|
style: style
|
|
36603
|
-
}, !!badge &&
|
|
36604
|
-
intent: "primary"
|
|
36605
|
-
}, badge, {
|
|
36606
|
-
size: "small"
|
|
36607
|
-
})), renderSuffix({
|
|
36790
|
+
}, !!badge && renderBadge(badge), renderSuffix({
|
|
36608
36791
|
suffix: suffix
|
|
36609
36792
|
}));
|
|
36610
36793
|
};
|