-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add captureMethod to createPaymentIntent #447
Conversation
And always provide one.
Attempt to fix build errors like: > Could not configure Apple Service authentication: 2FA session saved > in Bitrise Developer Connection is expired, was valid until 2023-03-12 > 21:32:16 +0000 UTC (exit code: 1) https://app.bitrise.io/build/0565de0f-1eef-4d6c-a660-b6c5c709b6f4
It's not used yet, but this brings the example-app up-to-date with our dev-app.
Match our dev app and other example apps.
Our example-app is pinned to the currently released version of the RN SDK. So, we can't make these changes yet.
<List bolded={false} topSpacing={false} title="CAPTURE METHOD"> | ||
<Picker | ||
selectedValue={inputValues?.captureMethod} | ||
style={styles.picker} | ||
itemStyle={styles.pickerItem} | ||
testID="select-capture-method-picker" | ||
onValueChange={(value) => | ||
setInputValues((state) => ({ ...state, captureMethod: value })) | ||
} | ||
> | ||
{CAPTURE_METHODS.map((a) => ( | ||
<Picker.Item | ||
key={a.value} | ||
label={a.label} | ||
testID={a.value} | ||
value={a.value} | ||
/> | ||
))} | ||
</Picker> | ||
</List> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ignorable consistency nit: the native example apps use a "Automatic capture" switch instead of a picker...but thinking more about this I think I prefer the picker since it clarifies its an enum and just happens to have two options. So maybe my consistency nit should be to update the native example apps 🤷♂️
@@ -49,7 +49,7 @@ export default function CollectCardPaymentScreen() { | |||
}); | |||
const [testCardNumber, setTestCardNumber] = useState('4242424242424242'); | |||
const [enableInterac, setEnableInterac] = useState(false); | |||
const [skipTipping, setSkipTipping] = useState(true); | |||
const [skipTipping, setSkipTipping] = useState(false); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 good catch
Summary
Build on top of #443 to support
captureMethod
for iOS and Android and in thedev and example apps.
Tested example-app using yalc:
Testing
Documentation
Select one: