@schematichq/schematic-react 0.2.0-rc.1 → 0.2.0-rc.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-react.cjs.js +2380 -492
- package/dist/schematic-react.d.ts +758 -5
- package/dist/schematic-react.esm.js +2418 -528
- package/package.json +9 -3
@@ -1,6 +1,7 @@
|
|
1
1
|
import { Context } from 'react';
|
2
2
|
import * as Craft from '@craftjs/core';
|
3
3
|
import { DetailedHTMLProps } from 'react';
|
4
|
+
import { Dispatch } from 'react';
|
4
5
|
import { DO_NOT_USE_OR_YOU_WILL_BE_FIRED_CALLBACK_REF_RETURN_VALUES } from 'react';
|
5
6
|
import { Event as Event_2 } from '@schematichq/schematic-js';
|
6
7
|
import { EventBody } from '@schematichq/schematic-js';
|
@@ -15,7 +16,6 @@ import { HTMLAttributes } from 'react';
|
|
15
16
|
import { IStyledComponentBase } from 'styled-components/dist/types';
|
16
17
|
import { JSX as JSX_2 } from 'react/jsx-runtime';
|
17
18
|
import { Keys } from '@schematichq/schematic-js';
|
18
|
-
import { default as React_2 } from 'react';
|
19
19
|
import { ReactNode } from 'react';
|
20
20
|
import { RefAttributes } from 'react';
|
21
21
|
import { RefObject } from 'react';
|
@@ -23,11 +23,63 @@ import { Schematic } from '@schematichq/schematic-js';
|
|
23
23
|
import { SchematicContext } from '@schematichq/schematic-js';
|
24
24
|
import * as SchematicJS from '@schematichq/schematic-js';
|
25
25
|
import { SchematicOptions } from '@schematichq/schematic-js';
|
26
|
+
import { SetStateAction } from 'react';
|
27
|
+
import { Stripe } from '@stripe/stripe-js';
|
26
28
|
import { Substitute } from 'styled-components/dist/types';
|
27
29
|
import { Traits } from '@schematichq/schematic-js';
|
28
30
|
|
31
|
+
declare interface ApiResponse<T> {
|
32
|
+
raw: Response;
|
33
|
+
value(): Promise<T>;
|
34
|
+
}
|
35
|
+
|
36
|
+
/**
|
37
|
+
* Schematic API
|
38
|
+
* Schematic API
|
39
|
+
*
|
40
|
+
* The version of the OpenAPI document: 0.1
|
41
|
+
*
|
42
|
+
*
|
43
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
44
|
+
* https://openapi-generator.tech
|
45
|
+
* Do not edit the class manually.
|
46
|
+
*/
|
47
|
+
declare const BASE_PATH: string;
|
48
|
+
|
49
|
+
/**
|
50
|
+
* This is the base class for all generated API classes.
|
51
|
+
*/
|
52
|
+
declare class BaseAPI {
|
53
|
+
protected configuration: Configuration;
|
54
|
+
private static readonly jsonRegex;
|
55
|
+
private middleware;
|
56
|
+
constructor(configuration?: Configuration);
|
57
|
+
withMiddleware<T extends BaseAPI>(this: T, ...middlewares: Middleware[]): T;
|
58
|
+
withPreMiddleware<T extends BaseAPI>(this: T, ...preMiddlewares: Array<Middleware["pre"]>): T;
|
59
|
+
withPostMiddleware<T extends BaseAPI>(this: T, ...postMiddlewares: Array<Middleware["post"]>): T;
|
60
|
+
/**
|
61
|
+
* Check if the given MIME is a JSON MIME.
|
62
|
+
* JSON MIME examples:
|
63
|
+
* application/json
|
64
|
+
* application/json; charset=UTF8
|
65
|
+
* APPLICATION/JSON
|
66
|
+
* application/vnd.company+json
|
67
|
+
* @param mime - MIME (Multipurpose Internet Mail Extensions)
|
68
|
+
* @return True if the given MIME is JSON, false otherwise.
|
69
|
+
*/
|
70
|
+
protected isJsonMime(mime: string | null | undefined): boolean;
|
71
|
+
protected request(context: RequestOpts, initOverrides?: RequestInit | InitOverrideFunction): Promise<Response>;
|
72
|
+
private createFetchParams;
|
73
|
+
private fetchApi;
|
74
|
+
/**
|
75
|
+
* Create a shallow clone of `this` by constructing a new instance
|
76
|
+
* and then shallow cloning data members.
|
77
|
+
*/
|
78
|
+
private clone;
|
79
|
+
}
|
80
|
+
|
29
81
|
declare type BaseSchematicProviderProps = Omit<SchematicJS.SchematicOptions, "client" | "publishableKey"> & {
|
30
|
-
children: ReactNode;
|
82
|
+
children: React.ReactNode;
|
31
83
|
};
|
32
84
|
|
33
85
|
/**
|
@@ -202,6 +254,146 @@ declare interface BillingProductDetailResponseData {
|
|
202
254
|
updatedAt: Date;
|
203
255
|
}
|
204
256
|
|
257
|
+
/**
|
258
|
+
* Schematic API
|
259
|
+
* Schematic API
|
260
|
+
*
|
261
|
+
* The version of the OpenAPI document: 0.1
|
262
|
+
*
|
263
|
+
*
|
264
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
265
|
+
* https://openapi-generator.tech
|
266
|
+
* Do not edit the class manually.
|
267
|
+
*/
|
268
|
+
/**
|
269
|
+
*
|
270
|
+
* @export
|
271
|
+
* @interface BillingProductForSubscriptionResponseData
|
272
|
+
*/
|
273
|
+
declare interface BillingProductForSubscriptionResponseData {
|
274
|
+
/**
|
275
|
+
*
|
276
|
+
* @type {string}
|
277
|
+
* @memberof BillingProductForSubscriptionResponseData
|
278
|
+
*/
|
279
|
+
accountId: string;
|
280
|
+
/**
|
281
|
+
*
|
282
|
+
* @type {Date}
|
283
|
+
* @memberof BillingProductForSubscriptionResponseData
|
284
|
+
*/
|
285
|
+
createdAt: Date;
|
286
|
+
/**
|
287
|
+
*
|
288
|
+
* @type {string}
|
289
|
+
* @memberof BillingProductForSubscriptionResponseData
|
290
|
+
*/
|
291
|
+
currency: string;
|
292
|
+
/**
|
293
|
+
*
|
294
|
+
* @type {string}
|
295
|
+
* @memberof BillingProductForSubscriptionResponseData
|
296
|
+
*/
|
297
|
+
environmentId: string;
|
298
|
+
/**
|
299
|
+
*
|
300
|
+
* @type {string}
|
301
|
+
* @memberof BillingProductForSubscriptionResponseData
|
302
|
+
*/
|
303
|
+
externalId: string;
|
304
|
+
/**
|
305
|
+
*
|
306
|
+
* @type {string}
|
307
|
+
* @memberof BillingProductForSubscriptionResponseData
|
308
|
+
*/
|
309
|
+
id: string;
|
310
|
+
/**
|
311
|
+
*
|
312
|
+
* @type {string}
|
313
|
+
* @memberof BillingProductForSubscriptionResponseData
|
314
|
+
*/
|
315
|
+
interval?: string | null;
|
316
|
+
/**
|
317
|
+
*
|
318
|
+
* @type {string}
|
319
|
+
* @memberof BillingProductForSubscriptionResponseData
|
320
|
+
*/
|
321
|
+
name: string;
|
322
|
+
/**
|
323
|
+
*
|
324
|
+
* @type {number}
|
325
|
+
* @memberof BillingProductForSubscriptionResponseData
|
326
|
+
*/
|
327
|
+
price: number;
|
328
|
+
/**
|
329
|
+
*
|
330
|
+
* @type {number}
|
331
|
+
* @memberof BillingProductForSubscriptionResponseData
|
332
|
+
*/
|
333
|
+
quantity: number;
|
334
|
+
/**
|
335
|
+
*
|
336
|
+
* @type {string}
|
337
|
+
* @memberof BillingProductForSubscriptionResponseData
|
338
|
+
*/
|
339
|
+
subscriptionId: string;
|
340
|
+
/**
|
341
|
+
*
|
342
|
+
* @type {Date}
|
343
|
+
* @memberof BillingProductForSubscriptionResponseData
|
344
|
+
*/
|
345
|
+
updatedAt: Date;
|
346
|
+
}
|
347
|
+
|
348
|
+
/**
|
349
|
+
* Schematic API
|
350
|
+
* Schematic API
|
351
|
+
*
|
352
|
+
* The version of the OpenAPI document: 0.1
|
353
|
+
*
|
354
|
+
*
|
355
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
356
|
+
* https://openapi-generator.tech
|
357
|
+
* Do not edit the class manually.
|
358
|
+
*/
|
359
|
+
/**
|
360
|
+
* The created resource
|
361
|
+
* @export
|
362
|
+
* @interface BillingSubscriptionResponseData
|
363
|
+
*/
|
364
|
+
declare interface BillingSubscriptionResponseData {
|
365
|
+
/**
|
366
|
+
*
|
367
|
+
* @type {Date}
|
368
|
+
* @memberof BillingSubscriptionResponseData
|
369
|
+
*/
|
370
|
+
expiredAt?: Date | null;
|
371
|
+
/**
|
372
|
+
*
|
373
|
+
* @type {string}
|
374
|
+
* @memberof BillingSubscriptionResponseData
|
375
|
+
*/
|
376
|
+
externalId: string;
|
377
|
+
/**
|
378
|
+
*
|
379
|
+
* @type {number}
|
380
|
+
* @memberof BillingSubscriptionResponseData
|
381
|
+
*/
|
382
|
+
id: number;
|
383
|
+
/**
|
384
|
+
*
|
385
|
+
* @type {Date}
|
386
|
+
* @memberof BillingSubscriptionResponseData
|
387
|
+
*/
|
388
|
+
updatedAt: Date;
|
389
|
+
}
|
390
|
+
|
391
|
+
declare class BlobApiResponse {
|
392
|
+
raw: Response;
|
393
|
+
constructor(raw: Response);
|
394
|
+
value(): Promise<Blob>;
|
395
|
+
}
|
396
|
+
|
205
397
|
export declare const Box: IStyledComponentBase<"web", Substitute<DetailedHTMLProps<HTMLAttributes<HTMLDivElement>, HTMLDivElement>, ComponentProps>> & string;
|
206
398
|
|
207
399
|
export declare type BoxProps = ComponentProps;
|
@@ -220,6 +412,8 @@ export declare type ButtonStyleTypes = "blue" | "white" | "red" | "black";
|
|
220
412
|
|
221
413
|
export declare type ButtonVariantTypes = "solid" | "outline" | "ghost" | "link";
|
222
414
|
|
415
|
+
declare function canConsumeForm(consumes: Consume[]): boolean;
|
416
|
+
|
223
417
|
export declare const Card: ForwardRefExoticComponent<CardProps & RefAttributes<HTMLDivElement | null>>;
|
224
418
|
|
225
419
|
export declare interface CardProps {
|
@@ -227,6 +421,95 @@ export declare interface CardProps {
|
|
227
421
|
className?: string;
|
228
422
|
}
|
229
423
|
|
424
|
+
/**
|
425
|
+
* Schematic API
|
426
|
+
* Schematic API
|
427
|
+
*
|
428
|
+
* The version of the OpenAPI document: 0.1
|
429
|
+
*
|
430
|
+
*
|
431
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
432
|
+
* https://openapi-generator.tech
|
433
|
+
* Do not edit the class manually.
|
434
|
+
*/
|
435
|
+
/**
|
436
|
+
*
|
437
|
+
* @export
|
438
|
+
* @interface ChangeSubscriptionRequestBody
|
439
|
+
*/
|
440
|
+
declare interface ChangeSubscriptionRequestBody {
|
441
|
+
/**
|
442
|
+
*
|
443
|
+
* @type {string}
|
444
|
+
* @memberof ChangeSubscriptionRequestBody
|
445
|
+
*/
|
446
|
+
newPlanId: string;
|
447
|
+
/**
|
448
|
+
*
|
449
|
+
* @type {string}
|
450
|
+
* @memberof ChangeSubscriptionRequestBody
|
451
|
+
*/
|
452
|
+
newPriceId: string;
|
453
|
+
}
|
454
|
+
|
455
|
+
/**
|
456
|
+
*
|
457
|
+
*/
|
458
|
+
declare class CheckoutApi extends runtime.BaseAPI {
|
459
|
+
/**
|
460
|
+
* Checkout
|
461
|
+
*/
|
462
|
+
checkoutRaw(requestParameters: CheckoutRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CheckoutResponse>>;
|
463
|
+
/**
|
464
|
+
* Checkout
|
465
|
+
*/
|
466
|
+
checkout(requestParameters: CheckoutRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CheckoutResponse>;
|
467
|
+
/**
|
468
|
+
* Hydrate component
|
469
|
+
*/
|
470
|
+
hydrateComponentRaw(requestParameters: HydrateComponentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<HydrateComponentResponse>>;
|
471
|
+
/**
|
472
|
+
* Hydrate component
|
473
|
+
*/
|
474
|
+
hydrateComponent(requestParameters: HydrateComponentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<HydrateComponentResponse>;
|
475
|
+
}
|
476
|
+
|
477
|
+
declare interface CheckoutRequest {
|
478
|
+
changeSubscriptionRequestBody: ChangeSubscriptionRequestBody;
|
479
|
+
}
|
480
|
+
|
481
|
+
/**
|
482
|
+
*
|
483
|
+
* @export
|
484
|
+
* @interface CheckoutResponse
|
485
|
+
*/
|
486
|
+
declare interface CheckoutResponse {
|
487
|
+
/**
|
488
|
+
*
|
489
|
+
* @type {BillingSubscriptionResponseData}
|
490
|
+
* @memberof CheckoutResponse
|
491
|
+
*/
|
492
|
+
data: BillingSubscriptionResponseData;
|
493
|
+
/**
|
494
|
+
* Input parameters
|
495
|
+
* @type {object}
|
496
|
+
* @memberof CheckoutResponse
|
497
|
+
*/
|
498
|
+
params: object;
|
499
|
+
}
|
500
|
+
|
501
|
+
declare const COLLECTION_FORMATS: {
|
502
|
+
csv: string;
|
503
|
+
ssv: string;
|
504
|
+
tsv: string;
|
505
|
+
pipes: string;
|
506
|
+
};
|
507
|
+
|
508
|
+
export declare const Column: ForwardRefExoticComponent<Omit<ColumnProps, "ref"> & RefAttributes<HTMLDivElement | null>>;
|
509
|
+
|
510
|
+
export declare interface ColumnProps extends React.HTMLProps<HTMLDivElement> {
|
511
|
+
}
|
512
|
+
|
230
513
|
/**
|
231
514
|
*
|
232
515
|
* @export
|
@@ -423,6 +706,62 @@ declare interface CompanyPlanDetailResponseData {
|
|
423
706
|
yearlyPrice?: BillingPriceResponseData;
|
424
707
|
}
|
425
708
|
|
709
|
+
/**
|
710
|
+
*
|
711
|
+
* @export
|
712
|
+
* @interface CompanySubscriptionResponseData
|
713
|
+
*/
|
714
|
+
declare interface CompanySubscriptionResponseData {
|
715
|
+
/**
|
716
|
+
*
|
717
|
+
* @type {string}
|
718
|
+
* @memberof CompanySubscriptionResponseData
|
719
|
+
*/
|
720
|
+
customerExternalId: string;
|
721
|
+
/**
|
722
|
+
*
|
723
|
+
* @type {Date}
|
724
|
+
* @memberof CompanySubscriptionResponseData
|
725
|
+
*/
|
726
|
+
expiredAt?: Date | null;
|
727
|
+
/**
|
728
|
+
*
|
729
|
+
* @type {string}
|
730
|
+
* @memberof CompanySubscriptionResponseData
|
731
|
+
*/
|
732
|
+
interval: string;
|
733
|
+
/**
|
734
|
+
*
|
735
|
+
* @type {InvoiceResponseData}
|
736
|
+
* @memberof CompanySubscriptionResponseData
|
737
|
+
*/
|
738
|
+
latestInvoice?: InvoiceResponseData;
|
739
|
+
/**
|
740
|
+
*
|
741
|
+
* @type {PaymentMethodResponseData}
|
742
|
+
* @memberof CompanySubscriptionResponseData
|
743
|
+
*/
|
744
|
+
paymentMethod?: PaymentMethodResponseData;
|
745
|
+
/**
|
746
|
+
*
|
747
|
+
* @type {Array<BillingProductForSubscriptionResponseData>}
|
748
|
+
* @memberof CompanySubscriptionResponseData
|
749
|
+
*/
|
750
|
+
products: Array<BillingProductForSubscriptionResponseData>;
|
751
|
+
/**
|
752
|
+
*
|
753
|
+
* @type {string}
|
754
|
+
* @memberof CompanySubscriptionResponseData
|
755
|
+
*/
|
756
|
+
subscriptionExternalId: string;
|
757
|
+
/**
|
758
|
+
*
|
759
|
+
* @type {number}
|
760
|
+
* @memberof CompanySubscriptionResponseData
|
761
|
+
*/
|
762
|
+
totalPrice: number;
|
763
|
+
}
|
764
|
+
|
426
765
|
/**
|
427
766
|
* The returned resource
|
428
767
|
* @export
|
@@ -459,6 +798,18 @@ declare interface ComponentHydrateResponseData {
|
|
459
798
|
* @memberof ComponentHydrateResponseData
|
460
799
|
*/
|
461
800
|
stripeEmbed?: StripeEmbedInfo;
|
801
|
+
/**
|
802
|
+
*
|
803
|
+
* @type {CompanySubscriptionResponseData}
|
804
|
+
* @memberof ComponentHydrateResponseData
|
805
|
+
*/
|
806
|
+
subscription?: CompanySubscriptionResponseData;
|
807
|
+
/**
|
808
|
+
*
|
809
|
+
* @type {InvoiceResponseData}
|
810
|
+
* @memberof ComponentHydrateResponseData
|
811
|
+
*/
|
812
|
+
upcomingInvoice?: InvoiceResponseData;
|
462
813
|
}
|
463
814
|
|
464
815
|
declare interface ComponentProps extends TransientCSSProperties {
|
@@ -528,6 +879,22 @@ declare interface ComponentResponseData {
|
|
528
879
|
updatedAt: Date;
|
529
880
|
}
|
530
881
|
|
882
|
+
declare class Configuration {
|
883
|
+
private configuration;
|
884
|
+
constructor(configuration?: ConfigurationParameters);
|
885
|
+
set config(configuration: Configuration);
|
886
|
+
get basePath(): string;
|
887
|
+
get fetchApi(): FetchAPI | undefined;
|
888
|
+
get middleware(): Middleware[];
|
889
|
+
get queryParamsStringify(): (params: HTTPQuery) => string;
|
890
|
+
get username(): string | undefined;
|
891
|
+
get password(): string | undefined;
|
892
|
+
get apiKey(): ((name: string) => string | Promise<string>) | undefined;
|
893
|
+
get accessToken(): ((name?: string, scopes?: string[]) => string | Promise<string>) | undefined;
|
894
|
+
get headers(): HTTPHeaders | undefined;
|
895
|
+
get credentials(): RequestCredentials | undefined;
|
896
|
+
}
|
897
|
+
|
531
898
|
declare interface ConfigurationParameters {
|
532
899
|
basePath?: string;
|
533
900
|
fetchApi?: FetchAPI;
|
@@ -541,6 +908,10 @@ declare interface ConfigurationParameters {
|
|
541
908
|
credentials?: RequestCredentials;
|
542
909
|
}
|
543
910
|
|
911
|
+
declare interface Consume {
|
912
|
+
contentType: string;
|
913
|
+
}
|
914
|
+
|
544
915
|
declare const _default: {
|
545
916
|
alarm: number;
|
546
917
|
"arrow-curved": number;
|
@@ -641,6 +1012,8 @@ declare const _default: {
|
|
641
1012
|
wind: number;
|
642
1013
|
};
|
643
1014
|
|
1015
|
+
declare const DefaultConfig: Configuration;
|
1016
|
+
|
644
1017
|
export declare const defaultSettings: EmbedSettings;
|
645
1018
|
|
646
1019
|
export declare const defaultTheme: EmbedThemeSettings;
|
@@ -779,13 +1152,16 @@ declare interface ElementProps {
|
|
779
1152
|
export declare const EmbedContext: Context<EmbedContextProps>;
|
780
1153
|
|
781
1154
|
export declare interface EmbedContextProps {
|
782
|
-
|
1155
|
+
api: CheckoutApi | null;
|
1156
|
+
data: ComponentHydrateResponseData;
|
783
1157
|
nodes: SerializedNodeWithChildren[];
|
784
1158
|
settings: EmbedSettings;
|
1159
|
+
stripe: Promise<Stripe | null> | null;
|
785
1160
|
layout: EmbedLayout;
|
786
1161
|
error?: Error;
|
787
1162
|
setData: (data: RecursivePartial<ComponentHydrateResponseData>) => void;
|
788
1163
|
updateSettings: (settings: RecursivePartial<EmbedSettings>) => void;
|
1164
|
+
setStripe: (stripe: Promise<Stripe | null> | null) => void;
|
789
1165
|
setLayout: (layout: EmbedLayout) => void;
|
790
1166
|
}
|
791
1167
|
|
@@ -1408,6 +1784,12 @@ declare type FeatureUsageResponseDataAllocationTypeEnum = (typeof FeatureUsageRe
|
|
1408
1784
|
|
1409
1785
|
declare type FetchAPI = WindowOrWorkerGlobalScope["fetch"];
|
1410
1786
|
|
1787
|
+
declare class FetchError extends Error {
|
1788
|
+
cause: Error;
|
1789
|
+
name: "FetchError";
|
1790
|
+
constructor(cause: Error, msg?: string);
|
1791
|
+
}
|
1792
|
+
|
1411
1793
|
declare interface FetchParams {
|
1412
1794
|
url: string;
|
1413
1795
|
init: RequestInit;
|
@@ -1509,14 +1891,49 @@ ref?: ((instance: HTMLDivElement | null) => void | DO_NOT_USE_OR_YOU_WILL_BE_FIR
|
|
1509
1891
|
|
1510
1892
|
declare type FontStyle = keyof EmbedThemeSettings["typography"];
|
1511
1893
|
|
1894
|
+
declare type HTTPBody = Json | FormData | URLSearchParams;
|
1895
|
+
|
1512
1896
|
declare type HTTPHeaders = {
|
1513
1897
|
[key: string]: string;
|
1514
1898
|
};
|
1515
1899
|
|
1900
|
+
declare type HTTPMethod = "GET" | "POST" | "PUT" | "PATCH" | "DELETE" | "OPTIONS" | "HEAD";
|
1901
|
+
|
1516
1902
|
declare type HTTPQuery = {
|
1517
1903
|
[key: string]: string | number | null | boolean | Array<string | number | null | boolean> | Set<string | number | null | boolean> | HTTPQuery;
|
1518
1904
|
};
|
1519
1905
|
|
1906
|
+
declare type HTTPRequestInit = {
|
1907
|
+
headers?: HTTPHeaders;
|
1908
|
+
method: HTTPMethod;
|
1909
|
+
credentials?: RequestCredentials;
|
1910
|
+
body?: HTTPBody;
|
1911
|
+
};
|
1912
|
+
|
1913
|
+
declare interface HydrateComponentRequest {
|
1914
|
+
componentId: string;
|
1915
|
+
}
|
1916
|
+
|
1917
|
+
/**
|
1918
|
+
*
|
1919
|
+
* @export
|
1920
|
+
* @interface HydrateComponentResponse
|
1921
|
+
*/
|
1922
|
+
declare interface HydrateComponentResponse {
|
1923
|
+
/**
|
1924
|
+
*
|
1925
|
+
* @type {ComponentHydrateResponseData}
|
1926
|
+
* @memberof HydrateComponentResponse
|
1927
|
+
*/
|
1928
|
+
data: ComponentHydrateResponseData;
|
1929
|
+
/**
|
1930
|
+
* Input parameters
|
1931
|
+
* @type {object}
|
1932
|
+
* @memberof HydrateComponentResponse
|
1933
|
+
*/
|
1934
|
+
params: object;
|
1935
|
+
}
|
1936
|
+
|
1520
1937
|
export declare const Icon: ({ name, className, ...props }: IconProps) => JSX_2.Element;
|
1521
1938
|
|
1522
1939
|
export declare type IconNameTypes = keyof typeof _default;
|
@@ -1538,12 +1955,137 @@ export declare const IncludedFeatures: ForwardRefExoticComponent<ElementProps &
|
|
1538
1955
|
|
1539
1956
|
export declare type IncludedFeaturesProps = DesignProps_2;
|
1540
1957
|
|
1958
|
+
declare type InitOverrideFunction = (requestContext: {
|
1959
|
+
init: HTTPRequestInit;
|
1960
|
+
context: RequestOpts;
|
1961
|
+
}) => Promise<RequestInit>;
|
1962
|
+
|
1963
|
+
/**
|
1964
|
+
* Schematic API
|
1965
|
+
* Schematic API
|
1966
|
+
*
|
1967
|
+
* The version of the OpenAPI document: 0.1
|
1968
|
+
*
|
1969
|
+
*
|
1970
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
1971
|
+
* https://openapi-generator.tech
|
1972
|
+
* Do not edit the class manually.
|
1973
|
+
*/
|
1974
|
+
/**
|
1975
|
+
*
|
1976
|
+
* @export
|
1977
|
+
* @interface InvoiceResponseData
|
1978
|
+
*/
|
1979
|
+
declare interface InvoiceResponseData {
|
1980
|
+
/**
|
1981
|
+
*
|
1982
|
+
* @type {number}
|
1983
|
+
* @memberof InvoiceResponseData
|
1984
|
+
*/
|
1985
|
+
amountDue: number;
|
1986
|
+
/**
|
1987
|
+
*
|
1988
|
+
* @type {number}
|
1989
|
+
* @memberof InvoiceResponseData
|
1990
|
+
*/
|
1991
|
+
amountPaid: number;
|
1992
|
+
/**
|
1993
|
+
*
|
1994
|
+
* @type {number}
|
1995
|
+
* @memberof InvoiceResponseData
|
1996
|
+
*/
|
1997
|
+
amountRemaining: number;
|
1998
|
+
/**
|
1999
|
+
*
|
2000
|
+
* @type {string}
|
2001
|
+
* @memberof InvoiceResponseData
|
2002
|
+
*/
|
2003
|
+
collectionMethod: string;
|
2004
|
+
/**
|
2005
|
+
*
|
2006
|
+
* @type {string}
|
2007
|
+
* @memberof InvoiceResponseData
|
2008
|
+
*/
|
2009
|
+
companyId?: string | null;
|
2010
|
+
/**
|
2011
|
+
*
|
2012
|
+
* @type {Date}
|
2013
|
+
* @memberof InvoiceResponseData
|
2014
|
+
*/
|
2015
|
+
createdAt: Date;
|
2016
|
+
/**
|
2017
|
+
*
|
2018
|
+
* @type {string}
|
2019
|
+
* @memberof InvoiceResponseData
|
2020
|
+
*/
|
2021
|
+
currency: string;
|
2022
|
+
/**
|
2023
|
+
*
|
2024
|
+
* @type {string}
|
2025
|
+
* @memberof InvoiceResponseData
|
2026
|
+
*/
|
2027
|
+
customerExternalId: string;
|
2028
|
+
/**
|
2029
|
+
*
|
2030
|
+
* @type {Date}
|
2031
|
+
* @memberof InvoiceResponseData
|
2032
|
+
*/
|
2033
|
+
dueDate?: Date | null;
|
2034
|
+
/**
|
2035
|
+
*
|
2036
|
+
* @type {string}
|
2037
|
+
* @memberof InvoiceResponseData
|
2038
|
+
*/
|
2039
|
+
environmentId: string;
|
2040
|
+
/**
|
2041
|
+
*
|
2042
|
+
* @type {string}
|
2043
|
+
* @memberof InvoiceResponseData
|
2044
|
+
*/
|
2045
|
+
externalId: string;
|
2046
|
+
/**
|
2047
|
+
*
|
2048
|
+
* @type {string}
|
2049
|
+
* @memberof InvoiceResponseData
|
2050
|
+
*/
|
2051
|
+
id: string;
|
2052
|
+
/**
|
2053
|
+
*
|
2054
|
+
* @type {string}
|
2055
|
+
* @memberof InvoiceResponseData
|
2056
|
+
*/
|
2057
|
+
subscriptionExternalId?: string | null;
|
2058
|
+
/**
|
2059
|
+
*
|
2060
|
+
* @type {number}
|
2061
|
+
* @memberof InvoiceResponseData
|
2062
|
+
*/
|
2063
|
+
subtotal: number;
|
2064
|
+
/**
|
2065
|
+
*
|
2066
|
+
* @type {Date}
|
2067
|
+
* @memberof InvoiceResponseData
|
2068
|
+
*/
|
2069
|
+
updatedAt: Date;
|
2070
|
+
}
|
2071
|
+
|
1541
2072
|
export declare const Invoices: ForwardRefExoticComponent<ElementProps & RecursivePartial<DesignProps_6> & HTMLAttributes<HTMLDivElement> & RefAttributes<HTMLDivElement | null>>;
|
1542
2073
|
|
1543
2074
|
export declare type InvoicesProps = DesignProps_6;
|
1544
2075
|
|
2076
|
+
declare type Json = any;
|
2077
|
+
|
2078
|
+
declare class JSONApiResponse<T> {
|
2079
|
+
raw: Response;
|
2080
|
+
private transformer;
|
2081
|
+
constructor(raw: Response, transformer?: ResponseTransformer<T>);
|
2082
|
+
value(): Promise<T>;
|
2083
|
+
}
|
2084
|
+
|
1545
2085
|
export { Keys }
|
1546
2086
|
|
2087
|
+
declare function mapValues(data: any, fn: (item: any) => any): {};
|
2088
|
+
|
1547
2089
|
export declare const MeteredFeatures: ForwardRefExoticComponent<ElementProps & RecursivePartial<DesignProps_3> & HTMLAttributes<HTMLDivElement> & RefAttributes<HTMLDivElement | null>>;
|
1548
2090
|
|
1549
2091
|
export declare type MeteredFeaturesProps = DesignProps_3;
|
@@ -1554,12 +2096,136 @@ declare interface Middleware {
|
|
1554
2096
|
onError?(context: ErrorContext): Promise<Response | void>;
|
1555
2097
|
}
|
1556
2098
|
|
2099
|
+
declare type ModelPropertyNaming = "camelCase" | "snake_case" | "PascalCase" | "original";
|
2100
|
+
|
2101
|
+
export declare const OverlayHeader: ({ children, onClose, }: {
|
2102
|
+
children: ReactNode;
|
2103
|
+
onClose?: () => void;
|
2104
|
+
}) => JSX_2.Element;
|
2105
|
+
|
2106
|
+
export declare const OverlaySideBar: ({ pricePeriod, setPricePeriod, checkoutStage, setCheckoutStage, currentPlan, selectedPlan, }: {
|
2107
|
+
pricePeriod: "month" | "year";
|
2108
|
+
setPricePeriod: Dispatch<SetStateAction<"month" | "year">>;
|
2109
|
+
checkoutStage: "plan" | "checkout";
|
2110
|
+
setCheckoutStage: Dispatch<SetStateAction<"plan" | "checkout">>;
|
2111
|
+
currentPlan?: BillingPlan;
|
2112
|
+
selectedPlan?: CompanyPlanDetailResponseData;
|
2113
|
+
}) => JSX_2.Element;
|
2114
|
+
|
2115
|
+
export declare const OverlayWrapper: ({ children, size, }: {
|
2116
|
+
children: ReactNode;
|
2117
|
+
size?: "md" | "lg";
|
2118
|
+
}) => JSX_2.Element;
|
2119
|
+
|
1557
2120
|
export declare const PaymentMethod: ForwardRefExoticComponent<ElementProps & RecursivePartial<DesignProps_5> & HTMLAttributes<HTMLDivElement> & {
|
1558
2121
|
portal?: HTMLElement | null;
|
1559
2122
|
} & RefAttributes<HTMLDivElement | null>>;
|
1560
2123
|
|
1561
2124
|
export declare type PaymentMethodProps = DesignProps_5;
|
1562
2125
|
|
2126
|
+
/**
|
2127
|
+
* Schematic API
|
2128
|
+
* Schematic API
|
2129
|
+
*
|
2130
|
+
* The version of the OpenAPI document: 0.1
|
2131
|
+
*
|
2132
|
+
*
|
2133
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
2134
|
+
* https://openapi-generator.tech
|
2135
|
+
* Do not edit the class manually.
|
2136
|
+
*/
|
2137
|
+
/**
|
2138
|
+
*
|
2139
|
+
* @export
|
2140
|
+
* @interface PaymentMethodResponseData
|
2141
|
+
*/
|
2142
|
+
declare interface PaymentMethodResponseData {
|
2143
|
+
/**
|
2144
|
+
*
|
2145
|
+
* @type {string}
|
2146
|
+
* @memberof PaymentMethodResponseData
|
2147
|
+
*/
|
2148
|
+
cardBrand?: string | null;
|
2149
|
+
/**
|
2150
|
+
*
|
2151
|
+
* @type {number}
|
2152
|
+
* @memberof PaymentMethodResponseData
|
2153
|
+
*/
|
2154
|
+
cardExpMonth?: number | null;
|
2155
|
+
/**
|
2156
|
+
*
|
2157
|
+
* @type {number}
|
2158
|
+
* @memberof PaymentMethodResponseData
|
2159
|
+
*/
|
2160
|
+
cardExpYear?: number | null;
|
2161
|
+
/**
|
2162
|
+
*
|
2163
|
+
* @type {string}
|
2164
|
+
* @memberof PaymentMethodResponseData
|
2165
|
+
*/
|
2166
|
+
cardLast4?: string | null;
|
2167
|
+
/**
|
2168
|
+
*
|
2169
|
+
* @type {string}
|
2170
|
+
* @memberof PaymentMethodResponseData
|
2171
|
+
*/
|
2172
|
+
companyId?: string | null;
|
2173
|
+
/**
|
2174
|
+
*
|
2175
|
+
* @type {Date}
|
2176
|
+
* @memberof PaymentMethodResponseData
|
2177
|
+
*/
|
2178
|
+
createdAt: Date;
|
2179
|
+
/**
|
2180
|
+
*
|
2181
|
+
* @type {string}
|
2182
|
+
* @memberof PaymentMethodResponseData
|
2183
|
+
*/
|
2184
|
+
customerExternalId: string;
|
2185
|
+
/**
|
2186
|
+
*
|
2187
|
+
* @type {string}
|
2188
|
+
* @memberof PaymentMethodResponseData
|
2189
|
+
*/
|
2190
|
+
environmentId: string;
|
2191
|
+
/**
|
2192
|
+
*
|
2193
|
+
* @type {string}
|
2194
|
+
* @memberof PaymentMethodResponseData
|
2195
|
+
*/
|
2196
|
+
externalId: string;
|
2197
|
+
/**
|
2198
|
+
*
|
2199
|
+
* @type {string}
|
2200
|
+
* @memberof PaymentMethodResponseData
|
2201
|
+
*/
|
2202
|
+
id: string;
|
2203
|
+
/**
|
2204
|
+
*
|
2205
|
+
* @type {string}
|
2206
|
+
* @memberof PaymentMethodResponseData
|
2207
|
+
*/
|
2208
|
+
invoiceExternalId?: string | null;
|
2209
|
+
/**
|
2210
|
+
*
|
2211
|
+
* @type {string}
|
2212
|
+
* @memberof PaymentMethodResponseData
|
2213
|
+
*/
|
2214
|
+
paymentMethodType: string;
|
2215
|
+
/**
|
2216
|
+
*
|
2217
|
+
* @type {string}
|
2218
|
+
* @memberof PaymentMethodResponseData
|
2219
|
+
*/
|
2220
|
+
subscriptionExternalId?: string | null;
|
2221
|
+
/**
|
2222
|
+
*
|
2223
|
+
* @type {Date}
|
2224
|
+
* @memberof PaymentMethodResponseData
|
2225
|
+
*/
|
2226
|
+
updatedAt: Date;
|
2227
|
+
}
|
2228
|
+
|
1563
2229
|
/**
|
1564
2230
|
*
|
1565
2231
|
* @export
|
@@ -1784,6 +2450,8 @@ export declare interface ProgressBarProps extends React.ComponentPropsWithoutRef
|
|
1784
2450
|
barWidth?: string | number;
|
1785
2451
|
}
|
1786
2452
|
|
2453
|
+
declare function querystring(params: HTTPQuery, prefix?: string): string;
|
2454
|
+
|
1787
2455
|
declare type RecursivePartial<T> = {
|
1788
2456
|
[P in keyof T]?: T[P] extends (infer U)[] ? RecursivePartial<U>[] : T[P] extends object | undefined ? RecursivePartial<T[P]> : T[P];
|
1789
2457
|
};
|
@@ -1794,6 +2462,20 @@ declare interface RequestContext {
|
|
1794
2462
|
init: RequestInit;
|
1795
2463
|
}
|
1796
2464
|
|
2465
|
+
declare interface RequestOpts {
|
2466
|
+
path: string;
|
2467
|
+
method: HTTPMethod;
|
2468
|
+
headers: HTTPHeaders;
|
2469
|
+
query?: HTTPQuery;
|
2470
|
+
body?: HTTPBody;
|
2471
|
+
}
|
2472
|
+
|
2473
|
+
declare class RequiredError extends Error {
|
2474
|
+
field: string;
|
2475
|
+
name: "RequiredError";
|
2476
|
+
constructor(field: string, msg?: string);
|
2477
|
+
}
|
2478
|
+
|
1797
2479
|
declare interface ResponseContext {
|
1798
2480
|
fetch: FetchAPI;
|
1799
2481
|
url: string;
|
@@ -1801,6 +2483,21 @@ declare interface ResponseContext {
|
|
1801
2483
|
response: Response;
|
1802
2484
|
}
|
1803
2485
|
|
2486
|
+
declare class ResponseError extends Error {
|
2487
|
+
response: Response;
|
2488
|
+
name: "ResponseError";
|
2489
|
+
constructor(response: Response, msg?: string);
|
2490
|
+
}
|
2491
|
+
|
2492
|
+
declare interface ResponseTransformer<T> {
|
2493
|
+
(json: any): T;
|
2494
|
+
}
|
2495
|
+
|
2496
|
+
export declare const Root: ForwardRefExoticComponent<Omit<RootProps, "ref"> & RefAttributes<HTMLDivElement | null>>;
|
2497
|
+
|
2498
|
+
export declare interface RootProps extends React.HTMLProps<HTMLDivElement> {
|
2499
|
+
}
|
2500
|
+
|
1804
2501
|
/**
|
1805
2502
|
*
|
1806
2503
|
* @export
|
@@ -2102,6 +2799,45 @@ declare interface RuleDetailResponseData {
|
|
2102
2799
|
value: boolean;
|
2103
2800
|
}
|
2104
2801
|
|
2802
|
+
declare namespace runtime {
|
2803
|
+
export {
|
2804
|
+
querystring,
|
2805
|
+
mapValues,
|
2806
|
+
canConsumeForm,
|
2807
|
+
BASE_PATH,
|
2808
|
+
ConfigurationParameters,
|
2809
|
+
Configuration,
|
2810
|
+
DefaultConfig,
|
2811
|
+
BaseAPI,
|
2812
|
+
ResponseError,
|
2813
|
+
FetchError,
|
2814
|
+
RequiredError,
|
2815
|
+
COLLECTION_FORMATS,
|
2816
|
+
FetchAPI,
|
2817
|
+
Json,
|
2818
|
+
HTTPMethod,
|
2819
|
+
HTTPHeaders,
|
2820
|
+
HTTPQuery,
|
2821
|
+
HTTPBody,
|
2822
|
+
HTTPRequestInit,
|
2823
|
+
ModelPropertyNaming,
|
2824
|
+
InitOverrideFunction,
|
2825
|
+
FetchParams,
|
2826
|
+
RequestOpts,
|
2827
|
+
Consume,
|
2828
|
+
RequestContext,
|
2829
|
+
ResponseContext,
|
2830
|
+
ErrorContext,
|
2831
|
+
Middleware,
|
2832
|
+
ApiResponse,
|
2833
|
+
ResponseTransformer,
|
2834
|
+
JSONApiResponse,
|
2835
|
+
VoidApiResponse,
|
2836
|
+
BlobApiResponse,
|
2837
|
+
TextApiResponse
|
2838
|
+
}
|
2839
|
+
}
|
2840
|
+
|
2105
2841
|
export { Schematic }
|
2106
2842
|
|
2107
2843
|
export { SchematicContext }
|
@@ -2119,7 +2855,7 @@ export declare interface SchematicHookOpts {
|
|
2119
2855
|
|
2120
2856
|
export { SchematicOptions }
|
2121
2857
|
|
2122
|
-
export declare const SchematicProvider:
|
2858
|
+
export declare const SchematicProvider: React.FC<SchematicProviderProps>;
|
2123
2859
|
|
2124
2860
|
export declare type SchematicProviderProps = SchematicProviderPropsWithClient | SchematicProviderPropsWithPublishableKey;
|
2125
2861
|
|
@@ -2164,7 +2900,7 @@ declare interface StripeEmbedInfo {
|
|
2164
2900
|
* @type {string}
|
2165
2901
|
* @memberof StripeEmbedInfo
|
2166
2902
|
*/
|
2167
|
-
customerEkey
|
2903
|
+
customerEkey?: string | null;
|
2168
2904
|
/**
|
2169
2905
|
*
|
2170
2906
|
* @type {string}
|
@@ -2176,6 +2912,12 @@ declare interface StripeEmbedInfo {
|
|
2176
2912
|
declare const Text_2: IStyledComponentBase<"web", Substitute<DetailedHTMLProps<HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, TextProps>> & string;
|
2177
2913
|
export { Text_2 as Text }
|
2178
2914
|
|
2915
|
+
declare class TextApiResponse {
|
2916
|
+
raw: Response;
|
2917
|
+
constructor(raw: Response);
|
2918
|
+
value(): Promise<string>;
|
2919
|
+
}
|
2920
|
+
|
2179
2921
|
export declare interface TextProps extends ComponentProps {
|
2180
2922
|
$align?: ComponentProps["$textAlign"];
|
2181
2923
|
$font?: ComponentProps["$fontFamily"];
|
@@ -2221,4 +2963,15 @@ export declare type UseSchematicFlagOpts = SchematicHookOpts & {
|
|
2221
2963
|
fallback?: boolean;
|
2222
2964
|
};
|
2223
2965
|
|
2966
|
+
export declare const Viewport: ForwardRefExoticComponent<Omit<ViewportProps, "ref"> & RefAttributes<HTMLDivElement | null>>;
|
2967
|
+
|
2968
|
+
export declare interface ViewportProps extends React.HTMLProps<HTMLDivElement> {
|
2969
|
+
}
|
2970
|
+
|
2971
|
+
declare class VoidApiResponse {
|
2972
|
+
raw: Response;
|
2973
|
+
constructor(raw: Response);
|
2974
|
+
value(): Promise<void>;
|
2975
|
+
}
|
2976
|
+
|
2224
2977
|
export { }
|