@hero-design/rn 8.134.0 → 8.135.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/CHANGELOG.md +6 -0
- package/es/index.js +235 -78
- package/lib/index.js +232 -74
- package/package.json +1 -1
- package/src/components/List/BasicListItem.tsx +2 -2
- package/src/components/List/index.tsx +3 -0
- package/src/components/SectionList/SectionList.tsx +181 -0
- package/src/components/SectionList/StyledSectionList.tsx +65 -0
- package/src/components/SectionList/index.tsx +4 -0
- package/src/index.ts +2 -0
- package/src/theme/components/sectionList.ts +31 -0
- package/src/theme/getTheme.ts +3 -0
- package/src/types.ts +1 -0
- package/types/components/List/BasicListItem.d.ts +2 -2
- package/types/components/List/index.d.ts +2 -0
- package/types/components/Radio/StyledRadio.d.ts +1 -1
- package/types/components/SectionList/SectionList.d.ts +66 -0
- package/types/components/SectionList/StyledSectionList.d.ts +33 -0
- package/types/components/SectionList/index.d.ts +3 -0
- package/types/index.d.ts +2 -1
- package/types/theme/components/sectionList.d.ts +23 -0
- package/types/theme/getTheme.d.ts +2 -0
- package/types/types.d.ts +1 -0
package/es/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as reactNative from 'react-native';
|
|
2
|
-
import { StyleSheet as StyleSheet$1, Platform, Dimensions, Keyboard, Animated, View, UIManager, LayoutAnimation, TouchableOpacity, Text as Text$1, Easing, useWindowDimensions, TouchableWithoutFeedback, Modal as Modal$1, Image as Image$1, Pressable, KeyboardAvoidingView, TouchableHighlight, ScrollView, FlatList, TextInput as TextInput$1, PanResponder, BackHandler, InteractionManager, SectionList, PixelRatio, RefreshControl as RefreshControl$1 } from 'react-native';
|
|
2
|
+
import { StyleSheet as StyleSheet$1, Platform, Dimensions, Keyboard, Animated, View, UIManager, LayoutAnimation, TouchableOpacity, Text as Text$1, Easing, useWindowDimensions, TouchableWithoutFeedback, Modal as Modal$1, Image as Image$1, Pressable, KeyboardAvoidingView, TouchableHighlight, ScrollView, FlatList, TextInput as TextInput$1, PanResponder, BackHandler, InteractionManager, SectionList as SectionList$1, PixelRatio, RefreshControl as RefreshControl$1 } from 'react-native';
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import React__default, { useState, useEffect, useMemo, useCallback, useRef, useLayoutEffect, createContext, forwardRef, useContext, memo, useReducer, isValidElement, useImperativeHandle } from 'react';
|
|
5
5
|
import MaskedView from '@react-native-masked-view/masked-view';
|
|
@@ -6753,6 +6753,34 @@ var getSectionHeadingTheme = function getSectionHeadingTheme(theme) {
|
|
|
6753
6753
|
};
|
|
6754
6754
|
};
|
|
6755
6755
|
|
|
6756
|
+
var getSectionListTheme = function getSectionListTheme(theme) {
|
|
6757
|
+
var colors = {
|
|
6758
|
+
groupBackground: theme.colors.defaultGlobalSurface
|
|
6759
|
+
};
|
|
6760
|
+
var radii = {
|
|
6761
|
+
group: theme.radii.xlarge
|
|
6762
|
+
};
|
|
6763
|
+
var marginHorizontalValues = {
|
|
6764
|
+
none: 0,
|
|
6765
|
+
xsmall: theme.space.xsmall,
|
|
6766
|
+
small: theme.space.small,
|
|
6767
|
+
medium: theme.space.medium,
|
|
6768
|
+
large: theme.space.large,
|
|
6769
|
+
xlarge: theme.space.xlarge
|
|
6770
|
+
};
|
|
6771
|
+
var space = {
|
|
6772
|
+
marginHorizontal: marginHorizontalValues,
|
|
6773
|
+
sectionSpacing: theme.space.medium,
|
|
6774
|
+
sectionSpacingCompact: theme.space.small,
|
|
6775
|
+
headingPaddingLeft: theme.space.small
|
|
6776
|
+
};
|
|
6777
|
+
return {
|
|
6778
|
+
colors: colors,
|
|
6779
|
+
radii: radii,
|
|
6780
|
+
space: space
|
|
6781
|
+
};
|
|
6782
|
+
};
|
|
6783
|
+
|
|
6756
6784
|
var getSelectTheme = function getSelectTheme(theme) {
|
|
6757
6785
|
var space = {
|
|
6758
6786
|
minimumOptionListHeight: theme.space.xxxxlarge * 5,
|
|
@@ -7975,6 +8003,7 @@ var getTheme = function getTheme() {
|
|
|
7975
8003
|
richTextEditor: getRichTextEditorTheme(globalTheme),
|
|
7976
8004
|
search: getSearchTheme(globalTheme),
|
|
7977
8005
|
sectionHeading: getSectionHeadingTheme(globalTheme),
|
|
8006
|
+
sectionList: getSectionListTheme(globalTheme),
|
|
7978
8007
|
select: getSelectTheme(globalTheme),
|
|
7979
8008
|
skeleton: getSkeletonTheme(globalTheme),
|
|
7980
8009
|
slider: getSliderTheme(globalTheme),
|
|
@@ -8186,7 +8215,7 @@ var StyledText$4 = index$c(Text$1)(function (_ref) {
|
|
|
8186
8215
|
});
|
|
8187
8216
|
});
|
|
8188
8217
|
|
|
8189
|
-
var _excluded$
|
|
8218
|
+
var _excluded$Q = ["children", "fontSize", "fontWeight", "intent", "typeface", "allowFontScaling"];
|
|
8190
8219
|
/**
|
|
8191
8220
|
* @deprecated 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.
|
|
8192
8221
|
*/
|
|
@@ -8202,7 +8231,7 @@ var Text = function Text(_ref) {
|
|
|
8202
8231
|
typeface = _ref$typeface === void 0 ? 'neutral' : _ref$typeface,
|
|
8203
8232
|
_ref$allowFontScaling = _ref.allowFontScaling,
|
|
8204
8233
|
allowFontScaling = _ref$allowFontScaling === void 0 ? false : _ref$allowFontScaling,
|
|
8205
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
8234
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$Q);
|
|
8206
8235
|
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.');
|
|
8207
8236
|
return /*#__PURE__*/React__default.createElement(StyledText$4, _extends$1({}, nativeProps, {
|
|
8208
8237
|
themeFontSize: fontSize,
|
|
@@ -8255,10 +8284,10 @@ var pickAccessibilityProps = function pickAccessibilityProps(props) {
|
|
|
8255
8284
|
}, {});
|
|
8256
8285
|
};
|
|
8257
8286
|
|
|
8258
|
-
var _excluded$
|
|
8287
|
+
var _excluded$P = ["children"];
|
|
8259
8288
|
var GradientText = function GradientText(_ref) {
|
|
8260
8289
|
var children = _ref.children,
|
|
8261
|
-
accessibilityProps = _objectWithoutProperties(_ref, _excluded$
|
|
8290
|
+
accessibilityProps = _objectWithoutProperties(_ref, _excluded$P);
|
|
8262
8291
|
var theme = useTheme();
|
|
8263
8292
|
var gradient = theme.colors.gradients.aiDiagonal;
|
|
8264
8293
|
var _useState = useState(null),
|
|
@@ -8314,7 +8343,7 @@ var GradientText = function GradientText(_ref) {
|
|
|
8314
8343
|
}, children));
|
|
8315
8344
|
};
|
|
8316
8345
|
|
|
8317
|
-
var _excluded$
|
|
8346
|
+
var _excluded$O = ["children", "fontWeight", "intent", "allowFontScaling", "fontStyle", "style", "testID"];
|
|
8318
8347
|
var Caption = function Caption(_ref) {
|
|
8319
8348
|
var children = _ref.children,
|
|
8320
8349
|
_ref$fontWeight = _ref.fontWeight,
|
|
@@ -8327,7 +8356,7 @@ var Caption = function Caption(_ref) {
|
|
|
8327
8356
|
fontStyle = _ref$fontStyle === void 0 ? 'normal' : _ref$fontStyle,
|
|
8328
8357
|
style = _ref.style,
|
|
8329
8358
|
testID = _ref.testID,
|
|
8330
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
8359
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$O);
|
|
8331
8360
|
var isAi = intent === 'ai';
|
|
8332
8361
|
var styledText = /*#__PURE__*/React__default.createElement(StyledCaption, _extends$1({}, nativeProps, {
|
|
8333
8362
|
themeFontWeight: fontWeight,
|
|
@@ -8359,7 +8388,7 @@ var StyledLabel$1 = index$c(Text$1)(function (_ref) {
|
|
|
8359
8388
|
};
|
|
8360
8389
|
});
|
|
8361
8390
|
|
|
8362
|
-
var _excluded$
|
|
8391
|
+
var _excluded$N = ["children", "intent", "allowFontScaling", "fontStyle", "fontWeight", "style", "testID"];
|
|
8363
8392
|
var Label = function Label(_ref) {
|
|
8364
8393
|
var children = _ref.children,
|
|
8365
8394
|
_ref$intent = _ref.intent,
|
|
@@ -8372,7 +8401,7 @@ var Label = function Label(_ref) {
|
|
|
8372
8401
|
fontWeight = _ref$fontWeight === void 0 ? 'regular' : _ref$fontWeight,
|
|
8373
8402
|
style = _ref.style,
|
|
8374
8403
|
testID = _ref.testID,
|
|
8375
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
8404
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$N);
|
|
8376
8405
|
var isAi = intent === 'ai';
|
|
8377
8406
|
var styledText = /*#__PURE__*/React__default.createElement(StyledLabel$1, _extends$1({}, nativeProps, {
|
|
8378
8407
|
themeIntent: isAi ? 'body' : intent,
|
|
@@ -8403,7 +8432,7 @@ var StyledTitle$1 = index$c(Text$1)(function (_ref) {
|
|
|
8403
8432
|
};
|
|
8404
8433
|
});
|
|
8405
8434
|
|
|
8406
|
-
var _excluded$
|
|
8435
|
+
var _excluded$M = ["children", "intent", "allowFontScaling", "level", "typeface", "fontStyle", "style", "testID"];
|
|
8407
8436
|
var Title = function Title(_ref) {
|
|
8408
8437
|
var children = _ref.children,
|
|
8409
8438
|
_ref$intent = _ref.intent,
|
|
@@ -8418,7 +8447,7 @@ var Title = function Title(_ref) {
|
|
|
8418
8447
|
fontStyle = _ref$fontStyle === void 0 ? 'normal' : _ref$fontStyle,
|
|
8419
8448
|
style = _ref.style,
|
|
8420
8449
|
testID = _ref.testID,
|
|
8421
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
8450
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$M);
|
|
8422
8451
|
var isAi = intent === 'ai';
|
|
8423
8452
|
var styledText = /*#__PURE__*/React__default.createElement(StyledTitle$1, _extends$1({}, nativeProps, {
|
|
8424
8453
|
themeLevel: level,
|
|
@@ -8468,7 +8497,7 @@ var StyledBody$2 = index$c(Text$1)(function (_ref) {
|
|
|
8468
8497
|
};
|
|
8469
8498
|
});
|
|
8470
8499
|
|
|
8471
|
-
var _excluded$
|
|
8500
|
+
var _excluded$L = ["children", "intent", "allowFontScaling", "typeface", "variant", "fontStyle", "style", "testID"];
|
|
8472
8501
|
var Body = function Body(_ref) {
|
|
8473
8502
|
var children = _ref.children,
|
|
8474
8503
|
_ref$intent = _ref.intent,
|
|
@@ -8483,7 +8512,7 @@ var Body = function Body(_ref) {
|
|
|
8483
8512
|
fontStyle = _ref$fontStyle === void 0 ? 'normal' : _ref$fontStyle,
|
|
8484
8513
|
style = _ref.style,
|
|
8485
8514
|
testID = _ref.testID,
|
|
8486
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
8515
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$L);
|
|
8487
8516
|
var isAi = intent === 'ai';
|
|
8488
8517
|
var styledText = /*#__PURE__*/React__default.createElement(StyledBody$2, _extends$1({}, nativeProps, {
|
|
8489
8518
|
themeTypeface: typeface,
|
|
@@ -9165,22 +9194,22 @@ var SpinWrapper = function SpinWrapper(_ref) {
|
|
|
9165
9194
|
}, children);
|
|
9166
9195
|
};
|
|
9167
9196
|
|
|
9168
|
-
var _excluded$
|
|
9197
|
+
var _excluded$K = ["style"];
|
|
9169
9198
|
var AnimatedIcon = function AnimatedIcon(_ref) {
|
|
9170
9199
|
var style = _ref.style,
|
|
9171
|
-
otherProps = _objectWithoutProperties(_ref, _excluded$
|
|
9200
|
+
otherProps = _objectWithoutProperties(_ref, _excluded$K);
|
|
9172
9201
|
return /*#__PURE__*/React__default.createElement(SpinWrapper, {
|
|
9173
9202
|
style: style
|
|
9174
9203
|
}, /*#__PURE__*/React__default.createElement(StyledHeroIcon, otherProps));
|
|
9175
9204
|
};
|
|
9176
9205
|
|
|
9177
|
-
var _excluded$
|
|
9206
|
+
var _excluded$J = ["name", "themeSize", "testID", "style"];
|
|
9178
9207
|
var GradientIcon = function GradientIcon(_ref) {
|
|
9179
9208
|
var name = _ref.name,
|
|
9180
9209
|
themeSize = _ref.themeSize,
|
|
9181
9210
|
testID = _ref.testID,
|
|
9182
9211
|
style = _ref.style,
|
|
9183
|
-
accessibilityProps = _objectWithoutProperties(_ref, _excluded$
|
|
9212
|
+
accessibilityProps = _objectWithoutProperties(_ref, _excluded$J);
|
|
9184
9213
|
var theme = useTheme();
|
|
9185
9214
|
var gradient = theme.colors.gradients.aiDiagonal;
|
|
9186
9215
|
var size = theme.__hd__.icon.sizes[themeSize];
|
|
@@ -9308,7 +9337,7 @@ var AccordionItem = function AccordionItem(_ref) {
|
|
|
9308
9337
|
}, content));
|
|
9309
9338
|
};
|
|
9310
9339
|
|
|
9311
|
-
var _excluded$
|
|
9340
|
+
var _excluded$I = ["key"];
|
|
9312
9341
|
var Accordion = function Accordion(_ref) {
|
|
9313
9342
|
var items = _ref.items,
|
|
9314
9343
|
activeItemKey = _ref.activeItemKey,
|
|
@@ -9331,7 +9360,7 @@ var Accordion = function Accordion(_ref) {
|
|
|
9331
9360
|
accessible: accessible
|
|
9332
9361
|
}, items.map(function (_ref2, index) {
|
|
9333
9362
|
var key = _ref2.key,
|
|
9334
|
-
props = _objectWithoutProperties(_ref2, _excluded$
|
|
9363
|
+
props = _objectWithoutProperties(_ref2, _excluded$I);
|
|
9335
9364
|
var open = _activeItemKey === key;
|
|
9336
9365
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, {
|
|
9337
9366
|
key: key
|
|
@@ -10172,7 +10201,7 @@ var borderWidths = {
|
|
|
10172
10201
|
var config = _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({}, colors), space), radii), borderWidths);
|
|
10173
10202
|
var flexPropsKey = ['alignContent', 'alignItems', 'alignSelf', 'display', 'flex', 'flexBasis', 'flexDirection', 'flexGrow', 'flexShrink', 'flexWrap', 'justifyContent'];
|
|
10174
10203
|
|
|
10175
|
-
var _excluded$
|
|
10204
|
+
var _excluded$H = ["theme"];
|
|
10176
10205
|
var getThemeValue = function getThemeValue(theme, key, props) {
|
|
10177
10206
|
var propConfig = config[key];
|
|
10178
10207
|
var propValue = props[key];
|
|
@@ -10199,18 +10228,18 @@ var mapStylePropToThemeValue = function mapStylePropToThemeValue(theme, props) {
|
|
|
10199
10228
|
var configKeys = Object.keys(config);
|
|
10200
10229
|
var StyledBox = index$c(View)(function (_ref5) {
|
|
10201
10230
|
var theme = _ref5.theme,
|
|
10202
|
-
otherProps = _objectWithoutProperties(_ref5, _excluded$
|
|
10231
|
+
otherProps = _objectWithoutProperties(_ref5, _excluded$H);
|
|
10203
10232
|
var styleProps = pick(configKeys, otherProps);
|
|
10204
10233
|
var flexProps = pick(_toConsumableArray(flexPropsKey), otherProps);
|
|
10205
10234
|
return _objectSpread2(_objectSpread2({}, mapStylePropToThemeValue(theme, styleProps)), flexProps);
|
|
10206
10235
|
});
|
|
10207
10236
|
|
|
10208
|
-
var _excluded$
|
|
10237
|
+
var _excluded$G = ["children", "style", "testID"];
|
|
10209
10238
|
var Box = function Box(_ref) {
|
|
10210
10239
|
var children = _ref.children,
|
|
10211
10240
|
style = _ref.style,
|
|
10212
10241
|
testID = _ref.testID,
|
|
10213
|
-
otherProps = _objectWithoutProperties(_ref, _excluded$
|
|
10242
|
+
otherProps = _objectWithoutProperties(_ref, _excluded$G);
|
|
10214
10243
|
return /*#__PURE__*/React__default.createElement(StyledBox, _extends$1({}, otherProps, {
|
|
10215
10244
|
style: style,
|
|
10216
10245
|
testID: testID
|
|
@@ -10481,7 +10510,7 @@ var StyledIcon$4 = index$c(Icon)(function (_ref6) {
|
|
|
10481
10510
|
};
|
|
10482
10511
|
});
|
|
10483
10512
|
|
|
10484
|
-
var _excluded$
|
|
10513
|
+
var _excluded$F = ["children", "visible", "intent", "style", "testID"];
|
|
10485
10514
|
var Status$1 = function Status(_ref) {
|
|
10486
10515
|
var children = _ref.children,
|
|
10487
10516
|
_ref$visible = _ref.visible,
|
|
@@ -10490,7 +10519,7 @@ var Status$1 = function Status(_ref) {
|
|
|
10490
10519
|
intent = _ref$intent === void 0 ? 'danger' : _ref$intent,
|
|
10491
10520
|
style = _ref.style,
|
|
10492
10521
|
testID = _ref.testID,
|
|
10493
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
10522
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$F);
|
|
10494
10523
|
var _React$useRef = React__default.useRef(new Animated.Value(visible ? 1 : 0)),
|
|
10495
10524
|
opacity = _React$useRef.current;
|
|
10496
10525
|
var isFirstRendering = React__default.useRef(true);
|
|
@@ -10526,7 +10555,7 @@ var Status$1 = function Status(_ref) {
|
|
|
10526
10555
|
|
|
10527
10556
|
var DEFAULT_MAX_NUMBER = 99;
|
|
10528
10557
|
|
|
10529
|
-
var _excluded$
|
|
10558
|
+
var _excluded$E = ["children", "visible", "style", "max", "testID", "content"];
|
|
10530
10559
|
var Status = function Status(_ref) {
|
|
10531
10560
|
var children = _ref.children,
|
|
10532
10561
|
_ref$visible = _ref.visible,
|
|
@@ -10536,7 +10565,7 @@ var Status = function Status(_ref) {
|
|
|
10536
10565
|
max = _ref$max === void 0 ? DEFAULT_MAX_NUMBER : _ref$max,
|
|
10537
10566
|
testID = _ref.testID,
|
|
10538
10567
|
originalContent = _ref.content,
|
|
10539
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
10568
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$E);
|
|
10540
10569
|
var content = useMemo(function () {
|
|
10541
10570
|
return originalContent > max ? "".concat(max, "+") : String(originalContent);
|
|
10542
10571
|
}, [originalContent, max]);
|
|
@@ -10548,7 +10577,7 @@ var Status = function Status(_ref) {
|
|
|
10548
10577
|
}, /*#__PURE__*/React__default.createElement(StyledCountText, null, content)));
|
|
10549
10578
|
};
|
|
10550
10579
|
|
|
10551
|
-
var _excluded$
|
|
10580
|
+
var _excluded$D = ["content", "visible", "max", "intent", "style", "testID", "size", "variant", "icon"];
|
|
10552
10581
|
var getPaddingState = function getPaddingState(content) {
|
|
10553
10582
|
return content.length > 1 ? 'wideContent' : 'narrowContent';
|
|
10554
10583
|
};
|
|
@@ -10567,7 +10596,7 @@ var Badge$1 = function Badge(_ref) {
|
|
|
10567
10596
|
_ref$variant = _ref.variant,
|
|
10568
10597
|
variant = _ref$variant === void 0 ? 'filled' : _ref$variant,
|
|
10569
10598
|
icon = _ref.icon,
|
|
10570
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
10599
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$D);
|
|
10571
10600
|
var _React$useRef = React__default.useRef(new Animated.Value(visible ? 1 : 0)),
|
|
10572
10601
|
opacity = _React$useRef.current;
|
|
10573
10602
|
var isFirstRendering = React__default.useRef(true);
|
|
@@ -10685,7 +10714,7 @@ var StyledBottomBarText = index$c(Typography.Label)(function (_ref4) {
|
|
|
10685
10714
|
};
|
|
10686
10715
|
});
|
|
10687
10716
|
|
|
10688
|
-
var _excluded$
|
|
10717
|
+
var _excluded$C = ["onTabPress", "renderActiveTabOnly", "selectedTabKey", "tabs"];
|
|
10689
10718
|
var getInactiveIcon = function getInactiveIcon(icon) {
|
|
10690
10719
|
var inactiveIcon = "".concat(icon, "-outlined");
|
|
10691
10720
|
return isHeroIcon(inactiveIcon) ? inactiveIcon : icon;
|
|
@@ -10696,7 +10725,7 @@ var BottomNavigation = function BottomNavigation(_ref) {
|
|
|
10696
10725
|
renderActiveTabOnly = _ref$renderActiveTabO === void 0 ? false : _ref$renderActiveTabO,
|
|
10697
10726
|
selectedTabKey = _ref.selectedTabKey,
|
|
10698
10727
|
tabs = _ref.tabs,
|
|
10699
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
10728
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$C);
|
|
10700
10729
|
var insets = useSafeAreaInsets();
|
|
10701
10730
|
/**
|
|
10702
10731
|
* List of loaded tabs, tabs will be loaded when navigated to.
|
|
@@ -10788,13 +10817,13 @@ var StyledDivider = index$c(View)(function (_ref) {
|
|
|
10788
10817
|
}, horizontalMargin), verticalMargin);
|
|
10789
10818
|
});
|
|
10790
10819
|
|
|
10791
|
-
var _excluded$
|
|
10820
|
+
var _excluded$B = ["marginHorizontal", "marginVertical", "style", "testID"];
|
|
10792
10821
|
var Divider = function Divider(_ref) {
|
|
10793
10822
|
var marginHorizontal = _ref.marginHorizontal,
|
|
10794
10823
|
marginVertical = _ref.marginVertical,
|
|
10795
10824
|
style = _ref.style,
|
|
10796
10825
|
testID = _ref.testID,
|
|
10797
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
10826
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$B);
|
|
10798
10827
|
return /*#__PURE__*/React__default.createElement(StyledDivider, _extends$1({}, nativeProps, {
|
|
10799
10828
|
themeMarginHorizontal: marginHorizontal,
|
|
10800
10829
|
themeMarginVertical: marginVertical,
|
|
@@ -10925,7 +10954,7 @@ var StyledLoadingDot = index$c(View)(function (_ref) {
|
|
|
10925
10954
|
}, themeStyling());
|
|
10926
10955
|
});
|
|
10927
10956
|
|
|
10928
|
-
var _excluded$
|
|
10957
|
+
var _excluded$A = ["count", "size", "testID", "themeVariant"];
|
|
10929
10958
|
var AnimatedLoadingIndicatorWrapper = Animated.createAnimatedComponent(StyledLoadingIndicatorWrapper);
|
|
10930
10959
|
var AnimatedLoadingDot = Animated.createAnimatedComponent(StyledLoadingDot);
|
|
10931
10960
|
var renderDotComponent = function renderDotComponent(_ref) {
|
|
@@ -10957,7 +10986,7 @@ var LoadingIndicator = function LoadingIndicator(_ref2) {
|
|
|
10957
10986
|
size = _ref2$size === void 0 ? 12 : _ref2$size,
|
|
10958
10987
|
testID = _ref2.testID,
|
|
10959
10988
|
themeVariant = _ref2.themeVariant,
|
|
10960
|
-
nativeProps = _objectWithoutProperties(_ref2, _excluded$
|
|
10989
|
+
nativeProps = _objectWithoutProperties(_ref2, _excluded$A);
|
|
10961
10990
|
var progressAnimation = useRef(new Animated.Value(0));
|
|
10962
10991
|
useEffect(function () {
|
|
10963
10992
|
var animation = Animated.loop(Animated.timing(progressAnimation.current, {
|
|
@@ -11589,11 +11618,11 @@ var Header = function Header(_ref) {
|
|
|
11589
11618
|
}))) : null), showDivider ? /*#__PURE__*/React__default.createElement(Divider, null) : null);
|
|
11590
11619
|
};
|
|
11591
11620
|
|
|
11592
|
-
var _excluded$
|
|
11621
|
+
var _excluded$z = ["scrollEventThrottle"];
|
|
11593
11622
|
var BottomSheetScrollView = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
11594
11623
|
var _ref$scrollEventThrot = _ref.scrollEventThrottle,
|
|
11595
11624
|
scrollEventThrottle = _ref$scrollEventThrot === void 0 ? 100 : _ref$scrollEventThrot,
|
|
11596
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
11625
|
+
props = _objectWithoutProperties(_ref, _excluded$z);
|
|
11597
11626
|
var _useContext = useContext(BottomSheetContext),
|
|
11598
11627
|
setInternalShowDivider = _useContext.setInternalShowDivider;
|
|
11599
11628
|
var onScrollBeginDrag = useCallback(function (e) {
|
|
@@ -14715,12 +14744,12 @@ var Indicator = index$c(View)(function (_ref3) {
|
|
|
14715
14744
|
};
|
|
14716
14745
|
});
|
|
14717
14746
|
|
|
14718
|
-
var _excluded$
|
|
14747
|
+
var _excluded$y = ["intent", "children"];
|
|
14719
14748
|
var DataCard = function DataCard(_ref) {
|
|
14720
14749
|
var _ref$intent = _ref.intent,
|
|
14721
14750
|
intent = _ref$intent === void 0 ? 'info' : _ref$intent,
|
|
14722
14751
|
children = _ref.children,
|
|
14723
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
14752
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$y);
|
|
14724
14753
|
return /*#__PURE__*/React__default.createElement(StyledDataCard, nativeProps, /*#__PURE__*/React__default.createElement(Indicator, {
|
|
14725
14754
|
themeIntent: intent,
|
|
14726
14755
|
testID: "data-card-indicator"
|
|
@@ -14739,13 +14768,13 @@ var StyledCard$1 = index$c(View)(function (_ref) {
|
|
|
14739
14768
|
});
|
|
14740
14769
|
});
|
|
14741
14770
|
|
|
14742
|
-
var _excluded$
|
|
14771
|
+
var _excluded$x = ["intent", "children", "variant"];
|
|
14743
14772
|
var Card$1 = function Card(_ref) {
|
|
14744
14773
|
var intent = _ref.intent,
|
|
14745
14774
|
children = _ref.children,
|
|
14746
14775
|
_ref$variant = _ref.variant,
|
|
14747
14776
|
variant = _ref$variant === void 0 ? 'basic' : _ref$variant,
|
|
14748
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
14777
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$x);
|
|
14749
14778
|
return /*#__PURE__*/React__default.createElement(StyledCard$1, _extends$1({}, nativeProps, {
|
|
14750
14779
|
themeIntent: intent,
|
|
14751
14780
|
themeVariant: variant
|
|
@@ -15012,7 +15041,7 @@ var CardCarousel = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
15012
15041
|
});
|
|
15013
15042
|
CardCarousel.displayName = 'CardCarousel';
|
|
15014
15043
|
|
|
15015
|
-
var _excluded$
|
|
15044
|
+
var _excluded$w = ["rounded", "size", "testID", "style"];
|
|
15016
15045
|
/**
|
|
15017
15046
|
* @deprecated Image component will soon be deprecated. Please use `Image` from `react-native` instead.
|
|
15018
15047
|
*/
|
|
@@ -15023,7 +15052,7 @@ var Image = function Image(_ref) {
|
|
|
15023
15052
|
size = _ref$size === void 0 ? '6xlarge' : _ref$size,
|
|
15024
15053
|
testID = _ref.testID,
|
|
15025
15054
|
style = _ref.style,
|
|
15026
|
-
imageNativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
15055
|
+
imageNativeProps = _objectWithoutProperties(_ref, _excluded$w);
|
|
15027
15056
|
useDeprecation('Image component will soon be deprecated. Please use `Image` from `react-native` instead.');
|
|
15028
15057
|
var theme = useTheme();
|
|
15029
15058
|
var imageSize = theme.__hd__.image.sizes[size];
|
|
@@ -15158,7 +15187,7 @@ var CarouselItem = function CarouselItem(_ref) {
|
|
|
15158
15187
|
}, heading), !!body && /*#__PURE__*/React__default.createElement(Typography.Body, null, body)));
|
|
15159
15188
|
};
|
|
15160
15189
|
|
|
15161
|
-
var _excluded$
|
|
15190
|
+
var _excluded$v = ["items", "onItemIndexChange", "renderActions", "selectedItemIndex", "style", "shouldShowPagination", "testID", "pageControlPosition"];
|
|
15162
15191
|
function useStateFromProp(initialValue) {
|
|
15163
15192
|
var _useState = useState(initialValue),
|
|
15164
15193
|
_useState2 = _slicedToArray(_useState, 2),
|
|
@@ -15185,7 +15214,7 @@ var Carousel = function Carousel(_ref) {
|
|
|
15185
15214
|
testID = _ref.testID,
|
|
15186
15215
|
_ref$pageControlPosit = _ref.pageControlPosition,
|
|
15187
15216
|
pageControlPosition = _ref$pageControlPosit === void 0 ? 'top' : _ref$pageControlPosit,
|
|
15188
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
15217
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$v);
|
|
15189
15218
|
useDeprecation("shouldShowPagination prop has been deprecated", shouldShowPagination !== noop$2);
|
|
15190
15219
|
useDeprecation("The use of 'pageControlPosition == bottom' has been deprecated", pageControlPosition === 'bottom');
|
|
15191
15220
|
var theme = useTheme();
|
|
@@ -20456,7 +20485,7 @@ var StyledChipIcon = index$c(Icon)(function (_ref2) {
|
|
|
20456
20485
|
};
|
|
20457
20486
|
});
|
|
20458
20487
|
|
|
20459
|
-
var _excluded$
|
|
20488
|
+
var _excluded$u = ["label", "variant", "selected", "icon", "onPress", "showSelectedIcon", "accessible", "onBlur", "onFocus"];
|
|
20460
20489
|
var getChipLabel = function getChipLabel(label) {
|
|
20461
20490
|
if (typeof label === 'string') {
|
|
20462
20491
|
return /*#__PURE__*/React__default.createElement(Typography.Body, {
|
|
@@ -20492,7 +20521,7 @@ var Chip = function Chip(_ref) {
|
|
|
20492
20521
|
accessible = _ref.accessible,
|
|
20493
20522
|
onBlur = _ref.onBlur,
|
|
20494
20523
|
onFocus = _ref.onFocus,
|
|
20495
|
-
otherProps = _objectWithoutProperties(_ref, _excluded$
|
|
20524
|
+
otherProps = _objectWithoutProperties(_ref, _excluded$u);
|
|
20496
20525
|
useDeprecation('Chip variant `outlined` and `filled` are deprecated.', variant === 'outlined' || variant === 'filled');
|
|
20497
20526
|
var renamedVariant = getChipVariant(variant);
|
|
20498
20527
|
var shouldShowSelectedIcon = (renamedVariant === 'selection' || renamedVariant === 'compact-outlined') && selected && showSelectedIcon;
|
|
@@ -20883,7 +20912,7 @@ var StyledErrorAndMaxLengthContainer = index$c(View)(function (_ref14) {
|
|
|
20883
20912
|
};
|
|
20884
20913
|
});
|
|
20885
20914
|
|
|
20886
|
-
var _excluded$
|
|
20915
|
+
var _excluded$t = ["label", "prefix", "suffix", "style", "textStyle", "testID", "accessibilityLabelledBy", "error", "required", "editable", "disabled", "loading", "maxLength", "hideCharacterCount", "helpText", "value", "defaultValue", "renderInputValue", "allowFontScaling", "variant"];
|
|
20887
20916
|
var getState$3 = function getState(_ref) {
|
|
20888
20917
|
var disabled = _ref.disabled,
|
|
20889
20918
|
error = _ref.error,
|
|
@@ -20999,7 +21028,7 @@ var TextInput = /*#__PURE__*/forwardRef(function (_ref8, ref) {
|
|
|
20999
21028
|
allowFontScaling = _ref8$allowFontScalin === void 0 ? false : _ref8$allowFontScalin,
|
|
21000
21029
|
_ref8$variant = _ref8.variant,
|
|
21001
21030
|
variant = _ref8$variant === void 0 ? 'text' : _ref8$variant,
|
|
21002
|
-
nativeProps = _objectWithoutProperties(_ref8, _excluded$
|
|
21031
|
+
nativeProps = _objectWithoutProperties(_ref8, _excluded$t);
|
|
21003
21032
|
var displayText = getDisplayText(value, defaultValue);
|
|
21004
21033
|
var isEmptyValue = displayText.length === 0;
|
|
21005
21034
|
var _React$useState = React__default.useState(0),
|
|
@@ -21746,11 +21775,11 @@ var DatePickerIOS = function DatePickerIOS(_ref) {
|
|
|
21746
21775
|
}));
|
|
21747
21776
|
};
|
|
21748
21777
|
|
|
21749
|
-
var _excluded$
|
|
21778
|
+
var _excluded$s = ["variant"];
|
|
21750
21779
|
var DatePicker = function DatePicker(_ref) {
|
|
21751
21780
|
var _ref$variant = _ref.variant,
|
|
21752
21781
|
variant = _ref$variant === void 0 ? 'default' : _ref$variant,
|
|
21753
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
21782
|
+
props = _objectWithoutProperties(_ref, _excluded$s);
|
|
21754
21783
|
if (variant === 'calendar') {
|
|
21755
21784
|
return /*#__PURE__*/React__default.createElement(DatePickerCalendar, props);
|
|
21756
21785
|
}
|
|
@@ -22122,7 +22151,7 @@ var DragableDrawer = function DragableDrawer(_ref) {
|
|
|
22122
22151
|
}, /*#__PURE__*/React__default.createElement(StyledHandlerContainer$1, panHandlers, /*#__PURE__*/React__default.createElement(StyledHandler, null)), children)));
|
|
22123
22152
|
};
|
|
22124
22153
|
|
|
22125
|
-
var _excluded$
|
|
22154
|
+
var _excluded$r = ["onScroll", "onScrollEndDrag", "onMomentumScrollEnd", "scrollEventThrottle", "children"];
|
|
22126
22155
|
// scrollY tolerance: treat anything within this many pixels of the top as
|
|
22127
22156
|
// "at scroll top" to handle fractional pixels and throttled scroll events.
|
|
22128
22157
|
var SCROLL_TOP_THRESHOLD_PX = 5;
|
|
@@ -22149,7 +22178,7 @@ var DragableScrollView = function DragableScrollView(_ref) {
|
|
|
22149
22178
|
_ref$scrollEventThrot = _ref.scrollEventThrottle,
|
|
22150
22179
|
scrollEventThrottle = _ref$scrollEventThrot === void 0 ? DEFAULT_SCROLL_EVENT_THROTTLE : _ref$scrollEventThrot,
|
|
22151
22180
|
children = _ref.children,
|
|
22152
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
22181
|
+
props = _objectWithoutProperties(_ref, _excluded$r);
|
|
22153
22182
|
var _useDragableDrawerCon = useDragableDrawerContext(),
|
|
22154
22183
|
isAtMaxHeight = _useDragableDrawerCon.isAtMaxHeight,
|
|
22155
22184
|
scrollYRef = _useDragableDrawerCon.scrollYRef,
|
|
@@ -24013,7 +24042,7 @@ var StyledErrorDescription = index$c(Typography.Body)(function (_ref9) {
|
|
|
24013
24042
|
};
|
|
24014
24043
|
});
|
|
24015
24044
|
|
|
24016
|
-
var _excluded$
|
|
24045
|
+
var _excluded$q = ["variant", "title", "description", "image", "testID", "ctaText", "onCtaPress", "secondaryCtaText", "onSecondaryCtaPress", "icon"],
|
|
24017
24046
|
_excluded2 = ["visible", "variant", "title", "description", "image", "testID", "ctaText", "onCtaPress", "secondaryCtaText", "onSecondaryCtaPress"];
|
|
24018
24047
|
var renderImage$1 = function renderImage(image) {
|
|
24019
24048
|
if (/*#__PURE__*/isValidElement(image)) {
|
|
@@ -24054,7 +24083,7 @@ var ErrorPage = function ErrorPage(_ref2) {
|
|
|
24054
24083
|
secondaryCtaText = _ref2.secondaryCtaText,
|
|
24055
24084
|
onSecondaryCtaPress = _ref2.onSecondaryCtaPress,
|
|
24056
24085
|
icon = _ref2.icon,
|
|
24057
|
-
nativeProps = _objectWithoutProperties(_ref2, _excluded$
|
|
24086
|
+
nativeProps = _objectWithoutProperties(_ref2, _excluded$q);
|
|
24058
24087
|
var showCta = ctaText && onCtaPress !== undefined;
|
|
24059
24088
|
var showSecondaryCta = secondaryCtaText && onSecondaryCtaPress !== undefined;
|
|
24060
24089
|
var showButtonContainer = showCta || showSecondaryCta;
|
|
@@ -24283,13 +24312,13 @@ var ActionItem = function ActionItem(_ref) {
|
|
|
24283
24312
|
})), /*#__PURE__*/React__default.createElement(StyledActionItemText, null, title))));
|
|
24284
24313
|
};
|
|
24285
24314
|
|
|
24286
|
-
var _excluded$
|
|
24315
|
+
var _excluded$p = ["active"];
|
|
24287
24316
|
var AnimatedIcons = Animated.createAnimatedComponent(/*#__PURE__*/React__default.forwardRef(function (props, _) {
|
|
24288
24317
|
return /*#__PURE__*/React__default.createElement(StyledFABIcon, props);
|
|
24289
24318
|
}));
|
|
24290
24319
|
var AnimatedFABIcon = function AnimatedFABIcon(_ref) {
|
|
24291
24320
|
var active = _ref.active,
|
|
24292
|
-
iconProps = _objectWithoutProperties(_ref, _excluded$
|
|
24321
|
+
iconProps = _objectWithoutProperties(_ref, _excluded$p);
|
|
24293
24322
|
var rotateAnimation = useRef(new Animated.Value(active ? 1 : 0));
|
|
24294
24323
|
useEffect(function () {
|
|
24295
24324
|
var animation = Animated.spring(rotateAnimation.current, {
|
|
@@ -24695,11 +24724,11 @@ var StyledFAB = index$c(FABWithTitleStyle)(function (_ref) {
|
|
|
24695
24724
|
};
|
|
24696
24725
|
});
|
|
24697
24726
|
|
|
24698
|
-
var _excluded$
|
|
24727
|
+
var _excluded$o = ["fabConfig", "onCancel"];
|
|
24699
24728
|
var Pair = function Pair(_ref) {
|
|
24700
24729
|
var fabConfig = _ref.fabConfig,
|
|
24701
24730
|
onCancel = _ref.onCancel,
|
|
24702
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
24731
|
+
props = _objectWithoutProperties(_ref, _excluded$o);
|
|
24703
24732
|
var icon = fabConfig.icon,
|
|
24704
24733
|
title = fabConfig.title,
|
|
24705
24734
|
onPress = fabConfig.onPress,
|
|
@@ -25434,11 +25463,11 @@ var StyledFocusIcon = index$c(Icon)(function (_ref7) {
|
|
|
25434
25463
|
};
|
|
25435
25464
|
});
|
|
25436
25465
|
|
|
25437
|
-
var _excluded$
|
|
25466
|
+
var _excluded$n = ["style", "testID"];
|
|
25438
25467
|
var MapPinFocussed = function MapPinFocussed(_ref) {
|
|
25439
25468
|
var style = _ref.style,
|
|
25440
25469
|
testID = _ref.testID,
|
|
25441
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
25470
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$n);
|
|
25442
25471
|
return /*#__PURE__*/React__default.createElement(StyledContainer$4, _extends$1({}, nativeProps, {
|
|
25443
25472
|
style: style,
|
|
25444
25473
|
testID: testID
|
|
@@ -25448,7 +25477,7 @@ var MapPinFocussed = function MapPinFocussed(_ref) {
|
|
|
25448
25477
|
}));
|
|
25449
25478
|
};
|
|
25450
25479
|
|
|
25451
|
-
var _excluded$
|
|
25480
|
+
var _excluded$m = ["style", "testID", "state", "image", "icon"];
|
|
25452
25481
|
var getBadgeIconName = function getBadgeIconName(state) {
|
|
25453
25482
|
var iconMap = {
|
|
25454
25483
|
idle: undefined,
|
|
@@ -25464,7 +25493,7 @@ var MapPin = function MapPin(_ref) {
|
|
|
25464
25493
|
state = _ref$state === void 0 ? 'idle' : _ref$state,
|
|
25465
25494
|
image = _ref.image,
|
|
25466
25495
|
icon = _ref.icon,
|
|
25467
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
25496
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$m);
|
|
25468
25497
|
var badgeIcon = getBadgeIconName(state);
|
|
25469
25498
|
return /*#__PURE__*/React__default.createElement(StyledContainer$4, _extends$1({}, nativeProps, {
|
|
25470
25499
|
style: style,
|
|
@@ -25785,7 +25814,7 @@ var THEME_INTENT_MAP = {
|
|
|
25785
25814
|
'archived-inverted': 'archivedInverted'
|
|
25786
25815
|
};
|
|
25787
25816
|
|
|
25788
|
-
var _excluded$
|
|
25817
|
+
var _excluded$l = ["value", "renderValue", "intent", "style", "testID"];
|
|
25789
25818
|
var defaultRenderValue = function defaultRenderValue(value) {
|
|
25790
25819
|
return "".concat(value, "%");
|
|
25791
25820
|
};
|
|
@@ -25798,7 +25827,7 @@ var ProgressCircle = function ProgressCircle(_ref) {
|
|
|
25798
25827
|
intent = _ref$intent === void 0 ? 'primary' : _ref$intent,
|
|
25799
25828
|
style = _ref.style,
|
|
25800
25829
|
testID = _ref.testID,
|
|
25801
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
25830
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$l);
|
|
25802
25831
|
var theme = useTheme$1();
|
|
25803
25832
|
var size = theme.__hd__.progress.sizes.circleDiameter;
|
|
25804
25833
|
var strokeWidth = theme.__hd__.progress.sizes.circleCompletenessHeight;
|
|
@@ -25868,14 +25897,14 @@ var StyledInner = index$c(Animated.View)(function (_ref2) {
|
|
|
25868
25897
|
};
|
|
25869
25898
|
});
|
|
25870
25899
|
|
|
25871
|
-
var _excluded$
|
|
25900
|
+
var _excluded$k = ["value", "intent", "style", "testID"];
|
|
25872
25901
|
var ProgressBar = function ProgressBar(_ref) {
|
|
25873
25902
|
var value = _ref.value,
|
|
25874
25903
|
_ref$intent = _ref.intent,
|
|
25875
25904
|
intent = _ref$intent === void 0 ? 'primary' : _ref$intent,
|
|
25876
25905
|
style = _ref.style,
|
|
25877
25906
|
testID = _ref.testID,
|
|
25878
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
25907
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$k);
|
|
25879
25908
|
var _useState = useState(0),
|
|
25880
25909
|
_useState2 = _slicedToArray(_useState, 2),
|
|
25881
25910
|
width = _useState2[0],
|
|
@@ -25965,7 +25994,7 @@ var StyledSingleStep = index$c(Box)(function (_ref3) {
|
|
|
25965
25994
|
};
|
|
25966
25995
|
});
|
|
25967
25996
|
|
|
25968
|
-
var _excluded$
|
|
25997
|
+
var _excluded$j = ["steps", "current", "onLayout"];
|
|
25969
25998
|
var getStepState = function getStepState(current, index) {
|
|
25970
25999
|
if (index < current) {
|
|
25971
26000
|
return 'complete';
|
|
@@ -25979,7 +26008,7 @@ var ProgressStep = function ProgressStep(_ref) {
|
|
|
25979
26008
|
var steps = _ref.steps,
|
|
25980
26009
|
current = _ref.current,
|
|
25981
26010
|
onLayout = _ref.onLayout,
|
|
25982
|
-
props = _objectWithoutProperties(_ref, _excluded$
|
|
26011
|
+
props = _objectWithoutProperties(_ref, _excluded$j);
|
|
25983
26012
|
var theme = useTheme$1();
|
|
25984
26013
|
var _React$useState = React__default.useState(0),
|
|
25985
26014
|
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
@@ -26276,7 +26305,7 @@ var StyledEmptyText = index$c(Typography.Caption)(function (_ref4) {
|
|
|
26276
26305
|
};
|
|
26277
26306
|
});
|
|
26278
26307
|
|
|
26279
|
-
var _excluded$
|
|
26308
|
+
var _excluded$i = ["data", "headerConfig", "emptyText", "legendConfig", "styleConfig", "style", "testID", "collapsable"];
|
|
26280
26309
|
var ProgressSegmentedBar = function ProgressSegmentedBar(_ref) {
|
|
26281
26310
|
var data = _ref.data,
|
|
26282
26311
|
headerConfig = _ref.headerConfig,
|
|
@@ -26286,7 +26315,7 @@ var ProgressSegmentedBar = function ProgressSegmentedBar(_ref) {
|
|
|
26286
26315
|
style = _ref.style,
|
|
26287
26316
|
testID = _ref.testID,
|
|
26288
26317
|
collapsable = _ref.collapsable,
|
|
26289
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
26318
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$i);
|
|
26290
26319
|
var values = React__default.useMemo(function () {
|
|
26291
26320
|
return data.map(function (s) {
|
|
26292
26321
|
return s.data;
|
|
@@ -26656,14 +26685,14 @@ var AnimatedSpinner = function AnimatedSpinner(_ref) {
|
|
|
26656
26685
|
}, dotProps))));
|
|
26657
26686
|
};
|
|
26658
26687
|
|
|
26659
|
-
var _excluded$
|
|
26688
|
+
var _excluded$h = ["testID", "size", "intent"];
|
|
26660
26689
|
var Spinner = function Spinner(_ref) {
|
|
26661
26690
|
var testID = _ref.testID,
|
|
26662
26691
|
_ref$size = _ref.size,
|
|
26663
26692
|
size = _ref$size === void 0 ? 'medium' : _ref$size,
|
|
26664
26693
|
_ref$intent = _ref.intent,
|
|
26665
26694
|
intent = _ref$intent === void 0 ? 'primary' : _ref$intent,
|
|
26666
|
-
nativeProps = _objectWithoutProperties(_ref, _excluded$
|
|
26695
|
+
nativeProps = _objectWithoutProperties(_ref, _excluded$h);
|
|
26667
26696
|
return /*#__PURE__*/React__default.createElement(StyledView$1, nativeProps, /*#__PURE__*/React__default.createElement(StyledSpinnerContainer, {
|
|
26668
26697
|
testID: testID
|
|
26669
26698
|
}, /*#__PURE__*/React__default.createElement(AnimatedSpinner, {
|
|
@@ -26696,7 +26725,7 @@ var SwipeableAction = function SwipeableAction(_ref) {
|
|
|
26696
26725
|
}, children);
|
|
26697
26726
|
};
|
|
26698
26727
|
|
|
26699
|
-
var _excluded$
|
|
26728
|
+
var _excluded$g = ["children", "state", "onStateChange", "leftActions", "leftActionsWidth", "rightActions", "rightActionsWidth", "variant"];
|
|
26700
26729
|
var renderActions = function renderActions(actions, width, progress, direction) {
|
|
26701
26730
|
var trans = progress.interpolate({
|
|
26702
26731
|
inputRange: [0, 1],
|
|
@@ -26725,7 +26754,7 @@ var Swipeable = function Swipeable(_ref) {
|
|
|
26725
26754
|
rightActionsWidth = _ref.rightActionsWidth,
|
|
26726
26755
|
_ref$variant = _ref.variant,
|
|
26727
26756
|
variant = _ref$variant === void 0 ? 'card' : _ref$variant,
|
|
26728
|
-
swipeableProps = _objectWithoutProperties(_ref, _excluded$
|
|
26757
|
+
swipeableProps = _objectWithoutProperties(_ref, _excluded$g);
|
|
26729
26758
|
var theme = useTheme();
|
|
26730
26759
|
var _useWindowDimensions = useWindowDimensions(),
|
|
26731
26760
|
width = _useWindowDimensions.width;
|
|
@@ -26982,6 +27011,134 @@ var SectionHeading = function SectionHeading(_ref) {
|
|
|
26982
27011
|
}, text)), rightChildren);
|
|
26983
27012
|
};
|
|
26984
27013
|
|
|
27014
|
+
var isTop = function isTop(position) {
|
|
27015
|
+
return position === 'top' || position === 'single';
|
|
27016
|
+
};
|
|
27017
|
+
var isBottom = function isBottom(position) {
|
|
27018
|
+
return position === 'bottom' || position === 'single';
|
|
27019
|
+
};
|
|
27020
|
+
var StyledRow = index$c(View)(function (_ref) {
|
|
27021
|
+
var theme = _ref.theme,
|
|
27022
|
+
themePosition = _ref.themePosition,
|
|
27023
|
+
_ref$themeMarginHoriz = _ref.themeMarginHorizontal,
|
|
27024
|
+
themeMarginHorizontal = _ref$themeMarginHoriz === void 0 ? 'medium' : _ref$themeMarginHoriz;
|
|
27025
|
+
var radius = theme.__hd__.sectionList.radii.group;
|
|
27026
|
+
var marginHorizontal = theme.__hd__.sectionList.space.marginHorizontal[themeMarginHorizontal];
|
|
27027
|
+
return {
|
|
27028
|
+
marginHorizontal: marginHorizontal,
|
|
27029
|
+
backgroundColor: theme.__hd__.sectionList.colors.groupBackground,
|
|
27030
|
+
borderTopLeftRadius: isTop(themePosition) ? radius : 0,
|
|
27031
|
+
borderTopRightRadius: isTop(themePosition) ? radius : 0,
|
|
27032
|
+
borderBottomLeftRadius: isBottom(themePosition) ? radius : 0,
|
|
27033
|
+
borderBottomRightRadius: isBottom(themePosition) ? radius : 0,
|
|
27034
|
+
overflow: 'hidden'
|
|
27035
|
+
};
|
|
27036
|
+
});
|
|
27037
|
+
var StyledDividerWrapper = index$c(View)(function (_ref2) {
|
|
27038
|
+
var theme = _ref2.theme,
|
|
27039
|
+
_ref2$themeMarginHori = _ref2.themeMarginHorizontal,
|
|
27040
|
+
themeMarginHorizontal = _ref2$themeMarginHori === void 0 ? 'medium' : _ref2$themeMarginHori;
|
|
27041
|
+
return {
|
|
27042
|
+
marginHorizontal: theme.__hd__.sectionList.space.marginHorizontal[themeMarginHorizontal],
|
|
27043
|
+
backgroundColor: theme.__hd__.sectionList.colors.groupBackground
|
|
27044
|
+
};
|
|
27045
|
+
});
|
|
27046
|
+
var StyledSectionSpacer = index$c(View)(function (_ref3) {
|
|
27047
|
+
var theme = _ref3.theme,
|
|
27048
|
+
themeCompact = _ref3.themeCompact;
|
|
27049
|
+
return {
|
|
27050
|
+
height: themeCompact ? theme.__hd__.sectionList.space.sectionSpacingCompact : theme.__hd__.sectionList.space.sectionSpacing
|
|
27051
|
+
};
|
|
27052
|
+
});
|
|
27053
|
+
var StyledSectionHeading = index$c(SectionHeading)(function (_ref4) {
|
|
27054
|
+
var theme = _ref4.theme;
|
|
27055
|
+
return {
|
|
27056
|
+
paddingLeft: theme.__hd__.sectionList.space.headingPaddingLeft,
|
|
27057
|
+
marginBottom: 0
|
|
27058
|
+
};
|
|
27059
|
+
});
|
|
27060
|
+
|
|
27061
|
+
var _excluded$f = ["sections", "marginHorizontal", "style", "testID"];
|
|
27062
|
+
var positionOf = function positionOf(index, count) {
|
|
27063
|
+
if (count === 1) return 'single';
|
|
27064
|
+
if (index === 0) return 'top';
|
|
27065
|
+
if (index === count - 1) return 'bottom';
|
|
27066
|
+
return 'middle';
|
|
27067
|
+
};
|
|
27068
|
+
// StyledRow already clips corners via overflow:hidden + its own borderRadius, so the
|
|
27069
|
+
// inner list items must not add their own rounding on top of it.
|
|
27070
|
+
var NO_RADIUS = {
|
|
27071
|
+
borderRadius: 0
|
|
27072
|
+
};
|
|
27073
|
+
var renderRow = function renderRow(row) {
|
|
27074
|
+
return row.type === 'basic-item' ? /*#__PURE__*/React__default.createElement(List$1.BasicItem, _extends$1({}, row, {
|
|
27075
|
+
style: [NO_RADIUS, row.style]
|
|
27076
|
+
})) : /*#__PURE__*/React__default.createElement(List$1.Item, _extends$1({}, row, {
|
|
27077
|
+
style: [NO_RADIUS, row.style]
|
|
27078
|
+
}));
|
|
27079
|
+
};
|
|
27080
|
+
// Factory lives at module scope — satisfies react/no-unstable-nested-components.
|
|
27081
|
+
// RN only renders ItemSeparatorComponent between adjacent items (never after the
|
|
27082
|
+
// last), which is exactly the desired divider placement for a bounded group.
|
|
27083
|
+
var createRowDivider = function createRowDivider(margin) {
|
|
27084
|
+
return function () {
|
|
27085
|
+
return /*#__PURE__*/React__default.createElement(StyledDividerWrapper, {
|
|
27086
|
+
testID: "section-list-divider-wrapper",
|
|
27087
|
+
themeMarginHorizontal: margin
|
|
27088
|
+
}, /*#__PURE__*/React__default.createElement(Divider, {
|
|
27089
|
+
testID: "section-list-divider"
|
|
27090
|
+
}));
|
|
27091
|
+
};
|
|
27092
|
+
};
|
|
27093
|
+
var SectionSpacer$1 = function SectionSpacer(_ref) {
|
|
27094
|
+
var leadingItem = _ref.leadingItem,
|
|
27095
|
+
trailingSection = _ref.trailingSection;
|
|
27096
|
+
return leadingItem && trailingSection ? /*#__PURE__*/React__default.createElement(StyledSectionSpacer, {
|
|
27097
|
+
themeCompact: !!trailingSection.hideHeading,
|
|
27098
|
+
testID: "section-list-spacer"
|
|
27099
|
+
}) : null;
|
|
27100
|
+
};
|
|
27101
|
+
function SectionList(_ref2) {
|
|
27102
|
+
var sections = _ref2.sections,
|
|
27103
|
+
_ref2$marginHorizonta = _ref2.marginHorizontal,
|
|
27104
|
+
marginHorizontal = _ref2$marginHorizonta === void 0 ? 'medium' : _ref2$marginHorizonta,
|
|
27105
|
+
style = _ref2.style,
|
|
27106
|
+
testID = _ref2.testID,
|
|
27107
|
+
rest = _objectWithoutProperties(_ref2, _excluded$f);
|
|
27108
|
+
var RowDivider = useMemo(function () {
|
|
27109
|
+
return createRowDivider(marginHorizontal);
|
|
27110
|
+
}, [marginHorizontal]);
|
|
27111
|
+
return /*#__PURE__*/React__default.createElement(SectionList$1, _extends$1({}, rest, {
|
|
27112
|
+
style: style,
|
|
27113
|
+
testID: testID,
|
|
27114
|
+
sections: sections,
|
|
27115
|
+
stickySectionHeadersEnabled: false,
|
|
27116
|
+
ItemSeparatorComponent: RowDivider,
|
|
27117
|
+
renderSectionHeader: function renderSectionHeader(_ref3) {
|
|
27118
|
+
var _section$text;
|
|
27119
|
+
var section = _ref3.section;
|
|
27120
|
+
return section.hideHeading ? null : /*#__PURE__*/React__default.createElement(StyledSectionHeading, {
|
|
27121
|
+
text: (_section$text = section.text) !== null && _section$text !== void 0 ? _section$text : '',
|
|
27122
|
+
icon: section.icon,
|
|
27123
|
+
rightChildren: section.rightChildren,
|
|
27124
|
+
intent: section.intent,
|
|
27125
|
+
size: section.size
|
|
27126
|
+
});
|
|
27127
|
+
},
|
|
27128
|
+
renderItem: function renderItem(_ref4) {
|
|
27129
|
+
var item = _ref4.item,
|
|
27130
|
+
index = _ref4.index,
|
|
27131
|
+
section = _ref4.section;
|
|
27132
|
+
return /*#__PURE__*/React__default.createElement(StyledRow, {
|
|
27133
|
+
testID: "section-list-row",
|
|
27134
|
+
themePosition: positionOf(index, section.data.length),
|
|
27135
|
+
themeMarginHorizontal: marginHorizontal
|
|
27136
|
+
}, renderRow(item));
|
|
27137
|
+
},
|
|
27138
|
+
SectionSeparatorComponent: SectionSpacer$1
|
|
27139
|
+
}));
|
|
27140
|
+
}
|
|
27141
|
+
|
|
26985
27142
|
var Footer = function Footer(_ref) {
|
|
26986
27143
|
var label = _ref.label,
|
|
26987
27144
|
onPress = _ref.onPress;
|
|
@@ -27047,7 +27204,7 @@ var StyledSearchBar = index$c(View)(function (_ref3) {
|
|
|
27047
27204
|
paddingBottom: theme.__hd__.select.space.searchBarBottomSpacing
|
|
27048
27205
|
};
|
|
27049
27206
|
});
|
|
27050
|
-
var StyledSectionList = index$c(SectionList)(function (_ref4) {
|
|
27207
|
+
var StyledSectionList = index$c(SectionList$1)(function (_ref4) {
|
|
27051
27208
|
var theme = _ref4.theme;
|
|
27052
27209
|
return {
|
|
27053
27210
|
paddingHorizontal: theme.__hd__.select.space.optionListHorizontalPadding
|
|
@@ -41968,7 +42125,7 @@ function SectionListWithFAB(_ref) {
|
|
|
41968
42125
|
var fabProps = _ref.fabProps,
|
|
41969
42126
|
props = _objectWithoutProperties(_ref, _excluded$3);
|
|
41970
42127
|
return /*#__PURE__*/React__default.createElement(AnimatedScroller, {
|
|
41971
|
-
ScrollComponent: /*#__PURE__*/React__default.createElement(SectionList, props),
|
|
42128
|
+
ScrollComponent: /*#__PURE__*/React__default.createElement(SectionList$1, props),
|
|
41972
42129
|
fabProps: fabProps
|
|
41973
42130
|
});
|
|
41974
42131
|
}
|
|
@@ -42883,4 +43040,4 @@ var InlineLoader = function InlineLoader(_ref) {
|
|
|
42883
43040
|
}, text));
|
|
42884
43041
|
};
|
|
42885
43042
|
|
|
42886
|
-
export { Accordion, Alert, AppCue, Attachment, index$b as Avatar, Badge, BottomNavigation, BottomSheet, Box, CompoundButton as Button, Calendar, Card, index$a as Carousel, Chart, index$9 as Checkbox, Chip, Collapse, ContentNavigator, index$8 as DatePicker, Divider, index$7 as Drawer, Empty, ErrorComponent as Error, FAB, FilterTrigger, FlatListWithFAB, FloatingIsland, HeroDesignProvider, Icon, Illustration, IllustrationList, Image, InlineLoader, List$1 as List, LocaleProvider, index$6 as MapPin, PageControl, PinInput, Portal, Progress, CompoundRadio as Radio, Rate, RefreshControl, index as RichTextEditor, ScrollViewWithFAB, Search, SectionHeading, SectionListWithFAB, SegmentedControl, index$4 as Select, Skeleton, Slider, Spinner, Success, index$5 as Swipeable, index$3 as Switch, index$2 as Tabs, Tag, TextInput, ThemeProvider, ThemeSwitcher, PublicTimePicker as TimePicker, Toast, index$1 as Toolbar, Typography, eBensSystemPalette, ehJobsShadowPalette, ehJobsSystemPalette, ehWorkDarkShadowPalette, ehWorkDarkSystemPalette, ehWorkShadowPalette, ehWorkSystemPalette, getTheme, jobsSystemPalette, scale, index$c as styled, swagDarkSystemPalette, swagLightJobsSystemPalette, swagSystemPalette$1 as swagLightSystemPalette, swagSystemPalette$2 as swagSystemPalette, defaultTheme as theme, useAvatarColors, useTheme, walletSystemPalette, withTheme, workSystemPalette };
|
|
43043
|
+
export { Accordion, Alert, AppCue, Attachment, index$b as Avatar, Badge, BottomNavigation, BottomSheet, Box, CompoundButton as Button, Calendar, Card, index$a as Carousel, Chart, index$9 as Checkbox, Chip, Collapse, ContentNavigator, index$8 as DatePicker, Divider, index$7 as Drawer, Empty, ErrorComponent as Error, FAB, FilterTrigger, FlatListWithFAB, FloatingIsland, HeroDesignProvider, Icon, Illustration, IllustrationList, Image, InlineLoader, List$1 as List, LocaleProvider, index$6 as MapPin, PageControl, PinInput, Portal, Progress, CompoundRadio as Radio, Rate, RefreshControl, index as RichTextEditor, ScrollViewWithFAB, Search, SectionHeading, SectionList, SectionListWithFAB, SegmentedControl, index$4 as Select, Skeleton, Slider, Spinner, Success, index$5 as Swipeable, index$3 as Switch, index$2 as Tabs, Tag, TextInput, ThemeProvider, ThemeSwitcher, PublicTimePicker as TimePicker, Toast, index$1 as Toolbar, Typography, eBensSystemPalette, ehJobsShadowPalette, ehJobsSystemPalette, ehWorkDarkShadowPalette, ehWorkDarkSystemPalette, ehWorkShadowPalette, ehWorkSystemPalette, getTheme, jobsSystemPalette, scale, index$c as styled, swagDarkSystemPalette, swagLightJobsSystemPalette, swagSystemPalette$1 as swagLightSystemPalette, swagSystemPalette$2 as swagSystemPalette, defaultTheme as theme, useAvatarColors, useTheme, walletSystemPalette, withTheme, workSystemPalette };
|