@layers-app/shared 0.4.10 → 0.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.
Files changed (57) hide show
  1. package/dist/components/AppContainer/AppContainer.js +24 -24
  2. package/dist/components/AppContainer/components/Header.d.ts +3 -1
  3. package/dist/components/AppContainer/components/Header.d.ts.map +1 -1
  4. package/dist/components/AppContainer/components/Header.js +9 -6
  5. package/dist/components/AppContainer/components/menus/HelpMenu/HelpMenu.module.css.js +102 -102
  6. package/dist/components/AppContainer/hooks/useAppContainerStore.d.ts +2 -2
  7. package/dist/components/AppContainer/hooks/useAppContainerStore.d.ts.map +1 -1
  8. package/dist/components/AppContainer/hooks/useAppContainerStore.js +20 -19
  9. package/dist/components/ColorPicker/icons.js +5 -5
  10. package/dist/components/MeetingPage/MeetingObjectAttitude.d.ts.map +1 -1
  11. package/dist/components/MeetingPage/MeetingObjectAttitude.js +64 -68
  12. package/dist/components/MeetingPage/MeetingObjectCard.d.ts.map +1 -1
  13. package/dist/components/MeetingPage/MeetingObjectCard.js +108 -109
  14. package/dist/components/MeetingPage/MeetingObjectDirectory.d.ts.map +1 -1
  15. package/dist/components/MeetingPage/MeetingObjectDirectory.js +85 -80
  16. package/dist/components/MeetingPage/MeetingObjectEditor.d.ts.map +1 -1
  17. package/dist/components/MeetingPage/MeetingObjectEditor.js +144 -140
  18. package/dist/components/MeetingPage/MeetingPanelError.d.ts.map +1 -1
  19. package/dist/components/MeetingPage/MeetingPanelError.js +17 -16
  20. package/dist/components/MeetingPage/MeetingPersonAppearances.d.ts.map +1 -1
  21. package/dist/components/MeetingPage/MeetingPersonAppearances.js +63 -55
  22. package/dist/components/MeetingPage/meetingAppearances.d.ts.map +1 -1
  23. package/dist/components/MeetingPage/meetingAppearances.js +29 -28
  24. package/dist/components/MeetingPage/meetingObjects.d.ts +8 -2
  25. package/dist/components/MeetingPage/meetingObjects.d.ts.map +1 -1
  26. package/dist/components/MeetingPage/meetingObjects.js +28 -31
  27. package/dist/components/MeetingPage/objectAttitude.d.ts +9 -2
  28. package/dist/components/MeetingPage/objectAttitude.d.ts.map +1 -1
  29. package/dist/components/MeetingPage/objectAttitude.js +88 -89
  30. package/dist/components/Notification/InfiniteScroll.js +10 -10
  31. package/dist/components/Notification/Notification.module.css.js +24 -20
  32. package/dist/components/Notification/atoms/UnreadDot.d.ts.map +1 -1
  33. package/dist/components/Notification/atoms/UnreadDot.js +4 -4
  34. package/dist/components/Notification/molecules/InboxEmpty.d.ts.map +1 -1
  35. package/dist/components/Notification/molecules/InboxEmpty.js +17 -15
  36. package/dist/components/Notification/molecules/InboxHeader.d.ts.map +1 -1
  37. package/dist/components/Notification/molecules/InboxHeader.js +26 -26
  38. package/dist/components/Notification/molecules/InboxTabs.d.ts.map +1 -1
  39. package/dist/components/Notification/molecules/InboxTabs.js +33 -22
  40. package/dist/components/Notification/molecules/NotificationContent.d.ts.map +1 -1
  41. package/dist/components/Notification/molecules/NotificationContent.js +121 -121
  42. package/dist/components/Notification/organisms/InboxItem.d.ts.map +1 -1
  43. package/dist/components/Notification/organisms/InboxItem.js +23 -22
  44. package/dist/components/Notification/organisms/InboxPanel.js +1 -1
  45. package/dist/components/StorageUsageProgress/index.d.ts.map +1 -1
  46. package/dist/components/StorageUsageProgress/index.js +1 -3
  47. package/dist/components/WorkspaceMenu/WorkspaceMenu.js +10 -7
  48. package/dist/config/envConfig.d.ts +3 -0
  49. package/dist/config/envConfig.d.ts.map +1 -1
  50. package/dist/index.css +1 -1
  51. package/dist/lang/locales/ui_en.json.js +20 -18
  52. package/dist/lang/locales/ui_es.json.js +30 -28
  53. package/dist/lang/locales/ui_ru.json.js +24 -22
  54. package/dist/utils/formatStorage.d.ts +6 -5
  55. package/dist/utils/formatStorage.d.ts.map +1 -1
  56. package/dist/utils/formatStorage.js +21 -11
  57. package/package.json +1 -1
@@ -1,77 +1,78 @@
1
- import { jsxs as n, jsx as t, Fragment as J } from "react/jsx-runtime";
2
- import { useState as i, useCallback as T, useEffect as P } from "react";
3
- import { MeetingObjectCard as V } from "./MeetingObjectCard.js";
4
- import { listAliases as X, listRelations as Y, listObjects as z, mergeObjects as _, removeAlias as $, addAlias as F, removeRelation as ee, addRelation as ae } from "./meetingObjects.js";
5
- import a from "./MeetingPage.module.css.js";
1
+ import { jsxs as n, jsx as i, Fragment as q } from "react/jsx-runtime";
2
+ import { useState as s, useCallback as J, useEffect as D } from "react";
3
+ import { useTranslation as V } from "react-i18next";
4
+ import { MeetingObjectCard as X } from "./MeetingObjectCard.js";
5
+ import { listAliases as Y, listRelations as $, listObjects as G, removeAlias as ee, addAlias as H, removeRelation as te, addRelation as ae, mergeObjects as ie } from "./meetingObjects.js";
6
+ import t from "./MeetingPage.module.css.js";
6
7
  function ce({
7
8
  workspaceId: u,
8
- objectType: l,
9
- objectId: s,
10
- onChanged: v,
11
- onMerged: G
9
+ objectType: r,
10
+ objectId: l,
11
+ onChanged: f,
12
+ onMerged: L
12
13
  }) {
13
- const [C, Q] = i([]), [O, W] = i([]), [Z, K] = i(/* @__PURE__ */ new Map()), [o, f] = i(""), [c, p] = i(!1), [k, h] = i(null), [b, w] = i(""), [B, S] = i(""), [y, E] = i(""), [A, M] = i(""), [I, U] = i([]), [g, j] = i(""), [x, q] = i([]), R = T(() => {
14
+ const { t: a } = V("ui"), [k, W] = s([]), [C, Q] = s([]), [Z, K] = s(/* @__PURE__ */ new Map()), [c, b] = s(""), [o, p] = s(!1), [w, h] = s(null), [y, F] = s(""), [S, T] = s(""), [A, B] = s(""), [R, P] = s(""), [E, U] = s([]), [N, _] = s(""), [M, j] = s([]), O = J(() => {
14
15
  let e = !1;
15
16
  return Promise.all([
16
- X(l, s),
17
- Y(l, s, null)
18
- ]).then(([r, m]) => {
19
- e || (Q(r), W(m));
17
+ Y(r, l),
18
+ $(r, l, null)
19
+ ]).then(([d, g]) => {
20
+ e || (W(d), Q(g));
20
21
  }), () => {
21
22
  e = !0;
22
23
  };
23
- }, [l, s]);
24
- P(R, [R]), P(() => {
24
+ }, [r, l]);
25
+ D(O, [O]), D(() => {
25
26
  let e = !1;
26
27
  return Promise.all([
27
- z("ORGANIZATION", u),
28
- z(l, u)
29
- ]).then(([r, m]) => {
28
+ G("ORGANIZATION", u),
29
+ G(r, u)
30
+ ]).then(([d, g]) => {
30
31
  if (e) return;
31
- const D = r.data, H = m.data;
32
- U(D), q(H.filter((N) => N.id !== s));
33
- const L = /* @__PURE__ */ new Map();
34
- [...D, ...H].forEach((N) => L.set(N.id, N.displayName)), K(L);
32
+ const z = d.data, I = g.data;
33
+ U(z), j(I.filter((v) => v.id !== l));
34
+ const x = /* @__PURE__ */ new Map();
35
+ [...z, ...I].forEach((v) => x.set(v.id, v.displayName)), K(x);
35
36
  }), () => {
36
37
  e = !0;
37
38
  };
38
- }, [u, l, s]);
39
- const d = async (e, r) => {
39
+ }, [u, r, l]);
40
+ const m = async (e, d) => {
40
41
  p(!0), h(null);
41
- const m = await e();
42
- if (p(!1), !m) {
43
- h(r);
42
+ const g = await e();
43
+ if (p(!1), !g) {
44
+ h(d);
44
45
  return;
45
46
  }
46
- R(), v();
47
+ O(), f();
47
48
  };
48
- return /* @__PURE__ */ n("div", { className: a.editor, "data-cy": "meeting-object-editor", children: [
49
- /* @__PURE__ */ t(
50
- V,
49
+ return /* @__PURE__ */ n("div", { className: t.editor, "data-cy": "meeting-object-editor", children: [
50
+ /* @__PURE__ */ i(
51
+ X,
51
52
  {
52
- objectType: l,
53
- objectId: s,
53
+ objectType: r,
54
+ objectId: l,
54
55
  appearancesLimit: 6,
55
56
  workspaceId: u,
56
- onChanged: v
57
+ onChanged: f
57
58
  },
58
- s
59
+ l
59
60
  ),
60
- /* @__PURE__ */ n("div", { className: a.editorBlock, children: [
61
- /* @__PURE__ */ t("span", { className: a.appearancesTitle, children: "Ещё его так называют" }),
62
- C.length > 0 && /* @__PURE__ */ t("span", { className: a.chips, children: C.map((e) => /* @__PURE__ */ n("span", { className: a.chipQuiet, children: [
61
+ /* @__PURE__ */ n("div", { className: t.editorBlock, children: [
62
+ /* @__PURE__ */ i("span", { className: t.appearancesTitle, children: a("meeting.editor.aliasesTitle") }),
63
+ k.length > 0 && /* @__PURE__ */ i("span", { className: t.chips, children: k.map((e) => /* @__PURE__ */ n("span", { className: t.chipQuiet, children: [
63
64
  e.alias,
64
- /* @__PURE__ */ t(
65
+ /* @__PURE__ */ i(
65
66
  "button",
66
67
  {
67
68
  type: "button",
68
- className: a.chipRemove,
69
- disabled: c,
70
- title: "Убрать синоним",
69
+ className: t.chipRemove,
70
+ disabled: o,
71
+ title: a("meeting.editor.aliasRemove"),
71
72
  onClick: () => {
72
- d(
73
- () => $(l, s, e.id),
74
- "Не убралось — попробуйте ещё раз"
73
+ m(
74
+ () => ee(r, l, e.id),
75
+ a("meeting.editor.removeFailed")
75
76
  );
76
77
  },
77
78
  "data-cy": "meeting-alias-remove",
@@ -79,193 +80,196 @@ function ce({
79
80
  }
80
81
  )
81
82
  ] }, e.id)) }),
82
- /* @__PURE__ */ n("span", { className: a.editorRow, children: [
83
- /* @__PURE__ */ t(
83
+ /* @__PURE__ */ n("span", { className: t.editorRow, children: [
84
+ /* @__PURE__ */ i(
84
85
  "input",
85
86
  {
86
- className: a.namingInput,
87
- value: o,
88
- placeholder: "Ещё одно имя",
89
- disabled: c,
90
- onChange: (e) => f(e.target.value),
87
+ className: t.namingInput,
88
+ value: c,
89
+ placeholder: a("meeting.editor.aliasPlaceholder"),
90
+ disabled: o,
91
+ onChange: (e) => b(e.target.value),
91
92
  onKeyDown: (e) => {
92
- e.key !== "Enter" || !o.trim() || d(async () => {
93
- const r = await F(l, s, o);
94
- return r && f(""), !!r;
95
- }, "Не сохранилось — возможно, такое имя уже занято");
93
+ e.key !== "Enter" || !c.trim() || m(async () => {
94
+ const d = await H(r, l, c);
95
+ return d && b(""), !!d;
96
+ }, a("meeting.editor.aliasFailed"));
96
97
  },
97
98
  "data-cy": "meeting-alias-input"
98
99
  }
99
100
  ),
100
- /* @__PURE__ */ t(
101
+ /* @__PURE__ */ i(
101
102
  "button",
102
103
  {
103
104
  type: "button",
104
- className: a.objectAction,
105
- disabled: c || !o.trim(),
105
+ className: t.objectAction,
106
+ disabled: o || !c.trim(),
106
107
  onClick: () => {
107
- d(async () => {
108
- const e = await F(l, s, o);
109
- return e && f(""), !!e;
110
- }, "Не сохранилось — возможно, такое имя уже занято");
108
+ m(async () => {
109
+ const e = await H(r, l, c);
110
+ return e && b(""), !!e;
111
+ }, a("meeting.editor.aliasFailed"));
111
112
  },
112
113
  "data-cy": "meeting-alias-add",
113
- children: "Добавить"
114
+ children: a("meeting.editor.aliasAdd")
114
115
  }
115
116
  )
116
117
  ] })
117
118
  ] }),
118
- /* @__PURE__ */ n("div", { className: a.editorBlock, children: [
119
- /* @__PURE__ */ t("span", { className: a.appearancesTitle, children: "Связи" }),
120
- O.length > 0 && /* @__PURE__ */ t("span", { className: a.editorList, children: O.map((e) => {
121
- const r = e.subjectId === s ? e.objectId : e.subjectId;
122
- return /* @__PURE__ */ n("span", { className: a.editorRow, children: [
123
- /* @__PURE__ */ n("span", { className: a.editorWhat, children: [
124
- e.roleTitle && /* @__PURE__ */ n("span", { className: a.objectRole, children: [
119
+ /* @__PURE__ */ n("div", { className: t.editorBlock, children: [
120
+ /* @__PURE__ */ i("span", { className: t.appearancesTitle, children: a("meeting.editor.relationsTitle") }),
121
+ C.length > 0 && /* @__PURE__ */ i("span", { className: t.editorList, children: C.map((e) => {
122
+ const d = e.subjectId === l ? e.objectId : e.subjectId;
123
+ return /* @__PURE__ */ n("span", { className: t.editorRow, children: [
124
+ /* @__PURE__ */ n("span", { className: t.editorWhat, children: [
125
+ e.roleTitle && /* @__PURE__ */ n("span", { className: t.objectRole, children: [
125
126
  e.roleTitle,
126
127
  " "
127
128
  ] }),
128
- /* @__PURE__ */ n("span", { className: a.objectWhere, children: [
129
- ",
130
- Z.get(r) ?? "…"
131
- ] }),
132
- /* @__PURE__ */ t("span", { className: a.objectPast, children: e.current ? "" : " — уже не так" })
129
+ /* @__PURE__ */ i("span", { className: t.objectWhere, children: a("meeting.editor.relationAt", {
130
+ name: Z.get(d) ?? "…"
131
+ }) }),
132
+ /* @__PURE__ */ i("span", { className: t.objectPast, children: e.current ? "" : a("meeting.editor.relationPast") })
133
133
  ] }),
134
- /* @__PURE__ */ t(
134
+ /* @__PURE__ */ i(
135
135
  "button",
136
136
  {
137
137
  type: "button",
138
- className: a.objectActionQuiet,
139
- disabled: c,
138
+ className: t.objectActionQuiet,
139
+ disabled: o,
140
140
  onClick: () => {
141
- d(
142
- () => ee(e.id),
143
- "Не убралось — попробуйте ещё раз"
141
+ m(
142
+ () => te(e.id),
143
+ a("meeting.editor.removeFailed")
144
144
  );
145
145
  },
146
146
  "data-cy": "meeting-relation-remove",
147
- children: "Убрать"
147
+ children: a("meeting.editor.relationRemove")
148
148
  }
149
149
  )
150
150
  ] }, e.id);
151
151
  }) }),
152
- I.length === 0 ? /* @__PURE__ */ t("span", { className: a.objectHint, children: "Организаций в пространстве ещё нет — связывать не с чем." }) : /* @__PURE__ */ n("span", { className: a.editorRow, children: [
152
+ E.length === 0 ? /* @__PURE__ */ i("span", { className: t.objectHint, children: a("meeting.editor.noOrganizations") }) : /* @__PURE__ */ n("span", { className: t.editorRow, children: [
153
153
  /* @__PURE__ */ n(
154
154
  "select",
155
155
  {
156
- className: a.namingInput,
157
- value: b,
158
- disabled: c,
159
- onChange: (e) => w(e.target.value),
156
+ className: t.namingInput,
157
+ value: y,
158
+ disabled: o,
159
+ onChange: (e) => F(e.target.value),
160
160
  "data-cy": "meeting-relation-target",
161
161
  children: [
162
- /* @__PURE__ */ t("option", { value: "", children: "Организация…" }),
163
- I.map((e) => /* @__PURE__ */ t("option", { value: e.id, children: e.displayName }, e.id))
162
+ /* @__PURE__ */ i("option", { value: "", children: a("meeting.editor.organizationOption") }),
163
+ E.map((e) => /* @__PURE__ */ i("option", { value: e.id, children: e.displayName }, e.id))
164
164
  ]
165
165
  }
166
166
  ),
167
- /* @__PURE__ */ t(
167
+ /* @__PURE__ */ i(
168
168
  "input",
169
169
  {
170
- className: a.namingInput,
171
- value: B,
172
- placeholder: "Должность",
173
- disabled: c,
174
- onChange: (e) => S(e.target.value),
170
+ className: t.namingInput,
171
+ value: S,
172
+ placeholder: a("meeting.editor.rolePlaceholder"),
173
+ disabled: o,
174
+ onChange: (e) => T(e.target.value),
175
175
  "data-cy": "meeting-relation-role"
176
176
  }
177
177
  ),
178
- /* @__PURE__ */ t(
178
+ /* @__PURE__ */ i(
179
179
  "input",
180
180
  {
181
- className: a.namingInput,
181
+ className: t.namingInput,
182
182
  type: "date",
183
- value: y,
184
- title: "С какого дня",
185
- disabled: c,
186
- onChange: (e) => E(e.target.value)
183
+ value: A,
184
+ title: a("meeting.editor.sinceTitle"),
185
+ disabled: o,
186
+ onChange: (e) => B(e.target.value)
187
187
  }
188
188
  ),
189
- /* @__PURE__ */ t(
189
+ /* @__PURE__ */ i(
190
190
  "input",
191
191
  {
192
- className: a.namingInput,
192
+ className: t.namingInput,
193
193
  type: "date",
194
- value: A,
195
- title: "По какой день — пусто, если всё ещё так",
196
- disabled: c,
197
- onChange: (e) => M(e.target.value)
194
+ value: R,
195
+ title: a("meeting.editor.untilTitle"),
196
+ disabled: o,
197
+ onChange: (e) => P(e.target.value)
198
198
  }
199
199
  ),
200
- /* @__PURE__ */ t(
200
+ /* @__PURE__ */ i(
201
201
  "button",
202
202
  {
203
203
  type: "button",
204
- className: a.objectAction,
205
- disabled: c || !b,
204
+ className: t.objectAction,
205
+ disabled: o || !y,
206
206
  onClick: () => {
207
- d(async () => {
207
+ m(async () => {
208
208
  const e = await ae(
209
+ r,
209
210
  l,
210
- s,
211
- { objectType: "ORGANIZATION", objectId: b },
212
- B,
213
- y ? new Date(y).toISOString() : null,
214
- A ? new Date(A).toISOString() : null
211
+ { objectType: "ORGANIZATION", objectId: y },
212
+ S,
213
+ A ? new Date(A).toISOString() : null,
214
+ R ? new Date(R).toISOString() : null
215
215
  );
216
- return e && (w(""), S(""), E(""), M("")), !!e;
217
- }, "Связь не сохранилась — проверьте даты");
216
+ return e && (F(""), T(""), B(""), P("")), !!e;
217
+ }, a("meeting.editor.relationFailed"));
218
218
  },
219
219
  "data-cy": "meeting-relation-add",
220
- children: "Связать"
220
+ children: a("meeting.editor.relationAdd")
221
221
  }
222
222
  )
223
223
  ] })
224
224
  ] }),
225
- /* @__PURE__ */ n("div", { className: a.editorBlock, children: [
226
- /* @__PURE__ */ t("span", { className: a.appearancesTitle, children: "Это тот же самый" }),
227
- x.length === 0 ? /* @__PURE__ */ t("span", { className: a.objectHint, children: "Другого такого объекта в пространстве нет — сливать не с кем." }) : /* @__PURE__ */ n(J, { children: [
228
- /* @__PURE__ */ t("span", { className: a.objectHint, children: "Встречи, упоминания и синонимы уйдут тому, кто остаётся." }),
229
- /* @__PURE__ */ n("span", { className: a.editorRow, children: [
225
+ /* @__PURE__ */ n("div", { className: t.editorBlock, children: [
226
+ /* @__PURE__ */ i("span", { className: t.appearancesTitle, children: a("meeting.editor.mergeTitle") }),
227
+ M.length === 0 ? /* @__PURE__ */ i("span", { className: t.objectHint, children: a("meeting.editor.noSiblings") }) : /* @__PURE__ */ n(q, { children: [
228
+ /* @__PURE__ */ i("span", { className: t.objectHint, children: a("meeting.editor.mergeWarning") }),
229
+ /* @__PURE__ */ n("span", { className: t.editorRow, children: [
230
230
  /* @__PURE__ */ n(
231
231
  "select",
232
232
  {
233
- className: a.namingInput,
234
- value: g,
235
- disabled: c,
236
- onChange: (e) => j(e.target.value),
233
+ className: t.namingInput,
234
+ value: N,
235
+ disabled: o,
236
+ onChange: (e) => _(e.target.value),
237
237
  "data-cy": "meeting-merge-target",
238
238
  children: [
239
- /* @__PURE__ */ t("option", { value: "", children: "Это на самом деле…" }),
240
- x.map((e) => /* @__PURE__ */ t("option", { value: e.id, children: e.displayName }, e.id))
239
+ /* @__PURE__ */ i("option", { value: "", children: a("meeting.editor.mergeOption") }),
240
+ M.map((e) => /* @__PURE__ */ i("option", { value: e.id, children: e.displayName }, e.id))
241
241
  ]
242
242
  }
243
243
  ),
244
- /* @__PURE__ */ t(
244
+ /* @__PURE__ */ i(
245
245
  "button",
246
246
  {
247
247
  type: "button",
248
- className: a.objectAction,
249
- disabled: c || !g,
248
+ className: t.objectAction,
249
+ disabled: o || !N,
250
250
  onClick: () => {
251
- p(!0), h(null), _(l, s, g).then(
251
+ p(!0), h(null), ie(r, l, N).then(
252
252
  (e) => {
253
253
  if (p(!1), !e.ok) {
254
- h(e.reason);
254
+ h(
255
+ e.reason ?? a(
256
+ e.code === "NO_TARGET" ? "meeting.editor.mergePick" : "meeting.editor.mergeFailed"
257
+ )
258
+ );
255
259
  return;
256
260
  }
257
- v(), G(g);
261
+ f(), L(N);
258
262
  }
259
263
  );
260
264
  },
261
265
  "data-cy": "meeting-merge",
262
- children: "Слить"
266
+ children: a("meeting.editor.mergeAction")
263
267
  }
264
268
  )
265
269
  ] })
266
270
  ] })
267
271
  ] }),
268
- k && /* @__PURE__ */ t("span", { className: a.namingError, children: k })
272
+ w && /* @__PURE__ */ i("span", { className: t.namingError, children: w })
269
273
  ] });
270
274
  }
271
275
  export {
@@ -1 +1 @@
1
- {"version":3,"file":"MeetingPanelError.d.ts","sourceRoot":"","sources":["../../../src/components/MeetingPage/MeetingPanelError.tsx"],"names":[],"mappings":"AAEA,MAAM,WAAW,sBAAsB;IACrC,yFAAyF;IACzF,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,+FAA+F;IAC/F,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,6EAA6E;IAC7E,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,iBAAiB,CAAC,EAChC,OAAO,EACP,IAAI,EACJ,OAAO,EACP,UAAwB,EACxB,SAAS,EAAE,MAA8B,GAC1C,EAAE,sBAAsB,2CAsBxB"}
1
+ {"version":3,"file":"MeetingPanelError.d.ts","sourceRoot":"","sources":["../../../src/components/MeetingPage/MeetingPanelError.tsx"],"names":[],"mappings":"AAIA,MAAM,WAAW,sBAAsB;IACrC,yFAAyF;IACzF,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,+FAA+F;IAC/F,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,6EAA6E;IAC7E,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,iBAAiB,CAAC,EAChC,OAAO,EACP,IAAI,EACJ,OAAO,EACP,UAAU,EACV,SAAS,EAAE,MAA8B,GAC1C,EAAE,sBAAsB,2CAuBxB"}
@@ -1,27 +1,28 @@
1
- import { jsxs as c, jsx as a } from "react/jsx-runtime";
2
- import r from "./MeetingPage.module.css.js";
3
- function m({
4
- onRetry: e,
5
- what: t,
1
+ import { jsxs as p, jsx as o } from "react/jsx-runtime";
2
+ import { useTranslation as c } from "react-i18next";
3
+ import e from "./MeetingPage.module.css.js";
4
+ function E({
5
+ onRetry: t,
6
+ what: n,
6
7
  message: l,
7
- retryLabel: s = "Повторить",
8
- "data-cy": n = "meeting-panel-error"
8
+ retryLabel: s,
9
+ "data-cy": a = "meeting-panel-error"
9
10
  }) {
10
- const o = l ?? (t ? `Не удалось загрузить ${t}. Сбой на нашей стороне данные никуда не делись.` : "Не удалось загрузить. Сбой на нашей стороне — данные никуда не делись.");
11
- return /* @__PURE__ */ c("span", { className: r.panelError, role: "status", "data-cy": n, children: [
12
- /* @__PURE__ */ a("span", { className: r.panelErrorText, children: o }),
13
- e ? /* @__PURE__ */ a(
11
+ const { t: r } = c("ui"), i = l ?? (n ? r("meeting.panelError.textWhat", { what: n }) : r("meeting.panelError.text"));
12
+ return /* @__PURE__ */ p("span", { className: e.panelError, role: "status", "data-cy": a, children: [
13
+ /* @__PURE__ */ o("span", { className: e.panelErrorText, children: i }),
14
+ t ? /* @__PURE__ */ o(
14
15
  "button",
15
16
  {
16
17
  type: "button",
17
- className: r.panelErrorRetry,
18
- onClick: e,
19
- "data-cy": `${n}-retry`,
20
- children: s
18
+ className: e.panelErrorRetry,
19
+ onClick: t,
20
+ "data-cy": `${a}-retry`,
21
+ children: s ?? r("meeting.panelError.retry")
21
22
  }
22
23
  ) : null
23
24
  ] });
24
25
  }
25
26
  export {
26
- m as MeetingPanelError
27
+ E as MeetingPanelError
27
28
  };
@@ -1 +1 @@
1
- {"version":3,"file":"MeetingPersonAppearances.d.ts","sourceRoot":"","sources":["../../../src/components/MeetingPage/MeetingPersonAppearances.tsx"],"names":[],"mappings":"AAeA,MAAM,WAAW,6BAA6B;IAC5C,QAAQ,EAAE,MAAM,CAAC;IACjB,sGAAsG;IACtG,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,wBAAwB,CAAC,EACvC,QAAQ,EACR,KAAS,GACV,EAAE,6BAA6B,kDAiJ/B"}
1
+ {"version":3,"file":"MeetingPersonAppearances.d.ts","sourceRoot":"","sources":["../../../src/components/MeetingPage/MeetingPersonAppearances.tsx"],"names":[],"mappings":"AAgBA,MAAM,WAAW,6BAA6B;IAC5C,QAAQ,EAAE,MAAM,CAAC;IACjB,sGAAsG;IACtG,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED;;;;;;;;;;;;;;;GAeG;AACH,wBAAgB,wBAAwB,CAAC,EACvC,QAAQ,EACR,KAAS,GACV,EAAE,6BAA6B,kDAiK/B"}