@stigg/js-client-sdk 3.20.0 → 3.21.1
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/index.js +116 -8
- package/dist/index.js.map +1 -1
- package/dist/models.d.ts +1 -0
- package/dist/services/cachedEntitlement.d.ts +2 -1
- package/dist/services/entitlementsService.d.ts +1 -1
- package/dist/src/models.d.ts +1 -0
- package/dist/src/services/cachedEntitlement.d.ts +2 -1
- package/dist/src/services/entitlementsService.d.ts +1 -1
- package/package.json +2 -2
package/dist/models.d.ts
CHANGED
|
@@ -418,6 +418,7 @@ export declare type ImmediateSubscriptionPreviewInvoice = SubscriptionPreviewInv
|
|
|
418
418
|
credits?: SubscriptionPreviewCredits;
|
|
419
419
|
};
|
|
420
420
|
export declare type SubscriptionPreviewDiscount = {
|
|
421
|
+
name?: string | null;
|
|
421
422
|
type: DiscountType;
|
|
422
423
|
value: number;
|
|
423
424
|
durationType: DiscountDurationType;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { EntitlementFeature, EntitlementResetPeriod } from '../models';
|
|
2
|
-
import { ResetPeriodConfigurationFragment } from '@stigg/api-client-js/src/generated/sdk';
|
|
2
|
+
import { AccessDeniedReason, ResetPeriodConfigurationFragment } from '@stigg/api-client-js/src/generated/sdk';
|
|
3
3
|
export interface CalculatedEntitlement {
|
|
4
4
|
usageLimit?: number | null;
|
|
5
5
|
hasUnlimitedUsage: boolean;
|
|
6
6
|
hasSoftLimit: boolean;
|
|
7
7
|
feature?: EntitlementFeature;
|
|
8
|
+
accessDeniedReason?: AccessDeniedReason;
|
|
8
9
|
}
|
|
9
10
|
export interface EntitlementUsage {
|
|
10
11
|
currentUsage: number;
|
|
@@ -26,7 +26,7 @@ export declare class EntitlementsService {
|
|
|
26
26
|
private loadEntitlementsFromRemote;
|
|
27
27
|
protected storeFetchedEntitlementsInCache(entitlements: EntitlementFragment[]): void;
|
|
28
28
|
private getLastEntitlementsUpdate;
|
|
29
|
-
private
|
|
29
|
+
private getEntitlement;
|
|
30
30
|
getEntitlements(): Promise<BooleanEntitlement[]>;
|
|
31
31
|
renewOutdatedCache(renewCondition: () => boolean): Promise<void>;
|
|
32
32
|
renewOutdatedCacheInBackground(renewCondition: () => boolean): void;
|
package/dist/src/models.d.ts
CHANGED
|
@@ -418,6 +418,7 @@ export declare type ImmediateSubscriptionPreviewInvoice = SubscriptionPreviewInv
|
|
|
418
418
|
credits?: SubscriptionPreviewCredits;
|
|
419
419
|
};
|
|
420
420
|
export declare type SubscriptionPreviewDiscount = {
|
|
421
|
+
name?: string | null;
|
|
421
422
|
type: DiscountType;
|
|
422
423
|
value: number;
|
|
423
424
|
durationType: DiscountDurationType;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { EntitlementFeature, EntitlementResetPeriod } from '../models';
|
|
2
|
-
import { ResetPeriodConfigurationFragment } from '@stigg/api-client-js/src/generated/sdk';
|
|
2
|
+
import { AccessDeniedReason, ResetPeriodConfigurationFragment } from '@stigg/api-client-js/src/generated/sdk';
|
|
3
3
|
export interface CalculatedEntitlement {
|
|
4
4
|
usageLimit?: number | null;
|
|
5
5
|
hasUnlimitedUsage: boolean;
|
|
6
6
|
hasSoftLimit: boolean;
|
|
7
7
|
feature?: EntitlementFeature;
|
|
8
|
+
accessDeniedReason?: AccessDeniedReason;
|
|
8
9
|
}
|
|
9
10
|
export interface EntitlementUsage {
|
|
10
11
|
currentUsage: number;
|
|
@@ -26,7 +26,7 @@ export declare class EntitlementsService {
|
|
|
26
26
|
private loadEntitlementsFromRemote;
|
|
27
27
|
protected storeFetchedEntitlementsInCache(entitlements: EntitlementFragment[]): void;
|
|
28
28
|
private getLastEntitlementsUpdate;
|
|
29
|
-
private
|
|
29
|
+
private getEntitlement;
|
|
30
30
|
getEntitlements(): Promise<BooleanEntitlement[]>;
|
|
31
31
|
renewOutdatedCache(renewCondition: () => boolean): Promise<void>;
|
|
32
32
|
renewOutdatedCacheInBackground(renewCondition: () => boolean): void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stigg/js-client-sdk",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.21.1",
|
|
4
4
|
"description": "Stigg client-side SDK for Browser",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"typings": "dist/index.d.ts",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"dependencies": {
|
|
29
29
|
"@apollo/client": "^3.4.17",
|
|
30
30
|
"@sentry/browser": "^7.11.1",
|
|
31
|
-
"@stigg/api-client-js": "
|
|
31
|
+
"@stigg/api-client-js": "2.85.7",
|
|
32
32
|
"cross-fetch": "^3.1.6",
|
|
33
33
|
"fetch-retry": "^5.0.6",
|
|
34
34
|
"husky": "^7.0.4",
|