@wix/forms 1.0.102 → 1.0.103
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.
|
@@ -3586,37 +3586,38 @@ interface UpdateExtendedFieldsOptions {
|
|
|
3586
3586
|
namespaceData: Record<string, any> | null;
|
|
3587
3587
|
}
|
|
3588
3588
|
|
|
3589
|
-
interface HttpClient {
|
|
3590
|
-
request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
|
|
3591
|
-
fetchWithAuth:
|
|
3589
|
+
interface HttpClient$2 {
|
|
3590
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory$2<TResponse, TData>): Promise<HttpResponse$2<TResponse>>;
|
|
3591
|
+
fetchWithAuth: typeof fetch;
|
|
3592
|
+
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
3592
3593
|
}
|
|
3593
|
-
type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
|
|
3594
|
-
type HttpResponse<T = any> = {
|
|
3594
|
+
type RequestOptionsFactory$2<TResponse = any, TData = any> = (context: any) => RequestOptions$2<TResponse, TData>;
|
|
3595
|
+
type HttpResponse$2<T = any> = {
|
|
3595
3596
|
data: T;
|
|
3596
3597
|
status: number;
|
|
3597
3598
|
statusText: string;
|
|
3598
3599
|
headers: any;
|
|
3599
3600
|
request?: any;
|
|
3600
3601
|
};
|
|
3601
|
-
type RequestOptions<_TResponse = any, Data = any> = {
|
|
3602
|
+
type RequestOptions$2<_TResponse = any, Data = any> = {
|
|
3602
3603
|
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
3603
3604
|
url: string;
|
|
3604
3605
|
data?: Data;
|
|
3605
3606
|
params?: URLSearchParams;
|
|
3606
|
-
} & APIMetadata;
|
|
3607
|
-
type APIMetadata = {
|
|
3607
|
+
} & APIMetadata$2;
|
|
3608
|
+
type APIMetadata$2 = {
|
|
3608
3609
|
methodFqn?: string;
|
|
3609
3610
|
entityFqdn?: string;
|
|
3610
3611
|
packageName?: string;
|
|
3611
3612
|
};
|
|
3612
|
-
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
|
3613
|
+
type EventDefinition$2<Payload = unknown, Type extends string = string> = {
|
|
3613
3614
|
__type: 'event-definition';
|
|
3614
3615
|
type: Type;
|
|
3615
3616
|
isDomainEvent?: boolean;
|
|
3616
3617
|
transformations?: (envelope: unknown) => Payload;
|
|
3617
3618
|
__payload: Payload;
|
|
3618
3619
|
};
|
|
3619
|
-
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
|
3620
|
+
declare function EventDefinition$2<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$2<Payload, Type>;
|
|
3620
3621
|
|
|
3621
3622
|
declare global {
|
|
3622
3623
|
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
@@ -3628,25 +3629,25 @@ declare global {
|
|
|
3628
3629
|
declare const __metadata$2: {
|
|
3629
3630
|
PACKAGE_NAME: string;
|
|
3630
3631
|
};
|
|
3631
|
-
declare function createForm(httpClient: HttpClient): (form: Form) => Promise<Form>;
|
|
3632
|
-
declare function bulkCreateForm(httpClient: HttpClient): (options?: BulkCreateFormOptions) => Promise<BulkCreateFormResponse>;
|
|
3633
|
-
declare function cloneForm(httpClient: HttpClient): (formId: string) => Promise<CloneFormResponse>;
|
|
3634
|
-
declare function getForm(httpClient: HttpClient): (formId: string, options?: GetFormOptions) => Promise<Form>;
|
|
3635
|
-
declare function updateForm(httpClient: HttpClient): (_id: string | null, form: UpdateForm) => Promise<Form>;
|
|
3636
|
-
declare function removeFormFromTrashBin(httpClient: HttpClient): (formId: string) => Promise<void>;
|
|
3637
|
-
declare function deleteForm(httpClient: HttpClient): (formId: string, options?: DeleteFormOptions) => Promise<void>;
|
|
3638
|
-
declare function restoreFromTrashBin(httpClient: HttpClient): (formId: string) => Promise<RestoreFromTrashBinResponse>;
|
|
3639
|
-
declare function queryForms(httpClient: HttpClient): (options?: QueryFormsOptions) => FormsQueryBuilder;
|
|
3640
|
-
declare function countForms(httpClient: HttpClient): (namespace: string, options?: CountFormsOptions) => Promise<CountFormsResponse>;
|
|
3641
|
-
declare function listForms(httpClient: HttpClient): (namespace: string, options?: ListFormsOptions) => Promise<ListFormsResponse>;
|
|
3642
|
-
declare function getDeletedForm(httpClient: HttpClient): (formId: string) => Promise<GetDeletedFormResponse>;
|
|
3643
|
-
declare function queryDeletedForms(httpClient: HttpClient): (query: CursorQuery$2) => Promise<QueryDeletedFormsResponse>;
|
|
3644
|
-
declare function listDeletedForms(httpClient: HttpClient): (namespace: string, options?: ListDeletedFormsOptions) => Promise<ListDeletedFormsResponse>;
|
|
3645
|
-
declare function bulkRemoveDeletedField(httpClient: HttpClient): (formId: string, options?: BulkRemoveDeletedFieldOptions) => Promise<BulkRemoveDeletedFieldResponse>;
|
|
3646
|
-
declare function updateExtendedFields(httpClient: HttpClient): (_id: string, namespace: string, options: UpdateExtendedFieldsOptions) => Promise<UpdateExtendedFieldsResponse>;
|
|
3647
|
-
declare const onFormCreated: EventDefinition<FormCreatedEnvelope, "wix.forms.v4.form_created">;
|
|
3648
|
-
declare const onFormUpdated: EventDefinition<FormUpdatedEnvelope, "wix.forms.v4.form_updated">;
|
|
3649
|
-
declare const onFormSubmissionKeysPermanentlyDeleted: EventDefinition<FormSubmissionKeysPermanentlyDeletedEnvelope, "wix.forms.v4.form_submission_keys_permanently_deleted">;
|
|
3632
|
+
declare function createForm(httpClient: HttpClient$2): (form: Form) => Promise<Form>;
|
|
3633
|
+
declare function bulkCreateForm(httpClient: HttpClient$2): (options?: BulkCreateFormOptions) => Promise<BulkCreateFormResponse>;
|
|
3634
|
+
declare function cloneForm(httpClient: HttpClient$2): (formId: string) => Promise<CloneFormResponse>;
|
|
3635
|
+
declare function getForm(httpClient: HttpClient$2): (formId: string, options?: GetFormOptions) => Promise<Form>;
|
|
3636
|
+
declare function updateForm(httpClient: HttpClient$2): (_id: string | null, form: UpdateForm) => Promise<Form>;
|
|
3637
|
+
declare function removeFormFromTrashBin(httpClient: HttpClient$2): (formId: string) => Promise<void>;
|
|
3638
|
+
declare function deleteForm(httpClient: HttpClient$2): (formId: string, options?: DeleteFormOptions) => Promise<void>;
|
|
3639
|
+
declare function restoreFromTrashBin(httpClient: HttpClient$2): (formId: string) => Promise<RestoreFromTrashBinResponse>;
|
|
3640
|
+
declare function queryForms(httpClient: HttpClient$2): (options?: QueryFormsOptions) => FormsQueryBuilder;
|
|
3641
|
+
declare function countForms(httpClient: HttpClient$2): (namespace: string, options?: CountFormsOptions) => Promise<CountFormsResponse>;
|
|
3642
|
+
declare function listForms(httpClient: HttpClient$2): (namespace: string, options?: ListFormsOptions) => Promise<ListFormsResponse>;
|
|
3643
|
+
declare function getDeletedForm(httpClient: HttpClient$2): (formId: string) => Promise<GetDeletedFormResponse>;
|
|
3644
|
+
declare function queryDeletedForms(httpClient: HttpClient$2): (query: CursorQuery$2) => Promise<QueryDeletedFormsResponse>;
|
|
3645
|
+
declare function listDeletedForms(httpClient: HttpClient$2): (namespace: string, options?: ListDeletedFormsOptions) => Promise<ListDeletedFormsResponse>;
|
|
3646
|
+
declare function bulkRemoveDeletedField(httpClient: HttpClient$2): (formId: string, options?: BulkRemoveDeletedFieldOptions) => Promise<BulkRemoveDeletedFieldResponse>;
|
|
3647
|
+
declare function updateExtendedFields(httpClient: HttpClient$2): (_id: string, namespace: string, options: UpdateExtendedFieldsOptions) => Promise<UpdateExtendedFieldsResponse>;
|
|
3648
|
+
declare const onFormCreated: EventDefinition$2<FormCreatedEnvelope, "wix.forms.v4.form_created">;
|
|
3649
|
+
declare const onFormUpdated: EventDefinition$2<FormUpdatedEnvelope, "wix.forms.v4.form_updated">;
|
|
3650
|
+
declare const onFormSubmissionKeysPermanentlyDeleted: EventDefinition$2<FormSubmissionKeysPermanentlyDeletedEnvelope, "wix.forms.v4.form_submission_keys_permanently_deleted">;
|
|
3650
3651
|
|
|
3651
3652
|
type index_d$2_AddressInfo = AddressInfo;
|
|
3652
3653
|
type index_d$2_AddressLine2 = AddressLine2;
|
|
@@ -4754,23 +4755,63 @@ interface FormSpamSubmissionReportsQueryBuilder {
|
|
|
4754
4755
|
find: () => Promise<FormSpamSubmissionReportsQueryResult>;
|
|
4755
4756
|
}
|
|
4756
4757
|
|
|
4758
|
+
interface HttpClient$1 {
|
|
4759
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory$1<TResponse, TData>): Promise<HttpResponse$1<TResponse>>;
|
|
4760
|
+
fetchWithAuth: typeof fetch;
|
|
4761
|
+
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
4762
|
+
}
|
|
4763
|
+
type RequestOptionsFactory$1<TResponse = any, TData = any> = (context: any) => RequestOptions$1<TResponse, TData>;
|
|
4764
|
+
type HttpResponse$1<T = any> = {
|
|
4765
|
+
data: T;
|
|
4766
|
+
status: number;
|
|
4767
|
+
statusText: string;
|
|
4768
|
+
headers: any;
|
|
4769
|
+
request?: any;
|
|
4770
|
+
};
|
|
4771
|
+
type RequestOptions$1<_TResponse = any, Data = any> = {
|
|
4772
|
+
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
4773
|
+
url: string;
|
|
4774
|
+
data?: Data;
|
|
4775
|
+
params?: URLSearchParams;
|
|
4776
|
+
} & APIMetadata$1;
|
|
4777
|
+
type APIMetadata$1 = {
|
|
4778
|
+
methodFqn?: string;
|
|
4779
|
+
entityFqdn?: string;
|
|
4780
|
+
packageName?: string;
|
|
4781
|
+
};
|
|
4782
|
+
type EventDefinition$1<Payload = unknown, Type extends string = string> = {
|
|
4783
|
+
__type: 'event-definition';
|
|
4784
|
+
type: Type;
|
|
4785
|
+
isDomainEvent?: boolean;
|
|
4786
|
+
transformations?: (envelope: unknown) => Payload;
|
|
4787
|
+
__payload: Payload;
|
|
4788
|
+
};
|
|
4789
|
+
declare function EventDefinition$1<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition$1<Payload, Type>;
|
|
4790
|
+
|
|
4791
|
+
declare global {
|
|
4792
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
4793
|
+
interface SymbolConstructor {
|
|
4794
|
+
readonly observable: symbol;
|
|
4795
|
+
}
|
|
4796
|
+
}
|
|
4797
|
+
|
|
4757
4798
|
declare const __metadata$1: {
|
|
4758
4799
|
PACKAGE_NAME: string;
|
|
4759
4800
|
};
|
|
4760
|
-
declare function checkForSpam(httpClient: HttpClient): (submission: FormSubmission$1) => Promise<CheckForSpamResponse>;
|
|
4761
|
-
declare function createFormSpamSubmissionReport(httpClient: HttpClient): (formSpamSubmissionReport: FormSpamSubmissionReport) => Promise<FormSpamSubmissionReport>;
|
|
4762
|
-
declare function getFormSpamSubmissionReport(httpClient: HttpClient): (formSpamSubmissionReportId: string) => Promise<FormSpamSubmissionReport>;
|
|
4763
|
-
declare function deleteFormSpamSubmissionReport(httpClient: HttpClient): (formSpamSubmissionReportId: string) => Promise<void>;
|
|
4764
|
-
declare function bulkDeleteFormSpamSubmissionReport(httpClient: HttpClient): (formId: string, options?: BulkDeleteFormSpamSubmissionReportOptions) => Promise<BulkDeleteFormSpamSubmissionReportResponse>;
|
|
4765
|
-
declare function bulkDeleteFormSpamSubmissionReportByFilter(httpClient: HttpClient): (filter: Record<string, any> | null) => Promise<BulkDeleteFormSpamSubmissionReportByFilterResponse>;
|
|
4766
|
-
declare function reportNotSpamSubmission(httpClient: HttpClient): (formSpamSubmissionReportId: string) => Promise<ReportNotSpamSubmissionResponse>;
|
|
4767
|
-
declare function bulkReportNotSpamSubmission(httpClient: HttpClient): (formId: string, options?: BulkReportNotSpamSubmissionOptions) => Promise<BulkReportNotSpamSubmissionResponse>;
|
|
4768
|
-
declare function reportSpamSubmission(httpClient: HttpClient): (submissionId: string, reportReason: ReportReason) => Promise<ReportSpamSubmissionResponse>;
|
|
4769
|
-
declare function bulkReportSpamSubmission(httpClient: HttpClient): (formId: string, options?: BulkReportSpamSubmissionOptions) => Promise<BulkReportSpamSubmissionResponse>;
|
|
4770
|
-
declare function queryFormSpamSubmissionReportsByNamespace(httpClient: HttpClient): () => FormSpamSubmissionReportsQueryBuilder;
|
|
4771
|
-
declare function countFormSpamSubmissionReports(httpClient: HttpClient): (formIds: string[], namespace: string) => Promise<CountFormSpamSubmissionReportsResponse>;
|
|
4772
|
-
declare const onFormSpamSubmissionReportCreated: EventDefinition<FormSpamSubmissionReportCreatedEnvelope, "wix.forms.v4.form_spam_submission_report_created">;
|
|
4773
|
-
declare const onFormSpamSubmissionReportDeleted: EventDefinition<FormSpamSubmissionReportDeletedEnvelope, "wix.forms.v4.form_spam_submission_report_deleted">;
|
|
4801
|
+
declare function checkForSpam(httpClient: HttpClient$1): (submission: FormSubmission$1) => Promise<CheckForSpamResponse>;
|
|
4802
|
+
declare function createFormSpamSubmissionReport(httpClient: HttpClient$1): (formSpamSubmissionReport: FormSpamSubmissionReport) => Promise<FormSpamSubmissionReport>;
|
|
4803
|
+
declare function getFormSpamSubmissionReport(httpClient: HttpClient$1): (formSpamSubmissionReportId: string) => Promise<FormSpamSubmissionReport>;
|
|
4804
|
+
declare function deleteFormSpamSubmissionReport(httpClient: HttpClient$1): (formSpamSubmissionReportId: string) => Promise<void>;
|
|
4805
|
+
declare function bulkDeleteFormSpamSubmissionReport(httpClient: HttpClient$1): (formId: string, options?: BulkDeleteFormSpamSubmissionReportOptions) => Promise<BulkDeleteFormSpamSubmissionReportResponse>;
|
|
4806
|
+
declare function bulkDeleteFormSpamSubmissionReportByFilter(httpClient: HttpClient$1): (filter: Record<string, any> | null) => Promise<BulkDeleteFormSpamSubmissionReportByFilterResponse>;
|
|
4807
|
+
declare function reportNotSpamSubmission(httpClient: HttpClient$1): (formSpamSubmissionReportId: string) => Promise<ReportNotSpamSubmissionResponse>;
|
|
4808
|
+
declare function bulkReportNotSpamSubmission(httpClient: HttpClient$1): (formId: string, options?: BulkReportNotSpamSubmissionOptions) => Promise<BulkReportNotSpamSubmissionResponse>;
|
|
4809
|
+
declare function reportSpamSubmission(httpClient: HttpClient$1): (submissionId: string, reportReason: ReportReason) => Promise<ReportSpamSubmissionResponse>;
|
|
4810
|
+
declare function bulkReportSpamSubmission(httpClient: HttpClient$1): (formId: string, options?: BulkReportSpamSubmissionOptions) => Promise<BulkReportSpamSubmissionResponse>;
|
|
4811
|
+
declare function queryFormSpamSubmissionReportsByNamespace(httpClient: HttpClient$1): () => FormSpamSubmissionReportsQueryBuilder;
|
|
4812
|
+
declare function countFormSpamSubmissionReports(httpClient: HttpClient$1): (formIds: string[], namespace: string) => Promise<CountFormSpamSubmissionReportsResponse>;
|
|
4813
|
+
declare const onFormSpamSubmissionReportCreated: EventDefinition$1<FormSpamSubmissionReportCreatedEnvelope, "wix.forms.v4.form_spam_submission_report_created">;
|
|
4814
|
+
declare const onFormSpamSubmissionReportDeleted: EventDefinition$1<FormSpamSubmissionReportDeletedEnvelope, "wix.forms.v4.form_spam_submission_report_deleted">;
|
|
4774
4815
|
|
|
4775
4816
|
type index_d$1_BulkDeleteFormSpamSubmissionReportByFilterRequest = BulkDeleteFormSpamSubmissionReportByFilterRequest;
|
|
4776
4817
|
type index_d$1_BulkDeleteFormSpamSubmissionReportByFilterResponse = BulkDeleteFormSpamSubmissionReportByFilterResponse;
|
|
@@ -5865,6 +5906,46 @@ interface UpsertContactFromSubmissionOptions {
|
|
|
5865
5906
|
emailVerified?: boolean;
|
|
5866
5907
|
}
|
|
5867
5908
|
|
|
5909
|
+
interface HttpClient {
|
|
5910
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
|
|
5911
|
+
fetchWithAuth: typeof fetch;
|
|
5912
|
+
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
5913
|
+
}
|
|
5914
|
+
type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
|
|
5915
|
+
type HttpResponse<T = any> = {
|
|
5916
|
+
data: T;
|
|
5917
|
+
status: number;
|
|
5918
|
+
statusText: string;
|
|
5919
|
+
headers: any;
|
|
5920
|
+
request?: any;
|
|
5921
|
+
};
|
|
5922
|
+
type RequestOptions<_TResponse = any, Data = any> = {
|
|
5923
|
+
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
5924
|
+
url: string;
|
|
5925
|
+
data?: Data;
|
|
5926
|
+
params?: URLSearchParams;
|
|
5927
|
+
} & APIMetadata;
|
|
5928
|
+
type APIMetadata = {
|
|
5929
|
+
methodFqn?: string;
|
|
5930
|
+
entityFqdn?: string;
|
|
5931
|
+
packageName?: string;
|
|
5932
|
+
};
|
|
5933
|
+
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
|
5934
|
+
__type: 'event-definition';
|
|
5935
|
+
type: Type;
|
|
5936
|
+
isDomainEvent?: boolean;
|
|
5937
|
+
transformations?: (envelope: unknown) => Payload;
|
|
5938
|
+
__payload: Payload;
|
|
5939
|
+
};
|
|
5940
|
+
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
|
5941
|
+
|
|
5942
|
+
declare global {
|
|
5943
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
5944
|
+
interface SymbolConstructor {
|
|
5945
|
+
readonly observable: symbol;
|
|
5946
|
+
}
|
|
5947
|
+
}
|
|
5948
|
+
|
|
5868
5949
|
declare const __metadata: {
|
|
5869
5950
|
PACKAGE_NAME: string;
|
|
5870
5951
|
};
|
|
@@ -310,15 +310,9 @@ declare global {
|
|
|
310
310
|
}
|
|
311
311
|
}
|
|
312
312
|
|
|
313
|
-
|
|
314
|
-
request: ValidateSubmissionRequest;
|
|
315
|
-
metadata: Context;
|
|
316
|
-
}
|
|
317
|
-
declare const provideHandlers$1: ServicePluginDefinition<{
|
|
318
|
-
validateSubmission(payload: ValidateSubmissionEnvelope): ValidateSubmissionResponse | Promise<ValidateSubmissionResponse>;
|
|
319
|
-
}>;
|
|
313
|
+
declare function createServicePluginModule<T extends ServicePluginDefinition<any>>(servicePluginDefinition: T): BuildServicePluginDefinition<T> & T;
|
|
320
314
|
|
|
321
|
-
declare const provideHandlers:
|
|
315
|
+
declare const provideHandlers: ReturnType<typeof createServicePluginModule<typeof publicProvideHandlers>>;
|
|
322
316
|
|
|
323
317
|
type context_ActionType = ActionType;
|
|
324
318
|
declare const context_ActionType: typeof ActionType;
|