stone-kit 0.0.1080 → 0.0.1085
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.
- package/README.md +88 -88
- package/dist/components/CheckBoxNew/CheckBoxNew.js +5 -5
- package/dist/components/CommercialLotCard/CommercialLotCard.js +91 -10
- package/dist/components/CommercialLotCard/components/PaymentLink/PaymentLink.js +4 -4
- package/dist/components/CommercialLotCard/components/Snippets/Snippets.js +98 -27
- package/dist/components/CommercialLotCard/components/Tags/Tags.js +1 -1
- package/dist/components/FilterWithSave/hooks/useFilterWithSave.js +54 -26
- package/dist/components/FilterWithSave/ui/FilterWithSave.js +323 -7
- package/dist/components/FormModal/ui/ModalForm.js +1516 -29
- package/dist/components/Logo/ui/Logo.js +6 -6
- package/dist/components/LotCard/hooks/useLotCard.js +6 -24
- package/dist/components/LotCard/index.js +2 -2
- package/dist/components/LotCard/ui/LotCard.js +252 -12
- package/dist/components/Modal/ui/Modal.js +22 -22
- package/dist/components/ModalSuccess/ModalSuccess.js +1 -1
- package/dist/components/RoundButton/ui/RoundButton.js +1 -1
- package/dist/components/Select/ui/Category.js +2 -2
- package/dist/components/Select/ui/Option.js +2 -2
- package/dist/components/Select/ui/Select.js +2 -2
- package/dist/components/SliderNavigation/ui/SliderNavigation.js +6 -6
- package/dist/components/SortSelect/index.js +1 -1
- package/dist/components/SortSelect/ui/SortSelect.js +108 -26
- package/dist/components/SummarySelect/ui/SummarySelect.js +1 -1
- package/dist/components/TabSelect/ui/TabSelect.js +4 -4
- package/dist/components/TabSwitcher/index.js +2 -2
- package/dist/components/TabSwitcher/ui/TabSwitcher.js +121 -26
- package/dist/layout/components/Header/Header.js +44 -65
- package/dist/layout/components/Menu.js +15 -37
- package/dist/main.js +70 -65
- package/dist/pages/ButtonsPage/Buttons.js +44 -61
- package/dist/pages/FormsPage/FormsPage.js +22 -42
- package/dist/pages/IconsPage/IconsPage.js +9 -31
- package/dist/pages/InputPage/InputPage.js +10 -32
- package/dist/pages/LogoPage/LogoPage.js +13 -36
- package/dist/pages/LotsPage/LotsPage.js +25 -24
- package/dist/pages/ModalsPage/ModalPage.js +46 -66
- package/dist/pages/SelectPage/SelectPage.js +41 -40
- package/dist/pages/TabsPage/TabsPage.js +1 -1
- package/dist/pages/TagsPage/TagsPage.js +23 -44
- package/dist/stone-kit.css +1 -1
- package/dist/stories/entities/CommercialLotCard/CommercialLotCard.stories.js +1 -1
- package/dist/stories/shared/ui/Button/Button.stories.js +4 -4
- package/dist/stories/shared/ui/FilterWithSave/FilterWithSave.stories.js +1 -1
- package/dist/stories/shared/ui/FormModal/FormModal.stories.js +7 -7
- package/dist/stories/shared/ui/SortSelect/SortSelect.stories.js +1 -1
- package/dist/stories/shared/ui/TabSwitcher/TabSwitcher.stories.js +1 -1
- package/dist/stories/shared/ui/Tag/Tag.stories.js +4 -4
- package/dist/useLotCard-BAA8s2eo.js +189 -0
- package/package.json +1 -1
- package/dist/FilterWithSave-B-Qb2OD5.js +0 -2718
- package/dist/{Option-DdjBe9yb.js → Option-DmDx_xOt.js} +1 -1
|
@@ -1,9 +1,325 @@
|
|
|
1
|
-
import "react/jsx-runtime";
|
|
2
|
-
import "
|
|
3
|
-
import {
|
|
4
|
-
import "
|
|
5
|
-
import "
|
|
6
|
-
import "../../
|
|
1
|
+
import { jsxs as d, Fragment as I, jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { O as M } from "../../../Option-DmDx_xOt.js";
|
|
3
|
+
import { g as D } from "../../../index-YnD2EP-S.js";
|
|
4
|
+
import { useFilterWithSave as P } from "../hooks/useFilterWithSave.js";
|
|
5
|
+
import { NewIcon as S } from "../../NewIcon/ui/NewIcon.js";
|
|
6
|
+
import { TabSwitcher as _ } from "../../TabSwitcher/ui/TabSwitcher.js";
|
|
7
|
+
import { Button as f } from "../../Button/ui/Button.js";
|
|
8
|
+
import { Modal as V } from "../../Modal/ui/Modal.js";
|
|
9
|
+
const G = "_root_1v1y9_1", H = "_filterWithSaveModal_1v1y9_15", J = "_modalAddBody_1v1y9_20", K = "_closeBtn_1v1y9_29", Q = "_btnName_1v1y9_35", U = "_modalTitle_1v1y9_39", X = "_tabSWitcherWrapper_1v1y9_48", Y = "_switcherTitle_1v1y9_77", Z = "_switcherScroll_1v1y9_84", ee = "_tabs_1v1y9_93", te = "_selectWrapper_1v1y9_98", ae = "_filterOption_1v1y9_102", re = "_btnWrapper_1v1y9_110", ie = "_resetBtn_1v1y9_116", se = "_saveBtn_1v1y9_117", ne = "_desktopWrapper_1v1y9_121", le = "_desktopWrapperOpen_1v1y9_144", e = {
|
|
10
|
+
root: G,
|
|
11
|
+
filterWithSaveModal: H,
|
|
12
|
+
modalAddBody: J,
|
|
13
|
+
closeBtn: K,
|
|
14
|
+
btnName: Q,
|
|
15
|
+
modalTitle: U,
|
|
16
|
+
tabSWitcherWrapper: X,
|
|
17
|
+
switcherTitle: Y,
|
|
18
|
+
switcherScroll: Z,
|
|
19
|
+
tabs: ee,
|
|
20
|
+
selectWrapper: te,
|
|
21
|
+
filterOption: ae,
|
|
22
|
+
btnWrapper: re,
|
|
23
|
+
resetBtn: ie,
|
|
24
|
+
saveBtn: se,
|
|
25
|
+
desktopWrapper: ne,
|
|
26
|
+
desktopWrapperOpen: le
|
|
27
|
+
};
|
|
28
|
+
var N = { exports: {} };
|
|
29
|
+
var A;
|
|
30
|
+
function oe() {
|
|
31
|
+
return A || (A = 1, (function(v) {
|
|
32
|
+
(function() {
|
|
33
|
+
var p = {}.hasOwnProperty;
|
|
34
|
+
function s() {
|
|
35
|
+
for (var a = "", i = 0; i < arguments.length; i++) {
|
|
36
|
+
var l = arguments[i];
|
|
37
|
+
l && (a = h(a, u.call(this, l)));
|
|
38
|
+
}
|
|
39
|
+
return a;
|
|
40
|
+
}
|
|
41
|
+
function u(a) {
|
|
42
|
+
if (typeof a == "string" || typeof a == "number")
|
|
43
|
+
return this && this[a] || a;
|
|
44
|
+
if (typeof a != "object")
|
|
45
|
+
return "";
|
|
46
|
+
if (Array.isArray(a))
|
|
47
|
+
return s.apply(this, a);
|
|
48
|
+
if (a.toString !== Object.prototype.toString && !a.toString.toString().includes("[native code]"))
|
|
49
|
+
return a.toString();
|
|
50
|
+
var i = "";
|
|
51
|
+
for (var l in a)
|
|
52
|
+
p.call(a, l) && a[l] && (i = h(i, this && this[l] || l));
|
|
53
|
+
return i;
|
|
54
|
+
}
|
|
55
|
+
function h(a, i) {
|
|
56
|
+
return i ? a ? a + " " + i : a + i : a;
|
|
57
|
+
}
|
|
58
|
+
v.exports ? (s.default = s, v.exports = s) : window.classNames = s;
|
|
59
|
+
})();
|
|
60
|
+
})(N)), N.exports;
|
|
61
|
+
}
|
|
62
|
+
var ce = oe();
|
|
63
|
+
const de = /* @__PURE__ */ D(ce), pe = de.bind(e), ye = ({
|
|
64
|
+
disabledOptions: v,
|
|
65
|
+
tabs: p = [],
|
|
66
|
+
selectOptions: s = [],
|
|
67
|
+
onChange: u,
|
|
68
|
+
onClick: h = () => null,
|
|
69
|
+
selectedValues: a,
|
|
70
|
+
setSelectedTabs: i,
|
|
71
|
+
selectedTabs: l,
|
|
72
|
+
onClickItem: z,
|
|
73
|
+
onCLickSelect: B,
|
|
74
|
+
dataTestId: j,
|
|
75
|
+
onSaveClick: F = () => null,
|
|
76
|
+
onClearClick: R = () => null,
|
|
77
|
+
onTabClick: q = () => null,
|
|
78
|
+
btnName: E = "Фильтр"
|
|
79
|
+
}) => {
|
|
80
|
+
const {
|
|
81
|
+
handleCloseModal: C,
|
|
82
|
+
localSelectedTabs: O,
|
|
83
|
+
selectedOptions: k,
|
|
84
|
+
isMobile: b,
|
|
85
|
+
handleOptionClick: w,
|
|
86
|
+
handleClearClick: T,
|
|
87
|
+
handleSaveClick: x,
|
|
88
|
+
isModalOpen: W,
|
|
89
|
+
setLocalSelectedTabs: g,
|
|
90
|
+
setIsModalOpen: y,
|
|
91
|
+
containerRef: L
|
|
92
|
+
} = P({
|
|
93
|
+
selectedTabs: l,
|
|
94
|
+
onClickItem: z,
|
|
95
|
+
setSelectedTabs: i,
|
|
96
|
+
tabs: p,
|
|
97
|
+
onChange: u,
|
|
98
|
+
disabledOptions: v,
|
|
99
|
+
selectedValues: a,
|
|
100
|
+
onSaveClick: F,
|
|
101
|
+
onClearClick: R
|
|
102
|
+
}), $ = () => /* @__PURE__ */ d(I, { children: [
|
|
103
|
+
/* @__PURE__ */ t(
|
|
104
|
+
"div",
|
|
105
|
+
{
|
|
106
|
+
className: e.closeBtn,
|
|
107
|
+
onClick: () => {
|
|
108
|
+
C();
|
|
109
|
+
},
|
|
110
|
+
children: /* @__PURE__ */ t(
|
|
111
|
+
S,
|
|
112
|
+
{
|
|
113
|
+
name: "close",
|
|
114
|
+
size: "24"
|
|
115
|
+
}
|
|
116
|
+
)
|
|
117
|
+
}
|
|
118
|
+
),
|
|
119
|
+
/* @__PURE__ */ t("div", { className: e.modalTitle, children: "Фильтры" }),
|
|
120
|
+
/* @__PURE__ */ d("div", { className: e.tabSWitcherWrapper, children: [
|
|
121
|
+
/* @__PURE__ */ t("div", { className: e.switcherTitle, children: "Готовность" }),
|
|
122
|
+
/* @__PURE__ */ t("div", { className: e.switcherScroll, children: /* @__PURE__ */ t(
|
|
123
|
+
_,
|
|
124
|
+
{
|
|
125
|
+
variant: "grayRow",
|
|
126
|
+
addClassName: e.tabs,
|
|
127
|
+
isApart: !0,
|
|
128
|
+
children: p?.map((o, n) => {
|
|
129
|
+
const r = o.value;
|
|
130
|
+
return /* @__PURE__ */ t(
|
|
131
|
+
_.Item,
|
|
132
|
+
{
|
|
133
|
+
itemsLength: p?.length,
|
|
134
|
+
mini: !0,
|
|
135
|
+
size_s: "small",
|
|
136
|
+
value: r,
|
|
137
|
+
onClick: () => {
|
|
138
|
+
},
|
|
139
|
+
checked: O?.find((m) => m.value === r)?.state ?? !1,
|
|
140
|
+
onChange: () => {
|
|
141
|
+
g?.(
|
|
142
|
+
(m) => m.map((c) => c.value === r ? { ...c, state: !c.state } : c)
|
|
143
|
+
);
|
|
144
|
+
},
|
|
145
|
+
index: n,
|
|
146
|
+
children: r
|
|
147
|
+
},
|
|
148
|
+
n
|
|
149
|
+
);
|
|
150
|
+
})
|
|
151
|
+
}
|
|
152
|
+
) })
|
|
153
|
+
] }),
|
|
154
|
+
/* @__PURE__ */ t("div", { className: e.selectWrapper, children: s?.map((o, n) => /* @__PURE__ */ t(
|
|
155
|
+
M,
|
|
156
|
+
{
|
|
157
|
+
sizeIcon: "24",
|
|
158
|
+
addClassName: e.filterOption,
|
|
159
|
+
disabledOptions: [],
|
|
160
|
+
clickableOptions: s?.map((r) => r.value.toString()),
|
|
161
|
+
selectedOptions: k,
|
|
162
|
+
option: o,
|
|
163
|
+
handleOptionClick: w
|
|
164
|
+
},
|
|
165
|
+
n
|
|
166
|
+
)) }),
|
|
167
|
+
/* @__PURE__ */ d("div", { className: e.btnWrapper, children: [
|
|
168
|
+
/* @__PURE__ */ t(
|
|
169
|
+
f,
|
|
170
|
+
{
|
|
171
|
+
as: "button",
|
|
172
|
+
variant: "gray",
|
|
173
|
+
additionalClass: e.resetBtn,
|
|
174
|
+
onClick: T,
|
|
175
|
+
children: "Сбросить"
|
|
176
|
+
}
|
|
177
|
+
),
|
|
178
|
+
/* @__PURE__ */ t(
|
|
179
|
+
f,
|
|
180
|
+
{
|
|
181
|
+
as: "button",
|
|
182
|
+
additionalClass: e.saveBtn,
|
|
183
|
+
onClick: x,
|
|
184
|
+
children: "Сохранить"
|
|
185
|
+
}
|
|
186
|
+
)
|
|
187
|
+
] })
|
|
188
|
+
] });
|
|
189
|
+
return /* @__PURE__ */ d(I, { children: [
|
|
190
|
+
/* @__PURE__ */ d("div", { style: { position: "relative" }, children: [
|
|
191
|
+
/* @__PURE__ */ d(
|
|
192
|
+
"div",
|
|
193
|
+
{
|
|
194
|
+
className: e.root,
|
|
195
|
+
"data-testid": j,
|
|
196
|
+
onClick: () => {
|
|
197
|
+
B && B(), h && h(), b ? y((o) => !o) : W || y(!0);
|
|
198
|
+
},
|
|
199
|
+
children: [
|
|
200
|
+
/* @__PURE__ */ t("div", { className: e.btnName, children: E }),
|
|
201
|
+
/* @__PURE__ */ t(
|
|
202
|
+
S,
|
|
203
|
+
{
|
|
204
|
+
name: "filter",
|
|
205
|
+
size: "16"
|
|
206
|
+
}
|
|
207
|
+
)
|
|
208
|
+
]
|
|
209
|
+
}
|
|
210
|
+
),
|
|
211
|
+
!b && /* @__PURE__ */ d(
|
|
212
|
+
"div",
|
|
213
|
+
{
|
|
214
|
+
ref: L,
|
|
215
|
+
className: pe(e.desktopWrapper, { [e.desktopWrapperOpen]: W }),
|
|
216
|
+
children: [
|
|
217
|
+
/* @__PURE__ */ t(
|
|
218
|
+
"div",
|
|
219
|
+
{
|
|
220
|
+
className: e.closeBtn,
|
|
221
|
+
onClick: () => {
|
|
222
|
+
C();
|
|
223
|
+
},
|
|
224
|
+
children: /* @__PURE__ */ t(
|
|
225
|
+
S,
|
|
226
|
+
{
|
|
227
|
+
name: "close",
|
|
228
|
+
size: "24"
|
|
229
|
+
}
|
|
230
|
+
)
|
|
231
|
+
}
|
|
232
|
+
),
|
|
233
|
+
/* @__PURE__ */ t("div", { className: e.modalTitle, children: "Фильтры" }),
|
|
234
|
+
/* @__PURE__ */ d("div", { className: e.tabSWitcherWrapper, children: [
|
|
235
|
+
/* @__PURE__ */ t("div", { className: e.switcherTitle, children: "Готовность" }),
|
|
236
|
+
/* @__PURE__ */ t("div", { className: e.switcherScroll, children: /* @__PURE__ */ t(
|
|
237
|
+
_,
|
|
238
|
+
{
|
|
239
|
+
variant: "grayRow",
|
|
240
|
+
addClassName: e.tabs,
|
|
241
|
+
isApart: !0,
|
|
242
|
+
children: p?.map((o, n) => {
|
|
243
|
+
const r = o.value;
|
|
244
|
+
return /* @__PURE__ */ t(
|
|
245
|
+
_.Item,
|
|
246
|
+
{
|
|
247
|
+
itemsLength: p?.length,
|
|
248
|
+
dataTestId: `filterWithSave_year_${r}_tab`,
|
|
249
|
+
size_s: "small",
|
|
250
|
+
mini: !0,
|
|
251
|
+
value: r,
|
|
252
|
+
onClick: () => q(),
|
|
253
|
+
checked: O?.find((m) => m.value === r)?.state ?? !1,
|
|
254
|
+
onChange: () => {
|
|
255
|
+
g?.(
|
|
256
|
+
(m) => m.map((c) => c.value === r ? { ...c, state: !c.state } : c)
|
|
257
|
+
);
|
|
258
|
+
},
|
|
259
|
+
index: n,
|
|
260
|
+
addItemClassName: e.tabSwitcher,
|
|
261
|
+
children: r
|
|
262
|
+
},
|
|
263
|
+
n
|
|
264
|
+
);
|
|
265
|
+
})
|
|
266
|
+
}
|
|
267
|
+
) })
|
|
268
|
+
] }),
|
|
269
|
+
/* @__PURE__ */ t("div", { className: e.selectWrapper, children: s?.map((o, n) => /* @__PURE__ */ t(
|
|
270
|
+
M,
|
|
271
|
+
{
|
|
272
|
+
sizeIcon: "24",
|
|
273
|
+
dataTestId: `filterWIthSave_${n}_select`,
|
|
274
|
+
addClassName: e.filterOption,
|
|
275
|
+
disabledOptions: [],
|
|
276
|
+
clickableOptions: s?.map((r) => r.value.toString()),
|
|
277
|
+
selectedOptions: k,
|
|
278
|
+
option: o,
|
|
279
|
+
handleOptionClick: w
|
|
280
|
+
},
|
|
281
|
+
n
|
|
282
|
+
)) }),
|
|
283
|
+
/* @__PURE__ */ d("div", { className: e.btnWrapper, children: [
|
|
284
|
+
/* @__PURE__ */ t(
|
|
285
|
+
f,
|
|
286
|
+
{
|
|
287
|
+
"data-testid": "filterWithSave_clear_btn",
|
|
288
|
+
as: "button",
|
|
289
|
+
variant: "gray",
|
|
290
|
+
additionalClass: e.resetBtn,
|
|
291
|
+
onClick: T,
|
|
292
|
+
children: "Сбросить"
|
|
293
|
+
}
|
|
294
|
+
),
|
|
295
|
+
/* @__PURE__ */ t(
|
|
296
|
+
f,
|
|
297
|
+
{
|
|
298
|
+
"data-testid": "filterWithSave_save_btn",
|
|
299
|
+
as: "button",
|
|
300
|
+
additionalClass: e.saveBtn,
|
|
301
|
+
onClick: x,
|
|
302
|
+
children: "Сохранить"
|
|
303
|
+
}
|
|
304
|
+
)
|
|
305
|
+
] })
|
|
306
|
+
]
|
|
307
|
+
}
|
|
308
|
+
)
|
|
309
|
+
] }),
|
|
310
|
+
b && /* @__PURE__ */ t(
|
|
311
|
+
V,
|
|
312
|
+
{
|
|
313
|
+
isOpen: W,
|
|
314
|
+
emitIsOpen: y,
|
|
315
|
+
isTransparentBack: !0,
|
|
316
|
+
additionalClassModalBody: e.modalAddBody,
|
|
317
|
+
additionalClass: e.filterWithSaveModal,
|
|
318
|
+
children: /* @__PURE__ */ t($, {})
|
|
319
|
+
}
|
|
320
|
+
)
|
|
321
|
+
] });
|
|
322
|
+
};
|
|
7
323
|
export {
|
|
8
|
-
|
|
324
|
+
ye as FilterWithSave
|
|
9
325
|
};
|