Skip to content

Conversation

@JayShortway
Copy link
Member

@JayShortway JayShortway commented Jul 15, 2025

Description

We can launch a Paywall in a new Window instead of in an Activity. This has the following benefits:

  • It allows us to set a realtime listener, instead of only getting a single result after the Paywall is dismissed.
  • It allows us to show the Paywall from plain Activities. Our PaywallActivity uses an intermediate PaywallFragment, which means that the launching Activity (from the app) needs to be a FragmentActivity. This requirement can be dropped when using a Window. This allows us to support Paywalls in purchases-unity.

Here's a video showing the realtime listener:

listener.mov

Still some rough edges:

  • The window is showing underneath the popup. Maybe that's just a bug in PaywallTester, but maybe we can fix it from the Paywall side too.
  • We still have to implement transition animations.
  • We'll have to add edge to edge support.
  • We'll need to remove the PaywallView from the Window when the app's Activity gets destroyed.

@JayShortway JayShortway self-assigned this Jul 15, 2025
@emerge-tools
Copy link

emerge-tools bot commented Jul 15, 2025

📸 Snapshot Test

660 unchanged

Name Added Removed Modified Renamed Unchanged Errored Approval
TestPurchasesUIAndroidCompatibility
com.revenuecat.testpurchasesuiandroidcompatibility
0 0 0 0 404 0 N/A
TestPurchasesUIAndroidCompatibility Paparazzi
com.revenuecat.testpurchasesuiandroidcompatibility.paparazzi
0 0 0 0 256 0 N/A

🛸 Powered by Emerge Tools

@codecov
Copy link

codecov bot commented Jul 15, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 78.10%. Comparing base (b9a831c) to head (6eb1f8a).
⚠️ Report is 51 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2528   +/-   ##
=======================================
  Coverage   78.10%   78.10%           
=======================================
  Files         286      286           
  Lines       10573    10573           
  Branches     1485     1485           
=======================================
  Hits         8258     8258           
  Misses       1668     1668           
  Partials      647      647           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@aboedo
Copy link
Member

aboedo commented Jul 15, 2025

awesome

Base automatically changed from compat-compose-view to main July 16, 2025 12:11
# Conflicts:
#	ui/revenuecatui/src/main/kotlin/com/revenuecat/purchases/ui/revenuecatui/views/PaywallView.kt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants