kwant-ui 3.29.5-alpha.1 → 3.29.5-alpha.2

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,3 +1,4 @@
1
+ /// <reference types="react" />
1
2
  import { IDatepicker } from './types';
2
- declare const Datepicker: (props: IDatepicker.Props) => import("react/jsx-runtime").JSX.Element;
3
+ declare const Datepicker: import("react").ForwardRefExoticComponent<Omit<IDatepicker.Props, "ref"> & import("react").RefAttributes<HTMLInputElement>>;
3
4
  export { Datepicker };
package/dist/index.es.js CHANGED
@@ -2016,7 +2016,7 @@ import{jsx as e,jsxs as t,Fragment as r}from"react/jsx-runtime";import n,{css as
2016
2016
  `,xa=n.div`
2017
2017
  display: flex;
2018
2018
  cursor: pointer;
2019
- `,Oa={chevronLeft:e("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e("path",{d:"M11.6736 2.5799L10.4869 1.3999L3.89355 7.9999L10.4936 14.5999L11.6736 13.4199L6.25355 7.9999L11.6736 2.5799Z",fill:"#0B1B2A"})}),chevronRight:e("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e("path",{d:"M4.32715 13.4199L5.50715 14.5999L12.1071 7.9999L5.50715 1.3999L4.32715 2.5799L9.74715 7.9999L4.32715 13.4199Z",fill:"#0B1B2A"})}),calendar:e("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e("path",{d:"M15.8333 3.33334H15V1.66667L13.3333 1.66667V3.33334L6.66667 3.33334V1.66667L5 1.66667V3.33334H4.16667C3.24167 3.33334 2.5 4.08334 2.5 5.00001L2.5 16.6667C2.5 17.5833 3.24167 18.3333 4.16667 18.3333H15.8333C16.75 18.3333 17.5 17.5833 17.5 16.6667V5.00001C17.5 4.08334 16.75 3.33334 15.8333 3.33334ZM15.8333 16.6667H4.16667L4.16667 8.33334L15.8333 8.33334L15.8333 16.6667ZM15.8333 6.66667L4.16667 6.66667L4.16667 5.00001L15.8333 5.00001V6.66667ZM5.83333 10L10 10L10 14.1667L5.83333 14.1667L5.83333 10Z",fill:"#A1AFC0"})})};var Ma;!function(e){var t;(t=e.DatpickerNavigationDirectionEnum||(e.DatpickerNavigationDirectionEnum={})).right="right",t.left="left"}(Ma||(Ma={}));const Ea=(t,r)=>e(ya,{onClick:e=>{e.stopPropagation(),r?.(e)},children:t===Ma.DatpickerNavigationDirectionEnum.right?Oa.chevronRight:Oa.chevronLeft}),Ha=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Pa=["Su","Mo","Tu","We","Th","Fr","Sa"],za=(e,t)=>!!(t>1&&e),ja="MM/DD/YYYY",Za=t=>{const{range:r,numberOfMonths:n=1,format:a=ja,onChange:c,label:i,placeholder:o=ja,required:s,readOnly:l,errorMessage:h,calendarRef:v,...p}=t;return e(ba,{renderButton:Ea,className:"date-picker-"+(za(r,n)?"range":"single"),ref:v,range:r,months:Ha,numberOfMonths:n,showOtherDays:!0,weekDays:Pa,render:(t,r,n)=>e(Ge,{rightSection:e(xa,{onClick:()=>{!l&&r()},children:Oa.calendar}),placeholder:o,value:t,onClick:()=>{!l&&r()},onChange:e=>{((e,t)=>{const r=e.target.value.match(/[^0-9/]/g);Array.isArray(r)||t(e)})(e,n)},label:i,required:s,readOnly:l,error:!!h,errorMessage:h}),onChange:c&&c,format:a,portal:!0,...p})},Va=n.div`
2019
+ `,Oa={chevronLeft:e("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e("path",{d:"M11.6736 2.5799L10.4869 1.3999L3.89355 7.9999L10.4936 14.5999L11.6736 13.4199L6.25355 7.9999L11.6736 2.5799Z",fill:"#0B1B2A"})}),chevronRight:e("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e("path",{d:"M4.32715 13.4199L5.50715 14.5999L12.1071 7.9999L5.50715 1.3999L4.32715 2.5799L9.74715 7.9999L4.32715 13.4199Z",fill:"#0B1B2A"})}),calendar:e("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e("path",{d:"M15.8333 3.33334H15V1.66667L13.3333 1.66667V3.33334L6.66667 3.33334V1.66667L5 1.66667V3.33334H4.16667C3.24167 3.33334 2.5 4.08334 2.5 5.00001L2.5 16.6667C2.5 17.5833 3.24167 18.3333 4.16667 18.3333H15.8333C16.75 18.3333 17.5 17.5833 17.5 16.6667V5.00001C17.5 4.08334 16.75 3.33334 15.8333 3.33334ZM15.8333 16.6667H4.16667L4.16667 8.33334L15.8333 8.33334L15.8333 16.6667ZM15.8333 6.66667L4.16667 6.66667L4.16667 5.00001L15.8333 5.00001V6.66667ZM5.83333 10L10 10L10 14.1667L5.83333 14.1667L5.83333 10Z",fill:"#A1AFC0"})})};var Ma;!function(e){var t;(t=e.DatpickerNavigationDirectionEnum||(e.DatpickerNavigationDirectionEnum={})).right="right",t.left="left"}(Ma||(Ma={}));const Ea=(t,r)=>e(ya,{onClick:e=>{e.stopPropagation(),r?.(e)},children:t===Ma.DatpickerNavigationDirectionEnum.right?Oa.chevronRight:Oa.chevronLeft}),Ha=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Pa=["Su","Mo","Tu","We","Th","Fr","Sa"],za=(e,t)=>!!(t>1&&e),ja="MM/DD/YYYY",Za=h(((t,r)=>{const{range:n,numberOfMonths:a=1,format:c=ja,onChange:i,label:o,placeholder:s=ja,required:l,readOnly:h,errorMessage:v,calendarRef:p,...u}=t;return e(ba,{renderButton:Ea,className:"date-picker-"+(za(n,a)?"range":"single"),ref:p,range:n,months:Ha,numberOfMonths:a,showOtherDays:!0,weekDays:Pa,render:(t,n,a)=>e(Ge,{rightSection:e(xa,{onClick:()=>{!h&&n()},children:Oa.calendar}),placeholder:s,value:t,onClick:()=>{!h&&n()},onChange:e=>{((e,t)=>{const r=e.target.value.match(/[^0-9/]/g);Array.isArray(r)||t(e)})(e,a)},label:o,required:l,readOnly:h,error:!!v,errorMessage:v,ref:r}),onChange:i&&i,format:c,portal:!0,...u})})),Va=n.div`
2020
2020
  .xsmall {
2021
2021
  width: 20px;
2022
2022
  height: 20px;
package/dist/index.js CHANGED
@@ -2016,7 +2016,7 @@
2016
2016
  `,Rn=t.div`
2017
2017
  display: flex;
2018
2018
  cursor: pointer;
2019
- `,Dn={chevronLeft:e.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e.jsx("path",{d:"M11.6736 2.5799L10.4869 1.3999L3.89355 7.9999L10.4936 14.5999L11.6736 13.4199L6.25355 7.9999L11.6736 2.5799Z",fill:"#0B1B2A"})}),chevronRight:e.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e.jsx("path",{d:"M4.32715 13.4199L5.50715 14.5999L12.1071 7.9999L5.50715 1.3999L4.32715 2.5799L9.74715 7.9999L4.32715 13.4199Z",fill:"#0B1B2A"})}),calendar:e.jsx("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e.jsx("path",{d:"M15.8333 3.33334H15V1.66667L13.3333 1.66667V3.33334L6.66667 3.33334V1.66667L5 1.66667V3.33334H4.16667C3.24167 3.33334 2.5 4.08334 2.5 5.00001L2.5 16.6667C2.5 17.5833 3.24167 18.3333 4.16667 18.3333H15.8333C16.75 18.3333 17.5 17.5833 17.5 16.6667V5.00001C17.5 4.08334 16.75 3.33334 15.8333 3.33334ZM15.8333 16.6667H4.16667L4.16667 8.33334L15.8333 8.33334L15.8333 16.6667ZM15.8333 6.66667L4.16667 6.66667L4.16667 5.00001L15.8333 5.00001V6.66667ZM5.83333 10L10 10L10 14.1667L5.83333 14.1667L5.83333 10Z",fill:"#A1AFC0"})})};var In;!function(e){var t;(t=e.DatpickerNavigationDirectionEnum||(e.DatpickerNavigationDirectionEnum={})).right="right",t.left="left"}(In||(In={}));const Tn=(t,r)=>e.jsx(Sn,{onClick:e=>{e.stopPropagation(),r?.(e)},children:t===In.DatpickerNavigationDirectionEnum.right?Dn.chevronRight:Dn.chevronLeft}),Nn=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Fn=["Su","Mo","Tu","We","Th","Fr","Sa"],Qn=(e,t)=>!!(t>1&&e),Yn="MM/DD/YYYY",$n=t=>{const{range:r,numberOfMonths:n=1,format:a=Yn,onChange:c,label:s,placeholder:i=Yn,required:o,readOnly:l,errorMessage:h,calendarRef:v,...p}=t;return e.jsx(kn,{renderButton:Tn,className:"date-picker-"+(Qn(r,n)?"range":"single"),ref:v,range:r,months:Nn,numberOfMonths:n,showOtherDays:!0,weekDays:Fn,render:(t,r,n)=>e.jsx(ze,{rightSection:e.jsx(Rn,{onClick:()=>{!l&&r()},children:Dn.calendar}),placeholder:i,value:t,onClick:()=>{!l&&r()},onChange:e=>{((e,t)=>{const r=e.target.value.match(/[^0-9/]/g);Array.isArray(r)||t(e)})(e,n)},label:s,required:o,readOnly:l,error:!!h,errorMessage:h}),onChange:c&&c,format:a,portal:!0,...p})},Un=t.div`
2019
+ `,Dn={chevronLeft:e.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e.jsx("path",{d:"M11.6736 2.5799L10.4869 1.3999L3.89355 7.9999L10.4936 14.5999L11.6736 13.4199L6.25355 7.9999L11.6736 2.5799Z",fill:"#0B1B2A"})}),chevronRight:e.jsx("svg",{width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e.jsx("path",{d:"M4.32715 13.4199L5.50715 14.5999L12.1071 7.9999L5.50715 1.3999L4.32715 2.5799L9.74715 7.9999L4.32715 13.4199Z",fill:"#0B1B2A"})}),calendar:e.jsx("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e.jsx("path",{d:"M15.8333 3.33334H15V1.66667L13.3333 1.66667V3.33334L6.66667 3.33334V1.66667L5 1.66667V3.33334H4.16667C3.24167 3.33334 2.5 4.08334 2.5 5.00001L2.5 16.6667C2.5 17.5833 3.24167 18.3333 4.16667 18.3333H15.8333C16.75 18.3333 17.5 17.5833 17.5 16.6667V5.00001C17.5 4.08334 16.75 3.33334 15.8333 3.33334ZM15.8333 16.6667H4.16667L4.16667 8.33334L15.8333 8.33334L15.8333 16.6667ZM15.8333 6.66667L4.16667 6.66667L4.16667 5.00001L15.8333 5.00001V6.66667ZM5.83333 10L10 10L10 14.1667L5.83333 14.1667L5.83333 10Z",fill:"#A1AFC0"})})};var In;!function(e){var t;(t=e.DatpickerNavigationDirectionEnum||(e.DatpickerNavigationDirectionEnum={})).right="right",t.left="left"}(In||(In={}));const Tn=(t,r)=>e.jsx(Sn,{onClick:e=>{e.stopPropagation(),r?.(e)},children:t===In.DatpickerNavigationDirectionEnum.right?Dn.chevronRight:Dn.chevronLeft}),Nn=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],Fn=["Su","Mo","Tu","We","Th","Fr","Sa"],Qn=(e,t)=>!!(t>1&&e),Yn="MM/DD/YYYY",$n=r.forwardRef(((t,r)=>{const{range:n,numberOfMonths:a=1,format:c=Yn,onChange:s,label:i,placeholder:o=Yn,required:l,readOnly:h,errorMessage:v,calendarRef:p,...u}=t;return e.jsx(kn,{renderButton:Tn,className:"date-picker-"+(Qn(n,a)?"range":"single"),ref:p,range:n,months:Nn,numberOfMonths:a,showOtherDays:!0,weekDays:Fn,render:(t,n,a)=>e.jsx(ze,{rightSection:e.jsx(Rn,{onClick:()=>{!h&&n()},children:Dn.calendar}),placeholder:o,value:t,onClick:()=>{!h&&n()},onChange:e=>{((e,t)=>{const r=e.target.value.match(/[^0-9/]/g);Array.isArray(r)||t(e)})(e,a)},label:i,required:l,readOnly:h,error:!!v,errorMessage:v,ref:r}),onChange:s&&s,format:c,portal:!0,...u})})),Un=t.div`
2020
2020
  .xsmall {
2021
2021
  width: 20px;
2022
2022
  height: 20px;
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kwant-ui",
3
- "version": "3.29.5-alpha.1",
3
+ "version": "3.29.5-alpha.2",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.es.js",
6
6
  "types": "./dist/index.d.ts",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kwant-ui",
3
- "version": "3.29.5-alpha.1",
3
+ "version": "3.29.5-alpha.2",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.es.js",
6
6
  "types": "./dist/index.d.ts",