What changed (plus any additional context for devs)
The formatting for max input value was using the valueBasedDecimalFormatter which is slightly different from the logic that the balance badge uses. This PR ports over the essential logic of the balance badge into a worklet and uses that for formatting.
This also fixes an issue with the non-worklet handleSignificantDecimals function that was copied over from helpers/utilities. A comment is added inline below describing the issue.
What to test
Tap max on various input assets (native and non-native) across multiple networks.
For non-native assets, the max formatted input value should match the balance badge.
For native assets, the max formatted input value should look similarly formatted to the balance badge, though the max input amount will be slightly less than what is shown in the balance badge since it needs to account for gas + some buffer.
Fixes APP-1627
What changed (plus any additional context for devs)
valueBasedDecimalFormatter
which is slightly different from the logic that the balance badge uses. This PR ports over the essential logic of the balance badge into a worklet and uses that for formatting.handleSignificantDecimals
function that was copied over from helpers/utilities. A comment is added inline below describing the issue.What to test
Screen recordings / screenshots