Skip to content

Commit

Permalink
add suggested changes
Browse files Browse the repository at this point in the history
  • Loading branch information
narefyev91 committed Jun 5, 2024
1 parent d659ef3 commit 0652324
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 18 deletions.
21 changes: 5 additions & 16 deletions src/components/AddPaymentCard/PaymentCardForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ type PaymentCardFormProps = {
submitButtonText: string;
/** Custom content to display in the footer after card form */
footerContent?: ReactNode;
/** Custom content to display in the footer before card form */
/** Custom content to display in the header before card form */
headerContent?: ReactNode;
};

Expand All @@ -53,17 +53,6 @@ function IAcceptTheLabel() {
);
}

function IAcceptDebitTheLabel() {
const {translate} = useLocalize();

return (
<Text>
{`${translate('common.iAcceptThe')}`}
<TextLink href={CONST.TERMS_URL}>{`${translate('common.expensifyTermsOfService')}`}</TextLink>
</Text>
);
}

const REQUIRED_FIELDS = [
INPUT_IDS.NAME_ON_CARD,
INPUT_IDS.CARD_NUMBER,
Expand Down Expand Up @@ -226,7 +215,7 @@ function PaymentCardForm({
spellCheck={false}
/>
<View style={[styles.flexRow, styles.mt5]}>
<View style={styles.mr2}>
<View style={[styles.mr2, styles.flex1]}>
<InputWrapper
InputComponent={TextInput}
inputID={INPUT_IDS.EXPIRATION_DATE}
Expand Down Expand Up @@ -304,12 +293,12 @@ function PaymentCardForm({
<View style={[styles.mt4, styles.ml1]}>
<InputWrapper
InputComponent={CheckboxWithLabel}
accessibilityLabel={`${translate('common.iAcceptThe')} ${translate('common.expensifyTermsOfService')} ${translate('common.and')} ${translate(
'common.termsOfService',
accessibilityLabel={`${translate('common.iAcceptThe')} ${translate('common.addCardTermsOfService')} ${translate('common.and')} ${translate(
'common.privacyPolicy',
)}`}
inputID={INPUT_IDS.ACCEPT_TERMS}
defaultValue={false}
LabelComponent={isDebitCard ? IAcceptDebitTheLabel : IAcceptTheLabel}
LabelComponent={IAcceptTheLabel}
/>
</View>
)}
Expand Down
1 change: 0 additions & 1 deletion src/languages/en.ts
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,6 @@ export default {
saveAndContinue: 'Save & continue',
settings: 'Settings',
termsOfService: 'Terms of Service',
expensifyTermsOfService: 'Expensify Terms of Service',
members: 'Members',
invite: 'Invite',
here: 'here',
Expand Down
1 change: 0 additions & 1 deletion src/languages/es.ts
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,6 @@ export default {
saveAndContinue: 'Guardar y continuar',
settings: 'Configuración',
termsOfService: 'Términos de Servicio',
expensifyTermsOfService: 'Términos de Servicio de Expensify',
members: 'Miembros',
invite: 'Invitar',
here: 'aquí',
Expand Down

0 comments on commit 0652324

Please sign in to comment.