@revenuecat/purchases-js 1.58.0 → 1.60.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.
- package/dist/Purchases.es.d.ts +63 -2
- package/dist/Purchases.es.js +6679 -6451
- package/dist/Purchases.umd.js +99 -98
- package/package.json +2 -2
package/dist/Purchases.es.d.ts
CHANGED
|
@@ -566,7 +566,12 @@ declare enum LocalizationKeys {
|
|
|
566
566
|
UpgradeConfirmPageOnFile = "upgrade_confirm_page.on_file",
|
|
567
567
|
UpgradeConfirmPageEmail = "upgrade_confirm_page.email",
|
|
568
568
|
UpgradeConfirmPagePaymentMethod = "upgrade_confirm_page.payment_method",
|
|
569
|
-
UpgradeConfirmPageBillingAddress = "upgrade_confirm_page.billing_address"
|
|
569
|
+
UpgradeConfirmPageBillingAddress = "upgrade_confirm_page.billing_address",
|
|
570
|
+
PaddleCheckoutReturnTo = "paddle_checkout.return_to",
|
|
571
|
+
PaddleOrderSummaryBilledFrequency = "paddle_order_summary.billed_frequency",
|
|
572
|
+
PaddleOrderSummaryIntroThenRecurring = "paddle_order_summary.intro_then_recurring",
|
|
573
|
+
PaddleOrderSummaryIncTax = "paddle_order_summary.inc_tax",
|
|
574
|
+
PaddleOrderSummaryDueOn = "paddle_order_summary.due_on"
|
|
570
575
|
}
|
|
571
576
|
|
|
572
577
|
/**
|
|
@@ -832,11 +837,67 @@ export declare enum PackageType {
|
|
|
832
837
|
Weekly = "$rc_weekly"
|
|
833
838
|
}
|
|
834
839
|
|
|
840
|
+
/**
|
|
841
|
+
* Known values of `component_type` in {@link PaywallInteractionEvent}.
|
|
842
|
+
* @public
|
|
843
|
+
*/
|
|
844
|
+
export declare const PAYWALL_COMPONENT_TYPES: {
|
|
845
|
+
readonly TAB: "tab";
|
|
846
|
+
readonly SWITCH: "switch";
|
|
847
|
+
readonly CAROUSEL: "carousel";
|
|
848
|
+
readonly BUTTON: "button";
|
|
849
|
+
readonly TEXT: "text";
|
|
850
|
+
readonly PACKAGE: "package";
|
|
851
|
+
readonly PACKAGE_SELECTION_SHEET: "package_selection_sheet";
|
|
852
|
+
readonly PURCHASE_BUTTON: "purchase_button";
|
|
853
|
+
};
|
|
854
|
+
|
|
855
|
+
/**
|
|
856
|
+
* A paywall control interaction, as passed to `PaywallListener.onInteraction`. Keys that do not apply
|
|
857
|
+
* are omitted.
|
|
858
|
+
* @public
|
|
859
|
+
*/
|
|
860
|
+
export declare interface PaywallInteractionEvent {
|
|
861
|
+
readonly timestamp: number;
|
|
862
|
+
readonly session_id: string;
|
|
863
|
+
readonly offering_id: string;
|
|
864
|
+
readonly paywall_id?: string;
|
|
865
|
+
readonly paywall_revision: number;
|
|
866
|
+
readonly display_mode?: string;
|
|
867
|
+
readonly dark_mode?: boolean;
|
|
868
|
+
readonly locale?: string;
|
|
869
|
+
readonly component_type: string;
|
|
870
|
+
readonly component_value: string;
|
|
871
|
+
readonly component_name?: string;
|
|
872
|
+
readonly component_url?: string;
|
|
873
|
+
readonly origin_index?: number;
|
|
874
|
+
readonly destination_index?: number;
|
|
875
|
+
readonly origin_context_name?: string;
|
|
876
|
+
readonly destination_context_name?: string;
|
|
877
|
+
readonly default_index?: number;
|
|
878
|
+
readonly origin_package_id?: string;
|
|
879
|
+
readonly destination_package_id?: string;
|
|
880
|
+
readonly default_package_id?: string;
|
|
881
|
+
readonly current_package_id?: string;
|
|
882
|
+
readonly resulting_package_id?: string;
|
|
883
|
+
readonly origin_product_id?: string;
|
|
884
|
+
readonly destination_product_id?: string;
|
|
885
|
+
readonly default_product_id?: string;
|
|
886
|
+
readonly current_product_id?: string;
|
|
887
|
+
readonly resulting_product_id?: string;
|
|
888
|
+
}
|
|
889
|
+
|
|
835
890
|
/**
|
|
836
891
|
* Listener for paywall purchase lifecycle events.
|
|
837
892
|
* @public
|
|
838
893
|
*/
|
|
839
|
-
export declare type PaywallListener = PurchaseListener
|
|
894
|
+
export declare type PaywallListener = PurchaseListener & {
|
|
895
|
+
/**
|
|
896
|
+
* Called when the user interacts with a paywall control.
|
|
897
|
+
* Exceptions thrown here are logged and do not affect the paywall.
|
|
898
|
+
*/
|
|
899
|
+
onInteraction?: (event: PaywallInteractionEvent) => void;
|
|
900
|
+
};
|
|
840
901
|
|
|
841
902
|
/**
|
|
842
903
|
* Represents the result of a purchase operation initiated from a paywall.
|