@comet/brevo-admin 3.0.0-canary-20241212151627 → 3.0.0-canary-20241218131430

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.
Files changed (40) hide show
  1. package/lib/brevoConfiguration/BrevoConfigForm.d.ts.map +1 -1
  2. package/lib/brevoConfiguration/BrevoConfigForm.gql.d.ts.map +1 -1
  3. package/lib/brevoConfiguration/BrevoConfigForm.gql.generated.d.ts +4 -0
  4. package/lib/brevoConfiguration/BrevoConfigForm.gql.generated.d.ts.map +1 -1
  5. package/lib/brevoConfiguration/BrevoConfigForm.gql.js +1 -1
  6. package/lib/brevoConfiguration/BrevoConfigForm.js +38 -15
  7. package/lib/brevoContacts/form/BrevoContactForm.d.ts +0 -2
  8. package/lib/brevoContacts/form/BrevoContactForm.d.ts.map +1 -1
  9. package/lib/brevoContacts/form/BrevoContactForm.generated.d.ts +0 -3
  10. package/lib/brevoContacts/form/BrevoContactForm.generated.d.ts.map +1 -1
  11. package/lib/brevoContacts/form/BrevoContactForm.gql.generated.d.ts +0 -6
  12. package/lib/brevoContacts/form/BrevoContactForm.gql.generated.d.ts.map +1 -1
  13. package/lib/brevoContacts/form/BrevoContactForm.js +11 -10
  14. package/lib/brevoTestContacts/BrevoTestContactsGrid.d.ts +13 -0
  15. package/lib/brevoTestContacts/BrevoTestContactsGrid.d.ts.map +1 -0
  16. package/lib/brevoTestContacts/BrevoTestContactsGrid.generated.d.ts +52 -0
  17. package/lib/brevoTestContacts/BrevoTestContactsGrid.generated.d.ts.map +1 -0
  18. package/lib/brevoTestContacts/BrevoTestContactsGrid.generated.js +17 -0
  19. package/lib/brevoTestContacts/BrevoTestContactsGrid.js +203 -0
  20. package/lib/brevoTestContacts/BrevoTestContactsPage.d.ts +17 -0
  21. package/lib/brevoTestContacts/BrevoTestContactsPage.d.ts.map +1 -0
  22. package/lib/brevoTestContacts/BrevoTestContactsPage.js +80 -0
  23. package/lib/brevoTestContacts/form/BrevoTestContactForm.d.ts +19 -0
  24. package/lib/brevoTestContacts/form/BrevoTestContactForm.d.ts.map +1 -0
  25. package/lib/brevoTestContacts/form/BrevoTestContactForm.generated.d.ts +13 -0
  26. package/lib/brevoTestContacts/form/BrevoTestContactForm.generated.d.ts.map +1 -0
  27. package/lib/brevoTestContacts/form/BrevoTestContactForm.generated.js +11 -0
  28. package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.d.ts +6 -0
  29. package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.d.ts.map +1 -0
  30. package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.generated.d.ts +64 -0
  31. package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.generated.d.ts.map +1 -0
  32. package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.generated.js +16 -0
  33. package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.js +17 -0
  34. package/lib/brevoTestContacts/form/BrevoTestContactForm.js +275 -0
  35. package/lib/graphql.generated.d.ts +30 -0
  36. package/lib/graphql.generated.d.ts.map +1 -1
  37. package/lib/index.d.ts +1 -0
  38. package/lib/index.d.ts.map +1 -1
  39. package/lib/index.js +7 -0
  40. package/package.json +1 -1
@@ -0,0 +1,203 @@
1
+ "use strict";
2
+
3
+ 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); }
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ exports.BrevoTestContactsGrid = BrevoTestContactsGrid;
8
+ var _client = require("@apollo/client");
9
+ var _admin = require("@comet/admin");
10
+ var _adminIcons = require("@comet/admin-icons");
11
+ var _material = require("@mui/material");
12
+ var _xDataGrid = require("@mui/x-data-grid");
13
+ var React = _interopRequireWildcard(require("react"));
14
+ var _reactIntl = require("react-intl");
15
+ var _jsxRuntime = require("react/jsx-runtime");
16
+ var _templateObject, _templateObject2, _templateObject3;
17
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
18
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
19
+ function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == _typeof(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, "throw" === n && e.iterator["return"] && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, "catch": function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
20
+ 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); }
21
+ 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); }); }; }
22
+ function _toConsumableArray(r) { return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread(); }
23
+ function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
24
+ function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
25
+ function _iterableToArray(r) { if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r); }
26
+ function _arrayWithoutHoles(r) { if (Array.isArray(r)) return _arrayLikeToArray(r); }
27
+ function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
28
+ 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; }
29
+ 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; }
30
+ 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; }
31
+ function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
32
+ 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); }
33
+ function _taggedTemplateLiteral(e, t) { return t || (t = e.slice(0)), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } })); }
34
+ var brevoContactsFragment = (0, _client.gql)(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n fragment BrevoContactsList on BrevoContact {\n id\n createdAt\n modifiedAt\n email\n emailBlacklisted\n smsBlacklisted\n }\n"])));
35
+ var deleteBrevoTestContactMutation = (0, _client.gql)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n mutation DeleteBrevoTestContact($id: Int!, $scope: EmailCampaignContentScopeInput!) {\n deleteBrevoTestContact(id: $id, scope: $scope)\n }\n"])));
36
+ function BrevoTestContactsGridToolbar(_ref) {
37
+ var intl = _ref.intl,
38
+ scope = _ref.scope;
39
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_admin.DataGridToolbar, {
40
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.ToolbarTitleItem, {
41
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactIntl.FormattedMessage, {
42
+ id: "cometBrevoModule.brevoTestContact.title",
43
+ defaultMessage: "Test contacts"
44
+ })
45
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.ToolbarItem, {
46
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_xDataGrid.GridToolbarQuickFilter, {
47
+ placeholder: intl.formatMessage({
48
+ id: "cometBrevoModule.brevoTestContact.searchEmail",
49
+ defaultMessage: "Search email address"
50
+ })
51
+ })
52
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.ToolbarFillSpace, {}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.ToolbarActions, {
53
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Button, {
54
+ startIcon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_adminIcons.Add, {}),
55
+ component: _admin.StackLink,
56
+ pageName: "add",
57
+ payload: "add",
58
+ variant: "contained",
59
+ color: "primary",
60
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactIntl.FormattedMessage, {
61
+ id: "cometBrevoModule.brevoTestContact.newContact",
62
+ defaultMessage: "New test contact"
63
+ })
64
+ })
65
+ })]
66
+ });
67
+ }
68
+ function BrevoTestContactsGrid(_ref2) {
69
+ var _additionalAttributes, _dataGridProps$filter, _dataGridProps$filter2, _data$brevoTestContac;
70
+ var scope = _ref2.scope,
71
+ additionalAttributesFragment = _ref2.additionalAttributesFragment,
72
+ _ref2$additionalGridF = _ref2.additionalGridFields,
73
+ additionalGridFields = _ref2$additionalGridF === void 0 ? [] : _ref2$additionalGridF;
74
+ var brevoTestContactsQuery = (0, _client.gql)(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n query BrevoTestContactsGrid($offset: Int, $limit: Int, $email: String, $scope: EmailCampaignContentScopeInput!) {\n brevoTestContacts(offset: $offset, limit: $limit, email: $email, scope: $scope) {\n nodes {\n ...BrevoContactsList\n ", "\n }\n totalCount\n }\n }\n ", "\n ", "\n "])), additionalAttributesFragment ? "...".concat(additionalAttributesFragment === null || additionalAttributesFragment === void 0 ? void 0 : additionalAttributesFragment.name) : "", brevoContactsFragment, (_additionalAttributes = additionalAttributesFragment === null || additionalAttributesFragment === void 0 ? void 0 : additionalAttributesFragment.fragment) !== null && _additionalAttributes !== void 0 ? _additionalAttributes : "");
75
+ var client = (0, _client.useApolloClient)();
76
+ var intl = (0, _reactIntl.useIntl)();
77
+ var dataGridProps = _objectSpread(_objectSpread({}, (0, _admin.useDataGridRemote)()), (0, _admin.usePersistentColumnState)("BrevoContactsGrid"));
78
+ var columns = [{
79
+ field: "createdAt",
80
+ headerName: intl.formatMessage({
81
+ id: "cometBrevoModule.brevoTestContact.subscribedAt",
82
+ defaultMessage: "Subscribed At"
83
+ }),
84
+ filterable: false,
85
+ sortable: false,
86
+ width: 150,
87
+ renderCell: function renderCell(_ref3) {
88
+ var row = _ref3.row;
89
+ return intl.formatDate(new Date(row.createdAt));
90
+ }
91
+ }, {
92
+ field: "modifiedAt",
93
+ headerName: intl.formatMessage({
94
+ id: "cometBrevoModule.brevoTestContact.modifiedAt",
95
+ defaultMessage: "Modified At"
96
+ }),
97
+ filterable: false,
98
+ sortable: false,
99
+ width: 150,
100
+ renderCell: function renderCell(_ref4) {
101
+ var row = _ref4.row;
102
+ return intl.formatDate(new Date(row.modifiedAt));
103
+ }
104
+ }, {
105
+ field: "email",
106
+ headerName: intl.formatMessage({
107
+ id: "cometBrevoModule.brevoTestContact.email",
108
+ defaultMessage: "Email"
109
+ }),
110
+ filterable: false,
111
+ sortable: false,
112
+ width: 150,
113
+ flex: 1
114
+ }].concat(_toConsumableArray(additionalGridFields), [{
115
+ field: "actions",
116
+ headerName: "",
117
+ sortable: false,
118
+ filterable: false,
119
+ type: "actions",
120
+ renderCell: function renderCell(params) {
121
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
122
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_material.IconButton, {
123
+ component: _admin.StackLink,
124
+ pageName: "edit",
125
+ payload: params.row.id.toString(),
126
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_adminIcons.Edit, {
127
+ color: "primary"
128
+ })
129
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.RowActionsMenu, {
130
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.RowActionsMenu, {
131
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.RowActionsItem, {
132
+ onClick: /*#__PURE__*/_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
133
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
134
+ while (1) switch (_context.prev = _context.next) {
135
+ case 0:
136
+ _context.next = 2;
137
+ return client.mutate({
138
+ mutation: deleteBrevoTestContactMutation,
139
+ variables: {
140
+ id: params.row.id,
141
+ scope: scope
142
+ },
143
+ refetchQueries: [brevoTestContactsQuery]
144
+ });
145
+ case 2:
146
+ case "end":
147
+ return _context.stop();
148
+ }
149
+ }, _callee);
150
+ })),
151
+ icon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_adminIcons.Delete, {}),
152
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactIntl.FormattedMessage, _objectSpread({}, _admin.messages["delete"]))
153
+ })
154
+ })
155
+ })]
156
+ });
157
+ }
158
+ }]);
159
+ var _useQuery = (0, _client.useQuery)(brevoTestContactsQuery, {
160
+ variables: {
161
+ offset: dataGridProps.page * dataGridProps.pageSize,
162
+ limit: dataGridProps.pageSize,
163
+ email: (_dataGridProps$filter = dataGridProps.filterModel) !== null && _dataGridProps$filter !== void 0 && _dataGridProps$filter.quickFilterValues ? (_dataGridProps$filter2 = dataGridProps.filterModel) === null || _dataGridProps$filter2 === void 0 ? void 0 : _dataGridProps$filter2.quickFilterValues[0] : undefined,
164
+ scope: scope
165
+ }
166
+ }),
167
+ data = _useQuery.data,
168
+ loading = _useQuery.loading,
169
+ error = _useQuery.error;
170
+ var rowCount = (0, _admin.useBufferedRowCount)(data === null || data === void 0 ? void 0 : data.brevoTestContacts.totalCount);
171
+ if (error) throw error;
172
+ var rows = (_data$brevoTestContac = data === null || data === void 0 ? void 0 : data.brevoTestContacts.nodes) !== null && _data$brevoTestContac !== void 0 ? _data$brevoTestContac : [];
173
+ return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_admin.MainContent, {
174
+ fullHeight: true,
175
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Box, {
176
+ sx: {
177
+ marginBottom: 4
178
+ },
179
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.Alert, {
180
+ severity: "warning",
181
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactIntl.FormattedMessage, {
182
+ id: "cometBrevoModule.brevoTestContact.testContactAlert",
183
+ defaultMessage: "Contacts in this list are only added for testing purposes. Users do not get a double-opt in to confirm their subscription."
184
+ })
185
+ })
186
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_xDataGrid.DataGrid, _objectSpread(_objectSpread({}, dataGridProps), {}, {
187
+ disableSelectionOnClick: true,
188
+ rows: rows,
189
+ rowCount: rowCount,
190
+ columns: columns,
191
+ loading: loading,
192
+ components: {
193
+ Toolbar: BrevoTestContactsGridToolbar
194
+ },
195
+ componentsProps: {
196
+ toolbar: {
197
+ intl: intl,
198
+ scope: scope
199
+ }
200
+ }
201
+ }))]
202
+ });
203
+ }
@@ -0,0 +1,17 @@
1
+ import { GridColDef } from "@comet/admin";
2
+ import { DocumentNode } from "graphql";
3
+ import * as React from "react";
4
+ import { EditBrevoContactFormValues } from "./form/BrevoTestContactForm";
5
+ interface CreateContactsPageOptions {
6
+ scopeParts: string[];
7
+ additionalAttributesFragment?: {
8
+ name: string;
9
+ fragment: DocumentNode;
10
+ };
11
+ additionalGridFields?: GridColDef[];
12
+ additionalFormFields?: React.ReactNode;
13
+ input2State?: (values?: EditBrevoContactFormValues) => EditBrevoContactFormValues;
14
+ }
15
+ declare function createBrevoTestContactsPage({ scopeParts, additionalAttributesFragment, additionalFormFields, additionalGridFields, input2State, }: CreateContactsPageOptions): () => JSX.Element;
16
+ export { createBrevoTestContactsPage };
17
+ //# 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,UAAU,EAA+C,MAAM,cAAc,CAAC;AAEvF,OAAO,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACvC,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,OAAO,EAAwB,0BAA0B,EAAE,MAAM,6BAA6B,CAAC;AAE/F,UAAU,yBAAyB;IAC/B,UAAU,EAAE,MAAM,EAAE,CAAC;IACrB,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,KAAK,CAAC,SAAS,CAAC;IACvC,WAAW,CAAC,EAAE,CAAC,MAAM,CAAC,EAAE,0BAA0B,KAAK,0BAA0B,CAAC;CACrF;AAED,iBAAS,2BAA2B,CAAC,EACjC,UAAU,EACV,4BAA4B,EAC5B,oBAAoB,EACpB,oBAAoB,EACpB,WAAW,GACd,EAAE,yBAAyB,SACU,WAAW,CAmDhD;AAED,OAAO,EAAE,2BAA2B,EAAE,CAAC"}
@@ -0,0 +1,80 @@
1
+ "use strict";
2
+
3
+ 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); }
4
+ Object.defineProperty(exports, "__esModule", {
5
+ value: true
6
+ });
7
+ exports.createBrevoTestContactsPage = createBrevoTestContactsPage;
8
+ var _admin = require("@comet/admin");
9
+ var _cmsAdmin = require("@comet/cms-admin");
10
+ var React = _interopRequireWildcard(require("react"));
11
+ var _reactIntl = require("react-intl");
12
+ var _BrevoTestContactsGrid = require("./BrevoTestContactsGrid");
13
+ var _BrevoTestContactForm = require("./form/BrevoTestContactForm");
14
+ var _jsxRuntime = require("react/jsx-runtime");
15
+ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
16
+ function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { "default": e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n["default"] = e, t && t.set(e, n), n; }
17
+ function createBrevoTestContactsPage(_ref) {
18
+ var scopeParts = _ref.scopeParts,
19
+ additionalAttributesFragment = _ref.additionalAttributesFragment,
20
+ additionalFormFields = _ref.additionalFormFields,
21
+ additionalGridFields = _ref.additionalGridFields,
22
+ input2State = _ref.input2State;
23
+ function BrevoTestContactsPage() {
24
+ var intl = (0, _reactIntl.useIntl)();
25
+ var _useContentScope = (0, _cmsAdmin.useContentScope)(),
26
+ completeScope = _useContentScope.scope;
27
+ var scope = scopeParts.reduce(function (acc, scopePart) {
28
+ acc[scopePart] = completeScope[scopePart];
29
+ return acc;
30
+ }, {});
31
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.Stack, {
32
+ topLevelTitle: intl.formatMessage({
33
+ id: "cometBrevoModule.brevoContacts.brevoTestContacts",
34
+ defaultMessage: "Test Contacts"
35
+ }),
36
+ children: /*#__PURE__*/(0, _jsxRuntime.jsxs)(_admin.StackSwitch, {
37
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_admin.StackPage, {
38
+ name: "grid",
39
+ children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.StackToolbar, {
40
+ scopeIndicator: /*#__PURE__*/(0, _jsxRuntime.jsx)(_cmsAdmin.ContentScopeIndicator, {
41
+ scope: scope
42
+ })
43
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_BrevoTestContactsGrid.BrevoTestContactsGrid, {
44
+ scope: scope,
45
+ additionalAttributesFragment: additionalAttributesFragment,
46
+ additionalGridFields: additionalGridFields
47
+ })]
48
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.StackPage, {
49
+ name: "edit",
50
+ title: intl.formatMessage({
51
+ id: "cometBrevoModule.brevoContacts.editBrevoContact",
52
+ defaultMessage: "Edit contact"
53
+ }),
54
+ children: function children(selectedId) {
55
+ return /*#__PURE__*/(0, _jsxRuntime.jsx)(_BrevoTestContactForm.BrevoTestContactForm, {
56
+ additionalFormFields: additionalFormFields,
57
+ additionalAttributesFragment: additionalAttributesFragment,
58
+ input2State: input2State,
59
+ id: Number(selectedId),
60
+ scope: scope
61
+ });
62
+ }
63
+ }), /*#__PURE__*/(0, _jsxRuntime.jsx)(_admin.StackPage, {
64
+ name: "add",
65
+ title: intl.formatMessage({
66
+ id: "cometBrevoModule.brevoContacts.addBrevoContact",
67
+ defaultMessage: "Add contact"
68
+ }),
69
+ children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_BrevoTestContactForm.BrevoTestContactForm, {
70
+ additionalFormFields: additionalFormFields,
71
+ additionalAttributesFragment: additionalAttributesFragment,
72
+ input2State: input2State,
73
+ scope: scope
74
+ })
75
+ })]
76
+ })
77
+ });
78
+ }
79
+ return BrevoTestContactsPage;
80
+ }
@@ -0,0 +1,19 @@
1
+ import { DocumentNode } from "@apollo/client";
2
+ import { ContentScopeInterface } from "@comet/cms-admin";
3
+ import React from "react";
4
+ export type EditBrevoContactFormValues = {
5
+ [key: string]: unknown;
6
+ };
7
+ interface FormProps {
8
+ id?: number;
9
+ scope: ContentScopeInterface;
10
+ additionalFormFields?: React.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): React.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,YAAY,EAAkC,MAAM,gBAAgB,CAAC;AAmB9E,OAAO,EAAE,qBAAqB,EAA+C,MAAM,kBAAkB,CAAC;AAItG,OAAO,KAAK,MAAM,OAAO,CAAC;AAoB1B,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,qBAAqB,CAAC;IAC7B,oBAAoB,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IACvC,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,KAAK,CAAC,YAAY,CA4JlJ"}
@@ -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,11 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.namedOperations = void 0;
7
+ var namedOperations = exports.namedOperations = {
8
+ Fragment: {
9
+ BrevoTestContactForm: 'BrevoTestContactForm'
10
+ }
11
+ };
@@ -0,0 +1,6 @@
1
+ import { 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,YAAY,EAAO,MAAM,gBAAgB,CAAC;AAEnD,eAAO,MAAM,qBAAqB,iCAAkC,YAAY,iBAS/E,CAAC;AAEF,eAAO,MAAM,oCAAoC,cAMhD,CAAC;AAEF,eAAO,MAAM,8BAA8B,cAI1C,CAAC;AAEF,eAAO,MAAM,0BAA0B,iCAAkC,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'];
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'];
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'];
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;IACzB,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;IACzB,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;IACzB,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,16 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.namedOperations = void 0;
7
+ var namedOperations = exports.namedOperations = {
8
+ Query: {
9
+ BrevoContactForm: 'BrevoContactForm',
10
+ BrevoContactFormCheckForChanges: 'BrevoContactFormCheckForChanges'
11
+ },
12
+ Mutation: {
13
+ CreateBrevoTestContact: 'CreateBrevoTestContact',
14
+ UpdateBrevoContact: 'UpdateBrevoContact'
15
+ }
16
+ };
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.updateBrevoContactMutation = exports.createBrevoTestContactMutation = exports.brevoContactFormQuery = exports.brevoContactFormCheckForChangesQuery = void 0;
7
+ var _client = require("@apollo/client");
8
+ var _templateObject, _templateObject2, _templateObject3, _templateObject4;
9
+ function _taggedTemplateLiteral(e, t) { return t || (t = e.slice(0)), Object.freeze(Object.defineProperties(e, { raw: { value: Object.freeze(t) } })); }
10
+ var brevoContactFormQuery = exports.brevoContactFormQuery = function brevoContactFormQuery(brevoTestContactFormFragment) {
11
+ return (0, _client.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);
12
+ };
13
+ var brevoContactFormCheckForChangesQuery = exports.brevoContactFormCheckForChangesQuery = (0, _client.gql)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n query BrevoContactFormCheckForChanges($id: Int!, $scope: EmailCampaignContentScopeInput!) {\n brevoContact(id: $id, scope: $scope) {\n modifiedAt\n }\n }\n"])));
14
+ var createBrevoTestContactMutation = exports.createBrevoTestContactMutation = (0, _client.gql)(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n mutation CreateBrevoTestContact($scope: EmailCampaignContentScopeInput!, $input: BrevoTestContactInput!) {\n createBrevoTestContact(scope: $scope, input: $input)\n }\n"])));
15
+ var updateBrevoContactMutation = exports.updateBrevoContactMutation = function updateBrevoContactMutation(brevoTestContactFormFragment) {
16
+ return (0, _client.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);
17
+ };