@lanaco/lnc-react-ui 4.0.77 → 4.0.78
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,4 +1,4 @@
|
|
|
1
|
-
"use strict";const
|
|
1
|
+
"use strict";const e=require("react/jsx-runtime"),d=require("react"),a=require("./emotion-styled.browser.esm-BtEseadx.cjs"),l=require("./consts-CtNoHdBj.cjs"),f=require("./index-ryadTWiS.cjs"),v=a.styled.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
flex-direction: column;
|
|
4
4
|
padding: 1.25rem;
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
box-shadow: none;
|
|
20
20
|
border: none;
|
|
21
21
|
}
|
|
22
|
-
`,
|
|
22
|
+
`,b=a.styled.div`
|
|
23
23
|
display: grid;
|
|
24
24
|
grid-template-columns: repeat(4, 1fr);
|
|
25
25
|
gap: 1.5rem;
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
grid-template-columns: repeat(2, 1fr);
|
|
29
29
|
gap: 0.5rem;
|
|
30
30
|
}
|
|
31
|
-
`,
|
|
31
|
+
`,j=a.styled.div`
|
|
32
32
|
display: flex;
|
|
33
33
|
flex-direction: column;
|
|
34
34
|
gap: 0.75rem;
|
|
@@ -57,4 +57,4 @@
|
|
|
57
57
|
color: var(--primary-500, #f59e0b);
|
|
58
58
|
}
|
|
59
59
|
}
|
|
60
|
-
`,
|
|
60
|
+
`,w=d.forwardRef((c,p)=>{const{title:m,items:t,options:o,onSelectRegion:g=()=>{},onSelectCity:x=()=>{},onSelectOption:u=()=>{}}=c;return e.jsxs(v,{ref:p,children:[e.jsx("div",{className:"wrapper-title",children:m}),(o==null?void 0:o.length)>0&&e.jsx(f.SelectBar,{items:o,onRemove:r=>{},onSelect:(r,i)=>{u(r,i)},labelKey:"name",valueKey:"code",noMargin:!0}),e.jsx(b,{children:t==null?void 0:t.map((r,i)=>{var s;return e.jsxs(j,{children:[e.jsx("div",{className:"region",onClick:()=>g(r),children:r==null?void 0:r.name}),e.jsx("div",{className:"group-items",children:(s=r==null?void 0:r.cities)==null?void 0:s.map((n,h)=>e.jsx(d.Fragment,{children:e.jsxs("div",{className:"city",onClick:()=>x(n),children:[e.jsx("span",{children:n==null?void 0:n.name}),e.jsxs("span",{className:"count-txt",children:["(",n==null?void 0:n.count,")"]})]})},i+h))})]},i)})})]})});module.exports=w;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { forwardRef as
|
|
3
|
-
import { s as
|
|
4
|
-
import { M as
|
|
1
|
+
import { jsxs as i, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as v, Fragment as x } from "react";
|
|
3
|
+
import { s as l } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
4
|
+
import { M as p } from "./consts-C1uHV4xc.js";
|
|
5
5
|
import { S as b } from "./index-DXmajb7F.js";
|
|
6
|
-
const w =
|
|
6
|
+
const w = l.div`
|
|
7
7
|
display: flex;
|
|
8
8
|
flex-direction: column;
|
|
9
9
|
padding: 1.25rem;
|
|
@@ -18,22 +18,22 @@ const w = t.div`
|
|
|
18
18
|
font-size: 1rem;
|
|
19
19
|
}
|
|
20
20
|
|
|
21
|
-
@media (max-width: ${
|
|
21
|
+
@media (max-width: ${p + "px"}) {
|
|
22
22
|
padding: 0;
|
|
23
23
|
border-radius: 0;
|
|
24
24
|
box-shadow: none;
|
|
25
25
|
border: none;
|
|
26
26
|
}
|
|
27
|
-
`,
|
|
27
|
+
`, S = l.div`
|
|
28
28
|
display: grid;
|
|
29
29
|
grid-template-columns: repeat(4, 1fr);
|
|
30
30
|
gap: 1.5rem;
|
|
31
31
|
|
|
32
|
-
@media (max-width: ${
|
|
32
|
+
@media (max-width: ${p + "px"}) {
|
|
33
33
|
grid-template-columns: repeat(2, 1fr);
|
|
34
34
|
gap: 0.5rem;
|
|
35
35
|
}
|
|
36
|
-
`,
|
|
36
|
+
`, N = l.div`
|
|
37
37
|
display: flex;
|
|
38
38
|
flex-direction: column;
|
|
39
39
|
gap: 0.75rem;
|
|
@@ -62,17 +62,19 @@ const w = t.div`
|
|
|
62
62
|
color: var(--primary-500, #f59e0b);
|
|
63
63
|
}
|
|
64
64
|
}
|
|
65
|
-
`, R =
|
|
65
|
+
`, R = v((m, s) => {
|
|
66
66
|
const {
|
|
67
67
|
title: c,
|
|
68
|
-
items:
|
|
68
|
+
items: t,
|
|
69
69
|
options: a,
|
|
70
70
|
onSelectRegion: g = () => {
|
|
71
71
|
},
|
|
72
72
|
onSelectCity: f = () => {
|
|
73
|
+
},
|
|
74
|
+
onSelectOption: h = () => {
|
|
73
75
|
}
|
|
74
|
-
} =
|
|
75
|
-
return /* @__PURE__ */
|
|
76
|
+
} = m;
|
|
77
|
+
return /* @__PURE__ */ i(w, { ref: s, children: [
|
|
76
78
|
/* @__PURE__ */ o("div", { className: "wrapper-title", children: c }),
|
|
77
79
|
(a == null ? void 0 : a.length) > 0 && /* @__PURE__ */ o(
|
|
78
80
|
b,
|
|
@@ -80,33 +82,27 @@ const w = t.div`
|
|
|
80
82
|
items: a,
|
|
81
83
|
onRemove: (e) => {
|
|
82
84
|
},
|
|
83
|
-
onSelect: (e) => {
|
|
85
|
+
onSelect: (e, n) => {
|
|
86
|
+
h(e, n);
|
|
84
87
|
},
|
|
85
88
|
labelKey: "name",
|
|
86
89
|
valueKey: "code",
|
|
87
90
|
noMargin: !0
|
|
88
91
|
}
|
|
89
92
|
),
|
|
90
|
-
/* @__PURE__ */ o(
|
|
91
|
-
var
|
|
92
|
-
return /* @__PURE__ */
|
|
93
|
-
/* @__PURE__ */ o("div", { className: "region", onClick: () => g(e
|
|
94
|
-
/* @__PURE__ */ o("div", { className: "group-items", children: (
|
|
95
|
-
"
|
|
96
|
-
{
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
r == null ? void 0 : r.count,
|
|
104
|
-
")"
|
|
105
|
-
] })
|
|
106
|
-
]
|
|
107
|
-
}
|
|
108
|
-
) }, d + h)) })
|
|
109
|
-
] }, d);
|
|
93
|
+
/* @__PURE__ */ o(S, { children: t == null ? void 0 : t.map((e, n) => {
|
|
94
|
+
var d;
|
|
95
|
+
return /* @__PURE__ */ i(N, { children: [
|
|
96
|
+
/* @__PURE__ */ o("div", { className: "region", onClick: () => g(e), children: e == null ? void 0 : e.name }),
|
|
97
|
+
/* @__PURE__ */ o("div", { className: "group-items", children: (d = e == null ? void 0 : e.cities) == null ? void 0 : d.map((r, u) => /* @__PURE__ */ o(x, { children: /* @__PURE__ */ i("div", { className: "city", onClick: () => f(r), children: [
|
|
98
|
+
/* @__PURE__ */ o("span", { children: r == null ? void 0 : r.name }),
|
|
99
|
+
/* @__PURE__ */ i("span", { className: "count-txt", children: [
|
|
100
|
+
"(",
|
|
101
|
+
r == null ? void 0 : r.count,
|
|
102
|
+
")"
|
|
103
|
+
] })
|
|
104
|
+
] }) }, n + u)) })
|
|
105
|
+
] }, n);
|
|
110
106
|
}) })
|
|
111
107
|
] });
|
|
112
108
|
});
|