File tree Expand file tree Collapse file tree 4 files changed +7
-8
lines changed
features/blocks/inputs/payment/components
packages/bot-engine/blocks/inputs/payment Expand file tree Collapse file tree 4 files changed +7
-8
lines changed Original file line number Diff line number Diff line change 1
1
import { Text } from '@chakra-ui/react'
2
2
import { useTranslate } from '@tolgee/react'
3
3
import { PaymentInputBlock } from '@typebot.io/schemas'
4
+ import { defaultPaymentInputOptions } from '@typebot.io/schemas/features/blocks/inputs/payment/constants'
4
5
5
6
type Props = {
6
7
block : PaymentInputBlock
@@ -9,11 +10,7 @@ type Props = {
9
10
export const PaymentInputContent = ( { block } : Props ) => {
10
11
const { t } = useTranslate ( )
11
12
12
- if (
13
- ! block . options ?. amount ||
14
- ! block . options . credentialsId ||
15
- ! block . options . currency
16
- )
13
+ if ( ! block . options ?. amount || ! block . options . credentialsId )
17
14
return (
18
15
< Text color = "gray.500" >
19
16
{ t ( 'blocks.inputs.payment.placeholder.label' ) }
@@ -22,7 +19,7 @@ export const PaymentInputContent = ({ block }: Props) => {
22
19
return (
23
20
< Text noOfLines = { 1 } pr = "6" >
24
21
{ t ( 'blocks.inputs.payment.collect.label' ) } { block . options . amount } { ' ' }
25
- { block . options . currency }
22
+ { block . options . currency ?? defaultPaymentInputOptions . currency }
26
23
</ Text >
27
24
)
28
25
}
Original file line number Diff line number Diff line change @@ -163,6 +163,7 @@ export const StripeConfigModal = ({
163
163
placeholder = "sk_test_..."
164
164
withVariableButton = { false }
165
165
debounceTimeout = { 0 }
166
+ type = "password"
166
167
/>
167
168
</ HStack >
168
169
</ Stack >
@@ -187,6 +188,7 @@ export const StripeConfigModal = ({
187
188
placeholder = "sk_live_..."
188
189
withVariableButton = { false }
189
190
debounceTimeout = { 0 }
191
+ type = "password"
190
192
/>
191
193
</ FormControl >
192
194
</ HStack >
Original file line number Diff line number Diff line change 143
143
"blocks.inputs.file.settings.skip.label" : " Skip button label:" ,
144
144
"blocks.inputs.fileUpload.blockCard.tooltip" : " Upload Files" ,
145
145
"blocks.inputs.number.settings.step.label" : " Step:" ,
146
- "blocks.inputs.payment.collect.label" : " Coletar " ,
146
+ "blocks.inputs.payment.collect.label" : " Collect " ,
147
147
"blocks.inputs.payment.placeholder.label" : " Configure..." ,
148
148
"blocks.inputs.payment.settings.account.label" : " Account:" ,
149
149
"blocks.inputs.payment.settings.accountText.label" : " {provider} account" ,
Original file line number Diff line number Diff line change @@ -77,7 +77,7 @@ const createStripePaymentIntent =
77
77
options . currency === 'EUR' ? 'fr-FR' : undefined ,
78
78
{
79
79
style : 'currency' ,
80
- currency : options . currency ,
80
+ currency,
81
81
}
82
82
)
83
83
You can’t perform that action at this time.
0 commit comments