@comet/brevo-admin 4.0.0-canary-20250731092722 → 9.0.0-canary-20260121090431
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/lib/blocks/NewsletterImageBlock.d.ts +2 -2
- package/lib/blocks/NewsletterImageBlock.d.ts.map +1 -1
- package/lib/blocks/NewsletterImageBlock.js +2 -5
- package/lib/blocks.generated.d.ts +204 -0
- package/lib/blocks.generated.d.ts.map +1 -0
- package/lib/blocks.generated.js +5 -0
- package/lib/brevoConfiguration/BrevoConfigForm.d.ts +4 -4
- package/lib/brevoConfiguration/BrevoConfigForm.d.ts.map +1 -1
- package/lib/brevoConfiguration/BrevoConfigForm.gql.generated.d.ts +2 -2
- package/lib/brevoConfiguration/BrevoConfigForm.gql.generated.d.ts.map +1 -1
- package/lib/brevoConfiguration/BrevoConfigForm.js +48 -54
- package/lib/brevoConfiguration/BrevoConfigPage.d.ts +0 -1
- package/lib/brevoConfiguration/BrevoConfigPage.d.ts.map +1 -1
- package/lib/brevoConfiguration/BrevoConfigPage.js +0 -4
- package/lib/brevoContacts/BrevoContactsGrid.d.ts +6 -6
- package/lib/brevoContacts/BrevoContactsGrid.d.ts.map +1 -1
- package/lib/brevoContacts/BrevoContactsGrid.generated.d.ts +5 -5
- package/lib/brevoContacts/BrevoContactsGrid.generated.d.ts.map +1 -1
- package/lib/brevoContacts/BrevoContactsGrid.js +39 -51
- package/lib/brevoContacts/BrevoContactsPage.d.ts +5 -5
- package/lib/brevoContacts/BrevoContactsPage.d.ts.map +1 -1
- package/lib/brevoContacts/BrevoContactsPage.js +0 -4
- package/lib/brevoContacts/form/BrevoContactForm.d.ts +6 -6
- package/lib/brevoContacts/form/BrevoContactForm.d.ts.map +1 -1
- package/lib/brevoContacts/form/BrevoContactForm.gql.d.ts +1 -1
- package/lib/brevoContacts/form/BrevoContactForm.gql.d.ts.map +1 -1
- package/lib/brevoContacts/form/BrevoContactForm.gql.generated.d.ts +3 -3
- package/lib/brevoContacts/form/BrevoContactForm.gql.generated.d.ts.map +1 -1
- package/lib/brevoContacts/form/BrevoContactForm.js +62 -67
- package/lib/brevoTestContacts/BrevoTestContactsGrid.d.ts +6 -6
- package/lib/brevoTestContacts/BrevoTestContactsGrid.d.ts.map +1 -1
- package/lib/brevoTestContacts/BrevoTestContactsGrid.generated.d.ts +4 -4
- package/lib/brevoTestContacts/BrevoTestContactsGrid.generated.d.ts.map +1 -1
- package/lib/brevoTestContacts/BrevoTestContactsGrid.js +31 -40
- package/lib/brevoTestContacts/BrevoTestContactsPage.d.ts +5 -5
- package/lib/brevoTestContacts/BrevoTestContactsPage.d.ts.map +1 -1
- package/lib/brevoTestContacts/BrevoTestContactsPage.js +0 -4
- package/lib/brevoTestContacts/form/BrevoTestContactForm.d.ts +6 -6
- package/lib/brevoTestContacts/form/BrevoTestContactForm.d.ts.map +1 -1
- package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.d.ts +1 -1
- package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.d.ts.map +1 -1
- package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.generated.d.ts +3 -3
- package/lib/brevoTestContacts/form/BrevoTestContactForm.gql.generated.d.ts.map +1 -1
- package/lib/brevoTestContacts/form/BrevoTestContactForm.js +50 -55
- package/lib/common/BrevoConfigProvider.d.ts +4 -4
- package/lib/common/BrevoConfigProvider.d.ts.map +1 -1
- package/lib/common/BrevoConfigProvider.js +3 -4
- package/lib/common/contactImport/useContactImportFromCsv.d.ts +10 -5
- package/lib/common/contactImport/useContactImportFromCsv.d.ts.map +1 -1
- package/lib/common/contactImport/useContactImportFromCsv.gql.generated.d.ts +3 -3
- package/lib/common/contactImport/useContactImportFromCsv.gql.generated.d.ts.map +1 -1
- package/lib/common/contactImport/useContactImportFromCsv.js +74 -76
- package/lib/configVerification/ConfigVerification.d.ts +4 -4
- package/lib/configVerification/ConfigVerification.d.ts.map +1 -1
- package/lib/configVerification/ConfigVerification.js +0 -4
- package/lib/emailCampaigns/EmailCampaignsGrid.d.ts +4 -5
- package/lib/emailCampaigns/EmailCampaignsGrid.d.ts.map +1 -1
- package/lib/emailCampaigns/EmailCampaignsGrid.generated.d.ts +4 -4
- package/lib/emailCampaigns/EmailCampaignsGrid.generated.d.ts.map +1 -1
- package/lib/emailCampaigns/EmailCampaignsGrid.js +35 -43
- package/lib/emailCampaigns/EmailCampaignsPage.d.ts +1 -2
- package/lib/emailCampaigns/EmailCampaignsPage.d.ts.map +1 -1
- package/lib/emailCampaigns/EmailCampaignsPage.js +0 -4
- package/lib/emailCampaigns/SendingStateColumn.d.ts +2 -3
- package/lib/emailCampaigns/SendingStateColumn.d.ts.map +1 -1
- package/lib/emailCampaigns/SendingStateColumn.js +5 -11
- package/lib/emailCampaigns/form/ConfigFields.d.ts +1 -2
- package/lib/emailCampaigns/form/ConfigFields.d.ts.map +1 -1
- package/lib/emailCampaigns/form/ConfigFields.js +0 -4
- package/lib/emailCampaigns/form/EmailCampaignForm.d.ts +3 -5
- package/lib/emailCampaigns/form/EmailCampaignForm.d.ts.map +1 -1
- package/lib/emailCampaigns/form/EmailCampaignForm.gql.generated.d.ts +4 -4
- package/lib/emailCampaigns/form/EmailCampaignForm.gql.generated.d.ts.map +1 -1
- package/lib/emailCampaigns/form/EmailCampaignForm.js +72 -86
- package/lib/emailCampaigns/form/SendEmailCampaignNowDialog.d.ts +1 -2
- package/lib/emailCampaigns/form/SendEmailCampaignNowDialog.d.ts.map +1 -1
- package/lib/emailCampaigns/form/SendEmailCampaignNowDialog.js +1 -3
- package/lib/emailCampaigns/form/SendManagerFields.d.ts +3 -4
- package/lib/emailCampaigns/form/SendManagerFields.d.ts.map +1 -1
- package/lib/emailCampaigns/form/SendManagerFields.gql.generated.d.ts +1 -1
- package/lib/emailCampaigns/form/SendManagerFields.gql.generated.d.ts.map +1 -1
- package/lib/emailCampaigns/form/SendManagerFields.js +27 -40
- package/lib/emailCampaigns/form/SendManagerWrapper.d.ts +4 -4
- package/lib/emailCampaigns/form/SendManagerWrapper.d.ts.map +1 -1
- package/lib/emailCampaigns/form/SendManagerWrapper.js +0 -4
- package/lib/emailCampaigns/form/TestEmailCampaignForm.d.ts +2 -3
- package/lib/emailCampaigns/form/TestEmailCampaignForm.d.ts.map +1 -1
- package/lib/emailCampaigns/form/TestEmailCampaignForm.generated.d.ts +3 -3
- package/lib/emailCampaigns/form/TestEmailCampaignForm.generated.d.ts.map +1 -1
- package/lib/emailCampaigns/form/TestEmailCampaignForm.gql.generated.d.ts +1 -1
- package/lib/emailCampaigns/form/TestEmailCampaignForm.gql.generated.d.ts.map +1 -1
- package/lib/emailCampaigns/form/TestEmailCampaignForm.js +19 -33
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.d.ts +2 -2
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.d.ts.map +1 -1
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.gql.generated.d.ts +1 -1
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.gql.generated.d.ts.map +1 -1
- package/lib/emailCampaigns/statistics/EmailCampaignStatistics.js +34 -31
- package/lib/emailCampaigns/statistics/PercentageCard.d.ts +3 -3
- package/lib/emailCampaigns/statistics/PercentageCard.d.ts.map +1 -1
- package/lib/emailCampaigns/statistics/PercentageCard.js +6 -15
- package/lib/emailCampaigns/view/EmailCampaignView.d.ts +2 -3
- package/lib/emailCampaigns/view/EmailCampaignView.d.ts.map +1 -1
- package/lib/emailCampaigns/view/EmailCampaignView.gql.generated.d.ts +1 -1
- package/lib/emailCampaigns/view/EmailCampaignView.gql.generated.d.ts.map +1 -1
- package/lib/emailCampaigns/view/EmailCampaignView.js +2 -5
- package/lib/graphql.generated.d.ts +280 -211
- package/lib/graphql.generated.d.ts.map +1 -1
- package/lib/index.d.ts +3 -3
- package/lib/index.d.ts.map +1 -1
- package/lib/index.js +0 -20
- package/lib/targetGroups/TargetGroupDialog.d.ts +4 -4
- package/lib/targetGroups/TargetGroupDialog.d.ts.map +1 -1
- package/lib/targetGroups/TargetGroupDialog.js +10 -12
- package/lib/targetGroups/TargetGroupForm.d.ts +6 -6
- package/lib/targetGroups/TargetGroupForm.d.ts.map +1 -1
- package/lib/targetGroups/TargetGroupForm.gql.d.ts +1 -1
- package/lib/targetGroups/TargetGroupForm.gql.d.ts.map +1 -1
- package/lib/targetGroups/TargetGroupForm.gql.generated.d.ts +4 -4
- package/lib/targetGroups/TargetGroupForm.gql.generated.d.ts.map +1 -1
- package/lib/targetGroups/TargetGroupForm.js +28 -33
- package/lib/targetGroups/TargetGroupsGrid.d.ts +5 -5
- package/lib/targetGroups/TargetGroupsGrid.d.ts.map +1 -1
- package/lib/targetGroups/TargetGroupsGrid.generated.d.ts +7 -7
- package/lib/targetGroups/TargetGroupsGrid.generated.d.ts.map +1 -1
- package/lib/targetGroups/TargetGroupsGrid.js +45 -55
- package/lib/targetGroups/TargetGroupsPage.d.ts +5 -5
- package/lib/targetGroups/TargetGroupsPage.d.ts.map +1 -1
- package/lib/targetGroups/TargetGroupsPage.js +0 -4
- package/lib/targetGroups/addContacts/AddContactsGridSelect.d.ts +4 -4
- package/lib/targetGroups/addContacts/AddContactsGridSelect.d.ts.map +1 -1
- package/lib/targetGroups/addContacts/AddContactsGridSelect.gql.generated.d.ts +9 -9
- package/lib/targetGroups/addContacts/AddContactsGridSelect.gql.generated.d.ts.map +1 -1
- package/lib/targetGroups/addContacts/AddContactsGridSelect.js +43 -52
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.d.ts +4 -4
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.d.ts.map +1 -1
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.gql.generated.d.ts +4 -4
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.gql.generated.d.ts.map +1 -1
- package/lib/targetGroups/allAssignedContacts/AllAssignedContactsGrid.js +9 -14
- package/package.json +71 -72
- package/lib/temp/CrudMoreActionsMenu.d.ts +0 -23
- package/lib/temp/CrudMoreActionsMenu.d.ts.map +0 -1
- package/lib/temp/CrudMoreActionsMenu.js +0 -208
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
1
|
+
import { type ContentScope } from "@comet/cms-admin";
|
|
2
|
+
import { type ReactElement } from "react";
|
|
3
3
|
interface AllAssignedContactsGridProps {
|
|
4
|
-
scope:
|
|
4
|
+
scope: ContentScope;
|
|
5
5
|
id: string;
|
|
6
6
|
brevoId?: number;
|
|
7
7
|
}
|
|
8
|
-
export declare function AllAssignedContactsGrid({ id, scope, brevoId }: AllAssignedContactsGridProps):
|
|
8
|
+
export declare function AllAssignedContactsGrid({ id, scope, brevoId }: AllAssignedContactsGridProps): ReactElement;
|
|
9
9
|
export {};
|
|
10
10
|
//# sourceMappingURL=AllAssignedContactsGrid.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AllAssignedContactsGrid.d.ts","sourceRoot":"","sources":["../../../src/targetGroups/allAssignedContacts/AllAssignedContactsGrid.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"AllAssignedContactsGrid.d.ts","sourceRoot":"","sources":["../../../src/targetGroups/allAssignedContacts/AllAssignedContactsGrid.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAErD,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,OAAO,CAAC;AA4B1C,UAAU,4BAA4B;IAClC,KAAK,EAAE,YAAY,CAAC;IACpB,EAAE,EAAE,MAAM,CAAC;IACX,OAAO,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,wBAAgB,uBAAuB,CAAC,EAAE,EAAE,EAAE,KAAK,EAAE,OAAO,EAAE,EAAE,4BAA4B,GAAG,YAAY,CA0E1G"}
|
|
@@ -17,10 +17,10 @@ export type GQLTargetGroupBrevoContactsListFragment = {
|
|
|
17
17
|
smsBlacklisted: boolean;
|
|
18
18
|
};
|
|
19
19
|
export type GQLBrevoContactsQueryVariables = Types.Exact<{
|
|
20
|
-
offset?: Types.InputMaybe<Types.Scalars['Int']>;
|
|
21
|
-
limit?: Types.InputMaybe<Types.Scalars['Int']>;
|
|
22
|
-
email?: Types.InputMaybe<Types.Scalars['String']>;
|
|
23
|
-
targetGroupId: Types.Scalars['ID'];
|
|
20
|
+
offset?: Types.InputMaybe<Types.Scalars['Int']['input']>;
|
|
21
|
+
limit?: Types.InputMaybe<Types.Scalars['Int']['input']>;
|
|
22
|
+
email?: Types.InputMaybe<Types.Scalars['String']['input']>;
|
|
23
|
+
targetGroupId: Types.Scalars['ID']['input'];
|
|
24
24
|
scope: Types.GQLEmailCampaignContentScopeInput;
|
|
25
25
|
}>;
|
|
26
26
|
export type GQLBrevoContactsQuery = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AllAssignedContactsGrid.gql.generated.d.ts","sourceRoot":"","sources":["../../../src/targetGroups/allAssignedContacts/AllAssignedContactsGrid.gql.generated.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,yBAAyB,CAAC;AAEjD,eAAO,MAAM,eAAe;;;;;;;CAO3B,CAAA;AACD,MAAM,MAAM,uCAAuC,GAAG;IAAE,UAAU,CAAC,EAAE,cAAc,CAAC;IAAC,EAAE,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,gBAAgB,EAAE,OAAO,CAAC;IAAC,cAAc,EAAE,OAAO,CAAA;CAAE,CAAC;AAE5M,MAAM,MAAM,8BAA8B,GAAG,KAAK,CAAC,KAAK,CAAC;IACvD,MAAM,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"AllAssignedContactsGrid.gql.generated.d.ts","sourceRoot":"","sources":["../../../src/targetGroups/allAssignedContacts/AllAssignedContactsGrid.gql.generated.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,yBAAyB,CAAC;AAEjD,eAAO,MAAM,eAAe;;;;;;;CAO3B,CAAA;AACD,MAAM,MAAM,uCAAuC,GAAG;IAAE,UAAU,CAAC,EAAE,cAAc,CAAC;IAAC,EAAE,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,MAAM,CAAC;IAAC,UAAU,EAAE,MAAM,CAAC;IAAC,KAAK,EAAE,MAAM,CAAC;IAAC,gBAAgB,EAAE,OAAO,CAAC;IAAC,cAAc,EAAE,OAAO,CAAA;CAAE,CAAC;AAE5M,MAAM,MAAM,8BAA8B,GAAG,KAAK,CAAC,KAAK,CAAC;IACvD,MAAM,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC;IACzD,KAAK,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC;IACxD,KAAK,CAAC,EAAE,KAAK,CAAC,UAAU,CAAC,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC;IAC3D,aAAa,EAAE,KAAK,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,OAAO,CAAC,CAAC;IAC5C,KAAK,EAAE,KAAK,CAAC,iCAAiC,CAAC;CAChD,CAAC,CAAC;AAGH,MAAM,MAAM,qBAAqB,GAAG;IAAE,UAAU,CAAC,EAAE,OAAO,CAAC;IAAC,aAAa,EAAE;QAAE,UAAU,CAAC,EAAE,wBAAwB,CAAC;QAAC,UAAU,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,KAAK,CAAC;YAAE,UAAU,CAAC,EAAE,cAAc,CAAC;YAAC,EAAE,EAAE,MAAM,CAAC;YAAC,SAAS,EAAE,MAAM,CAAC;YAAC,UAAU,EAAE,MAAM,CAAC;YAAC,KAAK,EAAE,MAAM,CAAC;YAAC,gBAAgB,EAAE,OAAO,CAAC;YAAC,cAAc,EAAE,OAAO,CAAA;SAAE,CAAC,CAAA;KAAE,CAAA;CAAE,CAAC"}
|
|
@@ -7,12 +7,9 @@ exports.AllAssignedContactsGrid = AllAssignedContactsGrid;
|
|
|
7
7
|
var _client = require("@apollo/client");
|
|
8
8
|
var _admin = require("@comet/admin");
|
|
9
9
|
var _xDataGrid = require("@mui/x-data-grid");
|
|
10
|
-
var React = _interopRequireWildcard(require("react"));
|
|
11
10
|
var _reactIntl = require("react-intl");
|
|
12
11
|
var _AllAssignedContactsGrid = require("./AllAssignedContactsGrid.gql");
|
|
13
12
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
14
|
-
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); }
|
|
15
|
-
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; }
|
|
16
13
|
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); }
|
|
17
14
|
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; }
|
|
18
15
|
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; }
|
|
@@ -27,12 +24,10 @@ var AssignedContactsGridToolbar = function AssignedContactsGridToolbar() {
|
|
|
27
24
|
id: "cometBrevoModule.targetGroup.allAssignedContacts.title",
|
|
28
25
|
defaultMessage: "All assigned contacts"
|
|
29
26
|
})
|
|
30
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
defaultMessage: "Search email address"
|
|
35
|
-
})
|
|
27
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_xDataGrid.GridToolbarQuickFilter, {
|
|
28
|
+
placeholder: intl.formatMessage({
|
|
29
|
+
id: "cometBrevoModule.targetGroup.assignedContacts.searchEmail",
|
|
30
|
+
defaultMessage: "Search email address"
|
|
36
31
|
})
|
|
37
32
|
})]
|
|
38
33
|
});
|
|
@@ -46,8 +41,8 @@ function AllAssignedContactsGrid(_ref) {
|
|
|
46
41
|
var dataGridAllAssignedContactsProps = _objectSpread(_objectSpread({}, (0, _admin.useDataGridRemote)()), (0, _admin.usePersistentColumnState)("TargetGroupAssignedBrevoContactsGrid"));
|
|
47
42
|
var _useQuery = (0, _client.useQuery)(_AllAssignedContactsGrid.allAssignedBrevoContactsGridQuery, {
|
|
48
43
|
variables: {
|
|
49
|
-
offset: dataGridAllAssignedContactsProps.page * dataGridAllAssignedContactsProps.pageSize,
|
|
50
|
-
limit: dataGridAllAssignedContactsProps.pageSize,
|
|
44
|
+
offset: dataGridAllAssignedContactsProps.paginationModel.page * dataGridAllAssignedContactsProps.paginationModel.pageSize,
|
|
45
|
+
limit: dataGridAllAssignedContactsProps.paginationModel.pageSize,
|
|
51
46
|
email: (_dataGridAllAssignedC = dataGridAllAssignedContactsProps.filterModel) !== null && _dataGridAllAssignedC !== void 0 && _dataGridAllAssignedC.quickFilterValues ? (_dataGridAllAssignedC2 = dataGridAllAssignedContactsProps.filterModel) === null || _dataGridAllAssignedC2 === void 0 ? void 0 : _dataGridAllAssignedC2.quickFilterValues[0] : undefined,
|
|
52
47
|
targetGroupId: id,
|
|
53
48
|
scope: scope
|
|
@@ -107,14 +102,14 @@ function AllAssignedContactsGrid(_ref) {
|
|
|
107
102
|
var allAssignedContactsRowCount = (0, _admin.useBufferedRowCount)(allAssignedContactsData === null || allAssignedContactsData === void 0 ? void 0 : allAssignedContactsData.brevoContacts.totalCount);
|
|
108
103
|
if (allAssignedContactsError) throw allAssignedContactsError;
|
|
109
104
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_xDataGrid.DataGrid, _objectSpread(_objectSpread({}, dataGridAllAssignedContactsProps), {}, {
|
|
110
|
-
|
|
105
|
+
disableRowSelectionOnClick: true,
|
|
111
106
|
rows: (_allAssignedContactsD = allAssignedContactsData === null || allAssignedContactsData === void 0 ? void 0 : allAssignedContactsData.brevoContacts.nodes) !== null && _allAssignedContactsD !== void 0 ? _allAssignedContactsD : [],
|
|
112
107
|
rowCount: allAssignedContactsRowCount,
|
|
113
108
|
columns: allAssignedContactsColumns,
|
|
114
109
|
autoHeight: true,
|
|
115
110
|
loading: assignedContactsLoading,
|
|
116
|
-
|
|
117
|
-
|
|
111
|
+
slots: {
|
|
112
|
+
toolbar: AssignedContactsGridToolbar
|
|
118
113
|
}
|
|
119
114
|
}));
|
|
120
115
|
}
|
package/package.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@comet/brevo-admin",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "9.0.0-canary-20260121090431",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
|
-
"url": "https://github.com/vivid-planet/comet
|
|
7
|
-
"directory": "packages/
|
|
6
|
+
"url": "https://github.com/vivid-planet/comet/",
|
|
7
|
+
"directory": "packages/admin/brevo-admin"
|
|
8
8
|
},
|
|
9
9
|
"license": "BSD-2-Clause",
|
|
10
10
|
"main": "lib/index.js",
|
|
@@ -13,94 +13,93 @@
|
|
|
13
13
|
"lib"
|
|
14
14
|
],
|
|
15
15
|
"dependencies": {
|
|
16
|
-
"date-fns": "^
|
|
16
|
+
"date-fns": "^4.1.0",
|
|
17
17
|
"file-saver": "^2.0.5",
|
|
18
|
-
"
|
|
19
|
-
"
|
|
18
|
+
"react-dropzone": "^14.2.3",
|
|
19
|
+
"@comet/admin-icons": "9.0.0-canary-20260121090431"
|
|
20
20
|
},
|
|
21
21
|
"devDependencies": {
|
|
22
|
-
"@apollo/client": "^3.
|
|
23
|
-
"@babel/cli": "^7.
|
|
24
|
-
"@babel/core": "^7.
|
|
25
|
-
"@
|
|
26
|
-
"@
|
|
27
|
-
"@
|
|
28
|
-
"@
|
|
29
|
-
"@
|
|
30
|
-
"@
|
|
31
|
-
"@
|
|
32
|
-
"@
|
|
33
|
-
"@
|
|
34
|
-
"@
|
|
35
|
-
"@mui/
|
|
36
|
-
"@mui/
|
|
37
|
-
"@mui/system": "^5.17.1",
|
|
38
|
-
"@mui/x-data-grid": "^5.17.26",
|
|
22
|
+
"@apollo/client": "^3.14.0",
|
|
23
|
+
"@babel/cli": "^7.28.3",
|
|
24
|
+
"@babel/core": "^7.28.5",
|
|
25
|
+
"@emotion/react": "^11.14.0",
|
|
26
|
+
"@emotion/styled": "^11.14.1",
|
|
27
|
+
"@graphql-codegen/cli": "^5.0.7",
|
|
28
|
+
"@graphql-codegen/named-operations-object": "^3.1.1",
|
|
29
|
+
"@graphql-codegen/near-operation-file-preset": "^3.1.0",
|
|
30
|
+
"@graphql-codegen/typescript": "^4.1.6",
|
|
31
|
+
"@graphql-codegen/typescript-operations": "^4.6.1",
|
|
32
|
+
"@mui/material": "^7.3.5",
|
|
33
|
+
"@mui/system": "^7.3.5",
|
|
34
|
+
"@mui/x-data-grid": "^7.29.12",
|
|
35
|
+
"@mui/x-data-grid-pro": "^7.29.12",
|
|
36
|
+
"@mui/x-date-pickers": "^7.29.4",
|
|
39
37
|
"@types/file-saver": "^2.0.7",
|
|
40
|
-
"@types/
|
|
41
|
-
"@types/react": "^
|
|
42
|
-
"@types/react-dom": "^17.0.0",
|
|
38
|
+
"@types/react": "^18.3.23",
|
|
39
|
+
"@types/react-dom": "^18.3.7",
|
|
43
40
|
"@types/react-router": "^5.1.20",
|
|
44
|
-
"
|
|
45
|
-
"eslint": "^
|
|
41
|
+
"chokidar-cli": "^3.0.0",
|
|
42
|
+
"eslint": "^9.30.1",
|
|
46
43
|
"final-form": "^4.20.10",
|
|
47
|
-
"graphql": "^
|
|
48
|
-
"
|
|
49
|
-
"
|
|
50
|
-
"react": "^17.0",
|
|
44
|
+
"graphql": "^16.0.0",
|
|
45
|
+
"prettier": "^3.4.2",
|
|
46
|
+
"react": "^18.3.1",
|
|
51
47
|
"react-dnd": "^16.0.1",
|
|
52
48
|
"react-dnd-html5-backend": "^16.0.1",
|
|
53
|
-
"react-dom": "^
|
|
54
|
-
"react-final-form": "^6.
|
|
55
|
-
"react-intl": "^
|
|
49
|
+
"react-dom": "^18.3.1",
|
|
50
|
+
"react-final-form": "^6.5.9",
|
|
51
|
+
"react-intl": "^7.1.11",
|
|
56
52
|
"react-router": "^5.3.4",
|
|
57
53
|
"react-router-dom": "^5.3.4",
|
|
58
|
-
"
|
|
59
|
-
"
|
|
54
|
+
"typescript": "5.9.3",
|
|
55
|
+
"@comet/admin": "9.0.0-canary-20260121090431",
|
|
56
|
+
"@comet/admin-babel-preset": "9.0.0-canary-20260121090431",
|
|
57
|
+
"@comet/admin-date-time": "9.0.0-canary-20260121090431",
|
|
58
|
+
"@comet/cms-admin": "9.0.0-canary-20260121090431",
|
|
59
|
+
"@comet/eslint-config": "9.0.0-canary-20260121090431"
|
|
60
60
|
},
|
|
61
61
|
"peerDependencies": {
|
|
62
|
-
"@apollo/client": "^3.
|
|
63
|
-
"@comet/admin": "
|
|
64
|
-
"@comet/admin-date-time": "
|
|
65
|
-
"@comet/admin
|
|
66
|
-
"@
|
|
67
|
-
"@
|
|
68
|
-
"@
|
|
69
|
-
"@
|
|
70
|
-
"@mui/
|
|
71
|
-
"@mui/
|
|
72
|
-
"
|
|
73
|
-
"
|
|
74
|
-
"
|
|
75
|
-
"
|
|
76
|
-
"
|
|
77
|
-
"
|
|
78
|
-
"react": "^
|
|
79
|
-
"react-
|
|
80
|
-
"react-
|
|
81
|
-
"react-dom": "^
|
|
82
|
-
"react-final-form": "^6.3.1",
|
|
83
|
-
"react-intl": "^5.0.0 || ^6.0.0",
|
|
84
|
-
"react-router": "^5.3.4",
|
|
85
|
-
"react-router-dom": "^5.3.4"
|
|
62
|
+
"@apollo/client": "^3.7.0",
|
|
63
|
+
"@comet/admin": "9.0.0-canary-20260121090431",
|
|
64
|
+
"@comet/admin-date-time": "9.0.0-canary-20260121090431",
|
|
65
|
+
"@comet/cms-admin": "9.0.0-canary-20260121090431",
|
|
66
|
+
"@emotion/react": "^11.5.0",
|
|
67
|
+
"@emotion/styled": "^11.3.0",
|
|
68
|
+
"@mui/material": "^7.0.0",
|
|
69
|
+
"@mui/x-data-grid": "^7.0.0",
|
|
70
|
+
"@mui/x-data-grid-pro": "^7.0.0",
|
|
71
|
+
"@mui/x-date-pickers": "^7.0.0",
|
|
72
|
+
"final-form": "^4.0.0",
|
|
73
|
+
"graphql": "^15.0.0 || ^16.0.0",
|
|
74
|
+
"react": "^16.8.0 || ^17.0.0 || ^18.0.0",
|
|
75
|
+
"react-dnd": "^16.0.0",
|
|
76
|
+
"react-dnd-html5-backend": "^16.0.0",
|
|
77
|
+
"react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0",
|
|
78
|
+
"react-final-form": "^6.0.0",
|
|
79
|
+
"react-intl": "^5.0.0 || ^6.0.0 || ^7.0.0",
|
|
80
|
+
"react-router": "^5.0.0",
|
|
81
|
+
"react-router-dom": "^5.0.0"
|
|
86
82
|
},
|
|
87
83
|
"publishConfig": {
|
|
88
84
|
"access": "public",
|
|
89
85
|
"registry": "https://registry.npmjs.org"
|
|
90
86
|
},
|
|
91
87
|
"scripts": {
|
|
92
|
-
"build": "
|
|
93
|
-
"build:babel": "
|
|
94
|
-
"build:types": "tsc --project ./tsconfig.json --emitDeclarationOnly",
|
|
95
|
-
"clean": "rimraf lib",
|
|
96
|
-
"generate-
|
|
97
|
-
"generate-
|
|
98
|
-
"
|
|
99
|
-
"
|
|
100
|
-
"lint
|
|
88
|
+
"build": "pnpm run clean && run-p gql:types generate-block-types && run-p build:babel build:types",
|
|
89
|
+
"build:babel": "pnpm exec babel ./src -x \".ts,.tsx\" -d lib",
|
|
90
|
+
"build:types": "tsc --project ./tsconfig.build.json --emitDeclarationOnly",
|
|
91
|
+
"clean": "rimraf lib 'src/**/*.generated.ts'",
|
|
92
|
+
"generate-block-types": "comet generate-block-types --inputs",
|
|
93
|
+
"generate-block-types:watch": "chokidar -s \"block-meta.json\" -c \"pnpm generate-block-types\"",
|
|
94
|
+
"gql:types": "graphql-codegen",
|
|
95
|
+
"gql:watch": "pnpm graphql-codegen --watch",
|
|
96
|
+
"lint": "run-p gql:types generate-block-types && run-p lint:prettier lint:eslint lint:tsc",
|
|
97
|
+
"lint:ci": "pnpm run lint",
|
|
98
|
+
"lint:eslint": "eslint --max-warnings 0 src/ **/*.json --no-warn-ignored",
|
|
99
|
+
"lint:prettier": "pnpm exec prettier --check './**/*.{js,json,md,yml,yaml}'",
|
|
101
100
|
"lint:tsc": "tsc --noEmit",
|
|
102
|
-
"start": "run-p generate-
|
|
103
|
-
"start:babel": "
|
|
101
|
+
"start": "run-p gql:types generate-block-types && run-p start:babel start:types",
|
|
102
|
+
"start:babel": "pnpm exec babel ./src -x \".ts,.tsx\" -d lib -w",
|
|
104
103
|
"start:types": "tsc --project ./tsconfig.json --emitDeclarationOnly --watch --preserveWatchOutput"
|
|
105
104
|
}
|
|
106
105
|
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { Button, ChipProps, Divider, MenuItem, MenuProps, TypographyProps } from "@mui/material";
|
|
2
|
-
import { Maybe } from "graphql/jsutils/Maybe";
|
|
3
|
-
import * as React from "react";
|
|
4
|
-
export interface ActionItem extends React.ComponentProps<typeof MenuItem> {
|
|
5
|
-
type: "action";
|
|
6
|
-
label: React.ReactNode;
|
|
7
|
-
startAdornment?: React.ReactNode;
|
|
8
|
-
}
|
|
9
|
-
export interface DividerItem extends React.ComponentProps<typeof Divider> {
|
|
10
|
-
type: "divider";
|
|
11
|
-
}
|
|
12
|
-
export type CrudMoreActionsItem = ActionItem | DividerItem;
|
|
13
|
-
export interface CrudMoreActionsMenuProps {
|
|
14
|
-
selectionSize?: number;
|
|
15
|
-
buttonProps?: React.ComponentProps<typeof Button>;
|
|
16
|
-
menuProps?: Partial<MenuProps>;
|
|
17
|
-
chipProps?: Partial<ChipProps>;
|
|
18
|
-
groupTypographyProps?: Partial<TypographyProps>;
|
|
19
|
-
overallItems?: Maybe<CrudMoreActionsItem>[];
|
|
20
|
-
selectiveItems?: Maybe<CrudMoreActionsItem>[];
|
|
21
|
-
}
|
|
22
|
-
export declare function CrudMoreActionsMenu({ overallItems, selectiveItems, buttonProps, menuProps, chipProps, groupTypographyProps, selectionSize, }: CrudMoreActionsMenuProps): React.JSX.Element;
|
|
23
|
-
//# sourceMappingURL=CrudMoreActionsMenu.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"CrudMoreActionsMenu.d.ts","sourceRoot":"","sources":["../../src/temp/CrudMoreActionsMenu.tsx"],"names":[],"mappings":"AAIA,OAAO,EACH,MAAM,EAEN,SAAS,EACT,OAAO,EAKP,QAAQ,EAGR,SAAS,EAET,eAAe,EAClB,MAAM,eAAe,CAAC;AACvB,OAAO,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AAC9C,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAyB/B,MAAM,WAAW,UAAW,SAAQ,KAAK,CAAC,cAAc,CAAC,OAAO,QAAQ,CAAC;IACrE,IAAI,EAAE,QAAQ,CAAC;IACf,KAAK,EAAE,KAAK,CAAC,SAAS,CAAC;IACvB,cAAc,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CACpC;AAED,MAAM,WAAW,WAAY,SAAQ,KAAK,CAAC,cAAc,CAAC,OAAO,OAAO,CAAC;IACrE,IAAI,EAAE,SAAS,CAAC;CACnB;AAED,MAAM,MAAM,mBAAmB,GAAG,UAAU,GAAG,WAAW,CAAC;AAE3D,MAAM,WAAW,wBAAwB;IACrC,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,WAAW,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,OAAO,MAAM,CAAC,CAAC;IAClD,SAAS,CAAC,EAAE,OAAO,CAAC,SAAS,CAAC,CAAC;IAC/B,SAAS,CAAC,EAAE,OAAO,CAAC,SAAS,CAAC,CAAC;IAC/B,oBAAoB,CAAC,EAAE,OAAO,CAAC,eAAe,CAAC,CAAC;IAChD,YAAY,CAAC,EAAE,KAAK,CAAC,mBAAmB,CAAC,EAAE,CAAC;IAC5C,cAAc,CAAC,EAAE,KAAK,CAAC,mBAAmB,CAAC,EAAE,CAAC;CACjD;AAcD,wBAAgB,mBAAmB,CAAC,EAChC,YAAY,EACZ,cAAc,EACd,WAAW,EACX,SAAS,EACT,SAAS,EACT,oBAAoB,EACpB,aAAa,GAChB,EAAE,wBAAwB,qBA0G1B"}
|
|
@@ -1,208 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.CrudMoreActionsMenu = CrudMoreActionsMenu;
|
|
7
|
-
var _adminIcons = require("@comet/admin-icons");
|
|
8
|
-
var _material = require("@mui/material");
|
|
9
|
-
var _react = _interopRequireWildcard(require("react"));
|
|
10
|
-
var React = _react;
|
|
11
|
-
var _reactIntl = require("react-intl");
|
|
12
|
-
var _jsxRuntime = require("react/jsx-runtime");
|
|
13
|
-
var _excluded = ["label"],
|
|
14
|
-
_excluded2 = ["label", "startAdornment", "onClick"],
|
|
15
|
-
_excluded3 = ["label", "startAdornment", "onClick"];
|
|
16
|
-
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); }
|
|
17
|
-
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; }
|
|
18
|
-
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); }
|
|
19
|
-
function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }
|
|
20
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
21
|
-
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; } }
|
|
22
|
-
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; }
|
|
23
|
-
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t["return"] && (u = t["return"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
24
|
-
function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
25
|
-
function _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var s = Object.getOwnPropertySymbols(e); for (r = 0; r < s.length; r++) o = s[r], t.includes(o) || {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } return i; }
|
|
26
|
-
function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (e.includes(n)) continue; t[n] = r[n]; } return t; }
|
|
27
|
-
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; }
|
|
28
|
-
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; }
|
|
29
|
-
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; }
|
|
30
|
-
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : i + ""; }
|
|
31
|
-
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); } // temporary copy from https://github.com/vivid-planet/comet/pull/2115/files
|
|
32
|
-
// remove as soon as it's available in COMET
|
|
33
|
-
function CrudMoreActionsDivider(props) {
|
|
34
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Divider, _objectSpread({
|
|
35
|
-
sx: {
|
|
36
|
-
margin: "8px 10px",
|
|
37
|
-
borderColor: function borderColor(theme) {
|
|
38
|
-
return theme.palette.grey[50];
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
}, props));
|
|
42
|
-
}
|
|
43
|
-
function CrudMoreActionsGroup(_ref) {
|
|
44
|
-
var groupTitle = _ref.groupTitle,
|
|
45
|
-
children = _ref.children,
|
|
46
|
-
menuListProps = _ref.menuListProps,
|
|
47
|
-
typographyProps = _ref.typographyProps;
|
|
48
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
49
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Typography, _objectSpread(_objectSpread({
|
|
50
|
-
variant: "subtitle2",
|
|
51
|
-
color: function color(theme) {
|
|
52
|
-
return theme.palette.grey[500];
|
|
53
|
-
},
|
|
54
|
-
fontWeight: "bold",
|
|
55
|
-
pt: "20px",
|
|
56
|
-
px: "15px"
|
|
57
|
-
}, typographyProps), {}, {
|
|
58
|
-
children: groupTitle
|
|
59
|
-
})), /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.MenuList, _objectSpread(_objectSpread({}, menuListProps), {}, {
|
|
60
|
-
children: children
|
|
61
|
-
}))]
|
|
62
|
-
});
|
|
63
|
-
}
|
|
64
|
-
function SelectedItemsChip(_ref2) {
|
|
65
|
-
var label = _ref2.label,
|
|
66
|
-
restProps = _objectWithoutProperties(_ref2, _excluded);
|
|
67
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.Chip, _objectSpread(_objectSpread({
|
|
68
|
-
size: "small",
|
|
69
|
-
color: "primary",
|
|
70
|
-
sx: {
|
|
71
|
-
width: 20,
|
|
72
|
-
height: 20,
|
|
73
|
-
flexShrink: 0,
|
|
74
|
-
borderRadius: 20,
|
|
75
|
-
marginLeft: 1
|
|
76
|
-
}
|
|
77
|
-
}, restProps), {}, {
|
|
78
|
-
label: label
|
|
79
|
-
}));
|
|
80
|
-
}
|
|
81
|
-
function CrudMoreActionsMenu(_ref3) {
|
|
82
|
-
var overallItems = _ref3.overallItems,
|
|
83
|
-
selectiveItems = _ref3.selectiveItems,
|
|
84
|
-
buttonProps = _ref3.buttonProps,
|
|
85
|
-
menuProps = _ref3.menuProps,
|
|
86
|
-
chipProps = _ref3.chipProps,
|
|
87
|
-
groupTypographyProps = _ref3.groupTypographyProps,
|
|
88
|
-
selectionSize = _ref3.selectionSize;
|
|
89
|
-
var _React$useState = React.useState(null),
|
|
90
|
-
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
91
|
-
anchorEl = _React$useState2[0],
|
|
92
|
-
setAnchorEl = _React$useState2[1];
|
|
93
|
-
var handleClick = function handleClick(event) {
|
|
94
|
-
return setAnchorEl(event.currentTarget);
|
|
95
|
-
};
|
|
96
|
-
var handleClose = function handleClose() {
|
|
97
|
-
return setAnchorEl(null);
|
|
98
|
-
};
|
|
99
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_jsxRuntime.Fragment, {
|
|
100
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(_material.Button, _objectSpread(_objectSpread({
|
|
101
|
-
variant: "text",
|
|
102
|
-
color: "inherit",
|
|
103
|
-
endIcon: /*#__PURE__*/(0, _jsxRuntime.jsx)(_adminIcons.MoreVertical, {}),
|
|
104
|
-
sx: {
|
|
105
|
-
mx: 2
|
|
106
|
-
}
|
|
107
|
-
}, buttonProps), {}, {
|
|
108
|
-
onClick: function onClick(event) {
|
|
109
|
-
var _buttonProps$onClick;
|
|
110
|
-
handleClick(event);
|
|
111
|
-
buttonProps === null || buttonProps === void 0 || (_buttonProps$onClick = buttonProps.onClick) === null || _buttonProps$onClick === void 0 || _buttonProps$onClick.call(buttonProps, event);
|
|
112
|
-
},
|
|
113
|
-
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_reactIntl.FormattedMessage, {
|
|
114
|
-
id: "comet.pages.dam.moreActions",
|
|
115
|
-
defaultMessage: "More actions"
|
|
116
|
-
}), !!selectionSize && /*#__PURE__*/(0, _jsxRuntime.jsx)(SelectedItemsChip, _objectSpread(_objectSpread({}, chipProps), {}, {
|
|
117
|
-
label: selectionSize
|
|
118
|
-
}))]
|
|
119
|
-
})), /*#__PURE__*/(0, _jsxRuntime.jsxs)(_material.Menu, _objectSpread(_objectSpread({
|
|
120
|
-
keepMounted: false,
|
|
121
|
-
PaperProps: {
|
|
122
|
-
sx: {
|
|
123
|
-
minWidth: 220,
|
|
124
|
-
borderRadius: "4px"
|
|
125
|
-
}
|
|
126
|
-
},
|
|
127
|
-
open: Boolean(anchorEl),
|
|
128
|
-
anchorEl: anchorEl
|
|
129
|
-
}, menuProps), {}, {
|
|
130
|
-
onClose: function onClose(event, reason) {
|
|
131
|
-
var _menuProps$onClose;
|
|
132
|
-
handleClose();
|
|
133
|
-
menuProps === null || menuProps === void 0 || (_menuProps$onClose = menuProps.onClose) === null || _menuProps$onClose === void 0 || _menuProps$onClose.call(menuProps, event, reason);
|
|
134
|
-
},
|
|
135
|
-
children: [!!(overallItems !== null && overallItems !== void 0 && overallItems.length) && /*#__PURE__*/(0, _jsxRuntime.jsx)(CrudMoreActionsGroup, {
|
|
136
|
-
groupTitle: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactIntl.FormattedMessage, {
|
|
137
|
-
id: "comet.dam.moreActions.overallActions",
|
|
138
|
-
defaultMessage: "Overall actions"
|
|
139
|
-
}),
|
|
140
|
-
typographyProps: groupTypographyProps,
|
|
141
|
-
menuListProps: menuProps === null || menuProps === void 0 ? void 0 : menuProps.MenuListProps,
|
|
142
|
-
children: overallItems.map(function (item, index) {
|
|
143
|
-
if (!item) return null;
|
|
144
|
-
var type = item.type;
|
|
145
|
-
if (type === "action") {
|
|
146
|
-
var label = item.label,
|
|
147
|
-
startAdornment = item.startAdornment,
|
|
148
|
-
_onClick = item.onClick,
|
|
149
|
-
rest = _objectWithoutProperties(item, _excluded2);
|
|
150
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_material.MenuItem, _objectSpread(_objectSpread({
|
|
151
|
-
disabled: !!selectionSize
|
|
152
|
-
}, rest), {}, {
|
|
153
|
-
onClick: function onClick(e) {
|
|
154
|
-
_onClick === null || _onClick === void 0 || _onClick(e);
|
|
155
|
-
handleClose();
|
|
156
|
-
},
|
|
157
|
-
children: [!!startAdornment && /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.ListItemIcon, {
|
|
158
|
-
children: startAdornment
|
|
159
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.ListItemText, {
|
|
160
|
-
primary: label
|
|
161
|
-
})]
|
|
162
|
-
}), index);
|
|
163
|
-
} else if (type === "divider") {
|
|
164
|
-
return /*#__PURE__*/(0, _react.createElement)(CrudMoreActionsDivider, _objectSpread(_objectSpread({}, item), {}, {
|
|
165
|
-
key: index
|
|
166
|
-
}));
|
|
167
|
-
}
|
|
168
|
-
})
|
|
169
|
-
}), !!(overallItems !== null && overallItems !== void 0 && overallItems.length) && !!(selectiveItems !== null && selectiveItems !== void 0 && selectiveItems.length) && /*#__PURE__*/(0, _jsxRuntime.jsx)(CrudMoreActionsDivider, {}), !!(selectiveItems !== null && selectiveItems !== void 0 && selectiveItems.length) && /*#__PURE__*/(0, _jsxRuntime.jsx)(CrudMoreActionsGroup, {
|
|
170
|
-
groupTitle: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactIntl.FormattedMessage, {
|
|
171
|
-
id: "comet.dam.moreActions.selectiveActions",
|
|
172
|
-
defaultMessage: "Selective actions"
|
|
173
|
-
}),
|
|
174
|
-
typographyProps: groupTypographyProps,
|
|
175
|
-
menuListProps: menuProps === null || menuProps === void 0 ? void 0 : menuProps.MenuListProps,
|
|
176
|
-
children: selectiveItems.map(function (item, index) {
|
|
177
|
-
if (!item) return;
|
|
178
|
-
var type = item.type;
|
|
179
|
-
if (type === "action") {
|
|
180
|
-
var label = item.label,
|
|
181
|
-
startAdornment = item.startAdornment,
|
|
182
|
-
_onClick2 = item.onClick,
|
|
183
|
-
rest = _objectWithoutProperties(item, _excluded3);
|
|
184
|
-
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_material.MenuItem, _objectSpread(_objectSpread({
|
|
185
|
-
disabled: !selectionSize
|
|
186
|
-
}, rest), {}, {
|
|
187
|
-
onClick: function onClick(e) {
|
|
188
|
-
_onClick2 === null || _onClick2 === void 0 || _onClick2(e);
|
|
189
|
-
handleClose();
|
|
190
|
-
},
|
|
191
|
-
children: [!!startAdornment && /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.ListItemIcon, {
|
|
192
|
-
children: startAdornment
|
|
193
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_material.ListItemText, {
|
|
194
|
-
primary: label
|
|
195
|
-
}), !!selectionSize && /*#__PURE__*/(0, _jsxRuntime.jsx)(SelectedItemsChip, _objectSpread(_objectSpread({}, chipProps), {}, {
|
|
196
|
-
label: selectionSize
|
|
197
|
-
}))]
|
|
198
|
-
}), index);
|
|
199
|
-
} else if (item.type === "divider") {
|
|
200
|
-
return /*#__PURE__*/(0, _react.createElement)(CrudMoreActionsDivider, _objectSpread(_objectSpread({}, item), {}, {
|
|
201
|
-
key: index
|
|
202
|
-
}));
|
|
203
|
-
}
|
|
204
|
-
})
|
|
205
|
-
})]
|
|
206
|
-
}))]
|
|
207
|
-
});
|
|
208
|
-
}
|