From 68b09ed4afd6b0576a0c5ae5578f38f4e909f10b Mon Sep 17 00:00:00 2001 From: Somarapu Vamshi Date: Wed, 18 Dec 2024 21:35:15 +0530 Subject: [PATCH] NTP-12975 | button style fix (#14249) --- App/Container/Navi-Insurance/Styles/index.ts | 3 +++ .../reusable/select-button/SelectButton.tsx | 21 ++++++++++++------- .../ItemCardWithTag.tsx | 7 ++++++- 3 files changed, 23 insertions(+), 8 deletions(-) diff --git a/App/Container/Navi-Insurance/Styles/index.ts b/App/Container/Navi-Insurance/Styles/index.ts index 690c78b58e..adc7a9de36 100644 --- a/App/Container/Navi-Insurance/Styles/index.ts +++ b/App/Container/Navi-Insurance/Styles/index.ts @@ -60,6 +60,9 @@ export const commonStyles = StyleSheet.create({ overflowHidden: { overflow: "hidden", }, + marginRight0: { + marginRight: 0, + }, }); export const commonHeaderShadowStyle = ( diff --git a/components/reusable/select-button/SelectButton.tsx b/components/reusable/select-button/SelectButton.tsx index 496e157390..982904ec97 100644 --- a/components/reusable/select-button/SelectButton.tsx +++ b/components/reusable/select-button/SelectButton.tsx @@ -1,26 +1,33 @@ -import { View } from "react-native"; -import { styles } from "./SelectButtonStyles"; +import { View, ViewStyle } from "react-native"; import { SelectButtonType } from "../../../App/common/constants"; +import { styles } from "./SelectButtonStyles"; interface SelectButtonProps { selected?: boolean; type?: string; + buttonStyle?: ViewStyle; } -const RadioButton = ({ selected }: SelectButtonProps) => { +const RadioButton = ({ selected, buttonStyle }: SelectButtonProps) => { return ( - + {selected && } ); }; -const SelectButton = ({ selected, type }: SelectButtonProps) => { +const SelectButton = ({ selected, type, buttonStyle }: SelectButtonProps) => { switch (type) { case SelectButtonType.RADIO: - return ; + return ; default: - return ; + return ; } }; diff --git a/components/widgets/select-card-with-tag-list-items/ItemCardWithTag.tsx b/components/widgets/select-card-with-tag-list-items/ItemCardWithTag.tsx index a9d2b7d776..570f8dfb7f 100644 --- a/components/widgets/select-card-with-tag-list-items/ItemCardWithTag.tsx +++ b/components/widgets/select-card-with-tag-list-items/ItemCardWithTag.tsx @@ -9,6 +9,7 @@ import { CardFooterCtaButtonProps, ItemCardProps, } from "../../../App/common/interface/widgets/widgetData"; +import { commonStyles } from "../../../App/Container/Navi-Insurance/Styles"; import { SelectButton } from "../../reusable"; import CtaButton from "../../reusable/cta-button/CtaButton"; import GradientBorder from "../../reusable/gradient-border/GradientBorder"; @@ -78,7 +79,11 @@ export const ItemCardWithTag = ({ )} - + {item?.tag &&