From 41b4d98b0ca6ce218d448b86588eb687f9f572eb Mon Sep 17 00:00:00 2001 From: Pritish Budhiraja <1805317@kiit.ac.in> Date: Wed, 17 Apr 2024 12:05:54 +0530 Subject: [PATCH 1/2] =?UTF-8?q?Revert=20"feat:=20mandate=20Changes=20for?= =?UTF-8?q?=20the=20Saved=20card=20screen=20&=20SDK=20Button=20Loader=20c?= =?UTF-8?q?=E2=80=A6"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This reverts commit 0e5b5abd588732481bfbafb84080b3297bf993c5. --- ...tailsCheckbox.res => AnimatedCheckbox.res} | 20 ++---- src/Components/SavedMethods.res | 40 ++---------- src/Hooks/UtilityHooks.res | 13 ---- src/Payments/CardPayment.res | 31 ++++----- src/Payments/PaymentMethodsRecord.res | 3 - src/Utilities/PaymentBody.res | 65 ++++++------------- src/orca-loader/Hyper.res | 2 +- 7 files changed, 47 insertions(+), 127 deletions(-) rename src/Components/{SaveDetailsCheckbox.res => AnimatedCheckbox.res} (68%) diff --git a/src/Components/SaveDetailsCheckbox.res b/src/Components/AnimatedCheckbox.res similarity index 68% rename from src/Components/SaveDetailsCheckbox.res rename to src/Components/AnimatedCheckbox.res index 703c58858..7a6fd1726 100644 --- a/src/Components/SaveDetailsCheckbox.res +++ b/src/Components/AnimatedCheckbox.res @@ -1,14 +1,12 @@ @react.component -let make = (~isChecked, ~setIsChecked, ~list: PaymentMethodsRecord.list) => { +let make = (~isChecked, ~setIsChecked) => { let {themeObj} = Recoil.useRecoilValueFromAtom(RecoilAtoms.configAtom) - let showFields = Recoil.useRecoilValueFromAtom(RecoilAtoms.showCardFieldsAtom) - let {business} = Recoil.useRecoilValueFromAtom(RecoilAtoms.optionAtom) - let css = `.container { display: flex; cursor: pointer; position: relative; justify-content: center; + align-items: center; } .container input { @@ -48,21 +46,13 @@ let make = (~isChecked, ~setIsChecked, ~list: PaymentMethodsRecord.list) => { ? ("Checkbox--checked", "CheckboxInput--checked", "CheckboxLabel--checked") : ("", "", "") - let valueToBeRendered = if showFields { - localeString.saveCardDetails - } else if business.name !== "" { - localeString.cardTerms(business.name) - } else { - localeString.cardTerms(list.merchant_name) - } -