@tesouro/embedded-components-react 0.5.186 → 0.5.187
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/dist/libs/tesouro-embedded-components-react/settings-widget/team/data-access/dist/index7.js +116 -94
- package/dist/libs/tesouro-embedded-components-react/settings-widget/team/feature/dist/index12.js +76 -68
- package/dist/libs/tesouro-embedded-components-react/settings-widget/team/feature/dist/index17.js +181 -179
- package/dist/libs/tesouro-embedded-components-react/settings-widget/team/feature/dist/index3.js +2 -0
- package/dist/libs/tesouro-embedded-components-react/settings-widget/team/feature/dist/index7.js +16 -12
- package/dist/libs/tesouro-embedded-components-react/settings-widget/team/ui/dist/index8.js +66 -66
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/index.js +36 -35
- package/dist/libs/tesouro-embedded-components-react/shared/data-access/dist/lib/debit-card/useAllDebitCardsQuery.js +54 -0
- package/dist/libs/tesouro-embedded-components-react/shared/feature/dist/lib/analytics/build-info.js +1 -1
- package/package.json +1 -1
package/dist/libs/tesouro-embedded-components-react/settings-widget/team/feature/dist/index17.js
CHANGED
|
@@ -42,7 +42,7 @@ var Le = [
|
|
|
42
42
|
5,
|
|
43
43
|
10,
|
|
44
44
|
25
|
|
45
|
-
], Re = 10, ze = [t.UserReadOrg], p = [t.UserWriteOrg, t.UserWriteAll], Be = [t.UserWriteAll], Ve = [t.UserWriteOrg], He = [t.UserWriteOrg], Ue = [t.RoleReadOrg], We = [t.UserWriteOrg], Ge = [t.BankAccountReadOrg], Ke = [t.ExternalBankAccountReadOrg], qe = [t.BankAccountWriteOrg];
|
|
45
|
+
], Re = 10, ze = [t.UserReadOrg], p = [t.UserWriteOrg, t.UserWriteAll], Be = [t.UserWriteAll], Ve = [t.UserWriteOrg], He = [t.UserWriteOrg], Ue = [t.RoleReadOrg], We = [t.UserWriteOrg], Ge = [t.BankAccountReadOrg], Ke = [t.ExternalBankAccountReadOrg], qe = [t.BankAccountWriteOrg], Je = [t.DebitCardReadOrg], Ye = [t.DebitCardIssueOrg];
|
|
46
46
|
function m({ labels: r, featureLabels: i, acceptInviteRedirectUri: m }) {
|
|
47
47
|
let h = c(() => ({
|
|
48
48
|
...ae,
|
|
@@ -51,15 +51,15 @@ function m({ labels: r, featureLabels: i, acceptInviteRedirectUri: m }) {
|
|
|
51
51
|
s(() => {
|
|
52
52
|
g(oe.Mounted);
|
|
53
53
|
}, [g]);
|
|
54
|
-
let { organizationId: _, widgetToken:
|
|
55
|
-
canRead: x &&
|
|
56
|
-
canWrite:
|
|
54
|
+
let { organizationId: _, widgetToken: Xe, initResponse: v } = ne(), y = v?.userId ?? void 0, Ze = ie(), Qe = !!re(), b = !!(_ && Xe), x = c(() => e(v?.scopes, ze), [v?.scopes]), S = b && x && !!v, C = v?.scopes, w = e(C, Ue), $e = e(C, We), et = b && e(C, p) && w && $e, T = b && x && e(C, p), tt = b && e(C, Be), nt = b && e(C, Ve), rt = b && w && $e, it = b && e(C, He), at = b && x && e(C, [t.UserWriteOrg]), E = b && e(C, Ge), D = b && e(C, Ke), O = b && e(C, qe) && E && D, ot = b && e(C, Je) && e(C, Ye), [k, st] = l("members"), A = le({
|
|
55
|
+
canRead: x && k === "departments",
|
|
56
|
+
canWrite: at,
|
|
57
57
|
featureLabels: h
|
|
58
|
-
}),
|
|
59
|
-
canRead: x &&
|
|
60
|
-
canWrite:
|
|
58
|
+
}), j = ye({
|
|
59
|
+
canRead: x && k === "locations",
|
|
60
|
+
canWrite: at,
|
|
61
61
|
featureLabels: h
|
|
62
|
-
}),
|
|
62
|
+
}), ct = [
|
|
63
63
|
{
|
|
64
64
|
id: "members",
|
|
65
65
|
label: h.teamMembersTab
|
|
@@ -72,282 +72,284 @@ function m({ labels: r, featureLabels: i, acceptInviteRedirectUri: m }) {
|
|
|
72
72
|
id: "locations",
|
|
73
73
|
label: h.locationsTab
|
|
74
74
|
}
|
|
75
|
-
], [
|
|
76
|
-
Limit:
|
|
75
|
+
], [lt, M] = l(), [N, ut] = l(Re), [dt, P] = l(0), [F, I] = l(), L = (et || rt) && w, ft = S && w && (!!F || !L), [pt, mt] = l(), R = se({
|
|
76
|
+
Limit: N,
|
|
77
77
|
Status: "ALL",
|
|
78
|
-
PaginationToken:
|
|
78
|
+
PaginationToken: lt,
|
|
79
79
|
enabled: S
|
|
80
|
-
}),
|
|
80
|
+
}), ht = v?.organizationTypes ?? [], z = c(() => ({
|
|
81
81
|
organizationId: _ ?? "",
|
|
82
|
-
organizationTypes:
|
|
83
|
-
}), [_,
|
|
84
|
-
let e =
|
|
85
|
-
return he(e,
|
|
82
|
+
organizationTypes: ht
|
|
83
|
+
}), [_, ht]), B = ee({ enabled: ft }), gt = c(() => me(B.data?.data ?? [], z), [B.data?.data, z]), V = S ? R.data?.data ?? [] : [], H = a({ enabled: L }), U = c(() => fe(H.data?.data ?? [], z), [H.data, z]), _t = c(() => {
|
|
84
|
+
let e = L ? H.data?.data ?? [] : B.data?.data ?? [];
|
|
85
|
+
return he(e, z);
|
|
86
86
|
}, [
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
]),
|
|
92
|
-
canInvite:
|
|
87
|
+
L,
|
|
88
|
+
H.data,
|
|
89
|
+
B.data,
|
|
90
|
+
z
|
|
91
|
+
]), vt = gt.length > 0 && !B.isResolving && !B.isError, yt = c(() => me(H.data?.data ?? [], z), [H.data, z]), W = vt ? gt : yt, bt = _e(V, h, I, W, _), xt = !!H.data, St = U.length > 0, Ct = et && xt && St, wt = rt && xt && St, G = ve({
|
|
92
|
+
canInvite: Ct,
|
|
93
93
|
canReadDirectory: x,
|
|
94
|
-
canManageAccountAccess:
|
|
95
|
-
canReadInternalAccounts:
|
|
96
|
-
canReadExternalAccounts:
|
|
97
|
-
|
|
98
|
-
|
|
94
|
+
canManageAccountAccess: O,
|
|
95
|
+
canReadInternalAccounts: E,
|
|
96
|
+
canReadExternalAccounts: D,
|
|
97
|
+
canGrantDebitCardAccess: ot,
|
|
98
|
+
roles: U,
|
|
99
|
+
roleCatalog: W,
|
|
99
100
|
organizationId: _,
|
|
100
101
|
featureLabels: h,
|
|
101
102
|
acceptInviteRedirectUri: m
|
|
102
|
-
}),
|
|
103
|
-
canEditAnyProfile:
|
|
104
|
-
canEditOrgProfile:
|
|
103
|
+
}), K = Ce({
|
|
104
|
+
canEditAnyProfile: tt,
|
|
105
|
+
canEditOrgProfile: nt,
|
|
105
106
|
organizationId: _,
|
|
106
107
|
currentUserId: y,
|
|
107
|
-
canEditRole:
|
|
108
|
+
canEditRole: wt,
|
|
108
109
|
canReadDirectory: x,
|
|
109
|
-
canManageAccountAccess:
|
|
110
|
-
canReadInternalAccounts:
|
|
111
|
-
canReadExternalAccounts:
|
|
112
|
-
members:
|
|
113
|
-
roles:
|
|
114
|
-
allRoles:
|
|
115
|
-
roleCatalog:
|
|
110
|
+
canManageAccountAccess: O,
|
|
111
|
+
canReadInternalAccounts: E,
|
|
112
|
+
canReadExternalAccounts: D,
|
|
113
|
+
members: V,
|
|
114
|
+
roles: U,
|
|
115
|
+
allRoles: _t,
|
|
116
|
+
roleCatalog: W,
|
|
116
117
|
featureLabels: h
|
|
117
|
-
}),
|
|
118
|
-
canDeactivate:
|
|
119
|
-
canResendInvite:
|
|
120
|
-
members:
|
|
118
|
+
}), q = we({
|
|
119
|
+
canDeactivate: it,
|
|
120
|
+
canResendInvite: T,
|
|
121
|
+
members: V,
|
|
121
122
|
featureLabels: h,
|
|
122
123
|
acceptInviteRedirectUri: m
|
|
123
|
-
}),
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
124
|
+
}), Tt = R.data?.nextPaginationToken, Et = R.data?.prevPaginationToken, J = F ? V.find((e) => e.id === F) : void 0, Y = ce({ enabled: !!J && x }), Dt = Y.data?.data ?? V, X = J ? de(Dt, J.reportingManagerUserId) : void 0, Ot = c(() => J && Y.isComplete ? pe(Y.data?.data ?? [], J.id, h, W, _) : [], [
|
|
125
|
+
J,
|
|
126
|
+
Y.isComplete,
|
|
127
|
+
Y.data?.data,
|
|
127
128
|
h,
|
|
128
|
-
|
|
129
|
+
W,
|
|
129
130
|
_
|
|
130
|
-
]),
|
|
131
|
+
]), kt = !!R.data, At = kt && !!F && !J;
|
|
131
132
|
s(() => {
|
|
132
|
-
|
|
133
|
-
}, [
|
|
134
|
-
let
|
|
133
|
+
At && I(void 0);
|
|
134
|
+
}, [At]);
|
|
135
|
+
let jt = R.isError;
|
|
135
136
|
s(() => {
|
|
136
|
-
|
|
137
|
-
}, [
|
|
138
|
-
let
|
|
139
|
-
member:
|
|
137
|
+
jt && (M(void 0), P(0));
|
|
138
|
+
}, [jt]);
|
|
139
|
+
let Mt = bt.length, Nt = Mt === 0 ? 0 : dt * N + 1, Pt = dt * N + Mt, Ft = `${h.viewingRangeLabel} ${Nt}-${Pt}`, Z = ue(J), It = !!(J && xe({
|
|
140
|
+
member: J,
|
|
140
141
|
organizationId: _,
|
|
141
|
-
canEditAnyProfile:
|
|
142
|
-
canEditOrgProfile:
|
|
142
|
+
canEditAnyProfile: tt,
|
|
143
|
+
canEditOrgProfile: nt,
|
|
143
144
|
currentUserId: y
|
|
144
|
-
})),
|
|
145
|
-
member:
|
|
145
|
+
})), Lt = !!(J && Se({
|
|
146
|
+
member: J,
|
|
146
147
|
organizationId: _,
|
|
147
|
-
canEditRole:
|
|
148
|
+
canEditRole: wt,
|
|
148
149
|
currentUserId: y
|
|
149
|
-
})),
|
|
150
|
-
selectedMember:
|
|
151
|
-
canReadInternalAccounts:
|
|
152
|
-
canReadExternalAccounts:
|
|
150
|
+
})), Rt = O && !!J && J?.id !== y, zt = It || Lt || Rt, Q = be({
|
|
151
|
+
selectedMember: J && Z ? J : void 0,
|
|
152
|
+
canReadInternalAccounts: E,
|
|
153
|
+
canReadExternalAccounts: D,
|
|
153
154
|
featureLabels: h,
|
|
154
|
-
allRoles:
|
|
155
|
-
}), $ = c(() =>
|
|
156
|
-
|
|
155
|
+
allRoles: _t
|
|
156
|
+
}), $ = c(() => J ? ge(J, h, W, _) : void 0, [
|
|
157
|
+
J,
|
|
157
158
|
h,
|
|
158
|
-
|
|
159
|
+
W,
|
|
159
160
|
_
|
|
160
161
|
]);
|
|
161
162
|
return /* @__PURE__ */ f(u, { children: [
|
|
162
163
|
/* @__PURE__ */ d(n, {}),
|
|
163
|
-
|
|
164
|
-
open:
|
|
165
|
-
memberName:
|
|
166
|
-
memberEmail:
|
|
164
|
+
K.isEditOpen ? /* @__PURE__ */ d(Ee, {
|
|
165
|
+
open: K.isEditOpen,
|
|
166
|
+
memberName: K.editMemberName,
|
|
167
|
+
memberEmail: K.editMemberEmail,
|
|
167
168
|
memberInitials: $?.initials,
|
|
168
|
-
avatarSeed:
|
|
169
|
+
avatarSeed: J?.email,
|
|
169
170
|
roleBadgeLabel: $?.roleCardTitle,
|
|
170
171
|
statusLabel: $?.statusLabel,
|
|
171
172
|
statusTone: $?.statusTone,
|
|
172
173
|
lastSignInLabel: $?.lastSignInLabel,
|
|
173
|
-
form:
|
|
174
|
+
form: K.editForm,
|
|
175
|
+
roleOptions: K.roleOptions,
|
|
176
|
+
departmentOptions: K.departmentOptions,
|
|
177
|
+
locationOptions: K.locationOptions,
|
|
178
|
+
reportingManagerOptions: K.reportingManagerOptions,
|
|
179
|
+
departmentsLoading: K.departmentsLoading,
|
|
180
|
+
locationsLoading: K.locationsLoading,
|
|
181
|
+
reportingManagersLoading: K.reportingManagersLoading,
|
|
182
|
+
departmentsError: K.departmentsError,
|
|
183
|
+
locationsError: K.locationsError,
|
|
184
|
+
reportingManagersError: K.reportingManagersError,
|
|
185
|
+
errors: K.editErrors,
|
|
186
|
+
submitErrorMessage: K.editErrorMessage,
|
|
187
|
+
isSubmitting: K.isSavingEdit,
|
|
188
|
+
isNameDisabled: K.isEditNameDisabled,
|
|
189
|
+
isRoleDisabled: K.isEditRoleDisabled,
|
|
190
|
+
isGroupDisabled: K.isEditGroupDisabled,
|
|
191
|
+
isReportingManagerDisabled: K.isEditReportingManagerDisabled,
|
|
192
|
+
isSaveDisabled: K.isEditSaveDisabled,
|
|
193
|
+
accountAccessMode: K.accountAccessMode,
|
|
194
|
+
accountAccessRows: K.accountAccessRows,
|
|
195
|
+
onAccountAccessToggle: K.onAccountAccessToggle,
|
|
196
|
+
isAccountAccessLoading: K.isAccountAccessLoading,
|
|
197
|
+
accountAccessErrorMessage: K.accountAccessErrorMessage,
|
|
198
|
+
onOpenChange: K.onEditOpenChange,
|
|
199
|
+
onFormChange: K.onEditFormChange,
|
|
200
|
+
onSubmit: K.onEditSubmit,
|
|
201
|
+
labels: r
|
|
202
|
+
}) : J ? /* @__PURE__ */ d(Ae, {
|
|
203
|
+
...ge(J, h, W, _),
|
|
204
|
+
avatarSeed: J.email,
|
|
205
|
+
reportingManagerName: X?.name,
|
|
206
|
+
reportingManagerInitials: X?.initials,
|
|
207
|
+
reportingManagerSeed: X?.email,
|
|
208
|
+
directReports: Ot,
|
|
209
|
+
accountAccessLabel: Q.detailAccountAccessLabel,
|
|
210
|
+
accountAccessRows: Q.detailAccounts,
|
|
211
|
+
isAccountAccessLoading: Q.detailAccountsLoading,
|
|
212
|
+
isRoleLoading: w && B.isResolving,
|
|
213
|
+
onBackClick: () => {
|
|
214
|
+
mt(F), I(void 0);
|
|
215
|
+
},
|
|
216
|
+
onEditClick: zt && Z ? () => K.openMemberEdit(J.id) : void 0,
|
|
217
|
+
onResendClick: T && (J.status ?? "").trim().toUpperCase() === "INVITED" ? () => q.openResendConfirmation(J.id) : void 0,
|
|
218
|
+
onDeactivateClick: it && Z ? () => q.openDeactivateConfirmation(J.id) : void 0,
|
|
219
|
+
labels: r
|
|
220
|
+
}) : G.isInviteOpen ? /* @__PURE__ */ d(Te, {
|
|
221
|
+
form: G.inviteForm,
|
|
174
222
|
roleOptions: G.roleOptions,
|
|
175
223
|
departmentOptions: G.departmentOptions,
|
|
176
224
|
locationOptions: G.locationOptions,
|
|
177
225
|
reportingManagerOptions: G.reportingManagerOptions,
|
|
226
|
+
accountAccessOptions: G.accountAccessOptions,
|
|
178
227
|
departmentsLoading: G.departmentsLoading,
|
|
179
228
|
locationsLoading: G.locationsLoading,
|
|
180
229
|
reportingManagersLoading: G.reportingManagersLoading,
|
|
181
230
|
departmentsError: G.departmentsError,
|
|
182
231
|
locationsError: G.locationsError,
|
|
183
232
|
reportingManagersError: G.reportingManagersError,
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
isSubmitting: G.isSavingEdit,
|
|
187
|
-
isNameDisabled: G.isEditNameDisabled,
|
|
188
|
-
isRoleDisabled: G.isEditRoleDisabled,
|
|
189
|
-
isGroupDisabled: G.isEditGroupDisabled,
|
|
190
|
-
isReportingManagerDisabled: G.isEditReportingManagerDisabled,
|
|
191
|
-
isSaveDisabled: G.isEditSaveDisabled,
|
|
233
|
+
accountAccessLoading: G.accountAccessLoading,
|
|
234
|
+
accountAccessError: G.accountAccessError,
|
|
192
235
|
accountAccessMode: G.accountAccessMode,
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
}) : q ? /* @__PURE__ */ d(Ae, {
|
|
202
|
-
...ge(q, h, U, _),
|
|
203
|
-
avatarSeed: q.email,
|
|
204
|
-
reportingManagerName: Y?.name,
|
|
205
|
-
reportingManagerInitials: Y?.initials,
|
|
206
|
-
reportingManagerSeed: Y?.email,
|
|
207
|
-
directReports: Et,
|
|
208
|
-
accountAccessLabel: Q.detailAccountAccessLabel,
|
|
209
|
-
accountAccessRows: Q.detailAccounts,
|
|
210
|
-
isAccountAccessLoading: Q.detailAccountsLoading,
|
|
211
|
-
isRoleLoading: w && z.isResolving,
|
|
212
|
-
onBackClick: () => {
|
|
213
|
-
ft(P), F(void 0);
|
|
214
|
-
},
|
|
215
|
-
onEditClick: It && Z ? () => G.openMemberEdit(q.id) : void 0,
|
|
216
|
-
onResendClick: $e && (q.status ?? "").trim().toUpperCase() === "INVITED" ? () => K.openResendConfirmation(q.id) : void 0,
|
|
217
|
-
onDeactivateClick: rt && Z ? () => K.openDeactivateConfirmation(q.id) : void 0,
|
|
218
|
-
labels: r
|
|
219
|
-
}) : W.isInviteOpen ? /* @__PURE__ */ d(Te, {
|
|
220
|
-
form: W.inviteForm,
|
|
221
|
-
roleOptions: W.roleOptions,
|
|
222
|
-
departmentOptions: W.departmentOptions,
|
|
223
|
-
locationOptions: W.locationOptions,
|
|
224
|
-
reportingManagerOptions: W.reportingManagerOptions,
|
|
225
|
-
accountAccessOptions: W.accountAccessOptions,
|
|
226
|
-
departmentsLoading: W.departmentsLoading,
|
|
227
|
-
locationsLoading: W.locationsLoading,
|
|
228
|
-
reportingManagersLoading: W.reportingManagersLoading,
|
|
229
|
-
departmentsError: W.departmentsError,
|
|
230
|
-
locationsError: W.locationsError,
|
|
231
|
-
reportingManagersError: W.reportingManagersError,
|
|
232
|
-
accountAccessLoading: W.accountAccessLoading,
|
|
233
|
-
accountAccessError: W.accountAccessError,
|
|
234
|
-
accountAccessMode: W.accountAccessMode,
|
|
235
|
-
errors: W.inviteErrors,
|
|
236
|
-
submitErrorMessage: W.inviteErrorMessage,
|
|
237
|
-
isSubmitting: W.isInviting,
|
|
238
|
-
onFormChange: W.onInviteFormChange,
|
|
239
|
-
onBackClick: W.closeInviteForm,
|
|
240
|
-
onCancel: W.closeInviteForm,
|
|
241
|
-
onSubmit: W.onInviteSubmit,
|
|
236
|
+
errors: G.inviteErrors,
|
|
237
|
+
submitErrorMessage: G.inviteErrorMessage,
|
|
238
|
+
isSubmitting: G.isInviting,
|
|
239
|
+
isSubmitBlocked: G.isInviteSubmitBlocked,
|
|
240
|
+
onFormChange: G.onInviteFormChange,
|
|
241
|
+
onBackClick: G.closeInviteForm,
|
|
242
|
+
onCancel: G.closeInviteForm,
|
|
243
|
+
onSubmit: G.onInviteSubmit,
|
|
242
244
|
labels: r
|
|
243
245
|
}) : /* @__PURE__ */ d("div", {
|
|
244
246
|
className: "ttw:space-y-4 ttw:rounded-xl ttw:border ttw:border-border ttw:bg-card ttw:p-6",
|
|
245
247
|
children: /* @__PURE__ */ d(je, {
|
|
246
|
-
tabs:
|
|
247
|
-
activeTabId:
|
|
248
|
-
onTabChange:
|
|
249
|
-
children:
|
|
248
|
+
tabs: ct,
|
|
249
|
+
activeTabId: k,
|
|
250
|
+
onTabChange: st,
|
|
251
|
+
children: k === "departments" ? /* @__PURE__ */ f(u, { children: [
|
|
250
252
|
/* @__PURE__ */ d(Oe, {
|
|
251
253
|
icon: /* @__PURE__ */ d(Ne, { className: "ttw:size-4" }),
|
|
252
|
-
...
|
|
254
|
+
...A.panel
|
|
253
255
|
}),
|
|
254
|
-
/* @__PURE__ */ d(De, { ...
|
|
256
|
+
/* @__PURE__ */ d(De, { ...A.drawer }),
|
|
255
257
|
/* @__PURE__ */ d(o, {
|
|
256
|
-
open:
|
|
258
|
+
open: A.deleteDialog.open,
|
|
257
259
|
icon: /* @__PURE__ */ d(Ie, {
|
|
258
260
|
"aria-hidden": !0,
|
|
259
261
|
className: "ttw:size-6"
|
|
260
262
|
}),
|
|
261
263
|
title: h.departmentDeleteDialogTitle,
|
|
262
264
|
description: h.departmentDeleteDialogDescription,
|
|
263
|
-
subjectName:
|
|
265
|
+
subjectName: A.deleteDialog.subjectName,
|
|
264
266
|
confirmButtonLabel: h.departmentDeleteConfirmButton,
|
|
265
|
-
errorMessage:
|
|
266
|
-
isConfirming:
|
|
267
|
-
onOpenChange:
|
|
268
|
-
onConfirm:
|
|
267
|
+
errorMessage: A.deleteDialog.errorMessage,
|
|
268
|
+
isConfirming: A.deleteDialog.isConfirming,
|
|
269
|
+
onOpenChange: A.deleteDialog.onOpenChange,
|
|
270
|
+
onConfirm: A.deleteDialog.onConfirm,
|
|
269
271
|
labels: r
|
|
270
272
|
})
|
|
271
|
-
] }) :
|
|
273
|
+
] }) : k === "locations" ? /* @__PURE__ */ f(u, { children: [
|
|
272
274
|
/* @__PURE__ */ d(Oe, {
|
|
273
275
|
icon: /* @__PURE__ */ d(Fe, { className: "ttw:size-4" }),
|
|
274
|
-
...
|
|
276
|
+
...j.panel
|
|
275
277
|
}),
|
|
276
|
-
/* @__PURE__ */ d(De, { ...
|
|
278
|
+
/* @__PURE__ */ d(De, { ...j.drawer }),
|
|
277
279
|
/* @__PURE__ */ d(o, {
|
|
278
|
-
open:
|
|
280
|
+
open: j.deleteDialog.open,
|
|
279
281
|
icon: /* @__PURE__ */ d(Ie, {
|
|
280
282
|
"aria-hidden": !0,
|
|
281
283
|
className: "ttw:size-6"
|
|
282
284
|
}),
|
|
283
285
|
title: h.locationDeleteDialogTitle,
|
|
284
286
|
description: h.locationDeleteDialogDescription,
|
|
285
|
-
subjectName:
|
|
287
|
+
subjectName: j.deleteDialog.subjectName,
|
|
286
288
|
confirmButtonLabel: h.locationDeleteConfirmButton,
|
|
287
|
-
errorMessage:
|
|
288
|
-
isConfirming:
|
|
289
|
-
onOpenChange:
|
|
290
|
-
onConfirm:
|
|
289
|
+
errorMessage: j.deleteDialog.errorMessage,
|
|
290
|
+
isConfirming: j.deleteDialog.isConfirming,
|
|
291
|
+
onOpenChange: j.deleteDialog.onOpenChange,
|
|
292
|
+
onConfirm: j.deleteDialog.onConfirm,
|
|
291
293
|
labels: r
|
|
292
294
|
})
|
|
293
295
|
] }) : /* @__PURE__ */ d(ke, {
|
|
294
|
-
rows:
|
|
295
|
-
isLoading: !
|
|
296
|
-
isError:
|
|
297
|
-
showPagination: S &&
|
|
298
|
-
isPreviousPageDisabled: !
|
|
299
|
-
isNextPageDisabled: !
|
|
300
|
-
pageSize:
|
|
296
|
+
rows: bt,
|
|
297
|
+
isLoading: !Qe && (!b || Ze && !v || S && R.isLoading),
|
|
298
|
+
isError: Qe || S && R.isError,
|
|
299
|
+
showPagination: S && kt && !R.isError,
|
|
300
|
+
isPreviousPageDisabled: !Et,
|
|
301
|
+
isNextPageDisabled: !Tt,
|
|
302
|
+
pageSize: N,
|
|
301
303
|
pageSizeOptions: Le,
|
|
302
|
-
rangeLabel:
|
|
304
|
+
rangeLabel: Ft,
|
|
303
305
|
onPageSizeChange: (e) => {
|
|
304
|
-
|
|
306
|
+
ut(e), M(void 0), P(0);
|
|
305
307
|
},
|
|
306
|
-
autoFocusRowKey:
|
|
308
|
+
autoFocusRowKey: pt,
|
|
307
309
|
onPreviousPageClick: () => {
|
|
308
|
-
|
|
310
|
+
M(Et ?? void 0), P((e) => Math.max(0, e - 1));
|
|
309
311
|
},
|
|
310
312
|
onNextPageClick: () => {
|
|
311
|
-
|
|
313
|
+
M(Tt ?? void 0), P((e) => e + 1);
|
|
312
314
|
},
|
|
313
|
-
onInviteClick:
|
|
315
|
+
onInviteClick: Ct ? G.openInviteForm : void 0,
|
|
314
316
|
labels: r
|
|
315
317
|
})
|
|
316
318
|
})
|
|
317
319
|
}),
|
|
318
320
|
/* @__PURE__ */ d(o, {
|
|
319
|
-
open:
|
|
321
|
+
open: q.isDeactivateOpen,
|
|
320
322
|
icon: /* @__PURE__ */ d(Me, {
|
|
321
323
|
"aria-hidden": !0,
|
|
322
324
|
className: "ttw:size-6"
|
|
323
325
|
}),
|
|
324
326
|
title: h.deactivateDialogTitle,
|
|
325
327
|
description: h.deactivateDialogDescription,
|
|
326
|
-
subjectName:
|
|
327
|
-
subjectDetail:
|
|
328
|
+
subjectName: q.deactivateMemberName,
|
|
329
|
+
subjectDetail: q.deactivateMemberEmail,
|
|
328
330
|
confirmButtonLabel: h.deactivateConfirmButton,
|
|
329
|
-
errorMessage:
|
|
330
|
-
isConfirming:
|
|
331
|
-
onOpenChange:
|
|
332
|
-
onConfirm:
|
|
331
|
+
errorMessage: q.deactivateErrorMessage,
|
|
332
|
+
isConfirming: q.isDeactivating,
|
|
333
|
+
onOpenChange: q.onDeactivateOpenChange,
|
|
334
|
+
onConfirm: q.onDeactivateConfirm,
|
|
333
335
|
labels: r
|
|
334
336
|
}),
|
|
335
337
|
/* @__PURE__ */ d(o, {
|
|
336
|
-
open:
|
|
338
|
+
open: q.isResendOpen,
|
|
337
339
|
icon: /* @__PURE__ */ d(Pe, {
|
|
338
340
|
"aria-hidden": !0,
|
|
339
341
|
className: "ttw:size-6"
|
|
340
342
|
}),
|
|
341
343
|
title: h.resendDialogTitle,
|
|
342
344
|
description: h.resendDialogDescription,
|
|
343
|
-
subjectName:
|
|
344
|
-
subjectDetail:
|
|
345
|
+
subjectName: q.resendMemberName,
|
|
346
|
+
subjectDetail: q.resendMemberEmail,
|
|
345
347
|
confirmButtonLabel: h.resendConfirmButton,
|
|
346
348
|
confirmVariant: "default",
|
|
347
|
-
errorMessage:
|
|
348
|
-
isConfirming:
|
|
349
|
-
onOpenChange:
|
|
350
|
-
onConfirm:
|
|
349
|
+
errorMessage: q.resendErrorMessage,
|
|
350
|
+
isConfirming: q.isResending,
|
|
351
|
+
onOpenChange: q.onResendOpenChange,
|
|
352
|
+
onConfirm: q.onResendConfirm,
|
|
351
353
|
labels: r
|
|
352
354
|
})
|
|
353
355
|
] });
|
package/dist/libs/tesouro-embedded-components-react/settings-widget/team/feature/dist/index3.js
CHANGED
|
@@ -10,6 +10,7 @@ var e = {
|
|
|
10
10
|
emailInvalidError: "Enter a valid email address.",
|
|
11
11
|
roleRequiredError: "Choose a role for the member.",
|
|
12
12
|
inviteSuccessToast: "Invite sent.",
|
|
13
|
+
inviteCardAccessWarningToast: "Invite sent, but the member could not be granted access to every card.",
|
|
13
14
|
resendSuccessToast: "Invite resent.",
|
|
14
15
|
inviteFailedError: "Something went wrong while sending the invite. Please try again.",
|
|
15
16
|
editFailedError: "Something went wrong while saving the changes. Please try again.",
|
|
@@ -18,6 +19,7 @@ var e = {
|
|
|
18
19
|
loadAccessFailedError: "We couldn’t load this member’s account access. Please try again.",
|
|
19
20
|
roleNeedsAccountAccessError: "Assigning the Admin or Employee role changes account access, which requires the account-access permission. Ask an admin with that permission to make this change.",
|
|
20
21
|
rolePermissionsUnavailableError: "We couldn’t check this role’s account-access permissions. Please try again.",
|
|
22
|
+
debitCardsUnavailableError: "We couldn’t load this company’s cards to grant this role access to them. Please try again.",
|
|
21
23
|
accountAccessAll: "All accounts",
|
|
22
24
|
accountAccessNone: "This member doesn’t have access to any account.",
|
|
23
25
|
accountAccessCountSingular: "account",
|
package/dist/libs/tesouro-embedded-components-react/settings-widget/team/feature/dist/index7.js
CHANGED
|
@@ -5,25 +5,29 @@ var t = e.BankAccountWriteOrg, n = [e.BankAccountReadOrg, e.ExternalBankAccountR
|
|
|
5
5
|
function r(e) {
|
|
6
6
|
return !!e?.has(t);
|
|
7
7
|
}
|
|
8
|
-
|
|
8
|
+
var i = e.DebitCardIssueOrg;
|
|
9
|
+
function a(e) {
|
|
10
|
+
return !!e?.has(i);
|
|
11
|
+
}
|
|
12
|
+
function o(e) {
|
|
9
13
|
return e ? !n.some((t) => e.has(t)) : !1;
|
|
10
14
|
}
|
|
11
|
-
function
|
|
15
|
+
function s(e, t) {
|
|
12
16
|
return e && !t;
|
|
13
17
|
}
|
|
14
|
-
function
|
|
18
|
+
function c(e) {
|
|
15
19
|
return `••••${(e ?? "").trim().slice(-4)}`;
|
|
16
20
|
}
|
|
17
|
-
function
|
|
21
|
+
function l(e, t) {
|
|
18
22
|
return e?.trim() || t;
|
|
19
23
|
}
|
|
20
|
-
function
|
|
24
|
+
function u(e, t, n) {
|
|
21
25
|
let r = [], i = /* @__PURE__ */ new Map();
|
|
22
26
|
for (let t of e) {
|
|
23
|
-
let e =
|
|
27
|
+
let e = c(t.accountNumber);
|
|
24
28
|
r.push({
|
|
25
29
|
value: t.id,
|
|
26
|
-
name:
|
|
30
|
+
name: l(t.nickname, e),
|
|
27
31
|
typeLabel: n.checking,
|
|
28
32
|
maskedNumber: e,
|
|
29
33
|
source: "internal"
|
|
@@ -33,10 +37,10 @@ function c(e, t, n) {
|
|
|
33
37
|
});
|
|
34
38
|
}
|
|
35
39
|
for (let e of t) {
|
|
36
|
-
let t =
|
|
40
|
+
let t = c(e.accountNumber);
|
|
37
41
|
r.push({
|
|
38
42
|
value: e.id,
|
|
39
|
-
name:
|
|
43
|
+
name: l(e.nickname, t),
|
|
40
44
|
typeLabel: e.type === "SAVINGS" ? n.savings : n.checking,
|
|
41
45
|
maskedNumber: t,
|
|
42
46
|
source: "external"
|
|
@@ -51,11 +55,11 @@ function c(e, t, n) {
|
|
|
51
55
|
allAccountIds: r.map((e) => e.value)
|
|
52
56
|
};
|
|
53
57
|
}
|
|
54
|
-
function
|
|
58
|
+
function d(e, t) {
|
|
55
59
|
return e.map((e) => t.get(e)).filter((e) => !!e);
|
|
56
60
|
}
|
|
57
|
-
function
|
|
61
|
+
function f({ isAdmin: e, accessibleCount: t, totalCount: n, labels: r }) {
|
|
58
62
|
return e ? r.accountAccessAll : t <= 0 ? r.accountAccessNone : `${t} ${t === 1 ? r.accountAccessCountSingular : r.accountAccessCountPlural}${n > 0 ? ` ${r.accountAccessOf} ${n}` : ""}`;
|
|
59
63
|
}
|
|
60
64
|
//#endregion
|
|
61
|
-
export { t as ACCOUNT_ACCESS_ADMIN_PERMISSION_KEY, n as ACCOUNT_ACCESS_VISIBILITY_PERMISSION_KEYS,
|
|
65
|
+
export { t as ACCOUNT_ACCESS_ADMIN_PERMISSION_KEY, n as ACCOUNT_ACCESS_VISIBILITY_PERMISSION_KEYS, i as DEBIT_CARD_ADMIN_PERMISSION_KEY, f as formatAccountAccessLabel, s as isAccountsSectionVisibleForRole, r as isAdminPermissionSet, a as isDebitCardAdminPermissionSet, o as isEmployeePermissionSet, c as maskAccountNumber, d as toAccountAccessInputs, u as toAccountAccessOptions };
|