stone-kit 0.0.529 → 0.0.531

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,51 +1,51 @@
1
- import { jsxs as _, Fragment as z, jsx as e } from "react/jsx-runtime";
2
- import { useState as c, useEffect as F } from "react";
1
+ import { jsxs as _, Fragment as F, jsx as e } from "react/jsx-runtime";
2
+ import { useState as c, useEffect as R } from "react";
3
3
  import { NewIcon as C } from "../../NewIcon/ui/NewIcon.js";
4
- import { M as R } from "../../../Modal-BZv6nlLe.js";
4
+ import { M as E } from "../../../Modal-BZv6nlLe.js";
5
5
  import { S as N } from "../../../SortSelect-Chp89Mue.js";
6
- import { O as E } from "../../../Option-CyYM1iBJ.js";
6
+ import { O as q } from "../../../Option-CyYM1iBJ.js";
7
7
  import { Button as O } from "../../Button/ui/Button.js";
8
- const q = "_root_1fkwh_1", D = "_filterWithSaveModal_1fkwh_15", G = "_modalAddBody_1fkwh_20", H = "_closeBtn_1fkwh_29", J = "_modalTitle_1fkwh_35", K = "_tabSWitcherWrapper_1fkwh_44", L = "_switcherTitle_1fkwh_52", P = "_switcherScroll_1fkwh_59", Q = "_tabs_1fkwh_63", U = "_selectWrapper_1fkwh_68", X = "_filterOption_1fkwh_72", Y = "_btnWrapper_1fkwh_79", Z = "_resetBtn_1fkwh_85", $ = "_saveBtn_1fkwh_86", t = {
9
- root: q,
10
- filterWithSaveModal: D,
11
- modalAddBody: G,
12
- closeBtn: H,
13
- modalTitle: J,
14
- tabSWitcherWrapper: K,
15
- switcherTitle: L,
16
- switcherScroll: P,
17
- tabs: Q,
18
- selectWrapper: U,
19
- filterOption: X,
20
- btnWrapper: Y,
21
- resetBtn: Z,
22
- saveBtn: $
23
- }, at = ({
8
+ const D = "_root_1fkwh_1", G = "_filterWithSaveModal_1fkwh_15", H = "_modalAddBody_1fkwh_20", J = "_closeBtn_1fkwh_29", K = "_modalTitle_1fkwh_35", L = "_tabSWitcherWrapper_1fkwh_44", P = "_switcherTitle_1fkwh_52", Q = "_switcherScroll_1fkwh_59", U = "_tabs_1fkwh_63", X = "_selectWrapper_1fkwh_68", Y = "_filterOption_1fkwh_72", Z = "_btnWrapper_1fkwh_79", $ = "_resetBtn_1fkwh_85", V = "_saveBtn_1fkwh_86", t = {
9
+ root: D,
10
+ filterWithSaveModal: G,
11
+ modalAddBody: H,
12
+ closeBtn: J,
13
+ modalTitle: K,
14
+ tabSWitcherWrapper: L,
15
+ switcherTitle: P,
16
+ switcherScroll: Q,
17
+ tabs: U,
18
+ selectWrapper: X,
19
+ filterOption: Y,
20
+ btnWrapper: Z,
21
+ resetBtn: $,
22
+ saveBtn: V
23
+ }, lt = ({
24
24
  disabledOptions: S = [],
25
- tabs: a = [],
25
+ tabs: r = [],
26
26
  selectOptions: v = [],
27
27
  onChange: d,
28
28
  selectedValues: u = [],
29
29
  setSelectedTabs: l,
30
30
  selectedTabs: h = []
31
31
  }) => {
32
- const [w, m] = c(!1), [M] = c(h), [y] = c(u), [p, n] = c(M), [s, k] = c(y), A = (i) => {
33
- if (S.some((r) => r.value === i.value))
32
+ const [w, m] = c(!1), [M, y] = c(h), [I] = c(u), [p, o] = c(M), [s, k] = c(I), A = (i) => {
33
+ if (S.some((a) => a.value === i.value))
34
34
  return;
35
- const o = s.some((r) => r.value === i.value) ? s.filter((r) => r.value !== i.value) : [...s, i];
36
- k(o);
37
- }, I = () => {
38
- n(a), k([]), d && (d([]), l == null || l(a));
35
+ const n = s.some((a) => a.value === i.value) ? s.filter((a) => a.value !== i.value) : [...s, i];
36
+ k(n);
39
37
  }, x = () => {
40
- k(u), n(h);
38
+ y(r), k([]), d && (d([]), l == null || l(r));
41
39
  }, g = () => {
42
- x(), m(!1);
40
+ k(u), o(h);
43
41
  }, j = () => {
42
+ g(), m(!1);
43
+ }, z = () => {
44
44
  d && (l == null || l(p), d(s)), m(!1);
45
45
  };
46
- return F(() => {
47
- w || n(h);
48
- }, [w, h]), /* @__PURE__ */ _(z, { children: [
46
+ return R(() => {
47
+ w || o(h);
48
+ }, [w, h]), /* @__PURE__ */ _(F, { children: [
49
49
  /* @__PURE__ */ e(
50
50
  "div",
51
51
  {
@@ -63,7 +63,7 @@ const q = "_root_1fkwh_1", D = "_filterWithSaveModal_1fkwh_15", G = "_modalAddBo
63
63
  }
64
64
  ),
65
65
  /* @__PURE__ */ _(
66
- R,
66
+ E,
67
67
  {
68
68
  isOpen: w,
69
69
  emitIsOpen: m,
@@ -75,7 +75,7 @@ const q = "_root_1fkwh_1", D = "_filterWithSaveModal_1fkwh_15", G = "_modalAddBo
75
75
  "div",
76
76
  {
77
77
  className: t.closeBtn,
78
- onClick: g,
78
+ onClick: j,
79
79
  children: /* @__PURE__ */ e(
80
80
  C,
81
81
  {
@@ -94,35 +94,35 @@ const q = "_root_1fkwh_1", D = "_filterWithSaveModal_1fkwh_15", G = "_modalAddBo
94
94
  variant: "grayRow",
95
95
  addClassName: t.tabs,
96
96
  isApart: !0,
97
- children: a == null ? void 0 : a.map((i, o) => {
97
+ children: r == null ? void 0 : r.map((i, n) => {
98
98
  var B;
99
- const r = i.value;
99
+ const a = i.value;
100
100
  return /* @__PURE__ */ e(
101
101
  N.Item,
102
102
  {
103
- itemsLength: a == null ? void 0 : a.length,
103
+ itemsLength: r == null ? void 0 : r.length,
104
104
  mini: !0,
105
- value: r,
105
+ value: a,
106
106
  onClick: () => {
107
107
  },
108
- checked: ((B = p == null ? void 0 : p.find((W) => W.value === r)) == null ? void 0 : B.state) ?? !1,
108
+ checked: ((B = p == null ? void 0 : p.find((W) => W.value === a)) == null ? void 0 : B.state) ?? !1,
109
109
  onChange: () => {
110
- n == null || n(
111
- (W) => W.map((f) => f.value === r ? { ...f, state: !f.state } : f)
110
+ o == null || o(
111
+ (W) => W.map((f) => f.value === a ? { ...f, state: !f.state } : f)
112
112
  );
113
113
  },
114
- index: o,
114
+ index: n,
115
115
  addItemClassName: t.tabSwitcher,
116
- children: r
116
+ children: a
117
117
  },
118
- o
118
+ n
119
119
  );
120
120
  })
121
121
  }
122
122
  ) })
123
123
  ] }),
124
- /* @__PURE__ */ e("div", { className: t.selectWrapper, children: v == null ? void 0 : v.map((i, o) => /* @__PURE__ */ e(
125
- E,
124
+ /* @__PURE__ */ e("div", { className: t.selectWrapper, children: v == null ? void 0 : v.map((i, n) => /* @__PURE__ */ e(
125
+ q,
126
126
  {
127
127
  addClassName: t.filterOption,
128
128
  disabledOptions: [],
@@ -131,7 +131,7 @@ const q = "_root_1fkwh_1", D = "_filterWithSaveModal_1fkwh_15", G = "_modalAddBo
131
131
  option: i,
132
132
  handleOptionClick: A
133
133
  },
134
- o
134
+ n
135
135
  )) }),
136
136
  /* @__PURE__ */ _("div", { className: t.btnWrapper, children: [
137
137
  /* @__PURE__ */ e(
@@ -140,7 +140,7 @@ const q = "_root_1fkwh_1", D = "_filterWithSaveModal_1fkwh_15", G = "_modalAddBo
140
140
  as: "button",
141
141
  variant: "gray",
142
142
  additionalClass: t.resetBtn,
143
- onClick: I,
143
+ onClick: x,
144
144
  children: "Сбросить"
145
145
  }
146
146
  ),
@@ -149,7 +149,7 @@ const q = "_root_1fkwh_1", D = "_filterWithSaveModal_1fkwh_15", G = "_modalAddBo
149
149
  {
150
150
  as: "button",
151
151
  additionalClass: t.saveBtn,
152
- onClick: j,
152
+ onClick: z,
153
153
  children: "Сохранить"
154
154
  }
155
155
  )
@@ -160,5 +160,5 @@ const q = "_root_1fkwh_1", D = "_filterWithSaveModal_1fkwh_15", G = "_modalAddBo
160
160
  ] });
161
161
  };
162
162
  export {
163
- at as FilterWithSave
163
+ lt as FilterWithSave
164
164
  };
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.529",
5
+ "version": "0.0.531",
6
6
  "author": "Mollycodd1e",
7
7
  "license": "ISC",
8
8
  "type": "module",