@namiml/web-sdk 1.0.0 → 1.1.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/CHANGELOG.md +20 -2
- package/dist/nami-web.cjs +12 -12
- package/dist/nami-web.d.ts +12 -3
- package/dist/nami-web.js +14 -14
- package/dist/nami-web.mjs +14 -14
- package/dist/nami-web.umd.js +15 -15
- package/package.json +10 -3
package/dist/nami-web.d.ts
CHANGED
|
@@ -98,6 +98,7 @@ type TButtonContainer = TBaseComponent & {
|
|
|
98
98
|
component: "button";
|
|
99
99
|
actionTap: string;
|
|
100
100
|
onTap?: UserAction;
|
|
101
|
+
sku?: SelectableItemType;
|
|
101
102
|
components: Array<TTextComponent | TTextListComponent | TSpacerComponent | TImageComponent>;
|
|
102
103
|
};
|
|
103
104
|
type UserAction = {
|
|
@@ -345,12 +346,13 @@ type TPaywallContext = TInitialState & {
|
|
|
345
346
|
type SelectableItemType = {
|
|
346
347
|
id: string;
|
|
347
348
|
sku_id: string;
|
|
349
|
+
promo_id: string;
|
|
348
350
|
featured: boolean;
|
|
349
351
|
selected: boolean;
|
|
350
352
|
name: string;
|
|
351
353
|
sku_ref_id: string;
|
|
352
354
|
sku_type: string;
|
|
353
|
-
product_details
|
|
355
|
+
product_details?: NamiProductDetails;
|
|
354
356
|
[key: string]: any;
|
|
355
357
|
variables: {
|
|
356
358
|
[key: string]: any;
|
|
@@ -461,7 +463,7 @@ declare enum NamiPaywallAction {
|
|
|
461
463
|
}
|
|
462
464
|
type NamiPaywallEvent = {
|
|
463
465
|
action: NamiPaywallAction;
|
|
464
|
-
|
|
466
|
+
sku?: SelectableItemType;
|
|
465
467
|
campaignId: string;
|
|
466
468
|
campaignName: string;
|
|
467
469
|
paywallId: string;
|
|
@@ -509,6 +511,7 @@ declare class ContextConsumer implements ReactiveController {
|
|
|
509
511
|
}
|
|
510
512
|
declare class NamiElement extends LitElement {
|
|
511
513
|
contextConsumer: ContextConsumer;
|
|
514
|
+
constructor();
|
|
512
515
|
protected styles(): CSSResult;
|
|
513
516
|
createRenderRoot(): HTMLElement | DocumentFragment;
|
|
514
517
|
disconnectedCallback(): void;
|
|
@@ -640,7 +643,7 @@ declare class NamiCustomerManager {
|
|
|
640
643
|
* @param enabled - A boolean value indicating whether the anonymous mode should be enabled or disabled.
|
|
641
644
|
* @returns A Promise that resolves when the anonymous mode is set.
|
|
642
645
|
*/
|
|
643
|
-
static setAnonymousMode(enabled: boolean): void
|
|
646
|
+
static setAnonymousMode(enabled: boolean): Promise<void>;
|
|
644
647
|
/**
|
|
645
648
|
* Returns whether or not the SDK is currently operating in anonymous mode
|
|
646
649
|
*/
|
|
@@ -679,6 +682,12 @@ declare class NamiCustomerManager {
|
|
|
679
682
|
*/
|
|
680
683
|
private get isSDKInitialized();
|
|
681
684
|
private static updateCustomerDataPlatformId;
|
|
685
|
+
/**
|
|
686
|
+
* Returns whether or not the configured app platform id belongs to an anonymous mode
|
|
687
|
+
* capable Nami account.
|
|
688
|
+
*/
|
|
689
|
+
private static anonymousModeCapability;
|
|
690
|
+
private static refetchConfig;
|
|
682
691
|
}
|
|
683
692
|
declare class NamiPaywallManager {
|
|
684
693
|
static instance: NamiPaywallManager;
|