@bigbinary/neeto-team-members-frontend 2.4.9 → 2.4.11
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/README.md +2 -2
- package/dist/index.cjs.js +205 -138
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.esm.js +207 -140
- package/dist/index.esm.js.map +1 -1
- package/package.json +6 -6
- package/types.d.ts +2 -1
package/dist/index.esm.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import React, { createContext, useContext, createElement, isValidElement, cloneElement, useState, useRef, useEffect, useMemo, useCallback } from 'react';
|
|
2
2
|
import { complement, isEmpty, modifyPath, prepend, assocPath, findIndex, propEq, dissocPath, groupBy, is, prop, keys, map, identical, modify, includes, fromPairs, toPairs, filter, isNil, curry, __, trim, toLower, identity, without, append, clamp, mergeLeft, pluck, head, reverse, assoc } from 'ramda';
|
|
3
|
+
import { ExternalLink, MenuHorizontal, Up, Down, Search, Info } from '@bigbinary/neeto-icons';
|
|
3
4
|
import ReactDOM from 'react-dom';
|
|
4
5
|
import axios from 'axios';
|
|
5
6
|
import { Toastr, Tooltip, Button, Typography, Checkbox, Pane, Dropdown, Alert, Input as Input$1, PageLoader, Label, Avatar, Tag, Table as Table$1 } from '@bigbinary/neetoui';
|
|
6
7
|
import { Header as Header$2, Container, MenuBar, SubHeader as SubHeader$1 } from '@bigbinary/neetoui/layouts';
|
|
7
|
-
import { useFormikContext
|
|
8
|
-
import { Input, Textarea, MultiEmailInput, Radio } from '@bigbinary/neetoui/formik';
|
|
8
|
+
import { useFormikContext } from 'formik';
|
|
9
|
+
import { Form, Input, Textarea, MultiEmailInput, Radio } from '@bigbinary/neetoui/formik';
|
|
9
10
|
import * as yup from 'yup';
|
|
10
11
|
import { object, string } from 'yup';
|
|
11
12
|
import classnames from 'classnames';
|
|
12
|
-
import { MenuHorizontal, Up, Down, Search, Info } from '@bigbinary/neeto-icons';
|
|
13
13
|
|
|
14
14
|
function _typeof(obj) {
|
|
15
15
|
"@babel/helpers - typeof";
|
|
@@ -140,9 +140,9 @@ function _toArray(arr) {
|
|
|
140
140
|
return _arrayWithHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableRest();
|
|
141
141
|
}
|
|
142
142
|
|
|
143
|
-
function ownKeys$
|
|
143
|
+
function ownKeys$c(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
|
144
144
|
|
|
145
|
-
function _objectSpread$
|
|
145
|
+
function _objectSpread$c(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$c(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$c(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
146
146
|
|
|
147
147
|
var consoleLogger = {
|
|
148
148
|
type: 'logger',
|
|
@@ -229,7 +229,7 @@ var Logger = function () {
|
|
|
229
229
|
}, {
|
|
230
230
|
key: "create",
|
|
231
231
|
value: function create(moduleName) {
|
|
232
|
-
return new Logger(this.logger, _objectSpread$
|
|
232
|
+
return new Logger(this.logger, _objectSpread$c(_objectSpread$c({}, {
|
|
233
233
|
prefix: "".concat(this.prefix, ":").concat(moduleName, ":")
|
|
234
234
|
}), this.options));
|
|
235
235
|
}
|
|
@@ -3421,9 +3421,9 @@ var unescape = function unescape(text) {
|
|
|
3421
3421
|
return text.replace(matchHtmlEntity, unescapeHtmlEntity);
|
|
3422
3422
|
};
|
|
3423
3423
|
|
|
3424
|
-
function ownKeys$
|
|
3424
|
+
function ownKeys$b(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
|
3425
3425
|
|
|
3426
|
-
function _objectSpread$
|
|
3426
|
+
function _objectSpread$b(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$b(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$b(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
3427
3427
|
var defaultOptions = {
|
|
3428
3428
|
bindI18n: 'languageChanged',
|
|
3429
3429
|
bindI18nStore: '',
|
|
@@ -3438,7 +3438,7 @@ var i18nInstance;
|
|
|
3438
3438
|
var I18nContext = createContext();
|
|
3439
3439
|
function setDefaults() {
|
|
3440
3440
|
var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
3441
|
-
defaultOptions = _objectSpread$
|
|
3441
|
+
defaultOptions = _objectSpread$b(_objectSpread$b({}, defaultOptions), options);
|
|
3442
3442
|
}
|
|
3443
3443
|
function getDefaults() {
|
|
3444
3444
|
return defaultOptions;
|
|
@@ -3565,9 +3565,9 @@ function hasLoadedNamespace(ns, i18n) {
|
|
|
3565
3565
|
var _excluded$2 = ["format"],
|
|
3566
3566
|
_excluded2$2 = ["children", "count", "parent", "i18nKey", "context", "tOptions", "values", "defaults", "components", "ns", "i18n", "t", "shouldUnescape"];
|
|
3567
3567
|
|
|
3568
|
-
function ownKeys$
|
|
3568
|
+
function ownKeys$a(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
|
3569
3569
|
|
|
3570
|
-
function _objectSpread$
|
|
3570
|
+
function _objectSpread$a(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$a(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$a(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
3571
3571
|
|
|
3572
3572
|
function hasChildren(node, checkLength) {
|
|
3573
3573
|
if (!node) return false;
|
|
@@ -3593,7 +3593,7 @@ function getAsArray(data) {
|
|
|
3593
3593
|
}
|
|
3594
3594
|
|
|
3595
3595
|
function mergeProps(source, target) {
|
|
3596
|
-
var newTarget = _objectSpread$
|
|
3596
|
+
var newTarget = _objectSpread$a({}, target);
|
|
3597
3597
|
|
|
3598
3598
|
newTarget.props = Object.assign(source.props, target.props);
|
|
3599
3599
|
return newTarget;
|
|
@@ -3663,7 +3663,7 @@ function renderNodes(children, targetString, i18n, i18nOptions, combinedTOpts, s
|
|
|
3663
3663
|
getData(children);
|
|
3664
3664
|
var ast = c.parse("<0>".concat(targetString, "</0>"));
|
|
3665
3665
|
|
|
3666
|
-
var opts = _objectSpread$
|
|
3666
|
+
var opts = _objectSpread$a(_objectSpread$a({}, data), combinedTOpts);
|
|
3667
3667
|
|
|
3668
3668
|
function renderInner(child, node, rootReactNode) {
|
|
3669
3669
|
var childs = getChildren(child);
|
|
@@ -3673,7 +3673,7 @@ function renderNodes(children, targetString, i18n, i18nOptions, combinedTOpts, s
|
|
|
3673
3673
|
|
|
3674
3674
|
function pushTranslatedJSX(child, inner, mem, i, isVoid) {
|
|
3675
3675
|
if (child.dummy) child.children = inner;
|
|
3676
|
-
mem.push(cloneElement(child, _objectSpread$
|
|
3676
|
+
mem.push(cloneElement(child, _objectSpread$a(_objectSpread$a({}, child.props), {}, {
|
|
3677
3677
|
key: i
|
|
3678
3678
|
}), isVoid ? undefined : inner));
|
|
3679
3679
|
}
|
|
@@ -3705,7 +3705,7 @@ function renderNodes(children, targetString, i18n, i18nOptions, combinedTOpts, s
|
|
|
3705
3705
|
} else if (isEmptyTransWithHTML) {
|
|
3706
3706
|
var _inner = mapAST(reactNodes, node.children, rootReactNode);
|
|
3707
3707
|
|
|
3708
|
-
mem.push(cloneElement(child, _objectSpread$
|
|
3708
|
+
mem.push(cloneElement(child, _objectSpread$a(_objectSpread$a({}, child.props), {}, {
|
|
3709
3709
|
key: i
|
|
3710
3710
|
}), _inner));
|
|
3711
3711
|
} else if (Number.isNaN(parseFloat(node.name))) {
|
|
@@ -3736,11 +3736,11 @@ function renderNodes(children, targetString, i18n, i18nOptions, combinedTOpts, s
|
|
|
3736
3736
|
var content = node.children[0] ? translationContent : null;
|
|
3737
3737
|
if (content) mem.push(content);
|
|
3738
3738
|
} else if (node.children.length === 1 && translationContent) {
|
|
3739
|
-
mem.push(cloneElement(child, _objectSpread$
|
|
3739
|
+
mem.push(cloneElement(child, _objectSpread$a(_objectSpread$a({}, child.props), {}, {
|
|
3740
3740
|
key: i
|
|
3741
3741
|
}), translationContent));
|
|
3742
3742
|
} else {
|
|
3743
|
-
mem.push(cloneElement(child, _objectSpread$
|
|
3743
|
+
mem.push(cloneElement(child, _objectSpread$a(_objectSpread$a({}, child.props), {}, {
|
|
3744
3744
|
key: i
|
|
3745
3745
|
})));
|
|
3746
3746
|
}
|
|
@@ -3803,7 +3803,7 @@ function Trans(_ref) {
|
|
|
3803
3803
|
|
|
3804
3804
|
if (context) tOptions.context = context;
|
|
3805
3805
|
|
|
3806
|
-
var reactI18nextOptions = _objectSpread$
|
|
3806
|
+
var reactI18nextOptions = _objectSpread$a(_objectSpread$a({}, getDefaults()), i18n.options && i18n.options.react);
|
|
3807
3807
|
|
|
3808
3808
|
var namespaces = ns || t.ns || defaultNSFromContext || i18n.options && i18n.options.defaultNS;
|
|
3809
3809
|
namespaces = typeof namespaces === 'string' ? [namespaces] : namespaces || ['translation'];
|
|
@@ -3811,13 +3811,13 @@ function Trans(_ref) {
|
|
|
3811
3811
|
var hashTransKey = reactI18nextOptions.hashTransKey;
|
|
3812
3812
|
var key = i18nKey || (hashTransKey ? hashTransKey(defaultValue) : defaultValue);
|
|
3813
3813
|
var interpolationOverride = values ? tOptions.interpolation : {
|
|
3814
|
-
interpolation: _objectSpread$
|
|
3814
|
+
interpolation: _objectSpread$a(_objectSpread$a({}, tOptions.interpolation), {}, {
|
|
3815
3815
|
prefix: '#$?',
|
|
3816
3816
|
suffix: '?$#'
|
|
3817
3817
|
})
|
|
3818
3818
|
};
|
|
3819
3819
|
|
|
3820
|
-
var combinedTOpts = _objectSpread$
|
|
3820
|
+
var combinedTOpts = _objectSpread$a(_objectSpread$a(_objectSpread$a(_objectSpread$a({}, tOptions), {}, {
|
|
3821
3821
|
count: count
|
|
3822
3822
|
}, values), interpolationOverride), {}, {
|
|
3823
3823
|
defaultValue: defaultValue,
|
|
@@ -3859,9 +3859,9 @@ function _slicedToArray(arr, i) {
|
|
|
3859
3859
|
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
|
|
3860
3860
|
}
|
|
3861
3861
|
|
|
3862
|
-
function ownKeys$
|
|
3862
|
+
function ownKeys$9(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
|
3863
3863
|
|
|
3864
|
-
function _objectSpread$
|
|
3864
|
+
function _objectSpread$9(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys$9(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys$9(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
3865
3865
|
|
|
3866
3866
|
var usePrevious = function usePrevious(value, ignore) {
|
|
3867
3867
|
var ref = useRef();
|
|
@@ -3898,7 +3898,7 @@ function useTranslation(ns) {
|
|
|
3898
3898
|
|
|
3899
3899
|
if (i18n.options.react && i18n.options.react.wait !== undefined) warnOnce('It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.');
|
|
3900
3900
|
|
|
3901
|
-
var i18nOptions = _objectSpread$
|
|
3901
|
+
var i18nOptions = _objectSpread$9(_objectSpread$9(_objectSpread$9({}, getDefaults()), i18n.options.react), props);
|
|
3902
3902
|
|
|
3903
3903
|
var useSuspense = i18nOptions.useSuspense,
|
|
3904
3904
|
keyPrefix = i18nOptions.keyPrefix;
|
|
@@ -4022,9 +4022,11 @@ var common$1 = {
|
|
|
4022
4022
|
var helpers$1 = {
|
|
4023
4023
|
configPermissions: "Configure permissions for the modules.",
|
|
4024
4024
|
enterMultipleEmails: "Please press space, tab or enter key after entering an email address.",
|
|
4025
|
+
moreInfoAboutPermissions: "More information about permissions",
|
|
4025
4026
|
noRolesFound: "No roles found.",
|
|
4026
4027
|
searchRoles: "Search roles",
|
|
4027
|
-
selectedMembersCount: "{{count}} {{metaName}} selected from {{totalCount}}"
|
|
4028
|
+
selectedMembersCount: "{{count}} {{metaName}} selected from {{totalCount}}",
|
|
4029
|
+
visitToKnowMoreAboutPermissions: "Visit to know more about permissions"
|
|
4028
4030
|
};
|
|
4029
4031
|
var metaNames$1 = {
|
|
4030
4032
|
agent_one: "Agent",
|
|
@@ -4117,10 +4119,12 @@ var common = {
|
|
|
4117
4119
|
var helpers = {
|
|
4118
4120
|
configPermissions: "Configurez les autorisations pour les modules.",
|
|
4119
4121
|
enterMultipleEmails: "Veuillez appuyer sur espace, tabulation ou entrée après avoir saisi une adresse e-mail.",
|
|
4122
|
+
moreInfoAboutPermissions: "Plus d'informations sur les autorisations",
|
|
4120
4123
|
noRolesFound: "Aucun rôle trouvé.",
|
|
4121
4124
|
searchRoles: "Rechercher des rôles",
|
|
4122
4125
|
selectedMembersCount_one: "{{count}} {{metaName}} sélectionné parmi {{totalCount}}",
|
|
4123
|
-
selectedMembersCount_other: "{{count}} {{metaName}} sélectionnés parmi {{totalCount}}"
|
|
4126
|
+
selectedMembersCount_other: "{{count}} {{metaName}} sélectionnés parmi {{totalCount}}",
|
|
4127
|
+
visitToKnowMoreAboutPermissions: "Visitez pour en savoir plus sur les autorisations"
|
|
4124
4128
|
};
|
|
4125
4129
|
var metaNames = {
|
|
4126
4130
|
member_one: "Membre",
|
|
@@ -7449,11 +7453,11 @@ const QUERY_KEYS = {
|
|
|
7449
7453
|
PERMISSIONS: "neeto-team-members-permissions"
|
|
7450
7454
|
};
|
|
7451
7455
|
|
|
7452
|
-
function ownKeys$
|
|
7453
|
-
function _objectSpread$
|
|
7456
|
+
function ownKeys$8(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
7457
|
+
function _objectSpread$8(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$8(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$8(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
7454
7458
|
const useFetchPermissions = function () {
|
|
7455
7459
|
let options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
7456
|
-
return useQuery(QUERY_KEYS.PERMISSIONS, permissionsApi.fetch, _objectSpread$
|
|
7460
|
+
return useQuery(QUERY_KEYS.PERMISSIONS, permissionsApi.fetch, _objectSpread$8({
|
|
7457
7461
|
staleTime: DEFAULT_STALE_TIME,
|
|
7458
7462
|
select: response => response.permissions || response.data.permissions
|
|
7459
7463
|
}, options));
|
|
@@ -7475,11 +7479,11 @@ const organizationRolesApi = {
|
|
|
7475
7479
|
const _excluded$1 = ["onSuccess"],
|
|
7476
7480
|
_excluded2$1 = ["onSuccess"],
|
|
7477
7481
|
_excluded3$1 = ["onSuccess"];
|
|
7478
|
-
function ownKeys$
|
|
7479
|
-
function _objectSpread$
|
|
7482
|
+
function ownKeys$7(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
7483
|
+
function _objectSpread$7(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$7(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$7(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
7480
7484
|
const useFetchRoles = function () {
|
|
7481
7485
|
let options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
7482
|
-
return useQuery(QUERY_KEYS.ROLES, organizationRolesApi.fetch, _objectSpread$
|
|
7486
|
+
return useQuery(QUERY_KEYS.ROLES, organizationRolesApi.fetch, _objectSpread$7({
|
|
7483
7487
|
staleTime: DEFAULT_STALE_TIME,
|
|
7484
7488
|
select: response => response.organizationRoles || response.data.organizationRoles
|
|
7485
7489
|
}, options));
|
|
@@ -7487,7 +7491,7 @@ const useFetchRoles = function () {
|
|
|
7487
7491
|
const useCreateRole = _ref => {
|
|
7488
7492
|
let onSuccess = _ref.onSuccess,
|
|
7489
7493
|
options = _objectWithoutProperties(_ref, _excluded$1);
|
|
7490
|
-
return useMutation(organizationRolesApi.create, _objectSpread$
|
|
7494
|
+
return useMutation(organizationRolesApi.create, _objectSpread$7({
|
|
7491
7495
|
onSuccess: response => {
|
|
7492
7496
|
queryClient.setQueriesData(QUERY_KEYS.ROLES, cachedData => {
|
|
7493
7497
|
if (!!cachedData.data && !!cachedData.data.organizationRoles) {
|
|
@@ -7507,7 +7511,7 @@ const useUpdateRole = _ref2 => {
|
|
|
7507
7511
|
let id = _ref3.id,
|
|
7508
7512
|
payload = _ref3.payload;
|
|
7509
7513
|
return organizationRolesApi.update(id, payload);
|
|
7510
|
-
}, _objectSpread$
|
|
7514
|
+
}, _objectSpread$7({
|
|
7511
7515
|
onSuccess: response => {
|
|
7512
7516
|
queryClient.invalidateQueries(QUERY_KEYS.TEAMS);
|
|
7513
7517
|
queryClient.setQueriesData(QUERY_KEYS.ROLES, cachedData => {
|
|
@@ -7529,7 +7533,7 @@ const useDestroyRole = _ref4 => {
|
|
|
7529
7533
|
let id = _ref5.id,
|
|
7530
7534
|
payload = _ref5.payload;
|
|
7531
7535
|
return organizationRolesApi.destroy(id, payload);
|
|
7532
|
-
}, _objectSpread$
|
|
7536
|
+
}, _objectSpread$7({
|
|
7533
7537
|
onSuccess: response => {
|
|
7534
7538
|
queryClient.setQueriesData(QUERY_KEYS.ROLES, cachedData => {
|
|
7535
7539
|
if (!!cachedData.data && !!cachedData.data.organizationRoles) {
|
|
@@ -8928,9 +8932,9 @@ const renderSearchProps = (searchString, setSearchString) => ({
|
|
|
8928
8932
|
}),
|
|
8929
8933
|
value: searchString
|
|
8930
8934
|
});
|
|
8931
|
-
const renderBreadcrumbs =
|
|
8935
|
+
const renderBreadcrumbs = breadcrumbs => breadcrumbs !== null && breadcrumbs !== void 0 ? breadcrumbs : [{
|
|
8932
8936
|
text: instance.t("metaNames.member", PLURAL),
|
|
8933
|
-
link:
|
|
8937
|
+
link: "/members"
|
|
8934
8938
|
}];
|
|
8935
8939
|
|
|
8936
8940
|
const AddRoleButton = _ref => {
|
|
@@ -8962,8 +8966,18 @@ const Header$1 = _ref => {
|
|
|
8962
8966
|
const _useTranslation = useTranslation(),
|
|
8963
8967
|
t = _useTranslation.t;
|
|
8964
8968
|
return /*#__PURE__*/React.createElement(Header$2, {
|
|
8965
|
-
title:
|
|
8966
|
-
|
|
8969
|
+
title: /*#__PURE__*/React.createElement("span", {
|
|
8970
|
+
className: "neeto-ui-flex neeto-ui-items-center neeto-ui-gap-6"
|
|
8971
|
+
}, t("common.role", PLURAL), (config === null || config === void 0 ? void 0 : config.helpUrl) && /*#__PURE__*/React.createElement(Button, {
|
|
8972
|
+
"data-cy": "ntm-roles-permission-more-info-button",
|
|
8973
|
+
className: "neeto-ui-mt-1",
|
|
8974
|
+
href: config === null || config === void 0 ? void 0 : config.helpUrl,
|
|
8975
|
+
icon: ExternalLink,
|
|
8976
|
+
label: t("helpers.moreInfoAboutPermissions"),
|
|
8977
|
+
style: "link",
|
|
8978
|
+
target: "_blank"
|
|
8979
|
+
})),
|
|
8980
|
+
breadcrumbs: renderBreadcrumbs(config === null || config === void 0 ? void 0 : (_config$header = config.header) === null || _config$header === void 0 ? void 0 : _config$header.breadcrumbs),
|
|
8967
8981
|
searchProps: renderSearchProps(searchString, setSearchString),
|
|
8968
8982
|
actionBlock: /*#__PURE__*/React.createElement(AddRoleButton, {
|
|
8969
8983
|
onClick: () => setIsNewRolePaneOpen(true),
|
|
@@ -9043,6 +9057,12 @@ const ADD_ROLE_FORM_VALIDATION_SCHEMA = object({
|
|
|
9043
9057
|
limit: 255
|
|
9044
9058
|
}))
|
|
9045
9059
|
});
|
|
9060
|
+
const ROLE_FORMIK_PROPS = {
|
|
9061
|
+
initialValues: ADD_ROLE_FORM_INITIAL_VALUES,
|
|
9062
|
+
validateOnBlur: false,
|
|
9063
|
+
validateOnChange: false,
|
|
9064
|
+
validationSchema: ADD_ROLE_FORM_VALIDATION_SCHEMA
|
|
9065
|
+
};
|
|
9046
9066
|
|
|
9047
9067
|
const Permissions = _ref => {
|
|
9048
9068
|
let permissions = _ref.permissions;
|
|
@@ -9099,8 +9119,8 @@ const Permissions = _ref => {
|
|
|
9099
9119
|
}))));
|
|
9100
9120
|
};
|
|
9101
9121
|
|
|
9102
|
-
function ownKeys$
|
|
9103
|
-
function _objectSpread$
|
|
9122
|
+
function ownKeys$6(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
9123
|
+
function _objectSpread$6(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$6(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$6(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
9104
9124
|
const New = _ref => {
|
|
9105
9125
|
let isOpen = _ref.isOpen,
|
|
9106
9126
|
onClose = _ref.onClose,
|
|
@@ -9114,7 +9134,7 @@ const New = _ref => {
|
|
|
9114
9134
|
createRole = _useCreateRole.mutate,
|
|
9115
9135
|
isSubmitting = _useCreateRole.isLoading;
|
|
9116
9136
|
const handleFormSubmit = formValues => {
|
|
9117
|
-
const modifiedFormValues = _objectSpread$
|
|
9137
|
+
const modifiedFormValues = _objectSpread$6(_objectSpread$6({}, formValues), {}, {
|
|
9118
9138
|
description: formValues.description.trim()
|
|
9119
9139
|
});
|
|
9120
9140
|
createRole({
|
|
@@ -9129,18 +9149,14 @@ const New = _ref => {
|
|
|
9129
9149
|
style: "h2"
|
|
9130
9150
|
}, t("common.add_", {
|
|
9131
9151
|
what: t("common.role", SINGULAR).toLocaleLowerCase()
|
|
9132
|
-
}))), /*#__PURE__*/React.createElement(
|
|
9133
|
-
|
|
9134
|
-
|
|
9135
|
-
|
|
9136
|
-
|
|
9137
|
-
validationSchema: ADD_ROLE_FORM_VALIDATION_SCHEMA
|
|
9152
|
+
}))), /*#__PURE__*/React.createElement(Form, {
|
|
9153
|
+
formikProps: _objectSpread$6(_objectSpread$6({}, ROLE_FORMIK_PROPS), {}, {
|
|
9154
|
+
onSubmit: handleFormSubmit
|
|
9155
|
+
}),
|
|
9156
|
+
ref: formReference
|
|
9138
9157
|
}, _ref2 => {
|
|
9139
9158
|
let dirty = _ref2.dirty;
|
|
9140
|
-
return /*#__PURE__*/React.createElement(
|
|
9141
|
-
ref: formReference,
|
|
9142
|
-
noValidate: true
|
|
9143
|
-
}, /*#__PURE__*/React.createElement(ScrollToErrorField, {
|
|
9159
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(ScrollToErrorField, {
|
|
9144
9160
|
formRef: formReference
|
|
9145
9161
|
}), /*#__PURE__*/React.createElement(Pane.Body, null, /*#__PURE__*/React.createElement("div", {
|
|
9146
9162
|
className: "ntm-roles-pane__body"
|
|
@@ -9428,8 +9444,7 @@ const TableHeader = _ref => {
|
|
|
9428
9444
|
isDelete: true,
|
|
9429
9445
|
selectedRole: role
|
|
9430
9446
|
}),
|
|
9431
|
-
size: "small"
|
|
9432
|
-
style: "danger"
|
|
9447
|
+
size: "small"
|
|
9433
9448
|
}, t("common.delete"))))))));
|
|
9434
9449
|
})));
|
|
9435
9450
|
};
|
|
@@ -9473,8 +9488,8 @@ const Delete = _ref => {
|
|
|
9473
9488
|
});
|
|
9474
9489
|
};
|
|
9475
9490
|
|
|
9476
|
-
function ownKeys$
|
|
9477
|
-
function _objectSpread$
|
|
9491
|
+
function ownKeys$5(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
9492
|
+
function _objectSpread$5(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$5(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$5(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
9478
9493
|
const Edit = _ref => {
|
|
9479
9494
|
let isOpen = _ref.isOpen,
|
|
9480
9495
|
onClose = _ref.onClose,
|
|
@@ -9493,7 +9508,7 @@ const Edit = _ref => {
|
|
|
9493
9508
|
};
|
|
9494
9509
|
const handleFormSubmit = formValues => {
|
|
9495
9510
|
const payload = {
|
|
9496
|
-
organizationRole: _objectSpread$
|
|
9511
|
+
organizationRole: _objectSpread$5(_objectSpread$5(_objectSpread$5({}, selectedRole), formValues), {}, {
|
|
9497
9512
|
description: formValues.description.trim()
|
|
9498
9513
|
})
|
|
9499
9514
|
};
|
|
@@ -9510,18 +9525,15 @@ const Edit = _ref => {
|
|
|
9510
9525
|
style: "h2"
|
|
9511
9526
|
}, t("common.update_", {
|
|
9512
9527
|
what: t("common.role", SINGULAR).toLocaleLowerCase()
|
|
9513
|
-
}))), /*#__PURE__*/React.createElement(
|
|
9514
|
-
|
|
9515
|
-
|
|
9516
|
-
|
|
9517
|
-
|
|
9518
|
-
|
|
9528
|
+
}))), /*#__PURE__*/React.createElement(Form, {
|
|
9529
|
+
formikProps: _objectSpread$5(_objectSpread$5({}, ROLE_FORMIK_PROPS), {}, {
|
|
9530
|
+
initialValues,
|
|
9531
|
+
onSubmit: handleFormSubmit
|
|
9532
|
+
}),
|
|
9533
|
+
ref: formReference
|
|
9519
9534
|
}, _ref2 => {
|
|
9520
9535
|
let dirty = _ref2.dirty;
|
|
9521
|
-
return /*#__PURE__*/React.createElement(
|
|
9522
|
-
ref: formReference,
|
|
9523
|
-
noValidate: true
|
|
9524
|
-
}, /*#__PURE__*/React.createElement(ScrollToErrorField, {
|
|
9536
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(ScrollToErrorField, {
|
|
9525
9537
|
formRef: formReference
|
|
9526
9538
|
}), /*#__PURE__*/React.createElement(Pane.Body, null, /*#__PURE__*/React.createElement("div", {
|
|
9527
9539
|
className: "ntm-roles-pane__body"
|
|
@@ -9755,6 +9767,8 @@ const Table = _ref => {
|
|
|
9755
9767
|
const Roles = _ref => {
|
|
9756
9768
|
var _config$permissions$v, _config$permissions, _config$permissions$v2, _config$permissions2;
|
|
9757
9769
|
let config = _ref.config;
|
|
9770
|
+
const _useTranslation = useTranslation(),
|
|
9771
|
+
t = _useTranslation.t;
|
|
9758
9772
|
const _useState = useState(""),
|
|
9759
9773
|
_useState2 = _slicedToArray(_useState, 2),
|
|
9760
9774
|
searchString = _useState2[0],
|
|
@@ -9803,17 +9817,21 @@ const Roles = _ref => {
|
|
|
9803
9817
|
permissionGroups: permissionGroups,
|
|
9804
9818
|
roles: roles,
|
|
9805
9819
|
setIsNewRolePaneOpen: setIsNewRolePaneOpen
|
|
9806
|
-
})
|
|
9820
|
+
}), (config === null || config === void 0 ? void 0 : config.helpUrl) && /*#__PURE__*/React.createElement("div", {
|
|
9821
|
+
className: "ntm-roles-help-url-wrapper"
|
|
9822
|
+
}, /*#__PURE__*/React.createElement(Button, {
|
|
9823
|
+
"data-cy": "ntm-roles-permission-more-info-button",
|
|
9824
|
+
href: config.helpUrl,
|
|
9825
|
+
icon: ExternalLink,
|
|
9826
|
+
label: t("helpers.visitToKnowMoreAboutPermissions"),
|
|
9827
|
+
style: "link",
|
|
9828
|
+
target: "_blank"
|
|
9829
|
+
})))), /*#__PURE__*/React.createElement(New, {
|
|
9807
9830
|
isOpen: isNewRolePaneOpen,
|
|
9808
9831
|
onClose: () => setIsNewRolePaneOpen(false),
|
|
9809
9832
|
permissions: permissions
|
|
9810
9833
|
}));
|
|
9811
9834
|
};
|
|
9812
|
-
Roles.defaultProps = {
|
|
9813
|
-
config: {
|
|
9814
|
-
membersPageUrl: "/members"
|
|
9815
|
-
}
|
|
9816
|
-
};
|
|
9817
9835
|
var index$1 = withReactQuery(Roles);
|
|
9818
9836
|
|
|
9819
9837
|
const fetch = params => axios.get(`${BASE_URL}/teams`, {
|
|
@@ -9832,12 +9850,12 @@ const teamsApi = {
|
|
|
9832
9850
|
const _excluded = ["onSuccess"],
|
|
9833
9851
|
_excluded2 = ["onSuccess"],
|
|
9834
9852
|
_excluded3 = ["onSuccess"];
|
|
9835
|
-
function ownKeys$
|
|
9836
|
-
function _objectSpread$
|
|
9853
|
+
function ownKeys$4(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
9854
|
+
function _objectSpread$4(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$4(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$4(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
9837
9855
|
const useFetchMembers = function () {
|
|
9838
9856
|
let params = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
9839
9857
|
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};
|
|
9840
|
-
return useQuery([QUERY_KEYS.TEAMS, params], () => teamsApi.fetch(params), _objectSpread$
|
|
9858
|
+
return useQuery([QUERY_KEYS.TEAMS, params], () => teamsApi.fetch(params), _objectSpread$4({
|
|
9841
9859
|
staleTime: DEFAULT_STALE_TIME,
|
|
9842
9860
|
select: response => response.data || response,
|
|
9843
9861
|
keepPreviousData: true
|
|
@@ -9846,7 +9864,7 @@ const useFetchMembers = function () {
|
|
|
9846
9864
|
const useCreateMember = _ref => {
|
|
9847
9865
|
let onSuccess = _ref.onSuccess,
|
|
9848
9866
|
options = _objectWithoutProperties(_ref, _excluded);
|
|
9849
|
-
return useMutation(teamsApi.create, _objectSpread$
|
|
9867
|
+
return useMutation(teamsApi.create, _objectSpread$4({
|
|
9850
9868
|
onSuccess: response => {
|
|
9851
9869
|
queryClient.invalidateQueries(QUERY_KEYS.TEAMS);
|
|
9852
9870
|
Toastr.success(response.ntmNotice || response.data.ntmNotice);
|
|
@@ -9861,7 +9879,7 @@ const useUpdateMember = _ref2 => {
|
|
|
9861
9879
|
let id = _ref3.id,
|
|
9862
9880
|
payload = _ref3.payload;
|
|
9863
9881
|
return teamsApi.update(id, payload);
|
|
9864
|
-
}, _objectSpread$
|
|
9882
|
+
}, _objectSpread$4({
|
|
9865
9883
|
onSuccess: response => {
|
|
9866
9884
|
queryClient.invalidateQueries(QUERY_KEYS.TEAMS);
|
|
9867
9885
|
Toastr.success(response.ntmNotice || response.data.ntmNotice);
|
|
@@ -9872,7 +9890,7 @@ const useUpdateMember = _ref2 => {
|
|
|
9872
9890
|
const useBulkUpdateMembers = _ref4 => {
|
|
9873
9891
|
let onSuccess = _ref4.onSuccess,
|
|
9874
9892
|
options = _objectWithoutProperties(_ref4, _excluded3);
|
|
9875
|
-
return useMutation(teamsApi.bulkUpdate, _objectSpread$
|
|
9893
|
+
return useMutation(teamsApi.bulkUpdate, _objectSpread$4({
|
|
9876
9894
|
onSuccess: response => {
|
|
9877
9895
|
queryClient.invalidateQueries(QUERY_KEYS.TEAMS);
|
|
9878
9896
|
Toastr.success(response.ntmNotice || response.data.ntmNotice);
|
|
@@ -10070,6 +10088,7 @@ const Menu$1 = Dropdown.Menu,
|
|
|
10070
10088
|
MenuItem = Dropdown.MenuItem;
|
|
10071
10089
|
const RolesDropdown = _ref => {
|
|
10072
10090
|
let handleRoleChange = _ref.handleRoleChange,
|
|
10091
|
+
hasUpdatePermission = _ref.hasUpdatePermission,
|
|
10073
10092
|
_ref$isSearchable = _ref.isSearchable,
|
|
10074
10093
|
isSearchable = _ref$isSearchable === void 0 ? false : _ref$isSearchable,
|
|
10075
10094
|
_ref$roles = _ref.roles,
|
|
@@ -10095,11 +10114,16 @@ const RolesDropdown = _ref => {
|
|
|
10095
10114
|
setSearchTerm("");
|
|
10096
10115
|
setIsDropdownOpen(false);
|
|
10097
10116
|
};
|
|
10098
|
-
return /*#__PURE__*/React.createElement(
|
|
10117
|
+
return /*#__PURE__*/React.createElement(Tooltip, {
|
|
10118
|
+
content: instance.t("tooltips.noPermissionToEditMembers"),
|
|
10119
|
+
disabled: hasUpdatePermission,
|
|
10120
|
+
position: "top"
|
|
10121
|
+
}, /*#__PURE__*/React.createElement("span", null, /*#__PURE__*/React.createElement(Dropdown, {
|
|
10099
10122
|
buttonSize: "small",
|
|
10100
10123
|
buttonStyle: "secondary",
|
|
10101
10124
|
closeOnSelect: false,
|
|
10102
10125
|
"data-cy": "ntm-members-roles-update-dropdown",
|
|
10126
|
+
disabled: !hasUpdatePermission,
|
|
10103
10127
|
label: instance.t("buttons.changeRole"),
|
|
10104
10128
|
isOpen: isDropdownOpen,
|
|
10105
10129
|
onClick: () => setIsDropdownOpen(true),
|
|
@@ -10122,7 +10146,7 @@ const RolesDropdown = _ref => {
|
|
|
10122
10146
|
}, name);
|
|
10123
10147
|
}) : /*#__PURE__*/React.createElement("span", {
|
|
10124
10148
|
className: "neeto-ui-flex neeto-ui-flex-col neeto-ui-items-center neeto-ui-p-2"
|
|
10125
|
-
}, instance.t("helpers.noRolesFound")))));
|
|
10149
|
+
}, instance.t("helpers.noRolesFound")))))));
|
|
10126
10150
|
};
|
|
10127
10151
|
|
|
10128
10152
|
var _URLSearchParams$get;
|
|
@@ -10198,13 +10222,16 @@ const Left = _ref => {
|
|
|
10198
10222
|
}) : `${filteredCount} ${pluralizedByFilterCount}`);
|
|
10199
10223
|
};
|
|
10200
10224
|
const Right = _ref2 => {
|
|
10225
|
+
var _config$permissions$u, _config$permissions;
|
|
10201
10226
|
let columns = _ref2.columns,
|
|
10227
|
+
config = _ref2.config,
|
|
10202
10228
|
roles = _ref2.roles,
|
|
10203
10229
|
rolesButtonProps = _ref2.rolesButtonProps,
|
|
10204
10230
|
selectedRows = _ref2.selectedRows,
|
|
10205
10231
|
setColumnData = _ref2.setColumnData,
|
|
10206
10232
|
setSelectedRows = _ref2.setSelectedRows;
|
|
10207
10233
|
const isRolesButtonVisible = !!rolesButtonProps;
|
|
10234
|
+
const hasUpdatePermission = (_config$permissions$u = config === null || config === void 0 ? void 0 : (_config$permissions = config.permissions) === null || _config$permissions === void 0 ? void 0 : _config$permissions.update) !== null && _config$permissions$u !== void 0 ? _config$permissions$u : DEFAULT_PERMISSION;
|
|
10208
10235
|
const _useBulkUpdateMembers = useBulkUpdateMembers({
|
|
10209
10236
|
onSuccess: () => setSelectedRows(DEFAULT_SELECTED_ROWS)
|
|
10210
10237
|
}),
|
|
@@ -10230,20 +10257,31 @@ const Right = _ref2 => {
|
|
|
10230
10257
|
}
|
|
10231
10258
|
});
|
|
10232
10259
|
};
|
|
10233
|
-
return /*#__PURE__*/React.createElement(React.Fragment, null, getDeactivatedButtonVisible(selectedRows) && /*#__PURE__*/React.createElement(
|
|
10260
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, getDeactivatedButtonVisible(selectedRows) && /*#__PURE__*/React.createElement(Tooltip, {
|
|
10261
|
+
content: instance.t("tooltips.noPermissionToEditMembers"),
|
|
10262
|
+
disabled: hasUpdatePermission,
|
|
10263
|
+
position: "top"
|
|
10264
|
+
}, /*#__PURE__*/React.createElement("span", null, /*#__PURE__*/React.createElement(Button, {
|
|
10234
10265
|
"data-cy": "ntm-deactivate-members-button",
|
|
10266
|
+
disabled: !hasUpdatePermission,
|
|
10235
10267
|
label: instance.t("common.deactivate"),
|
|
10236
10268
|
size: "small",
|
|
10237
10269
|
style: "secondary",
|
|
10238
10270
|
onClick: () => handleDeactivateMembers()
|
|
10239
|
-
}), getActivateButtonVisible(selectedRows) && /*#__PURE__*/React.createElement(
|
|
10271
|
+
}))), getActivateButtonVisible(selectedRows) && /*#__PURE__*/React.createElement(Tooltip, {
|
|
10272
|
+
content: instance.t("tooltips.noPermissionToEditMembers"),
|
|
10273
|
+
disabled: hasUpdatePermission,
|
|
10274
|
+
position: "top"
|
|
10275
|
+
}, /*#__PURE__*/React.createElement("span", null, /*#__PURE__*/React.createElement(Button, {
|
|
10240
10276
|
"data-cy": "ntm-activate-members-button",
|
|
10277
|
+
disabled: !hasUpdatePermission,
|
|
10241
10278
|
label: instance.t("common.activate"),
|
|
10242
10279
|
size: "small",
|
|
10243
10280
|
style: "secondary",
|
|
10244
10281
|
onClick: () => handleActivateMembers()
|
|
10245
|
-
}), isNotEmpty$1(selectedRows.keys) && /*#__PURE__*/React.createElement(RolesDropdown, {
|
|
10282
|
+
}))), isNotEmpty$1(selectedRows.keys) && /*#__PURE__*/React.createElement(RolesDropdown, {
|
|
10246
10283
|
handleRoleChange: handleRoleChange,
|
|
10284
|
+
hasUpdatePermission: hasUpdatePermission,
|
|
10247
10285
|
roles: roles
|
|
10248
10286
|
}), /*#__PURE__*/React.createElement(Columns, {
|
|
10249
10287
|
columnData: columns,
|
|
@@ -10774,21 +10812,21 @@ var pluralize$1 = {exports: {}};
|
|
|
10774
10812
|
|
|
10775
10813
|
var pluralize = pluralize$1.exports;
|
|
10776
10814
|
|
|
10777
|
-
function ownKeys$
|
|
10778
|
-
function _objectSpread$
|
|
10815
|
+
function ownKeys$3(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
10816
|
+
function _objectSpread$3(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$3(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$3(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
10779
10817
|
const renderNameColumn = (_ref, diplayStatusTag) => {
|
|
10780
|
-
let
|
|
10818
|
+
let name = _ref.displayName,
|
|
10781
10819
|
imageUrl = _ref.profileImageUrl,
|
|
10782
10820
|
active = _ref.active;
|
|
10783
10821
|
return /*#__PURE__*/React.createElement("div", {
|
|
10784
10822
|
className: "ntm-members-table__column"
|
|
10785
10823
|
}, /*#__PURE__*/React.createElement(Avatar, {
|
|
10786
10824
|
user: {
|
|
10787
|
-
name
|
|
10825
|
+
name,
|
|
10788
10826
|
imageUrl
|
|
10789
10827
|
},
|
|
10790
10828
|
size: "medium"
|
|
10791
|
-
}),
|
|
10829
|
+
}), name, diplayStatusTag && /*#__PURE__*/React.createElement(Tag, {
|
|
10792
10830
|
"data-cy": "ntm-member-status-tag",
|
|
10793
10831
|
label: active ? MEMBER_FILTER.ACTIVE.label : MEMBER_FILTER.DEACTIVATED.label,
|
|
10794
10832
|
style: active ? "primary" : "secondary",
|
|
@@ -10799,7 +10837,7 @@ const isDropDownButtonDisabled = permissions => {
|
|
|
10799
10837
|
var _permissions$update;
|
|
10800
10838
|
return !((_permissions$update = permissions === null || permissions === void 0 ? void 0 : permissions.update) !== null && _permissions$update !== void 0 ? _permissions$update : hasPermission(MANAGE_MEMBER_PERMISSIONS));
|
|
10801
10839
|
};
|
|
10802
|
-
const renderDropdownButton = (_ref2,
|
|
10840
|
+
const renderDropdownButton = (_ref2, handleUpdateRole, handleUpdateStatus, permissions) => {
|
|
10803
10841
|
let displayName = _ref2.displayName,
|
|
10804
10842
|
id = _ref2.id,
|
|
10805
10843
|
active = _ref2.active,
|
|
@@ -10840,8 +10878,7 @@ const renderDropdownButton = (_ref2, handleUpdateStatus, handleUpdateRole, permi
|
|
|
10840
10878
|
name: displayName,
|
|
10841
10879
|
active
|
|
10842
10880
|
}),
|
|
10843
|
-
size: "small"
|
|
10844
|
-
style: active && "danger"
|
|
10881
|
+
size: "small"
|
|
10845
10882
|
}, active ? instance.t("common.deactivate") : instance.t("common.activate"))))));
|
|
10846
10883
|
};
|
|
10847
10884
|
const getDefaultAlertTitle = _ref3 => {
|
|
@@ -10864,37 +10901,60 @@ const getDefaultAlertMessage = _ref4 => {
|
|
|
10864
10901
|
person: member === null || member === void 0 ? void 0 : member.name
|
|
10865
10902
|
});
|
|
10866
10903
|
};
|
|
10904
|
+
const getDefaultColumns = displayStatusTag => [{
|
|
10905
|
+
dataIndex: "name",
|
|
10906
|
+
key: "name",
|
|
10907
|
+
render: (_, tableData) => renderNameColumn(tableData, displayStatusTag),
|
|
10908
|
+
sorter: true,
|
|
10909
|
+
title: instance.t("common.name")
|
|
10910
|
+
}, {
|
|
10911
|
+
dataIndex: "email",
|
|
10912
|
+
key: "email",
|
|
10913
|
+
sorter: true,
|
|
10914
|
+
title: instance.t("common.email", SINGULAR)
|
|
10915
|
+
}, {
|
|
10916
|
+
dataIndex: "role",
|
|
10917
|
+
key: "organization_role",
|
|
10918
|
+
sorter: true,
|
|
10919
|
+
title: instance.t("common.role", SINGULAR)
|
|
10920
|
+
}];
|
|
10921
|
+
const getActionColumn = (handleUpdateRole, handleUpdateStatus, permissions) => ({
|
|
10922
|
+
dataIndex: "actions",
|
|
10923
|
+
key: "icon_button",
|
|
10924
|
+
render: (_, props) => renderDropdownButton(props, handleUpdateRole, handleUpdateStatus, permissions),
|
|
10925
|
+
width: 75
|
|
10926
|
+
});
|
|
10867
10927
|
const getColumnData = _ref5 => {
|
|
10868
|
-
|
|
10869
|
-
|
|
10928
|
+
var _config$otherColumns;
|
|
10929
|
+
let config = _ref5.config,
|
|
10870
10930
|
handleUpdateRole = _ref5.handleUpdateRole,
|
|
10871
|
-
|
|
10872
|
-
|
|
10873
|
-
|
|
10874
|
-
|
|
10875
|
-
|
|
10876
|
-
|
|
10877
|
-
|
|
10878
|
-
|
|
10879
|
-
|
|
10880
|
-
|
|
10881
|
-
|
|
10882
|
-
|
|
10883
|
-
|
|
10884
|
-
|
|
10885
|
-
|
|
10886
|
-
|
|
10887
|
-
|
|
10888
|
-
|
|
10889
|
-
|
|
10890
|
-
|
|
10891
|
-
|
|
10892
|
-
|
|
10893
|
-
dataIndex
|
|
10894
|
-
|
|
10895
|
-
|
|
10896
|
-
|
|
10897
|
-
|
|
10931
|
+
handleUpdateStatus = _ref5.handleUpdateStatus,
|
|
10932
|
+
memberFilter = _ref5.memberFilter;
|
|
10933
|
+
const displayStatusTag = identical(memberFilter, MEMBER_FILTER.ALL.value);
|
|
10934
|
+
const defaultColumns = getDefaultColumns(displayStatusTag);
|
|
10935
|
+
const actionColumn = getActionColumn(handleUpdateRole, handleUpdateStatus, config === null || config === void 0 ? void 0 : config.permissions);
|
|
10936
|
+
const otherColumns = (_config$otherColumns = config === null || config === void 0 ? void 0 : config.otherColumns) !== null && _config$otherColumns !== void 0 ? _config$otherColumns : [];
|
|
10937
|
+
const columns = defaultColumns.map(column => {
|
|
10938
|
+
const otherColumn = otherColumns.find(_ref6 => {
|
|
10939
|
+
let dataIndex = _ref6.dataIndex;
|
|
10940
|
+
return identical(dataIndex, column.dataIndex);
|
|
10941
|
+
});
|
|
10942
|
+
return otherColumn || column;
|
|
10943
|
+
});
|
|
10944
|
+
otherColumns.forEach(otherColumn => {
|
|
10945
|
+
const column = columns.find(_ref7 => {
|
|
10946
|
+
let dataIndex = _ref7.dataIndex;
|
|
10947
|
+
return identical(dataIndex, otherColumn.dataIndex);
|
|
10948
|
+
});
|
|
10949
|
+
if (!column) columns.push(otherColumn);
|
|
10950
|
+
});
|
|
10951
|
+
if (!columns.some(_ref8 => {
|
|
10952
|
+
let dataIndex = _ref8.dataIndex;
|
|
10953
|
+
return identical(dataIndex, "actions");
|
|
10954
|
+
})) {
|
|
10955
|
+
columns.push(actionColumn);
|
|
10956
|
+
}
|
|
10957
|
+
return columns;
|
|
10898
10958
|
};
|
|
10899
10959
|
const renderHeaderTitle = (filterStatus, metaName) => instance.t(`common.${toLower(filterStatus)}_`, {
|
|
10900
10960
|
what: metaName(PLURAL).toLocaleLowerCase()
|
|
@@ -10913,7 +10973,7 @@ const renderUpdateAlert = (field, props) => {
|
|
|
10913
10973
|
}
|
|
10914
10974
|
return field === "title" ? getDefaultAlertTitle(props) : getDefaultAlertMessage(props);
|
|
10915
10975
|
};
|
|
10916
|
-
const getSearchParams = (page, filter) => new URLSearchParams(_objectSpread$
|
|
10976
|
+
const getSearchParams = (page, filter) => new URLSearchParams(_objectSpread$3(_objectSpread$3({}, page), {}, {
|
|
10917
10977
|
filter: filter.toLowerCase()
|
|
10918
10978
|
})).toString();
|
|
10919
10979
|
const handlePageChange = (setFilters, filter) => (page, results) => {
|
|
@@ -10935,15 +10995,15 @@ const getMetaName = curry((metaName, count) => {
|
|
|
10935
10995
|
});
|
|
10936
10996
|
const clearSelectedMembers = (previousCategory, currentCategory) => isNotEqual(previousCategory, currentCategory) && isNotEqual(currentCategory, "ALL");
|
|
10937
10997
|
|
|
10938
|
-
function ownKeys$
|
|
10939
|
-
function _objectSpread$
|
|
10998
|
+
function ownKeys$2(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
10999
|
+
function _objectSpread$2(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$2(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$2(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
10940
11000
|
const MULTIPLE_EMAIL_INPUT_VALIDATION_SCHEMA = {
|
|
10941
11001
|
emails: yup.array().min(1, instance.t("validations.minOneEmail")).test("are-all-emails-valid", instance.t("validations.validEmail"), emails => emails.every(prop("valid"))).nullable()
|
|
10942
11002
|
};
|
|
10943
11003
|
const ROLES_RADIO_GROUP_VALIDATION_SCHEMA = {
|
|
10944
11004
|
role: yup.string().required(instance.t("validations.roleRequired"))
|
|
10945
11005
|
};
|
|
10946
|
-
const VALIDATION_SCHEMA$1 = yup.object().shape(_objectSpread$
|
|
11006
|
+
const VALIDATION_SCHEMA$1 = yup.object().shape(_objectSpread$2(_objectSpread$2({}, MULTIPLE_EMAIL_INPUT_VALIDATION_SCHEMA), ROLES_RADIO_GROUP_VALIDATION_SCHEMA));
|
|
10947
11007
|
const FILTER_INVALID_EMAILS = {
|
|
10948
11008
|
label: instance.t("validations.filterInvalidEmails")
|
|
10949
11009
|
};
|
|
@@ -10951,6 +11011,10 @@ const COUNTER_PROPS = {
|
|
|
10951
11011
|
label: instance.t("common.email", PLURAL),
|
|
10952
11012
|
startsFrom: 4
|
|
10953
11013
|
};
|
|
11014
|
+
const MANAGE_MEMBERS_FORMIK_PROPS = {
|
|
11015
|
+
enableReinitialize: true,
|
|
11016
|
+
validationSchema: VALIDATION_SCHEMA$1
|
|
11017
|
+
};
|
|
10954
11018
|
|
|
10955
11019
|
const renderInitialValues = (selectedMember, roles) => {
|
|
10956
11020
|
var _roles$;
|
|
@@ -11043,6 +11107,8 @@ RolesRadioGroup.defaultProps = {
|
|
|
11043
11107
|
roles: []
|
|
11044
11108
|
};
|
|
11045
11109
|
|
|
11110
|
+
function ownKeys$1(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
11111
|
+
function _objectSpread$1(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys$1(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$1(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
11046
11112
|
const ManageMember = _ref => {
|
|
11047
11113
|
var _config$manageMember;
|
|
11048
11114
|
let config = _ref.config,
|
|
@@ -11102,21 +11168,20 @@ const ManageMember = _ref => {
|
|
|
11102
11168
|
what: metaName(SINGULAR).toLocaleLowerCase()
|
|
11103
11169
|
}) : instance.t("common.add_", {
|
|
11104
11170
|
what: metaName(SINGULAR).toLocaleLowerCase()
|
|
11105
|
-
}))), config !== null && config !== void 0 && (_config$manageMember = config.manageMember) !== null && _config$manageMember !== void 0 && _config$manageMember.component ? config.manageMember.component(manageMemberProps) : /*#__PURE__*/React.createElement(
|
|
11106
|
-
|
|
11107
|
-
|
|
11108
|
-
|
|
11109
|
-
|
|
11110
|
-
|
|
11111
|
-
|
|
11171
|
+
}))), config !== null && config !== void 0 && (_config$manageMember = config.manageMember) !== null && _config$manageMember !== void 0 && _config$manageMember.component ? config.manageMember.component(manageMemberProps) : /*#__PURE__*/React.createElement(Form, {
|
|
11172
|
+
ref: formReference,
|
|
11173
|
+
formikProps: _objectSpread$1(_objectSpread$1({}, MANAGE_MEMBERS_FORMIK_PROPS), {}, {
|
|
11174
|
+
initialValues: renderInitialValues(selectedMember, roles),
|
|
11175
|
+
onSubmit: handleAddMember,
|
|
11176
|
+
validateOnBlur: hasSubmitted,
|
|
11177
|
+
validateOnChange: hasSubmitted
|
|
11178
|
+
})
|
|
11112
11179
|
}, _ref2 => {
|
|
11113
11180
|
let values = _ref2.values,
|
|
11114
11181
|
dirty = _ref2.dirty;
|
|
11115
11182
|
const emails = values.emails,
|
|
11116
11183
|
role = values.role;
|
|
11117
|
-
return /*#__PURE__*/React.createElement(
|
|
11118
|
-
ref: formReference
|
|
11119
|
-
}, /*#__PURE__*/React.createElement(ScrollToErrorField, {
|
|
11184
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(ScrollToErrorField, {
|
|
11120
11185
|
formRef: formReference
|
|
11121
11186
|
}), /*#__PURE__*/React.createElement(Pane.Body, null, /*#__PURE__*/React.createElement("div", {
|
|
11122
11187
|
className: "ntm-members-pane__body"
|
|
@@ -11256,11 +11321,11 @@ const TeamMembers = _ref => {
|
|
|
11256
11321
|
setIsOpen(assoc("manageMember", true));
|
|
11257
11322
|
};
|
|
11258
11323
|
const columns = useMemo(() => getColumnData({
|
|
11259
|
-
|
|
11260
|
-
handleUpdateStatus,
|
|
11324
|
+
config,
|
|
11261
11325
|
handleUpdateRole,
|
|
11262
|
-
|
|
11263
|
-
|
|
11326
|
+
handleUpdateStatus,
|
|
11327
|
+
memberFilter: filters.category
|
|
11328
|
+
}), [filters.category] // eslint-disable-line react-hooks/exhaustive-deps
|
|
11264
11329
|
);
|
|
11265
11330
|
|
|
11266
11331
|
const handleAlertClose = () => {
|
|
@@ -11324,6 +11389,7 @@ const TeamMembers = _ref => {
|
|
|
11324
11389
|
}),
|
|
11325
11390
|
rightActionBlock: /*#__PURE__*/React.createElement(SubHeader.Right, {
|
|
11326
11391
|
columns: columns,
|
|
11392
|
+
config: config,
|
|
11327
11393
|
roles: roles,
|
|
11328
11394
|
rolesButtonProps: config.rolesButtonProps,
|
|
11329
11395
|
selectedRows: selectedRows,
|
|
@@ -11354,7 +11420,8 @@ const TeamMembers = _ref => {
|
|
|
11354
11420
|
}),
|
|
11355
11421
|
actionBlock: /*#__PURE__*/React.createElement(Header, {
|
|
11356
11422
|
metaName: metaName,
|
|
11357
|
-
onClick: () => setIsOpen(assoc("manageMember", true))
|
|
11423
|
+
onClick: () => setIsOpen(assoc("manageMember", true)),
|
|
11424
|
+
permissions: config === null || config === void 0 ? void 0 : config.permissions
|
|
11358
11425
|
})
|
|
11359
11426
|
})), /*#__PURE__*/React.createElement(ManageMember, {
|
|
11360
11427
|
config: config,
|
|
@@ -11393,7 +11460,7 @@ const VALIDATION_SCHEMA = {
|
|
|
11393
11460
|
|
|
11394
11461
|
var e=[],t=[];function n(n,r){if(n&&"undefined"!=typeof document){var a,s=!0===r.prepend?"prepend":"append",d=!0===r.singleTag,i="string"==typeof r.container?document.querySelector(r.container):document.getElementsByTagName("head")[0];if(d){var u=e.indexOf(i);-1===u&&(u=e.push(i)-1,t[u]={}),a=t[u]&&t[u][s]?t[u][s]:t[u][s]=c();}else a=c();65279===n.charCodeAt(0)&&(n=n.substring(1)),a.styleSheet?a.styleSheet.cssText+=n:a.appendChild(document.createTextNode(n));}function c(){var e=document.createElement("style");if(e.setAttribute("type","text/css"),r.attributes)for(var t=Object.keys(r.attributes),n=0;n<t.length;n++)e.setAttribute(t[n],r.attributes[t[n]]);var a="prepend"===s?"afterbegin":"beforeend";return i.insertAdjacentElement(a,e),e}}
|
|
11395
11462
|
|
|
11396
|
-
var css = ":root {\n --ntm-roles-table-default-scroll: 15px;\n}\n\n.ntm-dropdown__button {\n border-radius: 0 !important;\n font-weight: var(--neeto-ui-font-normal);\n min-height: 34px;\n min-width: 150px;\n text-align: left;\n width: 100%;\n}\n\n.ntm-scrollbar__inner {\n width: 100%;\n height: 200px;\n}\n.ntm-scrollbar__outer {\n position: \"absolute\";\n top: 0px;\n left: 0px;\n width: 200px;\n height: 150px;\n overflow: \"hidden\";\n visibility: \"hidden\";\n}\n\n.ntm-empty-state {\n align-items: center;\n display: flex;\n height: 100%;\n justify-content: center;\n width: 100%;\n}\n.ntm-empty-state__image {\n display: flex;\n justify-content: center;\n align-items: center;\n margin-bottom: 2rem;\n}\n.ntm-empty-state__title--with-action-block {\n margin-bottom: 1rem;\n}\n.ntm-empty-state__action-block {\n display: flex;\n justify-content: center;\n}\n\n.ntm-members {\n overflow: auto;\n width: 100%;\n}\n.ntm-members-wrapper {\n display: flex;\n}\n.ntm-members-page-loader {\n width: 100%;\n height: 100vh;\n}\n.ntm-members__table-wrapper {\n height: calc(100vh - 205px);\n width: 100%;\n}\n.ntm-members-table__column {\n display: flex;\n align-items: center;\n gap: 0.5rem;\n}\n.ntm-members-pane__header {\n margin-bottom: 0.5rem;\n}\n.ntm-members-pane__body {\n width: 100%;\n padding-bottom: 1rem;\n}\n.ntm-members-pane__body > * + * {\n margin-top: 1rem;\n}\n.ntm-members-pane__footer {\n display: flex;\n gap: 0.5rem;\n}\n\n.ntm-members-radio-group {\n width: 100%;\n}\n.ntm-members-radio-group .neeto-ui-radio__container--stacked {\n width: 100%;\n}\n.ntm-members-radio-group__label {\n padding-right: 4px;\n}\n.ntm-members-radio-group__icon {\n cursor: pointer;\n}\n\n.ntm-members-pane-radio-item__wrapper {\n width: 100%;\n cursor: pointer;\n padding: 8px 0px !important;\n}\n.ntm-members-pane-radio-item__wrapper:first-child {\n padding-top: 0px !important;\n}\n.ntm-members-pane-radio-item__label {\n margin-bottom: 0 !important;\n}\n.ntm-members-pane-radio-item__description {\n color: rgb(var(--neeto-ui-gray-700));\n}\n\n.ntm-roles-header {\n border-bottom: 1px solid rgb(var(--neeto-ui-gray-300));\n}\n\n.ntm-roles-table__wrapper {\n width: 100%;\n height: calc(100vh - var(--neeto-ui-main-header-height));\n display: flex;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__sidebar {\n width: 396px;\n min-width: 396px;\n border-right: thin solid rgb(var(--neeto-ui-gray-300));\n}\n.ntm-roles-table__wrapper .ntm-roles-table__sidebar .ntm-roles-table-sidebar__search {\n padding: 24px 24px 16px;\n height: 72px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__sidebar .ntm-roles-table-sidebar__list {\n height: calc(\n 100vh - var(--neeto-ui-main-header-height) - 72px -\n var(--ntm-roles-table-default-scroll)\n );\n overflow-y: auto;\n padding-left: 24px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__sidebar .ntm-roles-table-sidebar__list .ntm-roles-table-sidebar__list-item {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 12px 8px;\n min-height:
|
|
11463
|
+
var css = ":root {\n --ntm-roles-table-default-scroll: 15px;\n}\n\n.ntm-dropdown__button {\n border-radius: 0 !important;\n font-weight: var(--neeto-ui-font-normal);\n min-height: 34px;\n min-width: 150px;\n text-align: left;\n width: 100%;\n}\n\n.ntm-scrollbar__inner {\n width: 100%;\n height: 200px;\n}\n.ntm-scrollbar__outer {\n position: \"absolute\";\n top: 0px;\n left: 0px;\n width: 200px;\n height: 150px;\n overflow: \"hidden\";\n visibility: \"hidden\";\n}\n\n.ntm-empty-state {\n align-items: center;\n display: flex;\n height: 100%;\n justify-content: center;\n width: 100%;\n}\n.ntm-empty-state__image {\n display: flex;\n justify-content: center;\n align-items: center;\n margin-bottom: 2rem;\n}\n.ntm-empty-state__title--with-action-block {\n margin-bottom: 1rem;\n}\n.ntm-empty-state__action-block {\n display: flex;\n justify-content: center;\n}\n\n.ntm-members {\n overflow: auto;\n width: 100%;\n}\n.ntm-members-wrapper {\n display: flex;\n}\n.ntm-members-page-loader {\n width: 100%;\n height: 100vh;\n}\n.ntm-members__table-wrapper {\n height: calc(100vh - 205px);\n width: 100%;\n}\n.ntm-members-table__column {\n display: flex;\n align-items: center;\n gap: 0.5rem;\n}\n.ntm-members-pane__header {\n margin-bottom: 0.5rem;\n}\n.ntm-members-pane__body {\n width: 100%;\n padding-bottom: 1rem;\n}\n.ntm-members-pane__body > * + * {\n margin-top: 1rem;\n}\n.ntm-members-pane__footer {\n display: flex;\n gap: 0.5rem;\n}\n\n.ntm-members-radio-group {\n width: 100%;\n}\n.ntm-members-radio-group .neeto-ui-radio__container--stacked {\n width: 100%;\n}\n.ntm-members-radio-group__label {\n padding-right: 4px;\n}\n.ntm-members-radio-group__icon {\n cursor: pointer;\n}\n\n.ntm-members-pane-radio-item__wrapper {\n width: 100%;\n cursor: pointer;\n padding: 8px 0px !important;\n}\n.ntm-members-pane-radio-item__wrapper:first-child {\n padding-top: 0px !important;\n}\n.ntm-members-pane-radio-item__label {\n margin-bottom: 0 !important;\n}\n.ntm-members-pane-radio-item__description {\n color: rgb(var(--neeto-ui-gray-700));\n}\n\n.ntm-roles-header {\n border-bottom: 1px solid rgb(var(--neeto-ui-gray-300));\n}\n\n.ntm-roles-table__wrapper {\n width: 100%;\n height: calc(100vh - var(--neeto-ui-main-header-with-breadcrumbs-height));\n display: flex;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__sidebar {\n width: 396px;\n min-width: 396px;\n border-right: thin solid rgb(var(--neeto-ui-gray-300));\n}\n.ntm-roles-table__wrapper .ntm-roles-table__sidebar .ntm-roles-table-sidebar__search {\n padding: 24px 24px 16px;\n height: 72px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__sidebar .ntm-roles-table-sidebar__list {\n height: calc(\n 100vh - var(--neeto-ui-main-header-with-breadcrumbs-height) - 72px -\n var(--ntm-roles-table-default-scroll)\n );\n overflow-y: auto;\n padding-left: 24px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__sidebar .ntm-roles-table-sidebar__list .ntm-roles-table-sidebar__list-item {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 12px 8px;\n min-height: 68px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__sidebar .ntm-roles-table-sidebar__list .ntm-roles-table-sidebar__list-item.ntm-roles-table-sidebar__list-item--highlighted {\n background-color: rgb(var(--neeto-ui-primary-100));\n padding: 12px 8px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__sidebar .ntm-roles-table-sidebar__list .ntm-roles-table-sidebar__list-item:not(.ntm-roles-table-sidebar__list-item--highlighted) {\n border-bottom: thin solid rgb(var(--neeto-ui-gray-300));\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns {\n width: calc(\n 100vw - var(--neeto-ui-sidebar-width) - 396px - 24px\n );\n overflow: hidden;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__cell {\n width: 100%;\n min-width: 200px;\n min-height: 68px;\n padding: 12px 8px;\n display: flex;\n justify-content: center;\n align-items: center;\n border-right: thin solid rgb(var(--neeto-ui-gray-300));\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table-cell__checkbox-wrapper {\n position: absolute;\n height: 1rem;\n width: 1rem;\n margin: auto;\n z-index: 10;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table-cell__checkbox {\n z-index: 10;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__header {\n display: flex;\n align-items: center;\n overflow-x: auto;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__header .ntm-roles-table__cell {\n height: 72px;\n padding-left: 24px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__header .ntm-roles-table-header-cell__container {\n display: flex;\n justify-content: space-between;\n align-items: center;\n width: 100%;\n gap: 1rem;\n overflow: hidden;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__header .ntm-roles-table-header__dropdown {\n margin: 3px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__header .ntm-roles-table-header__role-name {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__rows {\n width: 100%;\n height: calc(\n 100vh - var(--neeto-ui-main-header-with-breadcrumbs-height) - 72px -\n var(--ntm-roles-table-default-scroll)\n );\n overflow-y: auto;\n scrollbar-width: none;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__rows::-webkit-scrollbar {\n width: 0px;\n height: 0px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__rows::-webkit-scrollbar-thumb {\n background: rgb(var(--neeto-ui-gray-300));\n border-radius: 50px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__rows::-webkit-scrollbar-thumb:hover {\n border-radius: 50px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__rows::-webkit-scrollbar-track {\n background: rgb(var(--neeto-ui-gray-300));\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__rows .ntm-roles-table__row {\n display: flex;\n align-items: center;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__rows .ntm-roles-table__row .ntm-roles-table__cell {\n overflow: hidden;\n position: relative;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__rows .ntm-roles-table__row .ntm-roles-table__cell p {\n opacity: 0;\n width: 340px;\n min-width: 340px;\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__rows .ntm-roles-table__row.ntm-roles-table__row--highlighted .ntm-roles-table__cell {\n background-color: rgb(var(--neeto-ui-primary-100));\n}\n.ntm-roles-table__wrapper .ntm-roles-table__columns .ntm-roles-table__rows .ntm-roles-table__row:not(.ntm-roles-table__row--highlighted) .ntm-roles-table__cell {\n border-bottom: thin solid rgb(var(--neeto-ui-gray-300));\n}\n\n.ntm-roles-table-sidebar__drop-down-button {\n color: rgb(var(--neeto-ui-gray-600));\n cursor: pointer;\n}\n\n.ntm-roles-modal__body > * + * {\n margin-top: 1rem;\n}\n.ntm-roles-modal__footer {\n display: flex;\n gap: 0.5rem;\n}\n\n.ntm-roles-pane__body {\n width: 100%;\n margin-bottom: 1.5rem;\n}\n.ntm-roles-pane__body-wrapper > * + * {\n margin-top: 1rem;\n}\n.ntm-roles-pane__body > * + * {\n margin-top: 1.5rem;\n}\n.ntm-roles-pane__footer {\n display: flex;\n gap: 0.5rem;\n}\n\n.ntm-roles-permission > * + * {\n margin: 0.5rem;\n}\n.ntm-roles-permission__heading {\n color: rgb(var(--neeto-ui-gray-500));\n text-transform: uppercase;\n}\n.ntm-roles-permission__card {\n background-color: rgb(var(--neeto-ui-white));\n align-items: center;\n border-radius: var(--neeto-ui-rounded);\n border-width: 1px;\n border-color: rgb(var(--neeto-ui-gray-300));\n cursor: pointer;\n display: flex;\n gap: 0.75rem;\n padding: 1rem 0.75rem;\n}\n.ntm-roles-permission__card--description {\n flex-grow: 1;\n}\n.ntm-roles-permission__card--checkbox {\n padding: 0 0.5rem;\n}\n\n.ntm-roles-help-url-wrapper {\n display: flex;\n width: 100%;\n align-items: center;\n justify-content: center;\n padding: 1rem 0;\n}\n\ntd.ant-table-column-sort {\n background: transparent;\n}";
|
|
11397
11464
|
n(css,{});
|
|
11398
11465
|
|
|
11399
11466
|
export { MultipleEmailInput, index$1 as Roles, RolesRadioGroup, index as TeamMembers, VALIDATION_SCHEMA, hasPermission };
|