Fix product change mode in workflow paywalls (#4016)
Workflow-backed Paywalls V2 drop `play_store_product_change_mode`, so
Google Play subscription changes can create a parallel subscription
instead of replacing the old one. Fixes
[WFL-479](https://linear.app/revenuecat/issue/WFL-479/paywalls-v2-workflows-play-store-product-change-mode-is-dropped-so).
<!-- CURSOR_SUMMARY -->
---
> [!NOTE]
> **Medium Risk**
> Changes how Play Store subscription product-change replacement modes
are applied for workflow paywalls; incorrect behavior was already a
production bug, but purchase flows are sensitive.
>
> **Overview**
> Workflow-backed Paywalls V2 were **not reading**
`play_store_product_change_mode` from workflow screen JSON, so Google
Play subscription upgrades/downgrades could use the wrong replacement
behavior (e.g. creating a parallel subscription instead of replacing the
old one).
>
> This PR **adds** `productChangeConfig` on `WorkflowScreen` (same
`ProductChangeConfigSerializer` / empty `{}` → null behavior as
`PaywallComponentsData`) and **passes it through**
`WorkflowScreenMapper` into `PaywallComponentsData`.
`ProductChangeConfigSerializer` is widened from `private` to `internal`
so workflow models can share it.
>
> Tests replace the old descriptor parity check with focused JSON
deserialization and mapper assertions for upgrade/downgrade modes.
>
> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit
041641db031916e02cd2fe42a3bf3a85a5e03d6f. Bugbot is set up for automated
code reviews on this repo. Configure
[here](https://www.cursor.com/dashboard/bugbot).</sup>
<!-- /CURSOR_SUMMARY --> C
Cesar de la Vega committed
933b18d54a7a862ce5d872debac751d097fc7e5a
Parent: 90f74fc
Committed by GitHub <noreply@github.com>
on 8/19/2026, 4:28:11 PM