@dextinity/brevo-admin 2.0.0-canary-20260729062014
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/LICENSE +24 -0
- package/lib/blocks/NewsletterImageBlock.d.ts +8 -0
- package/lib/blocks/NewsletterImageBlock.d.ts.map +1 -0
- package/lib/blocks/NewsletterImageBlock.js +20 -0
- package/lib/blocks.generated.d.ts +206 -0
- package/lib/blocks.generated.d.ts.map +1 -0
- package/lib/blocks.generated.js +1 -0
- package/lib/brevoConfiguration/BrevoConfigForm.d.ts +8 -0
- package/lib/brevoConfiguration/BrevoConfigForm.d.ts.map +1 -0
- package/lib/brevoConfiguration/BrevoConfigForm.generated.d.ts +12 -0
- package/lib/brevoConfiguration/BrevoConfigForm.generated.d.ts.map +1 -0
- package/lib/brevoConfiguration/BrevoConfigForm.generated.js +1 -0
- package/lib/brevoConfiguration/BrevoConfigForm.gql.d.ts +6 -0
- package/lib/brevoConfiguration/BrevoConfigForm.gql.d.ts.map +1 -0
- package/lib/brevoConfiguration/BrevoConfigForm.gql.generated.d.ts +102 -0
- package/lib/brevoConfiguration/BrevoConfigForm.gql.generated.d.ts.map +1 -0
- package/lib/brevoConfiguration/BrevoConfigForm.gql.generated.js +14 -0
- package/lib/brevoConfiguration/BrevoConfigForm.gql.js +9 -0
- package/lib/brevoConfiguration/BrevoConfigForm.js +351 -0
- package/lib/brevoConfiguration/BrevoConfigPage.d.ts +3 -0
- package/lib/brevoConfiguration/BrevoConfigPage.d.ts.map +1 -0
- package/lib/brevoConfiguration/BrevoConfigPage.js +17 -0
- package/lib/brevoContacts/BrevoContactsGrid.d.ts +13 -0
- package/lib/brevoContacts/BrevoContactsGrid.d.ts.map +1 -0
- package/lib/brevoContacts/BrevoContactsGrid.generated.d.ts +65 -0
- package/lib/brevoContacts/BrevoContactsGrid.generated.d.ts.map +1 -0
- package/lib/brevoContacts/BrevoContactsGrid.generated.js +12 -0
- package/lib/brevoContacts/BrevoContactsGrid.js +238 -0
- package/lib/brevoContacts/BrevoContactsPage.d.ts +16 -0
- package/lib/brevoContacts/BrevoContactsPage.d.ts.map +1 -0
- package/lib/brevoContacts/BrevoContactsPage.js +77 -0
- package/lib/brevoContacts/form/BrevoContactForm.d.ts +19 -0
- package/lib/brevoContacts/form/BrevoContactForm.d.ts.map +1 -0
- package/lib/brevoContacts/form/BrevoContactForm.generated.d.ts +10 -0
- package/lib/brevoContacts/form/BrevoContactForm.generated.d.ts.map +1 -0
- package/lib/brevoContacts/form/BrevoContactForm.generated.js +5 -0
- package/lib/brevoContacts/form/BrevoContactForm.gql.d.ts +6 -0
- package/lib/brevoContacts/form/BrevoContactForm.gql.d.ts.map +1 -0
- package/lib/brevoContacts/form/BrevoContactForm.gql.generated.d.ts +58 -0
- package/lib/brevoContacts/form/BrevoContactForm.gql.generated.d.ts.map +1 -0
- package/lib/brevoContacts/form/BrevoContactForm.gql.generated.js +10 -0
- package/lib/brevoContacts/form/BrevoContactForm.gql.js +11 -0
- package/lib/brevoContacts/form/BrevoContactForm.js +346 -0
- package/lib/brevoTestContacts/BrevoTestContactsGrid.d.ts +13 -0
- package/lib/brevoTestContacts/BrevoTestContactsGrid.d.ts.map +1 -0
- package/lib/brevoTestContacts/BrevoTestContactsGrid.generated.d.ts +52 -0
- package/lib/brevoTestContacts/BrevoTestContactsGrid.generated.d.ts.map +1 -0
- package/lib/brevoTestContacts/BrevoTestContactsGrid.generated.js +11 -0
- package/lib/brevoTestContacts/BrevoTestContactsGrid.js +205 -0
- package/lib/brevoTestContacts/BrevoTestContactsPage.d.ts +18 -0
- package/lib/brevoTestContacts/BrevoTestContactsPage.d.ts.map +1 -0
- package/lib/brevoTestContacts/BrevoTestContactsPage.js +78 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.d.ts +19 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.d.ts.map +1 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.generated.d.ts +13 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.generated.d.ts.map +1 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.generated.js +5 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.d.ts +6 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.d.ts.map +1 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.generated.d.ts +64 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.generated.d.ts.map +1 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.generated.js +10 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.js +11 -0
- package/lib/brevoTestContacts/form/BrevoTestContactForm.js +266 -0
- package/lib/common/BrevoConfigProvider.d.ts +21 -0
- package/lib/common/BrevoConfigProvider.d.ts.map +1 -0
- package/lib/common/BrevoConfigProvider.js +33 -0
- package/lib/common/contactImport/useContactImportFromCsv.d.ts +18 -0
- package/lib/common/contactImport/useContactImportFromCsv.d.ts.map +1 -0
- package/lib/common/contactImport/useContactImportFromCsv.gql.d.ts +2 -0
- package/lib/common/contactImport/useContactImportFromCsv.gql.d.ts.map +1 -0
- package/lib/common/contactImport/useContactImportFromCsv.gql.generated.d.ts +26 -0
- package/lib/common/contactImport/useContactImportFromCsv.gql.generated.d.ts.map +1 -0
- package/lib/common/contactImport/useContactImportFromCsv.gql.generated.js +5 -0
- package/lib/common/contactImport/useContactImportFromCsv.gql.js +4 -0
- package/lib/common/contactImport/useContactImportFromCsv.js +462 -0
- package/lib/configVerification/ConfigVerification.d.ts +8 -0
- package/lib/configVerification/ConfigVerification.d.ts.map +1 -0
- package/lib/configVerification/ConfigVerification.gql.d.ts +2 -0
- package/lib/configVerification/ConfigVerification.gql.d.ts.map +1 -0
- package/lib/configVerification/ConfigVerification.gql.generated.d.ts +17 -0
- package/lib/configVerification/ConfigVerification.gql.generated.d.ts.map +1 -0
- package/lib/configVerification/ConfigVerification.gql.generated.js +5 -0
- package/lib/configVerification/ConfigVerification.gql.js +4 -0
- package/lib/configVerification/ConfigVerification.js +41 -0
- package/lib/dataGrid/DataGrid.d.ts +3 -0
- package/lib/dataGrid/DataGrid.d.ts.map +1 -0
- package/lib/dataGrid/DataGrid.js +19 -0
- package/lib/emailCampaigns/EmailCampaignsGrid.d.ts +7 -0
- package/lib/emailCampaigns/EmailCampaignsGrid.d.ts.map +1 -0
- package/lib/emailCampaigns/EmailCampaignsGrid.generated.d.ts +81 -0
- package/lib/emailCampaigns/EmailCampaignsGrid.generated.d.ts.map +1 -0
- package/lib/emailCampaigns/EmailCampaignsGrid.generated.js +12 -0
- package/lib/emailCampaigns/EmailCampaignsGrid.js +281 -0
- package/lib/emailCampaigns/EmailCampaignsPage.d.ts +8 -0
- package/lib/emailCampaigns/EmailCampaignsPage.d.ts.map +1 -0
- package/lib/emailCampaigns/EmailCampaignsPage.js +85 -0
- package/lib/emailCampaigns/SendingStateColumn.d.ts +7 -0
- package/lib/emailCampaigns/SendingStateColumn.d.ts.map +1 -0
- package/lib/emailCampaigns/SendingStateColumn.js +104 -0
- package/lib/emailCampaigns/form/ConfigFields.d.ts +2 -0
- package/lib/emailCampaigns/form/ConfigFields.d.ts.map +1 -0
- package/lib/emailCampaigns/form/ConfigFields.js +26 -0
- package/lib/emailCampaigns/form/EmailCampaignForm.d.ts +9 -0
- package/lib/emailCampaigns/form/EmailCampaignForm.d.ts.map +1 -0
- package/lib/emailCampaigns/form/EmailCampaignForm.gql.d.ts +4 -0
- package/lib/emailCampaigns/form/EmailCampaignForm.gql.d.ts.map +1 -0
- package/lib/emailCampaigns/form/EmailCampaignForm.gql.generated.d.ts +93 -0
- package/lib/emailCampaigns/form/EmailCampaignForm.gql.generated.d.ts.map +1 -0
- package/lib/emailCampaigns/form/EmailCampaignForm.gql.generated.js +12 -0
- package/lib/emailCampaigns/form/EmailCampaignForm.gql.js +7 -0
- package/lib/emailCampaigns/form/EmailCampaignForm.js +418 -0
- package/lib/emailCampaigns/form/SendEmailCampaignNowDialog.d.ts +8 -0
- package/lib/emailCampaigns/form/SendEmailCampaignNowDialog.d.ts.map +1 -0
- package/lib/emailCampaigns/form/SendEmailCampaignNowDialog.js +35 -0
- package/lib/emailCampaigns/form/SendManagerFields.d.ts +10 -0
- package/lib/emailCampaigns/form/SendManagerFields.d.ts.map +1 -0
- package/lib/emailCampaigns/form/SendManagerFields.gql.d.ts +3 -0
- package/lib/emailCampaigns/form/SendManagerFields.gql.d.ts.map +1 -0
- package/lib/emailCampaigns/form/SendManagerFields.gql.generated.d.ts +39 -0
- package/lib/emailCampaigns/form/SendManagerFields.gql.generated.d.ts.map +1 -0
- package/lib/emailCampaigns/form/SendManagerFields.gql.generated.js +11 -0
- package/lib/emailCampaigns/form/SendManagerFields.gql.js +6 -0
- package/lib/emailCampaigns/form/SendManagerFields.js +171 -0
- package/lib/emailCampaigns/form/SendManagerWrapper.d.ts +8 -0
- package/lib/emailCampaigns/form/SendManagerWrapper.d.ts.map +1 -0
- package/lib/emailCampaigns/form/SendManagerWrapper.gql.d.ts +2 -0
- package/lib/emailCampaigns/form/SendManagerWrapper.gql.d.ts.map +1 -0
- package/lib/emailCampaigns/form/SendManagerWrapper.gql.generated.d.ts +14 -0
- package/lib/emailCampaigns/form/SendManagerWrapper.gql.generated.d.ts.map +1 -0
- package/lib/emailCampaigns/form/SendManagerWrapper.gql.generated.js +5 -0
- package/lib/emailCampaigns/form/SendManagerWrapper.gql.js +4 -0
- package/lib/emailCampaigns/form/SendManagerWrapper.js +39 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.d.ts +10 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.d.ts.map +1 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.generated.d.ts +33 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.generated.d.ts.map +1 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.generated.js +8 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.gql.d.ts +2 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.gql.d.ts.map +1 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.gql.generated.d.ts +15 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.gql.generated.d.ts.map +1 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.gql.generated.js +5 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.gql.js +4 -0
- package/lib/emailCampaigns/form/TestEmailCampaignForm.js +146 -0
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.d.ts +7 -0
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.d.ts.map +1 -0
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.gql.d.ts +2 -0
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.gql.d.ts.map +1 -0
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.gql.generated.d.ts +23 -0
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.gql.generated.d.ts.map +1 -0
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.gql.generated.js +5 -0
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.gql.js +4 -0
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.js +133 -0
- package/lib/emailCampaigns/statistics/PercentageCard.d.ts +10 -0
- package/lib/emailCampaigns/statistics/PercentageCard.d.ts.map +1 -0
- package/lib/emailCampaigns/statistics/PercentageCard.js +145 -0
- package/lib/emailCampaigns/view/EmailCampaignView.d.ts +8 -0
- package/lib/emailCampaigns/view/EmailCampaignView.d.ts.map +1 -0
- package/lib/emailCampaigns/view/EmailCampaignView.gql.d.ts +2 -0
- package/lib/emailCampaigns/view/EmailCampaignView.gql.d.ts.map +1 -0
- package/lib/emailCampaigns/view/EmailCampaignView.gql.generated.d.ts +18 -0
- package/lib/emailCampaigns/view/EmailCampaignView.gql.generated.d.ts.map +1 -0
- package/lib/emailCampaigns/view/EmailCampaignView.gql.generated.js +5 -0
- package/lib/emailCampaigns/view/EmailCampaignView.gql.js +4 -0
- package/lib/emailCampaigns/view/EmailCampaignView.js +81 -0
- package/lib/graphql.generated.d.ts +596 -0
- package/lib/graphql.generated.d.ts.map +1 -0
- package/lib/graphql.generated.js +1 -0
- package/lib/index.d.ts +10 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +7 -0
- package/lib/targetGroups/TargetGroupDialog.d.ts +8 -0
- package/lib/targetGroups/TargetGroupDialog.d.ts.map +1 -0
- package/lib/targetGroups/TargetGroupDialog.gql.d.ts +2 -0
- package/lib/targetGroups/TargetGroupDialog.gql.d.ts.map +1 -0
- package/lib/targetGroups/TargetGroupDialog.gql.generated.d.ts +18 -0
- package/lib/targetGroups/TargetGroupDialog.gql.generated.d.ts.map +1 -0
- package/lib/targetGroups/TargetGroupDialog.gql.generated.js +5 -0
- package/lib/targetGroups/TargetGroupDialog.gql.js +4 -0
- package/lib/targetGroups/TargetGroupDialog.js +72 -0
- package/lib/targetGroups/TargetGroupForm.d.ts +20 -0
- package/lib/targetGroups/TargetGroupForm.d.ts.map +1 -0
- package/lib/targetGroups/TargetGroupForm.gql.d.ts +4 -0
- package/lib/targetGroups/TargetGroupForm.gql.d.ts.map +1 -0
- package/lib/targetGroups/TargetGroupForm.gql.generated.d.ts +37 -0
- package/lib/targetGroups/TargetGroupForm.gql.generated.d.ts.map +1 -0
- package/lib/targetGroups/TargetGroupForm.gql.generated.js +8 -0
- package/lib/targetGroups/TargetGroupForm.gql.js +9 -0
- package/lib/targetGroups/TargetGroupForm.js +219 -0
- package/lib/targetGroups/TargetGroupsGrid.d.ts +18 -0
- package/lib/targetGroups/TargetGroupsGrid.d.ts.map +1 -0
- package/lib/targetGroups/TargetGroupsGrid.generated.d.ts +90 -0
- package/lib/targetGroups/TargetGroupsGrid.generated.d.ts.map +1 -0
- package/lib/targetGroups/TargetGroupsGrid.generated.js +14 -0
- package/lib/targetGroups/TargetGroupsGrid.js +280 -0
- package/lib/targetGroups/TargetGroupsPage.d.ts +26 -0
- package/lib/targetGroups/TargetGroupsPage.d.ts.map +1 -0
- package/lib/targetGroups/TargetGroupsPage.js +63 -0
- package/lib/targetGroups/addContacts/AddContactsGridSelect.d.ts +10 -0
- package/lib/targetGroups/addContacts/AddContactsGridSelect.d.ts.map +1 -0
- package/lib/targetGroups/addContacts/AddContactsGridSelect.gql.d.ts +5 -0
- package/lib/targetGroups/addContacts/AddContactsGridSelect.gql.d.ts.map +1 -0
- package/lib/targetGroups/addContacts/AddContactsGridSelect.gql.generated.d.ts +84 -0
- package/lib/targetGroups/addContacts/AddContactsGridSelect.gql.generated.d.ts.map +1 -0
- package/lib/targetGroups/addContacts/AddContactsGridSelect.gql.generated.js +13 -0
- package/lib/targetGroups/addContacts/AddContactsGridSelect.gql.js +8 -0
- package/lib/targetGroups/addContacts/AddContactsGridSelect.js +346 -0
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.d.ts +10 -0
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.d.ts.map +1 -0
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.gql.d.ts +2 -0
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.gql.d.ts.map +1 -0
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.gql.generated.d.ts +42 -0
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.gql.generated.d.ts.map +1 -0
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.gql.generated.js +8 -0
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.gql.js +5 -0
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.js +112 -0
- package/package.json +109 -0
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { type GridColDef } from "@dextinity/admin";
|
|
2
|
+
import type { DocumentNode } from "graphql";
|
|
3
|
+
import type { JSX, ReactNode } from "react";
|
|
4
|
+
import { type EditBrevoContactFormValues } from "./form/BrevoTestContactForm";
|
|
5
|
+
interface CreateContactsPageOptions {
|
|
6
|
+
/** @deprecated Pass via BrevoConfigProvider instead */
|
|
7
|
+
scopeParts?: string[];
|
|
8
|
+
additionalAttributesFragment?: {
|
|
9
|
+
name: string;
|
|
10
|
+
fragment: DocumentNode;
|
|
11
|
+
};
|
|
12
|
+
additionalGridFields?: GridColDef[];
|
|
13
|
+
additionalFormFields?: ReactNode;
|
|
14
|
+
input2State?: (values?: EditBrevoContactFormValues) => EditBrevoContactFormValues;
|
|
15
|
+
}
|
|
16
|
+
declare function createBrevoTestContactsPage({ scopeParts: passedScopeParts, additionalAttributesFragment, additionalFormFields, additionalGridFields, input2State, }: CreateContactsPageOptions): () => JSX.Element;
|
|
17
|
+
export { createBrevoTestContactsPage };
|
|
18
|
+
//# sourceMappingURL=BrevoTestContactsPage.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BrevoTestContactsPage.d.ts","sourceRoot":"","sources":["../../src/brevoTestContacts/BrevoTestContactsPage.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,UAAU,EAA+C,MAAM,kBAAkB,CAAC;AAEhG,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAC5C,OAAO,KAAK,EAAE,GAAG,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAM5C,OAAO,EAAwB,KAAK,0BAA0B,EAAE,MAAM,6BAA6B,CAAC;AAEpG,UAAU,yBAAyB;IAC/B,uDAAuD;IACvD,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,4BAA4B,CAAC,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,YAAY,CAAA;KAAE,CAAC;IACxE,oBAAoB,CAAC,EAAE,UAAU,EAAE,CAAC;IACpC,oBAAoB,CAAC,EAAE,SAAS,CAAC;IACjC,WAAW,CAAC,EAAE,CAAC,MAAM,CAAC,EAAE,0BAA0B,KAAK,0BAA0B,CAAC;CACrF;AAED,iBAAS,2BAA2B,CAAC,EACjC,UAAU,EAAE,gBAAgB,EAC5B,4BAA4B,EAC5B,oBAAoB,EACpB,oBAAoB,EACpB,WAAW,GACd,EAAE,yBAAyB,SACU,GAAG,CAAC,OAAO,CA4DhD;AAED,OAAO,EAAE,2BAA2B,EAAE,CAAC"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { Stack, StackPage, StackSwitch, StackToolbar } from "@dextinity/admin";
|
|
2
|
+
import { ContentScopeIndicator, useContentScope } from "@dextinity/cms-admin";
|
|
3
|
+
import { useIntl } from "react-intl";
|
|
4
|
+
import { useBrevoConfig } from "../common/BrevoConfigProvider";
|
|
5
|
+
import { ConfigVerification } from "../configVerification/ConfigVerification";
|
|
6
|
+
import { BrevoTestContactsGrid } from "./BrevoTestContactsGrid";
|
|
7
|
+
import { BrevoTestContactForm } from "./form/BrevoTestContactForm";
|
|
8
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
9
|
+
function createBrevoTestContactsPage(_ref) {
|
|
10
|
+
var passedScopeParts = _ref.scopeParts,
|
|
11
|
+
additionalAttributesFragment = _ref.additionalAttributesFragment,
|
|
12
|
+
additionalFormFields = _ref.additionalFormFields,
|
|
13
|
+
additionalGridFields = _ref.additionalGridFields,
|
|
14
|
+
input2State = _ref.input2State;
|
|
15
|
+
function BrevoTestContactsPage() {
|
|
16
|
+
var intl = useIntl();
|
|
17
|
+
var brevoConfig = useBrevoConfig();
|
|
18
|
+
var scopeParts = passedScopeParts !== null && passedScopeParts !== void 0 ? passedScopeParts : brevoConfig.scopeParts;
|
|
19
|
+
var _useContentScope = useContentScope(),
|
|
20
|
+
completeScope = _useContentScope.scope;
|
|
21
|
+
var scope = scopeParts.reduce(function (acc, scopePart) {
|
|
22
|
+
acc[scopePart] = completeScope[scopePart];
|
|
23
|
+
return acc;
|
|
24
|
+
}, {});
|
|
25
|
+
return /*#__PURE__*/_jsx(ConfigVerification, {
|
|
26
|
+
scope: scope,
|
|
27
|
+
children: /*#__PURE__*/_jsx(Stack, {
|
|
28
|
+
topLevelTitle: intl.formatMessage({
|
|
29
|
+
id: "cometBrevoModule.brevoContacts.brevoTestContacts",
|
|
30
|
+
defaultMessage: "Test Contacts"
|
|
31
|
+
}),
|
|
32
|
+
children: /*#__PURE__*/_jsxs(StackSwitch, {
|
|
33
|
+
children: [/*#__PURE__*/_jsxs(StackPage, {
|
|
34
|
+
name: "grid",
|
|
35
|
+
children: [/*#__PURE__*/_jsx(StackToolbar, {
|
|
36
|
+
scopeIndicator: /*#__PURE__*/_jsx(ContentScopeIndicator, {
|
|
37
|
+
scope: scope
|
|
38
|
+
})
|
|
39
|
+
}), /*#__PURE__*/_jsx(BrevoTestContactsGrid, {
|
|
40
|
+
scope: scope,
|
|
41
|
+
additionalAttributesFragment: additionalAttributesFragment,
|
|
42
|
+
additionalGridFields: additionalGridFields
|
|
43
|
+
})]
|
|
44
|
+
}), /*#__PURE__*/_jsx(StackPage, {
|
|
45
|
+
name: "edit",
|
|
46
|
+
title: intl.formatMessage({
|
|
47
|
+
id: "cometBrevoModule.brevoContacts.editBrevoContact",
|
|
48
|
+
defaultMessage: "Edit contact"
|
|
49
|
+
}),
|
|
50
|
+
children: function children(selectedId) {
|
|
51
|
+
return /*#__PURE__*/_jsx(BrevoTestContactForm, {
|
|
52
|
+
additionalFormFields: additionalFormFields,
|
|
53
|
+
additionalAttributesFragment: additionalAttributesFragment,
|
|
54
|
+
input2State: input2State,
|
|
55
|
+
id: Number(selectedId),
|
|
56
|
+
scope: scope
|
|
57
|
+
});
|
|
58
|
+
}
|
|
59
|
+
}), /*#__PURE__*/_jsx(StackPage, {
|
|
60
|
+
name: "add",
|
|
61
|
+
title: intl.formatMessage({
|
|
62
|
+
id: "cometBrevoModule.brevoContacts.addBrevoContact",
|
|
63
|
+
defaultMessage: "Add contact"
|
|
64
|
+
}),
|
|
65
|
+
children: /*#__PURE__*/_jsx(BrevoTestContactForm, {
|
|
66
|
+
additionalFormFields: additionalFormFields,
|
|
67
|
+
additionalAttributesFragment: additionalAttributesFragment,
|
|
68
|
+
input2State: input2State,
|
|
69
|
+
scope: scope
|
|
70
|
+
})
|
|
71
|
+
})]
|
|
72
|
+
})
|
|
73
|
+
})
|
|
74
|
+
});
|
|
75
|
+
}
|
|
76
|
+
return BrevoTestContactsPage;
|
|
77
|
+
}
|
|
78
|
+
export { createBrevoTestContactsPage };
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import { type DocumentNode } from "@apollo/client";
|
|
2
|
+
import { type ContentScope } from "@dextinity/cms-admin";
|
|
3
|
+
import { type ReactElement, type ReactNode } from "react";
|
|
4
|
+
export type EditBrevoContactFormValues = {
|
|
5
|
+
[key: string]: unknown;
|
|
6
|
+
};
|
|
7
|
+
interface FormProps {
|
|
8
|
+
id?: number;
|
|
9
|
+
scope: ContentScope;
|
|
10
|
+
additionalFormFields?: ReactNode;
|
|
11
|
+
additionalAttributesFragment?: {
|
|
12
|
+
name: string;
|
|
13
|
+
fragment: DocumentNode;
|
|
14
|
+
};
|
|
15
|
+
input2State?: (values?: EditBrevoContactFormValues) => EditBrevoContactFormValues;
|
|
16
|
+
}
|
|
17
|
+
export declare function BrevoTestContactForm({ id, scope, input2State, additionalFormFields, additionalAttributesFragment }: FormProps): ReactElement;
|
|
18
|
+
export {};
|
|
19
|
+
//# sourceMappingURL=BrevoTestContactForm.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BrevoTestContactForm.d.ts","sourceRoot":"","sources":["../../../src/brevoTestContacts/form/BrevoTestContactForm.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,YAAY,EAAkC,MAAM,gBAAgB,CAAC;AAmBnF,OAAO,EAAE,KAAK,YAAY,EAA+C,MAAM,sBAAsB,CAAC;AAItG,OAAO,EAAE,KAAK,YAAY,EAAE,KAAK,SAAS,EAAW,MAAM,OAAO,CAAC;AAoBnE,MAAM,MAAM,0BAA0B,GAAG;IACrC,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;CAC1B,CAAC;AAMF,UAAU,SAAS;IACf,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,YAAY,CAAC;IACpB,oBAAoB,CAAC,EAAE,SAAS,CAAC;IACjC,4BAA4B,CAAC,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,QAAQ,EAAE,YAAY,CAAA;KAAE,CAAC;IACxE,WAAW,CAAC,EAAE,CAAC,MAAM,CAAC,EAAE,0BAA0B,KAAK,0BAA0B,CAAC;CACrF;AAED,wBAAgB,oBAAoB,CAAC,EAAE,EAAE,EAAE,KAAK,EAAE,WAAW,EAAE,oBAAoB,EAAE,4BAA4B,EAAE,EAAE,SAAS,GAAG,YAAY,CA8J5I"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export declare const namedOperations: {
|
|
2
|
+
Fragment: {
|
|
3
|
+
BrevoTestContactForm: string;
|
|
4
|
+
};
|
|
5
|
+
};
|
|
6
|
+
export type GQLBrevoTestContactFormFragment = {
|
|
7
|
+
__typename?: 'BrevoContact';
|
|
8
|
+
email: string;
|
|
9
|
+
createdAt: string;
|
|
10
|
+
emailBlacklisted: boolean;
|
|
11
|
+
smsBlacklisted: boolean;
|
|
12
|
+
};
|
|
13
|
+
//# sourceMappingURL=BrevoTestContactForm.generated.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BrevoTestContactForm.generated.d.ts","sourceRoot":"","sources":["../../../src/brevoTestContacts/form/BrevoTestContactForm.generated.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,eAAe;;;;CAI3B,CAAA;AACD,MAAM,MAAM,+BAA+B,GAAG;IAAE,UAAU,CAAC,EAAE,cAAc,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAC;IAAC,gBAAgB,EAAE,OAAO,CAAC;IAAC,cAAc,EAAE,OAAO,CAAA;CAAE,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { type DocumentNode } from "@apollo/client";
|
|
2
|
+
export declare const brevoContactFormQuery: (brevoTestContactFormFragment: DocumentNode) => DocumentNode;
|
|
3
|
+
export declare const brevoContactFormCheckForChangesQuery: DocumentNode;
|
|
4
|
+
export declare const createBrevoTestContactMutation: DocumentNode;
|
|
5
|
+
export declare const updateBrevoContactMutation: (brevoTestContactFormFragment: DocumentNode) => DocumentNode;
|
|
6
|
+
//# sourceMappingURL=BrevoTestContactForm.gql.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BrevoTestContactForm.gql.d.ts","sourceRoot":"","sources":["../../../src/brevoTestContacts/form/BrevoTestContactForm.gql.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,YAAY,EAAO,MAAM,gBAAgB,CAAC;AAExD,eAAO,MAAM,qBAAqB,GAAI,8BAA8B,YAAY,iBAS/E,CAAC;AAEF,eAAO,MAAM,oCAAoC,cAMhD,CAAC;AAEF,eAAO,MAAM,8BAA8B,cAI1C,CAAC;AAEF,eAAO,MAAM,0BAA0B,GAAI,8BAA8B,YAAY,iBASpF,CAAC"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import * as Types from '../../graphql.generated';
|
|
2
|
+
export declare const namedOperations: {
|
|
3
|
+
Query: {
|
|
4
|
+
BrevoContactForm: string;
|
|
5
|
+
BrevoContactFormCheckForChanges: string;
|
|
6
|
+
};
|
|
7
|
+
Mutation: {
|
|
8
|
+
CreateBrevoTestContact: string;
|
|
9
|
+
UpdateBrevoContact: string;
|
|
10
|
+
};
|
|
11
|
+
};
|
|
12
|
+
export type GQLBrevoContactFormQueryVariables = Types.Exact<{
|
|
13
|
+
id: Types.Scalars['Int']['input'];
|
|
14
|
+
scope: Types.GQLEmailCampaignContentScopeInput;
|
|
15
|
+
}>;
|
|
16
|
+
export type GQLBrevoContactFormQuery = {
|
|
17
|
+
__typename?: 'Query';
|
|
18
|
+
brevoContact: {
|
|
19
|
+
__typename?: 'BrevoContact';
|
|
20
|
+
id: number;
|
|
21
|
+
modifiedAt: string;
|
|
22
|
+
email: string;
|
|
23
|
+
createdAt: string;
|
|
24
|
+
emailBlacklisted: boolean;
|
|
25
|
+
smsBlacklisted: boolean;
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
export type GQLBrevoContactFormCheckForChangesQueryVariables = Types.Exact<{
|
|
29
|
+
id: Types.Scalars['Int']['input'];
|
|
30
|
+
scope: Types.GQLEmailCampaignContentScopeInput;
|
|
31
|
+
}>;
|
|
32
|
+
export type GQLBrevoContactFormCheckForChangesQuery = {
|
|
33
|
+
__typename?: 'Query';
|
|
34
|
+
brevoContact: {
|
|
35
|
+
__typename?: 'BrevoContact';
|
|
36
|
+
modifiedAt: string;
|
|
37
|
+
};
|
|
38
|
+
};
|
|
39
|
+
export type GQLCreateBrevoTestContactMutationVariables = Types.Exact<{
|
|
40
|
+
scope: Types.GQLEmailCampaignContentScopeInput;
|
|
41
|
+
input: Types.GQLBrevoTestContactInput;
|
|
42
|
+
}>;
|
|
43
|
+
export type GQLCreateBrevoTestContactMutation = {
|
|
44
|
+
__typename?: 'Mutation';
|
|
45
|
+
createBrevoTestContact: Types.GQLSubscribeResponse;
|
|
46
|
+
};
|
|
47
|
+
export type GQLUpdateBrevoContactMutationVariables = Types.Exact<{
|
|
48
|
+
id: Types.Scalars['Int']['input'];
|
|
49
|
+
input: Types.GQLBrevoContactUpdateInput;
|
|
50
|
+
scope: Types.GQLEmailCampaignContentScopeInput;
|
|
51
|
+
}>;
|
|
52
|
+
export type GQLUpdateBrevoContactMutation = {
|
|
53
|
+
__typename?: 'Mutation';
|
|
54
|
+
updateBrevoContact: {
|
|
55
|
+
__typename?: 'BrevoContact';
|
|
56
|
+
id: number;
|
|
57
|
+
modifiedAt: string;
|
|
58
|
+
email: string;
|
|
59
|
+
createdAt: string;
|
|
60
|
+
emailBlacklisted: boolean;
|
|
61
|
+
smsBlacklisted: boolean;
|
|
62
|
+
};
|
|
63
|
+
};
|
|
64
|
+
//# sourceMappingURL=BrevoTestContactForm.gql.generated.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BrevoTestContactForm.gql.generated.d.ts","sourceRoot":"","sources":["../../../src/brevoTestContacts/form/BrevoTestContactForm.gql.generated.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,yBAAyB,CAAC;AAEjD,eAAO,MAAM,eAAe;;;;;;;;;CAS3B,CAAA;AACD,MAAM,MAAM,iCAAiC,GAAG,KAAK,CAAC,KAAK,CAAC;IAC1D,EAAE,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC,CAAC;IAClC,KAAK,EAAE,KAAK,CAAC,iCAAiC,CAAC;CAChD,CAAC,CAAC;AAGH,MAAM,MAAM,wBAAwB,GAAG;IAAE,UAAU,CAAC,EAAE,OAAO,CAAC;IAAC,YAAY,EAAE;QAAE,UAAU,CAAC,EAAE,cAAc,CAAC;QAAC,EAAE,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAC;QAAC,gBAAgB,EAAE,OAAO,CAAC;QAAC,cAAc,EAAE,OAAO,CAAA;KAAE,CAAA;CAAE,CAAC;AAErO,MAAM,MAAM,gDAAgD,GAAG,KAAK,CAAC,KAAK,CAAC;IACzE,EAAE,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC,CAAC;IAClC,KAAK,EAAE,KAAK,CAAC,iCAAiC,CAAC;CAChD,CAAC,CAAC;AAGH,MAAM,MAAM,uCAAuC,GAAG;IAAE,UAAU,CAAC,EAAE,OAAO,CAAC;IAAC,YAAY,EAAE;QAAE,UAAU,CAAC,EAAE,cAAc,CAAC;QAAC,UAAU,EAAE,MAAM,CAAA;KAAE,CAAA;CAAE,CAAC;AAElJ,MAAM,MAAM,0CAA0C,GAAG,KAAK,CAAC,KAAK,CAAC;IACnE,KAAK,EAAE,KAAK,CAAC,iCAAiC,CAAC;IAC/C,KAAK,EAAE,KAAK,CAAC,wBAAwB,CAAC;CACvC,CAAC,CAAC;AAGH,MAAM,MAAM,iCAAiC,GAAG;IAAE,UAAU,CAAC,EAAE,UAAU,CAAC;IAAC,sBAAsB,EAAE,KAAK,CAAC,oBAAoB,CAAA;CAAE,CAAC;AAEhI,MAAM,MAAM,sCAAsC,GAAG,KAAK,CAAC,KAAK,CAAC;IAC/D,EAAE,EAAE,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC,CAAC;IAClC,KAAK,EAAE,KAAK,CAAC,0BAA0B,CAAC;IACxC,KAAK,EAAE,KAAK,CAAC,iCAAiC,CAAC;CAChD,CAAC,CAAC;AAGH,MAAM,MAAM,6BAA6B,GAAG;IAAE,UAAU,CAAC,EAAE,UAAU,CAAC;IAAC,kBAAkB,EAAE;QAAE,UAAU,CAAC,EAAE,cAAc,CAAC;QAAC,EAAE,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,SAAS,EAAE,MAAM,CAAC;QAAC,gBAAgB,EAAE,OAAO,CAAC;QAAC,cAAc,EAAE,OAAO,CAAA;KAAE,CAAA;CAAE,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export var namedOperations = {
|
|
2
|
+
Query: {
|
|
3
|
+
BrevoContactForm: 'BrevoContactForm',
|
|
4
|
+
BrevoContactFormCheckForChanges: 'BrevoContactFormCheckForChanges'
|
|
5
|
+
},
|
|
6
|
+
Mutation: {
|
|
7
|
+
CreateBrevoTestContact: 'CreateBrevoTestContact',
|
|
8
|
+
UpdateBrevoContact: 'UpdateBrevoContact'
|
|
9
|
+
}
|
|
10
|
+
};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
|
2
|
+
function _taggedTemplateLiteral(e, t) { return t || (t = e.slice(0)), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } })); }
|
|
3
|
+
import { gql } from "@apollo/client";
|
|
4
|
+
export var brevoContactFormQuery = function brevoContactFormQuery(brevoTestContactFormFragment) {
|
|
5
|
+
return gql(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n query BrevoContactForm($id: Int!, $scope: EmailCampaignContentScopeInput!) {\n brevoContact(id: $id, scope: $scope) {\n id\n modifiedAt\n ...BrevoTestContactForm\n }\n }\n ", "\n"])), brevoTestContactFormFragment);
|
|
6
|
+
};
|
|
7
|
+
export var brevoContactFormCheckForChangesQuery = gql(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n query BrevoContactFormCheckForChanges($id: Int!, $scope: EmailCampaignContentScopeInput!) {\n brevoContact(id: $id, scope: $scope) {\n modifiedAt\n }\n }\n"])));
|
|
8
|
+
export var createBrevoTestContactMutation = gql(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n mutation CreateBrevoTestContact($scope: EmailCampaignContentScopeInput!, $input: BrevoTestContactInput!) {\n createBrevoTestContact(scope: $scope, input: $input)\n }\n"])));
|
|
9
|
+
export var updateBrevoContactMutation = function updateBrevoContactMutation(brevoTestContactFormFragment) {
|
|
10
|
+
return gql(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n mutation UpdateBrevoContact($id: Int!, $input: BrevoContactUpdateInput!, $scope: EmailCampaignContentScopeInput!) {\n updateBrevoContact(id: $id, input: $input, scope: $scope) {\n id\n modifiedAt\n ...BrevoTestContactForm\n }\n }\n ", "\n"])), brevoTestContactFormFragment);
|
|
11
|
+
};
|
|
@@ -0,0 +1,266 @@
|
|
|
1
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
var _excluded = ["email"];
|
|
3
|
+
var _templateObject;
|
|
4
|
+
function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var n = Object.getOwnPropertySymbols(e); for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } return i; }
|
|
5
|
+
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }
|
|
6
|
+
function _regenerator() { /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/babel/babel/blob/main/packages/babel-helpers/LICENSE */ var e, t, r = "function" == typeof Symbol ? Symbol : {}, n = r.iterator || "@@iterator", o = r.toStringTag || "@@toStringTag"; function i(r, n, o, i) { var c = n && n.prototype instanceof Generator ? n : Generator, u = Object.create(c.prototype); return _regeneratorDefine2(u, "_invoke", function (r, n, o) { var i, c, u, f = 0, p = o || [], y = !1, G = { p: 0, n: 0, v: e, a: d, f: d.bind(e, 4), d: function d(t, r) { return i = t, c = 0, u = e, G.n = r, a; } }; function d(r, n) { for (c = r, u = n, t = 0; !y && f && !o && t < p.length; t++) { var o, i = p[t], d = G.p, l = i[2]; r > 3 ? (o = l === n) && (u = i[(c = i[4]) ? 5 : (c = 3, 3)], i[4] = i[5] = e) : i[0] <= d && ((o = r < 2 && d < i[1]) ? (c = 0, G.v = n, G.n = i[1]) : d < l && (o = r < 3 || i[0] > n || n > l) && (i[4] = r, i[5] = n, G.n = l, c = 0)); } if (o || r > 1) return a; throw y = !0, n; } return function (o, p, l) { if (f > 1) throw TypeError("Generator is already running"); for (y && 1 === p && d(p, l), c = p, u = l; (t = c < 2 ? e : u) || !y;) { i || (c ? c < 3 ? (c > 1 && (G.n = -1), d(c, u)) : G.n = u : G.v = u); try { if (f = 2, i) { if (c || (o = "next"), t = i[o]) { if (!(t = t.call(i, u))) throw TypeError("iterator result is not an object"); if (!t.done) return t; u = t.value, c < 2 && (c = 0); } else 1 === c && (t = i["return"]) && t.call(i), c < 2 && (u = TypeError("The iterator does not provide a '" + o + "' method"), c = 1); i = e; } else if ((t = (y = G.n < 0) ? u : r.call(n, G)) !== a) break; } catch (t) { i = e, c = 1, u = t; } finally { f = 1; } } return { value: t, done: y }; }; }(r, o, i), !0), u; } var a = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} t = Object.getPrototypeOf; var c = [][n] ? t(t([][n]())) : (_regeneratorDefine2(t = {}, n, function () { return this; }), t), u = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(c); function f(e) { return Object.setPrototypeOf ? Object.setPrototypeOf(e, GeneratorFunctionPrototype) : (e.__proto__ = GeneratorFunctionPrototype, _regeneratorDefine2(e, o, "GeneratorFunction")), e.prototype = Object.create(u), e; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, _regeneratorDefine2(u, "constructor", GeneratorFunctionPrototype), _regeneratorDefine2(GeneratorFunctionPrototype, "constructor", GeneratorFunction), GeneratorFunction.displayName = "GeneratorFunction", _regeneratorDefine2(GeneratorFunctionPrototype, o, "GeneratorFunction"), _regeneratorDefine2(u), _regeneratorDefine2(u, o, "Generator"), _regeneratorDefine2(u, n, function () { return this; }), _regeneratorDefine2(u, "toString", function () { return "[object Generator]"; }), (_regenerator = function _regenerator() { return { w: i, m: f }; })(); }
|
|
7
|
+
function _regeneratorDefine2(e, r, n, t) { var i = Object.defineProperty; try { i({}, "", {}); } catch (e) { i = 0; } _regeneratorDefine2 = function _regeneratorDefine(e, r, n, t) { function o(r, n) { _regeneratorDefine2(e, r, function (e) { return this._invoke(r, n, e); }); } r ? i ? i(e, r, { value: n, enumerable: !t, configurable: !t, writable: !t }) : e[r] = n : (o("next", 0), o("throw", 1), o("return", 2)); }, _regeneratorDefine2(e, r, n, t); }
|
|
8
|
+
function asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }
|
|
9
|
+
function _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, "next", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, "throw", n); } _next(void 0); }); }; }
|
|
10
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
11
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
12
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
13
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
14
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
15
|
+
function _taggedTemplateLiteral(e, t) { return t || (t = e.slice(0)), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } })); }
|
|
16
|
+
import { gql, useApolloClient, useQuery } from "@apollo/client";
|
|
17
|
+
import { Alert, FillSpace, FinalForm, FinalFormSaveButton, FormSection, Loading, MainContent, TextField, Toolbar, ToolbarActions, ToolbarItem, ToolbarTitleItem, useFormApiRef, useStackApi } from "@dextinity/admin";
|
|
18
|
+
import { ArrowLeft } from "@dextinity/admin-icons";
|
|
19
|
+
import { resolveHasSaveConflict, useFormSaveConflict } from "@dextinity/cms-admin";
|
|
20
|
+
import { Card, IconButton } from "@mui/material";
|
|
21
|
+
import { Box } from "@mui/system";
|
|
22
|
+
import { useMemo } from "react";
|
|
23
|
+
import { FormattedMessage } from "react-intl";
|
|
24
|
+
import { brevoContactFormCheckForChangesQuery, brevoContactFormQuery, createBrevoTestContactMutation, updateBrevoContactMutation } from "./BrevoTestContactForm.gql";
|
|
25
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
26
|
+
export function BrevoTestContactForm(_ref) {
|
|
27
|
+
var _additionalAttributes;
|
|
28
|
+
var id = _ref.id,
|
|
29
|
+
scope = _ref.scope,
|
|
30
|
+
input2State = _ref.input2State,
|
|
31
|
+
additionalFormFields = _ref.additionalFormFields,
|
|
32
|
+
additionalAttributesFragment = _ref.additionalAttributesFragment;
|
|
33
|
+
var stackApi = useStackApi();
|
|
34
|
+
var client = useApolloClient();
|
|
35
|
+
var mode = id ? "edit" : "add";
|
|
36
|
+
var formApiRef = useFormApiRef();
|
|
37
|
+
var brevoTestContactFormFragment = gql(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n fragment BrevoTestContactForm on BrevoContact {\n email\n createdAt\n emailBlacklisted\n smsBlacklisted\n ", "\n }\n ", "\n"])), additionalAttributesFragment ? "...".concat(additionalAttributesFragment === null || additionalAttributesFragment === void 0 ? void 0 : additionalAttributesFragment.name) : "", (_additionalAttributes = additionalAttributesFragment === null || additionalAttributesFragment === void 0 ? void 0 : additionalAttributesFragment.fragment) !== null && _additionalAttributes !== void 0 ? _additionalAttributes : "");
|
|
38
|
+
var _useQuery = useQuery(brevoContactFormQuery(brevoTestContactFormFragment), id ? {
|
|
39
|
+
variables: {
|
|
40
|
+
id: id,
|
|
41
|
+
scope: scope
|
|
42
|
+
}
|
|
43
|
+
} : {
|
|
44
|
+
skip: true
|
|
45
|
+
}),
|
|
46
|
+
data = _useQuery.data,
|
|
47
|
+
error = _useQuery.error,
|
|
48
|
+
loading = _useQuery.loading,
|
|
49
|
+
refetch = _useQuery.refetch;
|
|
50
|
+
var initialValues = useMemo(function () {
|
|
51
|
+
var _data$brevoContact;
|
|
52
|
+
var baseInitialValues = {
|
|
53
|
+
email: ""
|
|
54
|
+
};
|
|
55
|
+
if (input2State) {
|
|
56
|
+
baseInitialValues = _objectSpread(_objectSpread({}, baseInitialValues), input2State(data === null || data === void 0 ? void 0 : data.brevoContact));
|
|
57
|
+
}
|
|
58
|
+
return data !== null && data !== void 0 && (_data$brevoContact = data.brevoContact) !== null && _data$brevoContact !== void 0 && _data$brevoContact.email ? _objectSpread(_objectSpread({}, baseInitialValues), {}, {
|
|
59
|
+
email: data.brevoContact.email
|
|
60
|
+
}) : baseInitialValues;
|
|
61
|
+
}, [data === null || data === void 0 ? void 0 : data.brevoContact, input2State]);
|
|
62
|
+
var saveConflict = useFormSaveConflict({
|
|
63
|
+
checkConflict: function () {
|
|
64
|
+
var _checkConflict = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee() {
|
|
65
|
+
var _data$brevoContact2;
|
|
66
|
+
var _yield$client$query, updatedData;
|
|
67
|
+
return _regenerator().w(function (_context) {
|
|
68
|
+
while (1) switch (_context.n) {
|
|
69
|
+
case 0:
|
|
70
|
+
if (id) {
|
|
71
|
+
_context.n = 1;
|
|
72
|
+
break;
|
|
73
|
+
}
|
|
74
|
+
return _context.a(2, false);
|
|
75
|
+
case 1:
|
|
76
|
+
_context.n = 2;
|
|
77
|
+
return client.query({
|
|
78
|
+
query: brevoContactFormCheckForChangesQuery,
|
|
79
|
+
variables: {
|
|
80
|
+
id: id,
|
|
81
|
+
scope: scope
|
|
82
|
+
},
|
|
83
|
+
fetchPolicy: "no-cache"
|
|
84
|
+
});
|
|
85
|
+
case 2:
|
|
86
|
+
_yield$client$query = _context.v;
|
|
87
|
+
updatedData = _yield$client$query.data;
|
|
88
|
+
return _context.a(2, resolveHasSaveConflict(data === null || data === void 0 || (_data$brevoContact2 = data.brevoContact) === null || _data$brevoContact2 === void 0 ? void 0 : _data$brevoContact2.modifiedAt, updatedData.brevoContact.modifiedAt));
|
|
89
|
+
}
|
|
90
|
+
}, _callee);
|
|
91
|
+
}));
|
|
92
|
+
function checkConflict() {
|
|
93
|
+
return _checkConflict.apply(this, arguments);
|
|
94
|
+
}
|
|
95
|
+
return checkConflict;
|
|
96
|
+
}(),
|
|
97
|
+
formApiRef: formApiRef,
|
|
98
|
+
loadLatestVersion: function () {
|
|
99
|
+
var _loadLatestVersion = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee2() {
|
|
100
|
+
return _regenerator().w(function (_context2) {
|
|
101
|
+
while (1) switch (_context2.n) {
|
|
102
|
+
case 0:
|
|
103
|
+
_context2.n = 1;
|
|
104
|
+
return refetch();
|
|
105
|
+
case 1:
|
|
106
|
+
return _context2.a(2);
|
|
107
|
+
}
|
|
108
|
+
}, _callee2);
|
|
109
|
+
}));
|
|
110
|
+
function loadLatestVersion() {
|
|
111
|
+
return _loadLatestVersion.apply(this, arguments);
|
|
112
|
+
}
|
|
113
|
+
return loadLatestVersion;
|
|
114
|
+
}()
|
|
115
|
+
});
|
|
116
|
+
var handleSubmit = /*#__PURE__*/function () {
|
|
117
|
+
var _ref2 = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee3(state, form, event) {
|
|
118
|
+
var output, email, rest, _yield$client$mutate, mutationResponse, response;
|
|
119
|
+
return _regenerator().w(function (_context3) {
|
|
120
|
+
while (1) switch (_context3.n) {
|
|
121
|
+
case 0:
|
|
122
|
+
_context3.n = 1;
|
|
123
|
+
return saveConflict.checkForConflicts();
|
|
124
|
+
case 1:
|
|
125
|
+
if (!_context3.v) {
|
|
126
|
+
_context3.n = 2;
|
|
127
|
+
break;
|
|
128
|
+
}
|
|
129
|
+
throw new Error("Conflicts detected");
|
|
130
|
+
case 2:
|
|
131
|
+
output = _objectSpread(_objectSpread({}, state), {}, {
|
|
132
|
+
blocked: false
|
|
133
|
+
});
|
|
134
|
+
if (!(mode === "edit")) {
|
|
135
|
+
_context3.n = 5;
|
|
136
|
+
break;
|
|
137
|
+
}
|
|
138
|
+
if (id) {
|
|
139
|
+
_context3.n = 3;
|
|
140
|
+
break;
|
|
141
|
+
}
|
|
142
|
+
throw new Error("Missing id in edit mode");
|
|
143
|
+
case 3:
|
|
144
|
+
email = output.email, rest = _objectWithoutProperties(output, _excluded);
|
|
145
|
+
_context3.n = 4;
|
|
146
|
+
return client.mutate({
|
|
147
|
+
mutation: updateBrevoContactMutation(brevoTestContactFormFragment),
|
|
148
|
+
variables: {
|
|
149
|
+
id: id,
|
|
150
|
+
input: rest,
|
|
151
|
+
scope: scope
|
|
152
|
+
}
|
|
153
|
+
});
|
|
154
|
+
case 4:
|
|
155
|
+
_context3.n = 9;
|
|
156
|
+
break;
|
|
157
|
+
case 5:
|
|
158
|
+
_context3.n = 6;
|
|
159
|
+
return client.mutate({
|
|
160
|
+
mutation: createBrevoTestContactMutation,
|
|
161
|
+
variables: {
|
|
162
|
+
scope: scope,
|
|
163
|
+
input: output
|
|
164
|
+
}
|
|
165
|
+
});
|
|
166
|
+
case 6:
|
|
167
|
+
_yield$client$mutate = _context3.v;
|
|
168
|
+
mutationResponse = _yield$client$mutate.data;
|
|
169
|
+
if (event.navigatingBack) {
|
|
170
|
+
_context3.n = 9;
|
|
171
|
+
break;
|
|
172
|
+
}
|
|
173
|
+
response = mutationResponse === null || mutationResponse === void 0 ? void 0 : mutationResponse.createBrevoTestContact;
|
|
174
|
+
if (!(response === "SUCCESSFUL")) {
|
|
175
|
+
_context3.n = 7;
|
|
176
|
+
break;
|
|
177
|
+
}
|
|
178
|
+
setTimeout(function () {
|
|
179
|
+
stackApi === null || stackApi === void 0 || stackApi.goBack();
|
|
180
|
+
});
|
|
181
|
+
_context3.n = 9;
|
|
182
|
+
break;
|
|
183
|
+
case 7:
|
|
184
|
+
if (!(response === "ERROR_CONTAINED_IN_ECG_RTR_LIST")) {
|
|
185
|
+
_context3.n = 8;
|
|
186
|
+
break;
|
|
187
|
+
}
|
|
188
|
+
throw new Error("Contact contained in ECG RTR list, cannot create contact");
|
|
189
|
+
case 8:
|
|
190
|
+
throw new Error("Error creating contact");
|
|
191
|
+
case 9:
|
|
192
|
+
return _context3.a(2);
|
|
193
|
+
}
|
|
194
|
+
}, _callee3);
|
|
195
|
+
}));
|
|
196
|
+
return function handleSubmit(_x, _x2, _x3) {
|
|
197
|
+
return _ref2.apply(this, arguments);
|
|
198
|
+
};
|
|
199
|
+
}();
|
|
200
|
+
if (error) {
|
|
201
|
+
throw error;
|
|
202
|
+
}
|
|
203
|
+
if (loading) {
|
|
204
|
+
return /*#__PURE__*/_jsx(Loading, {
|
|
205
|
+
behavior: "fillPageHeight"
|
|
206
|
+
});
|
|
207
|
+
}
|
|
208
|
+
return /*#__PURE__*/_jsx(FinalForm, {
|
|
209
|
+
apiRef: formApiRef,
|
|
210
|
+
onSubmit: handleSubmit,
|
|
211
|
+
mode: mode,
|
|
212
|
+
initialValues: initialValues,
|
|
213
|
+
children: /*#__PURE__*/_jsxs(_Fragment, {
|
|
214
|
+
children: [saveConflict.dialogs, /*#__PURE__*/_jsxs(Toolbar, {
|
|
215
|
+
children: [/*#__PURE__*/_jsx(ToolbarItem, {
|
|
216
|
+
children: /*#__PURE__*/_jsx(IconButton, {
|
|
217
|
+
onClick: stackApi === null || stackApi === void 0 ? void 0 : stackApi.goBack,
|
|
218
|
+
children: /*#__PURE__*/_jsx(ArrowLeft, {})
|
|
219
|
+
})
|
|
220
|
+
}), /*#__PURE__*/_jsx(ToolbarTitleItem, {
|
|
221
|
+
children: /*#__PURE__*/_jsx(FormattedMessage, {
|
|
222
|
+
id: "cometBrevoModule.brevoTestContacts.brevoTestContact",
|
|
223
|
+
defaultMessage: "Test contact"
|
|
224
|
+
})
|
|
225
|
+
}), /*#__PURE__*/_jsx(FillSpace, {}), /*#__PURE__*/_jsx(ToolbarActions, {
|
|
226
|
+
children: /*#__PURE__*/_jsx(FinalFormSaveButton, {
|
|
227
|
+
hasConflict: saveConflict.hasConflict
|
|
228
|
+
})
|
|
229
|
+
})]
|
|
230
|
+
}), /*#__PURE__*/_jsxs(MainContent, {
|
|
231
|
+
children: [mode === "edit" && /*#__PURE__*/_jsx(Box, {
|
|
232
|
+
sx: {
|
|
233
|
+
marginBottom: 4
|
|
234
|
+
},
|
|
235
|
+
children: /*#__PURE__*/_jsx(Alert, {
|
|
236
|
+
severity: "warning",
|
|
237
|
+
children: /*#__PURE__*/_jsx(FormattedMessage, {
|
|
238
|
+
id: "cometBrevoModule.brevoContact.contactEditAlert",
|
|
239
|
+
defaultMessage: "Editing a contact will affect all scopes and the target groups within those scopes."
|
|
240
|
+
})
|
|
241
|
+
})
|
|
242
|
+
}), /*#__PURE__*/_jsx(TextField, {
|
|
243
|
+
required: true,
|
|
244
|
+
fullWidth: true,
|
|
245
|
+
name: "email",
|
|
246
|
+
label: /*#__PURE__*/_jsx(FormattedMessage, {
|
|
247
|
+
id: "cometBrevoModule.brevoTestContact.email",
|
|
248
|
+
defaultMessage: "Email"
|
|
249
|
+
}),
|
|
250
|
+
disabled: mode === "edit"
|
|
251
|
+
}), additionalFormFields && /*#__PURE__*/_jsx(Card, {
|
|
252
|
+
sx: {
|
|
253
|
+
padding: 4
|
|
254
|
+
},
|
|
255
|
+
children: /*#__PURE__*/_jsx(FormSection, {
|
|
256
|
+
title: /*#__PURE__*/_jsx(FormattedMessage, {
|
|
257
|
+
id: "cometBrevoModule.brevoTestContact.attributes",
|
|
258
|
+
defaultMessage: "Attributes"
|
|
259
|
+
}),
|
|
260
|
+
children: additionalFormFields
|
|
261
|
+
})
|
|
262
|
+
})]
|
|
263
|
+
})]
|
|
264
|
+
})
|
|
265
|
+
});
|
|
266
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { type ContentScope } from "@dextinity/cms-admin";
|
|
2
|
+
import { type PropsWithChildren } from "react";
|
|
3
|
+
export interface BrevoConfig {
|
|
4
|
+
apiUrl: string;
|
|
5
|
+
scopeParts: string[];
|
|
6
|
+
resolvePreviewUrlForScope: (scope: ContentScope) => string;
|
|
7
|
+
allowAddingContactsWithoutDoi?: boolean;
|
|
8
|
+
}
|
|
9
|
+
interface BrevoConfigProviderProps {
|
|
10
|
+
value: BrevoConfig;
|
|
11
|
+
}
|
|
12
|
+
export declare const BrevoConfigProvider: ({ children, value }: PropsWithChildren<BrevoConfigProviderProps>) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
+
interface UseBrevoConfigReturn {
|
|
14
|
+
apiUrl: string;
|
|
15
|
+
previewUrl: string;
|
|
16
|
+
scopeParts: string[];
|
|
17
|
+
allowAddingContactsWithoutDoi?: boolean;
|
|
18
|
+
}
|
|
19
|
+
export declare const useBrevoConfig: () => UseBrevoConfigReturn;
|
|
20
|
+
export {};
|
|
21
|
+
//# sourceMappingURL=BrevoConfigProvider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BrevoConfigProvider.d.ts","sourceRoot":"","sources":["../../src/common/BrevoConfigProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,YAAY,EAAmB,MAAM,sBAAsB,CAAC;AAC1E,OAAO,EAAiB,KAAK,iBAAiB,EAAc,MAAM,OAAO,CAAC;AAE1E,MAAM,WAAW,WAAW;IACxB,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,yBAAyB,EAAE,CAAC,KAAK,EAAE,YAAY,KAAK,MAAM,CAAC;IAC3D,6BAA6B,CAAC,EAAE,OAAO,CAAC;CAC3C;AAID,UAAU,wBAAwB;IAC9B,KAAK,EAAE,WAAW,CAAC;CACtB;AAED,eAAO,MAAM,mBAAmB,GAAI,qBAAqB,iBAAiB,CAAC,wBAAwB,CAAC,4CAEnG,CAAC;AAEF,UAAU,oBAAoB;IAC1B,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,6BAA6B,CAAC,EAAE,OAAO,CAAC;CAC3C;AAED,eAAO,MAAM,cAAc,QAAO,oBAYjC,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
3
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
|
+
function _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }
|
|
5
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
6
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
7
|
+
import { useContentScope } from "@dextinity/cms-admin";
|
|
8
|
+
import { createContext, useContext } from "react";
|
|
9
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
10
|
+
var BrevoConfigContext = /*#__PURE__*/createContext(undefined);
|
|
11
|
+
export var BrevoConfigProvider = function BrevoConfigProvider(_ref) {
|
|
12
|
+
var children = _ref.children,
|
|
13
|
+
value = _ref.value;
|
|
14
|
+
return /*#__PURE__*/_jsx(BrevoConfigContext.Provider, {
|
|
15
|
+
value: value,
|
|
16
|
+
children: children
|
|
17
|
+
});
|
|
18
|
+
};
|
|
19
|
+
export var useBrevoConfig = function useBrevoConfig() {
|
|
20
|
+
var _context$allowAddingC;
|
|
21
|
+
var _useContentScope = useContentScope(),
|
|
22
|
+
scope = _useContentScope.scope;
|
|
23
|
+
var context = useContext(BrevoConfigContext);
|
|
24
|
+
if (context === undefined) {
|
|
25
|
+
throw new Error("useBrevoConfig must be used within a BrevoConfigProvider");
|
|
26
|
+
}
|
|
27
|
+
var previewUrl = context.resolvePreviewUrlForScope(scope);
|
|
28
|
+
var allowAddingContactsWithoutDoi = (_context$allowAddingC = context.allowAddingContactsWithoutDoi) !== null && _context$allowAddingC !== void 0 ? _context$allowAddingC : false;
|
|
29
|
+
return _objectSpread(_objectSpread({}, context), {}, {
|
|
30
|
+
previewUrl: previewUrl,
|
|
31
|
+
allowAddingContactsWithoutDoi: allowAddingContactsWithoutDoi
|
|
32
|
+
});
|
|
33
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { RefetchQueriesInclude } from "@apollo/client/core/types";
|
|
2
|
+
import { type MenuItem } from "@mui/material";
|
|
3
|
+
import { type ComponentProps, type ReactNode } from "react";
|
|
4
|
+
import type { GQLEmailCampaignContentScopeInput } from "../../graphql.generated";
|
|
5
|
+
interface UseContactImportProps {
|
|
6
|
+
scope: GQLEmailCampaignContentScopeInput;
|
|
7
|
+
sendDoubleOptIn: boolean;
|
|
8
|
+
targetGroupId?: string;
|
|
9
|
+
refetchQueries?: RefetchQueriesInclude;
|
|
10
|
+
}
|
|
11
|
+
interface ActionItem extends ComponentProps<typeof MenuItem> {
|
|
12
|
+
type: "action";
|
|
13
|
+
label: ReactNode;
|
|
14
|
+
startAdornment?: ReactNode;
|
|
15
|
+
}
|
|
16
|
+
export declare const useContactImportFromCsv: ({ scope, targetGroupId, refetchQueries }: UseContactImportProps) => [ActionItem, ReactNode];
|
|
17
|
+
export {};
|
|
18
|
+
//# sourceMappingURL=useContactImportFromCsv.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useContactImportFromCsv.d.ts","sourceRoot":"","sources":["../../../src/common/contactImport/useContactImportFromCsv.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,2BAA2B,CAAC;AAGvE,OAAO,EAAkD,KAAK,QAAQ,EAAE,MAAM,eAAe,CAAC;AAE9F,OAAO,EAAE,KAAK,cAAc,EAAE,KAAK,SAAS,EAA6C,MAAM,OAAO,CAAC;AAIvG,OAAO,KAAK,EAA2B,iCAAiC,EAAE,MAAM,yBAAyB,CAAC;AAK1G,UAAU,qBAAqB;IAC3B,KAAK,EAAE,iCAAiC,CAAC;IACzC,eAAe,EAAE,OAAO,CAAC;IACzB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,cAAc,CAAC,EAAE,qBAAqB,CAAC;CAC1C;AAMD,UAAU,UAAW,SAAQ,cAAc,CAAC,OAAO,QAAQ,CAAC;IACxD,IAAI,EAAE,QAAQ,CAAC;IACf,KAAK,EAAE,SAAS,CAAC;IACjB,cAAc,CAAC,EAAE,SAAS,CAAC;CAC9B;AAED,eAAO,MAAM,uBAAuB,GAAI,0CAA0C,qBAAqB,KAAG,CAAC,UAAU,EAAE,SAAS,CAwG/H,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useContactImportFromCsv.gql.d.ts","sourceRoot":"","sources":["../../../src/common/contactImport/useContactImportFromCsv.gql.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,+BAA+B,gCAY3C,CAAC"}
|