dhre-ui-kit 0.0.369 → 0.0.371

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/lib/index.d.ts CHANGED
@@ -58,6 +58,7 @@ interface BottomDrawerProps {
58
58
  rightTitleVariant?: string;
59
59
  rightTitle?: string;
60
60
  rightTitleStyle?: TextStyle;
61
+ handleRightTitlePress?: () => void;
61
62
  }
62
63
 
63
64
  declare const BottomDrawer: React$1.FC<BottomDrawerProps>;
package/lib/index.js CHANGED
@@ -694,8 +694,18 @@ const styles$z = reactNative.StyleSheet.create({
694
694
  },
695
695
  title: { flex: 1, color: "#fff", textAlign: "left" },
696
696
  leftIconStyle: { marginRight: 8 },
697
- rightIconStyle: { marginLeft: 8 },
698
- rightTitle: { flex: 1, color: "#fff", textAlign: "right", marginRight: verticalScale(16) }
697
+ rightTitle: {
698
+ color: "#fff",
699
+ textAlign: "right",
700
+ marginRight: moderateScale(16)
701
+ },
702
+ rightIconStyle: {
703
+ marginLeft: 0
704
+ },
705
+ rightSideStyle: {
706
+ flexDirection: "row",
707
+ alignItems: "center"
708
+ }
699
709
  });
700
710
 
701
711
  const isIos = () => reactNative.Platform.OS === "ios" /* ios */;
@@ -728,7 +738,8 @@ const BottomDrawer = ({
728
738
  swipeDirection = "down",
729
739
  rightTitleVariant = "B2_REGULAR",
730
740
  rightTitle,
731
- rightTitleStyle
741
+ rightTitleStyle,
742
+ handleRightTitlePress
732
743
  }) => {
733
744
  return /* @__PURE__ */ React__default["default"].createElement(
734
745
  Modal__default["default"],
@@ -760,14 +771,14 @@ const BottomDrawer = ({
760
771
  text: title,
761
772
  style: { ...styles$z.title, ...titleStyle }
762
773
  }
763
- )), /* @__PURE__ */ React__default["default"].createElement(reactNative.View, null, rightTitle ? /* @__PURE__ */ React__default["default"].createElement(
774
+ )), /* @__PURE__ */ React__default["default"].createElement(reactNative.View, { style: rightTitle?.length ? styles$z.rightSideStyle : {} }, rightTitle?.length ? /* @__PURE__ */ React__default["default"].createElement(reactNative.Pressable, { onPress: handleRightTitlePress }, /* @__PURE__ */ React__default["default"].createElement(
764
775
  CustomTypography,
765
776
  {
766
777
  variant: rightTitleVariant,
767
778
  text: rightTitle,
768
779
  style: { ...styles$z.rightTitle, ...rightTitleStyle }
769
780
  }
770
- ) : null, showRightIcon && rightIcon ? React__default["default"].cloneElement(rightIcon, {
781
+ )) : null, showRightIcon && rightIcon ? React__default["default"].cloneElement(rightIcon, {
771
782
  width: moderateScale(24),
772
783
  height: moderateScale(24),
773
784
  style: styles$z.rightIconStyle,