@schematichq/schematic-components 2.8.2 → 2.8.3
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 +265 -136
- package/dist/schematic-components.d.ts +230 -0
- package/dist/schematic-components.esm.js +265 -136
- package/package.json +4 -4
|
@@ -2191,6 +2191,72 @@ function BillingProductPriceResponseDataFromJSONTyped(json, ignoreDiscriminator)
|
|
|
2191
2191
|
};
|
|
2192
2192
|
}
|
|
2193
2193
|
|
|
2194
|
+
// src/api/checkoutexternal/models/BillingProductPriceTierResponseData.ts
|
|
2195
|
+
function BillingProductPriceTierResponseDataFromJSON(json) {
|
|
2196
|
+
return BillingProductPriceTierResponseDataFromJSONTyped(json, false);
|
|
2197
|
+
}
|
|
2198
|
+
function BillingProductPriceTierResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
2199
|
+
if (json == null) {
|
|
2200
|
+
return json;
|
|
2201
|
+
}
|
|
2202
|
+
return {
|
|
2203
|
+
flatAmount: json["flat_amount"] == null ? void 0 : json["flat_amount"],
|
|
2204
|
+
perUnitPrice: json["per_unit_price"] == null ? void 0 : json["per_unit_price"],
|
|
2205
|
+
perUnitPriceDecimal: json["per_unit_price_decimal"] == null ? void 0 : json["per_unit_price_decimal"],
|
|
2206
|
+
upTo: json["up_to"] == null ? void 0 : json["up_to"]
|
|
2207
|
+
};
|
|
2208
|
+
}
|
|
2209
|
+
|
|
2210
|
+
// src/api/checkoutexternal/models/BillingPriceView.ts
|
|
2211
|
+
function BillingPriceViewFromJSON(json) {
|
|
2212
|
+
return BillingPriceViewFromJSONTyped(json, false);
|
|
2213
|
+
}
|
|
2214
|
+
function BillingPriceViewFromJSONTyped(json, ignoreDiscriminator) {
|
|
2215
|
+
if (json == null) {
|
|
2216
|
+
return json;
|
|
2217
|
+
}
|
|
2218
|
+
return {
|
|
2219
|
+
billingScheme: BillingPriceSchemeFromJSON(json["billing_scheme"]),
|
|
2220
|
+
createdAt: new Date(json["created_at"]),
|
|
2221
|
+
currency: json["currency"],
|
|
2222
|
+
id: json["id"],
|
|
2223
|
+
interval: BillingProductPriceIntervalFromJSON(json["interval"]),
|
|
2224
|
+
isActive: json["is_active"],
|
|
2225
|
+
meterEventName: json["meter_event_name"] == null ? void 0 : json["meter_event_name"],
|
|
2226
|
+
meterEventPayloadKey: json["meter_event_payload_key"] == null ? void 0 : json["meter_event_payload_key"],
|
|
2227
|
+
meterId: json["meter_id"] == null ? void 0 : json["meter_id"],
|
|
2228
|
+
packageSize: json["package_size"],
|
|
2229
|
+
price: json["price"],
|
|
2230
|
+
priceDecimal: json["price_decimal"] == null ? void 0 : json["price_decimal"],
|
|
2231
|
+
priceExternalId: json["price_external_id"],
|
|
2232
|
+
priceId: json["price_id"],
|
|
2233
|
+
priceTier: json["price_tier"].map(
|
|
2234
|
+
BillingProductPriceTierResponseDataFromJSON
|
|
2235
|
+
),
|
|
2236
|
+
productExternalId: json["product_external_id"],
|
|
2237
|
+
productId: json["product_id"],
|
|
2238
|
+
productName: json["product_name"],
|
|
2239
|
+
providerType: BillingProviderTypeFromJSON(json["provider_type"]),
|
|
2240
|
+
tiersMode: json["tiers_mode"] == null ? void 0 : BillingTiersModeFromJSON(json["tiers_mode"]),
|
|
2241
|
+
updatedAt: new Date(json["updated_at"]),
|
|
2242
|
+
usageType: BillingPriceUsageTypeFromJSON(json["usage_type"])
|
|
2243
|
+
};
|
|
2244
|
+
}
|
|
2245
|
+
|
|
2246
|
+
// src/api/checkoutexternal/models/CreditBundleCurrencyPrice.ts
|
|
2247
|
+
function CreditBundleCurrencyPriceFromJSON(json) {
|
|
2248
|
+
return CreditBundleCurrencyPriceFromJSONTyped(json, false);
|
|
2249
|
+
}
|
|
2250
|
+
function CreditBundleCurrencyPriceFromJSONTyped(json, ignoreDiscriminator) {
|
|
2251
|
+
if (json == null) {
|
|
2252
|
+
return json;
|
|
2253
|
+
}
|
|
2254
|
+
return {
|
|
2255
|
+
currency: json["currency"],
|
|
2256
|
+
price: json["price"] == null ? void 0 : BillingPriceViewFromJSON(json["price"])
|
|
2257
|
+
};
|
|
2258
|
+
}
|
|
2259
|
+
|
|
2194
2260
|
// src/api/checkoutexternal/models/BillingCreditExpiryUnit.ts
|
|
2195
2261
|
function BillingCreditExpiryUnitFromJSON(json) {
|
|
2196
2262
|
return BillingCreditExpiryUnitFromJSONTyped(json, false);
|
|
@@ -2214,6 +2280,9 @@ function BillingCreditBundleViewFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
2214
2280
|
creditIcon: json["credit_icon"] == null ? void 0 : json["credit_icon"],
|
|
2215
2281
|
creditId: json["credit_id"],
|
|
2216
2282
|
creditName: json["credit_name"],
|
|
2283
|
+
currencyPrices: json["currency_prices"] == null ? void 0 : json["currency_prices"].map(
|
|
2284
|
+
CreditBundleCurrencyPriceFromJSON
|
|
2285
|
+
),
|
|
2217
2286
|
expiryType: BillingCreditExpiryTypeFromJSON(json["expiry_type"]),
|
|
2218
2287
|
expiryUnit: BillingCreditExpiryUnitFromJSON(json["expiry_unit"]),
|
|
2219
2288
|
expiryUnitCount: json["expiry_unit_count"] == null ? void 0 : json["expiry_unit_count"],
|
|
@@ -2260,6 +2329,40 @@ function BillingCreditGrantZeroedOutReasonFromJSONTyped(json, ignoreDiscriminato
|
|
|
2260
2329
|
return json;
|
|
2261
2330
|
}
|
|
2262
2331
|
|
|
2332
|
+
// src/api/checkoutexternal/models/BillingPriceResponseData.ts
|
|
2333
|
+
function BillingPriceResponseDataFromJSON(json) {
|
|
2334
|
+
return BillingPriceResponseDataFromJSONTyped(json, false);
|
|
2335
|
+
}
|
|
2336
|
+
function BillingPriceResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
2337
|
+
if (json == null) {
|
|
2338
|
+
return json;
|
|
2339
|
+
}
|
|
2340
|
+
return {
|
|
2341
|
+
currency: json["currency"],
|
|
2342
|
+
externalPriceId: json["external_price_id"],
|
|
2343
|
+
id: json["id"],
|
|
2344
|
+
interval: BillingProductPriceIntervalFromJSON(json["interval"]),
|
|
2345
|
+
price: json["price"],
|
|
2346
|
+
priceDecimal: json["price_decimal"] == null ? void 0 : json["price_decimal"],
|
|
2347
|
+
providerType: BillingProviderTypeFromJSON(json["provider_type"]),
|
|
2348
|
+
scheme: BillingPriceSchemeFromJSON(json["scheme"])
|
|
2349
|
+
};
|
|
2350
|
+
}
|
|
2351
|
+
|
|
2352
|
+
// src/api/checkoutexternal/models/CreditCurrencyPriceResponseData.ts
|
|
2353
|
+
function CreditCurrencyPriceResponseDataFromJSON(json) {
|
|
2354
|
+
return CreditCurrencyPriceResponseDataFromJSONTyped(json, false);
|
|
2355
|
+
}
|
|
2356
|
+
function CreditCurrencyPriceResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
2357
|
+
if (json == null) {
|
|
2358
|
+
return json;
|
|
2359
|
+
}
|
|
2360
|
+
return {
|
|
2361
|
+
currency: json["currency"],
|
|
2362
|
+
price: json["price"] == null ? void 0 : BillingPriceResponseDataFromJSON(json["price"])
|
|
2363
|
+
};
|
|
2364
|
+
}
|
|
2365
|
+
|
|
2263
2366
|
// src/api/checkoutexternal/models/BillingProductResponseData.ts
|
|
2264
2367
|
function BillingProductResponseDataFromJSON(json) {
|
|
2265
2368
|
return BillingProductResponseDataFromJSONTyped(json, false);
|
|
@@ -2285,26 +2388,6 @@ function BillingProductResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
2285
2388
|
};
|
|
2286
2389
|
}
|
|
2287
2390
|
|
|
2288
|
-
// src/api/checkoutexternal/models/BillingPriceResponseData.ts
|
|
2289
|
-
function BillingPriceResponseDataFromJSON(json) {
|
|
2290
|
-
return BillingPriceResponseDataFromJSONTyped(json, false);
|
|
2291
|
-
}
|
|
2292
|
-
function BillingPriceResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
2293
|
-
if (json == null) {
|
|
2294
|
-
return json;
|
|
2295
|
-
}
|
|
2296
|
-
return {
|
|
2297
|
-
currency: json["currency"],
|
|
2298
|
-
externalPriceId: json["external_price_id"],
|
|
2299
|
-
id: json["id"],
|
|
2300
|
-
interval: BillingProductPriceIntervalFromJSON(json["interval"]),
|
|
2301
|
-
price: json["price"],
|
|
2302
|
-
priceDecimal: json["price_decimal"] == null ? void 0 : json["price_decimal"],
|
|
2303
|
-
providerType: BillingProviderTypeFromJSON(json["provider_type"]),
|
|
2304
|
-
scheme: BillingPriceSchemeFromJSON(json["scheme"])
|
|
2305
|
-
};
|
|
2306
|
-
}
|
|
2307
|
-
|
|
2308
2391
|
// src/api/checkoutexternal/models/BillingCreditRolloverPolicy.ts
|
|
2309
2392
|
function BillingCreditRolloverPolicyFromJSON(json) {
|
|
2310
2393
|
return BillingCreditRolloverPolicyFromJSONTyped(json, false);
|
|
@@ -2325,6 +2408,9 @@ function BillingCreditResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
2325
2408
|
burnStrategy: BillingCreditBurnStrategyFromJSON(json["burn_strategy"]),
|
|
2326
2409
|
costEditable: json["cost_editable"],
|
|
2327
2410
|
createdAt: new Date(json["created_at"]),
|
|
2411
|
+
currencyPrices: json["currency_prices"].map(
|
|
2412
|
+
CreditCurrencyPriceResponseDataFromJSON
|
|
2413
|
+
),
|
|
2328
2414
|
defaultExpiryUnit: BillingCreditExpiryUnitFromJSON(
|
|
2329
2415
|
json["default_expiry_unit"]
|
|
2330
2416
|
),
|
|
@@ -2344,58 +2430,6 @@ function BillingCreditResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
2344
2430
|
};
|
|
2345
2431
|
}
|
|
2346
2432
|
|
|
2347
|
-
// src/api/checkoutexternal/models/BillingProductPriceTierResponseData.ts
|
|
2348
|
-
function BillingProductPriceTierResponseDataFromJSON(json) {
|
|
2349
|
-
return BillingProductPriceTierResponseDataFromJSONTyped(json, false);
|
|
2350
|
-
}
|
|
2351
|
-
function BillingProductPriceTierResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
2352
|
-
if (json == null) {
|
|
2353
|
-
return json;
|
|
2354
|
-
}
|
|
2355
|
-
return {
|
|
2356
|
-
flatAmount: json["flat_amount"] == null ? void 0 : json["flat_amount"],
|
|
2357
|
-
perUnitPrice: json["per_unit_price"] == null ? void 0 : json["per_unit_price"],
|
|
2358
|
-
perUnitPriceDecimal: json["per_unit_price_decimal"] == null ? void 0 : json["per_unit_price_decimal"],
|
|
2359
|
-
upTo: json["up_to"] == null ? void 0 : json["up_to"]
|
|
2360
|
-
};
|
|
2361
|
-
}
|
|
2362
|
-
|
|
2363
|
-
// src/api/checkoutexternal/models/BillingPriceView.ts
|
|
2364
|
-
function BillingPriceViewFromJSON(json) {
|
|
2365
|
-
return BillingPriceViewFromJSONTyped(json, false);
|
|
2366
|
-
}
|
|
2367
|
-
function BillingPriceViewFromJSONTyped(json, ignoreDiscriminator) {
|
|
2368
|
-
if (json == null) {
|
|
2369
|
-
return json;
|
|
2370
|
-
}
|
|
2371
|
-
return {
|
|
2372
|
-
billingScheme: BillingPriceSchemeFromJSON(json["billing_scheme"]),
|
|
2373
|
-
createdAt: new Date(json["created_at"]),
|
|
2374
|
-
currency: json["currency"],
|
|
2375
|
-
id: json["id"],
|
|
2376
|
-
interval: BillingProductPriceIntervalFromJSON(json["interval"]),
|
|
2377
|
-
isActive: json["is_active"],
|
|
2378
|
-
meterEventName: json["meter_event_name"] == null ? void 0 : json["meter_event_name"],
|
|
2379
|
-
meterEventPayloadKey: json["meter_event_payload_key"] == null ? void 0 : json["meter_event_payload_key"],
|
|
2380
|
-
meterId: json["meter_id"] == null ? void 0 : json["meter_id"],
|
|
2381
|
-
packageSize: json["package_size"],
|
|
2382
|
-
price: json["price"],
|
|
2383
|
-
priceDecimal: json["price_decimal"] == null ? void 0 : json["price_decimal"],
|
|
2384
|
-
priceExternalId: json["price_external_id"],
|
|
2385
|
-
priceId: json["price_id"],
|
|
2386
|
-
priceTier: json["price_tier"].map(
|
|
2387
|
-
BillingProductPriceTierResponseDataFromJSON
|
|
2388
|
-
),
|
|
2389
|
-
productExternalId: json["product_external_id"],
|
|
2390
|
-
productId: json["product_id"],
|
|
2391
|
-
productName: json["product_name"],
|
|
2392
|
-
providerType: BillingProviderTypeFromJSON(json["provider_type"]),
|
|
2393
|
-
tiersMode: json["tiers_mode"] == null ? void 0 : BillingTiersModeFromJSON(json["tiers_mode"]),
|
|
2394
|
-
updatedAt: new Date(json["updated_at"]),
|
|
2395
|
-
usageType: BillingPriceUsageTypeFromJSON(json["usage_type"])
|
|
2396
|
-
};
|
|
2397
|
-
}
|
|
2398
|
-
|
|
2399
2433
|
// src/api/checkoutexternal/models/BillingCreditView.ts
|
|
2400
2434
|
function BillingCreditViewFromJSON(json) {
|
|
2401
2435
|
return BillingCreditViewFromJSONTyped(json, false);
|
|
@@ -3609,6 +3643,21 @@ function PlanControlledByTypeFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
3609
3643
|
return json;
|
|
3610
3644
|
}
|
|
3611
3645
|
|
|
3646
|
+
// src/api/checkoutexternal/models/EntitlementCurrencyPricesResponseData.ts
|
|
3647
|
+
function EntitlementCurrencyPricesResponseDataFromJSON(json) {
|
|
3648
|
+
return EntitlementCurrencyPricesResponseDataFromJSONTyped(json, false);
|
|
3649
|
+
}
|
|
3650
|
+
function EntitlementCurrencyPricesResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
3651
|
+
if (json == null) {
|
|
3652
|
+
return json;
|
|
3653
|
+
}
|
|
3654
|
+
return {
|
|
3655
|
+
currency: json["currency"],
|
|
3656
|
+
monthlyPrice: json["monthly_price"] == null ? void 0 : BillingPriceViewFromJSON(json["monthly_price"]),
|
|
3657
|
+
yearlyPrice: json["yearly_price"] == null ? void 0 : BillingPriceViewFromJSON(json["yearly_price"])
|
|
3658
|
+
};
|
|
3659
|
+
}
|
|
3660
|
+
|
|
3612
3661
|
// src/api/checkoutexternal/models/EntitlementPriceBehavior.ts
|
|
3613
3662
|
var EntitlementPriceBehavior = {
|
|
3614
3663
|
CreditBurndown: "credit_burndown",
|
|
@@ -3664,6 +3713,9 @@ function PlanEntitlementResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
3664
3713
|
billingThreshold: json["billing_threshold"] == null ? void 0 : json["billing_threshold"],
|
|
3665
3714
|
consumptionRate: json["consumption_rate"] == null ? void 0 : json["consumption_rate"],
|
|
3666
3715
|
createdAt: new Date(json["created_at"]),
|
|
3716
|
+
currencyPrices: json["currency_prices"].map(
|
|
3717
|
+
EntitlementCurrencyPricesResponseDataFromJSON
|
|
3718
|
+
),
|
|
3667
3719
|
environmentId: json["environment_id"],
|
|
3668
3720
|
feature: json["feature"] == null ? void 0 : FeatureResponseDataFromJSON(json["feature"]),
|
|
3669
3721
|
featureId: json["feature_id"],
|
|
@@ -3689,6 +3741,37 @@ function PlanEntitlementResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
3689
3741
|
};
|
|
3690
3742
|
}
|
|
3691
3743
|
|
|
3744
|
+
// src/api/checkoutexternal/models/CustomPlanConfig.ts
|
|
3745
|
+
function CustomPlanConfigFromJSON(json) {
|
|
3746
|
+
return CustomPlanConfigFromJSONTyped(json, false);
|
|
3747
|
+
}
|
|
3748
|
+
function CustomPlanConfigFromJSONTyped(json, ignoreDiscriminator) {
|
|
3749
|
+
if (json == null) {
|
|
3750
|
+
return json;
|
|
3751
|
+
}
|
|
3752
|
+
return {
|
|
3753
|
+
ctaText: json["cta_text"],
|
|
3754
|
+
ctaWebSite: json["cta_web_site"],
|
|
3755
|
+
priceText: json["price_text"]
|
|
3756
|
+
};
|
|
3757
|
+
}
|
|
3758
|
+
|
|
3759
|
+
// src/api/checkoutexternal/models/PlanCurrencyPricesResponseData.ts
|
|
3760
|
+
function PlanCurrencyPricesResponseDataFromJSON(json) {
|
|
3761
|
+
return PlanCurrencyPricesResponseDataFromJSONTyped(json, false);
|
|
3762
|
+
}
|
|
3763
|
+
function PlanCurrencyPricesResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
3764
|
+
if (json == null) {
|
|
3765
|
+
return json;
|
|
3766
|
+
}
|
|
3767
|
+
return {
|
|
3768
|
+
currency: json["currency"],
|
|
3769
|
+
monthlyPrice: json["monthly_price"] == null ? void 0 : BillingPriceResponseDataFromJSON(json["monthly_price"]),
|
|
3770
|
+
oneTimePrice: json["one_time_price"] == null ? void 0 : BillingPriceResponseDataFromJSON(json["one_time_price"]),
|
|
3771
|
+
yearlyPrice: json["yearly_price"] == null ? void 0 : BillingPriceResponseDataFromJSON(json["yearly_price"])
|
|
3772
|
+
};
|
|
3773
|
+
}
|
|
3774
|
+
|
|
3692
3775
|
// src/api/checkoutexternal/models/PlanVersionStatus.ts
|
|
3693
3776
|
function PlanVersionStatusFromJSON(json) {
|
|
3694
3777
|
return PlanVersionStatusFromJSONTyped(json, false);
|
|
@@ -3720,21 +3803,6 @@ function PlanVersionResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
3720
3803
|
};
|
|
3721
3804
|
}
|
|
3722
3805
|
|
|
3723
|
-
// src/api/checkoutexternal/models/CustomPlanConfig.ts
|
|
3724
|
-
function CustomPlanConfigFromJSON(json) {
|
|
3725
|
-
return CustomPlanConfigFromJSONTyped(json, false);
|
|
3726
|
-
}
|
|
3727
|
-
function CustomPlanConfigFromJSONTyped(json, ignoreDiscriminator) {
|
|
3728
|
-
if (json == null) {
|
|
3729
|
-
return json;
|
|
3730
|
-
}
|
|
3731
|
-
return {
|
|
3732
|
-
ctaText: json["cta_text"],
|
|
3733
|
-
ctaWebSite: json["cta_web_site"],
|
|
3734
|
-
priceText: json["price_text"]
|
|
3735
|
-
};
|
|
3736
|
-
}
|
|
3737
|
-
|
|
3738
3806
|
// src/api/checkoutexternal/models/CreditUsageAggregation.ts
|
|
3739
3807
|
function CreditUsageAggregationFromJSON(json) {
|
|
3740
3808
|
return CreditUsageAggregationFromJSONTyped(json, false);
|
|
@@ -3841,6 +3909,9 @@ function CompanyPlanDetailResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
3841
3909
|
compatiblePlanIds: json["compatible_plan_ids"],
|
|
3842
3910
|
controlledBy: PlanControlledByTypeFromJSON(json["controlled_by"]),
|
|
3843
3911
|
createdAt: new Date(json["created_at"]),
|
|
3912
|
+
currencyPrices: json["currency_prices"].map(
|
|
3913
|
+
PlanCurrencyPricesResponseDataFromJSON
|
|
3914
|
+
),
|
|
3844
3915
|
current: json["current"],
|
|
3845
3916
|
custom: json["custom"],
|
|
3846
3917
|
customPlanConfig: json["custom_plan_config"] == null ? void 0 : CustomPlanConfigFromJSON(json["custom_plan_config"]),
|
|
@@ -3995,6 +4066,9 @@ function PlanDetailResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
3995
4066
|
companyCount: json["company_count"],
|
|
3996
4067
|
controlledBy: PlanControlledByTypeFromJSON(json["controlled_by"]),
|
|
3997
4068
|
createdAt: new Date(json["created_at"]),
|
|
4069
|
+
currencyPrices: json["currency_prices"].map(
|
|
4070
|
+
PlanCurrencyPricesResponseDataFromJSON
|
|
4071
|
+
),
|
|
3998
4072
|
description: json["description"],
|
|
3999
4073
|
draftVersion: json["draft_version"] == null ? void 0 : PlanVersionResponseDataFromJSON(json["draft_version"]),
|
|
4000
4074
|
features: json["features"].map(
|
|
@@ -4072,6 +4146,7 @@ function CreditCompanyGrantViewFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
4072
4146
|
creditDescription: json["credit_description"],
|
|
4073
4147
|
creditIcon: json["credit_icon"] == null ? void 0 : json["credit_icon"],
|
|
4074
4148
|
creditName: json["credit_name"],
|
|
4149
|
+
currency: json["currency"] == null ? void 0 : json["currency"],
|
|
4075
4150
|
exhaustedAt: json["exhausted_at"] == null ? void 0 : new Date(json["exhausted_at"]),
|
|
4076
4151
|
expiresAt: json["expires_at"] == null ? void 0 : new Date(json["expires_at"]),
|
|
4077
4152
|
expiryType: json["expiry_type"] == null ? void 0 : BillingCreditExpiryTypeFromJSON(json["expiry_type"]),
|
|
@@ -9249,6 +9324,7 @@ var SUPPORT_NOTICE_KEY = "__i18next_supportNoticeShown";
|
|
|
9249
9324
|
var getSupportNoticeShown = () => {
|
|
9250
9325
|
if (typeof globalThis !== "undefined" && !!globalThis[SUPPORT_NOTICE_KEY]) return true;
|
|
9251
9326
|
if (typeof process !== "undefined" && process.env && process.env.I18NEXT_NO_SUPPORT_NOTICE) return true;
|
|
9327
|
+
if (typeof process !== "undefined" && process.env && false) return true;
|
|
9252
9328
|
return false;
|
|
9253
9329
|
};
|
|
9254
9330
|
var setSupportNoticeShown = () => {
|
|
@@ -11223,39 +11299,6 @@ function BillingCreditExpiryUnitFromJSONTyped8(json, ignoreDiscriminator) {
|
|
|
11223
11299
|
return json;
|
|
11224
11300
|
}
|
|
11225
11301
|
|
|
11226
|
-
// src/api/componentspublic/models/BillingProviderType.ts
|
|
11227
|
-
function BillingProviderTypeFromJSON2(json) {
|
|
11228
|
-
return BillingProviderTypeFromJSONTyped13(json, false);
|
|
11229
|
-
}
|
|
11230
|
-
function BillingProviderTypeFromJSONTyped13(json, ignoreDiscriminator) {
|
|
11231
|
-
return json;
|
|
11232
|
-
}
|
|
11233
|
-
|
|
11234
|
-
// src/api/componentspublic/models/BillingProductResponseData.ts
|
|
11235
|
-
function BillingProductResponseDataFromJSON2(json) {
|
|
11236
|
-
return BillingProductResponseDataFromJSONTyped5(json, false);
|
|
11237
|
-
}
|
|
11238
|
-
function BillingProductResponseDataFromJSONTyped5(json, ignoreDiscriminator) {
|
|
11239
|
-
if (json == null) {
|
|
11240
|
-
return json;
|
|
11241
|
-
}
|
|
11242
|
-
return {
|
|
11243
|
-
accountId: json["account_id"],
|
|
11244
|
-
createdAt: new Date(json["created_at"]),
|
|
11245
|
-
currency: json["currency"] == null ? void 0 : json["currency"],
|
|
11246
|
-
environmentId: json["environment_id"],
|
|
11247
|
-
externalId: json["external_id"],
|
|
11248
|
-
isActive: json["is_active"],
|
|
11249
|
-
name: json["name"],
|
|
11250
|
-
price: json["price"],
|
|
11251
|
-
priceDecimal: json["price_decimal"] == null ? void 0 : json["price_decimal"],
|
|
11252
|
-
productId: json["product_id"],
|
|
11253
|
-
providerType: BillingProviderTypeFromJSON2(json["provider_type"]),
|
|
11254
|
-
quantity: json["quantity"],
|
|
11255
|
-
updatedAt: new Date(json["updated_at"])
|
|
11256
|
-
};
|
|
11257
|
-
}
|
|
11258
|
-
|
|
11259
11302
|
// src/api/componentspublic/models/BillingProductPriceInterval.ts
|
|
11260
11303
|
function BillingProductPriceIntervalFromJSON2(json) {
|
|
11261
11304
|
return BillingProductPriceIntervalFromJSONTyped5(json, false);
|
|
@@ -11264,6 +11307,14 @@ function BillingProductPriceIntervalFromJSONTyped5(json, ignoreDiscriminator) {
|
|
|
11264
11307
|
return json;
|
|
11265
11308
|
}
|
|
11266
11309
|
|
|
11310
|
+
// src/api/componentspublic/models/BillingProviderType.ts
|
|
11311
|
+
function BillingProviderTypeFromJSON2(json) {
|
|
11312
|
+
return BillingProviderTypeFromJSONTyped13(json, false);
|
|
11313
|
+
}
|
|
11314
|
+
function BillingProviderTypeFromJSONTyped13(json, ignoreDiscriminator) {
|
|
11315
|
+
return json;
|
|
11316
|
+
}
|
|
11317
|
+
|
|
11267
11318
|
// src/api/componentspublic/models/BillingPriceScheme.ts
|
|
11268
11319
|
function BillingPriceSchemeFromJSON2(json) {
|
|
11269
11320
|
return BillingPriceSchemeFromJSONTyped6(json, false);
|
|
@@ -11274,9 +11325,9 @@ function BillingPriceSchemeFromJSONTyped6(json, ignoreDiscriminator) {
|
|
|
11274
11325
|
|
|
11275
11326
|
// src/api/componentspublic/models/BillingPriceResponseData.ts
|
|
11276
11327
|
function BillingPriceResponseDataFromJSON2(json) {
|
|
11277
|
-
return
|
|
11328
|
+
return BillingPriceResponseDataFromJSONTyped9(json, false);
|
|
11278
11329
|
}
|
|
11279
|
-
function
|
|
11330
|
+
function BillingPriceResponseDataFromJSONTyped9(json, ignoreDiscriminator) {
|
|
11280
11331
|
if (json == null) {
|
|
11281
11332
|
return json;
|
|
11282
11333
|
}
|
|
@@ -11292,6 +11343,45 @@ function BillingPriceResponseDataFromJSONTyped7(json, ignoreDiscriminator) {
|
|
|
11292
11343
|
};
|
|
11293
11344
|
}
|
|
11294
11345
|
|
|
11346
|
+
// src/api/componentspublic/models/CreditCurrencyPriceResponseData.ts
|
|
11347
|
+
function CreditCurrencyPriceResponseDataFromJSON2(json) {
|
|
11348
|
+
return CreditCurrencyPriceResponseDataFromJSONTyped3(json, false);
|
|
11349
|
+
}
|
|
11350
|
+
function CreditCurrencyPriceResponseDataFromJSONTyped3(json, ignoreDiscriminator) {
|
|
11351
|
+
if (json == null) {
|
|
11352
|
+
return json;
|
|
11353
|
+
}
|
|
11354
|
+
return {
|
|
11355
|
+
currency: json["currency"],
|
|
11356
|
+
price: json["price"] == null ? void 0 : BillingPriceResponseDataFromJSON2(json["price"])
|
|
11357
|
+
};
|
|
11358
|
+
}
|
|
11359
|
+
|
|
11360
|
+
// src/api/componentspublic/models/BillingProductResponseData.ts
|
|
11361
|
+
function BillingProductResponseDataFromJSON2(json) {
|
|
11362
|
+
return BillingProductResponseDataFromJSONTyped5(json, false);
|
|
11363
|
+
}
|
|
11364
|
+
function BillingProductResponseDataFromJSONTyped5(json, ignoreDiscriminator) {
|
|
11365
|
+
if (json == null) {
|
|
11366
|
+
return json;
|
|
11367
|
+
}
|
|
11368
|
+
return {
|
|
11369
|
+
accountId: json["account_id"],
|
|
11370
|
+
createdAt: new Date(json["created_at"]),
|
|
11371
|
+
currency: json["currency"] == null ? void 0 : json["currency"],
|
|
11372
|
+
environmentId: json["environment_id"],
|
|
11373
|
+
externalId: json["external_id"],
|
|
11374
|
+
isActive: json["is_active"],
|
|
11375
|
+
name: json["name"],
|
|
11376
|
+
price: json["price"],
|
|
11377
|
+
priceDecimal: json["price_decimal"] == null ? void 0 : json["price_decimal"],
|
|
11378
|
+
productId: json["product_id"],
|
|
11379
|
+
providerType: BillingProviderTypeFromJSON2(json["provider_type"]),
|
|
11380
|
+
quantity: json["quantity"],
|
|
11381
|
+
updatedAt: new Date(json["updated_at"])
|
|
11382
|
+
};
|
|
11383
|
+
}
|
|
11384
|
+
|
|
11295
11385
|
// src/api/componentspublic/models/BillingCreditRolloverPolicy.ts
|
|
11296
11386
|
function BillingCreditRolloverPolicyFromJSON2(json) {
|
|
11297
11387
|
return BillingCreditRolloverPolicyFromJSONTyped4(json, false);
|
|
@@ -11312,6 +11402,9 @@ function BillingCreditResponseDataFromJSONTyped4(json, ignoreDiscriminator) {
|
|
|
11312
11402
|
burnStrategy: BillingCreditBurnStrategyFromJSON2(json["burn_strategy"]),
|
|
11313
11403
|
costEditable: json["cost_editable"],
|
|
11314
11404
|
createdAt: new Date(json["created_at"]),
|
|
11405
|
+
currencyPrices: json["currency_prices"].map(
|
|
11406
|
+
CreditCurrencyPriceResponseDataFromJSON2
|
|
11407
|
+
),
|
|
11315
11408
|
defaultExpiryUnit: BillingCreditExpiryUnitFromJSON2(
|
|
11316
11409
|
json["default_expiry_unit"]
|
|
11317
11410
|
),
|
|
@@ -11365,9 +11458,9 @@ function BillingTiersModeFromJSONTyped4(json, ignoreDiscriminator) {
|
|
|
11365
11458
|
|
|
11366
11459
|
// src/api/componentspublic/models/BillingPriceView.ts
|
|
11367
11460
|
function BillingPriceViewFromJSON2(json) {
|
|
11368
|
-
return
|
|
11461
|
+
return BillingPriceViewFromJSONTyped8(json, false);
|
|
11369
11462
|
}
|
|
11370
|
-
function
|
|
11463
|
+
function BillingPriceViewFromJSONTyped8(json, ignoreDiscriminator) {
|
|
11371
11464
|
if (json == null) {
|
|
11372
11465
|
return json;
|
|
11373
11466
|
}
|
|
@@ -11580,6 +11673,21 @@ function CustomPlanConfigFromJSONTyped3(json, ignoreDiscriminator) {
|
|
|
11580
11673
|
};
|
|
11581
11674
|
}
|
|
11582
11675
|
|
|
11676
|
+
// src/api/componentspublic/models/EntitlementCurrencyPricesResponseData.ts
|
|
11677
|
+
function EntitlementCurrencyPricesResponseDataFromJSON2(json) {
|
|
11678
|
+
return EntitlementCurrencyPricesResponseDataFromJSONTyped3(json, false);
|
|
11679
|
+
}
|
|
11680
|
+
function EntitlementCurrencyPricesResponseDataFromJSONTyped3(json, ignoreDiscriminator) {
|
|
11681
|
+
if (json == null) {
|
|
11682
|
+
return json;
|
|
11683
|
+
}
|
|
11684
|
+
return {
|
|
11685
|
+
currency: json["currency"],
|
|
11686
|
+
monthlyPrice: json["monthly_price"] == null ? void 0 : BillingPriceViewFromJSON2(json["monthly_price"]),
|
|
11687
|
+
yearlyPrice: json["yearly_price"] == null ? void 0 : BillingPriceViewFromJSON2(json["yearly_price"])
|
|
11688
|
+
};
|
|
11689
|
+
}
|
|
11690
|
+
|
|
11583
11691
|
// src/api/componentspublic/models/EntitlementPriceBehavior.ts
|
|
11584
11692
|
function EntitlementPriceBehaviorFromJSON2(json) {
|
|
11585
11693
|
return EntitlementPriceBehaviorFromJSONTyped5(json, false);
|
|
@@ -11910,6 +12018,22 @@ function PlanCreditGrantViewFromJSONTyped4(json, ignoreDiscriminator) {
|
|
|
11910
12018
|
};
|
|
11911
12019
|
}
|
|
11912
12020
|
|
|
12021
|
+
// src/api/componentspublic/models/PlanCurrencyPricesResponseData.ts
|
|
12022
|
+
function PlanCurrencyPricesResponseDataFromJSON2(json) {
|
|
12023
|
+
return PlanCurrencyPricesResponseDataFromJSONTyped5(json, false);
|
|
12024
|
+
}
|
|
12025
|
+
function PlanCurrencyPricesResponseDataFromJSONTyped5(json, ignoreDiscriminator) {
|
|
12026
|
+
if (json == null) {
|
|
12027
|
+
return json;
|
|
12028
|
+
}
|
|
12029
|
+
return {
|
|
12030
|
+
currency: json["currency"],
|
|
12031
|
+
monthlyPrice: json["monthly_price"] == null ? void 0 : BillingPriceResponseDataFromJSON2(json["monthly_price"]),
|
|
12032
|
+
oneTimePrice: json["one_time_price"] == null ? void 0 : BillingPriceResponseDataFromJSON2(json["one_time_price"]),
|
|
12033
|
+
yearlyPrice: json["yearly_price"] == null ? void 0 : BillingPriceResponseDataFromJSON2(json["yearly_price"])
|
|
12034
|
+
};
|
|
12035
|
+
}
|
|
12036
|
+
|
|
11913
12037
|
// src/api/componentspublic/models/PlanType.ts
|
|
11914
12038
|
function PlanTypeFromJSON2(json) {
|
|
11915
12039
|
return PlanTypeFromJSONTyped7(json, false);
|
|
@@ -11950,6 +12074,9 @@ function PlanEntitlementResponseDataFromJSONTyped5(json, ignoreDiscriminator) {
|
|
|
11950
12074
|
billingThreshold: json["billing_threshold"] == null ? void 0 : json["billing_threshold"],
|
|
11951
12075
|
consumptionRate: json["consumption_rate"] == null ? void 0 : json["consumption_rate"],
|
|
11952
12076
|
createdAt: new Date(json["created_at"]),
|
|
12077
|
+
currencyPrices: json["currency_prices"].map(
|
|
12078
|
+
EntitlementCurrencyPricesResponseDataFromJSON2
|
|
12079
|
+
),
|
|
11953
12080
|
environmentId: json["environment_id"],
|
|
11954
12081
|
feature: json["feature"] == null ? void 0 : FeatureResponseDataFromJSON2(json["feature"]),
|
|
11955
12082
|
featureId: json["feature_id"],
|
|
@@ -12023,6 +12150,9 @@ function PlanViewPublicResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
12023
12150
|
compatiblePlanIds: json["compatible_plan_ids"],
|
|
12024
12151
|
controlledBy: PlanControlledByTypeFromJSON2(json["controlled_by"]),
|
|
12025
12152
|
createdAt: new Date(json["created_at"]),
|
|
12153
|
+
currencyPrices: json["currency_prices"].map(
|
|
12154
|
+
PlanCurrencyPricesResponseDataFromJSON2
|
|
12155
|
+
),
|
|
12026
12156
|
custom: json["custom"],
|
|
12027
12157
|
customPlanConfig: json["custom_plan_config"] == null ? void 0 : CustomPlanConfigFromJSON2(json["custom_plan_config"]),
|
|
12028
12158
|
description: json["description"],
|
|
@@ -12334,7 +12464,7 @@ var reducer = (state, action) => {
|
|
|
12334
12464
|
// src/context/EmbedProvider.tsx
|
|
12335
12465
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
12336
12466
|
var getCustomHeaders = (sessionId) => ({
|
|
12337
|
-
"X-Schematic-Components-Version": "2.8.
|
|
12467
|
+
"X-Schematic-Components-Version": "2.8.3",
|
|
12338
12468
|
"X-Schematic-Session-ID": sessionId
|
|
12339
12469
|
});
|
|
12340
12470
|
var EmbedProvider = ({
|
|
@@ -12722,6 +12852,7 @@ var EmbedProvider = ({
|
|
|
12722
12852
|
value: {
|
|
12723
12853
|
isPending: state.isPending,
|
|
12724
12854
|
stale: state.stale,
|
|
12855
|
+
accessToken: state.accessToken,
|
|
12725
12856
|
data: state.data,
|
|
12726
12857
|
error: state.error,
|
|
12727
12858
|
settings: state.settings,
|
|
@@ -15677,9 +15808,7 @@ var CheckoutDialog = ({ top }) => {
|
|
|
15677
15808
|
(available) => available.id === addOnId
|
|
15678
15809
|
);
|
|
15679
15810
|
if (!availableAddOn) return [];
|
|
15680
|
-
return availableAddOn.entitlements.filter(
|
|
15681
|
-
(entitlement) => entitlement.priceBehavior === EntitlementPriceBehavior.PayInAdvance
|
|
15682
|
-
).map((entitlement) => ({
|
|
15811
|
+
return availableAddOn.entitlements.filter((entitlement) => !!entitlement.priceBehavior).map((entitlement) => ({
|
|
15683
15812
|
...entitlement,
|
|
15684
15813
|
allocation: entitlement.valueNumeric || 0,
|
|
15685
15814
|
usage: 0,
|
|
@@ -17648,18 +17777,18 @@ var SubscriptionSidebar = forwardRef7(
|
|
|
17648
17777
|
usageBasedEntitlements,
|
|
17649
17778
|
addOnUsageBasedEntitlements
|
|
17650
17779
|
]);
|
|
17651
|
-
const
|
|
17780
|
+
const selectedAddOnsWithPrice = useMemo13(
|
|
17652
17781
|
() => addOns.filter(
|
|
17653
|
-
(addOn) => addOn.isSelected && getPlanPrice(addOn)?.price
|
|
17782
|
+
(addOn) => addOn.isSelected && typeof getPlanPrice(addOn)?.price === "number"
|
|
17654
17783
|
),
|
|
17655
17784
|
[addOns]
|
|
17656
17785
|
);
|
|
17657
17786
|
const { removedAddOns, willAddOnsChange } = useMemo13(() => {
|
|
17658
|
-
const addedAddOns =
|
|
17659
|
-
(selected) =>
|
|
17787
|
+
const addedAddOns = selectedAddOnsWithPrice.filter(
|
|
17788
|
+
(selected) => !currentAddOns.some((current) => selected.id === current.id)
|
|
17660
17789
|
);
|
|
17661
17790
|
const removedAddOns2 = currentAddOns.filter(
|
|
17662
|
-
(current) => current.planPrice && current.planPeriod !== "one-time" && !
|
|
17791
|
+
(current) => current.planPrice && current.planPeriod !== "one-time" && !selectedAddOnsWithPrice.some(
|
|
17663
17792
|
(selected) => current.id === selected.id
|
|
17664
17793
|
)
|
|
17665
17794
|
);
|
|
@@ -17669,7 +17798,7 @@ var SubscriptionSidebar = forwardRef7(
|
|
|
17669
17798
|
removedAddOns: removedAddOns2,
|
|
17670
17799
|
willAddOnsChange: willAddOnsChange2
|
|
17671
17800
|
};
|
|
17672
|
-
}, [currentAddOns,
|
|
17801
|
+
}, [currentAddOns, selectedAddOnsWithPrice]);
|
|
17673
17802
|
const addedCreditBundles = useMemo13(
|
|
17674
17803
|
() => creditBundles.filter((bundle) => bundle.count > 0),
|
|
17675
17804
|
[creditBundles]
|
|
@@ -18113,7 +18242,7 @@ var SubscriptionSidebar = forwardRef7(
|
|
|
18113
18242
|
}
|
|
18114
18243
|
)
|
|
18115
18244
|
] }),
|
|
18116
|
-
(willAddOnsChange ||
|
|
18245
|
+
(willAddOnsChange || selectedAddOnsWithPrice.length > 0) && /* @__PURE__ */ jsxs23(Flex, { $flexDirection: "column", $gap: "0.5rem", $marginBottom: "1.5rem", children: [
|
|
18117
18246
|
/* @__PURE__ */ jsx32(Box, { $opacity: "0.625", children: /* @__PURE__ */ jsx32(Text, { $size: 14, children: t2("Add-ons") }) }),
|
|
18118
18247
|
removedAddOns.map((addOn, index) => {
|
|
18119
18248
|
return /* @__PURE__ */ jsxs23(
|
|
@@ -18142,7 +18271,7 @@ var SubscriptionSidebar = forwardRef7(
|
|
|
18142
18271
|
index
|
|
18143
18272
|
);
|
|
18144
18273
|
}),
|
|
18145
|
-
|
|
18274
|
+
selectedAddOnsWithPrice.map((addOn, index) => {
|
|
18146
18275
|
const { price: addOnPrice, currency: addOnCurrency } = getAddOnPrice(addOn, planPeriod) || {};
|
|
18147
18276
|
return /* @__PURE__ */ jsxs23(
|
|
18148
18277
|
Flex,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@schematichq/schematic-components",
|
|
3
|
-
"version": "2.8.
|
|
3
|
+
"version": "2.8.3",
|
|
4
4
|
"main": "dist/schematic-components.cjs.js",
|
|
5
5
|
"module": "dist/schematic-components.esm.js",
|
|
6
6
|
"types": "dist/schematic-components.d.ts",
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@schematichq/schematic-icons": "^0.5.2",
|
|
37
37
|
"@stripe/stripe-js": "^8.11.0",
|
|
38
|
-
"i18next": "^25.10.
|
|
38
|
+
"i18next": "^25.10.10",
|
|
39
39
|
"lodash": "^4.17.23",
|
|
40
40
|
"pako": "^2.1.0",
|
|
41
41
|
"react-i18next": "16.1.6",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"devDependencies": {
|
|
46
46
|
"@eslint/js": "^9.39.3",
|
|
47
47
|
"@eslint/json": "^1.2.0",
|
|
48
|
-
"@eslint/markdown": "^
|
|
48
|
+
"@eslint/markdown": "^8.0.0",
|
|
49
49
|
"@microsoft/api-extractor": "^7.57.7",
|
|
50
50
|
"@openapitools/openapi-generator-cli": "^2.31.0",
|
|
51
51
|
"@stripe/react-stripe-js": "^5.6.1",
|
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
"eslint-plugin-react": "^7.37.5",
|
|
66
66
|
"eslint-plugin-react-hooks": "^7.0.1",
|
|
67
67
|
"globals": "^17.4.0",
|
|
68
|
-
"happy-dom": "^20.8.
|
|
68
|
+
"happy-dom": "^20.8.9",
|
|
69
69
|
"jsdom": "^29.0.1",
|
|
70
70
|
"msw": "^2.12.14",
|
|
71
71
|
"prettier": "^3.8.1",
|