@lanaco/lnc-react-ui 4.0.94 → 4.0.96
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/DecimalInput.cjs +1 -1
- package/dist/DecimalInput.js +1 -1
- package/dist/DecimalInputV2.cjs +1 -1
- package/dist/DecimalInputV2.js +20 -20
- package/dist/DetailedProductsSection.cjs +4 -4
- package/dist/DetailedProductsSection.js +16 -14
- package/dist/DragAndDropFile.cjs +1 -1
- package/dist/DragAndDropFile.js +1 -1
- package/dist/Dropdown.cjs +1 -1
- package/dist/Dropdown.js +18 -18
- package/dist/DropdownLookup.cjs +1 -1
- package/dist/DropdownLookup.js +14 -14
- package/dist/Icon.cjs +1 -1
- package/dist/Icon.js +8 -8
- package/dist/MultiSelectDropdown.cjs +1 -1
- package/dist/MultiSelectDropdown.js +6 -6
- package/dist/MultiSelectDropdownLookup.cjs +1 -1
- package/dist/MultiSelectDropdownLookup.js +6 -6
- package/dist/NumberInput.cjs +4 -4
- package/dist/NumberInput.js +80 -80
- package/dist/PasswordInput.cjs +1 -1
- package/dist/PasswordInput.js +1 -1
- package/dist/ProgressBar.cjs +1 -1
- package/dist/ProgressBar.js +1 -1
- package/dist/RadioGroup.cjs +3 -3
- package/dist/RadioGroup.js +22 -22
- package/dist/RadioInput.cjs +1 -1
- package/dist/RadioInput.js +13 -13
- package/dist/Table.cjs +1 -1
- package/dist/Table.js +1 -1
- package/dist/TextAreaInput.cjs +1 -1
- package/dist/TextAreaInput.js +1 -1
- package/dist/TextInput.cjs +4 -4
- package/dist/TextInput.js +71 -71
- package/dist/TimeInput.cjs +1 -1
- package/dist/TimeInput.js +1 -1
- package/dist/UrgentSaleProductsSection.cjs +1 -1
- package/dist/UrgentSaleProductsSection.js +1 -1
- package/dist/{suspense-product-card-detailed-Z0emIstD.js → suspense-product-card-detailed-Bez9UFMR.js} +61 -49
- package/dist/suspense-product-card-detailed-Yjo62f1v.cjs +124 -0
- package/package.json +1 -1
- package/dist/suspense-product-card-detailed-EXZJLtNh.cjs +0 -114
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as g } from "react/jsx-runtime";
|
|
2
2
|
import { P as e } from "./index-S5Cd7WrG.js";
|
|
3
3
|
import { forwardRef as y, useCallback as h } from "react";
|
|
4
4
|
import { a as M } from "./CustomStyles-9CHBrzIM.js";
|
|
@@ -64,11 +64,11 @@ const w = y((l, t) => {
|
|
|
64
64
|
// children,
|
|
65
65
|
...p
|
|
66
66
|
} = l, b = I(), f = h(
|
|
67
|
-
S((d,
|
|
68
|
-
o == null || o(d,
|
|
67
|
+
S((d, O) => {
|
|
68
|
+
o == null || o(d, O);
|
|
69
69
|
}, s)
|
|
70
70
|
);
|
|
71
|
-
return /* @__PURE__ */
|
|
71
|
+
return /* @__PURE__ */ g(
|
|
72
72
|
C,
|
|
73
73
|
{
|
|
74
74
|
isMulti: !0,
|
|
@@ -155,11 +155,11 @@ w.propTypes = {
|
|
|
155
155
|
/**
|
|
156
156
|
* The id to set on the SelectContainer component
|
|
157
157
|
*/
|
|
158
|
-
id: e.
|
|
158
|
+
id: e.any,
|
|
159
159
|
/**
|
|
160
160
|
* The id of the search input
|
|
161
161
|
*/
|
|
162
|
-
|
|
162
|
+
inputid: e.any,
|
|
163
163
|
/**
|
|
164
164
|
* Override the built-in logic to detect whether an option is disabled. `(...) => boolean`
|
|
165
165
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const O=require("react/jsx-runtime"),e=require("./index-BPVoEhTF.cjs"),s=require("react"),g=require("./CustomStyles-BoYYyJVV.cjs"),h=require("./index-DaiUAQVF.cjs"),M=require("./DropdownLookup.cjs"),S=require("./emotion-element-f0de968e.browser.esm-B7k6i6lC.cjs"),r=s.forwardRef((n,
|
|
1
|
+
"use strict";const O=require("react/jsx-runtime"),e=require("./index-BPVoEhTF.cjs"),s=require("react"),g=require("./CustomStyles-BoYYyJVV.cjs"),h=require("./index-DaiUAQVF.cjs"),M=require("./DropdownLookup.cjs"),S=require("./emotion-element-f0de968e.browser.esm-B7k6i6lC.cjs"),r=s.forwardRef((n,l)=>{const{styles:p,debounceTime:t=0,isSearchable:u=!0,isClearable:y=!0,onInputChange:o,size:a="small",color:i="primary",className:c="",style:T={},...P}=n,b=S.useTheme(),m=s.useCallback(h.debounce((d,f)=>{o==null||o(d,f)},t));return O.jsx(M,{isMulti:!0,ref:l,styles:p||g.customStyles,size:a,color:i,theme:b,isSearchable:u,isClearable:y,onInputChange:m,className:c,style:T,...P})});r.propTypes={defaultOptions:e.PropTypes.oneOfType([e.PropTypes.bool,e.PropTypes.array]),cacheOptions:e.PropTypes.any,loadOptions:e.PropTypes.func,styles:e.PropTypes.object,debounceTime:e.PropTypes.number,name:e.PropTypes.string,value:e.PropTypes.any,tabIndex:e.PropTypes.number,isSearchable:e.PropTypes.bool,isClearable:e.PropTypes.bool,isLoading:e.PropTypes.bool,isRtl:e.PropTypes.bool,isDisabled:e.PropTypes.bool,readOnly:e.PropTypes.bool,closeMenuOnSelect:e.PropTypes.bool,closeMenuOnScroll:e.PropTypes.oneOfType([e.PropTypes.bool,e.PropTypes.func]),escapeClearsValue:e.PropTypes.bool,filterOption:e.PropTypes.func,formatGroupLabel:e.PropTypes.func,formatOptionLabel:e.PropTypes.func,getOptionLabel:e.PropTypes.func,getOptionValue:e.PropTypes.func,hideSelectedOptions:e.PropTypes.bool,id:e.PropTypes.any,inputid:e.PropTypes.any,isOptionDisabled:e.PropTypes.func,isOptionSelected:e.PropTypes.func,loadingMessage:e.PropTypes.func,minMenuHeight:e.PropTypes.number,maxMenuHeight:e.PropTypes.number,menuPlacement:e.PropTypes.oneOf(["bottom","auto","top"]),menuPosition:e.PropTypes.oneOf(["absolute","fixed"]),menuShouldBlockScroll:e.PropTypes.bool,menuShouldScrollIntoView:e.PropTypes.bool,openMenuOnFocus:e.PropTypes.bool,openMenuOnClick:e.PropTypes.bool,autoFocus:e.PropTypes.bool,placeholder:e.PropTypes.any,noOptionsMessage:e.PropTypes.string,menuIsOpen:e.PropTypes.bool,components:e.PropTypes.object,defaultValue:e.PropTypes.string,defaultInputValue:e.PropTypes.string,defaultMenuIsOpen:e.PropTypes.bool,delimiter:e.PropTypes.string,onChange:e.PropTypes.func,onInputChange:e.PropTypes.func,onMenuOpen:e.PropTypes.func,onMenuClose:e.PropTypes.func,onFocus:e.PropTypes.func,onBlur:e.PropTypes.func,onKeyDown:e.PropTypes.func,className:e.PropTypes.string,style:e.PropTypes.object,color:e.PropTypes.oneOf(["primary","secondary","success","warning","danger","information","neutral","gray"]),size:e.PropTypes.oneOf(["small","medium","large"])};module.exports=r;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { jsx as
|
|
1
|
+
import { jsx as y } from "react/jsx-runtime";
|
|
2
2
|
import { P as e } from "./index-S5Cd7WrG.js";
|
|
3
|
-
import { forwardRef as
|
|
3
|
+
import { forwardRef as g, useCallback as h } from "react";
|
|
4
4
|
import { a as M } from "./CustomStyles-9CHBrzIM.js";
|
|
5
5
|
import { d as S } from "./index-CkWvbrVT.js";
|
|
6
6
|
import C from "./DropdownLookup.js";
|
|
7
7
|
import { u as I } from "./emotion-element-f0de968e.browser.esm-CkCiQliQ.js";
|
|
8
|
-
const T =
|
|
8
|
+
const T = g((l, t) => {
|
|
9
9
|
const {
|
|
10
10
|
// defaultOptions,
|
|
11
11
|
// cacheOptions,
|
|
@@ -70,7 +70,7 @@ const T = y((l, t) => {
|
|
|
70
70
|
o == null || o(d, O);
|
|
71
71
|
}, s)
|
|
72
72
|
);
|
|
73
|
-
return /* @__PURE__ */
|
|
73
|
+
return /* @__PURE__ */ y(
|
|
74
74
|
C,
|
|
75
75
|
{
|
|
76
76
|
isMulti: !0,
|
|
@@ -168,11 +168,11 @@ T.propTypes = {
|
|
|
168
168
|
/**
|
|
169
169
|
* The id to set on the SelectContainer component
|
|
170
170
|
*/
|
|
171
|
-
id: e.
|
|
171
|
+
id: e.any,
|
|
172
172
|
/**
|
|
173
173
|
* The id of the search input
|
|
174
174
|
*/
|
|
175
|
-
|
|
175
|
+
inputid: e.any,
|
|
176
176
|
/**
|
|
177
177
|
* Override the built-in logic to detect whether an option is disabled. `(...) => boolean`
|
|
178
178
|
*/
|
package/dist/NumberInput.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const
|
|
1
|
+
"use strict";const d=require("react/jsx-runtime"),t=require("./index-BPVoEhTF.cjs"),s=require("react"),A=require("./index-DaiUAQVF.cjs"),c=require("./emotion-styled.browser.esm-BtEseadx.cjs"),r=require("./utils-BOtq2mcF.cjs"),B=require("./emotion-element-f0de968e.browser.esm-B7k6i6lC.cjs"),D=c.styled.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
align-items: center;
|
|
4
4
|
|
|
@@ -11,10 +11,10 @@
|
|
|
11
11
|
|
|
12
12
|
${e=>e.focused&&e.readOnly!==!0?r.getOutlineCss(e.theme):""}
|
|
13
13
|
${e=>e.disabled===!0?r.getDisabledStateCss(e.theme):""}
|
|
14
|
-
|
|
14
|
+
`,C=c.styled.span`
|
|
15
15
|
padding: 0 12px;
|
|
16
16
|
color: ${e=>r.getColorRgbaValue(e.theme,"Input",e.focused===!0?"primary":e.color,"enabled","prefix")};
|
|
17
|
-
`,
|
|
17
|
+
`,G=c.styled(C)``,M=c.styled.input`
|
|
18
18
|
background: none;
|
|
19
19
|
border: none;
|
|
20
20
|
outline: none;
|
|
@@ -42,4 +42,4 @@
|
|
|
42
42
|
${e=>r.getDisabledStateCss(e.theme)}
|
|
43
43
|
background: none;
|
|
44
44
|
}
|
|
45
|
-
`,
|
|
45
|
+
`,S=s.forwardRef((e,I)=>{const{disabled:f,readOnly:T,debounceTime:R=0,step:z=1,min:N=Number.MIN_SAFE_INTEGER,max:O=Number.MAX_SAFE_INTEGER,prefix:m,suffix:p,placeholder:E,value:o,defaultValue:x,onChange:a,onBlur:y,onFocus:g,className:_="",style:q={},size:P="small",color:l="primary",...v}=e,u=B.useTheme(),i=s.useRef(o||x||""),[j,$]=s.useState(o||x||""),[b,V]=s.useState(!1);s.useEffect(()=>{o!=null&&(i.current=o,$(i.current))},[o]);const F=s.useCallback(A.debounce((n,h)=>W(n,h),R),[a]),W=(n,h)=>{a&&(a==null||a(n,h))},k=n=>{i.current=n.target.value,$(i.current),F(n,n.target.value)},w=n=>{V(!0),g==null||g(n)},U=n=>{V(!1),y==null||y(n)};return d.jsxs(D,{style:q,className:_,theme:u,color:l,size:P,focused:b,disabled:f,readOnly:T,children:[m&&d.jsx(C,{theme:u,color:l,focused:b,className:"lnc-input-prefix",children:m}),d.jsx(M,{ref:I,type:"number",theme:u,color:l,size:P,placeholder:E,prefix:m,suffix:p,disabled:f,readOnly:T,step:z,min:N,max:O,value:j,onFocus:w,onBlur:U,onChange:k,...v}),p&&d.jsx(G,{theme:u,color:l,focused:b,className:"lnc-input-suffix",children:p})]})});S.propTypes={id:t.PropTypes.any,value:t.PropTypes.any,defaultValue:t.PropTypes.any,disabled:t.PropTypes.bool,readOnly:t.PropTypes.bool,debounceTime:t.PropTypes.number,step:t.PropTypes.number,min:t.PropTypes.number,max:t.PropTypes.number,prefix:t.PropTypes.oneOfType([t.PropTypes.string,t.PropTypes.element]),suffix:t.PropTypes.oneOfType([t.PropTypes.string,t.PropTypes.element]),placeholder:t.PropTypes.string,tabIndex:t.PropTypes.number,onChange:t.PropTypes.func,onBlur:t.PropTypes.func,onFocus:t.PropTypes.func,className:t.PropTypes.string,style:t.PropTypes.object,size:t.PropTypes.oneOf(["small","medium","large"]),color:t.PropTypes.oneOf(["primary","secondary","success","danger","warning","information","neutral","gray"])};module.exports=S;
|
package/dist/NumberInput.js
CHANGED
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import { jsxs as
|
|
1
|
+
import { jsxs as P, jsx as y } from "react/jsx-runtime";
|
|
2
2
|
import { P as n } from "./index-S5Cd7WrG.js";
|
|
3
|
-
import { forwardRef as
|
|
4
|
-
import { d as
|
|
3
|
+
import { forwardRef as W, useRef as G, useState as S, useEffect as M, useCallback as U } from "react";
|
|
4
|
+
import { d as D } from "./index-CkWvbrVT.js";
|
|
5
5
|
import { s as i } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
6
|
-
import { d, b as
|
|
7
|
-
import { u as
|
|
8
|
-
const
|
|
6
|
+
import { d as s, b as r, a as X, e as q, h as T, c as H } from "./utils-WHYrEnYF.js";
|
|
7
|
+
import { u as J } from "./emotion-element-f0de968e.browser.esm-CkCiQliQ.js";
|
|
8
|
+
const K = i.div`
|
|
9
9
|
display: flex;
|
|
10
10
|
align-items: center;
|
|
11
11
|
|
|
12
|
-
min-height: ${(e) =>
|
|
13
|
-
max-height: ${(e) =>
|
|
14
|
-
background-color: ${(e) =>
|
|
12
|
+
min-height: ${(e) => s(e.theme, e.size)};
|
|
13
|
+
max-height: ${(e) => s(e.theme, e.size)};
|
|
14
|
+
background-color: ${(e) => r(
|
|
15
15
|
e.theme,
|
|
16
16
|
"Input",
|
|
17
17
|
e.color,
|
|
@@ -19,27 +19,27 @@ const H = i.div`
|
|
|
19
19
|
"background"
|
|
20
20
|
)};
|
|
21
21
|
border: 1px solid
|
|
22
|
-
${(e) =>
|
|
22
|
+
${(e) => r(
|
|
23
23
|
e.theme,
|
|
24
24
|
"Input",
|
|
25
25
|
e.focused === !0 ? "primary" : e.color,
|
|
26
26
|
e.disabled === !0 ? "disabled" : "enabled",
|
|
27
27
|
"border"
|
|
28
28
|
)};
|
|
29
|
-
border-radius: ${(e) =>
|
|
29
|
+
border-radius: ${(e) => X(e.theme, "regular")};
|
|
30
30
|
|
|
31
|
-
${(e) => e.focused && e.readOnly !== !0 ?
|
|
32
|
-
${(e) => e.disabled === !0 ?
|
|
33
|
-
`,
|
|
31
|
+
${(e) => e.focused && e.readOnly !== !0 ? q(e.theme) : ""}
|
|
32
|
+
${(e) => e.disabled === !0 ? T(e.theme) : ""}
|
|
33
|
+
`, V = i.span`
|
|
34
34
|
padding: 0 12px;
|
|
35
|
-
color: ${(e) =>
|
|
35
|
+
color: ${(e) => r(
|
|
36
36
|
e.theme,
|
|
37
37
|
"Input",
|
|
38
38
|
e.focused === !0 ? "primary" : e.color,
|
|
39
39
|
"enabled",
|
|
40
40
|
"prefix"
|
|
41
41
|
)};
|
|
42
|
-
`,
|
|
42
|
+
`, L = i(V)``, Q = i.input`
|
|
43
43
|
background: none;
|
|
44
44
|
border: none;
|
|
45
45
|
outline: none;
|
|
@@ -47,22 +47,22 @@ const H = i.div`
|
|
|
47
47
|
padding-bottom: 0.625rem;
|
|
48
48
|
width: 100%;
|
|
49
49
|
|
|
50
|
-
${(e) =>
|
|
51
|
-
min-height: ${(e) =>
|
|
52
|
-
max-height: ${(e) =>
|
|
53
|
-
color: ${(e) =>
|
|
50
|
+
${(e) => H(e.theme, "Input", e.size, "enabled")}
|
|
51
|
+
min-height: ${(e) => s(e.theme, e.size)};
|
|
52
|
+
max-height: ${(e) => s(e.theme, e.size)};
|
|
53
|
+
color: ${(e) => r(
|
|
54
54
|
e.theme,
|
|
55
55
|
"Input",
|
|
56
56
|
e.focused === !0 ? "primary" : e.color,
|
|
57
57
|
"enabled",
|
|
58
58
|
"text"
|
|
59
59
|
)};
|
|
60
|
-
caret-color: ${(e) =>
|
|
60
|
+
caret-color: ${(e) => r(e.theme, "Input", e.color, "enabled", "caret")};
|
|
61
61
|
padding-right: ${(e) => e.suffix ? "0" : "0.75rem"};
|
|
62
62
|
padding-left: ${(e) => e.prefix ? "0" : "0.75rem"};
|
|
63
63
|
|
|
64
64
|
&::placeholder {
|
|
65
|
-
color: ${(e) =>
|
|
65
|
+
color: ${(e) => r(
|
|
66
66
|
e.theme,
|
|
67
67
|
"Input",
|
|
68
68
|
e.color,
|
|
@@ -76,99 +76,99 @@ const H = i.div`
|
|
|
76
76
|
}
|
|
77
77
|
|
|
78
78
|
&:disabled {
|
|
79
|
-
${(e) =>
|
|
79
|
+
${(e) => T(e.theme)}
|
|
80
80
|
background: none;
|
|
81
81
|
}
|
|
82
|
-
`,
|
|
82
|
+
`, Y = W((e, O) => {
|
|
83
83
|
const {
|
|
84
|
-
disabled:
|
|
85
|
-
readOnly:
|
|
86
|
-
debounceTime:
|
|
87
|
-
step:
|
|
88
|
-
min:
|
|
89
|
-
max:
|
|
90
|
-
prefix:
|
|
84
|
+
disabled: p,
|
|
85
|
+
readOnly: x,
|
|
86
|
+
debounceTime: z = 0,
|
|
87
|
+
step: v = 1,
|
|
88
|
+
min: E = Number.MIN_SAFE_INTEGER,
|
|
89
|
+
max: R = Number.MAX_SAFE_INTEGER,
|
|
90
|
+
prefix: c,
|
|
91
91
|
suffix: m,
|
|
92
|
-
placeholder:
|
|
93
|
-
value:
|
|
94
|
-
defaultValue:
|
|
92
|
+
placeholder: F,
|
|
93
|
+
value: a,
|
|
94
|
+
defaultValue: $,
|
|
95
95
|
//----------------
|
|
96
96
|
onChange: l,
|
|
97
|
-
onBlur:
|
|
98
|
-
onFocus:
|
|
97
|
+
onBlur: f,
|
|
98
|
+
onFocus: h,
|
|
99
99
|
//----------------
|
|
100
100
|
className: k = "",
|
|
101
|
-
style:
|
|
102
|
-
size:
|
|
101
|
+
style: B = {},
|
|
102
|
+
size: I = "small",
|
|
103
103
|
color: o = "primary",
|
|
104
|
-
...
|
|
105
|
-
} = e, u =
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
}, [
|
|
109
|
-
const
|
|
110
|
-
|
|
104
|
+
..._
|
|
105
|
+
} = e, u = J(), d = G(a || $ || ""), [j, C] = S(a || $ || ""), [b, N] = S(!1);
|
|
106
|
+
M(() => {
|
|
107
|
+
a != null && (d.current = a, C(d.current));
|
|
108
|
+
}, [a]);
|
|
109
|
+
const w = U(
|
|
110
|
+
D((t, g) => A(t, g), z),
|
|
111
111
|
[l]
|
|
112
|
-
),
|
|
113
|
-
l && (l == null || l(t,
|
|
112
|
+
), A = (t, g) => {
|
|
113
|
+
l && (l == null || l(t, g));
|
|
114
114
|
};
|
|
115
|
-
return /* @__PURE__ */
|
|
116
|
-
|
|
115
|
+
return /* @__PURE__ */ P(
|
|
116
|
+
K,
|
|
117
117
|
{
|
|
118
|
-
style:
|
|
118
|
+
style: B,
|
|
119
119
|
className: k,
|
|
120
120
|
theme: u,
|
|
121
121
|
color: o,
|
|
122
|
-
size:
|
|
123
|
-
focused:
|
|
124
|
-
disabled:
|
|
125
|
-
readOnly:
|
|
122
|
+
size: I,
|
|
123
|
+
focused: b,
|
|
124
|
+
disabled: p,
|
|
125
|
+
readOnly: x,
|
|
126
126
|
children: [
|
|
127
|
-
|
|
128
|
-
|
|
127
|
+
c && /* @__PURE__ */ y(
|
|
128
|
+
V,
|
|
129
129
|
{
|
|
130
130
|
theme: u,
|
|
131
131
|
color: o,
|
|
132
|
-
focused:
|
|
132
|
+
focused: b,
|
|
133
133
|
className: "lnc-input-prefix",
|
|
134
|
-
children:
|
|
134
|
+
children: c
|
|
135
135
|
}
|
|
136
136
|
),
|
|
137
|
-
/* @__PURE__ */
|
|
138
|
-
|
|
137
|
+
/* @__PURE__ */ y(
|
|
138
|
+
Q,
|
|
139
139
|
{
|
|
140
|
-
ref:
|
|
140
|
+
ref: O,
|
|
141
141
|
type: "number",
|
|
142
142
|
theme: u,
|
|
143
143
|
color: o,
|
|
144
|
-
size:
|
|
145
|
-
placeholder:
|
|
146
|
-
prefix:
|
|
144
|
+
size: I,
|
|
145
|
+
placeholder: F,
|
|
146
|
+
prefix: c,
|
|
147
147
|
suffix: m,
|
|
148
|
-
disabled:
|
|
149
|
-
readOnly:
|
|
150
|
-
step:
|
|
151
|
-
min:
|
|
152
|
-
max:
|
|
153
|
-
value:
|
|
148
|
+
disabled: p,
|
|
149
|
+
readOnly: x,
|
|
150
|
+
step: v,
|
|
151
|
+
min: E,
|
|
152
|
+
max: R,
|
|
153
|
+
value: j,
|
|
154
154
|
onFocus: (t) => {
|
|
155
|
-
|
|
155
|
+
N(!0), h == null || h(t);
|
|
156
156
|
},
|
|
157
157
|
onBlur: (t) => {
|
|
158
|
-
|
|
158
|
+
N(!1), f == null || f(t);
|
|
159
159
|
},
|
|
160
160
|
onChange: (t) => {
|
|
161
|
-
|
|
161
|
+
d.current = t.target.value, C(d.current), w(t, t.target.value);
|
|
162
162
|
},
|
|
163
|
-
...
|
|
163
|
+
..._
|
|
164
164
|
}
|
|
165
165
|
),
|
|
166
|
-
m && /* @__PURE__ */
|
|
167
|
-
|
|
166
|
+
m && /* @__PURE__ */ y(
|
|
167
|
+
L,
|
|
168
168
|
{
|
|
169
169
|
theme: u,
|
|
170
170
|
color: o,
|
|
171
|
-
focused:
|
|
171
|
+
focused: b,
|
|
172
172
|
className: "lnc-input-suffix",
|
|
173
173
|
children: m
|
|
174
174
|
}
|
|
@@ -177,8 +177,8 @@ const H = i.div`
|
|
|
177
177
|
}
|
|
178
178
|
);
|
|
179
179
|
});
|
|
180
|
-
|
|
181
|
-
id: n.
|
|
180
|
+
Y.propTypes = {
|
|
181
|
+
id: n.any,
|
|
182
182
|
value: n.any,
|
|
183
183
|
defaultValue: n.any,
|
|
184
184
|
disabled: n.bool,
|
|
@@ -237,5 +237,5 @@ L.propTypes = {
|
|
|
237
237
|
])
|
|
238
238
|
};
|
|
239
239
|
export {
|
|
240
|
-
|
|
240
|
+
Y as default
|
|
241
241
|
};
|
package/dist/PasswordInput.cjs
CHANGED
|
@@ -44,4 +44,4 @@
|
|
|
44
44
|
${e=>r.getDisabledStateCss(e.theme)}
|
|
45
45
|
background: none;
|
|
46
46
|
}
|
|
47
|
-
`,V=s.forwardRef((e,m)=>{const{wrapperRef:z,disabled:$,readOnly:C,debounceTime:R=0,placeholder:k,prefix:b,suffix:f,value:u,defaultValue:v,onChange:
|
|
47
|
+
`,V=s.forwardRef((e,m)=>{const{wrapperRef:z,disabled:$,readOnly:C,debounceTime:R=0,placeholder:k,prefix:b,suffix:f,value:u,defaultValue:v,onChange:c,onBlur:p,onFocus:x,className:j="",style:q={},size:P="small",color:i="primary",...w}=e,o=s.useRef(),d=A.useTheme(),[O,S]=s.useState(u||v||"");s.useEffect(()=>{u!=null&&S(u)},[u]);const[y,W]=s.useState(!0),[g,I]=s.useState(!1);s.useEffect(()=>{var l;const t=((l=o==null?void 0:o.current)==null?void 0:l.value)||"";o.current.selectionStart=t!=null&&t.length?t.length:0,o.current.selectionEnd=t!=null&&t.length?t.length:0},[y]),s.useEffect(()=>{m!=null&&(m.current=o.current)},[m,o]);const E=s.useCallback(L.debounce((t,l)=>U(t,l),R),[c]),U=(t,l)=>{c&&(c==null||c(t,l))},F=t=>{S(t.target.value),E(t,t.target.value)},N=()=>{W(!y),o.current.focus()},_=t=>{I(!0),x==null||x(t)},B=t=>{I(!1),p==null||p(t)};return a.jsxs(G,{ref:z,style:q,className:j,theme:d,color:i,size:P,focused:g,disabled:$,readOnly:C,children:[b&&a.jsx(T,{theme:d,color:i,focused:g,className:"lnc-input-prefix",children:b}),a.jsx(K,{ref:o,type:y?"password":"text",theme:d,color:i,size:P,placeholder:k,prefix:b,suffix:f,disabled:$,readOnly:C,focused:g,onFocus:_,onBlur:B,onChange:F,value:O,...w}),a.jsx(J,{theme:d,color:i,focused:g,onClick:N,children:a.jsx(D,{icon:y?"eye-slash":"eye"})}),f&&a.jsx(H,{theme:d,color:i,focused:g,className:"lnc-input-suffix",children:f})]})});V.propTypes={id:n.PropTypes.any,value:n.PropTypes.string,defaultValue:n.PropTypes.string,disabled:n.PropTypes.bool,readOnly:n.PropTypes.bool,debounceTime:n.PropTypes.number,placeholder:n.PropTypes.string,tabIndex:n.PropTypes.number,onChange:n.PropTypes.func,onBlur:n.PropTypes.func,onFocus:n.PropTypes.func,className:n.PropTypes.string,style:n.PropTypes.object,size:n.PropTypes.oneOf(["small","medium","large"]),color:n.PropTypes.oneOf(["primary","secondary","success","danger","warning","information","neutral","gray"])};module.exports=V;
|
package/dist/PasswordInput.js
CHANGED
package/dist/ProgressBar.cjs
CHANGED
|
@@ -27,4 +27,4 @@
|
|
|
27
27
|
left: 50%;
|
|
28
28
|
transform: translate(-50%, -50%);
|
|
29
29
|
color: ${e=>o.getColorRgbaValue(e.theme,"Progress",e.color,"enabled","text")};
|
|
30
|
-
`,d=i.forwardRef((e,w)=>{const{id:$="",showLabel:c=!1,progressPercentage:t=0,className:m="",style:u={},onChange:C=()=>{},size:g="small",color:b="primary",progressBarEndComponent:s,...
|
|
30
|
+
`,d=i.forwardRef((e,w)=>{const{id:$="",showLabel:c=!1,progressPercentage:t=0,className:m="",style:u={},onChange:C=()=>{},size:g="small",color:b="primary",progressBarEndComponent:s,...y}=e,n=P.useTheme(),h=()=>{var p;if(i.isValidElement(s))return i.cloneElement(s,{className:`progress-icon ${(p=s==null?void 0:s.props)==null?void 0:p.className}`})};return a.jsxs(f,{style:u,className:"lnc-ui-progress "+m,theme:n,size:g,showLabel:c,progressPercentage:t,...y,children:[a.jsx(x,{progressPercentage:t,theme:n,color:b,children:s!==null&&h()}),c&&a.jsxs(T,{theme:n,size:g,children:[t,"%"]})]})});d.propTypes={id:r.PropTypes.any,showLabel:r.PropTypes.bool,progressPercentage:r.PropTypes.number,onChange:r.PropTypes.func,className:r.PropTypes.string,style:r.PropTypes.object,size:r.PropTypes.oneOf(["small","medium","large"]),color:r.PropTypes.oneOf(["primary","secondary","success","danger","warning","disabled","information","neutral","gray"]),progressBarEndComponent:r.PropTypes.any};module.exports=d;
|
package/dist/ProgressBar.js
CHANGED
package/dist/RadioGroup.cjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
"use strict";const p=require("react/jsx-runtime"),n=require("react"),
|
|
1
|
+
"use strict";const p=require("react/jsx-runtime"),n=require("react"),O=require("./emotion-styled.browser.esm-BtEseadx.cjs"),e=require("./index-BPVoEhTF.cjs"),R=require("./RadioInput.cjs"),I=require("./emotion-element-f0de968e.browser.esm-B7k6i6lC.cjs"),_=O.styled.div`
|
|
2
2
|
display: inline-flex;
|
|
3
|
-
flex-direction: ${
|
|
3
|
+
flex-direction: ${o=>o.inline===!0?"row":"column"};
|
|
4
4
|
gap: 1.5rem;
|
|
5
5
|
width: fit-content;
|
|
6
6
|
box-sizing: border-box;
|
|
7
|
-
`,
|
|
7
|
+
`,l=n.forwardRef((o,t)=>{const{id:d="",name:y,value:s=null,disabled:c=!1,readOnly:u=!1,items:m=[],mapId:z="id",mapValue:k="value",radioProps:P,inline:T=!0,onChange:a=()=>{},className:f="",style:b={},size:g="small",color:h="primary",...x}=o;var v=I.useTheme();const[q,w]=n.useState(null);n.useEffect(()=>{s!==q&&w(s)},[s]);var C={color:h,theme:v,size:g,disabled:c,readOnly:u};const j=(r,i)=>{a&&a(r)};return p.jsx(_,{ref:t,id:d,inline:T,style:b,className:f,...x,children:m.map((r,i)=>p.jsx(R,{...C,label:r.label,value:r.value,...P,onChange:j,name:y},i))})});l.propTypes={id:e.PropTypes.any,name:e.PropTypes.string,value:e.PropTypes.any,disabled:e.PropTypes.bool,readOnly:e.PropTypes.bool,items:e.PropTypes.arrayOf(e.PropTypes.object),mapid:e.PropTypes.any,mapValue:e.PropTypes.string,inline:e.PropTypes.bool,onChange:e.PropTypes.func,className:e.PropTypes.string,style:e.PropTypes.object,size:e.PropTypes.oneOf(["small","medium","large"]),color:e.PropTypes.oneOf(["primary","secondary","success","danger","warning","information","neutral","gray"]),radioProps:e.PropTypes.any};module.exports=l;
|
package/dist/RadioGroup.js
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { forwardRef as
|
|
1
|
+
import { jsx as l } from "react/jsx-runtime";
|
|
2
|
+
import { forwardRef as I, useState as j, useEffect as z } from "react";
|
|
3
3
|
import { s as R } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
4
4
|
import { P as e } from "./index-S5Cd7WrG.js";
|
|
5
5
|
import T from "./RadioInput.js";
|
|
6
6
|
import { u as k } from "./emotion-element-f0de968e.browser.esm-CkCiQliQ.js";
|
|
7
7
|
const N = R.div`
|
|
8
8
|
display: inline-flex;
|
|
9
|
-
flex-direction: ${(
|
|
9
|
+
flex-direction: ${(o) => o.inline === !0 ? "row" : "column"};
|
|
10
10
|
gap: 1.5rem;
|
|
11
11
|
width: fit-content;
|
|
12
12
|
box-sizing: border-box;
|
|
13
|
-
`, V =
|
|
13
|
+
`, V = I((o, s) => {
|
|
14
14
|
const {
|
|
15
15
|
id: t = "",
|
|
16
16
|
name: m,
|
|
17
|
-
value:
|
|
17
|
+
value: r = null,
|
|
18
18
|
disabled: d = !1,
|
|
19
19
|
readOnly: p = !1,
|
|
20
20
|
items: u = [],
|
|
@@ -26,44 +26,44 @@ const N = R.div`
|
|
|
26
26
|
onChange: n = () => {
|
|
27
27
|
},
|
|
28
28
|
//----------------
|
|
29
|
-
className:
|
|
30
|
-
style:
|
|
29
|
+
className: y = "",
|
|
30
|
+
style: g = {},
|
|
31
31
|
size: b = "small",
|
|
32
32
|
color: h = "primary",
|
|
33
33
|
...v
|
|
34
|
-
} =
|
|
34
|
+
} = o;
|
|
35
35
|
var x = k();
|
|
36
|
-
const [C,
|
|
36
|
+
const [C, O] = j(null);
|
|
37
37
|
z(() => {
|
|
38
|
-
|
|
39
|
-
}, [
|
|
40
|
-
var
|
|
38
|
+
r !== C && O(r);
|
|
39
|
+
}, [r]);
|
|
40
|
+
var P = {
|
|
41
41
|
color: h,
|
|
42
42
|
theme: x,
|
|
43
43
|
size: b,
|
|
44
44
|
disabled: d,
|
|
45
45
|
readOnly: p
|
|
46
46
|
};
|
|
47
|
-
const
|
|
47
|
+
const w = (a, i) => {
|
|
48
48
|
n && n(a);
|
|
49
49
|
};
|
|
50
|
-
return /* @__PURE__ */
|
|
50
|
+
return /* @__PURE__ */ l(
|
|
51
51
|
N,
|
|
52
52
|
{
|
|
53
|
-
ref:
|
|
53
|
+
ref: s,
|
|
54
54
|
id: t,
|
|
55
55
|
inline: f,
|
|
56
|
-
style:
|
|
57
|
-
className:
|
|
56
|
+
style: g,
|
|
57
|
+
className: y,
|
|
58
58
|
...v,
|
|
59
|
-
children: u.map((a, i) => /* @__PURE__ */
|
|
59
|
+
children: u.map((a, i) => /* @__PURE__ */ l(
|
|
60
60
|
T,
|
|
61
61
|
{
|
|
62
|
-
...
|
|
62
|
+
...P,
|
|
63
63
|
label: a.label,
|
|
64
64
|
value: a.value,
|
|
65
65
|
...c,
|
|
66
|
-
onChange:
|
|
66
|
+
onChange: w,
|
|
67
67
|
name: m
|
|
68
68
|
},
|
|
69
69
|
i
|
|
@@ -72,13 +72,13 @@ const N = R.div`
|
|
|
72
72
|
);
|
|
73
73
|
});
|
|
74
74
|
V.propTypes = {
|
|
75
|
-
id: e.
|
|
75
|
+
id: e.any,
|
|
76
76
|
name: e.string,
|
|
77
77
|
value: e.any,
|
|
78
78
|
disabled: e.bool,
|
|
79
79
|
readOnly: e.bool,
|
|
80
80
|
items: e.arrayOf(e.object),
|
|
81
|
-
|
|
81
|
+
mapid: e.any,
|
|
82
82
|
mapValue: e.string,
|
|
83
83
|
inline: e.bool,
|
|
84
84
|
//----------------
|
package/dist/RadioInput.cjs
CHANGED
|
@@ -114,4 +114,4 @@
|
|
|
114
114
|
overflow: hidden;
|
|
115
115
|
text-overflow: ellipsis;
|
|
116
116
|
color: ${e=>o.getColorRgbaValue(e.theme,"Radio",e.color,"enabled","text")};
|
|
117
|
-
`,
|
|
117
|
+
`,y=h.forwardRef((e,f)=>{const{wrapperRef:R,className:C="",style:w={},color:k="primary",innerColor:x="white",size:$="small",onChange:a,onFocus:l,onBlur:n,onClick:c,onKeyDown:N,label:u,labelPosition:p="right",spaceBetween:v,disabled:s,readOnly:d,...P}=e,[T,b]=h.useState(!1);var g={theme:O.useTheme(),size:$,color:k,disabled:s,labelPosition:p,spaceBetween:v};const V=t=>{b(!1),n&&(n==null||n(t))},z=t=>{b(!0),l&&(l==null||l(t))};return i.jsxs(q,{...g,ref:R,className:C,style:w,tabIndex:-1,readOnly:d,focused:T,onClick:t=>c==null?void 0:c(t),innerColor:x,children:[i.jsx("input",{ref:f,disabled:s||d,type:"radio",onBlur:V,onFocus:z,onChange:t=>a==null?void 0:a(t),...P}),i.jsx("div",{className:"checkmark",children:i.jsxs("svg",{id:"eqw1eBsfm9l1",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",shapeRendering:"geometricPrecision",textRendering:"geometricPrecision",children:[i.jsx("ellipse",{className:"outer-circle",rx:"9.5",ry:"9.5",transform:"translate(10 10)",fillRule:"evenodd",stroke:"red"}),i.jsx("ellipse",{rx:"5",ry:"5",transform:"translate(10 10)",className:"inner-circle",strokeWidth:"0"})]})}),i.jsx(B,{...g,className:"lnc-radio-input-label",disalbed:s,readOnly:d,title:u,tabIndex:-1,children:u})]})});y.propTypes={id:r.PropTypes.any,name:r.PropTypes.string,checked:r.PropTypes.bool,disabled:r.PropTypes.bool,readOnly:r.PropTypes.bool,label:r.PropTypes.oneOfType([r.PropTypes.string,r.PropTypes.element]),labelPosition:r.PropTypes.oneOf(["right","left"]),tabIndex:r.PropTypes.number,spaceBetween:r.PropTypes.bool,onChange:r.PropTypes.func,onFocus:r.PropTypes.func,onBlur:r.PropTypes.func,onClick:r.PropTypes.func,onKeyDown:r.PropTypes.func,className:r.PropTypes.string,style:r.PropTypes.object,size:r.PropTypes.oneOf(["small","medium","large"]),color:r.PropTypes.oneOf(["primary","secondary","success","danger","warning","information","neutral","gray"]),innerColor:r.PropTypes.oneOf(["primary","secondary","success","danger","warning","information","neutral","gray","white","transparent"])};module.exports=y;
|
package/dist/RadioInput.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { jsxs as b, jsx as
|
|
1
|
+
import { jsxs as b, jsx as r } from "react/jsx-runtime";
|
|
2
2
|
import { forwardRef as P, useState as j } from "react";
|
|
3
3
|
import { s as g } from "./emotion-styled.browser.esm-BNN1dTl3.js";
|
|
4
4
|
import { P as i } from "./index-S5Cd7WrG.js";
|
|
@@ -246,26 +246,26 @@ const I = (e) => e == "left" ? "row-reverse" : "row", D = g.label`
|
|
|
246
246
|
tabIndex: -1,
|
|
247
247
|
readOnly: s,
|
|
248
248
|
focused: B,
|
|
249
|
-
onClick: (
|
|
249
|
+
onClick: (o) => c == null ? void 0 : c(o),
|
|
250
250
|
innerColor: v,
|
|
251
251
|
children: [
|
|
252
|
-
/* @__PURE__ */
|
|
252
|
+
/* @__PURE__ */ r(
|
|
253
253
|
"input",
|
|
254
254
|
{
|
|
255
255
|
ref: y,
|
|
256
256
|
disabled: d || s,
|
|
257
257
|
type: "radio",
|
|
258
|
-
onBlur: (
|
|
259
|
-
m(!1), l && (l == null || l(
|
|
258
|
+
onBlur: (o) => {
|
|
259
|
+
m(!1), l && (l == null || l(o));
|
|
260
260
|
},
|
|
261
|
-
onFocus: (
|
|
262
|
-
m(!0), n && (n == null || n(
|
|
261
|
+
onFocus: (o) => {
|
|
262
|
+
m(!0), n && (n == null || n(o));
|
|
263
263
|
},
|
|
264
|
-
onChange: (
|
|
264
|
+
onChange: (o) => a == null ? void 0 : a(o),
|
|
265
265
|
...z
|
|
266
266
|
}
|
|
267
267
|
),
|
|
268
|
-
/* @__PURE__ */
|
|
268
|
+
/* @__PURE__ */ r("div", { className: "checkmark", children: /* @__PURE__ */ b(
|
|
269
269
|
"svg",
|
|
270
270
|
{
|
|
271
271
|
id: "eqw1eBsfm9l1",
|
|
@@ -274,7 +274,7 @@ const I = (e) => e == "left" ? "row-reverse" : "row", D = g.label`
|
|
|
274
274
|
shapeRendering: "geometricPrecision",
|
|
275
275
|
textRendering: "geometricPrecision",
|
|
276
276
|
children: [
|
|
277
|
-
/* @__PURE__ */
|
|
277
|
+
/* @__PURE__ */ r(
|
|
278
278
|
"ellipse",
|
|
279
279
|
{
|
|
280
280
|
className: "outer-circle",
|
|
@@ -285,7 +285,7 @@ const I = (e) => e == "left" ? "row-reverse" : "row", D = g.label`
|
|
|
285
285
|
stroke: "red"
|
|
286
286
|
}
|
|
287
287
|
),
|
|
288
|
-
/* @__PURE__ */
|
|
288
|
+
/* @__PURE__ */ r(
|
|
289
289
|
"ellipse",
|
|
290
290
|
{
|
|
291
291
|
rx: "5",
|
|
@@ -298,7 +298,7 @@ const I = (e) => e == "left" ? "row-reverse" : "row", D = g.label`
|
|
|
298
298
|
]
|
|
299
299
|
}
|
|
300
300
|
) }),
|
|
301
|
-
/* @__PURE__ */
|
|
301
|
+
/* @__PURE__ */ r(
|
|
302
302
|
K,
|
|
303
303
|
{
|
|
304
304
|
...u,
|
|
@@ -315,7 +315,7 @@ const I = (e) => e == "left" ? "row-reverse" : "row", D = g.label`
|
|
|
315
315
|
);
|
|
316
316
|
});
|
|
317
317
|
L.propTypes = {
|
|
318
|
-
id: i.
|
|
318
|
+
id: i.any,
|
|
319
319
|
name: i.string,
|
|
320
320
|
checked: i.bool,
|
|
321
321
|
disabled: i.bool,
|