@hero-design/rn 8.103.7 → 8.104.1-alpha.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.
Files changed (29) hide show
  1. package/.turbo/turbo-build.log +3 -3
  2. package/CHANGELOG.md +18 -0
  3. package/es/index.js +215 -18
  4. package/lib/index.js +215 -17
  5. package/package.json +1 -1
  6. package/src/components/FilterTrigger/StyledFilterTrigger.tsx +104 -0
  7. package/src/components/FilterTrigger/__tests__/__snapshots__/index.spec.tsx.snap +637 -0
  8. package/src/components/FilterTrigger/__tests__/index.spec.tsx +161 -0
  9. package/src/components/FilterTrigger/index.tsx +106 -0
  10. package/src/components/Icon/HeroIcon/index.tsx +3 -1
  11. package/src/components/Icon/__tests__/__snapshots__/index.spec.tsx.snap +45 -0
  12. package/src/components/Icon/__tests__/index.spec.tsx +1 -0
  13. package/src/components/Icon/index.tsx +2 -1
  14. package/src/components/Toolbar/StyledToolbar.tsx +0 -1
  15. package/src/components/Toolbar/__tests__/__snapshots__/ToolbarMessage.spec.tsx.snap +0 -4
  16. package/src/index.ts +2 -0
  17. package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +71 -0
  18. package/src/theme/components/filterTrigger.ts +88 -0
  19. package/src/theme/components/icon.ts +1 -0
  20. package/src/theme/getTheme.ts +3 -0
  21. package/stats/8.104.0/rn-stats.html +4842 -0
  22. package/types/components/FilterTrigger/StyledFilterTrigger.d.ts +20 -0
  23. package/types/components/FilterTrigger/index.d.ts +39 -0
  24. package/types/components/Icon/HeroIcon/index.d.ts +1 -1
  25. package/types/components/Icon/index.d.ts +1 -1
  26. package/types/index.d.ts +2 -1
  27. package/types/theme/components/filterTrigger.d.ts +72 -0
  28. package/types/theme/components/icon.d.ts +1 -0
  29. package/types/theme/getTheme.d.ts +2 -0
@@ -1,4 +1,4 @@
1
- (node:3293) ExperimentalWarning: Importing JSON modules is an experimental feature and might change at any time
1
+ (node:4176) ExperimentalWarning: Importing JSON modules is an experimental feature and might change at any time
2
2
  (Use `node --trace-warnings ...` to show where the warning was created)
3
3
  
4
4
  src/index.ts → lib/index.js, es/index.js...
@@ -15,9 +15,9 @@ node_modules/d3-selection/src/selection/index.js -> node_modules/d3-selection/sr
15
15
     ~~~~~~~~~~~~~~~~~~~
16
16
  
17
17
  (!) [plugin node-resolve] preferring built-in module 'events' over local alternative at '/home/runner/work/hero-design/hero-design/node_modules/events/events.js', pass 'preferBuiltins: false' to disable this behavior or 'preferBuiltins: true' to disable this warning.or passing a function to 'preferBuiltins' to provide more fine-grained control over which built-in modules to prefer.
18
- created lib/index.js, es/index.js in 1m 13.2s
18
+ created lib/index.js, es/index.js in 1m 11.4s
19
19
  
20
20
  /home/runner/work/hero-design/hero-design/packages/rn/src/locales/en_AU.ts, /home/runner/work/hero-design/hero-design/packages/rn/src/locales/en_CA.ts, /home/runner/work/hero-design/hero-design/packages/rn/src/locales/index.ts, /home/runner/work/hero-design/hero-design/packages/rn/src/locales/types.ts → ., ....
21
21
  (!) Generated empty chunks
22
22
  "locales/types" and "locales/types"
23
- created ., . in 20s
23
+ created ., . in 20.6s
package/CHANGELOG.md CHANGED
@@ -1,5 +1,23 @@
1
1
  # @hero-design/rn
2
2
 
3
+ ## 8.104.1-alpha.0
4
+
5
+ ### Patch Changes
6
+
7
+ - [#3497](https://github.com/Thinkei/hero-design/pull/3497) [`e92d1dab57316441e7b5054debe823328e1a1083`](https://github.com/Thinkei/hero-design/commit/e92d1dab57316441e7b5054debe823328e1a1083) Thanks [@luanlai2201](https://github.com/luanlai2201)! - [Font] replace playful font to Saiga
8
+
9
+ ## 8.104.0
10
+
11
+ ### Minor Changes
12
+
13
+ - [#4097](https://github.com/Thinkei/hero-design/pull/4097) [`1a70cbc2bc27c426c6d9ee94206fb7915ef9aa32`](https://github.com/Thinkei/hero-design/commit/1a70cbc2bc27c426c6d9ee94206fb7915ef9aa32) Thanks [@ttkien](https://github.com/ttkien)! - [FilterTrigger] Add component
14
+
15
+ - [#4097](https://github.com/Thinkei/hero-design/pull/4097) [`1a70cbc2bc27c426c6d9ee94206fb7915ef9aa32`](https://github.com/Thinkei/hero-design/commit/1a70cbc2bc27c426c6d9ee94206fb7915ef9aa32) Thanks [@ttkien](https://github.com/ttkien)! - [Icon] Add inactive intent
16
+
17
+ ### Patch Changes
18
+
19
+ - [#4097](https://github.com/Thinkei/hero-design/pull/4097) [`1a70cbc2bc27c426c6d9ee94206fb7915ef9aa32`](https://github.com/Thinkei/hero-design/commit/1a70cbc2bc27c426c6d9ee94206fb7915ef9aa32) Thanks [@ttkien](https://github.com/ttkien)! - [Toolbar] Fix TextInput layout on Toolbar message
20
+
3
21
  ## 8.103.7
4
22
 
5
23
  ### Patch Changes
package/es/index.js CHANGED
@@ -6248,7 +6248,8 @@ var getIconTheme = function getIconTheme(theme) {
6248
6248
  warning: theme.colors.warning,
6249
6249
  disabledText: theme.colors.disabledOnDefaultGlobalSurface,
6250
6250
  invertedText: theme.colors.onDarkGlobalSurface,
6251
- muted: theme.colors.mutedOnDefaultGlobalSurface
6251
+ muted: theme.colors.mutedOnDefaultGlobalSurface,
6252
+ inactive: theme.colors.inactiveOnDefaultGlobalSurface
6252
6253
  };
6253
6254
  var sizes = {
6254
6255
  xxxsmall: theme.fontSizes.small,
@@ -7378,6 +7379,85 @@ var getAppCueTheme = function getAppCueTheme(theme) {
7378
7379
  };
7379
7380
  };
7380
7381
 
7382
+ var getFilterTriggerTheme = function getFilterTriggerTheme(theme) {
7383
+ var borderWidths = {
7384
+ wrapper: {
7385
+ filled: theme.borderWidths.medium,
7386
+ outlined: theme.borderWidths.medium,
7387
+ ghost: 0
7388
+ }
7389
+ };
7390
+ var colors = {
7391
+ wrapper: {
7392
+ activeBackground: theme.colors.highlightedSurface,
7393
+ inactiveBackground: theme.colors.neutralGlobalSurface,
7394
+ background: {
7395
+ active: {
7396
+ filled: theme.colors.highlightedSurface,
7397
+ outlined: 'transparent',
7398
+ ghost: 'transparent',
7399
+ filledLabeless: theme.colors.neutralGlobalSurface
7400
+ },
7401
+ inactive: {
7402
+ filled: theme.colors.neutralGlobalSurface,
7403
+ outlined: 'transparent',
7404
+ ghost: 'transparent'
7405
+ }
7406
+ },
7407
+ border: {
7408
+ active: {
7409
+ filled: theme.colors.highlightedSurface,
7410
+ outlined: theme.colors.primaryOutline,
7411
+ ghost: 'transparent',
7412
+ filledLabeless: theme.colors.neutralGlobalSurface
7413
+ },
7414
+ inactive: {
7415
+ filled: theme.colors.neutralGlobalSurface,
7416
+ outlined: theme.colors.secondaryOutline,
7417
+ ghost: 'transparent'
7418
+ }
7419
+ }
7420
+ }
7421
+ };
7422
+ var space = {
7423
+ wrapper: {
7424
+ "default": {
7425
+ paddingHorizontal: theme.space.smallMedium,
7426
+ paddingVertical: theme.space.xsmall
7427
+ },
7428
+ labeless: {
7429
+ paddingHorizontal: theme.space.small,
7430
+ paddingVertical: theme.space.xsmall
7431
+ },
7432
+ itemGap: theme.space.xsmall
7433
+ },
7434
+ badge: {
7435
+ labelessRight: theme.space.xxsmall,
7436
+ labelessBottom: theme.space.xxsmall
7437
+ }
7438
+ };
7439
+ var radii = {
7440
+ wrapper: {
7441
+ "default": theme.radii.xxxlarge,
7442
+ labeless: theme.radii.xlarge
7443
+ }
7444
+ };
7445
+ var sizes = {
7446
+ wrapperHeight: scale(36)
7447
+ };
7448
+ var lineHeights = {
7449
+ text: theme.lineHeights.small
7450
+ };
7451
+ return {
7452
+ colors: colors,
7453
+ space: space,
7454
+ radii: radii,
7455
+ borderWidths: borderWidths,
7456
+ sizes: sizes,
7457
+ lineHeights: lineHeights
7458
+ };
7459
+ };
7460
+
7381
7461
  var getTheme = function getTheme() {
7382
7462
  var scale = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : scale$1;
7383
7463
  var systemPallete = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : swagSystemPalette$2;
@@ -7410,6 +7490,7 @@ var getTheme = function getTheme() {
7410
7490
  empty: getEmptyTheme(globalTheme),
7411
7491
  error: getErrorTheme(globalTheme),
7412
7492
  fab: getFABTheme(globalTheme),
7493
+ filterTrigger: getFilterTriggerTheme(globalTheme),
7413
7494
  icon: getIconTheme(globalTheme),
7414
7495
  image: getImageTheme(globalTheme),
7415
7496
  list: getListTheme(globalTheme),
@@ -7615,7 +7696,7 @@ var FONTWEIGHT_MAP$2 = {
7615
7696
  regular: 'regular',
7616
7697
  'semi-bold': 'semiBold'
7617
7698
  };
7618
- var StyledText$3 = index$b(Text$1)(function (_ref) {
7699
+ var StyledText$4 = index$b(Text$1)(function (_ref) {
7619
7700
  var themeFontSize = _ref.themeFontSize,
7620
7701
  themeFontWeight = _ref.themeFontWeight,
7621
7702
  themeIntent = _ref.themeIntent,
@@ -7647,7 +7728,7 @@ var Text = function Text(_ref) {
7647
7728
  allowFontScaling = _ref$allowFontScaling === void 0 ? false : _ref$allowFontScaling,
7648
7729
  nativeProps = _objectWithoutProperties(_ref, _excluded$O);
7649
7730
  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.');
7650
- return /*#__PURE__*/React__default.createElement(StyledText$3, _extends$1({}, nativeProps, {
7731
+ return /*#__PURE__*/React__default.createElement(StyledText$4, _extends$1({}, nativeProps, {
7651
7732
  themeFontSize: fontSize,
7652
7733
  themeFontWeight: fontWeight,
7653
7734
  themeIntent: intent,
@@ -8377,7 +8458,8 @@ var COLOR_INTENTS = {
8377
8458
  warning: 'warning',
8378
8459
  'disabled-text': 'disabledText',
8379
8460
  'text-inverted': 'invertedText',
8380
- muted: 'muted'
8461
+ muted: 'muted',
8462
+ inactive: 'inactive'
8381
8463
  };
8382
8464
  var StyledHeroIcon = index$b(HeroIcon)(function (_ref) {
8383
8465
  var themeIntent = _ref.themeIntent,
@@ -9104,7 +9186,7 @@ var StyledTextWrapper$1 = index$b(View)(function () {
9104
9186
  height: '100%'
9105
9187
  };
9106
9188
  });
9107
- var StyledText$2 = index$b(Typography.Body)(function (_ref2) {
9189
+ var StyledText$3 = index$b(Typography.Body)(function (_ref2) {
9108
9190
  var themeSize = _ref2.themeSize,
9109
9191
  theme = _ref2.theme;
9110
9192
  return _objectSpread2({
@@ -9159,7 +9241,7 @@ var Avatar = function Avatar(_ref) {
9159
9241
  themeIntent: intent,
9160
9242
  themeSize: size,
9161
9243
  style: style
9162
- }, (source === undefined || hasImageError) && /*#__PURE__*/React__default.createElement(StyledTextWrapper$1, null, /*#__PURE__*/React__default.createElement(StyledText$2, {
9244
+ }, (source === undefined || hasImageError) && /*#__PURE__*/React__default.createElement(StyledTextWrapper$1, null, /*#__PURE__*/React__default.createElement(StyledText$3, {
9163
9245
  themeSize: size
9164
9246
  }, title)), source !== undefined && /*#__PURE__*/React__default.createElement(StyledImage$1, {
9165
9247
  resizeMode: "cover",
@@ -9684,7 +9766,7 @@ var StyledView$2 = index$b(Animated.View)(function (_ref) {
9684
9766
  borderColor: themeVariant === 'outlined' ? theme.__hd__.badge.colors.border : theme.__hd__.badge.colors[themeIntent]
9685
9767
  };
9686
9768
  });
9687
- var StyledText$1 = index$b(Typography.Caption)(function (_ref2) {
9769
+ var StyledText$2 = index$b(Typography.Caption)(function (_ref2) {
9688
9770
  var theme = _ref2.theme,
9689
9771
  themeSize = _ref2.themeSize;
9690
9772
  return {
@@ -9874,7 +9956,7 @@ var Badge = function Badge(_ref) {
9874
9956
  icon: icon,
9875
9957
  themeSize: size,
9876
9958
  intent: "text-inverted"
9877
- }) : /*#__PURE__*/React__default.createElement(StyledText$1, {
9959
+ }) : /*#__PURE__*/React__default.createElement(StyledText$2, {
9878
9960
  themeSize: size
9879
9961
  }, content));
9880
9962
  };
@@ -23671,7 +23753,7 @@ var StyledContent = index$b(View)(function (_ref2) {
23671
23753
  alignItems: 'center'
23672
23754
  };
23673
23755
  });
23674
- var StyledBadge$1 = index$b(View)(function (_ref3) {
23756
+ var StyledBadge$2 = index$b(View)(function (_ref3) {
23675
23757
  var theme = _ref3.theme;
23676
23758
  return {
23677
23759
  right: theme.__hd__.mapPin.space.iconRight,
@@ -23759,7 +23841,7 @@ var MapPin = function MapPin(_ref) {
23759
23841
  icon: icon,
23760
23842
  size: "xsmall",
23761
23843
  testID: testID ? "".concat(testID, "-icon") : undefined
23762
- })), badgeIcon && /*#__PURE__*/React__default.createElement(StyledBadge$1, {
23844
+ })), badgeIcon && /*#__PURE__*/React__default.createElement(StyledBadge$2, {
23763
23845
  testID: testID ? "".concat(testID, "-badge") : undefined
23764
23846
  }, /*#__PURE__*/React__default.createElement(StyledBadgeIcon, {
23765
23847
  icon: badgeIcon,
@@ -26699,7 +26781,7 @@ var StyledView = index$b(View)(function (_ref) {
26699
26781
  paddingHorizontal: theme.__hd__.tag.space.horizontalPadding
26700
26782
  };
26701
26783
  });
26702
- var StyledText = index$b(Typography.Caption)(function (_ref2) {
26784
+ var StyledText$1 = index$b(Typography.Caption)(function (_ref2) {
26703
26785
  var themeIntent = _ref2.themeIntent,
26704
26786
  theme = _ref2.theme;
26705
26787
  return {
@@ -26725,7 +26807,7 @@ var Tag = function Tag(_ref) {
26725
26807
  themeIntent: intent,
26726
26808
  style: style,
26727
26809
  testID: testID
26728
- }), typeof content === 'string' ? /*#__PURE__*/React__default.createElement(StyledText, {
26810
+ }), typeof content === 'string' ? /*#__PURE__*/React__default.createElement(StyledText$1, {
26729
26811
  themeIntent: intent,
26730
26812
  fontWeight: "semi-bold"
26731
26813
  }, content) : content);
@@ -27016,8 +27098,7 @@ var StyledInputContainer$1 = index$b(View)(function (_ref8) {
27016
27098
  backgroundColor: theme.__hd__.toolbar.colors.inputContainerBackground,
27017
27099
  borderRadius: theme.__hd__.toolbar.radii.messageContainer,
27018
27100
  height: theme.__hd__.toolbar.sizes.messageInputHeight,
27019
- paddingHorizontal: theme.__hd__.toolbar.space.messageInputPaddingHorizontal,
27020
- paddingVertical: theme.__hd__.toolbar.space.messageInputPaddingVertical
27101
+ paddingHorizontal: theme.__hd__.toolbar.space.messageInputPaddingHorizontal
27021
27102
  };
27022
27103
  });
27023
27104
  var StyledInput$1 = index$b(TextInput$1)(function (_ref9) {
@@ -46577,7 +46658,7 @@ var StyledHandlerContainer = index$b(View)(function (_ref5) {
46577
46658
  paddingVertical: theme.__hd__.search.space.inputVerticalPadding
46578
46659
  };
46579
46660
  });
46580
- var StyledBadge = index$b(Badge$1)(function (_ref6) {
46661
+ var StyledBadge$1 = index$b(Badge$1)(function (_ref6) {
46581
46662
  var theme = _ref6.theme;
46582
46663
  return {
46583
46664
  position: 'absolute',
@@ -46779,12 +46860,12 @@ var renderBadge = function renderBadge(props) {
46779
46860
  var content = props.content,
46780
46861
  icon = props.icon,
46781
46862
  rest = _objectWithoutProperties(props, _excluded$1);
46782
- if (content) return /*#__PURE__*/React__default.createElement(StyledBadge, _extends$1({
46863
+ if (content) return /*#__PURE__*/React__default.createElement(StyledBadge$1, _extends$1({
46783
46864
  intent: "primary",
46784
46865
  content: content,
46785
46866
  size: "small"
46786
46867
  }, rest));
46787
- if (icon) return /*#__PURE__*/React__default.createElement(StyledBadge, _extends$1({
46868
+ if (icon) return /*#__PURE__*/React__default.createElement(StyledBadge$1, _extends$1({
46788
46869
  intent: "primary",
46789
46870
  icon: icon,
46790
46871
  size: "small"
@@ -46894,4 +46975,120 @@ var FloatingIsland = function FloatingIsland(_ref2) {
46894
46975
  }));
46895
46976
  };
46896
46977
 
46897
- export { Accordion, Alert, AppCue, Attachment, index$a as Avatar, Badge$1 as Badge, BottomNavigation, BottomSheet$1 as BottomSheet, Box, CompoundButton as Button, Calendar$1 as Calendar, Card$1 as Card, index$9 as Carousel, Chart, Checkbox, Chip, Collapse, ContentNavigator, index$8 as DatePicker, Divider, index$7 as Drawer, Empty, ErrorComponent as Error, FAB, FlatListWithFAB, FloatingIsland, HeroDesignProvider, Icon, Image, List$1 as List, LocaleProvider, index$6 as MapPin, PageControl, PinInput, Portal$1 as Portal, Progress, CompoundRadio as Radio, Rate, RefreshControl, index as RichTextEditor, ScrollViewWithFAB, Search, SectionHeading, SectionListWithFAB, 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, ehJobsSystemPalette, ehWorkDarkSystemPalette, ehWorkSystemPalette, getTheme, jobsSystemPalette, scale, index$b as styled, swagDarkSystemPalette, swagLightJobsSystemPalette, swagSystemPalette$1 as swagLightSystemPalette, swagSystemPalette$2 as swagSystemPalette, defaultTheme as theme, useAvatarColors, useTheme, walletSystemPalette, withTheme, workSystemPalette };
46978
+ var getBackgroundColor = function getBackgroundColor(theme, themeIsActive, themeHasLabel, themeVariant) {
46979
+ var colors = theme.__hd__.filterTrigger.colors;
46980
+ if (themeIsActive && !themeHasLabel && themeVariant === 'filled') {
46981
+ return colors.wrapper.background.active.filledLabeless;
46982
+ }
46983
+ var state = themeIsActive ? 'active' : 'inactive';
46984
+ return colors.wrapper.background[state][themeVariant];
46985
+ };
46986
+ var getBorderStyles = function getBorderStyles(theme, themeIsActive, themeHasLabel, themeVariant) {
46987
+ var _theme$__hd__$filterT = theme.__hd__.filterTrigger,
46988
+ colors = _theme$__hd__$filterT.colors,
46989
+ borderWidths = _theme$__hd__$filterT.borderWidths,
46990
+ radii = _theme$__hd__$filterT.radii;
46991
+ var borderColor;
46992
+ if (themeIsActive && !themeHasLabel && themeVariant === 'filled') {
46993
+ borderColor = colors.wrapper.border.active.filledLabeless;
46994
+ } else {
46995
+ var state = themeIsActive ? 'active' : 'inactive';
46996
+ borderColor = colors.wrapper.border[state][themeVariant];
46997
+ }
46998
+ return {
46999
+ borderWidth: borderWidths.wrapper[themeVariant],
47000
+ borderColor: borderColor,
47001
+ borderRadius: themeHasLabel ? radii.wrapper["default"] : radii.wrapper.labeless
47002
+ };
47003
+ };
47004
+ var getSpacingStyles = function getSpacingStyles(theme, themeHasLabel) {
47005
+ var space = theme.__hd__.filterTrigger.space;
47006
+ var paddingConfig = themeHasLabel ? space.wrapper["default"] : space.wrapper.labeless;
47007
+ return {
47008
+ gap: space.wrapper.itemGap,
47009
+ paddingHorizontal: paddingConfig.paddingHorizontal,
47010
+ paddingVertical: paddingConfig.paddingVertical
47011
+ };
47012
+ };
47013
+ var StyledFilterWrapper = index$b(TouchableOpacity)(function (_ref) {
47014
+ var theme = _ref.theme,
47015
+ themeActive = _ref.themeActive,
47016
+ themeVariant = _ref.themeVariant,
47017
+ themeHasLabel = _ref.themeHasLabel;
47018
+ return _objectSpread2(_objectSpread2({
47019
+ position: 'relative',
47020
+ flexDirection: 'row',
47021
+ alignItems: 'center',
47022
+ justifyContent: 'center',
47023
+ alignSelf: 'flex-start',
47024
+ height: theme.__hd__.filterTrigger.sizes.wrapperHeight,
47025
+ backgroundColor: getBackgroundColor(theme, themeActive, themeHasLabel, themeVariant)
47026
+ }, getBorderStyles(theme, themeActive, themeHasLabel, themeVariant)), getSpacingStyles(theme, themeHasLabel));
47027
+ });
47028
+ var StyledBadge = index$b(Badge$1)(function (_ref2) {
47029
+ var theme = _ref2.theme,
47030
+ themeHasLabel = _ref2.themeHasLabel;
47031
+ return _objectSpread2({
47032
+ position: 'absolute'
47033
+ }, themeHasLabel ? {
47034
+ right: 0,
47035
+ bottom: 0
47036
+ } : {
47037
+ right: -theme.__hd__.filterTrigger.space.badge.labelessRight,
47038
+ bottom: -theme.__hd__.filterTrigger.space.badge.labelessBottom
47039
+ });
47040
+ });
47041
+ var StyledText = index$b(Typography.Body)(function (_ref3) {
47042
+ var theme = _ref3.theme;
47043
+ return {
47044
+ lineHeight: theme.__hd__.filterTrigger.lineHeights.text,
47045
+ textAlignVertical: 'center',
47046
+ includeFontPadding: false
47047
+ };
47048
+ });
47049
+
47050
+ var FilterTrigger = function FilterTrigger(_ref) {
47051
+ var label = _ref.label,
47052
+ _ref$active = _ref.active,
47053
+ active = _ref$active === void 0 ? false : _ref$active,
47054
+ _ref$filterCount = _ref.filterCount,
47055
+ filterCount = _ref$filterCount === void 0 ? 0 : _ref$filterCount,
47056
+ _ref$variant = _ref.variant,
47057
+ variant = _ref$variant === void 0 ? 'filled' : _ref$variant,
47058
+ suffix = _ref.suffix,
47059
+ onPress = _ref.onPress,
47060
+ testID = _ref.testID,
47061
+ style = _ref.style;
47062
+ var shouldShowBadge = filterCount > 0 && active;
47063
+ var iconIntent = active ? 'text' : 'inactive';
47064
+ var typographyVariant = active ? 'small-bold' : 'small';
47065
+ return /*#__PURE__*/React__default.createElement(StyledFilterWrapper, {
47066
+ testID: testID,
47067
+ style: style,
47068
+ themeActive: active,
47069
+ themeVariant: variant,
47070
+ onPress: onPress,
47071
+ themeHasLabel: !!label
47072
+ }, label ? /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(StyledText, {
47073
+ variant: typographyVariant
47074
+ }, label), shouldShowBadge && /*#__PURE__*/React__default.createElement(Badge$1, {
47075
+ content: filterCount,
47076
+ size: "small"
47077
+ }), suffix && /*#__PURE__*/React__default.createElement(Icon, {
47078
+ icon: suffix,
47079
+ size: "xxxsmall",
47080
+ intent: iconIntent,
47081
+ testID: "".concat(testID, "-suffix")
47082
+ })) : /*#__PURE__*/React__default.createElement(React__default.Fragment, null, suffix && /*#__PURE__*/React__default.createElement(Icon, {
47083
+ icon: suffix,
47084
+ size: "xsmall",
47085
+ intent: iconIntent,
47086
+ testID: "".concat(testID, "-suffix")
47087
+ }), shouldShowBadge && /*#__PURE__*/React__default.createElement(StyledBadge, {
47088
+ content: filterCount,
47089
+ size: "small",
47090
+ themeHasLabel: !!label
47091
+ })));
47092
+ };
47093
+
47094
+ export { Accordion, Alert, AppCue, Attachment, index$a as Avatar, Badge$1 as Badge, BottomNavigation, BottomSheet$1 as BottomSheet, Box, CompoundButton as Button, Calendar$1 as Calendar, Card$1 as Card, index$9 as Carousel, Chart, Checkbox, Chip, Collapse, ContentNavigator, index$8 as DatePicker, Divider, index$7 as Drawer, Empty, ErrorComponent as Error, FAB, FilterTrigger, FlatListWithFAB, FloatingIsland, HeroDesignProvider, Icon, Image, List$1 as List, LocaleProvider, index$6 as MapPin, PageControl, PinInput, Portal$1 as Portal, Progress, CompoundRadio as Radio, Rate, RefreshControl, index as RichTextEditor, ScrollViewWithFAB, Search, SectionHeading, SectionListWithFAB, 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, ehJobsSystemPalette, ehWorkDarkSystemPalette, ehWorkSystemPalette, getTheme, jobsSystemPalette, scale, index$b as styled, swagDarkSystemPalette, swagLightJobsSystemPalette, swagSystemPalette$1 as swagLightSystemPalette, swagSystemPalette$2 as swagSystemPalette, defaultTheme as theme, useAvatarColors, useTheme, walletSystemPalette, withTheme, workSystemPalette };