PaywallData validation#1273
Conversation
Codecov ReportAll modified lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## paywalls #1273 +/- ##
=========================================
Coverage 85.46% 85.46%
=========================================
Files 190 190
Lines 6385 6385
Branches 930 930
=========================================
Hits 5457 5457
Misses 568 568
Partials 360 360 ☔ View full report in Codecov by Sentry. |
|
This is looking good 👍🏻 |
2d44608 to
bb02408
Compare
bf8bb92 to
a899d61
Compare
There was a problem hiding this comment.
We should check if light/dark theme colors get automatically updated in the default paywall. My strong bet is that no. In that case, we should maybe store the last state in the view model so we can update the state when it changes, but we can do that in another PR.
There was a problem hiding this comment.
Since we're not doing this anymore, it may crash in the TemplateConfigurationFactory.create since we require a that there is at least some packages. Should we perform that validation before to avoid the crash?
There was a problem hiding this comment.
Right, I missed those require
There was a problem hiding this comment.
c6d5e40 to
1f821dd
Compare
a13c1f4 to
2f424c7
Compare
NachoSoto
left a comment
There was a problem hiding this comment.
Just a few minor things left, but this is perfect 🎉
…dation-2 # Conflicts: # ui/revenuecatui/src/main/kotlin/com/revenuecat/purchases/ui/revenuecatui/data/PaywallViewModel.kt
|
Fixed the light/dark colors. We will default to the current color scheme now, when it changes, and we react to the change |
|
@tonidero I will do the icons validation in another PR so we can merge this one. Do you mind taking a look? |
| variableDataProvider: VariableDataProvider, | ||
| mode: PaywallViewMode, | ||
| paywallData: PaywallData, | ||
| validatedPaywallData: PaywallData, |
There was a problem hiding this comment.
I'm wondering if this should keep being paywallData to not be confused with ValidatedPaywallResult... I think it's ok though.
Add validation to paywall data and creates default template if validation fails