@lanaco/lnc-react-ui 4.0.5 → 4.0.6

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/dist/Chip.cjs CHANGED
@@ -24,4 +24,4 @@
24
24
  &:active {
25
25
  background-color: ${e=>!e.disabled&&n.getColorRgbaValue(e.theme,"Chip",e.color,"active","background","backgroundOpacity")};
26
26
  }
27
- `,B=(e,o)=>`calc(${n.getSizeValueWithUnits(e,o)} - 8px)`,b=V.forwardRef((e,o)=>{const{label:l,leadingIcon:a,trailingIcon:i,avatar:s=!1,size:c="small",borderRadius:h="regular",disabled:d=!1,tabIndex:p=0,onFocus:y=()=>{},onBlur:f=()=>{},onClick:C=()=>{},onKeyDown:$=()=>{},onLeadingIconClick:P=()=>{},onTrailingIconClick:T=()=>{},className:k="",style:I={},color:v="primary",avatarProps:x,children:R,...w}=e,g=q.useTheme(),u={theme:g,color:v,style:I,className:"lnc-ui-chip "+k};return t.jsxs(N,{ref:o,size:c,...u,trailingIcon:i,leadingIcon:a,avatar:s,borderRadius:h,disabled:d,tabIndex:p,onClick:C,onKeyDown:$,onBlur:f,onFocus:y,...w,children:[s&&t.jsx(O,{...u,disabled:d,sizeInUnits:B(g,c),...x}),a&&t.jsx("i",{className:m(a),onClick:P}),t.jsxs(t.Fragment,{children:[l,R]}),i&&t.jsx("i",{className:m(i),onClick:T})]})});b.propTypes={label:r.PropTypes.string,leadingIcon:r.PropTypes.string,trailingIcon:r.PropTypes.string,avatar:r.PropTypes.bool,borderRadius:r.PropTypes.oneOf(["slight","regular","edged","curved","none"]),disabled:r.PropTypes.bool,tabIndex:r.PropTypes.number,onBlur:r.PropTypes.func,onFocus:r.PropTypes.func,onClick:r.PropTypes.func,onKeyDown:r.PropTypes.func,onLeadingIconClick:r.PropTypes.func,onTrailingIconClick:r.PropTypes.func,className:r.PropTypes.string,style:r.PropTypes.object,color:r.PropTypes.oneOf(["primary","secondary","success","warning","danger","information","neutral","gray"]),size:r.PropTypes.oneOf(["small","medium","large"]),avatarProps:r.PropTypes.any};module.exports=b;
27
+ `,B=(e,o)=>`calc(${n.getSizeValueWithUnits(e,o)} - 8px)`,b=V.forwardRef((e,o)=>{const{label:l,leadingIcon:a,trailingIcon:i,avatar:c=!1,size:s="small",borderRadius:h="regular",disabled:d=!1,tabIndex:p=0,onFocus:y=()=>{},onBlur:f=()=>{},onClick:C=()=>{},onKeyDown:$=()=>{},onLeadingIconClick:P=()=>{},onTrailingIconClick:T=()=>{},className:k="",style:I={},color:v="primary",avatarProps:x,children:R,...w}=e,g=q.useTheme(),u={theme:g,color:v,style:I,size:s,className:"lnc-ui-chip "+k};return t.jsxs(N,{ref:o,size:s,...u,trailingIcon:i,leadingIcon:a,avatar:c,borderRadius:h,disabled:d,tabIndex:p,onClick:C,onKeyDown:$,onBlur:f,onFocus:y,...w,children:[c&&t.jsx(O,{...u,disabled:d,sizeInUnits:B(g,s),...x}),a&&t.jsx("i",{className:m(a),onClick:P}),t.jsxs(t.Fragment,{children:[l,R]}),i&&t.jsx("i",{className:m(i),onClick:T})]})});b.propTypes={label:r.PropTypes.string,leadingIcon:r.PropTypes.string,trailingIcon:r.PropTypes.string,avatar:r.PropTypes.bool,borderRadius:r.PropTypes.oneOf(["slight","regular","edged","curved","none"]),disabled:r.PropTypes.bool,tabIndex:r.PropTypes.number,onBlur:r.PropTypes.func,onFocus:r.PropTypes.func,onClick:r.PropTypes.func,onKeyDown:r.PropTypes.func,onLeadingIconClick:r.PropTypes.func,onTrailingIconClick:r.PropTypes.func,className:r.PropTypes.string,style:r.PropTypes.object,color:r.PropTypes.oneOf(["primary","secondary","success","warning","danger","information","neutral","gray"]),size:r.PropTypes.oneOf(["small","medium","large"]),avatarProps:r.PropTypes.any};module.exports=b;
package/dist/Chip.js CHANGED
@@ -1,4 +1,4 @@
1
- import { jsxs as u, jsx as i, Fragment as N } from "react/jsx-runtime";
1
+ import { jsxs as u, jsx as c, Fragment as N } from "react/jsx-runtime";
2
2
  import { forwardRef as S } from "react";
3
3
  import { P as a } from "./index-BYnWp42a.js";
4
4
  import { n as j } from "./emotion-styled.browser.esm-BiK8DcgW.js";
@@ -73,8 +73,8 @@ const h = (e) => {
73
73
  label: l,
74
74
  leadingIcon: r,
75
75
  trailingIcon: o,
76
- avatar: c = !1,
77
- size: d = "small",
76
+ avatar: d = !1,
77
+ size: i = "small",
78
78
  borderRadius: f = "regular",
79
79
  disabled: s = !1,
80
80
  tabIndex: y = 0,
@@ -102,17 +102,18 @@ const h = (e) => {
102
102
  theme: m,
103
103
  color: w,
104
104
  style: O,
105
+ size: i,
105
106
  className: "lnc-ui-chip " + x
106
107
  };
107
108
  return /* @__PURE__ */ u(
108
109
  L,
109
110
  {
110
111
  ref: n,
111
- size: d,
112
+ size: i,
112
113
  ...g,
113
114
  trailingIcon: o,
114
115
  leadingIcon: r,
115
- avatar: c,
116
+ avatar: d,
116
117
  borderRadius: f,
117
118
  disabled: s,
118
119
  tabIndex: y,
@@ -122,21 +123,21 @@ const h = (e) => {
122
123
  onFocus: C,
123
124
  ...T,
124
125
  children: [
125
- c && /* @__PURE__ */ i(
126
+ d && /* @__PURE__ */ c(
126
127
  W,
127
128
  {
128
129
  ...g,
129
130
  disabled: s,
130
- sizeInUnits: z(m, d),
131
+ sizeInUnits: z(m, i),
131
132
  ...P
132
133
  }
133
134
  ),
134
- r && /* @__PURE__ */ i("i", { className: h(r), onClick: I }),
135
+ r && /* @__PURE__ */ c("i", { className: h(r), onClick: I }),
135
136
  /* @__PURE__ */ u(N, { children: [
136
137
  l,
137
138
  R
138
139
  ] }),
139
- o && /* @__PURE__ */ i(
140
+ o && /* @__PURE__ */ c(
140
141
  "i",
141
142
  {
142
143
  className: h(o),
package/dist/MenuItem.cjs CHANGED
@@ -1,4 +1,4 @@
1
- "use strict";const c=require("react/jsx-runtime"),f=require("react"),s=require("./index-BIlhCoy2.cjs"),Y=require("./emotion-styled.browser.esm-Cbp_XsK4.cjs"),M=require("./Icon.cjs"),l=require("./utils-DTAPpJXU.cjs"),G=require("./emotion-element-5486c51c.browser.esm-QRQ5FSjv.cjs"),H=Y.newStyled.div`
1
+ "use strict";const c=require("react/jsx-runtime"),f=require("react"),s=require("./index-BIlhCoy2.cjs"),G=require("./emotion-styled.browser.esm-Cbp_XsK4.cjs"),M=require("./Icon.cjs"),l=require("./utils-DTAPpJXU.cjs"),H=require("./emotion-element-5486c51c.browser.esm-QRQ5FSjv.cjs"),J=G.newStyled.div`
2
2
  box-sizing: border-box;
3
3
  cursor: ${n=>n.disabled==!1?"pointer":"context-menu"};
4
4
  width: 100%;
@@ -33,4 +33,4 @@
33
33
  color: ${l.getColorRgbaValue(n.theme,"MenuItem",n.color,"hover","text")};
34
34
  `}
35
35
  }
36
- `,h=f.forwardRef((n,a)=>{const{value:T,active:r=null,icon:E,disabled:m=!1,isNested:d=!1,showNested:P,justifyToEnd:J=!1,onFocus:N=()=>{},onBlur:k=()=>{},onClick:C=()=>{},onKeyDown:v=()=>{},onMouseEnter:Q=()=>{},onMouseLeave:W=()=>{},toggleNested:u=()=>{},onItemSelected:w=()=>{},className:x="",style:_={},color:$="primary",iconProps:R,__TYPE__:X="MENU_ITEM",children:S,...A}=n,j={theme:G.useTheme(),color:$,style:_},y=f.useRef(),[q,g]=f.useState(r??!1);f.useEffect(()=>{g(r)},[r]);const O=e=>{m==!1&&(d&&u&&u(),w(e,T)),C(C)},D=e=>{g(!0),N(e)},V=e=>{r==null&&g(!1),k(e)},F=e=>{e.preventDefault(),e.key=="ArrowDown"?b(a?a.current:y.current):e.key=="ArrowUp"?p(a?a.current:y.current):(e.key=="Enter"||e.keyCode==32)&&m==!1&&(d&&u&&u(),w(e,T)),v(e)},b=e=>{if(e!=null&&e.nextSibling){let o=B(e);if(o!=null&&o.node&&(o==null?void 0:o.type)=="item")o.node.focus();else if(o!=null&&o.node&&(o==null?void 0:o.type)=="nested"){let i=z(o.node);i&&i.focus()}else e!=null&&e.parentElement&&t(e.parentElement,"nested-item-lnc")&&b(e.parentElement)}else e!=null&&e.parentElement&&t(e.parentElement,"nested-item-lnc")&&b(e.parentElement)},p=e=>{if(e!=null&&e.previousSibling){let o=K(e);if(o!=null&&o.node&&(o==null?void 0:o.type)=="item")o.node.focus();else if(o!=null&&o.node&&(o==null?void 0:o.type)=="nested"){let i=L(o.node);i&&i.focus()}else e!=null&&e.parentElement&&t(e.parentElement,"nested-item-lnc")&&p(e.parentElement)}else e!=null&&e.parentElement&&t(e.parentElement,"nested-item-lnc")&&p(e.parentElement)},B=e=>{for(;e=e.nextSibling;){if(t(e,"menu-item-lnc"))return{node:e,type:"item"};if(t(e,"nested-item-lnc"))return{node:e,type:"nested"}}return null},K=e=>{for(;e=e.previousSibling;){if(t(e,"menu-item-lnc"))return{node:e,type:"item"};if(t(e,"nested-item-lnc"))return{node:e,type:"nested"}}return null},z=e=>{var o;return(o=Array.from(e.querySelectorAll(".menu-item-lnc")))==null?void 0:o[0]},L=e=>{var o;return(o=Array.from(e.querySelectorAll(".menu-item-lnc")))==null?void 0:o.pop()},t=(e,o)=>{var i=" "+e.className+" ",U=" "+o+" ";return i.indexOf(U)!=-1};return c.jsx(c.Fragment,{children:c.jsxs(H,{ref:a||y,className:"menu-item-lnc "+(d?"nested-menu-item-lnc ":"")+(P?"spread-nested-item-lnc ":"")+x,...j,disabled:m,tabIndex:0,onKeyDown:F,onFocus:D,onBlur:V,onClick:O,isActive:q,showNested:P,...A,children:[E&&c.jsx(M,{icon:E,className:"menu-icon-lnc",...R}),c.jsx("div",{children:S}),d&&c.jsx(M,{icon:"angle-down",className:"sub-menu-icon-lnc"})]})})});h.propTypes={value:s.PropTypes.any,active:s.PropTypes.bool,icon:s.PropTypes.string,disabled:s.PropTypes.bool,isNested:s.PropTypes.bool,justifyToEnd:s.PropTypes.bool,onBlur:s.PropTypes.func,onFocus:s.PropTypes.func,onClick:s.PropTypes.func,onKeyDown:s.PropTypes.func,onMouseEnter:s.PropTypes.func,onMouseLeave:s.PropTypes.func,className:s.PropTypes.string,style:s.PropTypes.object,color:s.PropTypes.oneOf(["primary","secondary","success","warning","danger","information","neutral","gray"]),iconProps:s.PropTypes.any,size:s.PropTypes.oneOf(["small","medium","large"]),__TYPE__:s.PropTypes.string};h.displayName="MENU_ITEM";module.exports=h;
36
+ `,h=f.forwardRef((n,a)=>{const{value:T,active:r=null,icon:E,disabled:m=!1,isNested:d=!1,showNested:P,justifyToEnd:Q=!1,onFocus:N=()=>{},onBlur:k=()=>{},onClick:C=()=>{},onKeyDown:v=()=>{},onMouseEnter:W=()=>{},onMouseLeave:X=()=>{},toggleNested:u=()=>{},onItemSelected:w=()=>{},className:x="",style:_={},color:$="primary",size:R="small",iconProps:S,__TYPE__:Z="MENU_ITEM",children:A,...j}=n,q={theme:H.useTheme(),color:$,style:_,size:R},y=f.useRef(),[O,g]=f.useState(r??!1);f.useEffect(()=>{g(r)},[r]);const D=e=>{m==!1&&(d&&u&&u(),w(e,T)),C(C)},V=e=>{g(!0),N(e)},F=e=>{r==null&&g(!1),k(e)},z=e=>{e.preventDefault(),e.key=="ArrowDown"?b(a?a.current:y.current):e.key=="ArrowUp"?p(a?a.current:y.current):(e.key=="Enter"||e.keyCode==32)&&m==!1&&(d&&u&&u(),w(e,T)),v(e)},b=e=>{if(e!=null&&e.nextSibling){let o=B(e);if(o!=null&&o.node&&(o==null?void 0:o.type)=="item")o.node.focus();else if(o!=null&&o.node&&(o==null?void 0:o.type)=="nested"){let i=L(o.node);i&&i.focus()}else e!=null&&e.parentElement&&t(e.parentElement,"nested-item-lnc")&&b(e.parentElement)}else e!=null&&e.parentElement&&t(e.parentElement,"nested-item-lnc")&&b(e.parentElement)},p=e=>{if(e!=null&&e.previousSibling){let o=K(e);if(o!=null&&o.node&&(o==null?void 0:o.type)=="item")o.node.focus();else if(o!=null&&o.node&&(o==null?void 0:o.type)=="nested"){let i=U(o.node);i&&i.focus()}else e!=null&&e.parentElement&&t(e.parentElement,"nested-item-lnc")&&p(e.parentElement)}else e!=null&&e.parentElement&&t(e.parentElement,"nested-item-lnc")&&p(e.parentElement)},B=e=>{for(;e=e.nextSibling;){if(t(e,"menu-item-lnc"))return{node:e,type:"item"};if(t(e,"nested-item-lnc"))return{node:e,type:"nested"}}return null},K=e=>{for(;e=e.previousSibling;){if(t(e,"menu-item-lnc"))return{node:e,type:"item"};if(t(e,"nested-item-lnc"))return{node:e,type:"nested"}}return null},L=e=>{var o;return(o=Array.from(e.querySelectorAll(".menu-item-lnc")))==null?void 0:o[0]},U=e=>{var o;return(o=Array.from(e.querySelectorAll(".menu-item-lnc")))==null?void 0:o.pop()},t=(e,o)=>{var i=" "+e.className+" ",Y=" "+o+" ";return i.indexOf(Y)!=-1};return c.jsx(c.Fragment,{children:c.jsxs(J,{ref:a||y,className:"menu-item-lnc "+(d?"nested-menu-item-lnc ":"")+(P?"spread-nested-item-lnc ":"")+x,...q,disabled:m,tabIndex:0,onKeyDown:z,onFocus:V,onBlur:F,onClick:D,isActive:O,showNested:P,...j,children:[E&&c.jsx(M,{icon:E,className:"menu-icon-lnc",...S}),c.jsx("div",{children:A}),d&&c.jsx(M,{icon:"angle-down",className:"sub-menu-icon-lnc"})]})})});h.propTypes={value:s.PropTypes.any,active:s.PropTypes.bool,icon:s.PropTypes.string,disabled:s.PropTypes.bool,isNested:s.PropTypes.bool,justifyToEnd:s.PropTypes.bool,onBlur:s.PropTypes.func,onFocus:s.PropTypes.func,onClick:s.PropTypes.func,onKeyDown:s.PropTypes.func,onMouseEnter:s.PropTypes.func,onMouseLeave:s.PropTypes.func,className:s.PropTypes.string,style:s.PropTypes.object,color:s.PropTypes.oneOf(["primary","secondary","success","warning","danger","information","neutral","gray"]),iconProps:s.PropTypes.any,size:s.PropTypes.oneOf(["small","medium","large"]),__TYPE__:s.PropTypes.string};h.displayName="MENU_ITEM";module.exports=h;
package/dist/MenuItem.js CHANGED
@@ -1,11 +1,11 @@
1
- import { jsx as m, Fragment as V, jsxs as G } from "react/jsx-runtime";
2
- import { forwardRef as H, useRef as J, useState as Q, useEffect as W } from "react";
1
+ import { jsx as m, Fragment as G, jsxs as H } from "react/jsx-runtime";
2
+ import { forwardRef as J, useRef as Q, useState as W, useEffect as X } from "react";
3
3
  import { P as o } from "./index-BYnWp42a.js";
4
- import { n as X } from "./emotion-styled.browser.esm-BiK8DcgW.js";
4
+ import { n as Z } from "./emotion-styled.browser.esm-BiK8DcgW.js";
5
5
  import k from "./Icon.js";
6
- import { a as i, g as Z, h as v } from "./utils-C52T57HO.js";
7
- import { u as I } from "./emotion-element-5486c51c.browser.esm-Bb4VkP8U.js";
8
- const ee = X.div`
6
+ import { a as i, g as I, h as v } from "./utils-C52T57HO.js";
7
+ import { u as ee } from "./emotion-element-5486c51c.browser.esm-Bb4VkP8U.js";
8
+ const ne = Z.div`
9
9
  box-sizing: border-box;
10
10
  cursor: ${(n) => n.disabled == !1 ? "pointer" : "context-menu"};
11
11
  width: 100%;
@@ -16,7 +16,7 @@ const ee = X.div`
16
16
  gap: 0.563rem;
17
17
  padding: 0.563rem;
18
18
  color: ${(n) => i(n.theme, "MenuItem", n.color, "enabled", "text")};
19
- ${(n) => Z(n.theme, "MenuItem", n.size, "enabled")};
19
+ ${(n) => I(n.theme, "MenuItem", n.size, "enabled")};
20
20
  & .menu-icon-lnc {
21
21
  color: ${(n) => n.isActive && n.disabled == !1 ? i(
22
22
  n.theme,
@@ -78,7 +78,7 @@ const ee = X.div`
78
78
  )};
79
79
  `}
80
80
  }
81
- `, C = H((n, a) => {
81
+ `, C = J((n, a) => {
82
82
  const {
83
83
  value: g,
84
84
  active: c = null,
@@ -86,7 +86,7 @@ const ee = X.div`
86
86
  disabled: r = !1,
87
87
  isNested: d = !1,
88
88
  showNested: M,
89
- justifyToEnd: ne = !1,
89
+ justifyToEnd: le = !1,
90
90
  //----------------
91
91
  onFocus: p = () => {
92
92
  },
@@ -96,9 +96,9 @@ const ee = X.div`
96
96
  },
97
97
  onKeyDown: x = () => {
98
98
  },
99
- onMouseEnter: le = () => {
99
+ onMouseEnter: oe = () => {
100
100
  },
101
- onMouseLeave: oe = () => {
101
+ onMouseLeave: se = () => {
102
102
  },
103
103
  toggleNested: f = () => {
104
104
  },
@@ -108,15 +108,16 @@ const ee = X.div`
108
108
  className: A = "",
109
109
  style: S = {},
110
110
  color: T = "primary",
111
- iconProps: _,
112
- __TYPE__: se = "MENU_ITEM",
113
- children: O,
114
- ...P
115
- } = n, D = { theme: I(), color: T, style: S }, u = J(), [F, y] = Q(c ?? !1);
116
- W(() => {
111
+ size: _ = "small",
112
+ iconProps: O,
113
+ __TYPE__: te = "MENU_ITEM",
114
+ children: P,
115
+ ...D
116
+ } = n, F = { theme: ee(), color: T, style: S, size: _ }, u = Q(), [j, y] = W(c ?? !1);
117
+ X(() => {
117
118
  y(c);
118
119
  }, [c]);
119
- const j = (e) => {
120
+ const z = (e) => {
120
121
  r == !1 && (d && f && f(), N(e, g)), w(w);
121
122
  }, B = (e) => {
122
123
  y(!0), p(e);
@@ -126,25 +127,25 @@ const ee = X.div`
126
127
  e.preventDefault(), e.key == "ArrowDown" ? h(a ? a.current : u.current) : e.key == "ArrowUp" ? b(a ? a.current : u.current) : (e.key == "Enter" || e.keyCode == 32) && r == !1 && (d && f && f(), N(e, g)), x(e);
127
128
  }, h = (e) => {
128
129
  if (e != null && e.nextSibling) {
129
- let l = z(e);
130
+ let l = L(e);
130
131
  if (l != null && l.node && (l == null ? void 0 : l.type) == "item")
131
132
  l.node.focus();
132
133
  else if (l != null && l.node && (l == null ? void 0 : l.type) == "nested") {
133
- let t = U(l.node);
134
+ let t = q(l.node);
134
135
  t && t.focus();
135
136
  } else e != null && e.parentElement && s(e.parentElement, "nested-item-lnc") && h(e.parentElement);
136
137
  } else e != null && e.parentElement && s(e.parentElement, "nested-item-lnc") && h(e.parentElement);
137
138
  }, b = (e) => {
138
139
  if (e != null && e.previousSibling) {
139
- let l = L(e);
140
+ let l = U(e);
140
141
  if (l != null && l.node && (l == null ? void 0 : l.type) == "item")
141
142
  l.node.focus();
142
143
  else if (l != null && l.node && (l == null ? void 0 : l.type) == "nested") {
143
- let t = q(l.node);
144
+ let t = Y(l.node);
144
145
  t && t.focus();
145
146
  } else e != null && e.parentElement && s(e.parentElement, "nested-item-lnc") && b(e.parentElement);
146
147
  } else e != null && e.parentElement && s(e.parentElement, "nested-item-lnc") && b(e.parentElement);
147
- }, z = (e) => {
148
+ }, L = (e) => {
148
149
  for (; e = e.nextSibling; ) {
149
150
  if (s(e, "menu-item-lnc"))
150
151
  return { node: e, type: "item" };
@@ -152,7 +153,7 @@ const ee = X.div`
152
153
  return { node: e, type: "nested" };
153
154
  }
154
155
  return null;
155
- }, L = (e) => {
156
+ }, U = (e) => {
156
157
  for (; e = e.previousSibling; ) {
157
158
  if (s(e, "menu-item-lnc"))
158
159
  return { node: e, type: "item" };
@@ -160,34 +161,34 @@ const ee = X.div`
160
161
  return { node: e, type: "nested" };
161
162
  }
162
163
  return null;
163
- }, U = (e) => {
164
+ }, q = (e) => {
164
165
  var l;
165
166
  return (l = Array.from(e.querySelectorAll(".menu-item-lnc"))) == null ? void 0 : l[0];
166
- }, q = (e) => {
167
+ }, Y = (e) => {
167
168
  var l;
168
169
  return (l = Array.from(e.querySelectorAll(".menu-item-lnc"))) == null ? void 0 : l.pop();
169
170
  }, s = (e, l) => {
170
- var t = " " + e.className + " ", Y = " " + l + " ";
171
- return t.indexOf(Y) != -1;
171
+ var t = " " + e.className + " ", V = " " + l + " ";
172
+ return t.indexOf(V) != -1;
172
173
  };
173
- return /* @__PURE__ */ m(V, { children: /* @__PURE__ */ G(
174
- ee,
174
+ return /* @__PURE__ */ m(G, { children: /* @__PURE__ */ H(
175
+ ne,
175
176
  {
176
177
  ref: a || u,
177
178
  className: "menu-item-lnc " + (d ? "nested-menu-item-lnc " : "") + (M ? "spread-nested-item-lnc " : "") + A,
178
- ...D,
179
+ ...F,
179
180
  disabled: r,
180
181
  tabIndex: 0,
181
182
  onKeyDown: R,
182
183
  onFocus: B,
183
184
  onBlur: K,
184
- onClick: j,
185
- isActive: F,
185
+ onClick: z,
186
+ isActive: j,
186
187
  showNested: M,
187
- ...P,
188
+ ...D,
188
189
  children: [
189
- E && /* @__PURE__ */ m(k, { icon: E, className: "menu-icon-lnc", ..._ }),
190
- /* @__PURE__ */ m("div", { children: O }),
190
+ E && /* @__PURE__ */ m(k, { icon: E, className: "menu-icon-lnc", ...O }),
191
+ /* @__PURE__ */ m("div", { children: P }),
191
192
  d && /* @__PURE__ */ m(k, { icon: "angle-down", className: "sub-menu-icon-lnc" })
192
193
  ]
193
194
  }
@@ -1,4 +1,4 @@
1
- "use strict";const s=require("react/jsx-runtime"),C=require("react"),o=require("./index-BIlhCoy2.cjs"),N=require("./emotion-styled.browser.esm-Cbp_XsK4.cjs"),_=require("./react-toastify.esm-Dqcb4SQT.cjs");;/* empty css */const t=require("./utils-DTAPpJXU.cjs"),R=require("./ThemeProvider.cjs"),v=N.newStyled.div`
1
+ "use strict";const s=require("react/jsx-runtime"),N=require("react"),o=require("./index-BIlhCoy2.cjs"),_=require("./emotion-styled.browser.esm-Cbp_XsK4.cjs"),R=require("./react-toastify.esm-Dqcb4SQT.cjs");;/* empty css */const t=require("./utils-DTAPpJXU.cjs"),v=require("./ThemeProvider.cjs"),O=_.newStyled.div`
2
2
  & .lnc-notification {
3
3
  & > div {
4
4
  background-color: ${e=>t.getColorRgbaValue(e.theme,"Notification",e.color,"enabled","background","backgroundOpacity")};
@@ -34,4 +34,4 @@
34
34
  }
35
35
  }
36
36
  }
37
- `,r=C.forwardRef((e,i)=>{const{position:a="top-right",autoClose:n=5e5,hideProgressBar:l=!0,newestOnTop:c=!0,closeOnClick:p=!0,rtl:u=!1,pauseOnFocusLoss:b=!1,draggable:g=!1,pauseOnHover:d=!1,closeButton:f=!0,className:y="",style:m={},toastContainerProps:T,children:O,...h}=e,{theme:P}=R.useTheme(),x={theme:P,className:"lnc-ui-notification "+y,style:m};return s.jsx(v,{ref:i,...x,...h,children:s.jsx(_.ToastContainer,{position:a,autoClose:n,hideProgressBar:l,newestOnTop:c,closeOnClick:p,rtl:u,pauseOnFocusLoss:b,draggable:g,pauseOnHover:d,closeButton:f,className:"lnc-notification",...T})})});r.propTypes={position:o.PropTypes.oneOf(["top-right","top-center","top-left","bottom-right","bottom-center","bottom-left"]),autoClose:o.PropTypes.number,hideProgressBar:o.PropTypes.bool,newestOnTop:o.PropTypes.bool,closeOnClick:o.PropTypes.bool,rtl:o.PropTypes.bool,pauseOnFocusLoss:o.PropTypes.bool,draggable:o.PropTypes.bool,pauseOnHover:o.PropTypes.bool,closeButton:o.PropTypes.bool,className:o.PropTypes.string,style:o.PropTypes.object,toastContainerProps:o.PropTypes.any};module.exports=r;
37
+ `,r=N.forwardRef((e,i)=>{const{position:a="top-right",autoClose:n=5e5,hideProgressBar:l=!0,newestOnTop:c=!0,closeOnClick:p=!0,rtl:u=!1,pauseOnFocusLoss:b=!1,draggable:g=!1,pauseOnHover:f=!1,closeButton:d=!0,className:m="",style:y={},size:T="small",toastContainerProps:h,...P}=e,{theme:x}=v.useTheme(),C={theme:x,className:"lnc-ui-notification "+m,style:y,size:T};return s.jsx(O,{ref:i,...C,...P,children:s.jsx(R.ToastContainer,{position:a,autoClose:n,hideProgressBar:l,newestOnTop:c,closeOnClick:p,rtl:u,pauseOnFocusLoss:b,draggable:g,pauseOnHover:f,closeButton:d,className:"lnc-notification",...h})})});r.propTypes={position:o.PropTypes.oneOf(["top-right","top-center","top-left","bottom-right","bottom-center","bottom-left"]),autoClose:o.PropTypes.number,hideProgressBar:o.PropTypes.bool,newestOnTop:o.PropTypes.bool,closeOnClick:o.PropTypes.bool,rtl:o.PropTypes.bool,pauseOnFocusLoss:o.PropTypes.bool,draggable:o.PropTypes.bool,pauseOnHover:o.PropTypes.bool,closeButton:o.PropTypes.bool,className:o.PropTypes.string,style:o.PropTypes.object,toastContainerProps:o.PropTypes.any};module.exports=r;
@@ -1,12 +1,12 @@
1
1
  import { jsx as i } from "react/jsx-runtime";
2
- import { forwardRef as T } from "react";
2
+ import { forwardRef as O } from "react";
3
3
  import { P as t } from "./index-BYnWp42a.js";
4
- import { n as O } from "./emotion-styled.browser.esm-BiK8DcgW.js";
5
- import { T as _ } from "./react-toastify.esm-CkXGwKXL.js";
4
+ import { n as _ } from "./emotion-styled.browser.esm-BiK8DcgW.js";
5
+ import { T as v } from "./react-toastify.esm-CkXGwKXL.js";
6
6
  /* empty css */
7
- import { a as e, b as v } from "./utils-C52T57HO.js";
8
- import { useTheme as C } from "./ThemeProvider.js";
9
- const $ = O.div`
7
+ import { a as e, b as C } from "./utils-C52T57HO.js";
8
+ import { useTheme as $ } from "./ThemeProvider.js";
9
+ const P = _.div`
10
10
  & .lnc-notification {
11
11
  & > div {
12
12
  background-color: ${(o) => e(
@@ -27,7 +27,7 @@ const $ = O.div`
27
27
  "enabled",
28
28
  "border"
29
29
  )}`};
30
- border-radius: ${(o) => v(o.theme, "regular")};
30
+ border-radius: ${(o) => C(o.theme, "regular")};
31
31
  }
32
32
  & .Toastify__close-button {
33
33
  & svg {
@@ -85,7 +85,7 @@ const $ = O.div`
85
85
  }
86
86
  }
87
87
  }
88
- `, P = T((o, a) => {
88
+ `, w = O((o, a) => {
89
89
  const {
90
90
  position: s = "top-right",
91
91
  autoClose: n = 5e5,
@@ -93,22 +93,23 @@ const $ = O.div`
93
93
  newestOnTop: l = !0,
94
94
  closeOnClick: c = !0,
95
95
  rtl: f = !1,
96
- pauseOnFocusLoss: p = !1,
97
- draggable: m = !1,
96
+ pauseOnFocusLoss: m = !1,
97
+ draggable: p = !1,
98
98
  pauseOnHover: b = !1,
99
99
  closeButton: d = !0,
100
100
  className: u = "",
101
101
  style: g = {},
102
- toastContainerProps: h,
103
- children: w,
104
- ...y
105
- } = o, { theme: N } = C(), x = {
106
- theme: N,
102
+ size: h = "small",
103
+ toastContainerProps: y,
104
+ ...N
105
+ } = o, { theme: x } = $(), T = {
106
+ theme: x,
107
107
  className: "lnc-ui-notification " + u,
108
- style: g
108
+ style: g,
109
+ size: h
109
110
  };
110
- return /* @__PURE__ */ i($, { ref: a, ...x, ...y, children: /* @__PURE__ */ i(
111
- _,
111
+ return /* @__PURE__ */ i(P, { ref: a, ...T, ...N, children: /* @__PURE__ */ i(
112
+ v,
112
113
  {
113
114
  position: s,
114
115
  autoClose: n,
@@ -116,16 +117,16 @@ const $ = O.div`
116
117
  newestOnTop: l,
117
118
  closeOnClick: c,
118
119
  rtl: f,
119
- pauseOnFocusLoss: p,
120
- draggable: m,
120
+ pauseOnFocusLoss: m,
121
+ draggable: p,
121
122
  pauseOnHover: b,
122
123
  closeButton: d,
123
124
  className: "lnc-notification",
124
- ...h
125
+ ...y
125
126
  }
126
127
  ) });
127
128
  });
128
- P.propTypes = {
129
+ w.propTypes = {
129
130
  position: t.oneOf([
130
131
  "top-right",
131
132
  "top-center",
@@ -158,5 +159,5 @@ P.propTypes = {
158
159
  toastContainerProps: t.any
159
160
  };
160
161
  export {
161
- P as default
162
+ w as default
162
163
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lanaco/lnc-react-ui",
3
- "version": "4.0.5",
3
+ "version": "4.0.6",
4
4
  "description": "React component library",
5
5
  "type": "module",
6
6
  "keywords": [