-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #97 from xsolla/PAYMENTS-19010
feat(PAYMENTS-19010): add cash-payment-instruction
- Loading branch information
Showing
28 changed files
with
482 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,4 +6,5 @@ export interface CashPaymentData { | |
title: string; | ||
projectName: string; | ||
printUrl: string; | ||
instruction?: string; | ||
} |
29 changes: 29 additions & 0 deletions
29
...-checkout/web-components/cash-payment-instruction/cash-payment-instruction.component.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
@use 'src/styles/mixins/typo.mixin' as typo; | ||
@use 'src/styles/mixins/animation.mixin' as animation; | ||
@use 'src/styles/mixins/buttons.mixin' as buttons; | ||
|
||
.cash-payment-instruction { | ||
@include typo.psdk-typo; | ||
|
||
.payment-title { | ||
@include typo.psdk-title2; | ||
|
||
margin: 0 0 4px; | ||
padding: 0; | ||
} | ||
|
||
.payment-description { | ||
margin: 0 0 20px; | ||
padding: 0; | ||
} | ||
|
||
.payment-instruction { | ||
margin: 0; | ||
padding: 0; | ||
|
||
a { | ||
color: var(--psdk-checkbox-checked-bg); | ||
text-decoration: none; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
22 changes: 22 additions & 0 deletions
22
...ess-checkout/web-components/cash-payment-instruction/cash-payment-instruction.template.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import i18next from 'i18next'; | ||
|
||
export const getCashPaymentInstructionTemplate = ( | ||
paymentMethodName: string, | ||
instruction?: string, | ||
): string => { | ||
return ` | ||
<div class='cash-payment-instruction'> | ||
<h2 class='payment-title'> | ||
${i18next.t('cash-payment-instruction.title', { paymentMethodName })} | ||
</h2> | ||
<p class='payment-description'> | ||
${i18next.t('cash-payment-instruction.description')} | ||
</p> | ||
<h3 class="payment-title">${i18next.t( | ||
'cash-payment-instruction.how-to', | ||
)}</h3> | ||
<p class='payment-instruction'> | ||
${instruction ?? ''} | ||
</p> | ||
</div>`; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.