groundfloor-react-ui 1.3.49 → 1.3.50
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/index.es.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
package/dist/index.es.js
CHANGED
|
@@ -783,7 +783,7 @@ ${({customTriggerStyle:e})=>e}
|
|
|
783
783
|
`,nt=m.span`
|
|
784
784
|
color: ${({theme:e})=>e.variant.error};
|
|
785
785
|
${({errorTextStyle:e})=>e};
|
|
786
|
-
`,st=({listChips:e,setListChips:l,currentChip:o,setCurrentChip:
|
|
786
|
+
`,st=({listChips:e,setListChips:l,currentChip:o,setCurrentChip:i,chipListString:a,placeholder:r,errorMsg:n,handleBlurProps:s,label:d,labelCusTomStyles:p,containerStyle:m,inputContainerStyle:u,errorTextStyle:f,disabled:g,isValid:h,handleInputKeyDownProps:y,handleInputChangeProps:C,...x})=>{let v=a?a.split(","):e||[];const[w,A]=c(v),[S,k]=c(o),[E,V]=c(""),M=b()||R;return t.createElement(ot,{theme:M,containerStyle:m},t.createElement(ct,{inputContainerStyle:u},t.createElement(lt,{text:d,customStyles:p}),w.map(((e,l)=>t.createElement(it,{theme:M,key:e+`${l}`,onClick:()=>(e=>{const t=[...w];t.splice(e,1),A(t),V(""),s(t.join(","))})(l)},t.createElement(at,null,e)))),t.createElement(rt,{type:"text",placeholder:r,value:S,onKeyDown:e=>{"Enter"===e.key||","===e.key?(e.preventDefault(),h?S.trim()&&(y([...w,S.trim()].join(",")),A([...w,S.trim()]),k(""),V("")):V(n)):"Backspace"!==e.key||S||(y(w.slice(0,-1).join(",")),A(w.slice(0,-1)))},onChange:e=>{k(e.target.value),V(""),C(e.target.value)},theme:M,onBlur:()=>{if(h){let e;e=S.trim()?[...w,S.trim()]:[...w],s(e.join(",")),A(e),k("")}else h||V(n)},disabled:g})),E&&t.createElement(nt,{errorTextStyle:f,theme:M},E))};st.propTypes={listChips:e.arrayOf(e.string),setListChips:e.func,chipListString:e.string,currentChip:e.string,setCurrentChip:e.func,placeholder:e.string,isValid:e.bool,errorMsg:e.string,label:e.string,labelCusTomStyles:e.object,containerStyle:e.object,inputContainerStyle:e.object,errorTextStyle:e.object,disabled:e.bool,handleInputKeyDownProps:e.func,handleInputChangeProps:e.func},st.defaultProps={listChips:[],setListChips:()=>{},currentChip:"",setCurrentChip:()=>{},placeholder:"",errorMsg:"Please enter a valid email address",label:"From:",labelCusTomStyles:{},containerStyle:{},inputContainerStyle:{},errorTextStyle:{},disabled:!1,isValid:!0};const dt=m.div`
|
|
787
787
|
box-sizing: initial;
|
|
788
788
|
|
|
789
789
|
//Set the styles from the default styles object
|
package/dist/index.js
CHANGED
|
@@ -783,7 +783,7 @@ ${({customTriggerStyle:e})=>e}
|
|
|
783
783
|
`,ot=h.default.span`
|
|
784
784
|
color: ${({theme:e})=>e.variant.error};
|
|
785
785
|
${({errorTextStyle:e})=>e};
|
|
786
|
-
`,rt=({listChips:e,setListChips:a,currentChip:o,setCurrentChip:r,chipListString:c,placeholder:i,errorMsg:n,handleBlurProps:d,label:s,labelCusTomStyles:p,containerStyle:u,inputContainerStyle:f,errorTextStyle:m,disabled:b,isValid:h,handleInputKeyDownProps:y,handleInputChangeProps:x,...C})=>{let v=c?c.split(","):e||[];const[w,A]=t.useState(v),[S,k]=t.useState(o),[E,V]=t.useState(""),M=l.useTheme()||I;
|
|
786
|
+
`,rt=({listChips:e,setListChips:a,currentChip:o,setCurrentChip:r,chipListString:c,placeholder:i,errorMsg:n,handleBlurProps:d,label:s,labelCusTomStyles:p,containerStyle:u,inputContainerStyle:f,errorTextStyle:m,disabled:b,isValid:h,handleInputKeyDownProps:y,handleInputChangeProps:x,...C})=>{let v=c?c.split(","):e||[];const[w,A]=t.useState(v),[S,k]=t.useState(o),[E,V]=t.useState(""),M=l.useTheme()||I;return g.default.createElement(_e,{theme:M,containerStyle:u},g.default.createElement(et,{inputContainerStyle:f},g.default.createElement($e,{text:s,customStyles:p}),w.map(((e,t)=>g.default.createElement(tt,{theme:M,key:e+`${t}`,onClick:()=>(e=>{const t=[...w];t.splice(e,1),A(t),V(""),d(t.join(","))})(t)},g.default.createElement(lt,null,e)))),g.default.createElement(at,{type:"text",placeholder:i,value:S,onKeyDown:e=>{"Enter"===e.key||","===e.key?(e.preventDefault(),h?S.trim()&&(y([...w,S.trim()].join(",")),A([...w,S.trim()]),k(""),V("")):V(n)):"Backspace"!==e.key||S||(y(w.slice(0,-1).join(",")),A(w.slice(0,-1)))},onChange:e=>{k(e.target.value),V(""),x(e.target.value)},theme:M,onBlur:()=>{if(h){let e;e=S.trim()?[...w,S.trim()]:[...w],d(e.join(",")),A(e),k("")}else h||V(n)},disabled:b})),E&&g.default.createElement(ot,{errorTextStyle:m,theme:M},E))};rt.propTypes={listChips:b.default.arrayOf(b.default.string),setListChips:b.default.func,chipListString:b.default.string,currentChip:b.default.string,setCurrentChip:b.default.func,placeholder:b.default.string,isValid:b.default.bool,errorMsg:b.default.string,label:b.default.string,labelCusTomStyles:b.default.object,containerStyle:b.default.object,inputContainerStyle:b.default.object,errorTextStyle:b.default.object,disabled:b.default.bool,handleInputKeyDownProps:b.default.func,handleInputChangeProps:b.default.func},rt.defaultProps={listChips:[],setListChips:()=>{},currentChip:"",setCurrentChip:()=>{},placeholder:"",errorMsg:"Please enter a valid email address",label:"From:",labelCusTomStyles:{},containerStyle:{},inputContainerStyle:{},errorTextStyle:{},disabled:!1,isValid:!0};const ct=h.default.div`
|
|
787
787
|
box-sizing: initial;
|
|
788
788
|
|
|
789
789
|
//Set the styles from the default styles object
|