Releases: FinTecSystems/xs2a-android
5.1.0
- Implemented Button border styling.
- Added
ButtonStyle.borderStyle
field, which defaults toBorderStyle.Unspecified
- You can use the new
BorderStyle
class to specify the width and color of a button border - If you don't want to specify a border style, you can either omit it from the
ButtonStyle
constructor or passBorderStyle.Unspecified
- For the shape of the border use the already existing
XS2ATheme.buttonShape
- Added
5.0.1
- Fixed Issue where the server would receive invalid values of checkboxes when selecting multiple accounts
5.0.0
Dependency Upgrade
To mitigate security issues due to outdated dependencies, we updated all dependencies and kotlin to the latest version.
Due to the breaking nature of this update, we use a new major version.
Please notice the following:
- Please update to the latest Kotlin version (1.8.10 or higher)
If you are using the Compose version:
- Please update to the latest Compose Version (1.3) and Compiler (1.4)
4.0.0
Rewrite of Initialization and Styling
Initialization
The wizard will no longer initialize using a config object.
This is to separate the serializable data from the callbacks, since that caused Issues when trying to store the wizard state in the Bundle.
// Compose
// Just call composable
XS2AWizard(
modifier = Modifier.fillMaxSize(), // Recommended
sessionKey = <your-session-key>, // Required
)
//Fragment
// Create Fragment
val xs2aWizard = XS2AWizardFragment(
sessionKey = <your-session-key> // Required
)
// Commit fragment
supportFragmentManager.beginTransaction().let {
it.add(<wizard-container>, xs2aWizard)
it.commit()
}
Callbacks
Instead of function references the wizard now expects an object of type XS2AWizardCallbackListener
, which will be used for callbacks.
On Jetpack Compose this can just be passed to the Composable without any Issues:
val callbackListener = object : XS2AWizardCallbackListener {
/**
* interface implementation
*/
}
XS2AWizard(
// ...
callbackListener = callbackListener,
)
This is not directly possible with Fragments. Instead you can register Fragment Callbacks.
A good place to register them would be in the
onCreate
method.
You should use the keys provided by the `XS2AWizardFragment.
supportFragmentManager.setFragmentResultListener(
XS2AWizardFragment.onFinishKey,
this // May be your Activity
) { requestKey, bundle ->
if (requestKey == XS2AWizardFragment.onFinishKey) {
// Perform onFinish action
}
}
Alternatively you can just use the FragmentResultOwner.setXs2aCallbacks
extension method to register to all callbacks directly.
Use FragmentResultOwner.clearXs2aCallbacks
to clear them.
This results in a similar usage to the Jetpack Compose side.
val callbackListener = object : XS2AWizardCallbackListener {
/**
* interface implementation
*/
}
supportFragmentManager.setXs2aCallbacks(
this, // May be your Activity
callbackListener
)
Styling
The theme is no longer a interface and just a class.
On top of that all fields now use shared wrappers, this lifts the separation of both Frameworks which now use the exact same class.
The main reason is that many of the Jetpack Compose classes like shapes cannot be put into the Bundle, which makes state saving and restoration impossible.
val theme = XS2ATheme(
tintColor = XS2AColor("#ff0000"),
backgroundColor = XS2AColor("#00ff00"),
submitButtonStyle = ButtonStyle(
backgroundColor = XS2AColor("#ffffff"),
textColor = XS2AColor("#000000")
)
// ... Other arguments
)
Typography
Instead of within XS2ATheme
a custom font has to be defined differently depending on the Framework used.
// Compose
XS2AWizard(
// ...
typography = Typography(
defaultFontFamily = FontFamily.Default
)
)
//Fragment
XS2AWizardFragment(
// ...
fontResId = <id-of-your-font>
)
3.14.0
- Added
XS2AWizardConfig.enableAutomaticRetry
- Setting this to
true
let's the SDK retry network requests, when the device is offline. - If it's set to
false
the SDK aborts all network request, when the device is offline.
- Setting this to
Thank you @hossamCheck24 for the change!
3.13.2
- Removed
lateinit
property ofXS2AWizardViewModel.config
and made it nullable.- This hopefully fixes a crash during the
init
call.
- This hopefully fixes a crash during the
3.13.1
- Fixed Issue where
ImageLine
may take up the entire screen.
Thank you @hossamCheck24 for the fix.
3.13.0
- Added
isBankSearch
andisLogin
toXS2AWizardViewModel
- With those methods you will be able to check if the form is currently the bank search or the first login screen.
3.12.2
- Fixed loading indicator using up more space than it should.
- The size is now bound to the size of
XS2AWizard
.
- The size is now bound to the size of
For more consistent behavior explicitly set the size of the
XS2AWizard
:XS2AWizard( modifier = Modifier.fillMaxSize(), ...
3.12.1
- Fixed an Issue where the SDK loads indefinitely in some cases.
Thank you @hossamCheck24 for the fix!