-
Notifications
You must be signed in to change notification settings - Fork 645
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 ElementsSessionContext
to Instant Debits flows
#9251
Conversation
Diffuse output:
APK
DEX
|
36bf0f2
to
f20ff8e
Compare
e0ba692
to
d1182d1
Compare
f20ff8e
to
6768ce0
Compare
b63d623
to
ddc679b
Compare
IntentContext
to FC flowsElementsContext
to FC flows
ElementsContext
to FC flowsElementsContext
to Instant Debits flows
8d24abf
to
b456e95
Compare
b456e95
to
4c56dcf
Compare
b0f7a69
to
25696f1
Compare
0e0404c
to
f255410
Compare
f255410
to
20ef6f5
Compare
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.
Love this approach! it scales (both for adding more context to elements, or following the same approach for new contexts if needed). Just a minor comment.
.../src/main/java/com/stripe/android/financialconnections/FinancialConnectionsSheetViewModel.kt
Outdated
Show resolved
Hide resolved
private fun CollectBankAccountConfiguration.retrieveElementsContext(): ElementsContext? { | ||
return (this as? InstantDebits)?.elementsContext | ||
} |
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.
same as above : )
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.
This one is a little trickier, since CollectBankAccountConfiguration.USBankAccount
is public. Good if we revisit this later this year for the next major version bump?
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.
sounds good! When we do that ideally we also move it out of the configuration object (that intends to be public facing) and follow the Args pattern we do on FC 😄
- Rename `ElementsContext` to `ElementsSessionContext` - Require the context on `FinancialConnectionsSheetActivityArgs`
1dfe400
to
22d331b
Compare
ElementsContext
to Instant Debits flowsElementsSessionContext
to Instant Debits flows
Summary
This pull request adds an
ElementsContext
struct to the Instant Debits flow, allowing us to pass in information from the hosting surface.Right now, this is only used with the
LinkMode
in Instant Debits flow, but can be extended to more properties and to the ACH flow.Motivation
BANKCON-14527
Testing
Screenshots
Changelog