mimir-ui-kit 1.65.6 → 1.65.7

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.
@@ -20,4 +20,8 @@ export declare const OtpInput: import('react').ForwardRefExoticComponent<Omit<TI
20
20
  * Флаг, показывающий нужно ли отображать разделитель между вводами.
21
21
  */
22
22
  needSeparator?: boolean;
23
+ /**
24
+ * Позиции полей, после которых отображаются разделители.
25
+ */
26
+ separatorPositions?: number[];
23
27
  } & import('react').RefAttributes<unknown>>;
@@ -1,62 +1,69 @@
1
- import { jsx as r, jsxs as g } from "react/jsx-runtime";
1
+ import { jsx as r, jsxs as v } from "react/jsx-runtime";
2
2
  import { c as u } from "../../index-DIxK0V-G.js";
3
- import { forwardRef as P, useImperativeHandle as R, Fragment as T } from "react";
4
- import { ITEMS_PER_SEPARATOR as v, DEFAULT_VALUE_LENGTH as y } from "./constants.js";
5
- import { useOTPInput as z } from "./hooks.js";
6
- import { I as A } from "../../Input-JwHUiwVK.js";
7
- import '../../assets/OtpInput.css';const C = "_otp_1ncuz_2", F = "_input_1ncuz_13", L = "_separator_1ncuz_27", n = {
8
- otp: C,
3
+ import { forwardRef as R, useImperativeHandle as T, Fragment as y } from "react";
4
+ import { DEFAULT_VALUE_LENGTH as z, ITEMS_PER_SEPARATOR as A } from "./constants.js";
5
+ import { useOTPInput as C } from "./hooks.js";
6
+ import { getValidSeparatorPositions as D, getDefaultSeparatorPositions as F } from "./utils.js";
7
+ import { I as L } from "../../Input-JwHUiwVK.js";
8
+ import '../../assets/OtpInput.css';const O = "_otp_1ncuz_2", j = "_input_1ncuz_13", x = "_separator_1ncuz_27", o = {
9
+ otp: O,
9
10
  "input-wrapper": "_input-wrapper_1ncuz_13",
10
- input: F,
11
- separator: L
12
- }, O = P(
11
+ input: j,
12
+ separator: x
13
+ }, H = R(
13
14
  ({
14
15
  value: c = "",
15
- valueLength: m = y,
16
- needSeparator: l = !0,
17
- onChange: i,
18
- className: _,
19
- ...d
20
- }, f) => {
16
+ valueLength: i = z,
17
+ needSeparator: m = !0,
18
+ onChange: l,
19
+ className: d,
20
+ separatorPositions: _,
21
+ ...f
22
+ }, h) => {
21
23
  const {
22
- data: { inputRefs: o, valueItems: p },
23
- handlers: { handleChange: h, handleFocus: I, handleKeyDown: w, handlePaste: N }
24
- } = z({
25
- onChange: i,
24
+ data: { inputRefs: s, valueItems: n },
25
+ handlers: { handleChange: g, handleFocus: I, handleKeyDown: P, handlePaste: w }
26
+ } = C({
27
+ onChange: l,
26
28
  value: c,
27
- valueLength: m
29
+ valueLength: i
28
30
  });
29
- return R(f, () => ({
31
+ T(h, () => ({
30
32
  focus: () => {
31
33
  var a;
32
- (a = o.current[0]) == null || a.focus();
34
+ (a = s.current[0]) == null || a.focus();
33
35
  }
34
- })), /* @__PURE__ */ r("div", { className: u(n.otp, _), children: p.map((a, e) => {
35
- const s = e + 1, E = l && s % v === 0 && s !== p.length;
36
- return /* @__PURE__ */ g(T, { children: [
36
+ }));
37
+ const p = D(
38
+ _,
39
+ n.length
40
+ ), N = p.length ? p : F(n.length, A);
41
+ return /* @__PURE__ */ r("div", { className: u(o.otp, d), children: n.map((a, e) => {
42
+ const S = e + 1, E = m && N.includes(S);
43
+ return /* @__PURE__ */ v(y, { children: [
37
44
  /* @__PURE__ */ r(
38
- A,
45
+ L,
39
46
  {
40
- ref: (t) => o.current[e] = t,
47
+ ref: (t) => s.current[e] = t,
41
48
  type: "text",
42
49
  inputMode: "numeric",
43
50
  autoComplete: "one-time-code",
44
51
  pattern: "\\d{1}",
45
52
  maxLength: 1,
46
53
  value: a,
47
- className: n.input,
48
- wrapperClassName: n["input-wrapper"],
49
- onChange: (t) => h(t, e),
50
- onKeyDown: (t) => w(t, e),
54
+ className: o.input,
55
+ wrapperClassName: o["input-wrapper"],
56
+ onChange: (t) => g(t, e),
57
+ onKeyDown: (t) => P(t, e),
51
58
  onFocus: (t) => I(t, e),
52
- onPaste: N,
53
- ...d
59
+ onPaste: w,
60
+ ...f
54
61
  }
55
62
  ),
56
63
  E && /* @__PURE__ */ r(
57
64
  "span",
58
65
  {
59
- className: u(n.separator),
66
+ className: u(o.separator),
60
67
  "data-testid": "separator"
61
68
  }
62
69
  )
@@ -64,7 +71,7 @@ import '../../assets/OtpInput.css';const C = "_otp_1ncuz_2", F = "_input_1ncuz_1
64
71
  }) });
65
72
  }
66
73
  );
67
- O.displayName = "OtpInput";
74
+ H.displayName = "OtpInput";
68
75
  export {
69
- O as OtpInput
76
+ H as OtpInput
70
77
  };
@@ -0,0 +1,2 @@
1
+ export declare const getValidSeparatorPositions: (positions: number[] | undefined, valueLength: number) => number[];
2
+ export declare const getDefaultSeparatorPositions: (valueLength: number, itemsPerSeparator: number) => number[];
@@ -0,0 +1,9 @@
1
+ const f = (e, t) => Array.isArray(e) ? e.filter(
2
+ (r) => typeof r == "number" && Number.isInteger(r) && r > 0 && r < t
3
+ ) : [], l = (e, t) => Array.from({ length: e }, (r, a) => a + 1).filter(
4
+ (r) => r % t === 0 && r !== e
5
+ );
6
+ export {
7
+ l as getDefaultSeparatorPositions,
8
+ f as getValidSeparatorPositions
9
+ };
@@ -27,6 +27,10 @@ type TProps = SwiperProps & {
27
27
  * Показывать стрелки навигации и количество слайдов.
28
28
  */
29
29
  needNavigation?: boolean;
30
+ /**
31
+ * Показывать количество слайдов.
32
+ */
33
+ needSlidesCount?: boolean;
30
34
  /**
31
35
  * Приостанавливать автопрокрутку при наведении на слайдер.
32
36
  */
@@ -92,5 +96,5 @@ type TProps = SwiperProps & {
92
96
  */
93
97
  images?: TSlideImage[];
94
98
  };
95
- export default function Slider({ images, children, gap, onSlideClick, swiperClassName, slideClassName, imageClassName, navigationClassName, navigationContent, sliderBottomPanelClassName, descriptionsClassName, navigationContentClassName, buttonsVariant, progressBarPosition, isFullPaginationWidth, needNavigation, leftDescription, rightDescription, delay, pauseOnMouseEnter, ...props }: TProps): import("react/jsx-runtime").JSX.Element;
99
+ export default function Slider({ images, children, gap, onSlideClick, swiperClassName, slideClassName, imageClassName, navigationClassName, navigationContent, sliderBottomPanelClassName, descriptionsClassName, navigationContentClassName, buttonsVariant, progressBarPosition, isFullPaginationWidth, needNavigation, needSlidesCount, leftDescription, rightDescription, delay, pauseOnMouseEnter, ...props }: TProps): import("react/jsx-runtime").JSX.Element;
96
100
  export {};
@@ -1,63 +1,63 @@
1
1
  import { jsx as s, jsxs as o, Fragment as N } from "react/jsx-runtime";
2
- import { c as a } from "../../index-DIxK0V-G.js";
3
- import { memo as F, useCallback as u, useMemo as Z, forwardRef as V, useRef as B, useState as W, Children as I } from "react";
4
- import { u as ee, S as se, A as re, a as T } from "../../swiper-react-BvAw14a4.js";
5
- import { EProgressBarPosition as S } from "./constants.js";
6
- import { formatSlideNumber as O } from "./utils.js";
7
- import { AppImage as P } from "../Image/Image.js";
8
- import { MergedButton as te } from "../MergedButton/MergedButton.js";
9
- import '../../assets/Slider.css';const ne = "_swiper_zqjj3_2", ae = "_slide_zqjj3_8", oe = "_link_zqjj3_15", ie = "_image_zqjj3_21", le = "_navigation_zqjj3_28", ce = "_pagination_zqjj3_46", de = "_slides_zqjj3_65", pe = "_separator_zqjj3_71", ue = "_progress_zqjj3_78", me = "_descriptions_zqjj3_95", e = {
2
+ import { c as n } from "../../index-DIxK0V-G.js";
3
+ import { memo as L, useCallback as u, useMemo as V, forwardRef as W, useRef as I, useState as ee, Children as T } from "react";
4
+ import { u as se, S as te, A as re, a as O } from "../../swiper-react-BvAw14a4.js";
5
+ import { EProgressBarPosition as b } from "./constants.js";
6
+ import { formatSlideNumber as P } from "./utils.js";
7
+ import { AppImage as E } from "../Image/Image.js";
8
+ import { MergedButton as ae } from "../MergedButton/MergedButton.js";
9
+ import '../../assets/Slider.css';const ne = "_swiper_zqjj3_2", oe = "_slide_zqjj3_8", ie = "_link_zqjj3_15", le = "_image_zqjj3_21", ce = "_navigation_zqjj3_28", de = "_pagination_zqjj3_46", pe = "_slides_zqjj3_65", ue = "_separator_zqjj3_71", me = "_progress_zqjj3_78", _e = "_descriptions_zqjj3_95", e = {
10
10
  swiper: ne,
11
- slide: ae,
12
- link: oe,
13
- image: ie,
14
- navigation: le,
11
+ slide: oe,
12
+ link: ie,
13
+ image: le,
14
+ navigation: ce,
15
15
  "navigation-content": "_navigation-content_zqjj3_37",
16
- pagination: ce,
16
+ pagination: de,
17
17
  "is-full": "_is-full_zqjj3_60",
18
- slides: de,
19
- separator: pe,
20
- progress: ue,
18
+ slides: pe,
19
+ separator: ue,
20
+ progress: me,
21
21
  "progress-bar-bottom": "_progress-bar-bottom_zqjj3_85",
22
22
  "progress-bar": "_progress-bar_zqjj3_85",
23
- descriptions: me
24
- }, _e = 15e3, E = F(
23
+ descriptions: _e
24
+ }, fe = 15e3, F = L(
25
25
  ({
26
- variant: t = "white"
26
+ variant: r = "white"
27
27
  }) => {
28
- const n = ee(), p = u(() => {
29
- n.slideNext();
30
- }, [n]), c = u(() => {
31
- n.slidePrev();
32
- }, [n]), m = Z(
28
+ const a = se(), p = u(() => {
29
+ a.slideNext();
30
+ }, [a]), c = u(() => {
31
+ a.slidePrev();
32
+ }, [a]), m = V(
33
33
  () => [
34
34
  {
35
35
  isIconButton: !0,
36
36
  iconName: "ArrowLeft16px",
37
- variant: t,
37
+ variant: r,
38
38
  onClick: c
39
39
  },
40
40
  {
41
41
  isIconButton: !0,
42
42
  iconName: "ArrowRight16px",
43
- variant: t,
43
+ variant: r,
44
44
  onClick: p
45
45
  }
46
46
  ],
47
- [c, t, p]
47
+ [c, r, p]
48
48
  );
49
- return /* @__PURE__ */ s(te, { buttons: m });
49
+ return /* @__PURE__ */ s(ae, { buttons: m });
50
50
  }
51
- ), b = F(
52
- V((t, n) => /* @__PURE__ */ s(
51
+ ), S = L(
52
+ W((r, a) => /* @__PURE__ */ s(
53
53
  "div",
54
54
  {
55
55
  "data-testid": "progress-bar-wrapper",
56
- className: a(e.progress, t == null ? void 0 : t.className),
56
+ className: n(e.progress, r == null ? void 0 : r.className),
57
57
  children: /* @__PURE__ */ s(
58
58
  "div",
59
59
  {
60
- ref: n,
60
+ ref: a,
61
61
  className: e["progress-bar"],
62
62
  "data-testid": "progress-bar"
63
63
  }
@@ -65,69 +65,70 @@ import '../../assets/Slider.css';const ne = "_swiper_zqjj3_2", ae = "_slide_zqjj
65
65
  }
66
66
  ))
67
67
  );
68
- function ze({
69
- images: t,
70
- children: n,
68
+ function ve({
69
+ images: r,
70
+ children: a,
71
71
  gap: p,
72
72
  onSlideClick: c,
73
73
  swiperClassName: m,
74
74
  slideClassName: q,
75
75
  imageClassName: z,
76
- navigationClassName: L,
76
+ navigationClassName: M,
77
77
  navigationContent: _,
78
- sliderBottomPanelClassName: M,
79
- descriptionsClassName: R,
80
- navigationContentClassName: $,
78
+ sliderBottomPanelClassName: R,
79
+ descriptionsClassName: $,
80
+ navigationContentClassName: D,
81
81
  buttonsVariant: v,
82
82
  progressBarPosition: f = "top",
83
83
  isFullPaginationWidth: k = !1,
84
84
  needNavigation: i = !0,
85
- leftDescription: C,
86
- rightDescription: y,
87
- delay: D = _e,
88
- pauseOnMouseEnter: U = !1,
89
- ...Y
85
+ needSlidesCount: C = !0,
86
+ leftDescription: y,
87
+ rightDescription: A,
88
+ delay: U = fe,
89
+ pauseOnMouseEnter: Y = !1,
90
+ ...G
90
91
  }) {
91
- const d = B(null), h = B(null), [G, H] = W(1), j = !(typeof n == "function") && !!n, J = j ? I.count(n) : 0, K = (t == null ? void 0 : t.length) ?? 0, A = O(G), x = O(
92
- j ? J : K
93
- ), Q = u(() => {
92
+ const d = I(null), h = I(null), [H, J] = ee(1), j = !(typeof a == "function") && !!a, K = j ? T.count(a) : 0, Q = (r == null ? void 0 : r.length) ?? 0, x = P(H), B = P(
93
+ j ? K : Q
94
+ ), X = u(() => {
94
95
  if (h.current && i) {
95
- const r = h.current.swiper;
96
- H(r.realIndex + 1);
96
+ const t = h.current.swiper;
97
+ J(t.realIndex + 1);
97
98
  }
98
- }, [i]), X = u(
99
- (r, l) => {
99
+ }, [i]), Z = u(
100
+ (t, l) => {
100
101
  if (d.current && i) {
101
- const g = r.params.autoplay.delay, w = l / g * 100;
102
+ const g = t.params.autoplay.delay, w = l / g * 100;
102
103
  d.current.style.width = `${100 - w}%`;
103
104
  }
104
105
  },
105
106
  [i]
106
107
  );
107
108
  return /* @__PURE__ */ o(
108
- se,
109
+ te,
109
110
  {
110
- ...Y,
111
+ ...G,
111
112
  ref: h,
112
- className: a(e.swiper, m),
113
+ className: n(e.swiper, m),
113
114
  loop: !0,
114
115
  spaceBetween: p,
115
116
  autoplay: {
116
- delay: D,
117
+ delay: U,
117
118
  disableOnInteraction: !1,
118
- pauseOnMouseEnter: U
119
+ pauseOnMouseEnter: Y
119
120
  },
120
121
  fadeEffect: {
121
122
  crossFade: !0
122
123
  },
123
124
  modules: [re],
124
- onAutoplayTimeLeft: X,
125
- onSlideChange: Q,
125
+ onAutoplayTimeLeft: Z,
126
+ onSlideChange: X,
126
127
  children: [
127
128
  /* @__PURE__ */ s(
128
129
  "div",
129
130
  {
130
- className: a(e.navigation, L, {
131
+ className: n(e.navigation, M, {
131
132
  [e["navigation-with-content"]]: !!_
132
133
  }),
133
134
  slot: "container-start",
@@ -135,9 +136,9 @@ function ze({
135
136
  /* @__PURE__ */ o(
136
137
  "div",
137
138
  {
138
- className: a(
139
+ className: n(
139
140
  e["navigation-content"],
140
- $
141
+ D
141
142
  ),
142
143
  children: [
143
144
  _,
@@ -145,102 +146,102 @@ function ze({
145
146
  "div",
146
147
  {
147
148
  "data-testid": "pagination",
148
- className: a(e.pagination, {
149
+ className: n(e.pagination, {
149
150
  [e["is-full"]]: k
150
151
  }),
151
152
  children: [
152
- /* @__PURE__ */ o("h2", { className: e.slides, children: [
153
- A,
153
+ C && /* @__PURE__ */ o("h2", { "data-testid": "slides-count", className: e.slides, children: [
154
+ x,
154
155
  /* @__PURE__ */ s("span", { className: e.separator }),
155
- x
156
+ B
156
157
  ] }),
157
- /* @__PURE__ */ s(E, { variant: v })
158
+ /* @__PURE__ */ s(F, { variant: v })
158
159
  ]
159
160
  }
160
161
  )
161
162
  ]
162
163
  }
163
164
  ),
164
- f === S.TOP && i && /* @__PURE__ */ s(b, { ref: d })
165
+ f === b.TOP && i && /* @__PURE__ */ s(S, { ref: d })
165
166
  ] }) : /* @__PURE__ */ s(N, { children: i && /* @__PURE__ */ o(N, { children: [
166
167
  /* @__PURE__ */ o(
167
168
  "div",
168
169
  {
169
170
  "data-testid": "pagination",
170
- className: a(e.pagination, {
171
+ className: n(e.pagination, {
171
172
  [e["is-full"]]: k
172
173
  }),
173
174
  children: [
174
- /* @__PURE__ */ o("h2", { className: e.slides, children: [
175
- A,
175
+ C && /* @__PURE__ */ o("h2", { "data-testid": "slides-count", className: e.slides, children: [
176
+ x,
176
177
  /* @__PURE__ */ s("span", { className: e.separator }),
177
- x
178
+ B
178
179
  ] }),
179
- /* @__PURE__ */ s(E, { variant: v })
180
+ /* @__PURE__ */ s(F, { variant: v })
180
181
  ]
181
182
  }
182
183
  ),
183
- f === S.TOP && /* @__PURE__ */ s(b, { ref: d })
184
+ f === b.TOP && /* @__PURE__ */ s(S, { ref: d })
184
185
  ] }) })
185
186
  }
186
187
  ),
187
- j ? I.map(n, (r, l) => /* @__PURE__ */ s(
188
- T,
188
+ j ? T.map(a, (t, l) => /* @__PURE__ */ s(
189
+ O,
189
190
  {
190
191
  onClick: c,
191
192
  "data-testid": `slide-${l}`,
192
- className: a(e.slide, q),
193
- children: r
193
+ className: n(e.slide, q),
194
+ children: t
194
195
  },
195
196
  l
196
- )) : t == null ? void 0 : t.map((r, l) => {
197
- if (!r) return null;
197
+ )) : r == null ? void 0 : r.map((t, l) => {
198
+ if (!t) return null;
198
199
  const g = /* @__PURE__ */ s(
199
200
  "a",
200
201
  {
201
202
  className: e.link,
202
- href: r.url,
203
+ href: t.url,
203
204
  rel: "noopener noreferrer",
204
205
  target: "_blank",
205
206
  children: /* @__PURE__ */ s(
206
- P,
207
+ E,
207
208
  {
208
- className: a(e.image, z),
209
- src: r.image
209
+ className: n(e.image, z),
210
+ src: t.image
210
211
  }
211
212
  )
212
213
  }
213
- ), w = () => typeof n == "function" ? n(r) : r.url ? g : /* @__PURE__ */ s(
214
- P,
214
+ ), w = () => typeof a == "function" ? a(t) : t.url ? g : /* @__PURE__ */ s(
215
+ E,
215
216
  {
216
- className: a(e.image, z),
217
- src: r.image,
218
- desktopImage: r.imageDesktop,
219
- mobileImage: r.imageMobile
217
+ className: n(e.image, z),
218
+ src: t.image,
219
+ desktopImage: t.imageDesktop,
220
+ mobileImage: t.imageMobile
220
221
  }
221
222
  );
222
223
  return /* @__PURE__ */ s(
223
- T,
224
+ O,
224
225
  {
225
226
  "data-testid": `slide-${l}`,
226
227
  onClick: c,
227
- className: a(e.slide, q),
228
+ className: n(e.slide, q),
228
229
  children: w()
229
230
  },
230
- r.id
231
+ t.id
231
232
  );
232
233
  }),
233
- f === S.BOTTOM && /* @__PURE__ */ o("div", { className: M, children: [
234
+ f === b.BOTTOM && /* @__PURE__ */ o("div", { className: R, children: [
234
235
  /* @__PURE__ */ s(
235
- b,
236
+ S,
236
237
  {
237
238
  ref: d,
238
239
  className: e["progress-bar-bottom"]
239
240
  }
240
241
  ),
241
- /* @__PURE__ */ o("div", { className: a(e.descriptions, R), children: [
242
- C && /* @__PURE__ */ s("div", { "data-testid": "slider-left-description", children: C }),
243
- y && /* @__PURE__ */ s("div", { "data-testid": "slider-right-description", children: y })
242
+ /* @__PURE__ */ o("div", { className: n(e.descriptions, $), children: [
243
+ y && /* @__PURE__ */ s("div", { "data-testid": "slider-left-description", children: y }),
244
+ A && /* @__PURE__ */ s("div", { "data-testid": "slider-right-description", children: A })
244
245
  ] })
245
246
  ] })
246
247
  ]
@@ -248,5 +249,5 @@ function ze({
248
249
  );
249
250
  }
250
251
  export {
251
- ze as default
252
+ ve as default
252
253
  };
@@ -1,18 +1,18 @@
1
- import { jsxs as X, jsx as l } from "react/jsx-runtime";
2
- import { c as k } from "../../index-DIxK0V-G.js";
3
- import { forwardRef as q, useState as A, useEffect as B } from "react";
1
+ import { jsxs as k, jsx as l } from "react/jsx-runtime";
2
+ import { c as q } from "../../index-DIxK0V-G.js";
3
+ import { forwardRef as A, useState as B, useEffect as C } from "react";
4
4
  import { EUploaderFilesVariant as F } from "./constants.js";
5
- import { useMediaQuery as C } from "../../hooks/useMediaQuery/useMediaQuery.js";
6
- import { EMediaQuery as G } from "../../hooks/useMediaQuery/constants.js";
7
- import { ListFiles as H } from "../ListFiles/ListFiles.js";
5
+ import { useMediaQuery as G } from "../../hooks/useMediaQuery/useMediaQuery.js";
6
+ import { EMediaQuery as H } from "../../hooks/useMediaQuery/constants.js";
7
+ import { ListFiles as I } from "../ListFiles/ListFiles.js";
8
8
  import { EFileItemVariant as w } from "../ListFiles/constants.js";
9
- import { Uploader as I } from "../Uploader/Uploader.js";
10
- import '../../assets/UploaderFiles.css';const J = "_container_aj93w_2", K = "_white_aj93w_11", O = "_gray_aj93w_14", P = "_compact_aj93w_17", n = {
11
- container: J,
12
- white: K,
13
- gray: O,
14
- compact: P
15
- }, ri = q(
9
+ import { Uploader as J } from "../Uploader/Uploader.js";
10
+ import '../../assets/UploaderFiles.css';const K = "_container_aj93w_2", O = "_white_aj93w_11", P = "_gray_aj93w_14", Y = "_compact_aj93w_17", n = {
11
+ container: K,
12
+ white: O,
13
+ gray: P,
14
+ compact: Y
15
+ }, ti = A(
16
16
  (x, _) => {
17
17
  const {
18
18
  compact: h,
@@ -30,13 +30,14 @@ import '../../assets/UploaderFiles.css';const J = "_container_aj93w_2", K = "_wh
30
30
  onMaxFilesExceeded: g,
31
31
  onMaxSizeExceeded: z,
32
32
  onInvalidFileType: N,
33
- dataTestIdReactMap: a
34
- } = x, V = C(G.XSS), [e, c] = A(r || []), U = t && e.length >= t, D = m === F.White ? w.gray : w.white;
35
- B(() => {
33
+ dataTestIdReactMap: a,
34
+ accept: V
35
+ } = x, U = G(H.XSS), [e, c] = B(r || []), D = t && e.length >= t, M = m === F.White ? w.gray : w.white;
36
+ C(() => {
36
37
  r && c(r);
37
38
  }, [r]);
38
- const M = (o) => {
39
- const L = [
39
+ const Q = (o) => {
40
+ const X = [
40
41
  ...e,
41
42
  ...o.value.map((i) => {
42
43
  var f, y, u;
@@ -49,33 +50,34 @@ import '../../assets/UploaderFiles.css';const J = "_container_aj93w_2", K = "_wh
49
50
  };
50
51
  })
51
52
  ];
52
- c(L), s == null || s({ type: "add", data: o.value, name: p });
53
- }, Q = (o) => {
53
+ c(X), s == null || s({ type: "add", data: o.value, name: p });
54
+ }, W = (o) => {
54
55
  c(o.list), o.deleteId && (s == null || s({ type: "delete", data: o.deleteId, name: p }));
55
- }, W = k([
56
+ }, L = q([
56
57
  n.container,
57
58
  n[m],
58
59
  h && n.compact,
59
60
  b
60
61
  ]);
61
- return /* @__PURE__ */ X(
62
+ return /* @__PURE__ */ k(
62
63
  "div",
63
64
  {
64
65
  "data-testid-react": a == null ? void 0 : a.wrapper,
65
- className: W,
66
+ className: L,
66
67
  children: [
67
68
  /* @__PURE__ */ l(
68
- I,
69
+ J,
69
70
  {
70
71
  dataTestIdReactMap: { wrapper: a == null ? void 0 : a.uploader },
71
72
  filesType: S,
72
73
  arrayName: j,
74
+ accept: V,
73
75
  maxSize: v,
74
- onChangeValue: M,
76
+ onChangeValue: Q,
75
77
  ref: _,
76
- buttonSize: V ? "s" : "m",
78
+ buttonSize: U ? "s" : "m",
77
79
  maxFiles: t && t - e.length,
78
- isDisabled: U || d,
80
+ isDisabled: D || d,
79
81
  buttonText: E,
80
82
  onMaxFilesExceeded: g,
81
83
  onMaxSizeExceeded: z,
@@ -83,11 +85,11 @@ import '../../assets/UploaderFiles.css';const J = "_container_aj93w_2", K = "_wh
83
85
  }
84
86
  ),
85
87
  /* @__PURE__ */ l("div", { "data-testid-react": a == null ? void 0 : a.listFiles, children: /* @__PURE__ */ l(
86
- H,
88
+ I,
87
89
  {
88
90
  value: e,
89
- variant: D,
90
- onChange: Q,
91
+ variant: M,
92
+ onChange: W,
91
93
  disabled: d
92
94
  }
93
95
  ) })
@@ -97,5 +99,5 @@ import '../../assets/UploaderFiles.css';const J = "_container_aj93w_2", K = "_wh
97
99
  }
98
100
  );
99
101
  export {
100
- ri as UploaderFiles
102
+ ti as UploaderFiles
101
103
  };
@@ -72,6 +72,7 @@ export type TUploaderFiles = {
72
72
  * Объект, для передачи в компонент и его элементы data-testid-react, для автоматизированного тестирования
73
73
  */
74
74
  dataTestIdReactMap?: TDataTestIdReactMap<'wrapper' | 'uploader' | 'listFiles'>;
75
+ accept?: Record<string, string>;
75
76
  };
76
77
  export type TOnChangeFilesUpdate = {
77
78
  type: string;
@@ -65,6 +65,7 @@ export type TUploaderPhotos = {
65
65
  * Объект, для передачи в компонент и его элементы data-testid-react, для автоматизированного тестирования
66
66
  */
67
67
  dataTestIdReactMap?: TDataTestIdReactMap<'wrapper' | 'uploader' | 'listPhotos'>;
68
+ accept?: Record<string, string>;
68
69
  };
69
70
  export type TOnChangePhotosUpdate = {
70
71
  type: string;