forstok-ui-lib 8.10.1 → 8.10.3

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.d.ts CHANGED
@@ -764,10 +764,12 @@ type TDate$1 = {
764
764
  allowEmpty?: boolean;
765
765
  setForceUpdate?: TState<boolean>;
766
766
  showTimeInput?: boolean;
767
- 'data-qa-id'?: string;
768
- 'data-tip'?: string;
769
- 'data-place'?: string;
770
- 'data-type'?: string;
767
+ minDate?: any;
768
+ minTime?: any;
769
+ "data-qa-id"?: string;
770
+ "data-tip"?: string;
771
+ "data-place"?: string;
772
+ "data-type"?: string;
771
773
  };
772
774
  declare const DateComponent: react.ForwardRefExoticComponent<TDate$1 & react.RefAttributes<unknown>>;
773
775
 
@@ -790,11 +792,13 @@ type TDate = {
790
792
  placeholderText?: string;
791
793
  portalId?: string;
792
794
  isIcon?: boolean;
793
- 'data-qa-id'?: string;
794
- 'data-tip'?: string;
795
- 'data-place'?: string;
796
- 'data-type'?: string;
795
+ "data-qa-id"?: string;
796
+ "data-tip"?: string;
797
+ "data-place"?: string;
798
+ "data-type"?: string;
797
799
  disabled?: boolean;
800
+ minDate?: any;
801
+ minTime?: any;
798
802
  };
799
803
  declare const DateRefComponent: react.ForwardRefExoticComponent<TDate & react.RefAttributes<unknown>>;
800
804
 
package/dist/index.js CHANGED
@@ -4800,7 +4800,7 @@ function O(e,t){if(!1===e||null==e)throw new Error(t)}function M(e,t){if(!e){"un
4800
4800
  border: 1px solid var(--ck-clr-ln);
4801
4801
  border-radius: var(--ter-rd);
4802
4802
  `}
4803
- `,Ua=r.forwardRef(((t,i)=>{var{dateFormat:n="MMM dd, yyyy",name:a,evChange:o,isField:l,saveFormat:s,showFormat:d,evChangeCustom:c,value:C,isForceUpdate:p,setForceUpdate:g,isError:h=!1,showTimeInput:x=!1,allowEmpty:m=!1}=t,u=b(t,["dateFormat","name","evChange","isField","saveFormat","showFormat","evChangeCustom","value","isForceUpdate","setForceUpdate","isError","showTimeInput","allowEmpty"]);const[v,f]=r.useState(C||(m?null:new Date)),w=e=>{f(e),o&&o(a,e),l&&c&&c(a,e?A.default(e).format(s):e)};return r.useEffect((()=>{if(p){const e=C||(m?null:new Date);f(e),g&&g(!1)}}),[p,g,C,m]),e.jsxs(Ya,Object.assign({$isError:h},u["data-qa-id"]&&{"data-qa-id":u["data-qa-id"]},{children:[e.jsx(y.default,{selected:v,name:a,portalId:"popup-portal",dateFormat:n,onChange:w,showTimeInput:x,onKeyDown:e=>e.preventDefault(),ref:i}),m&&v?e.jsx(Va,{onClick:()=>w(null),title:"clear",children:e.jsx("svg",{height:"20",width:"20",viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",children:e.jsx("path",{d:"M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z"})})}):null]}))})),Ra=r.forwardRef(((t,i)=>{const{dateFormat:n="MMM dd, yyyy",name:a,evChange:o,isField:l,saveFormat:s,showFormat:d,evChangeCustom:c,value:C,reset:p,setReset:g,isForceUpdate:h,setForceUpdate:x,isError:m=!1,showTimeInput:u=!1,allowEmpty:v=!1,placeholderText:f,portalId:w,isIcon:F,disabled:D}=t,E=b(t,["dateFormat","name","evChange","isField","saveFormat","showFormat","evChangeCustom","value","reset","setReset","isForceUpdate","setForceUpdate","isError","showTimeInput","allowEmpty","placeholderText","portalId","isIcon","disabled"]),[B,j]=r.useState(void 0!==C?C:v?null:new Date),k=e=>{j(e),o&&o(a,e),l&&c&&c(a,e?A.default(e).format(s):e)};return r.useEffect((()=>{if(p&&(j(null),g&&g(!1)),h){const e=C||(v?null:new Date);j(e),x&&x(!1)}}),[h,x,C,v,p,g]),e.jsxs(Ya,Object.assign({$isError:m},E["data-tip"]&&{"data-tip":E["data-tip"],"data-place":E["data-place"],"data-type":E["data-type"]},E["data-qa-id"]&&{"data-qa-id":E["data-qa-id"]},{children:[F&&e.jsx(yn,{$name:"calendar",$width:"20px"}),e.jsx(y.default,Object.assign({selected:B,name:a,dateFormat:n,onChange:k,showTimeInput:u,onKeyDown:e=>e.preventDefault(),placeholderText:f,ref:i},D&&{disabled:!0},w&&{portalId:w})),v&&B?e.jsx(Va,{onClick:()=>k(null),title:"clear",children:e.jsx("svg",{height:"20",width:"20",viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",children:e.jsx("path",{d:"M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z"})})}):null]}))})),Ga=m.default.div`
4803
+ `,Ua=r.forwardRef(((t,i)=>{var{dateFormat:n="MMM dd, yyyy",name:a,evChange:o,isField:l,saveFormat:s,showFormat:d,evChangeCustom:c,value:C,isForceUpdate:p,setForceUpdate:g,minDate:h,minTime:x,isError:m=!1,showTimeInput:u=!1,allowEmpty:v=!1}=t,f=b(t,["dateFormat","name","evChange","isField","saveFormat","showFormat","evChangeCustom","value","isForceUpdate","setForceUpdate","minDate","minTime","isError","showTimeInput","allowEmpty"]);const[w,F]=r.useState(C||(v?null:new Date)),D=e=>{F(e),o&&o(a,e),l&&c&&c(a,e?A.default(e).format(s):e)};return r.useEffect((()=>{if(p){const e=C||(v?null:new Date);F(e),g&&g(!1)}}),[p,g,C,v]),e.jsxs(Ya,Object.assign({$isError:m},f["data-qa-id"]&&{"data-qa-id":f["data-qa-id"]},{children:[e.jsx(y.default,Object.assign({selected:w,name:a,portalId:"popup-portal",dateFormat:n,onChange:D,showTimeInput:u,onKeyDown:e=>e.preventDefault(),ref:i},h&&{minDate:h},x&&{minTime:x})),v&&w?e.jsx(Va,{onClick:()=>D(null),title:"clear",children:e.jsx("svg",{height:"20",width:"20",viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",children:e.jsx("path",{d:"M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z"})})}):null]}))})),Ra=r.forwardRef(((t,i)=>{const{dateFormat:n="MMM dd, yyyy",name:a,evChange:o,isField:l,saveFormat:s,showFormat:d,evChangeCustom:c,value:C,reset:p,setReset:g,isForceUpdate:h,setForceUpdate:x,isError:m=!1,showTimeInput:u=!1,allowEmpty:v=!1,placeholderText:f,portalId:w,isIcon:F,disabled:D,minDate:E,minTime:B}=t,j=b(t,["dateFormat","name","evChange","isField","saveFormat","showFormat","evChangeCustom","value","reset","setReset","isForceUpdate","setForceUpdate","isError","showTimeInput","allowEmpty","placeholderText","portalId","isIcon","disabled","minDate","minTime"]),[k,O]=r.useState(void 0!==C?C:v?null:new Date),M=e=>{O(e),o&&o(a,e),l&&c&&c(a,e?A.default(e).format(s):e)};return r.useEffect((()=>{if(p&&(O(null),g&&g(!1)),h){const e=C||(v?null:new Date);O(e),x&&x(!1)}}),[h,x,C,v,p,g]),e.jsxs(Ya,Object.assign({$isError:m},j["data-tip"]&&{"data-tip":j["data-tip"],"data-place":j["data-place"],"data-type":j["data-type"]},j["data-qa-id"]&&{"data-qa-id":j["data-qa-id"]},{children:[F&&e.jsx(yn,{$name:"calendar",$width:"20px"}),e.jsx(y.default,Object.assign({selected:k,name:a,dateFormat:n,onChange:M,showTimeInput:u,onKeyDown:e=>e.preventDefault(),placeholderText:f,ref:i},D&&{disabled:!0},w&&{portalId:w},E&&{minDate:E},B&&{minTime:B})),v&&k?e.jsx(Va,{onClick:()=>M(null),title:"clear",children:e.jsx("svg",{height:"20",width:"20",viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",children:e.jsx("path",{d:"M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z"})})}):null]}))})),Ga=m.default.div`
4804
4804
  display: grid;
4805
4805
  `,Za=m.default.div`
4806
4806
  display: grid;