@schematichq/schematic-components 2.9.1 → 2.10.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/schematic-components.cjs.js +3946 -2946
- package/dist/schematic-components.d.ts +216 -29
- package/dist/schematic-components.esm.js +3592 -2592
- package/package.json +18 -17
|
@@ -27,6 +27,11 @@ declare interface AddOnsProps {
|
|
|
27
27
|
currency?: string;
|
|
28
28
|
}
|
|
29
29
|
|
|
30
|
+
export declare interface AvailableCurrenciesResult {
|
|
31
|
+
currencies: string[];
|
|
32
|
+
invalidFilterEntries: string[];
|
|
33
|
+
}
|
|
34
|
+
|
|
30
35
|
declare interface AvailablePlanOptions {
|
|
31
36
|
useSelectedPeriod?: boolean;
|
|
32
37
|
}
|
|
@@ -2224,6 +2229,7 @@ declare interface BillingProductResponseData_2 {
|
|
|
2224
2229
|
* @export
|
|
2225
2230
|
*/
|
|
2226
2231
|
declare const BillingProviderType: {
|
|
2232
|
+
readonly Orb: "orb";
|
|
2227
2233
|
readonly Schematic: "schematic";
|
|
2228
2234
|
readonly Stripe: "stripe";
|
|
2229
2235
|
};
|
|
@@ -2235,6 +2241,7 @@ declare type BillingProviderType = (typeof BillingProviderType)[keyof typeof Bil
|
|
|
2235
2241
|
* @export
|
|
2236
2242
|
*/
|
|
2237
2243
|
declare const BillingProviderType_2: {
|
|
2244
|
+
readonly Orb: "orb";
|
|
2238
2245
|
readonly Schematic: "schematic";
|
|
2239
2246
|
readonly Stripe: "stripe";
|
|
2240
2247
|
};
|
|
@@ -3115,6 +3122,12 @@ declare interface CompanyDetailResponseData {
|
|
|
3115
3122
|
* @memberof CompanyDetailResponseData
|
|
3116
3123
|
*/
|
|
3117
3124
|
createdAt: Date;
|
|
3125
|
+
/**
|
|
3126
|
+
*
|
|
3127
|
+
* @type {Array<CustomPlanBillingResponseData>}
|
|
3128
|
+
* @memberof CompanyDetailResponseData
|
|
3129
|
+
*/
|
|
3130
|
+
customPlanBillings: Array<CustomPlanBillingResponseData>;
|
|
3118
3131
|
/**
|
|
3119
3132
|
*
|
|
3120
3133
|
* @type {PaymentMethodResponseData}
|
|
@@ -3542,6 +3555,18 @@ declare interface CompanyPlanDetailResponseData {
|
|
|
3542
3555
|
* @memberof CompanyPlanDetailResponseData
|
|
3543
3556
|
*/
|
|
3544
3557
|
companyCount: number;
|
|
3558
|
+
/**
|
|
3559
|
+
*
|
|
3560
|
+
* @type {string}
|
|
3561
|
+
* @memberof CompanyPlanDetailResponseData
|
|
3562
|
+
*/
|
|
3563
|
+
companyId?: string | null;
|
|
3564
|
+
/**
|
|
3565
|
+
*
|
|
3566
|
+
* @type {string}
|
|
3567
|
+
* @memberof CompanyPlanDetailResponseData
|
|
3568
|
+
*/
|
|
3569
|
+
companyName?: string | null;
|
|
3545
3570
|
/**
|
|
3546
3571
|
*
|
|
3547
3572
|
* @type {Array<string>}
|
|
@@ -3550,10 +3575,16 @@ declare interface CompanyPlanDetailResponseData {
|
|
|
3550
3575
|
compatiblePlanIds: Array<string>;
|
|
3551
3576
|
/**
|
|
3552
3577
|
*
|
|
3553
|
-
* @type {
|
|
3578
|
+
* @type {string}
|
|
3579
|
+
* @memberof CompanyPlanDetailResponseData
|
|
3580
|
+
*/
|
|
3581
|
+
controlledBy: string;
|
|
3582
|
+
/**
|
|
3583
|
+
*
|
|
3584
|
+
* @type {string}
|
|
3554
3585
|
* @memberof CompanyPlanDetailResponseData
|
|
3555
3586
|
*/
|
|
3556
|
-
|
|
3587
|
+
copiedFromPlanId?: string | null;
|
|
3557
3588
|
/**
|
|
3558
3589
|
*
|
|
3559
3590
|
* @type {Date}
|
|
@@ -5077,6 +5108,103 @@ declare interface CurrencyBalance {
|
|
|
5077
5108
|
currency: string;
|
|
5078
5109
|
}
|
|
5079
5110
|
|
|
5111
|
+
/**
|
|
5112
|
+
*
|
|
5113
|
+
* @export
|
|
5114
|
+
*/
|
|
5115
|
+
declare const CustomPlanActivationStrategy: {
|
|
5116
|
+
readonly Payment: "on_payment";
|
|
5117
|
+
readonly Publish: "on_publish";
|
|
5118
|
+
};
|
|
5119
|
+
|
|
5120
|
+
declare type CustomPlanActivationStrategy = (typeof CustomPlanActivationStrategy)[keyof typeof CustomPlanActivationStrategy];
|
|
5121
|
+
|
|
5122
|
+
/**
|
|
5123
|
+
*
|
|
5124
|
+
* @export
|
|
5125
|
+
* @interface CustomPlanBillingResponseData
|
|
5126
|
+
*/
|
|
5127
|
+
declare interface CustomPlanBillingResponseData {
|
|
5128
|
+
/**
|
|
5129
|
+
*
|
|
5130
|
+
* @type {CustomPlanActivationStrategy}
|
|
5131
|
+
* @memberof CustomPlanBillingResponseData
|
|
5132
|
+
*/
|
|
5133
|
+
activationStrategy: CustomPlanActivationStrategy;
|
|
5134
|
+
/**
|
|
5135
|
+
*
|
|
5136
|
+
* @type {string}
|
|
5137
|
+
* @memberof CustomPlanBillingResponseData
|
|
5138
|
+
*/
|
|
5139
|
+
companyId: string;
|
|
5140
|
+
/**
|
|
5141
|
+
*
|
|
5142
|
+
* @type {Date}
|
|
5143
|
+
* @memberof CustomPlanBillingResponseData
|
|
5144
|
+
*/
|
|
5145
|
+
createdAt: Date;
|
|
5146
|
+
/**
|
|
5147
|
+
*
|
|
5148
|
+
* @type {number}
|
|
5149
|
+
* @memberof CustomPlanBillingResponseData
|
|
5150
|
+
*/
|
|
5151
|
+
daysUntilDue: number;
|
|
5152
|
+
/**
|
|
5153
|
+
*
|
|
5154
|
+
* @type {string}
|
|
5155
|
+
* @memberof CustomPlanBillingResponseData
|
|
5156
|
+
*/
|
|
5157
|
+
id: string;
|
|
5158
|
+
/**
|
|
5159
|
+
*
|
|
5160
|
+
* @type {Date}
|
|
5161
|
+
* @memberof CustomPlanBillingResponseData
|
|
5162
|
+
*/
|
|
5163
|
+
paidAt?: Date | null;
|
|
5164
|
+
/**
|
|
5165
|
+
*
|
|
5166
|
+
* @type {string}
|
|
5167
|
+
* @memberof CustomPlanBillingResponseData
|
|
5168
|
+
*/
|
|
5169
|
+
planId: string;
|
|
5170
|
+
/**
|
|
5171
|
+
*
|
|
5172
|
+
* @type {Date}
|
|
5173
|
+
* @memberof CustomPlanBillingResponseData
|
|
5174
|
+
*/
|
|
5175
|
+
publishedAt?: Date | null;
|
|
5176
|
+
/**
|
|
5177
|
+
*
|
|
5178
|
+
* @type {CustomPlanBillingStatus}
|
|
5179
|
+
* @memberof CustomPlanBillingResponseData
|
|
5180
|
+
*/
|
|
5181
|
+
status: CustomPlanBillingStatus;
|
|
5182
|
+
/**
|
|
5183
|
+
*
|
|
5184
|
+
* @type {string}
|
|
5185
|
+
* @memberof CustomPlanBillingResponseData
|
|
5186
|
+
*/
|
|
5187
|
+
stripeInvoiceUrl?: string | null;
|
|
5188
|
+
/**
|
|
5189
|
+
*
|
|
5190
|
+
* @type {Date}
|
|
5191
|
+
* @memberof CustomPlanBillingResponseData
|
|
5192
|
+
*/
|
|
5193
|
+
updatedAt: Date;
|
|
5194
|
+
}
|
|
5195
|
+
|
|
5196
|
+
/**
|
|
5197
|
+
*
|
|
5198
|
+
* @export
|
|
5199
|
+
*/
|
|
5200
|
+
declare const CustomPlanBillingStatus: {
|
|
5201
|
+
readonly Active: "active";
|
|
5202
|
+
readonly Paid: "paid";
|
|
5203
|
+
readonly Pending: "pending";
|
|
5204
|
+
};
|
|
5205
|
+
|
|
5206
|
+
declare type CustomPlanBillingStatus = (typeof CustomPlanBillingStatus)[keyof typeof CustomPlanBillingStatus];
|
|
5207
|
+
|
|
5080
5208
|
/**
|
|
5081
5209
|
* Schematic API
|
|
5082
5210
|
* Schematic API
|
|
@@ -5497,7 +5625,7 @@ export declare interface EmbedProps {
|
|
|
5497
5625
|
accessToken?: string;
|
|
5498
5626
|
}
|
|
5499
5627
|
|
|
5500
|
-
export declare const EmbedProvider: ({ children, apiKey, apiConfig, ...options }: EmbedProviderProps) => JSX.Element;
|
|
5628
|
+
export declare const EmbedProvider: ({ children, apiKey, apiConfig, currencyFilter, ...options }: EmbedProviderProps) => JSX.Element;
|
|
5501
5629
|
|
|
5502
5630
|
export declare interface EmbedProviderProps {
|
|
5503
5631
|
children: React.ReactNode;
|
|
@@ -5505,6 +5633,12 @@ export declare interface EmbedProviderProps {
|
|
|
5505
5633
|
apiConfig?: ConfigurationParameters;
|
|
5506
5634
|
settings?: DeepPartial<EmbedSettings>;
|
|
5507
5635
|
debug?: boolean;
|
|
5636
|
+
/**
|
|
5637
|
+
* Restricts which currencies are presented in components that support
|
|
5638
|
+
* multi-currency display (PricingTable, CheckoutDialog). Entries are
|
|
5639
|
+
* ISO-4217 codes; case-insensitive. Omit to disable filtering.
|
|
5640
|
+
*/
|
|
5641
|
+
currencyFilter?: string[];
|
|
5508
5642
|
}
|
|
5509
5643
|
|
|
5510
5644
|
export declare type EmbedSettings = {
|
|
@@ -5525,6 +5659,7 @@ export declare interface EmbedState {
|
|
|
5525
5659
|
settings: EmbedSettings;
|
|
5526
5660
|
layout: EmbedLayout;
|
|
5527
5661
|
checkoutState?: CheckoutState;
|
|
5662
|
+
currencyFilter?: string[];
|
|
5528
5663
|
}
|
|
5529
5664
|
|
|
5530
5665
|
export declare const Entitlement: ({ entitlement, period, credits, tooltipPortal, currency: selectedCurrency, }: EntitlementProps) => JSX.Element;
|
|
@@ -7303,6 +7438,7 @@ export declare const initialContext: {
|
|
|
7303
7438
|
settings: EmbedSettings;
|
|
7304
7439
|
layout: EmbedLayout;
|
|
7305
7440
|
checkoutState?: CheckoutState;
|
|
7441
|
+
currencyFilter?: string[];
|
|
7306
7442
|
};
|
|
7307
7443
|
|
|
7308
7444
|
export declare const initialState: EmbedState;
|
|
@@ -7708,28 +7844,6 @@ export declare const Plan: ({ isLoading, plans, selectedPlan, period, selectPlan
|
|
|
7708
7844
|
|
|
7709
7845
|
declare type Plan_2 = CompanyPlanDetailResponseData;
|
|
7710
7846
|
|
|
7711
|
-
/**
|
|
7712
|
-
*
|
|
7713
|
-
* @export
|
|
7714
|
-
*/
|
|
7715
|
-
declare const PlanControlledByType: {
|
|
7716
|
-
readonly Schematic: "schematic";
|
|
7717
|
-
readonly Stripe: "stripe";
|
|
7718
|
-
};
|
|
7719
|
-
|
|
7720
|
-
declare type PlanControlledByType = (typeof PlanControlledByType)[keyof typeof PlanControlledByType];
|
|
7721
|
-
|
|
7722
|
-
/**
|
|
7723
|
-
*
|
|
7724
|
-
* @export
|
|
7725
|
-
*/
|
|
7726
|
-
declare const PlanControlledByType_2: {
|
|
7727
|
-
readonly Schematic: "schematic";
|
|
7728
|
-
readonly Stripe: "stripe";
|
|
7729
|
-
};
|
|
7730
|
-
|
|
7731
|
-
declare type PlanControlledByType_2 = (typeof PlanControlledByType_2)[keyof typeof PlanControlledByType_2];
|
|
7732
|
-
|
|
7733
7847
|
/**
|
|
7734
7848
|
*
|
|
7735
7849
|
* @export
|
|
@@ -8201,10 +8315,28 @@ declare interface PlanDetailResponseData {
|
|
|
8201
8315
|
companyCount: number;
|
|
8202
8316
|
/**
|
|
8203
8317
|
*
|
|
8204
|
-
* @type {
|
|
8318
|
+
* @type {string}
|
|
8205
8319
|
* @memberof PlanDetailResponseData
|
|
8206
8320
|
*/
|
|
8207
|
-
|
|
8321
|
+
companyId?: string | null;
|
|
8322
|
+
/**
|
|
8323
|
+
*
|
|
8324
|
+
* @type {string}
|
|
8325
|
+
* @memberof PlanDetailResponseData
|
|
8326
|
+
*/
|
|
8327
|
+
companyName?: string | null;
|
|
8328
|
+
/**
|
|
8329
|
+
*
|
|
8330
|
+
* @type {string}
|
|
8331
|
+
* @memberof PlanDetailResponseData
|
|
8332
|
+
*/
|
|
8333
|
+
controlledBy: string;
|
|
8334
|
+
/**
|
|
8335
|
+
*
|
|
8336
|
+
* @type {string}
|
|
8337
|
+
* @memberof PlanDetailResponseData
|
|
8338
|
+
*/
|
|
8339
|
+
copiedFromPlanId?: string | null;
|
|
8208
8340
|
/**
|
|
8209
8341
|
*
|
|
8210
8342
|
* @type {Date}
|
|
@@ -8764,6 +8896,18 @@ declare interface PlanResponseData {
|
|
|
8764
8896
|
* @deprecated
|
|
8765
8897
|
*/
|
|
8766
8898
|
audienceType?: string | null;
|
|
8899
|
+
/**
|
|
8900
|
+
*
|
|
8901
|
+
* @type {string}
|
|
8902
|
+
* @memberof PlanResponseData
|
|
8903
|
+
*/
|
|
8904
|
+
companyId?: string | null;
|
|
8905
|
+
/**
|
|
8906
|
+
*
|
|
8907
|
+
* @type {string}
|
|
8908
|
+
* @memberof PlanResponseData
|
|
8909
|
+
*/
|
|
8910
|
+
copiedFromPlanId?: string | null;
|
|
8767
8911
|
/**
|
|
8768
8912
|
*
|
|
8769
8913
|
* @type {Date}
|
|
@@ -8821,6 +8965,18 @@ declare interface PlanResponseData_2 {
|
|
|
8821
8965
|
* @deprecated
|
|
8822
8966
|
*/
|
|
8823
8967
|
audienceType?: string | null;
|
|
8968
|
+
/**
|
|
8969
|
+
*
|
|
8970
|
+
* @type {string}
|
|
8971
|
+
* @memberof PlanResponseData
|
|
8972
|
+
*/
|
|
8973
|
+
companyId?: string | null;
|
|
8974
|
+
/**
|
|
8975
|
+
*
|
|
8976
|
+
* @type {string}
|
|
8977
|
+
* @memberof PlanResponseData
|
|
8978
|
+
*/
|
|
8979
|
+
copiedFromPlanId?: string | null;
|
|
8824
8980
|
/**
|
|
8825
8981
|
*
|
|
8826
8982
|
* @type {Date}
|
|
@@ -9102,6 +9258,18 @@ declare interface PlanViewPublicResponseData {
|
|
|
9102
9258
|
* @memberof PlanViewPublicResponseData
|
|
9103
9259
|
*/
|
|
9104
9260
|
companyCount: number;
|
|
9261
|
+
/**
|
|
9262
|
+
*
|
|
9263
|
+
* @type {string}
|
|
9264
|
+
* @memberof PlanViewPublicResponseData
|
|
9265
|
+
*/
|
|
9266
|
+
companyId?: string | null;
|
|
9267
|
+
/**
|
|
9268
|
+
*
|
|
9269
|
+
* @type {string}
|
|
9270
|
+
* @memberof PlanViewPublicResponseData
|
|
9271
|
+
*/
|
|
9272
|
+
companyName?: string | null;
|
|
9105
9273
|
/**
|
|
9106
9274
|
*
|
|
9107
9275
|
* @type {Array<string>}
|
|
@@ -9110,10 +9278,16 @@ declare interface PlanViewPublicResponseData {
|
|
|
9110
9278
|
compatiblePlanIds: Array<string>;
|
|
9111
9279
|
/**
|
|
9112
9280
|
*
|
|
9113
|
-
* @type {
|
|
9281
|
+
* @type {string}
|
|
9114
9282
|
* @memberof PlanViewPublicResponseData
|
|
9115
9283
|
*/
|
|
9116
|
-
controlledBy:
|
|
9284
|
+
controlledBy: string;
|
|
9285
|
+
/**
|
|
9286
|
+
*
|
|
9287
|
+
* @type {string}
|
|
9288
|
+
* @memberof PlanViewPublicResponseData
|
|
9289
|
+
*/
|
|
9290
|
+
copiedFromPlanId?: string | null;
|
|
9117
9291
|
/**
|
|
9118
9292
|
*
|
|
9119
9293
|
* @type {Date}
|
|
@@ -10976,8 +11150,21 @@ declare interface UsageBasedEntitlementResponseData {
|
|
|
10976
11150
|
yearlyUsageBasedPrice?: BillingPriceView;
|
|
10977
11151
|
}
|
|
10978
11152
|
|
|
11153
|
+
/**
|
|
11154
|
+
* Returns the currencies that should be displayed in the UI. When a
|
|
11155
|
+
* `currencyFilter` is configured on EmbedProvider, this is the intersection
|
|
11156
|
+
* of the filter with the hydrated currency set. Otherwise it is the full
|
|
11157
|
+
* hydrated set.
|
|
11158
|
+
*/
|
|
10979
11159
|
export declare function useAvailableCurrencies(): string[];
|
|
10980
11160
|
|
|
11161
|
+
/**
|
|
11162
|
+
* Like `useAvailableCurrencies` but also returns the list of filter entries
|
|
11163
|
+
* that did not match any currency in the hydrated data. Consumers can render
|
|
11164
|
+
* an error notice and (optionally) log these invalid inputs.
|
|
11165
|
+
*/
|
|
11166
|
+
export declare function useAvailableCurrenciesWithInvalid(): AvailableCurrenciesResult;
|
|
11167
|
+
|
|
10981
11168
|
export declare function useAvailablePlans(activePeriod: string, options?: AvailablePlanOptions): {
|
|
10982
11169
|
plans: SelectedPlan[];
|
|
10983
11170
|
addOns: SelectedPlan[];
|