@rocapine/react-native-onboarding 1.61.0 → 1.62.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (70) hide show
  1. package/dist/OnboardingStudioClient.d.ts +23 -5
  2. package/dist/OnboardingStudioClient.d.ts.map +1 -1
  3. package/dist/OnboardingStudioClient.js +82 -6
  4. package/dist/OnboardingStudioClient.js.map +1 -1
  5. package/dist/index.d.ts +5 -0
  6. package/dist/index.d.ts.map +1 -1
  7. package/dist/index.js +6 -1
  8. package/dist/index.js.map +1 -1
  9. package/dist/infra/provider/OnboardingProvider.d.ts +25 -0
  10. package/dist/infra/provider/OnboardingProvider.d.ts.map +1 -1
  11. package/dist/infra/provider/OnboardingProvider.js +63 -3
  12. package/dist/infra/provider/OnboardingProvider.js.map +1 -1
  13. package/dist/infra/queries/cacheKey.d.ts +22 -4
  14. package/dist/infra/queries/cacheKey.d.ts.map +1 -1
  15. package/dist/infra/queries/cacheKey.js +26 -5
  16. package/dist/infra/queries/cacheKey.js.map +1 -1
  17. package/dist/paywalls/PaywallProvider.d.ts +66 -0
  18. package/dist/paywalls/PaywallProvider.d.ts.map +1 -0
  19. package/dist/paywalls/PaywallProvider.js +227 -0
  20. package/dist/paywalls/PaywallProvider.js.map +1 -0
  21. package/dist/paywalls/getPaywalls.query.d.ts +37 -0
  22. package/dist/paywalls/getPaywalls.query.d.ts.map +1 -0
  23. package/dist/paywalls/getPaywalls.query.js +114 -0
  24. package/dist/paywalls/getPaywalls.query.js.map +1 -0
  25. package/dist/paywalls/present.d.ts +100 -0
  26. package/dist/paywalls/present.d.ts.map +1 -0
  27. package/dist/paywalls/present.js +113 -0
  28. package/dist/paywalls/present.js.map +1 -0
  29. package/dist/paywalls/types.d.ts +95 -0
  30. package/dist/paywalls/types.d.ts.map +1 -0
  31. package/dist/paywalls/types.js +10 -0
  32. package/dist/paywalls/types.js.map +1 -0
  33. package/dist/paywalls/usePaywall.d.ts +29 -0
  34. package/dist/paywalls/usePaywall.d.ts.map +1 -0
  35. package/dist/paywalls/usePaywall.js +17 -0
  36. package/dist/paywalls/usePaywall.js.map +1 -0
  37. package/dist/products/ProductRuntimeContext.d.ts +15 -0
  38. package/dist/products/ProductRuntimeContext.d.ts.map +1 -0
  39. package/dist/products/ProductRuntimeContext.js +19 -0
  40. package/dist/products/ProductRuntimeContext.js.map +1 -0
  41. package/dist/products/index.d.ts +1 -0
  42. package/dist/products/index.d.ts.map +1 -1
  43. package/dist/products/index.js +4 -1
  44. package/dist/products/index.js.map +1 -1
  45. package/dist/products/mergeProductRuntimes.d.ts +55 -0
  46. package/dist/products/mergeProductRuntimes.d.ts.map +1 -0
  47. package/dist/products/mergeProductRuntimes.js +79 -0
  48. package/dist/products/mergeProductRuntimes.js.map +1 -0
  49. package/dist/steps/common.types.d.ts +22 -1
  50. package/dist/steps/common.types.d.ts.map +1 -1
  51. package/dist/steps/common.types.js +10 -1
  52. package/dist/steps/common.types.js.map +1 -1
  53. package/package.json +1 -1
  54. package/src/OnboardingStudioClient.ts +110 -7
  55. package/src/__tests__/mergeProductRuntimes.test.ts +172 -0
  56. package/src/__tests__/resolveLocalProductArgs.test.ts +41 -0
  57. package/src/index.ts +12 -0
  58. package/src/infra/provider/OnboardingProvider.tsx +73 -3
  59. package/src/infra/queries/cacheKey.ts +27 -4
  60. package/src/paywalls/PaywallProvider.tsx +342 -0
  61. package/src/paywalls/__tests__/getPaywalls.test.ts +334 -0
  62. package/src/paywalls/__tests__/present.test.ts +190 -0
  63. package/src/paywalls/getPaywalls.query.ts +123 -0
  64. package/src/paywalls/present.ts +141 -0
  65. package/src/paywalls/types.ts +99 -0
  66. package/src/paywalls/usePaywall.ts +35 -0
  67. package/src/products/ProductRuntimeContext.tsx +17 -0
  68. package/src/products/index.ts +1 -0
  69. package/src/products/mergeProductRuntimes.ts +78 -0
  70. package/src/steps/common.types.ts +34 -1
@@ -0,0 +1,95 @@
1
+ /**
2
+ * Response types for `OnboardingStudioClient.getPaywalls()` (spec §6.1). The
3
+ * endpoint returns every placement for the project/audience/locale in one
4
+ * payload — a paywall must render the instant the user taps upgrade, and a
5
+ * network round-trip at that moment is a conversion bug, so there is no
6
+ * per-placement fetch in the common path (see `PaywallOptions.placement`).
7
+ */
8
+ /** A single studio-authored paywall, keyed by `placement` in `PaywallCatalog.paywalls`. */
9
+ export type Paywall = {
10
+ id: string;
11
+ name: string;
12
+ placement: string;
13
+ /** UIElement[] — parsed by the UI adapter (Task 7's `ScreenElementsSchema`), not here. */
14
+ elements: unknown[];
15
+ products: Array<{
16
+ key: string;
17
+ ios?: string;
18
+ android?: string;
19
+ compareTo?: string;
20
+ }>;
21
+ configuration: Record<string, unknown> | null;
22
+ };
23
+ /** Full response body of `GET get-paywalls`. */
24
+ export type PaywallCatalog = {
25
+ metadata: {
26
+ audienceId: number | null;
27
+ audienceName: string | null;
28
+ locale: string | null;
29
+ draft: boolean;
30
+ };
31
+ /** Keyed by placement, not by paywall id. */
32
+ paywalls: Record<string, Paywall>;
33
+ fonts: Record<string, unknown> | null;
34
+ };
35
+ /**
36
+ * Options for `OnboardingStudioClient.getPaywalls()`.
37
+ *
38
+ * `placement` narrows the response to a single paywall — the exception, not
39
+ * the default. Omit it to get every placement in one round-trip, which is
40
+ * what lets a paywall render instantly at buy-tap time (see the module doc
41
+ * above).
42
+ */
43
+ export type PaywallOptions = {
44
+ locale?: string;
45
+ placement?: string;
46
+ };
47
+ /**
48
+ * Response headers for `get-paywalls`. Deliberately **not** the onboarding
49
+ * trio (`ONBS-Onboarding-Id` / `ONBS-Audience-Id` / `ONBS-Onboarding-Name`) —
50
+ * the paywall endpoint has no single onboarding/audience-name concept and
51
+ * instead reports which paywall ids came back.
52
+ */
53
+ export interface GetPaywallsResponseHeaders {
54
+ "ONBS-Audience-Id": string | null;
55
+ "ONBS-Paywall-Ids": string | null;
56
+ }
57
+ /**
58
+ * Resolved outcome of a `usePaywall().present(placement)` call (spec §7).
59
+ * Closed union, not the open-ended `ScreenHost.CompleteOutcome` — a
60
+ * presentation ends in exactly one of these four ways, and `present()`'s
61
+ * caller (typically an `await`) should be able to switch over it exhaustively.
62
+ *
63
+ * `"error"` covers both: (a) `placement` is absent from the catalog (or the
64
+ * catalog hasn't resolved yet), and (b) `present()` was called while another
65
+ * paywall is already being presented. Both resolve rather than throw — a
66
+ * missing placement or a mistimed call must not crash a host app mid-flow.
67
+ * See `resolvePresentDecision` in `present.ts` for the exact decision logic.
68
+ *
69
+ * `"purchased"` / `"cancelled"` are NOT produced by any ButtonAction directly
70
+ * — `dismiss` (the only in-content closing action) always reports
71
+ * `{status:"dismissed"}`, on purpose, since it doesn't know anything about
72
+ * purchase state. `PaywallProvider` instead tracks what the store actually
73
+ * did during the active presentation (`purchaseOutcomeFromResult` in
74
+ * `present.ts`) and `resolvePresentedOutcome` upgrades a bare `"dismissed"`
75
+ * to whichever of these occurred, if any — so spec §4.6's canonical authoring
76
+ * shape (`{type:"purchase", onSuccess:[{type:"dismiss"}]}`) resolves
77
+ * `"purchased"` even though `dismiss` itself never says so.
78
+ */
79
+ /**
80
+ * How a presentation ENDED — not what the user is entitled to.
81
+ *
82
+ * `"purchased"` means a purchase succeeded while this paywall was showing, and
83
+ * is the honest report in the common case. But it is deliberately not an
84
+ * entitlement signal: a purchase followed by a render crash resolves `"error"`
85
+ * (the boundary settles the promise so the user is not trapped), so a host that
86
+ * keys entitlement off `status === "purchased"` would under-grant a user who
87
+ * genuinely paid.
88
+ *
89
+ * Entitlement belongs to the store — read it from the `ProductProvider` /
90
+ * billing SDK, and use this only to decide what the UI does next.
91
+ */
92
+ export type PresentResult = {
93
+ status: "purchased" | "dismissed" | "cancelled" | "error";
94
+ };
95
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/paywalls/types.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,2FAA2F;AAC3F,MAAM,MAAM,OAAO,GAAG;IAC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C3D,CAAC"}
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ /**
3
+ * Response types for `OnboardingStudioClient.getPaywalls()` (spec §6.1). The
4
+ * endpoint returns every placement for the project/audience/locale in one
5
+ * payload — a paywall must render the instant the user taps upgrade, and a
6
+ * network round-trip at that moment is a conversion bug, so there is no
7
+ * per-placement fetch in the common path (see `PaywallOptions.placement`).
8
+ */
9
+ Object.defineProperty(exports, "__esModule", { value: true });
10
+ //# sourceMappingURL=types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/paywalls/types.ts"],"names":[],"mappings":";AAAA;;;;;;GAMG"}
@@ -0,0 +1,29 @@
1
+ import { PaywallCatalog, PresentResult } from "./types";
2
+ export type UsePaywallResult = {
3
+ /**
4
+ * Present a paywall by placement. Never fetches — the catalog and its
5
+ * products are already resolved (or resolving) from `PaywallProvider`
6
+ * mount, which is the whole point: a paywall must render the instant the
7
+ * user taps upgrade.
8
+ *
9
+ * Resolves `{ status: "error" }` — never throws — when `placement` is
10
+ * absent from the catalog, or when another paywall is already being
11
+ * presented. See `resolvePresentDecision` in `present.ts`.
12
+ */
13
+ present: (placement: string) => Promise<PresentResult>;
14
+ /**
15
+ * `true` once BOTH the catalog and its products have resolved — the one
16
+ * flag meaning "calling `present()` now will not show a spinner".
17
+ */
18
+ isReady: boolean;
19
+ /** The full resolved catalog (every placement), or `null` before it loads. */
20
+ catalog: PaywallCatalog | null;
21
+ };
22
+ /**
23
+ * Read the paywall runtime published by an ancestor `PaywallProvider`.
24
+ * Outside one, returns inert defaults (`present` resolves `"error"`,
25
+ * `isReady: false`, `catalog: null`) rather than throwing — mirrors how
26
+ * `useProductRuntime()` degrades to `null` with no ancestor.
27
+ */
28
+ export declare const usePaywall: () => UsePaywallResult;
29
+ //# sourceMappingURL=usePaywall.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"usePaywall.d.ts","sourceRoot":"","sources":["../../src/paywalls/usePaywall.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAExD,MAAM,MAAM,gBAAgB,GAAG;IAC7B;;;;;;;;;OASG;IACH,OAAO,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,OAAO,CAAC,aAAa,CAAC,CAAC;IACvD;;;OAGG;IACH,OAAO,EAAE,OAAO,CAAC;IACjB,8EAA8E;IAC9E,OAAO,EAAE,cAAc,GAAG,IAAI,CAAC;CAChC,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,UAAU,QAAO,gBAG7B,CAAC"}
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.usePaywall = void 0;
4
+ const react_1 = require("react");
5
+ const PaywallProvider_1 = require("./PaywallProvider");
6
+ /**
7
+ * Read the paywall runtime published by an ancestor `PaywallProvider`.
8
+ * Outside one, returns inert defaults (`present` resolves `"error"`,
9
+ * `isReady: false`, `catalog: null`) rather than throwing — mirrors how
10
+ * `useProductRuntime()` degrades to `null` with no ancestor.
11
+ */
12
+ const usePaywall = () => {
13
+ const { present, isReady, catalog } = (0, react_1.useContext)(PaywallProvider_1.PaywallContext);
14
+ return { present, isReady, catalog };
15
+ };
16
+ exports.usePaywall = usePaywall;
17
+ //# sourceMappingURL=usePaywall.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"usePaywall.js","sourceRoot":"","sources":["../../src/paywalls/usePaywall.ts"],"names":[],"mappings":";;;AAAA,iCAAmC;AACnC,uDAAmD;AAwBnD;;;;;GAKG;AACI,MAAM,UAAU,GAAG,GAAqB,EAAE;IAC/C,MAAM,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,GAAG,IAAA,kBAAU,EAAC,gCAAc,CAAC,CAAC;IACjE,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,CAAC;AACvC,CAAC,CAAC;AAHW,QAAA,UAAU,cAGrB"}
@@ -0,0 +1,15 @@
1
+ import type { ProductRuntime } from "./types";
2
+ /**
3
+ * Publishes one `ProductRuntime` above both `PaywallProvider` and
4
+ * `OnboardingProvider`, so a `PaywallProvider` mounted around an
5
+ * `OnboardingProvider` (Phase 5's `presentPaywall` arrangement) gives them one
6
+ * shared product catalog instead of each mounting its own `useProducts` — one
7
+ * store round-trip, one `purchasing` flag, for both.
8
+ *
9
+ * `null` by default: nothing above publishes a runtime, which is the normal
10
+ * case for an app that mounts only `OnboardingProvider`.
11
+ */
12
+ export declare const ProductRuntimeContext: import("react").Context<ProductRuntime | null>;
13
+ /** The ancestor `ProductRuntime`, or `null` when no provider publishes one. */
14
+ export declare const useProductRuntime: () => ProductRuntime | null;
15
+ //# sourceMappingURL=ProductRuntimeContext.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ProductRuntimeContext.d.ts","sourceRoot":"","sources":["../../src/products/ProductRuntimeContext.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAE9C;;;;;;;;;GASG;AACH,eAAO,MAAM,qBAAqB,gDAA6C,CAAC;AAEhF,+EAA+E;AAC/E,eAAO,MAAM,iBAAiB,QAAO,cAAc,GAAG,IAAyC,CAAC"}
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.useProductRuntime = exports.ProductRuntimeContext = void 0;
4
+ const react_1 = require("react");
5
+ /**
6
+ * Publishes one `ProductRuntime` above both `PaywallProvider` and
7
+ * `OnboardingProvider`, so a `PaywallProvider` mounted around an
8
+ * `OnboardingProvider` (Phase 5's `presentPaywall` arrangement) gives them one
9
+ * shared product catalog instead of each mounting its own `useProducts` — one
10
+ * store round-trip, one `purchasing` flag, for both.
11
+ *
12
+ * `null` by default: nothing above publishes a runtime, which is the normal
13
+ * case for an app that mounts only `OnboardingProvider`.
14
+ */
15
+ exports.ProductRuntimeContext = (0, react_1.createContext)(null);
16
+ /** The ancestor `ProductRuntime`, or `null` when no provider publishes one. */
17
+ const useProductRuntime = () => (0, react_1.useContext)(exports.ProductRuntimeContext);
18
+ exports.useProductRuntime = useProductRuntime;
19
+ //# sourceMappingURL=ProductRuntimeContext.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ProductRuntimeContext.js","sourceRoot":"","sources":["../../src/products/ProductRuntimeContext.tsx"],"names":[],"mappings":";;;AAAA,iCAAkD;AAGlD;;;;;;;;;GASG;AACU,QAAA,qBAAqB,GAAG,IAAA,qBAAa,EAAwB,IAAI,CAAC,CAAC;AAEhF,+EAA+E;AACxE,MAAM,iBAAiB,GAAG,GAA0B,EAAE,CAAC,IAAA,kBAAU,EAAC,6BAAqB,CAAC,CAAC;AAAnF,QAAA,iBAAiB,qBAAkE"}
@@ -3,6 +3,7 @@ export { parseIsoDuration } from "./duration";
3
3
  export { formatCurrency, deriveProductFields, deriveAll } from "./derive";
4
4
  export { productVariables } from "./toVariables";
5
5
  export { useProducts } from "./useProducts";
6
+ export { ProductRuntimeContext, useProductRuntime } from "./ProductRuntimeContext";
6
7
  export { stubProductProvider } from "./adapters/stub";
7
8
  export { revenueCatProductProvider } from "./adapters/revenueCat";
8
9
  export { expoIapProductProvider } from "./adapters/expoIap";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/products/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,UAAU,EACV,aAAa,EACb,eAAe,EACf,oBAAoB,EACpB,kBAAkB,EAClB,cAAc,EACd,aAAa,EACb,eAAe,EACf,aAAa,EACb,cAAc,GACf,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,mBAAmB,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAC1E,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,EAAE,yBAAyB,EAAE,MAAM,uBAAuB,CAAC;AAClE,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/products/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,UAAU,EACV,aAAa,EACb,eAAe,EACf,oBAAoB,EACpB,kBAAkB,EAClB,cAAc,EACd,aAAa,EACb,eAAe,EACf,aAAa,EACb,cAAc,GACf,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,mBAAmB,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAC1E,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,qBAAqB,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,CAAC;AACnF,OAAO,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AACtD,OAAO,EAAE,yBAAyB,EAAE,MAAM,uBAAuB,CAAC;AAClE,OAAO,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.expoIapProductProvider = exports.revenueCatProductProvider = exports.stubProductProvider = exports.useProducts = exports.productVariables = exports.deriveAll = exports.deriveProductFields = exports.formatCurrency = exports.parseIsoDuration = void 0;
3
+ exports.expoIapProductProvider = exports.revenueCatProductProvider = exports.stubProductProvider = exports.useProductRuntime = exports.ProductRuntimeContext = exports.useProducts = exports.productVariables = exports.deriveAll = exports.deriveProductFields = exports.formatCurrency = exports.parseIsoDuration = void 0;
4
4
  var duration_1 = require("./duration");
5
5
  Object.defineProperty(exports, "parseIsoDuration", { enumerable: true, get: function () { return duration_1.parseIsoDuration; } });
6
6
  var derive_1 = require("./derive");
@@ -11,6 +11,9 @@ var toVariables_1 = require("./toVariables");
11
11
  Object.defineProperty(exports, "productVariables", { enumerable: true, get: function () { return toVariables_1.productVariables; } });
12
12
  var useProducts_1 = require("./useProducts");
13
13
  Object.defineProperty(exports, "useProducts", { enumerable: true, get: function () { return useProducts_1.useProducts; } });
14
+ var ProductRuntimeContext_1 = require("./ProductRuntimeContext");
15
+ Object.defineProperty(exports, "ProductRuntimeContext", { enumerable: true, get: function () { return ProductRuntimeContext_1.ProductRuntimeContext; } });
16
+ Object.defineProperty(exports, "useProductRuntime", { enumerable: true, get: function () { return ProductRuntimeContext_1.useProductRuntime; } });
14
17
  var stub_1 = require("./adapters/stub");
15
18
  Object.defineProperty(exports, "stubProductProvider", { enumerable: true, get: function () { return stub_1.stubProductProvider; } });
16
19
  var revenueCat_1 = require("./adapters/revenueCat");
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/products/index.ts"],"names":[],"mappings":";;;AAYA,uCAA8C;AAArC,4GAAA,gBAAgB,OAAA;AACzB,mCAA0E;AAAjE,wGAAA,cAAc,OAAA;AAAE,6GAAA,mBAAmB,OAAA;AAAE,mGAAA,SAAS,OAAA;AACvD,6CAAiD;AAAxC,+GAAA,gBAAgB,OAAA;AACzB,6CAA4C;AAAnC,0GAAA,WAAW,OAAA;AACpB,wCAAsD;AAA7C,2GAAA,mBAAmB,OAAA;AAC5B,oDAAkE;AAAzD,uHAAA,yBAAyB,OAAA;AAClC,8CAA4D;AAAnD,iHAAA,sBAAsB,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/products/index.ts"],"names":[],"mappings":";;;AAYA,uCAA8C;AAArC,4GAAA,gBAAgB,OAAA;AACzB,mCAA0E;AAAjE,wGAAA,cAAc,OAAA;AAAE,6GAAA,mBAAmB,OAAA;AAAE,mGAAA,SAAS,OAAA;AACvD,6CAAiD;AAAxC,+GAAA,gBAAgB,OAAA;AACzB,6CAA4C;AAAnC,0GAAA,WAAW,OAAA;AACpB,iEAAmF;AAA1E,8HAAA,qBAAqB,OAAA;AAAE,0HAAA,iBAAiB,OAAA;AACjD,wCAAsD;AAA7C,2GAAA,mBAAmB,OAAA;AAC5B,oDAAkE;AAAzD,uHAAA,yBAAyB,OAAA;AAClC,8CAA4D;AAAnD,iHAAA,sBAAsB,OAAA"}
@@ -0,0 +1,55 @@
1
+ import type { ProductRuntime } from "./types";
2
+ /**
3
+ * Publishes ONE `ProductRuntime` out of the shared context runtime (a
4
+ * `PaywallProvider` ancestor's catalog union) and this `OnboardingProvider`'s
5
+ * own local resolution of its `productRefs` prop.
6
+ *
7
+ * Finding 5, 2026-08-17 final review: `OnboardingProvider` used to zero the
8
+ * local ref set out entirely whenever a context runtime existed, on the
9
+ * assumption that the paywall catalog's product union is always a superset of
10
+ * whatever `productRefs` the host declares — an assumption about a
11
+ * host-supplied prop, not a property of the code. That silently broke a
12
+ * documented Phase 3 prop the moment a host added a `PaywallProvider` above
13
+ * an existing `OnboardingProvider`: `productRefs` keys absent from the
14
+ * catalog union resolved to nothing, with no error and nothing that
15
+ * type-checks. `productRefs` is therefore ALWAYS resolved locally now,
16
+ * regardless of whether a context runtime exists (see
17
+ * `resolveLocalProductArgs`) — this function unions the result back into the
18
+ * one `ProductRuntime` the rest of the app reads.
19
+ *
20
+ * **Callers MUST memoize this** (`OnboardingProvider.tsx` wraps it in
21
+ * `useMemo`, keyed on the four arguments) — round 2 of the final review (N1)
22
+ * found the object literal below allocated fresh, plus a fresh `purchase`
23
+ * closure, on every call, which breaks `ScreenHost.products`'s "referentially
24
+ * stable across variable writes" contract when called inline in a render
25
+ * body.
26
+ *
27
+ * Returns `contextRuntime` UNCHANGED when there is nothing local to add
28
+ * (`hasLocalRefs` false — the common case: no host-declared `productRefs`),
29
+ * so the well-established "one shared runtime, no local round trip" identity
30
+ * and behavior is untouched for every app that doesn't use this prop.
31
+ *
32
+ * `purchase` routes by key: a key resolved by the LOCAL runtime purchases
33
+ * through the local provider (it is the only one that resolved it); anything
34
+ * else — including an unknown key — goes through the context runtime, which
35
+ * already reports "No resolved product for key" for that case (`useProducts.
36
+ * purchase`), so no separate handling is needed here. `restore` delegates to
37
+ * the context runtime only: restoring is a whole store-account operation, not
38
+ * scoped to individual refs, so one call through the shared adapter is
39
+ * correct even with a local ref set also present — the same billing adapter
40
+ * type is the expected real-world setup for both `productProvider` props.
41
+ *
42
+ * `hasLocalProvider` (N3, round 2): a host can declare `productRefs` with NO
43
+ * local `productProvider` — nothing unusual, since the shared context runtime
44
+ * is normally expected to cover everything. `useProducts` then never leaves
45
+ * `"idle"` for the local runtime (it bails before ever calling a provider it
46
+ * doesn't have — `useProducts.ts`), and a naive `mergeStatus` would drag the
47
+ * context runtime's `"ready"` down to `"idle"` FOREVER, closing every
48
+ * `renderWhen: {"products.loaded": {eq:"true"}}` gate for good — the same
49
+ * "idle blocks readiness when there's nothing to actually wait for" trap
50
+ * `computeIsReady` (`present.ts`) already special-cases for an empty ref set.
51
+ * When there is no local provider, the local runtime has nothing pending, so
52
+ * the merged status is just the context runtime's.
53
+ */
54
+ export declare const mergeProductRuntimes: (contextRuntime: ProductRuntime, localRuntime: ProductRuntime, hasLocalRefs: boolean, hasLocalProvider: boolean) => ProductRuntime;
55
+ //# sourceMappingURL=mergeProductRuntimes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mergeProductRuntimes.d.ts","sourceRoot":"","sources":["../../src/products/mergeProductRuntimes.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAiB,MAAM,SAAS,CAAC;AAS7D;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmDG;AACH,eAAO,MAAM,oBAAoB,GAC/B,gBAAgB,cAAc,EAC9B,cAAc,cAAc,EAC5B,cAAc,OAAO,EACrB,kBAAkB,OAAO,KACxB,cAWF,CAAC"}
@@ -0,0 +1,79 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.mergeProductRuntimes = void 0;
4
+ const mergeStatus = (a, b) => {
5
+ if (a === "error" || b === "error")
6
+ return "error";
7
+ if (a === "ready" && b === "ready")
8
+ return "ready";
9
+ if (a === "loading" || b === "loading")
10
+ return "loading";
11
+ return "idle";
12
+ };
13
+ /**
14
+ * Publishes ONE `ProductRuntime` out of the shared context runtime (a
15
+ * `PaywallProvider` ancestor's catalog union) and this `OnboardingProvider`'s
16
+ * own local resolution of its `productRefs` prop.
17
+ *
18
+ * Finding 5, 2026-08-17 final review: `OnboardingProvider` used to zero the
19
+ * local ref set out entirely whenever a context runtime existed, on the
20
+ * assumption that the paywall catalog's product union is always a superset of
21
+ * whatever `productRefs` the host declares — an assumption about a
22
+ * host-supplied prop, not a property of the code. That silently broke a
23
+ * documented Phase 3 prop the moment a host added a `PaywallProvider` above
24
+ * an existing `OnboardingProvider`: `productRefs` keys absent from the
25
+ * catalog union resolved to nothing, with no error and nothing that
26
+ * type-checks. `productRefs` is therefore ALWAYS resolved locally now,
27
+ * regardless of whether a context runtime exists (see
28
+ * `resolveLocalProductArgs`) — this function unions the result back into the
29
+ * one `ProductRuntime` the rest of the app reads.
30
+ *
31
+ * **Callers MUST memoize this** (`OnboardingProvider.tsx` wraps it in
32
+ * `useMemo`, keyed on the four arguments) — round 2 of the final review (N1)
33
+ * found the object literal below allocated fresh, plus a fresh `purchase`
34
+ * closure, on every call, which breaks `ScreenHost.products`'s "referentially
35
+ * stable across variable writes" contract when called inline in a render
36
+ * body.
37
+ *
38
+ * Returns `contextRuntime` UNCHANGED when there is nothing local to add
39
+ * (`hasLocalRefs` false — the common case: no host-declared `productRefs`),
40
+ * so the well-established "one shared runtime, no local round trip" identity
41
+ * and behavior is untouched for every app that doesn't use this prop.
42
+ *
43
+ * `purchase` routes by key: a key resolved by the LOCAL runtime purchases
44
+ * through the local provider (it is the only one that resolved it); anything
45
+ * else — including an unknown key — goes through the context runtime, which
46
+ * already reports "No resolved product for key" for that case (`useProducts.
47
+ * purchase`), so no separate handling is needed here. `restore` delegates to
48
+ * the context runtime only: restoring is a whole store-account operation, not
49
+ * scoped to individual refs, so one call through the shared adapter is
50
+ * correct even with a local ref set also present — the same billing adapter
51
+ * type is the expected real-world setup for both `productProvider` props.
52
+ *
53
+ * `hasLocalProvider` (N3, round 2): a host can declare `productRefs` with NO
54
+ * local `productProvider` — nothing unusual, since the shared context runtime
55
+ * is normally expected to cover everything. `useProducts` then never leaves
56
+ * `"idle"` for the local runtime (it bails before ever calling a provider it
57
+ * doesn't have — `useProducts.ts`), and a naive `mergeStatus` would drag the
58
+ * context runtime's `"ready"` down to `"idle"` FOREVER, closing every
59
+ * `renderWhen: {"products.loaded": {eq:"true"}}` gate for good — the same
60
+ * "idle blocks readiness when there's nothing to actually wait for" trap
61
+ * `computeIsReady` (`present.ts`) already special-cases for an empty ref set.
62
+ * When there is no local provider, the local runtime has nothing pending, so
63
+ * the merged status is just the context runtime's.
64
+ */
65
+ const mergeProductRuntimes = (contextRuntime, localRuntime, hasLocalRefs, hasLocalProvider) => {
66
+ var _a;
67
+ if (!hasLocalRefs)
68
+ return contextRuntime;
69
+ return {
70
+ products: Object.assign(Object.assign({}, contextRuntime.products), localRuntime.products),
71
+ status: hasLocalProvider ? mergeStatus(contextRuntime.status, localRuntime.status) : contextRuntime.status,
72
+ error: (_a = contextRuntime.error) !== null && _a !== void 0 ? _a : localRuntime.error,
73
+ purchasing: contextRuntime.purchasing || localRuntime.purchasing,
74
+ purchase: (key) => key in localRuntime.products ? localRuntime.purchase(key) : contextRuntime.purchase(key),
75
+ restore: contextRuntime.restore,
76
+ };
77
+ };
78
+ exports.mergeProductRuntimes = mergeProductRuntimes;
79
+ //# sourceMappingURL=mergeProductRuntimes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mergeProductRuntimes.js","sourceRoot":"","sources":["../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B/B"}
@@ -102,7 +102,28 @@ export type RestoreButtonAction = {
102
102
  onNothingToRestore?: ButtonAction[];
103
103
  onError?: ButtonAction[];
104
104
  };
105
- export type ButtonAction = "continue" | CustomButtonAction | SetVariableButtonAction | PurchaseButtonAction | RestoreButtonAction;
105
+ /** Terminal — finishes the screen with a `{ status: "dismissed" }` outcome. */
106
+ export type DismissButtonAction = {
107
+ type: "dismiss";
108
+ };
109
+ export declare const DismissButtonActionSchema: z.ZodObject<{
110
+ type: z.ZodLiteral<"dismiss">;
111
+ }, z.core.$strip>;
112
+ /**
113
+ * Asks the host to present a paywall by placement. Available from an
114
+ * onboarding step or a paywall alike — that is how an onboarding step opens a
115
+ * paywall mid-flow. No-ops (with a warning) on a host that doesn't support it.
116
+ */
117
+ export type PresentPaywallButtonAction = {
118
+ type: "presentPaywall";
119
+ /** Paywall placement key to present, e.g. "hard_paywall". */
120
+ placement: string;
121
+ };
122
+ export declare const PresentPaywallButtonActionSchema: z.ZodObject<{
123
+ type: z.ZodLiteral<"presentPaywall">;
124
+ placement: z.ZodString;
125
+ }, z.core.$strip>;
126
+ export type ButtonAction = "continue" | CustomButtonAction | SetVariableButtonAction | PurchaseButtonAction | RestoreButtonAction | DismissButtonAction | PresentPaywallButtonAction;
106
127
  export declare const PurchaseButtonActionSchema: z.ZodType<PurchaseButtonAction>;
107
128
  export declare const RestoreButtonActionSchema: z.ZodType<RestoreButtonAction>;
108
129
  export declare const ButtonActionSchema: z.ZodType<ButtonAction>;
@@ -1 +1 @@
1
- {"version":3,"file":"common.types.d.ts","sourceRoot":"","sources":["../../src/steps/common.types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,mBAAmB,kEAA0C,CAAC;AAE3E,eAAO,MAAM,iBAAiB;;;;;;mBAS5B,CAAC;AAEH,eAAO,MAAM,iBAAiB;;;;iBAI5B,CAAC;AAEH,eAAO,MAAM,aAAa;;;iBAGxB,CAAC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;;;;;;;;;;;;;;;;;;iBAa7B,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.BaseStepTypeSchema = exports.ONBOARDING_END_STEP_ID = exports.NextStepSchema = exports.BranchSchema = exports.ConditionGroupSchema = exports.LeafConditionSchema = exports.ConditionValueSchema = exports.isUnaryConditionOperator = exports.UNARY_CONDITION_OPERATORS = exports.ConditionOperatorSchema = exports.ButtonActionSchema = exports.RestoreButtonActionSchema = exports.PurchaseButtonActionSchema = exports.SetVariableButtonActionSchema = exports.CustomButtonActionSchema = exports.HapticStyleSchema = exports.ButtonSectionSchema = exports.InfoBoxSchema = exports.SocialProofSchema = exports.MediaSourceSchema = exports.CustomPayloadSchema = void 0;
3
+ exports.BaseStepTypeSchema = exports.ONBOARDING_END_STEP_ID = exports.NextStepSchema = exports.BranchSchema = exports.ConditionGroupSchema = exports.LeafConditionSchema = exports.ConditionValueSchema = exports.isUnaryConditionOperator = exports.UNARY_CONDITION_OPERATORS = exports.ConditionOperatorSchema = exports.ButtonActionSchema = exports.RestoreButtonActionSchema = exports.PurchaseButtonActionSchema = exports.PresentPaywallButtonActionSchema = exports.DismissButtonActionSchema = exports.SetVariableButtonActionSchema = exports.CustomButtonActionSchema = exports.HapticStyleSchema = exports.ButtonSectionSchema = exports.InfoBoxSchema = exports.SocialProofSchema = exports.MediaSourceSchema = exports.CustomPayloadSchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  exports.CustomPayloadSchema = zod_1.z.record(zod_1.z.string(), zod_1.z.any()).nullish();
6
6
  exports.MediaSourceSchema = zod_1.z.union([
@@ -52,6 +52,13 @@ exports.SetVariableButtonActionSchema = zod_1.z.object({
52
52
  kind: zod_1.z.enum(["int", "float", "string"]).optional(),
53
53
  arrayOp: zod_1.z.enum(["append", "remove", "toggle"]).optional(),
54
54
  });
55
+ exports.DismissButtonActionSchema = zod_1.z.object({
56
+ type: zod_1.z.literal("dismiss"),
57
+ });
58
+ exports.PresentPaywallButtonActionSchema = zod_1.z.object({
59
+ type: zod_1.z.literal("presentPaywall"),
60
+ placement: zod_1.z.string().min(1, "placement must not be empty"),
61
+ });
55
62
  exports.PurchaseButtonActionSchema = zod_1.z.lazy(() => zod_1.z.object({
56
63
  type: zod_1.z.literal("purchase"),
57
64
  product: zod_1.z.string().min(1, "product must not be empty"),
@@ -71,6 +78,8 @@ exports.ButtonActionSchema = zod_1.z.lazy(() => zod_1.z.union([
71
78
  exports.SetVariableButtonActionSchema,
72
79
  exports.PurchaseButtonActionSchema,
73
80
  exports.RestoreButtonActionSchema,
81
+ exports.DismissButtonActionSchema,
82
+ exports.PresentPaywallButtonActionSchema,
74
83
  ]));
75
84
  // ── Branching / nextStep schemas ─────────────────────────────────────────────
76
85
  exports.ConditionOperatorSchema = zod_1.z.enum([
@@ -1 +1 @@
1
- {"version":3,"file":"common.types.js","sourceRoot":"","sources":["../../src/steps/common.types.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAEX,QAAA,mBAAmB,GAAG,OAAC,CAAC,MAAM,CAAC,OAAC,CAAC,MAAM,EAAE,EAAE,OAAC,CAAC,GAAG,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC;AAE9D,QAAA,iBAAiB,GAAG,OAAC,CAAC,KAAK,CAAC;IACvC,OAAC,CAAC,MAAM,CAAC;QACP,IAAI,EAAE,OAAC,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,EAAE,CAAC,OAAC,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,CAAC,OAAC,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,CAAC,EAAE,CAAC,OAAC,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;QAC7F,WAAW,EAAE,OAAC,CAAC,MAAM,EAAE;KACxB,CAAC;IACF,OAAC,CAAC,MAAM,CAAC;QACP,IAAI,EAAE,OAAC,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,EAAE,CAAC,OA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AAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IACtC,QAAQ,EAAE,OAAC,CAAC,KAAK,CAAC,oBAAY,CAAC,CAAC,OAAO,CAAC,EAAE,CAAC;CAC5C,CAAC;KACD,QAAQ,EAAE;KACV,OAAO,CAAC,IAAI,CAAC,CAAC;AAGjB;;;;;;GAMG;AACU,QAAA,sBAAsB,GAAG,SAAS,CAAC;AAEhD,iFAAiF;AAEpE,QAAA,kBAAkB,GAAG,OAAC,CAAC,MAAM,CAAC;IACzC,2EAA2E;IAC3E,qEAAqE;IACrE,EAAE,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,KAAK,8BAAsB,EAAE;QACzD,OAAO,EAAE,IAAI,8BAAsB,8EAA8E;KAClH,CAAC;IACF,IAAI,EAAE,OAAC,CAAC,MAAM,EAAE;IAChB,qBAAqB,EAAE,OAAC,CAAC,OAAO,EAAE;IAClC,aAAa,EAAE,2BAAmB;IAClC,mBAAmB,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,CAAC,UAAU,CAAC;IAC9D,aAAa,EAAE,2BAAmB,CAAC,QAAQ,EAAE;IAC7C,QAAQ,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,OAAO,EAAE;IAC9B,QAAQ,EAAE,sBAAc;CACzB,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rocapine/react-native-onboarding",
3
- "version": "1.61.0",
3
+ "version": "1.62.0",
4
4
  "description": "Headless React Native SDK for Rocapine Onboarding Studio - Data fetching, state management, and hooks",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",