dhre-ui-kit 0.0.196 → 0.0.198
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 +2 -0
- package/lib/index.js +17 -6
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +17 -6
- package/lib/index.mjs.map +1 -1
- package/package.json +1 -1
package/lib/index.d.ts
CHANGED
|
@@ -101,6 +101,7 @@ interface CheckBoxProps {
|
|
|
101
101
|
titleVariant?: string;
|
|
102
102
|
titleStyle?: TextStyle;
|
|
103
103
|
containerStyle?: ViewStyle;
|
|
104
|
+
onPress?: () => void;
|
|
104
105
|
}
|
|
105
106
|
|
|
106
107
|
declare const Checkbox: React$1.FC<CheckBoxProps>;
|
|
@@ -511,6 +512,7 @@ interface ContactModalProps {
|
|
|
511
512
|
onClose: () => void;
|
|
512
513
|
isMailOpen: boolean;
|
|
513
514
|
data: string;
|
|
515
|
+
emailSubject: string;
|
|
514
516
|
}
|
|
515
517
|
declare const _default$b: (props: ContactModalProps) => React$1.JSX.Element;
|
|
516
518
|
|
package/lib/index.js
CHANGED
|
@@ -970,7 +970,8 @@ const Checkbox = ({
|
|
|
970
970
|
uncheckedIcon,
|
|
971
971
|
titleVariant = "L1_REGULAR",
|
|
972
972
|
titleStyle,
|
|
973
|
-
containerStyle
|
|
973
|
+
containerStyle,
|
|
974
|
+
onPress
|
|
974
975
|
}) => {
|
|
975
976
|
const [checked, setChecked] = React.useState(isChecked || false);
|
|
976
977
|
React.useEffect(() => {
|
|
@@ -1000,7 +1001,8 @@ const Checkbox = ({
|
|
|
1000
1001
|
{
|
|
1001
1002
|
variant: titleVariant,
|
|
1002
1003
|
text: labelName,
|
|
1003
|
-
style: titleStyle
|
|
1004
|
+
style: titleStyle,
|
|
1005
|
+
onPress
|
|
1004
1006
|
}
|
|
1005
1007
|
)
|
|
1006
1008
|
));
|
|
@@ -2606,7 +2608,8 @@ const ContactModal = ({
|
|
|
2606
2608
|
visible,
|
|
2607
2609
|
onClose,
|
|
2608
2610
|
isMailOpen,
|
|
2609
|
-
data
|
|
2611
|
+
data,
|
|
2612
|
+
emailSubject
|
|
2610
2613
|
}) => {
|
|
2611
2614
|
const handleCall = () => {
|
|
2612
2615
|
if (reactNative.Platform.OS === "ios") {
|
|
@@ -2618,11 +2621,11 @@ const ContactModal = ({
|
|
|
2618
2621
|
};
|
|
2619
2622
|
const openEmail = (recipient) => {
|
|
2620
2623
|
const mailtoUrl = `mailto:${recipient}?subject=${encodeURIComponent(
|
|
2621
|
-
|
|
2624
|
+
emailSubject
|
|
2622
2625
|
)}&body=${encodeURIComponent("")}`;
|
|
2623
2626
|
if (reactNative.Platform.OS === "android") {
|
|
2624
2627
|
const gmailUrl = `intent://#Intent;scheme=mailto;package=com.google.android.gm;S.to=${recipient};S.subject=${encodeURIComponent(
|
|
2625
|
-
|
|
2628
|
+
emailSubject
|
|
2626
2629
|
)};S.body=${encodeURIComponent("")};end`;
|
|
2627
2630
|
reactNative.Linking.canOpenURL(gmailUrl).then((supported) => {
|
|
2628
2631
|
if (supported) {
|
|
@@ -3102,6 +3105,14 @@ const createStyles$1 = (theme) => {
|
|
|
3102
3105
|
paddingHorizontal: 20,
|
|
3103
3106
|
borderRadius: 30
|
|
3104
3107
|
},
|
|
3108
|
+
feedbackButtonDisable: {
|
|
3109
|
+
backgroundColor: theme.SURFACE_PRIMARY,
|
|
3110
|
+
borderColor: theme.SURFACE_DISABLE,
|
|
3111
|
+
borderWidth: 1,
|
|
3112
|
+
paddingVertical: 10,
|
|
3113
|
+
paddingHorizontal: 20,
|
|
3114
|
+
borderRadius: 30
|
|
3115
|
+
},
|
|
3105
3116
|
cancelButton: {
|
|
3106
3117
|
paddingVertical: 10,
|
|
3107
3118
|
paddingHorizontal: 40
|
|
@@ -3149,7 +3160,7 @@ const FeedbackForm = ({
|
|
|
3149
3160
|
textColor: Theme.CONTENT_SECONDRY,
|
|
3150
3161
|
style: styles.charCounter
|
|
3151
3162
|
}
|
|
3152
|
-
), /* @__PURE__ */ React__default["default"].createElement(reactNative.View, { style: styles.buttonContainer }, /* @__PURE__ */ React__default["default"].createElement(reactNative.Pressable, { style: styles.feedbackButton, onPress: handleSendFeedback }, /* @__PURE__ */ React__default["default"].createElement(
|
|
3163
|
+
), /* @__PURE__ */ React__default["default"].createElement(reactNative.View, { style: styles.buttonContainer }, /* @__PURE__ */ React__default["default"].createElement(reactNative.Pressable, { disabled: feedback?.length < 1, style: feedback?.length < 1 ? styles.feedbackButtonDisable : styles.feedbackButton, onPress: handleSendFeedback }, /* @__PURE__ */ React__default["default"].createElement(
|
|
3153
3164
|
CustomText$1,
|
|
3154
3165
|
{
|
|
3155
3166
|
text: leftBtnTxt,
|