@hero-design/rn 8.136.1 → 8.136.3

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 CHANGED
@@ -1,5 +1,19 @@
1
1
  # @hero-design/rn
2
2
 
3
+ ## 8.136.3
4
+
5
+ ### Patch Changes
6
+
7
+ - [#5502](https://github.com/Thinkei/hero-design/pull/5502) [`61d504b`](https://github.com/Thinkei/hero-design/commit/61d504b72a5d2631dd66d10ce0af97cbc5cd30c7) Thanks [@ttkien](https://github.com/ttkien)! - [SectionHeading] Remove redundant icon wrapper spacing when no icon is provided
8
+
9
+ ## 8.136.2
10
+
11
+ ### Patch Changes
12
+
13
+ - [#5486](https://github.com/Thinkei/hero-design/pull/5486) [`fc7b9e0`](https://github.com/Thinkei/hero-design/commit/fc7b9e08b575111f40c79ea3445c03e286b5cb80) Thanks [@ttkien](https://github.com/ttkien)! - [List.BasicItem] Reduce horizontal padding to smallMedium
14
+
15
+ - [#5486](https://github.com/Thinkei/hero-design/pull/5486) [`fc7b9e0`](https://github.com/Thinkei/hero-design/commit/fc7b9e08b575111f40c79ea3445c03e286b5cb80) Thanks [@ttkien](https://github.com/ttkien)! - [List.Item] Reduce horizontal padding to smallMedium
16
+
3
17
  ## 8.136.1
4
18
 
5
19
  ### Patch Changes
package/es/index.js CHANGED
@@ -6478,7 +6478,8 @@ var getListTheme = function getListTheme(theme) {
6478
6478
  }
6479
6479
  };
6480
6480
  var space = {
6481
- listItemContainerPadding: theme.space.medium,
6481
+ listItemContainerVerticalPadding: theme.space.medium,
6482
+ listItemContainerHorizontalPadding: theme.space.smallMedium,
6482
6483
  leadingStatusMarginRight: theme.space.small,
6483
6484
  prefixContainerMarginRight: theme.space.small,
6484
6485
  suffixContainerMarginLeft: theme.space.small,
@@ -15743,7 +15744,8 @@ var StyledListItemContainer$1 = index$c(TouchableHighlight)(function (_ref) {
15743
15744
  var sharedStyles = {
15744
15745
  flexDirection: 'row',
15745
15746
  backgroundColor: themeSelected ? theme.__hd__.list.colors.checkedListItemContainerBackground : theme.__hd__.list.colors.listItemContainerBackground,
15746
- padding: theme.__hd__.list.space.listItemContainerPadding,
15747
+ paddingVertical: theme.__hd__.list.space.listItemContainerVerticalPadding,
15748
+ paddingHorizontal: theme.__hd__.list.space.listItemContainerHorizontalPadding,
15747
15749
  borderRadius: theme.__hd__.list.radii.item
15748
15750
  };
15749
15751
  switch (themeVariant) {
@@ -15873,7 +15875,8 @@ var StyledListItemContainer = index$c(TouchableHighlight)(function (_ref3) {
15873
15875
  alignItems: 'center',
15874
15876
  flexDirection: 'row',
15875
15877
  backgroundColor: themeSelected ? theme.__hd__.list.colors.checkedListItemContainerBackground : theme.__hd__.list.colors.listItemContainerBackground,
15876
- padding: theme.__hd__.list.space.listItemContainerPadding,
15878
+ paddingVertical: theme.__hd__.list.space.listItemContainerVerticalPadding,
15879
+ paddingHorizontal: theme.__hd__.list.space.listItemContainerHorizontalPadding,
15877
15880
  opacity: themeDisabled ? theme.__hd__.list.opacity.disabled : theme.__hd__.list.opacity.enabled,
15878
15881
  borderRadius: theme.__hd__.list.radii.basicItem
15879
15882
  };
@@ -27464,14 +27467,14 @@ var SectionHeading = function SectionHeading(_ref) {
27464
27467
  themeSize: size,
27465
27468
  style: style,
27466
27469
  testID: testID
27467
- }, /*#__PURE__*/React__default.createElement(StyledWrapper$4, null, /*#__PURE__*/React__default.createElement(StyledIconWrapper$2, null, icon !== undefined && (typeof icon === 'string' ? /*#__PURE__*/React__default.createElement(Icon, {
27470
+ }, /*#__PURE__*/React__default.createElement(StyledWrapper$4, null, icon !== undefined && /*#__PURE__*/React__default.createElement(StyledIconWrapper$2, null, typeof icon === 'string' ? /*#__PURE__*/React__default.createElement(Icon, {
27468
27471
  icon: icon,
27469
27472
  size: ICON_SIZE_MAP[size],
27470
27473
  intent: ICON_INTENT_MAP[intent]
27471
27474
  }) : (/*#__PURE__*/React__default.cloneElement(icon, _objectSpread2({
27472
27475
  size: ICON_SIZE_MAP[size],
27473
27476
  intent: ICON_INTENT_MAP[intent]
27474
- }, icon.props))))), size === 'small' ? /*#__PURE__*/React__default.createElement(Typography.Caption, {
27477
+ }, icon.props)))), size === 'small' ? /*#__PURE__*/React__default.createElement(Typography.Caption, {
27475
27478
  intent: intent
27476
27479
  }, text) : /*#__PURE__*/React__default.createElement(Typography.Body, {
27477
27480
  variant: "small",
@@ -27518,10 +27521,8 @@ var StyledSectionSpacer = index$c(View)(function (_ref3) {
27518
27521
  height: themeCompact ? theme.__hd__.sectionList.space.sectionSpacingCompact : theme.__hd__.sectionList.space.sectionSpacing
27519
27522
  };
27520
27523
  });
27521
- var StyledSectionHeading = index$c(SectionHeading)(function (_ref4) {
27522
- var theme = _ref4.theme;
27524
+ var StyledSectionHeading = index$c(SectionHeading)(function () {
27523
27525
  return {
27524
- paddingLeft: theme.__hd__.sectionList.space.headingPaddingLeft,
27525
27526
  marginBottom: 0
27526
27527
  };
27527
27528
  });
package/lib/index.js CHANGED
@@ -6507,7 +6507,8 @@ var getListTheme = function getListTheme(theme) {
6507
6507
  }
6508
6508
  };
6509
6509
  var space = {
6510
- listItemContainerPadding: theme.space.medium,
6510
+ listItemContainerVerticalPadding: theme.space.medium,
6511
+ listItemContainerHorizontalPadding: theme.space.smallMedium,
6511
6512
  leadingStatusMarginRight: theme.space.small,
6512
6513
  prefixContainerMarginRight: theme.space.small,
6513
6514
  suffixContainerMarginLeft: theme.space.small,
@@ -15772,7 +15773,8 @@ var StyledListItemContainer$1 = index$c(reactNative.TouchableHighlight)(function
15772
15773
  var sharedStyles = {
15773
15774
  flexDirection: 'row',
15774
15775
  backgroundColor: themeSelected ? theme.__hd__.list.colors.checkedListItemContainerBackground : theme.__hd__.list.colors.listItemContainerBackground,
15775
- padding: theme.__hd__.list.space.listItemContainerPadding,
15776
+ paddingVertical: theme.__hd__.list.space.listItemContainerVerticalPadding,
15777
+ paddingHorizontal: theme.__hd__.list.space.listItemContainerHorizontalPadding,
15776
15778
  borderRadius: theme.__hd__.list.radii.item
15777
15779
  };
15778
15780
  switch (themeVariant) {
@@ -15902,7 +15904,8 @@ var StyledListItemContainer = index$c(reactNative.TouchableHighlight)(function (
15902
15904
  alignItems: 'center',
15903
15905
  flexDirection: 'row',
15904
15906
  backgroundColor: themeSelected ? theme.__hd__.list.colors.checkedListItemContainerBackground : theme.__hd__.list.colors.listItemContainerBackground,
15905
- padding: theme.__hd__.list.space.listItemContainerPadding,
15907
+ paddingVertical: theme.__hd__.list.space.listItemContainerVerticalPadding,
15908
+ paddingHorizontal: theme.__hd__.list.space.listItemContainerHorizontalPadding,
15906
15909
  opacity: themeDisabled ? theme.__hd__.list.opacity.disabled : theme.__hd__.list.opacity.enabled,
15907
15910
  borderRadius: theme.__hd__.list.radii.basicItem
15908
15911
  };
@@ -27493,14 +27496,14 @@ var SectionHeading = function SectionHeading(_ref) {
27493
27496
  themeSize: size,
27494
27497
  style: style,
27495
27498
  testID: testID
27496
- }, /*#__PURE__*/React__namespace.default.createElement(StyledWrapper$4, null, /*#__PURE__*/React__namespace.default.createElement(StyledIconWrapper$2, null, icon !== undefined && (typeof icon === 'string' ? /*#__PURE__*/React__namespace.default.createElement(Icon, {
27499
+ }, /*#__PURE__*/React__namespace.default.createElement(StyledWrapper$4, null, icon !== undefined && /*#__PURE__*/React__namespace.default.createElement(StyledIconWrapper$2, null, typeof icon === 'string' ? /*#__PURE__*/React__namespace.default.createElement(Icon, {
27497
27500
  icon: icon,
27498
27501
  size: ICON_SIZE_MAP[size],
27499
27502
  intent: ICON_INTENT_MAP[intent]
27500
27503
  }) : (/*#__PURE__*/React__namespace.default.cloneElement(icon, _objectSpread2({
27501
27504
  size: ICON_SIZE_MAP[size],
27502
27505
  intent: ICON_INTENT_MAP[intent]
27503
- }, icon.props))))), size === 'small' ? /*#__PURE__*/React__namespace.default.createElement(Typography.Caption, {
27506
+ }, icon.props)))), size === 'small' ? /*#__PURE__*/React__namespace.default.createElement(Typography.Caption, {
27504
27507
  intent: intent
27505
27508
  }, text) : /*#__PURE__*/React__namespace.default.createElement(Typography.Body, {
27506
27509
  variant: "small",
@@ -27547,10 +27550,8 @@ var StyledSectionSpacer = index$c(reactNative.View)(function (_ref3) {
27547
27550
  height: themeCompact ? theme.__hd__.sectionList.space.sectionSpacingCompact : theme.__hd__.sectionList.space.sectionSpacing
27548
27551
  };
27549
27552
  });
27550
- var StyledSectionHeading = index$c(SectionHeading)(function (_ref4) {
27551
- var theme = _ref4.theme;
27553
+ var StyledSectionHeading = index$c(SectionHeading)(function () {
27552
27554
  return {
27553
- paddingLeft: theme.__hd__.sectionList.space.headingPaddingLeft,
27554
27555
  marginBottom: 0
27555
27556
  };
27556
27557
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hero-design/rn",
3
- "version": "8.136.1",
3
+ "version": "8.136.3",
4
4
  "license": "MIT",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",
@@ -20,7 +20,8 @@ const StyledListItemContainer = styled(TouchableHighlight)<{
20
20
  backgroundColor: themeSelected
21
21
  ? theme.__hd__.list.colors.checkedListItemContainerBackground
22
22
  : theme.__hd__.list.colors.listItemContainerBackground,
23
- padding: theme.__hd__.list.space.listItemContainerPadding,
23
+ paddingVertical: theme.__hd__.list.space.listItemContainerVerticalPadding,
24
+ paddingHorizontal: theme.__hd__.list.space.listItemContainerHorizontalPadding,
24
25
  opacity: themeDisabled
25
26
  ? theme.__hd__.list.opacity.disabled
26
27
  : theme.__hd__.list.opacity.enabled,
@@ -18,7 +18,9 @@ const StyledListItemContainer = styled(TouchableHighlight)<{
18
18
  backgroundColor: themeSelected
19
19
  ? theme.__hd__.list.colors.checkedListItemContainerBackground
20
20
  : theme.__hd__.list.colors.listItemContainerBackground,
21
- padding: theme.__hd__.list.space.listItemContainerPadding,
21
+ paddingVertical: theme.__hd__.list.space.listItemContainerVerticalPadding,
22
+ paddingHorizontal:
23
+ theme.__hd__.list.space.listItemContainerHorizontalPadding,
22
24
  borderRadius: theme.__hd__.list.radii.item,
23
25
  };
24
26
 
@@ -87,9 +87,9 @@ const SectionHeading = ({
87
87
  return (
88
88
  <StyledHeading themeSize={size} style={style} testID={testID}>
89
89
  <StyledWrapper>
90
- <StyledIconWrapper>
91
- {icon !== undefined &&
92
- (typeof icon === 'string' ? (
90
+ {icon !== undefined && (
91
+ <StyledIconWrapper>
92
+ {typeof icon === 'string' ? (
93
93
  <Icon
94
94
  icon={icon}
95
95
  size={ICON_SIZE_MAP[size]}
@@ -101,8 +101,9 @@ const SectionHeading = ({
101
101
  intent: ICON_INTENT_MAP[intent],
102
102
  ...icon.props,
103
103
  })
104
- ))}
105
- </StyledIconWrapper>
104
+ )}
105
+ </StyledIconWrapper>
106
+ )}
106
107
 
107
108
  {size === 'small' ? (
108
109
  <Typography.Caption intent={intent}>{text}</Typography.Caption>
@@ -52,8 +52,7 @@ const StyledSectionSpacer = styled(View)<{ themeCompact: boolean }>(
52
52
  })
53
53
  );
54
54
 
55
- const StyledSectionHeading = styled(SectionHeading)(({ theme }) => ({
56
- paddingLeft: theme.__hd__.sectionList.space.headingPaddingLeft,
55
+ const StyledSectionHeading = styled(SectionHeading)(() => ({
57
56
  marginBottom: 0,
58
57
  }));
59
58
 
@@ -15,7 +15,8 @@ const getListTheme = (theme: GlobalTheme) => {
15
15
  };
16
16
 
17
17
  const space = {
18
- listItemContainerPadding: theme.space.medium,
18
+ listItemContainerVerticalPadding: theme.space.medium,
19
+ listItemContainerHorizontalPadding: theme.space.smallMedium,
19
20
  leadingStatusMarginRight: theme.space.small,
20
21
  prefixContainerMarginRight: theme.space.small,
21
22
  suffixContainerMarginLeft: theme.space.small,
@@ -13,7 +13,8 @@ declare const getListTheme: (theme: GlobalTheme) => {
13
13
  };
14
14
  };
15
15
  space: {
16
- listItemContainerPadding: number;
16
+ listItemContainerVerticalPadding: number;
17
+ listItemContainerHorizontalPadding: number;
17
18
  leadingStatusMarginRight: number;
18
19
  prefixContainerMarginRight: number;
19
20
  suffixContainerMarginLeft: number;