stone-kit 0.0.579 → 0.0.580

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.
@@ -1,10 +1,10 @@
1
- import { jsxs as W, jsx as e, Fragment as F } from "react/jsx-runtime";
2
- import { forwardRef as Z, useState as B, useRef as P, useEffect as D } from "react";
1
+ import { jsxs as N, jsx as e, Fragment as F } from "react/jsx-runtime";
2
+ import { forwardRef as Z, useState as B, useRef as J, useEffect as D } from "react";
3
3
  import { NewIcon as R } from "./components/NewIcon/ui/NewIcon.js";
4
4
  import { M as q } from "./Modal-BZv6nlLe.js";
5
5
  import { Text as H } from "./components/Text/ui/Text.js";
6
6
  import { c as V, g as tt } from "./index-rKuIKazb.js";
7
- import { Button as T } from "./components/Button/ui/Button.js";
7
+ import { Button as P } from "./components/Button/ui/Button.js";
8
8
  import "./components/mobileButton/ui/MobileButton.js";
9
9
  import "./components/DestinationTab/ui/DestinationTab.js";
10
10
  import "./components/RoundButton/ui/RoundButton.js";
@@ -23,9 +23,9 @@ 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 rt = "_root_2bilg_1", ot = "_text_2bilg_18", nt = "_textMini_2bilg_26", st = "_rootCol_2bilg_32", at = "_item_2bilg_38", ct = "_whiteRow_2bilg_57", lt = "_firstItem_2bilg_68", dt = "_lastItem_2bilg_72", mt = "_apart_2bilg_103", pt = "_isLong_2bilg_103", _t = "_autoWidth_2bilg_128", ut = "_mini_2bilg_132", ft = "_isDisabled_2bilg_140", ht = "_grayRow_2bilg_164", p = {
27
- root: rt,
28
- text: ot,
26
+ const ot = "_root_2bilg_1", rt = "_text_2bilg_18", nt = "_textMini_2bilg_26", st = "_rootCol_2bilg_32", at = "_item_2bilg_38", ct = "_whiteRow_2bilg_57", lt = "_firstItem_2bilg_68", dt = "_lastItem_2bilg_72", mt = "_apart_2bilg_103", pt = "_isLong_2bilg_103", _t = "_autoWidth_2bilg_128", ut = "_mini_2bilg_132", ft = "_isDisabled_2bilg_140", ht = "_grayRow_2bilg_164", p = {
27
+ root: ot,
28
+ text: rt,
29
29
  textMini: nt,
30
30
  rootCol: st,
31
31
  item: at,
@@ -58,8 +58,8 @@ const rt = "_root_2bilg_1", ot = "_text_2bilg_18", nt = "_textMini_2bilg_26", st
58
58
  width_l: m,
59
59
  mini: k = !1,
60
60
  ...y
61
- } = s, x = (t != null && t.toString().length ? (t == null ? void 0 : t.toString().length) > 2 : !1) && S, w = (g, N) => g && c ? c : N && m ? m : f, h = !f && !c && !m && x;
62
- return /* @__PURE__ */ W("label", { className: I({ [p.isLong]: x }), children: [
61
+ } = s, x = (t != null && t.toString().length ? (t == null ? void 0 : t.toString().length) > 2 : !1) && S, w = (v, b) => v && c ? c : b && m ? m : f, h = !f && !c && !m && x;
62
+ return /* @__PURE__ */ N("label", { className: I({ [p.isLong]: x }), children: [
63
63
  /* @__PURE__ */ e(
64
64
  "input",
65
65
  {
@@ -90,7 +90,7 @@ const rt = "_root_2bilg_1", ot = "_text_2bilg_18", nt = "_textMini_2bilg_26", st
90
90
  ] });
91
91
  });
92
92
  G.displayName = "TabSwitcherItem";
93
- const J = Object.assign(gt, { Item: G }), L = V.bind(l), vt = ({
93
+ const T = Object.assign(gt, { Item: G }), L = V.bind(l), vt = ({
94
94
  options: s,
95
95
  selectedOption: n,
96
96
  placeholder: a = "",
@@ -104,7 +104,7 @@ const J = Object.assign(gt, { Item: G }), L = V.bind(l), vt = ({
104
104
  onClickItem: S,
105
105
  onCLickSelect: f
106
106
  }) => {
107
- const [c, m] = B(!1), k = P(null), { isMobile: y } = E(), { handleBlur: x, getInputValue: w, getOption: h, handleDocumentClick: g } = et(
107
+ const [c, m] = B(!1), k = J(null), { isMobile: y } = E(), { handleBlur: x, getInputValue: w, getOption: h, handleDocumentClick: v } = et(
108
108
  {
109
109
  selectedOption: n,
110
110
  onClickOption: S,
@@ -118,9 +118,9 @@ const J = Object.assign(gt, { Item: G }), L = V.bind(l), vt = ({
118
118
  onBlur: d
119
119
  }
120
120
  );
121
- return D(() => (document.addEventListener("click", g), () => {
122
- document.removeEventListener("click", g);
123
- }), []), /* @__PURE__ */ W(
121
+ return D(() => (document.addEventListener("click", v), () => {
122
+ document.removeEventListener("click", v);
123
+ }), []), /* @__PURE__ */ N(
124
124
  "div",
125
125
  {
126
126
  ref: k,
@@ -136,7 +136,7 @@ const J = Object.assign(gt, { Item: G }), L = V.bind(l), vt = ({
136
136
  f && f();
137
137
  },
138
138
  children: [
139
- /* @__PURE__ */ W("div", { className: L(l.inputWrapper), children: [
139
+ /* @__PURE__ */ N("div", { className: L(l.inputWrapper), children: [
140
140
  /* @__PURE__ */ e(
141
141
  "input",
142
142
  {
@@ -160,7 +160,7 @@ const J = Object.assign(gt, { Item: G }), L = V.bind(l), vt = ({
160
160
  }
161
161
  )
162
162
  ] }),
163
- c && y && /* @__PURE__ */ W(
163
+ c && y && /* @__PURE__ */ N(
164
164
  q,
165
165
  {
166
166
  isOpen: c,
@@ -170,7 +170,7 @@ const J = Object.assign(gt, { Item: G }), L = V.bind(l), vt = ({
170
170
  createPortalObj: { domNode: document.querySelector("body") },
171
171
  isTransparentBack: !0,
172
172
  children: [
173
- /* @__PURE__ */ W("div", { className: l.mobileSortHeader, children: [
173
+ /* @__PURE__ */ N("div", { className: l.mobileSortHeader, children: [
174
174
  /* @__PURE__ */ e(H, { children: "Сортировка" }),
175
175
  /* @__PURE__ */ e("div", { onClick: () => m(!1), children: /* @__PURE__ */ e(
176
176
  R,
@@ -180,17 +180,17 @@ const J = Object.assign(gt, { Item: G }), L = V.bind(l), vt = ({
180
180
  }
181
181
  ) })
182
182
  ] }),
183
- /* @__PURE__ */ e("div", { className: l.mobileOptionList, children: s == null ? void 0 : s.map((N) => h(N)) })
183
+ /* @__PURE__ */ e("div", { className: l.mobileOptionList, children: s == null ? void 0 : s.map((b) => h(b)) })
184
184
  ]
185
185
  }
186
186
  ),
187
- c && !y && /* @__PURE__ */ e("div", { className: L(l.optionsList, { [l.optionListOnTop]: C }), children: s == null ? void 0 : s.map((N) => h(N)) })
187
+ c && !y && /* @__PURE__ */ e("div", { className: L(l.optionsList, { [l.optionListOnTop]: C }), children: s == null ? void 0 : s.map((b) => h(b)) })
188
188
  ]
189
189
  }
190
190
  );
191
191
  };
192
192
  vt.displayName = "SortSelect";
193
- const Wt = "_root_1occg_1", Nt = "_filterWithSaveModal_1occg_15", bt = "_modalAddBody_1occg_20", wt = "_closeBtn_1occg_29", Ot = "_btnName_1occg_35", St = "_modalTitle_1occg_39", kt = "_tabSWitcherWrapper_1occg_48", yt = "_switcherTitle_1occg_56", Ct = "_switcherScroll_1occg_63", xt = "_tabs_1occg_67", Bt = "_selectWrapper_1occg_72", It = "_filterOption_1occg_76", Mt = "_btnWrapper_1occg_83", Lt = "_resetBtn_1occg_89", Rt = "_saveBtn_1occg_90", At = "_desktopWrapper_1occg_94", Dt = "_desktopWrapperOpen_1occg_116", r = {
193
+ const Wt = "_root_1occg_1", Nt = "_filterWithSaveModal_1occg_15", bt = "_modalAddBody_1occg_20", wt = "_closeBtn_1occg_29", Ot = "_btnName_1occg_35", St = "_modalTitle_1occg_39", kt = "_tabSWitcherWrapper_1occg_48", yt = "_switcherTitle_1occg_56", Ct = "_switcherScroll_1occg_63", xt = "_tabs_1occg_67", Bt = "_selectWrapper_1occg_72", It = "_filterOption_1occg_76", Mt = "_btnWrapper_1occg_83", Lt = "_resetBtn_1occg_89", Rt = "_saveBtn_1occg_90", At = "_desktopWrapper_1occg_94", Dt = "_desktopWrapperOpen_1occg_116", o = {
194
194
  root: Wt,
195
195
  filterWithSaveModal: Nt,
196
196
  modalAddBody: bt,
@@ -246,7 +246,7 @@ var K = { exports: {} };
246
246
  })();
247
247
  })(K);
248
248
  var Et = K.exports;
249
- const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(r), de = ({
249
+ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(o), de = ({
250
250
  disabledOptions: s = [],
251
251
  tabs: n = [],
252
252
  selectOptions: a = [],
@@ -258,35 +258,35 @@ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(r), de = ({
258
258
  onCLickSelect: O,
259
259
  btnName: C = "Фильтр"
260
260
  }) => {
261
- const { isMobile: S } = E(), [f, c] = B(!1), m = P(null), [k, y] = B(i), [x] = B(u), [w, h] = B(k), [g, N] = B(x), Q = (o) => {
262
- if (d && d(o), s.some((v) => v.value === o.value))
261
+ const { isMobile: S } = E(), [f, c] = B(!1), m = J(null), [k, y] = B(i), [x] = B(u), [w, h] = B(k), [v, b] = B(x), Q = (r) => {
262
+ if (d && d(r), s.some((W) => W.value === r.value))
263
263
  return;
264
- const b = g.some((v) => v.value === o.value) ? g.filter((v) => v.value !== o.value) : [...g, o];
265
- N(b);
264
+ const g = v.some((W) => W.value === r.value) ? v.filter((W) => W.value !== r.value) : [...v, r];
265
+ b(g);
266
266
  }, U = () => {
267
- y(n), h(n), N([]), _ && (_([]), t == null || t(n));
267
+ y(n), h(n), b([]), _ && (_([]), t == null || t(n));
268
268
  }, X = () => {
269
- N(u), h(i);
269
+ b(u), h(i);
270
270
  }, j = () => {
271
271
  X(), c(!1);
272
272
  }, Y = () => {
273
- _ && (t == null || t(w), _(g)), c(!1);
273
+ _ && (t == null || t(w), _(v)), c(!1);
274
274
  };
275
275
  D(() => {
276
- f || h((o) => JSON.stringify(o) !== JSON.stringify(i) ? i : o);
276
+ f || h((r) => JSON.stringify(r) !== JSON.stringify(i) ? i : r);
277
277
  }, [f, i]), D(() => {
278
- const o = (b) => {
279
- console.log("gdfgdfgdfg"), m.current && console.log(m.current.contains(b.target)), !(m.current && m.current.contains(b.target)) && j();
278
+ const r = (g) => {
279
+ g.stopPropagation(), g.stopImmediatePropagation(), console.log("gdfgdfgdfg"), m.current && console.log(m.current.contains(g.target)), !(m.current && m.current.contains(g.target)) && j();
280
280
  };
281
- return f ? document.addEventListener("click", o) : document.removeEventListener("click", o), () => {
282
- document.removeEventListener("click", o);
281
+ return f ? document.addEventListener("click", r) : document.removeEventListener("click", r), () => {
282
+ document.removeEventListener("click", r);
283
283
  };
284
284
  }, [f]);
285
- const $ = () => /* @__PURE__ */ W(F, { children: [
285
+ const $ = () => /* @__PURE__ */ N(F, { children: [
286
286
  /* @__PURE__ */ e(
287
287
  "div",
288
288
  {
289
- className: r.closeBtn,
289
+ className: o.closeBtn,
290
290
  onClick: () => {
291
291
  j();
292
292
  },
@@ -299,88 +299,88 @@ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(r), de = ({
299
299
  )
300
300
  }
301
301
  ),
302
- /* @__PURE__ */ e("div", { className: r.modalTitle, children: "Фильтры" }),
303
- /* @__PURE__ */ W("div", { className: r.tabSWitcherWrapper, children: [
304
- /* @__PURE__ */ e("div", { className: r.switcherTitle, children: "Готовность" }),
305
- /* @__PURE__ */ e("div", { className: r.switcherScroll, children: /* @__PURE__ */ e(
306
- J,
302
+ /* @__PURE__ */ e("div", { className: o.modalTitle, children: "Фильтры" }),
303
+ /* @__PURE__ */ N("div", { className: o.tabSWitcherWrapper, children: [
304
+ /* @__PURE__ */ e("div", { className: o.switcherTitle, children: "Готовность" }),
305
+ /* @__PURE__ */ e("div", { className: o.switcherScroll, children: /* @__PURE__ */ e(
306
+ T,
307
307
  {
308
308
  variant: "grayRow",
309
- addClassName: r.tabs,
309
+ addClassName: o.tabs,
310
310
  isApart: !0,
311
- children: n == null ? void 0 : n.map((o, b) => {
311
+ children: n == null ? void 0 : n.map((r, g) => {
312
312
  var z;
313
- const v = o.value;
313
+ const W = r.value;
314
314
  return /* @__PURE__ */ e(
315
- J.Item,
315
+ T.Item,
316
316
  {
317
317
  itemsLength: n == null ? void 0 : n.length,
318
318
  mini: !0,
319
- value: v,
319
+ value: W,
320
320
  onClick: () => {
321
321
  },
322
- checked: ((z = w == null ? void 0 : w.find((A) => A.value === v)) == null ? void 0 : z.state) ?? !1,
322
+ checked: ((z = w == null ? void 0 : w.find((A) => A.value === W)) == null ? void 0 : z.state) ?? !1,
323
323
  onChange: () => {
324
324
  h == null || h(
325
- (A) => A.map((M) => M.value === v ? { ...M, state: !M.state } : M)
325
+ (A) => A.map((M) => M.value === W ? { ...M, state: !M.state } : M)
326
326
  );
327
327
  },
328
- index: b,
329
- addItemClassName: r.tabSwitcher,
330
- children: v
328
+ index: g,
329
+ addItemClassName: o.tabSwitcher,
330
+ children: W
331
331
  },
332
- b
332
+ g
333
333
  );
334
334
  })
335
335
  }
336
336
  ) })
337
337
  ] }),
338
- /* @__PURE__ */ e("div", { className: r.selectWrapper, children: a == null ? void 0 : a.map((o, b) => /* @__PURE__ */ e(
338
+ /* @__PURE__ */ e("div", { className: o.selectWrapper, children: a == null ? void 0 : a.map((r, g) => /* @__PURE__ */ e(
339
339
  it,
340
340
  {
341
- addClassName: r.filterOption,
341
+ addClassName: o.filterOption,
342
342
  disabledOptions: [],
343
343
  clickableOptions: [],
344
- selectedOptions: g,
345
- option: o,
344
+ selectedOptions: v,
345
+ option: r,
346
346
  handleOptionClick: Q
347
347
  },
348
- b
348
+ g
349
349
  )) }),
350
- /* @__PURE__ */ W("div", { className: r.btnWrapper, children: [
350
+ /* @__PURE__ */ N("div", { className: o.btnWrapper, children: [
351
351
  /* @__PURE__ */ e(
352
- T,
352
+ P,
353
353
  {
354
354
  as: "button",
355
355
  variant: "gray",
356
- additionalClass: r.resetBtn,
356
+ additionalClass: o.resetBtn,
357
357
  onClick: U,
358
358
  children: "Сбросить"
359
359
  }
360
360
  ),
361
361
  /* @__PURE__ */ e(
362
- T,
362
+ P,
363
363
  {
364
364
  as: "button",
365
- additionalClass: r.saveBtn,
365
+ additionalClass: o.saveBtn,
366
366
  onClick: Y,
367
367
  children: "Сохранить"
368
368
  }
369
369
  )
370
370
  ] })
371
371
  ] });
372
- return /* @__PURE__ */ W(F, { children: [
373
- /* @__PURE__ */ W(
372
+ return /* @__PURE__ */ N(F, { children: [
373
+ /* @__PURE__ */ N(
374
374
  "div",
375
375
  {
376
376
  ref: m,
377
- className: r.root,
377
+ className: o.root,
378
378
  id: "modal-container",
379
379
  onClick: () => {
380
- O && O(), c(S ? (o) => !o : !0);
380
+ O && O(), c(S ? (r) => !r : !0);
381
381
  },
382
382
  children: [
383
- /* @__PURE__ */ e("div", { className: r.btnName, children: C }),
383
+ /* @__PURE__ */ e("div", { className: o.btnName, children: C }),
384
384
  /* @__PURE__ */ e(
385
385
  R,
386
386
  {
@@ -388,7 +388,7 @@ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(r), de = ({
388
388
  size: "16"
389
389
  }
390
390
  ),
391
- !S && /* @__PURE__ */ e("div", { className: $t(r.desktopWrapper, { [r.desktopWrapperOpen]: f }), children: /* @__PURE__ */ e($, {}) })
391
+ !S && /* @__PURE__ */ e("div", { className: $t(o.desktopWrapper, { [o.desktopWrapperOpen]: f }), children: /* @__PURE__ */ e($, {}) })
392
392
  ]
393
393
  }
394
394
  ),
@@ -398,8 +398,8 @@ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(r), de = ({
398
398
  isOpen: f,
399
399
  emitIsOpen: c,
400
400
  isTransparentBack: !0,
401
- additionalClassModalBody: r.modalAddBody,
402
- additionalClass: r.filterWithSaveModal,
401
+ additionalClassModalBody: o.modalAddBody,
402
+ additionalClass: o.filterWithSaveModal,
403
403
  children: /* @__PURE__ */ e($, {})
404
404
  }
405
405
  )
@@ -407,6 +407,6 @@ const jt = /* @__PURE__ */ tt(Et), $t = jt.bind(r), de = ({
407
407
  };
408
408
  export {
409
409
  de as F,
410
- J as S,
410
+ T as S,
411
411
  vt as a
412
412
  };
@@ -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-C8YKZZ0p.js";
4
+ import { F as w } from "../../../FilterWithSave-67AAGPax.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-C8YKZZ0p.js";
1
+ import { a as r } from "../../FilterWithSave-67AAGPax.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-C8YKZZ0p.js";
16
+ import { a as z } from "../../../FilterWithSave-67AAGPax.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-C8YKZZ0p.js";
1
+ import { S as e } from "../../FilterWithSave-67AAGPax.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-C8YKZZ0p.js";
3
+ import { S as v } from "../../../FilterWithSave-67AAGPax.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-C8YKZZ0p.js";
14
+ import "../../../FilterWithSave-67AAGPax.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-C8YKZZ0p.js";
13
+ import { F as B, a as L, S as k } from "./FilterWithSave-67AAGPax.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.579",
5
+ "version": "0.0.580",
6
6
  "author": "Mollycodd1e",
7
7
  "license": "ISC",
8
8
  "type": "module",