@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 r=require("react/jsx-runtime"),d=require("react"),s=require("./emotion-styled.browser.esm-BtEseadx.cjs"),l=require("./consts-CtNoHdBj.cjs"),h=require("./index-ryadTWiS.cjs"),f=s.styled.div`
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
- `,v=s.styled.div`
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
- `,b=s.styled.div`
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
- `,j=d.forwardRef((c,p)=>{const{title:m,items:a,options:o,onSelectRegion:g=()=>{},onSelectCity:u=()=>{}}=c;return r.jsxs(f,{ref:p,children:[r.jsx("div",{className:"wrapper-title",children:m}),(o==null?void 0:o.length)>0&&r.jsx(h.SelectBar,{items:o,onRemove:e=>{},onSelect:e=>{},labelKey:"name",valueKey:"code",noMargin:!0}),r.jsx(v,{children:a==null?void 0:a.map((e,i)=>{var t;return r.jsxs(b,{children:[r.jsx("div",{className:"region",onClick:()=>g(e==null?void 0:e.code),children:e==null?void 0:e.name}),r.jsx("div",{className:"group-items",children:(t=e==null?void 0:e.cities)==null?void 0:t.map((n,x)=>r.jsx(d.Fragment,{children:r.jsxs("div",{className:"city",onClick:()=>u(n==null?void 0:n.code),children:[r.jsx("span",{children:n==null?void 0:n.name}),r.jsxs("span",{className:"count-txt",children:["(",n==null?void 0:n.count,")"]})]})},i+x))})]},i)})})]})});module.exports=j;
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 n, jsx as o } from "react/jsx-runtime";
2
- import { forwardRef as u, Fragment as v } from "react";
3
- import { s as t } from "./emotion-styled.browser.esm-BNN1dTl3.js";
4
- import { M as m } from "./consts-C1uHV4xc.js";
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 = t.div`
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: ${m + "px"}) {
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
- `, x = t.div`
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: ${m + "px"}) {
32
+ @media (max-width: ${p + "px"}) {
33
33
  grid-template-columns: repeat(2, 1fr);
34
34
  gap: 0.5rem;
35
35
  }
36
- `, S = t.div`
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 = u((p, s) => {
65
+ `, R = v((m, s) => {
66
66
  const {
67
67
  title: c,
68
- items: i,
68
+ items: t,
69
69
  options: a,
70
70
  onSelectRegion: g = () => {
71
71
  },
72
72
  onSelectCity: f = () => {
73
+ },
74
+ onSelectOption: h = () => {
73
75
  }
74
- } = p;
75
- return /* @__PURE__ */ n(w, { ref: s, children: [
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(x, { children: i == null ? void 0 : i.map((e, d) => {
91
- var l;
92
- return /* @__PURE__ */ n(S, { children: [
93
- /* @__PURE__ */ o("div", { className: "region", onClick: () => g(e == null ? void 0 : e.code), children: e == null ? void 0 : e.name }),
94
- /* @__PURE__ */ o("div", { className: "group-items", children: (l = e == null ? void 0 : e.cities) == null ? void 0 : l.map((r, h) => /* @__PURE__ */ o(v, { children: /* @__PURE__ */ n(
95
- "div",
96
- {
97
- className: "city",
98
- onClick: () => f(r == null ? void 0 : r.code),
99
- children: [
100
- /* @__PURE__ */ o("span", { children: r == null ? void 0 : r.name }),
101
- /* @__PURE__ */ n("span", { className: "count-txt", children: [
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
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lanaco/lnc-react-ui",
3
- "version": "4.0.77",
3
+ "version": "4.0.78",
4
4
  "description": "React component library",
5
5
  "type": "module",
6
6
  "keywords": [