You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/components/reusable/FallbackPaywallIntroduction.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,14 +1,14 @@
1
1
<!--- FallbackPaywallIntroduction--->
2
2
3
-
To maintain a fluid user experience, it is important to set up [fallbacks](/fallback-paywalls) for your [paywalls](paywalls), flows, and [onboardings](onboardings). This precaution extends the application's capabilities in case of partial or complete loss of internet connection.
3
+
To maintain a fluid user experience, it is important to set up [fallbacks](/fallback-paywalls) for your flows, [paywalls](paywalls), and [onboardings](onboardings). This precaution extends the application's capabilities in case of partial or complete loss of internet connection.
4
4
5
5
***If the application cannot access Adapty servers:**
6
6
7
-
It will be able to display a fallback paywall or flow, and access the local onboarding configuration.
7
+
It will be able to display a fallback flow or paywall, and access the local onboarding configuration.
8
8
9
9
***If the application cannot access the internet:**
10
10
11
-
It will be able to display a fallback paywall or flow. Onboardings include remote content and require an internet connection to function.
11
+
It will be able to display a fallback flow or paywall. Onboardings include remote content and require an internet connection to function.
12
12
13
13
:::important
14
14
Before you follow the steps in this guide, [download](/local-fallback-paywalls) the fallback configuration files from Adapty.
If a flow includes buttons that request system permissions (push notifications, camera access, and others), the SDK calls your `AdaptySystemRequestsHandler`. You implement this handler to request the permission from the OS and return the result.
This guide covers event handling for purchases, restorations, product selection, and paywall rendering. You must also implement button handling (closing paywall, opening links, etc.). See our [guide on handling button actions](handle-paywall-actions) for details.
14
14
:::
15
15
16
-
Paywalls and flows don't need extra code to make and restore purchases. However, they generate some events that your app can respond to. Those events include button presses (close buttons, URLs, product selections, and so on) as well as notifications on purchase-related actions. Learn how to respond to these events below.
16
+
Flows and paywalls don't need extra code to make and restore purchases. However, they generate some events that your app can respond to. Those events include button presses (close buttons, URLs, product selections, and so on) as well as notifications on purchase-related actions. Learn how to respond to these events below.
17
17
18
18
:::tip
19
19
@@ -23,7 +23,7 @@ Want to see a real-world example of how Adapty SDK is integrated into a mobile a
23
23
24
24
## Handling events in SwiftUI
25
25
26
-
To control or monitor processes occurring on the paywall or flow screen within your mobile app, use the `.flow` modifier in SwiftUI:
26
+
To control or monitor processes occurring on the flow or paywall screen within your mobile app, use the `.flow` modifier in SwiftUI:
27
27
28
28
```swift showLineNumbers title="Swift"
29
29
@Statevar flowPresented =false
@@ -64,16 +64,16 @@ You can register only the closure parameters you need and omit those you do not
|**isPresented**| required | A binding that manages whether the paywall or flow screen is displayed. |
68
-
|**flowConfiguration**| required | An `AdaptyUI.FlowConfiguration` object containing visual details of the paywall or flow. Refer to [Get paywalls and flows](get-pb-paywalls) for more details. |
67
+
|**isPresented**| required | A binding that manages whether the flow or paywall screen is displayed. |
68
+
|**flowConfiguration**| required | An `AdaptyUI.FlowConfiguration` object containing visual details of the flow or paywall. Refer to [Get flows and paywalls](get-pb-paywalls) for more details. |
69
69
|**didFailPurchase**| required | Invoked when `Adapty.makePurchase()` fails. |
70
70
|**didFinishRestore**| required | Invoked when `Adapty.restorePurchases()` completes successfully. |
71
71
|**didFailRestore**| required | Invoked when `Adapty.restorePurchases()` fails. |
72
72
|**didFailRendering**| required | Invoked if an error occurs while rendering the interface. In this case, [contact Adapty Support](mailto:support@adapty.io). |
73
-
|**placeholderBuilder**| optional | A function for rendering the placeholder view while the paywall or flow is loading. Defaults to a `ProgressView`. |
74
-
|**fullScreen**| optional | Determines if the paywall or flow appears in full-screen mode or as a sheet. Defaults to `true`. |
75
-
|**didAppear**| optional | Invoked when the paywall or flow view appears on screen. |
76
-
|**didDisappear**| optional | Invoked when the paywall or flow view was dismissed. |
73
+
|**placeholderBuilder**| optional | A function for rendering the placeholder view while the flow or paywall is loading. Defaults to a `ProgressView`. |
74
+
|**fullScreen**| optional | Determines if the flow or paywall appears in full-screen mode or as a sheet. Defaults to `true`. |
75
+
|**didAppear**| optional | Invoked when the flow or paywall view appears on screen. |
76
+
|**didDisappear**| optional | Invoked when the flow or paywall view was dismissed. |
77
77
|**didPerformAction**| optional | Invoked when a user clicks a button. Two action IDs are pre-defined: `close` and `openURL`; others are custom and can be set in the builder. |
78
78
|**didSelectProduct**| optional | Invoked when a product is selected for purchase by the user or by the system. |
79
79
|**didStartPurchase**| optional | Invoked when the user begins the purchase process. |
@@ -82,7 +82,7 @@ You can register only the closure parameters you need and omit those you do not
82
82
|**didStartRestore**| optional | Invoked when the user starts the restore process. |
83
83
|**didFailLoadingProducts**| optional | Invoked when errors occur during product loading. Return `true` to retry loading. |
84
84
|**didPartiallyLoadProducts**| optional | Invoked when products are partially loaded. |
85
-
|**showAlertItem**| optional | A binding that manages the display of alert items above the paywall or flow. |
85
+
|**showAlertItem**| optional | A binding that manages the display of alert items above the flow or paywall. |
86
86
|**showAlertBuilder**| optional | A function for rendering the alert view. |
**Starting from SDK v4 (beta)**, you can build [flows](get-pb-paywalls) as a more powerful alternative to onboardings. Unlike onboardings which run inside a WebView, flows render natively on the device — giving you smoother animations, a consistent iOS look and feel, faster load times, and no WebView runtime dependency. See [Get paywalls & flows](get-pb-paywalls) and [Display flows & paywalls](ios-present-paywalls) to get started.
14
+
**Starting from SDK v4 (beta)**, you can build [flows](get-pb-paywalls) as a more powerful alternative to onboardings. Unlike onboardings which run inside a WebView, flows render natively on the device — giving you smoother animations, a consistent iOS look and feel, faster load times, and no WebView runtime dependency. See [Get flows & paywalls](get-pb-paywalls) and [Display flows & paywalls](ios-present-paywalls) to get started.
**Starting from SDK v4 (beta)**, you can build [flows](get-pb-paywalls) as a more powerful alternative to onboardings. Unlike onboardings which run inside a WebView, flows render natively on the device — giving you smoother animations, a consistent iOS look and feel, faster load times, and no WebView runtime dependency. See [Get paywalls & flows](get-pb-paywalls) and [Display flows & paywalls](ios-present-paywalls) to get started.
11
+
**Starting from SDK v4 (beta)**, you can build [flows](get-pb-paywalls) as a more powerful alternative to onboardings. Unlike onboardings which run inside a WebView, flows render natively on the device — giving you smoother animations, a consistent iOS look and feel, faster load times, and no WebView runtime dependency. See [Get flows & paywalls](get-pb-paywalls) and [Display flows & paywalls](ios-present-paywalls) to get started.
12
12
:::
13
13
14
14
When your users respond to a quiz question or input their data into an input field, the `onStateUpdatedAction` method will be invoked. You can save or process the field type in your code.
**Starting from SDK v4 (beta)**, you can build [flows](get-pb-paywalls) as a more powerful alternative to onboardings. Unlike onboardings which run inside a WebView, flows render natively on the device — giving you smoother animations, a consistent iOS look and feel, faster load times, and no WebView runtime dependency. See [Get paywalls & flows](get-pb-paywalls) and [Display flows & paywalls](ios-present-paywalls) to get started.
11
+
**Starting from SDK v4 (beta)**, you can build [flows](get-pb-paywalls) as a more powerful alternative to onboardings. Unlike onboardings which run inside a WebView, flows render natively on the device — giving you smoother animations, a consistent iOS look and feel, faster load times, and no WebView runtime dependency. See [Get flows & paywalls](get-pb-paywalls) and [Display flows & paywalls](ios-present-paywalls) to get started.
Copy file name to clipboardExpand all lines: src/content/docs/ios/ios-present-onboardings.mdx
+1-3Lines changed: 1 addition & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,7 +12,7 @@ import Tabs from '@theme/Tabs';
12
12
importTabItemfrom'@theme/TabItem';
13
13
14
14
:::tip
15
-
**Starting from SDK v4 (beta)**, you can build [flows](get-pb-paywalls) as a more powerful alternative to onboardings. Unlike onboardings which run inside a WebView, flows render natively on the device — giving you smoother animations, a consistent iOS look and feel, faster load times, and no WebView runtime dependency. See [Get paywalls & flows](get-pb-paywalls) and [Display flows & paywalls](ios-present-paywalls) to get started.
15
+
**Starting from SDK v4 (beta)**, you can build [flows](get-pb-paywalls) as a more powerful alternative to onboardings. Unlike onboardings which run inside a WebView, flows render natively on the device — giving you smoother animations, a consistent iOS look and feel, faster load times, and no WebView runtime dependency. See [Get flows & paywalls](get-pb-paywalls) and [Display flows & paywalls](ios-present-paywalls) to get started.
16
16
:::
17
17
18
18
If you've customized an onboarding using the builder, you don't need to worry about rendering it in your mobile app code to display it to the user. Such an onboarding contains both what should be shown within the onboarding and how it should be shown.
@@ -95,7 +95,6 @@ To do this, define a placeholder (what exactly will be shown while the onboardin
@@ -133,7 +132,6 @@ By default, links in onboardings open in an in-app browser. This provides a seam
133
132
If you prefer to open links in an external browser instead, you can customize this behavior by setting the `externalUrlsPresentation` parameter to `.externalBrowser`:
134
133
135
134
```swift showLineNumbers
136
-
importAdapty
137
135
importAdaptyUI
138
136
139
137
let configuration =try AdaptyUI.getOnboardingConfiguration(
0 commit comments