@box/unified-share-modal 2.12.4 → 2.12.5

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.
@@ -4,7 +4,7 @@ import { CopyInput as B } from "@box/copy-input";
4
4
  import e from "./messages.js";
5
5
  import { jsx as o, jsxs as C, Fragment as x } from "react/jsx-runtime";
6
6
  import { useUnifiedShareModalContext as S } from "../../contexts/unified-share-modal-context.js";
7
- function D({
7
+ function j({
8
8
  canChange: k,
9
9
  isAvailable: f,
10
10
  isChecked: n,
@@ -37,7 +37,7 @@ function D({
37
37
  return /* @__PURE__ */ C(x, {
38
38
  children: [i ? /* @__PURE__ */ o(w, {
39
39
  content: i,
40
- "data-testid": "download-settings-tooltip",
40
+ "data-testid": "usm-DownloadSettings-tooltip",
41
41
  side: "left",
42
42
  children: /* @__PURE__ */ o(y, {
43
43
  children: /* @__PURE__ */ o(m.Item, {
@@ -58,5 +58,5 @@ function D({
58
58
  });
59
59
  }
60
60
  export {
61
- D as DownloadSection
61
+ j as DownloadSection
62
62
  };
@@ -18,10 +18,10 @@ function le() {
18
18
  const {
19
19
  formatMessage: e
20
20
  } = H(), [g, x] = B(!1), {
21
- collaborationRole: h,
21
+ collaborationRole: C,
22
22
  setCollaborationRole: m
23
23
  } = U(), {
24
- collaborationRoles: C,
24
+ collaborationRoles: h,
25
25
  eventService: T,
26
26
  isSubmitting: k,
27
27
  item: j,
@@ -31,34 +31,34 @@ function le() {
31
31
  type: p
32
32
  } = j, {
33
33
  onCollaborationRoleChange: v
34
- } = T, S = L === "desktop", r = F(() => C.map((l) => {
34
+ } = T, R = L === "desktop", r = F(() => h.map((l) => {
35
35
  const {
36
- description: b,
36
+ description: u,
37
37
  id: i,
38
38
  label: a
39
- } = l, u = A(i), d = w(i);
40
- let R = d;
41
- i === "editor" && p === "folder" && (R += "Folder");
39
+ } = l, b = A(i), d = w(i);
40
+ let _ = d;
41
+ i === "editor" && p === "folder" && (_ += "Folder");
42
42
  let I = i, M = "";
43
- return u && (I = e($[`${d}Role`]), M = e(n[`${R}Description`])), {
43
+ return b && (I = e($[`${d}Role`]), M = e(n[`${_}Description`])), {
44
44
  ...l,
45
- description: b ?? M,
45
+ description: u ?? M,
46
46
  label: a ?? I
47
47
  };
48
- }), [C, e, p]);
48
+ }), [h, e, p]);
49
49
  if (z(() => {
50
50
  m(E(r));
51
- }, [r, m]), !r.length || !h)
51
+ }, [r, m]), !r.length || !C)
52
52
  return null;
53
53
  const {
54
54
  id: N,
55
- label: _
56
- } = h;
55
+ label: S
56
+ } = C;
57
57
  let c;
58
58
  return y.canInviteCollaborator || (c = e(n.inviteDisabledTooltip)), p === "web_link" && (c = e(n.inviteWebLinkDisabledTooltip)), c ? /* @__PURE__ */ t(O, {
59
59
  align: "start",
60
60
  content: c,
61
- "data-testid": "collaboration-role-tooltip",
61
+ "data-testid": "usm-CollaborationRole-tooltip",
62
62
  side: "bottom",
63
63
  children: /* @__PURE__ */ t(P, {
64
64
  className: s.focusable,
@@ -67,14 +67,14 @@ function le() {
67
67
  className: s.button,
68
68
  disabled: !0,
69
69
  label: e(n.inviteAsRoleLabel, {
70
- role: _
70
+ role: S
71
71
  }),
72
72
  size: "extraSmall",
73
73
  variant: "tertiary"
74
74
  })
75
75
  })
76
76
  }) : /* @__PURE__ */ f(o.Root, {
77
- isFullScreenEnabled: S,
77
+ isFullScreenEnabled: R,
78
78
  menuItemsSize: "medium",
79
79
  onOpenChange: x,
80
80
  open: g,
@@ -85,7 +85,7 @@ function le() {
85
85
  "data-target-id": "PlainButton-InviteePermissionsMenuToggle",
86
86
  disabled: k,
87
87
  label: e(n.inviteAsRoleLabel, {
88
- role: _
88
+ role: S
89
89
  }),
90
90
  size: "extraSmall",
91
91
  variant: "tertiary"
@@ -93,7 +93,7 @@ function le() {
93
93
  }), /* @__PURE__ */ f(o.Content, {
94
94
  align: "start",
95
95
  className: s.content,
96
- children: [S && /* @__PURE__ */ f(o.Header, {
96
+ children: [R && /* @__PURE__ */ f(o.Header, {
97
97
  children: [/* @__PURE__ */ t(o.Header.MenuCloseButton, {
98
98
  "aria-label": e(n.closeButton),
99
99
  iconVariant: "back"
@@ -102,10 +102,10 @@ function le() {
102
102
  })]
103
103
  }), r.map((l) => {
104
104
  const {
105
- description: b,
105
+ description: u,
106
106
  isDisabled: i,
107
107
  id: a,
108
- label: u
108
+ label: b
109
109
  } = l, d = () => {
110
110
  m(l), v && v(a);
111
111
  };
@@ -114,9 +114,9 @@ function le() {
114
114
  disabled: i,
115
115
  onSelect: d,
116
116
  children: /* @__PURE__ */ t(o.Item.MainContent, {
117
- caption: b,
117
+ caption: u,
118
118
  className: s.option,
119
- label: u
119
+ label: b
120
120
  })
121
121
  }, a);
122
122
  })]
@@ -117,7 +117,7 @@ function ut() {
117
117
  };
118
118
  let f, b = !1;
119
119
  h && !$.canInviteCollaborator && (f = o(i.inviteDisabledTooltip), b = !0), h && H === "web_link" && (f = o(i.inviteWebLinkDisabledTooltip), b = !0);
120
- const N = Fe("user-contacts-"), ue = o(h ? i.invitePeopleLabel : i.emailSharedLinkLabel), he = _e(ue, N);
120
+ const N = Fe("usm-UserContacts-"), ue = o(h ? i.invitePeopleLabel : i.emailSharedLinkLabel), he = _e(ue, N);
121
121
  return /* @__PURE__ */ l("form", {
122
122
  className: c.container,
123
123
  onSubmit: (e) => e.preventDefault(),
@@ -130,19 +130,19 @@ function ut() {
130
130
  className: fe(c.label, R && c.modernized)
131
131
  }), /* @__PURE__ */ t(xe, {
132
132
  content: f,
133
- "data-testid": "user-contacts-tooltip",
133
+ "data-testid": "usm-UserContacts-tooltip",
134
134
  open: f ? void 0 : !1,
135
135
  side: "bottom",
136
136
  children: /* @__PURE__ */ t(Ee, {
137
137
  focusable: b,
138
138
  children: /* @__PURE__ */ t(Me, {
139
- className: "collaboration-user-selector",
139
+ className: "usm-UserContacts-input",
140
140
  clearButtonAriaLabel: o(i.clearButton),
141
141
  clearOnBlur: !1,
142
142
  "data-target-id": "PillSelectorDropdown-AddNamesOrEmailAddresses",
143
143
  disabled: b || u,
144
144
  displayChipVariant: (e) => e.chipVariant,
145
- error: te["user-contact"],
145
+ error: te.userContacts,
146
146
  fetchAvatarUrls: se,
147
147
  fetchUsers: ne,
148
148
  hideOnEscape: ae,
@@ -1,14 +1,14 @@
1
- import D from "lodash/partition";
1
+ import K from "lodash/partition";
2
2
  import { useState as _, useEffect as k } from "react";
3
- import { useIntl as K, FormattedMessage as O } from "react-intl";
4
- import { Select as m, Link as P, InlineNotice as z, LoadingIndicator as G } from "@box/blueprint-web";
3
+ import { useIntl as O, FormattedMessage as P } from "react-intl";
4
+ import { Select as m, Link as z, InlineNotice as G, LoadingIndicator as T } from "@box/blueprint-web";
5
5
  import t from "./messages.js";
6
6
  import { jsx as i } from "react/jsx-runtime";
7
- import { isCollaboratorRestricted as T } from "../../../utils/collaborator.js";
8
- import { useUnifiedShareFormContext as V } from "../../../contexts/unified-share-form-context.js";
7
+ import { isCollaboratorRestricted as V } from "../../../utils/collaborator.js";
8
+ import { useUnifiedShareFormContext as q } from "../../../contexts/unified-share-form-context.js";
9
9
  import { useUnifiedShareModalContext as H } from "../../../contexts/unified-share-modal-context.js";
10
10
  import { callOnKeyboardEvent as Q } from "../../../utils/event.js";
11
- import '../../../../../styles/shield-restriction-notice.css';const W = "_select_19idq_1", X = "_link_19idq_5", Y = "_loading_19idq_9", Z = "_notice_19idq_15", r = {
11
+ import '../../../../../styles/shield-restriction-notice.css';const W = "_select_1e0dl_1", X = "_link_1e0dl_5", Y = "_loading_1e0dl_9", Z = "_notice_1e0dl_15", r = {
12
12
  select: W,
13
13
  link: X,
14
14
  loading: Y,
@@ -21,12 +21,12 @@ function lt({
21
21
  }) {
22
22
  const {
23
23
  formatMessage: s
24
- } = K(), [g, R] = _(!1), [c, J] = _([]), {
24
+ } = O(), [g, R] = _(!1), [c, J] = _([]), {
25
25
  setShieldRestriction: o,
26
26
  setUserContacts: j,
27
27
  shieldRestriction: I,
28
28
  userContacts: y
29
- } = V(), {
29
+ } = q(), {
30
30
  eventService: w,
31
31
  item: v,
32
32
  contactService: x
@@ -63,18 +63,18 @@ function lt({
63
63
  }
64
64
  })();
65
65
  }, [v, l, a, c, o]);
66
- const q = a ? t.justifiableContactRestrictionRemoveButtonLabel : t.contactRestrictionRemoveButtonLabel, S = () => {
67
- const [e, n] = D(y, (d) => T(d, p, C));
66
+ const B = a ? t.justifiableContactRestrictionRemoveButtonLabel : t.contactRestrictionRemoveButtonLabel, S = () => {
67
+ const [e, n] = K(y, (d) => V(d, p, C));
68
68
  N(n), j(n), b && b(e);
69
- }, B = (e) => {
69
+ }, F = (e) => {
70
70
  o({
71
71
  justificationReason: c.find((n) => n.id === e)
72
72
  });
73
- }, F = /* @__PURE__ */ i(m, {
73
+ }, M = /* @__PURE__ */ i(m, {
74
74
  className: r.select,
75
75
  hideLabel: !0,
76
76
  label: s(t.businessJustification),
77
- onValueChange: B,
77
+ onValueChange: F,
78
78
  placeholder: s(t.justificationSelectPlaceholder),
79
79
  value: I.justificationReason?.id,
80
80
  children: /* @__PURE__ */ i(m.Content, {
@@ -84,7 +84,7 @@ function lt({
84
84
  value: e.id
85
85
  }, e.id))
86
86
  })
87
- }), u = /* @__PURE__ */ i(P, {
87
+ }), u = /* @__PURE__ */ i(z, {
88
88
  "aria-disabled": h,
89
89
  className: r.link,
90
90
  onClick: S,
@@ -93,25 +93,25 @@ function lt({
93
93
  }),
94
94
  role: "button",
95
95
  tabIndex: h ? -1 : 0,
96
- children: s(q)
97
- }), M = () => A === "information_barrier" ? {
96
+ children: s(B)
97
+ }), U = () => A === "information_barrier" ? {
98
98
  message: t.contactRestrictionInformationBarrierNotice,
99
99
  count: f.length,
100
100
  removeLink: u
101
101
  } : !g && a && c?.length > 0 ? {
102
102
  message: t.justifiableContactRestrictionNotice,
103
103
  count: f.length,
104
- justificationSelect: F,
104
+ justificationSelect: M,
105
105
  removeLink: u
106
106
  } : {
107
107
  message: t.contactRestrictionNotice,
108
108
  count: f.length,
109
109
  removeLink: u
110
110
  }, {
111
- message: U,
112
- ...E
113
- } = M();
114
- return /* @__PURE__ */ i(z, {
111
+ message: E,
112
+ ...D
113
+ } = U();
114
+ return /* @__PURE__ */ i(G, {
115
115
  className: r.notice,
116
116
  icon: () => null,
117
117
  role: "alert",
@@ -119,13 +119,13 @@ function lt({
119
119
  variantIconAriaLabel: s(t.errorNoticeIconAriaLabel),
120
120
  children: g ? /* @__PURE__ */ i("div", {
121
121
  className: r.loading,
122
- children: /* @__PURE__ */ i(G, {
122
+ children: /* @__PURE__ */ i(T, {
123
123
  "aria-label": s(t.loadingJustificationReasonsLabel),
124
124
  size: "small"
125
125
  })
126
- }) : /* @__PURE__ */ i(O, {
127
- ...U,
128
- values: E
126
+ }) : /* @__PURE__ */ i(P, {
127
+ ...E,
128
+ values: D
129
129
  })
130
130
  });
131
131
  }
@@ -1,7 +1,7 @@
1
1
  import { useState as E } from "react";
2
2
  import { useIntl as I } from "react-intl";
3
- import { Tooltip as O, Focusable as D, TriggerButton as f, DropdownMenu as t } from "@box/blueprint-web";
4
- import { FILE_EXTENSION_BOX_NOTE as P } from "../../../constants.js";
3
+ import { Tooltip as O, Focusable as P, TriggerButton as S, DropdownMenu as t } from "@box/blueprint-web";
4
+ import { FILE_EXTENSION_BOX_NOTE as D } from "../../../constants.js";
5
5
  import r from "./messages.js";
6
6
  import { jsx as e, jsxs as a } from "react/jsx-runtime";
7
7
  import { usePermissionLevels as w } from "../../../hooks/use-permission-levels.js";
@@ -15,20 +15,20 @@ import '../../../../../styles/shared-link-access.css';const H = "_button_166my_1
15
15
  function W() {
16
16
  const {
17
17
  formatMessage: o
18
- } = I(), [l, g] = E(!1), {
19
- isSubmitting: S,
20
- item: c,
18
+ } = I(), [c, f] = E(!1), {
19
+ isSubmitting: g,
20
+ item: l,
21
21
  sharedLink: _,
22
- sharingService: k,
23
- variant: L
22
+ sharingService: L,
23
+ variant: k
24
24
  } = A(), {
25
25
  permissions: x = {}
26
- } = c, {
26
+ } = l, {
27
27
  access: M,
28
28
  permission: d
29
29
  } = _, {
30
30
  changeSharedLinkPermission: C
31
- } = k, m = L === "desktop", {
31
+ } = L, m = k === "desktop", {
32
32
  onAction: N
33
33
  } = F(C), {
34
34
  allowedLevels: p,
@@ -40,13 +40,13 @@ function W() {
40
40
  label: b
41
41
  } = u;
42
42
  let i = "";
43
- return c.extension === P && d === "can_edit" && (i = o(r.canEditBoxNoteDisabledTooltip)), i ? /* @__PURE__ */ e(O, {
43
+ return l.extension === D && d === "can_edit" && (i = o(r.canEditBoxNoteDisabledTooltip)), i ? /* @__PURE__ */ e(O, {
44
44
  align: "start",
45
45
  content: i,
46
- "data-testid": "shared-link-permission-tooltip",
46
+ "data-testid": "usm-SharedLinkPermission-tooltip",
47
47
  side: "bottom",
48
- children: /* @__PURE__ */ e(D, {
49
- children: /* @__PURE__ */ e(f, {
48
+ children: /* @__PURE__ */ e(P, {
49
+ children: /* @__PURE__ */ e(S, {
50
50
  caretDirection: "down",
51
51
  className: n.button,
52
52
  disabled: !0,
@@ -57,14 +57,14 @@ function W() {
57
57
  })
58
58
  }) : /* @__PURE__ */ a(t.Root, {
59
59
  isFullScreenEnabled: m,
60
- onOpenChange: g,
61
- open: l,
60
+ onOpenChange: f,
61
+ open: c,
62
62
  children: [/* @__PURE__ */ e(t.Trigger, {
63
- children: /* @__PURE__ */ e(f, {
64
- caretDirection: l ? "up" : "down",
63
+ children: /* @__PURE__ */ e(S, {
64
+ caretDirection: c ? "up" : "down",
65
65
  className: n.button,
66
66
  "data-target-id": "Button-SharedLinkPermissionsMenuLabel",
67
- disabled: !x.canSetShareAccess || S,
67
+ disabled: !x.canSetShareAccess || g,
68
68
  label: b,
69
69
  size: "extraSmall",
70
70
  variant: "tertiary"
@@ -98,7 +98,7 @@ function we() {
98
98
  children: [/* @__PURE__ */ i(C, {
99
99
  align: "start",
100
100
  content: u,
101
- "data-testid": "shared-link-tooltip",
101
+ "data-testid": "usm-SharedLinkToggle-tooltip",
102
102
  open: u ? void 0 : !1,
103
103
  children: /* @__PURE__ */ i(J, {
104
104
  focusable: p,
@@ -115,7 +115,7 @@ function we() {
115
115
  content: e(t.expirationIconTooltip, {
116
116
  expirationDate: ce(r.expiresAt)
117
117
  }),
118
- "data-testid": "expiration-date-tooltip",
118
+ "data-testid": "usm-SharedLinkExpiration-tooltip",
119
119
  children: /* @__PURE__ */ i(W, {
120
120
  color: ee,
121
121
  hideText: !0,
@@ -1,49 +1,49 @@
1
1
  import A from "lodash/differenceBy";
2
- import O from "lodash/uniqBy";
2
+ import M from "lodash/uniqBy";
3
3
  import { useCallback as l } from "react";
4
- import { useUnifiedShareFormContext as M } from "../contexts/unified-share-form-context.js";
5
- import { useUnifiedShareModalContext as P } from "../contexts/unified-share-modal-context.js";
6
- import { useFormValidation as T } from "./use-form-validation.js";
7
- import { useSharingAction as D } from "./use-sharing-action.js";
8
- import { parseEmails as J } from "../utils/email.js";
9
- const Z = (y, F) => {
4
+ import { useUnifiedShareFormContext as T } from "../contexts/unified-share-form-context.js";
5
+ import { useUnifiedShareModalContext as D } from "../contexts/unified-share-modal-context.js";
6
+ import { useFormValidation as J } from "./use-form-validation.js";
7
+ import { useSharingAction as O } from "./use-sharing-action.js";
8
+ import { parseEmails as P } from "../utils/email.js";
9
+ const Z = (S, v) => {
10
10
  const {
11
11
  errors: h,
12
- setFieldError: a,
12
+ setFieldError: r,
13
13
  validateCollaborationLimit: c,
14
14
  validateUserContact: g,
15
15
  validateUserSelector: u
16
- } = T(), {
17
- config: U,
16
+ } = J(), {
17
+ config: F,
18
18
  contactService: w
19
- } = P(), {
19
+ } = D(), {
20
20
  collaborationLimit: i
21
- } = U, {
21
+ } = F, {
22
22
  collaborationRole: E,
23
- form: x,
24
- messageValue: L,
23
+ form: L,
24
+ messageValue: x,
25
25
  setContactValue: m,
26
26
  setMessageValue: R,
27
27
  setUserContacts: f,
28
28
  shieldRestriction: d,
29
- userContacts: s
30
- } = M(), {
29
+ userContacts: n
30
+ } = T(), {
31
31
  onAction: V
32
- } = D(y, F), {
33
- getContactsByEmail: p
34
- } = w, b = () => {
35
- f([]), m(""), R(""), a("user-contact", "");
32
+ } = O(S, v), {
33
+ getContactsByEmail: C
34
+ } = w, U = () => {
35
+ f([]), m(""), R(""), r("userContacts", "");
36
36
  }, B = l((t) => {
37
- c(s, i) || a("user-contact", ""), m(t);
38
- }, [i, m, a, s, c]), S = l(async (t) => {
39
- const n = {};
40
- if (p && t.length > 0) {
41
- const e = await p(t);
37
+ c(n, i) || r("userContacts", ""), m(t);
38
+ }, [i, m, r, n, c]), b = l(async (t) => {
39
+ const s = {};
40
+ if (C && t.length > 0) {
41
+ const e = await C(t);
42
42
  for (const o of Object.keys(e))
43
- n[o.toLowerCase()] = e[o];
43
+ s[o.toLowerCase()] = e[o];
44
44
  }
45
45
  return t.map((e) => {
46
- const o = n[e.toLowerCase()];
46
+ const o = s[e.toLowerCase()];
47
47
  return o || {
48
48
  email: e,
49
49
  id: 0,
@@ -53,40 +53,40 @@ const Z = (y, F) => {
53
53
  type: "user"
54
54
  };
55
55
  });
56
- }, [p]), C = l(async (t) => {
57
- a("user-contact", ""), u(t);
58
- let n;
59
- if (t.length <= s.length || t[t.length - 1].id !== void 0)
60
- n = t;
56
+ }, [C]), p = l(async (t) => {
57
+ r("userContacts", ""), u(t);
58
+ let s;
59
+ if (t.length <= n.length || t[t.length - 1].id !== void 0)
60
+ s = t;
61
61
  else {
62
- const e = t.slice(0, -1), o = t[t.length - 1].value, v = J(o);
63
- v.length === 0 && g(o);
64
- const j = e.filter((r) => r.email).map((r) => r.email), k = O(A(v, j, (r) => r.toLowerCase()), (r) => r.toLowerCase()), q = await S(k);
65
- n = [...e, ...q];
62
+ const e = t.slice(0, -1), o = t[t.length - 1].value, y = P(o);
63
+ y.length === 0 && g(o);
64
+ const j = e.filter((a) => a.email).map((a) => a.email), k = M(A(y, j, (a) => a.toLowerCase()), (a) => a.toLowerCase()), q = await b(k);
65
+ s = [...e, ...q];
66
66
  }
67
- i && c(n, i), f(n);
68
- }, [i, S, a, f, s, c, g, u]), I = l((t) => {
69
- const n = t.relatedTarget?.closest(".collaboration-user-selector");
70
- if (document.querySelector('div[role="listbox"][aria-labelledby^="user-contacts"]')?.contains(t.relatedTarget) || n)
67
+ i && c(s, i), f(s);
68
+ }, [i, b, r, f, n, c, g, u]), I = l((t) => {
69
+ const s = t.relatedTarget?.closest(".usm-UserContacts-input"), e = document.querySelector('[aria-labelledby^="usm-UserContacts-"]')?.contains(t.relatedTarget);
70
+ if (s || e)
71
71
  return;
72
72
  const o = t.target.value.trim();
73
- o && C([...s, {
73
+ o && p([...n, {
74
74
  value: o
75
75
  }]);
76
- }, [C, s]);
76
+ }, [p, n]);
77
77
  return {
78
78
  errors: h,
79
- handleFormReset: b,
79
+ handleFormReset: U,
80
80
  handleFormSubmit: async () => {
81
- if (h["user-contact"] || u(s))
81
+ if (h.userContacts || u(n))
82
82
  return !0;
83
83
  const t = {
84
- contacts: s,
85
- message: L
84
+ contacts: n,
85
+ message: x
86
86
  };
87
- return x === "invite" && (t.role = E.id), d.isJustificationAllowed && (t.justificationReason = d.justificationReason, t.classificationId = d.classificationId), await V(t), b(), !1;
87
+ return L === "invite" && (t.role = E.id), d.isJustificationAllowed && (t.justificationReason = d.justificationReason, t.classificationId = d.classificationId), await V(t), U(), !1;
88
88
  },
89
- handleSelectedUsersChange: C,
89
+ handleSelectedUsersChange: p,
90
90
  handleUserSelectorBlur: I,
91
91
  updateContactValue: B
92
92
  };
@@ -7,8 +7,8 @@ const U = () => {
7
7
  const {
8
8
  formatMessage: e
9
9
  } = w(), [f, u] = h({}), t = i((r, o) => {
10
- u((n) => ({
11
- ...n,
10
+ u((s) => ({
11
+ ...s,
12
12
  [r]: o
13
13
  }));
14
14
  }, []), m = i((r) => {
@@ -17,15 +17,15 @@ const U = () => {
17
17
  const o = N();
18
18
  return r.compare(o) < 0 ? (t("expiration", e(a.expirationFutureDateErrorMessage)), !0) : !1;
19
19
  }, [e, t]), C = i((r) => r ? y(r) ? !1 : (t("vanityName", e(a.vanityNameInvalidErrorMessage)), !0) : (t("vanityName", e(a.vanityNameRequiredErrorMessage)), !0), [e, t]), g = i((r, o) => {
20
- const n = r.filter((s) => s.chipVariant === "error");
20
+ const s = r.filter((n) => n.chipVariant === "error");
21
21
  return o.isJustificationAllowed && !o.justificationReason ? e(a.justificationRequiredErrorNotice, {
22
- count: n.length
23
- }) : n.length && !o.isJustificationAllowed ? e(a.restrictedContactsErrorNotice, {
24
- count: n.length
22
+ count: s.length
23
+ }) : s.length && !o.isJustificationAllowed ? e(a.restrictedContactsErrorNotice, {
24
+ count: s.length
25
25
  }) : "";
26
- }, [e]), v = i((r) => r.length ? !1 : (t("user-contact", e(a.emailRequiredErrorMessage)), !0), [e, t]), E = i((r, o) => r.filter((s) => s.value !== "").length <= o ? !1 : (t("user-contact", e(a.contactsLimitErrorMessage, {
26
+ }, [e]), v = i((r) => r.length ? !1 : (t("userContacts", e(a.emailRequiredErrorMessage)), !0), [e, t]), E = i((r, o) => r.filter((n) => n.value !== "").length <= o ? !1 : (t("userContacts", e(a.contactsLimitErrorMessage, {
27
27
  maxContacts: o
28
- })), !0), [e, t]), M = i((r) => r === "" ? !0 : P(r) ? !1 : (t("user-contact", e(a.invalidEmailErrorMessage)), !0), [e, t]), p = i((r) => b(r) ? V(r) ? (t("password", e(a.passwordContainInvalidCharacterErrorMessage)), !0) : !x(r) && !(l(r) && c(r)) && !(l(r) && d(r)) && !(c(r) && d(r)) ? (t("password", e(a.passwordContainLetterNumberOrSymbolErrorMessage)), !0) : !1 : (t("password", e(a.passwordContainMinCharactersErrorMessage)), !0), [e, t]);
28
+ })), !0), [e, t]), M = i((r) => r === "" ? !0 : P(r) ? !1 : (t("userContacts", e(a.invalidEmailErrorMessage)), !0), [e, t]), p = i((r) => b(r) ? V(r) ? (t("password", e(a.passwordContainInvalidCharacterErrorMessage)), !0) : !x(r) && !(l(r) && c(r)) && !(l(r) && d(r)) && !(c(r) && d(r)) ? (t("password", e(a.passwordContainLetterNumberOrSymbolErrorMessage)), !0) : !1 : (t("password", e(a.passwordContainMinCharactersErrorMessage)), !0), [e, t]);
29
29
  return {
30
30
  errors: f,
31
31
  validateCollaborationLimit: E,
@@ -1 +1 @@
1
- ._select_19idq_1{margin:var(--bp-space-030) 0}._link_19idq_5{cursor:pointer}._loading_19idq_9{display:flex;align-items:center;height:var(--bp-size-080)}._notice_19idq_15>div[class*=base-inline-notice_contentContainer]{gap:0}
1
+ ._select_1e0dl_1{margin:var(--bp-space-030) 0}._link_1e0dl_5{cursor:pointer}._loading_1e0dl_9{display:flex;align-items:center;height:var(--bp-size-080)}._notice_1e0dl_15>div[class*=base-inline-notice][class*=contentContainer]{gap:0}
package/package.json CHANGED
@@ -1,23 +1,23 @@
1
1
  {
2
2
  "name": "@box/unified-share-modal",
3
- "version": "2.12.4",
3
+ "version": "2.12.5",
4
4
  "license": "SEE LICENSE IN LICENSE",
5
5
  "peerDependencies": {
6
- "@box/blueprint-web": "^14.0.2",
7
- "@box/blueprint-web-assets": "^4.111.17",
8
- "@box/copy-input": "^1.40.21",
9
- "@box/user-selector": "^1.74.22",
6
+ "@box/blueprint-web": "^14.1.0",
7
+ "@box/blueprint-web-assets": "^4.111.18",
8
+ "@box/copy-input": "^1.40.22",
9
+ "@box/user-selector": "^1.74.23",
10
10
  "lodash": "^4.17.15",
11
11
  "react": "^18.0.0",
12
12
  "react-dom": "^18.0.0",
13
13
  "react-intl": "^6.4.2"
14
14
  },
15
15
  "devDependencies": {
16
- "@box/blueprint-web": "^14.0.2",
17
- "@box/blueprint-web-assets": "^4.111.17",
18
- "@box/copy-input": "^1.40.21",
19
- "@box/eslint-plugin-blueprint": "1.1.8",
20
- "@box/storybook-utils": "0.17.17",
16
+ "@box/blueprint-web": "^14.1.0",
17
+ "@box/blueprint-web-assets": "^4.111.18",
18
+ "@box/copy-input": "^1.40.22",
19
+ "@box/eslint-plugin-blueprint": "1.1.9",
20
+ "@box/storybook-utils": "0.17.18",
21
21
  "react-intl": "^6.4.2"
22
22
  },
23
23
  "publishConfig": {