Open
Conversation
Uniform everything into `sendClickEvent` method and handles prevented prop.
Now dynamically exctract notification name from message.
Handling all click events.
There was a problem hiding this comment.
Pull request overview
Adds a “prevent default” mechanism for several paywall click events (currently iOS-focused), allowing JS handlers to optionally block the native SDK’s default click behavior.
Changes:
- Extend click events with
_messageId/preventedand add JS-sideprevent()handlers for click events. - Add iOS bridging to correlate click events with a JS response and conditionally invoke the native
prevent()callback. - Update example app and iOS dependency versions to exercise the new behavior.
Reviewed changes
Copilot reviewed 6 out of 8 changed files in this pull request and generated 10 comments.
Show a summary per file
| File | Description |
|---|---|
| src/specs/PaywallViewNativeComponent.ts | Extends ClickEvent payload to support preventable click actions. |
| src/Paywall/index.tsx | Adds JS handler signatures that expose prevent() and sends resolve/reject messages back to native. |
| ios/PaywallView.mm | Adds iOS-side observer wiring to call the SDK’s prevent() based on JS response. |
| ios/NativePaywallModule.mm | Changes notification routing to be derived from the emitted JS event name. |
| RNAccessIOS.podspec | Updates pinned AccessIOS dependency version. |
| example/src/App.tsx | Demonstrates new click handlers and prevent calls. |
| example/ios/Podfile.lock | Updates example iOS pods (including AccessIOS version and CocoaPods metadata). |
| example/Gemfile.lock | Updates Ruby/Bundler/CocoaPods lock metadata for the example app. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds prevent methods for click events :
onSubscribeClick,onLoginClick,onDataPolicyClick&
onDiscoveryLinkClick.Working only for iOS so far.
current iOS SDK version, it would probably be a good idea to wait until Access IOS
v2.10.1isavailable before releasing this.