stone-kit 0.0.570 → 0.0.571

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.
@@ -17,20 +17,20 @@ import "./components/MetroTag/ui/MetroTag.js";
17
17
  import "./components/LotCard/ui/LotCard.js";
18
18
  import "./components/Select/ui/Select.js";
19
19
  import { useClientWidth as E } from "./shared/useClientWidth.js";
20
- import { s as l, u as et } from "./useSortSelect-CjZXLFOG.js";
20
+ import { s as c, u as et } from "./useSortSelect-CjZXLFOG.js";
21
21
  import "./components/SliderNavigation/ui/SliderNavigation.js";
22
22
  import "./components/LotCardSkeleton/ui/LotCardSkeleton.js";
23
23
  import "./components/TabSelect/ui/TabSelect.js";
24
24
  import "./components/FormModal/ui/ModalForm.js";
25
25
  import { O as it } from "./Option-CyYM1iBJ.js";
26
- const ot = "_root_2bilg_1", rt = "_text_2bilg_18", st = "_textMini_2bilg_26", nt = "_rootCol_2bilg_32", at = "_item_2bilg_38", ct = "_whiteRow_2bilg_57", lt = "_firstItem_2bilg_68", dt = "_lastItem_2bilg_72", pt = "_apart_2bilg_103", mt = "_isLong_2bilg_103", _t = "_autoWidth_2bilg_128", ht = "_mini_2bilg_132", ut = "_isDisabled_2bilg_140", ft = "_grayRow_2bilg_164", p = {
26
+ const ot = "_root_2bilg_1", rt = "_text_2bilg_18", st = "_textMini_2bilg_26", nt = "_rootCol_2bilg_32", at = "_item_2bilg_38", lt = "_whiteRow_2bilg_57", ct = "_firstItem_2bilg_68", dt = "_lastItem_2bilg_72", pt = "_apart_2bilg_103", mt = "_isLong_2bilg_103", _t = "_autoWidth_2bilg_128", ht = "_mini_2bilg_132", ut = "_isDisabled_2bilg_140", ft = "_grayRow_2bilg_164", p = {
27
27
  root: ot,
28
28
  text: rt,
29
29
  textMini: st,
30
30
  rootCol: nt,
31
31
  item: at,
32
- whiteRow: ct,
33
- firstItem: lt,
32
+ whiteRow: lt,
33
+ firstItem: ct,
34
34
  lastItem: dt,
35
35
  apart: pt,
36
36
  isLong: mt,
@@ -38,27 +38,27 @@ const ot = "_root_2bilg_1", rt = "_text_2bilg_18", st = "_textMini_2bilg_26", nt
38
38
  mini: ht,
39
39
  isDisabled: ut,
40
40
  grayRow: ft
41
- }, I = G.bind(p), vt = ({
41
+ }, I = G.bind(p), gt = ({
42
42
  children: n,
43
43
  variant: r = "whiteRow",
44
44
  isApart: a = !1,
45
- addClassName: m = "",
46
- col: _ = !1
47
- }) => /* @__PURE__ */ e("div", { className: I(p.root, p[r], m, { [p.rootCol]: _, [p.apart]: a }), children: n }), J = Z((n, r) => {
48
- const { isTablet: a, isDesktop: m } = E(), {
49
- index: _,
45
+ addClassName: h = "",
46
+ col: u = !1
47
+ }) => /* @__PURE__ */ e("div", { className: I(p.root, p[r], h, { [p.rootCol]: u, [p.apart]: a }), children: n }), J = Z((n, r) => {
48
+ const { isTablet: a, isDesktop: h } = E(), {
49
+ index: u,
50
50
  children: t,
51
51
  addItemClassName: i,
52
52
  addTextClass: d,
53
53
  disabled: O = !1,
54
54
  itemsLength: x = 0,
55
55
  isLongOn: S = !0,
56
- width: f,
57
- width_m: c,
58
- width_l: h,
56
+ width: v,
57
+ width_m: l,
58
+ width_l: f,
59
59
  mini: C = !1,
60
60
  ...k
61
- } = n, y = (t != null && t.toString().length ? (t == null ? void 0 : t.toString().length) > 2 : !1) && S, w = (v, N) => v && c ? c : N && h ? h : f, u = !f && !c && !h && y;
61
+ } = n, y = (t != null && t.toString().length ? (t == null ? void 0 : t.toString().length) > 2 : !1) && S, w = (W, N) => W && l ? l : N && f ? f : v, g = !v && !l && !f && y;
62
62
  return /* @__PURE__ */ b("label", { className: I({ [p.isLong]: y }), children: [
63
63
  /* @__PURE__ */ e(
64
64
  "input",
@@ -72,14 +72,14 @@ const ot = "_root_2bilg_1", rt = "_text_2bilg_18", st = "_textMini_2bilg_26", nt
72
72
  /* @__PURE__ */ e(
73
73
  "div",
74
74
  {
75
- style: { width: w(a, m) },
75
+ style: { width: w(a, h) },
76
76
  className: I(
77
77
  I(
78
78
  p.item,
79
- { [p.firstItem]: _ === 0 },
80
- { [p.lastItem]: _ === x - 1 },
79
+ { [p.firstItem]: u === 0 },
80
+ { [p.lastItem]: u === x - 1 },
81
81
  { [p.isDisabled]: O },
82
- { [p.autoWidth]: u },
82
+ { [p.autoWidth]: g },
83
83
  { [p.mini]: C }
84
84
  ),
85
85
  i
@@ -90,53 +90,53 @@ const ot = "_root_2bilg_1", rt = "_text_2bilg_18", st = "_textMini_2bilg_26", nt
90
90
  ] });
91
91
  });
92
92
  J.displayName = "TabSwitcherItem";
93
- const T = Object.assign(vt, { Item: J }), R = G.bind(l), gt = ({
93
+ const T = Object.assign(gt, { Item: J }), R = G.bind(c), vt = ({
94
94
  options: n,
95
95
  selectedOption: r,
96
96
  placeholder: a = "",
97
- error: m,
98
- disabled: _,
97
+ error: h,
98
+ disabled: u,
99
99
  additionalClass: t = "",
100
100
  onChange: i,
101
101
  onBlur: d,
102
102
  mini: O,
103
103
  openOnTop: x = !1,
104
104
  onClickItem: S,
105
- onCLickSelect: f
105
+ onCLickSelect: v
106
106
  }) => {
107
- const [c, h] = B(!1), C = q(null), { isMobile: k } = E(), { handleBlur: y, getInputValue: w, getOption: u, handleDocumentClick: v } = et(
107
+ const [l, f] = B(!1), C = q(null), { isMobile: k } = E(), { handleBlur: y, getInputValue: w, getOption: g, handleDocumentClick: W } = et(
108
108
  {
109
109
  selectedOption: r,
110
110
  onClickOption: S,
111
111
  setSelectedOption: i,
112
- setIsOpen: h,
112
+ setIsOpen: f,
113
113
  containerRef: C,
114
- isOpen: c,
114
+ isOpen: l,
115
115
  isMobile: k,
116
116
  placeholder: a,
117
117
  onChange: i,
118
118
  onBlur: d
119
119
  }
120
120
  );
121
- return L(() => (document.addEventListener("click", v), () => {
122
- document.removeEventListener("click", v);
121
+ return L(() => (document.addEventListener("click", W), () => {
122
+ document.removeEventListener("click", W);
123
123
  }), []), /* @__PURE__ */ b(
124
124
  "div",
125
125
  {
126
126
  ref: C,
127
127
  className: R(
128
- l.sortSelectWrapper,
129
- { [l.sortSelectWrapperError]: m },
130
- { [l.sortSelectWrapperTop]: x },
128
+ c.sortSelectWrapper,
129
+ { [c.sortSelectWrapperError]: h },
130
+ { [c.sortSelectWrapperTop]: x },
131
131
  t
132
132
  ),
133
133
  tabIndex: 0,
134
134
  onBlur: y,
135
135
  onClick: () => {
136
- f && f();
136
+ v && v();
137
137
  },
138
138
  children: [
139
- /* @__PURE__ */ b("div", { className: R(l.inputWrapper), children: [
139
+ /* @__PURE__ */ b("div", { className: R(c.inputWrapper), children: [
140
140
  /* @__PURE__ */ e(
141
141
  "input",
142
142
  {
@@ -144,11 +144,11 @@ const T = Object.assign(vt, { Item: J }), R = G.bind(l), gt = ({
144
144
  readOnly: !0,
145
145
  value: w(),
146
146
  className: R(
147
- l.selectedOptions,
148
- { [l.selectOptionsDisabled]: _ },
149
- { [l.selectionOptionMini]: O }
147
+ c.selectedOptions,
148
+ { [c.selectOptionsDisabled]: u },
149
+ { [c.selectionOptionMini]: O }
150
150
  ),
151
- onClick: () => h(!c)
151
+ onClick: () => f(!l)
152
152
  }
153
153
  ),
154
154
  /* @__PURE__ */ e(
@@ -156,23 +156,23 @@ const T = Object.assign(vt, { Item: J }), R = G.bind(l), gt = ({
156
156
  {
157
157
  name: "twoArrows",
158
158
  size: "24",
159
- additionalClass: l.icon
159
+ additionalClass: c.icon
160
160
  }
161
161
  )
162
162
  ] }),
163
- c && k && /* @__PURE__ */ b(
163
+ l && k && /* @__PURE__ */ b(
164
164
  H,
165
165
  {
166
- isOpen: c,
167
- emitIsOpen: h,
168
- additionalClassModalBody: l.modalAddBody,
169
- additionalClass: l.selectModal,
166
+ isOpen: l,
167
+ emitIsOpen: f,
168
+ additionalClassModalBody: c.modalAddBody,
169
+ additionalClass: c.selectModal,
170
170
  createPortalObj: { domNode: document.querySelector("body") },
171
171
  isTransparentBack: !0,
172
172
  children: [
173
- /* @__PURE__ */ b("div", { className: l.mobileSortHeader, children: [
173
+ /* @__PURE__ */ b("div", { className: c.mobileSortHeader, children: [
174
174
  /* @__PURE__ */ e(V, { children: "Сортировка" }),
175
- /* @__PURE__ */ e("div", { onClick: () => h(!1), children: /* @__PURE__ */ e(
175
+ /* @__PURE__ */ e("div", { onClick: () => f(!1), children: /* @__PURE__ */ e(
176
176
  A,
177
177
  {
178
178
  name: "close",
@@ -180,16 +180,16 @@ const T = Object.assign(vt, { Item: J }), R = G.bind(l), gt = ({
180
180
  }
181
181
  ) })
182
182
  ] }),
183
- /* @__PURE__ */ e("div", { className: l.mobileOptionList, children: n == null ? void 0 : n.map((N) => u(N)) })
183
+ /* @__PURE__ */ e("div", { className: c.mobileOptionList, children: n == null ? void 0 : n.map((N) => g(N)) })
184
184
  ]
185
185
  }
186
186
  ),
187
- c && !k && /* @__PURE__ */ e("div", { className: R(l.optionsList, { [l.optionListOnTop]: x }), children: n == null ? void 0 : n.map((N) => u(N)) })
187
+ l && !k && /* @__PURE__ */ e("div", { className: R(c.optionsList, { [c.optionListOnTop]: x }), children: n == null ? void 0 : n.map((N) => g(N)) })
188
188
  ]
189
189
  }
190
190
  );
191
191
  };
192
- gt.displayName = "SortSelect";
192
+ vt.displayName = "SortSelect";
193
193
  const Wt = "_root_1occg_1", bt = "_filterWithSaveModal_1occg_15", Nt = "_modalAddBody_1occg_20", wt = "_closeBtn_1occg_29", Ot = "_btnName_1occg_35", St = "_modalTitle_1occg_39", Ct = "_tabSWitcherWrapper_1occg_48", kt = "_switcherTitle_1occg_56", xt = "_switcherScroll_1occg_63", yt = "_tabs_1occg_67", Bt = "_selectWrapper_1occg_72", It = "_filterOption_1occg_76", Mt = "_btnWrapper_1occg_83", Rt = "_resetBtn_1occg_89", Lt = "_saveBtn_1occg_90", At = "_desktopWrapper_1occg_94", Dt = "_desktopWrapperOpen_1occg_116", o = {
194
194
  root: Wt,
195
195
  filterWithSaveModal: bt,
@@ -221,11 +221,11 @@ var K = { exports: {} };
221
221
  function a() {
222
222
  for (var t = "", i = 0; i < arguments.length; i++) {
223
223
  var d = arguments[i];
224
- d && (t = _(t, m.call(this, d)));
224
+ d && (t = u(t, h.call(this, d)));
225
225
  }
226
226
  return t;
227
227
  }
228
- function m(t) {
228
+ function h(t) {
229
229
  if (typeof t == "string" || typeof t == "number")
230
230
  return this && this[t] || t;
231
231
  if (typeof t != "object")
@@ -236,10 +236,10 @@ var K = { exports: {} };
236
236
  return t.toString();
237
237
  var i = "";
238
238
  for (var d in t)
239
- r.call(t, d) && t[d] && (i = _(i, this && this[d] || d));
239
+ r.call(t, d) && t[d] && (i = u(i, this && this[d] || d));
240
240
  return i;
241
241
  }
242
- function _(t, i) {
242
+ function u(t, i) {
243
243
  return i ? t ? t + " " + i : t + i : t;
244
244
  }
245
245
  n.exports ? (a.default = a, n.exports = a) : window.classNames = a;
@@ -250,35 +250,36 @@ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(o), de = ({
250
250
  disabledOptions: n = [],
251
251
  tabs: r = [],
252
252
  selectOptions: a = [],
253
- onChange: m,
254
- selectedValues: _ = [],
253
+ onChange: h,
254
+ selectedValues: u = [],
255
255
  setSelectedTabs: t,
256
256
  selectedTabs: i = [],
257
257
  onClickItem: d,
258
258
  onCLickSelect: O,
259
259
  btnName: x = "Фильтр"
260
260
  }) => {
261
- const { isMobile: S } = E(), [f, c] = B(!1), h = q(null), [C, k] = B(i), [y] = B(_), [w, u] = B(C), [v, N] = B(y), Q = (s) => {
262
- if (d && d(s), n.some((W) => W.value === s.value))
261
+ const { isMobile: S } = E(), [v, l] = B(!1), f = q(null), [C, k] = B(i), [y] = B(u), [w, g] = B(C), [W, N] = B(y), Q = (s) => {
262
+ if (d && d(s), n.some((_) => _.value === s.value))
263
263
  return;
264
- const g = v.some((W) => W.value === s.value) ? v.filter((W) => W.value !== s.value) : [...v, s];
265
- N(g);
264
+ const m = W.some((_) => _.value === s.value) ? W.filter((_) => _.value !== s.value) : [...W, s];
265
+ N(m);
266
266
  }, U = () => {
267
- k(r), u(r), N([]), m && (m([]), t == null || t(r));
267
+ k(r), g(r), N([]), h && (h([]), t == null || t(r));
268
268
  }, X = () => {
269
- N(_), u(i);
269
+ N(u), g(i);
270
270
  }, j = () => {
271
- X(), c(!1);
271
+ X(), l(!1);
272
272
  }, Y = () => {
273
- m && (t == null || t(w), m(v)), c(!1);
273
+ h && (t == null || t(w), h(W)), l(!1);
274
274
  };
275
275
  L(() => {
276
- f || u(i);
277
- }, [f]), L(() => {
278
- u(i);
276
+ v || g(i);
277
+ }, [v]), L(() => {
278
+ g(i);
279
279
  }, [i]), L(() => {
280
- const s = (g) => {
281
- h.current && !h.current.contains(g.target) && j();
280
+ const s = (m) => {
281
+ var _;
282
+ console.log((_ = m == null ? void 0 : m.target) == null ? void 0 : _.closest("#id")), f.current && !f.current.contains(m.target) && j();
282
283
  };
283
284
  return document.addEventListener("click", s), () => {
284
285
  document.removeEventListener("click", s);
@@ -308,44 +309,44 @@ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(o), de = ({
308
309
  variant: "grayRow",
309
310
  addClassName: o.tabs,
310
311
  isApart: !0,
311
- children: r == null ? void 0 : r.map((s, g) => {
312
+ children: r == null ? void 0 : r.map((s, m) => {
312
313
  var z;
313
- const W = s.value;
314
+ const _ = s.value;
314
315
  return /* @__PURE__ */ e(
315
316
  T.Item,
316
317
  {
317
318
  itemsLength: r == null ? void 0 : r.length,
318
319
  mini: !0,
319
- value: W,
320
+ value: _,
320
321
  onClick: () => {
321
322
  },
322
- checked: ((z = w == null ? void 0 : w.find((D) => D.value === W)) == null ? void 0 : z.state) ?? !1,
323
+ checked: ((z = w == null ? void 0 : w.find((D) => D.value === _)) == null ? void 0 : z.state) ?? !1,
323
324
  onChange: () => {
324
- u == null || u(
325
- (D) => D.map((M) => M.value === W ? { ...M, state: !M.state } : M)
325
+ g == null || g(
326
+ (D) => D.map((M) => M.value === _ ? { ...M, state: !M.state } : M)
326
327
  );
327
328
  },
328
- index: g,
329
+ index: m,
329
330
  addItemClassName: o.tabSwitcher,
330
- children: W
331
+ children: _
331
332
  },
332
- g
333
+ m
333
334
  );
334
335
  })
335
336
  }
336
337
  ) })
337
338
  ] }),
338
- /* @__PURE__ */ e("div", { className: o.selectWrapper, children: a == null ? void 0 : a.map((s, g) => /* @__PURE__ */ e(
339
+ /* @__PURE__ */ e("div", { className: o.selectWrapper, children: a == null ? void 0 : a.map((s, m) => /* @__PURE__ */ e(
339
340
  it,
340
341
  {
341
342
  addClassName: o.filterOption,
342
343
  disabledOptions: [],
343
344
  clickableOptions: [],
344
- selectedOptions: v,
345
+ selectedOptions: W,
345
346
  option: s,
346
347
  handleOptionClick: Q
347
348
  },
348
- g
349
+ m
349
350
  )) }),
350
351
  /* @__PURE__ */ b("div", { className: o.btnWrapper, children: [
351
352
  /* @__PURE__ */ e(
@@ -376,7 +377,7 @@ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(o), de = ({
376
377
  className: o.root,
377
378
  id: "modal-container",
378
379
  onClick: (s) => {
379
- s.stopPropagation(), O && O(), c(S ? (g) => !g : !0);
380
+ s.stopPropagation(), O && O(), l(S ? (m) => !m : !0);
380
381
  },
381
382
  children: [
382
383
  /* @__PURE__ */ e("div", { className: o.btnName, children: x }),
@@ -390,8 +391,8 @@ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(o), de = ({
390
391
  !S && /* @__PURE__ */ e(
391
392
  "div",
392
393
  {
393
- ref: h,
394
- className: $t(o.desktopWrapper, { [o.desktopWrapperOpen]: f }),
394
+ ref: f,
395
+ className: $t(o.desktopWrapper, { [o.desktopWrapperOpen]: v }),
395
396
  onClick: (s) => s.stopPropagation(),
396
397
  children: /* @__PURE__ */ e($, {})
397
398
  }
@@ -402,8 +403,8 @@ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(o), de = ({
402
403
  S && /* @__PURE__ */ e(
403
404
  H,
404
405
  {
405
- isOpen: f,
406
- emitIsOpen: c,
406
+ isOpen: v,
407
+ emitIsOpen: l,
407
408
  isTransparentBack: !0,
408
409
  additionalClassModalBody: o.modalAddBody,
409
410
  additionalClass: o.filterWithSaveModal,
@@ -415,5 +416,5 @@ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(o), de = ({
415
416
  export {
416
417
  de as F,
417
418
  T as S,
418
- gt as a
419
+ vt as a
419
420
  };
@@ -1,7 +1,7 @@
1
1
  import "react/jsx-runtime";
2
2
  import "react";
3
3
  import "../../NewIcon/ui/NewIcon.js";
4
- import { F as w } from "../../../FilterWithSave-BNlzox9b.js";
4
+ import { F as w } from "../../../FilterWithSave-B1v4cN1L.js";
5
5
  import "../../../Modal-BZv6nlLe.js";
6
6
  import "../../../Option-CyYM1iBJ.js";
7
7
  import "../../Button/ui/Button.js";
@@ -1,4 +1,4 @@
1
- import { a as r } from "../../FilterWithSave-BNlzox9b.js";
1
+ import { a as r } from "../../FilterWithSave-B1v4cN1L.js";
2
2
  export {
3
3
  r as SortSelect
4
4
  };
@@ -13,7 +13,7 @@ import "../../Text/ui/Text.js";
13
13
  import "../../Flex/ui/Flex.js";
14
14
  import "../../Input/ui/Input.js";
15
15
  import "../../../Modal-BZv6nlLe.js";
16
- import { a as z } from "../../../FilterWithSave-BNlzox9b.js";
16
+ import { a as z } from "../../../FilterWithSave-B1v4cN1L.js";
17
17
  import "../../GroupedInput/ui/GroupedInputs.js";
18
18
  import "../../MetroTag/ui/MetroTag.js";
19
19
  import "../../LotCard/ui/LotCard.js";
@@ -1,4 +1,4 @@
1
- import { S as e } from "../../FilterWithSave-BNlzox9b.js";
1
+ import { S as e } from "../../FilterWithSave-B1v4cN1L.js";
2
2
  export {
3
3
  e as TabSwitcher
4
4
  };
@@ -1,6 +1,6 @@
1
1
  import "react/jsx-runtime";
2
2
  import "react";
3
- import { S as v } from "../../../FilterWithSave-BNlzox9b.js";
3
+ import { S as v } from "../../../FilterWithSave-B1v4cN1L.js";
4
4
  import "../../Text/ui/Text.js";
5
5
  import "../../../index-rKuIKazb.js";
6
6
  import "../../Button/ui/Button.js";
@@ -11,7 +11,7 @@ import "../../Flex/ui/Flex.js";
11
11
  import "../../Input/ui/Input.js";
12
12
  import "react";
13
13
  import "../../../Modal-BZv6nlLe.js";
14
- import "../../../FilterWithSave-BNlzox9b.js";
14
+ import "../../../FilterWithSave-B1v4cN1L.js";
15
15
  import "../../GroupedInput/ui/GroupedInputs.js";
16
16
  import "../../../index-rKuIKazb.js";
17
17
  import "../../MetroTag/ui/MetroTag.js";
package/dist/main.js CHANGED
@@ -10,7 +10,7 @@ import { Flex as T } from "./components/Flex/ui/Flex.js";
10
10
  import { Input as F } from "./components/Input/ui/Input.js";
11
11
  import { M as g } from "./Modal-BZv6nlLe.js";
12
12
  import { FieldInput as I } from "./components/FieldInput/ui/FieldInput.js";
13
- import { F as B, a as L, S as k } from "./FilterWithSave-BNlzox9b.js";
13
+ import { F as B, a as L, S as k } from "./FilterWithSave-B1v4cN1L.js";
14
14
  import { GroupedInputs as N } from "./components/GroupedInput/ui/GroupedInputs.js";
15
15
  import { Logo as j } from "./components/Logo/ui/Logo.js";
16
16
  import { MetroTag as D } from "./components/MetroTag/ui/MetroTag.js";
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "stone-kit",
3
3
  "description": "uikit for redesign",
4
4
  "private": false,
5
- "version": "0.0.570",
5
+ "version": "0.0.571",
6
6
  "author": "Mollycodd1e",
7
7
  "license": "ISC",
8
8
  "type": "module",