@zydon/common 2.5.11 → 2.5.13
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/chunk-2FXBVVBD.js +7 -0
- package/dist/chunk-2FXXN6VA.js +8 -0
- package/dist/chunk-2QUYG4AQ.js +8 -0
- package/dist/chunk-427TWOPH.js +10 -0
- package/dist/chunk-6O66AMF6.js +17 -0
- package/dist/{chunk-4VAXJ4XM.js → chunk-7WCRRQEW.js} +2 -2
- package/dist/{chunk-HZJAUQ3O.js → chunk-AJW3AGOS.js} +1 -1
- package/dist/chunk-DXACBPEV.js +9 -0
- package/dist/chunk-GJGUIHOL.js +17 -0
- package/dist/{chunk-DI3IT446.js → chunk-GVJPNJEL.js} +1 -1
- package/dist/{chunk-E4HZJEPW.js → chunk-MZ5WXXHN.js} +1 -1
- package/dist/chunk-NV2X5CYP.js +7 -0
- package/dist/{chunk-B3PCCRUQ.js → chunk-OYK7T66A.js} +2 -2
- package/dist/{chunk-FOOP2WUM.js → chunk-PBNDY7OR.js} +1 -1
- package/dist/{chunk-2NMLQNWC.js → chunk-TF3JCVT7.js} +1 -1
- package/dist/{chunk-JEAVENIM.js → chunk-X6R4YXWP.js} +1 -1
- package/dist/components/Autocomplete/index.js +1 -1
- package/dist/components/AutocompleteDetailed/index.js +1 -1
- package/dist/components/ColorPickerInput/index.js +1 -1
- package/dist/components/DataCards/index.js +1 -1
- package/dist/components/DataGrid/index.js +2 -2
- package/dist/components/DataView/index.js +3 -3
- package/dist/components/DatePicker/index.d.ts +2 -1
- package/dist/components/DatePicker/index.js +3 -3
- package/dist/components/DateRangeCalendar/index.d.ts +12 -0
- package/dist/components/DateRangeCalendar/index.js +7 -0
- package/dist/components/DateRangePicker/index.d.ts +2 -1
- package/dist/components/DateRangePicker/index.js +2 -2
- package/dist/components/DateTimePicker/index.d.ts +2 -1
- package/dist/components/DateTimePicker/index.js +3 -3
- package/dist/components/DragButton/index.js +1 -1
- package/dist/components/DragContainer/index.js +3 -3
- package/dist/components/FileUpload/index.js +6 -6
- package/dist/components/Incrementer/index.js +2 -2
- package/dist/components/InfoCircle/index.js +1 -1
- package/dist/components/MaskedInput/index.js +1 -1
- package/dist/components/NumberInput/index.js +1 -1
- package/dist/components/SearchInput/index.js +1 -1
- package/dist/components/SelectableCards/index.js +2 -2
- package/dist/components/SwapList/index.js +1 -1
- package/dist/components/TimePicker/index.d.ts +2 -1
- package/dist/components/TimePicker/index.js +2 -2
- package/dist/components/Tooltip/index.d.ts +1 -1
- package/dist/components/Tooltip/index.js +1 -1
- package/dist/components/form/Address/index.js +5 -5
- package/dist/components/form/Autocomplete/index.js +2 -2
- package/dist/components/form/AutocompleteDetailed/index.js +1 -1
- package/dist/components/form/Codes/index.js +2 -2
- package/dist/components/form/ColorPicker/index.js +1 -1
- package/dist/components/form/DatePicker/index.js +3 -3
- package/dist/components/form/DateRangePicker/index.js +5 -5
- package/dist/components/form/DateTimePicker/index.js +3 -3
- package/dist/components/form/Field/index.js +1 -1
- package/dist/components/form/Incrementer/index.js +2 -2
- package/dist/components/form/InputTags/index.js +4 -4
- package/dist/components/form/MaskedInput/index.js +2 -2
- package/dist/components/form/MultiChipField/index.js +4 -4
- package/dist/components/form/NumberInput/index.js +1 -1
- package/dist/components/form/Password/index.js +1 -1
- package/dist/components/form/SelectableCards/index.js +2 -2
- package/dist/components/form/TimePicker/index.js +2 -2
- package/dist/components/form/UploadAvatarWithCrop/index.js +3 -3
- package/dist/components/form/UploadWithCrop/index.js +4 -4
- package/dist/components/form/Webhook/index.js +3 -3
- package/dist/components/upload/index.js +6 -6
- package/dist/theme/styles/index.d.ts +1 -1
- package/package.json +1 -1
- package/dist/chunk-5J3V35EQ.js +0 -10
- package/dist/chunk-7BK54YIS.js +0 -8
- package/dist/chunk-7F56LFN2.js +0 -17
- package/dist/chunk-B42VMENU.js +0 -9
- package/dist/chunk-IPOTBSM7.js +0 -6
- package/dist/chunk-LLMDC6IE.js +0 -17
- package/dist/chunk-ORLVNXTG.js +0 -8
- package/dist/chunk-YNOYR4WX.js +0 -7
- package/dist/{chunk-JTD47UZZ.js → chunk-TQKNFH6W.js} +1 -1
package/dist/chunk-7F56LFN2.js
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { a } from './chunk-NF42ENKE.js';
|
|
2
|
-
import { b } from './chunk-ILHUUK4X.js';
|
|
3
|
-
import O, { forwardRef, useState, useMemo, useEffect } from 'react';
|
|
4
|
-
import fe, { autocompleteClasses } from '@mui/material/Autocomplete';
|
|
5
|
-
import be from '@mui/material/CircularProgress';
|
|
6
|
-
import ge from '@mui/material/TextField';
|
|
7
|
-
import { VariableSizeList } from 'react-window';
|
|
8
|
-
import W from '@mui/material/Typography';
|
|
9
|
-
import re from '@mui/material/Divider';
|
|
10
|
-
import L from '@mui/material/Stack';
|
|
11
|
-
import te from '@mui/material/Popper';
|
|
12
|
-
import { styled } from '@mui/material/styles';
|
|
13
|
-
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
14
|
-
|
|
15
|
-
var H=styled(te)({[`& .${autocompleteClasses.listbox}`]:{boxSizing:"border-box","& ul":{padding:0,margin:0}}}),D=styled(L)(({theme:e})=>({flex:1,width:"100%",gap:6,[e.breakpoints.down("md")]:{flexDirection:"column"},[e.breakpoints.up("md")]:{flexDirection:"row"}})),T=styled(L)(({theme:e})=>({flex:1,maxWidth:"100%",gap:6,[e.breakpoints.up("md")]:{flex:"1 1 calc(50% - 8px)",width:"calc(50% - 8px)",minWidth:"calc(50% - 8px)",maxWidth:"calc(50% - 8px)"}})),R=styled(L)(({theme:e})=>({position:"relative",alignItems:"center",justifyContent:"center",width:68,height:68,borderRadius:8,overflow:"hidden",img:{position:"absolute",width:"100%",height:"100%",objectFit:"cover"},[e.breakpoints.down("sm")]:{display:"none"}}));var oe=({option:e})=>{let t=Object.keys(e).filter(l=>l.startsWith("field")).map((l,p)=>{let s=e[l];if(s&&typeof s=="object"){let m="label"in s?s.label:null,u="value"in s?s.value:null;return jsxs(W,{component:"span",variant:"body2",color:"textPrimary",noWrap:!0,children:[m,": ",u]},`${l}:${p}`)}}),i=e.image?jsx("img",{alt:"Imagem",src:e.image}):jsx(a,{alt:e.label||e.value.toString(),name:e.label||e.value.toString(),sx:{width:68,height:68,borderRadius:1}});return jsxs(Fragment,{children:[jsxs(L,{direction:"row",gap:2,margin:2,children:[jsx(R,{children:i}),jsxs(L,{flex:1,overflow:"hidden",children:[jsxs(W,{variant:"subtitle2",color:"textPrimary",noWrap:!0,flex:1,children:[e.value," - ",e.label]}),t.length>0&&jsxs(D,{width:1,children:[jsxs(T,{children:[t[0]?t[0]:void 0,t[1]?t[1]:void 0]}),(t[2]||t[3])&&jsxs(T,{children:[t[2]?t[2]:void 0,t[3]?t[3]:void 0]})]})]})]}),jsx(re,{className:"border",sx:{borderStyle:"dashed",position:"absolute",bottom:0,width:1}})]})},x=oe;var N=8,se=e=>{let{data:t,index:i,style:l}=e,p=t[i],s={...l,top:l.top+N,paddingTop:8,display:"block"};return jsx(W,{component:"li",...p.props,noWrap:!0,style:s,children:jsx(x,{...p?.props?.children?.props})})},X=O.createContext({}),B=forwardRef((e,t)=>{let i=O.useContext(X);return jsx("div",{ref:t,...e,...i})});B.displayName="OuterElementType";var me=e=>{let t=O.useRef(null);return useEffect(()=>{t.current!=null&&t.current.resetAfterIndex(0,!0);},[e]),t},pe=forwardRef(function(t,i){let{children:l,"data-item-height":p,...s}=t,m=[];l.forEach(a=>{m.push(a),m.push(...a.children||[]);});let u=m.length,g=p>112?p:112,c=a=>Object.prototype.hasOwnProperty.call(a,"group")?48:g,v=()=>u>8?8*g:m.map(c).reduce((a,C)=>a+C,0),S=me(u);return jsx("div",{ref:i,children:jsx(X.Provider,{value:s,children:jsx(VariableSizeList,{itemData:m,height:v()+2*N,width:"100%",ref:S,outerElementType:B,innerElementType:"ul",itemSize:a=>c(m[a]),overscanCount:5,itemCount:u,children:se})})})}),J=pe;var j=forwardRef(({label:e,value:t,options:i=[],loading:l,noOptionsText:p="Nenhum resultado encontrado.",loadingText:s="Carregando op\xE7\xF5es...",error:m,helperText:u,placeholder:g,onChange:c,groupBy:v,disabled:S,multiple:a,required:C,renderOption:G,tabIndex:U,onSearch:P,onInputChange:w,...V},_)=>{let[F,I]=useState(),q=b("down","md"),K=o=>o&&typeof o=="object"?o.value.toString():o.toString(),Q=useMemo(()=>a?(Array.isArray(t)?t:[]).reduce((r,A)=>{let E=i.find(Z=>Z.value.toString()===A.toString());return E?[...r,E]:[...r]},[]):i.find(n=>n.value.toString()===t?.toString())||null,[i,t,a]),Y=q&&i[0]?Object.keys(i[0]).length*24:void 0;return jsx(fe,{ref:_,value:F||Q,onInputChange:(o,n,r)=>{if(w&&w(o,n,r),r==="input"){P&&P(n),I(n);return}I(void 0);},options:i,loading:l,noOptionsText:p,loadingText:s,disabled:l||S,disableListWrap:!0,PopperComponent:H,ListboxProps:{"data-item-height":Y},ListboxComponent:G?void 0:J,filterOptions:(o,n)=>o.filter(r=>`${r.field1?.value} ${r.field1?.label} ${r.field2?.label} ${r.field2?.value} ${r.field3?.label} ${r.field3?.value} ${r.field4?.label} ${r.field4?.value} ${r.field5?.label} ${r.field5?.value} ${r.label}${r.value}`.toLocaleUpperCase().includes(n.inputValue.toLocaleUpperCase())),onChange:(o,n)=>{if(!n){c(a?[]:null);return}if(Array.isArray(n)){c(n.map(K));return}c(typeof n=="string"?n.toString():n.value.toString());},renderOption:({key:o,...n},r)=>jsx("li",{...n,style:{display:"block"},children:jsx(x,{option:r})},o),renderGroup:o=>o,groupBy:v,multiple:a,renderInput:o=>jsx(ge,{...o,placeholder:g,fullWidth:!0,error:!!m,helperText:u,label:e,required:C,InputProps:{...o.InputProps,endAdornment:jsxs(Fragment,{children:[l?jsx(be,{color:"primary",size:20}):null,o.InputProps.endAdornment]})},inputProps:{...o.inputProps,tabIndex:U}}),...V})});j.displayName="Autocomplete";var qe=j;
|
|
16
|
-
|
|
17
|
-
export { qe as a };
|
package/dist/chunk-B42VMENU.js
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { a as a$1 } from './chunk-MAK4JF5M.js';
|
|
2
|
-
import l from '@mui/material/IconButton';
|
|
3
|
-
import p from '@mui/material/Stack';
|
|
4
|
-
import { styled } from '@mui/material/styles';
|
|
5
|
-
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
6
|
-
|
|
7
|
-
var e=styled(l)(({theme:t})=>({position:"absolute",top:0,left:-2,zIndex:1,color:t.palette.grey[500],padding:"22px 5px",cursor:"grab","&:active":{cursor:"grabbing"}})),a=styled(p)({flexDirection:"row",alignItems:"center",justifyContent:"center",width:16,height:16,overflow:"hidden",transform:"scale(0.8)"});var s=({disableDrag:t,...i})=>t?null:jsx(e,{className:"dragIcon",disableRipple:!0,"aria-label":"Arrastar para ordenar",...i,children:jsxs(a,{children:[jsx(a$1,{sx:{marginLeft:0},icon:"MORE_BOLD",width:16}),jsx(a$1,{sx:{marginLeft:"-10px"},icon:"MORE_BOLD",width:16})]})}),D=s;
|
|
8
|
-
|
|
9
|
-
export { D as a };
|
package/dist/chunk-IPOTBSM7.js
DELETED
package/dist/chunk-LLMDC6IE.js
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { a } from './chunk-MAK4JF5M.js';
|
|
2
|
-
import { createContext, forwardRef, useContext, useState, useMemo, useRef, useEffect } from 'react';
|
|
3
|
-
import me, { autocompleteClasses } from '@mui/material/Autocomplete';
|
|
4
|
-
import le from '@mui/material/CircularProgress';
|
|
5
|
-
import ae from '@mui/material/TextField';
|
|
6
|
-
import { VariableSizeList } from 'react-window';
|
|
7
|
-
import Q from '@mui/material/ListSubheader';
|
|
8
|
-
import K from '@mui/material/Stack';
|
|
9
|
-
import { useTheme, styled } from '@mui/material/styles';
|
|
10
|
-
import I from '@mui/material/Typography';
|
|
11
|
-
import Z from '@mui/material/useMediaQuery';
|
|
12
|
-
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
13
|
-
import ne from '@mui/material/Popper';
|
|
14
|
-
|
|
15
|
-
var k=8,ee=u=>{let{data:r,index:i,style:m}=u,n=r[i],{showValueInLabel:s,key:c,...f}=n[0],l={...m,top:m.top+k,paddingTop:8};return Object.prototype.hasOwnProperty.call(n,"group")?jsx(Q,{component:"div",style:l,children:n.group},`list-box-item-group-${c}`):jsx(I,{component:"li",...f,noWrap:!0,style:l,children:jsxs(K,{component:"div",direction:"row",flex:1,gap:1,justifyContent:"start",children:[n[1].icon&&jsx(a,{icon:n[1].icon}),n[1].label,s&&jsxs(I,{variant:"inherit",color:"grey.400",children:["(",n[1].value,")"]})]})},`list-box-item-${c}`)},z=createContext({}),M=forwardRef((u,r)=>{let i=useContext(z);return jsx("div",{ref:r,...u,...i})});M.displayName="OuterElementType";var te=u=>{let r=useRef(null);return useEffect(()=>{r.current!=null&&r.current.resetAfterIndex(0,!0);},[u]),r},re=forwardRef(function(r,i){let{children:m,...n}=r,s=[];m.forEach(o=>{s.push(o),s.push(...o.children||[]);});let c=useTheme(),f=Z(c.breakpoints.up("sm")),l=s.length,d=f?36:48,g=o=>Object.prototype.hasOwnProperty.call(o,"group")?48:d,C=()=>l>8?8*d:s.map(g).reduce((o,P)=>o+P,0),L=te(l);return jsx("div",{ref:i,children:jsx(z.Provider,{value:n,children:jsx(VariableSizeList,{itemData:s,height:C()+2*k,width:"100%",ref:L,outerElementType:M,innerElementType:"ul",itemSize:o=>g(s[o]),overscanCount:5,itemCount:l,children:ee})})})}),N=re;var D=styled(ne)({[`& .${autocompleteClasses.listbox}`]:{boxSizing:"border-box","& ul":{padding:0,margin:0}}});var H=forwardRef(({label:u,value:r,options:i=[],loading:m,noOptionsText:n="Nenhum resultado encontrado.",loadingText:s="Carregando op\xE7\xF5es...",error:c,helperText:f,placeholder:l,onChange:d,groupBy:g,showValueInLabel:C,disabled:L,multiple:o,required:P,renderOption:x,tabIndex:X,onInputChange:A,onSearch:v,onBlur:E,InputLabelProps:J,...$},V)=>{let[U,T]=useState(),W=e=>e&&typeof e=="object"?e.value.toString():e.toString(),y=useMemo(()=>o?(Array.isArray(r)?r:[]).reduce((p,b)=>{let O=i.find(j=>j.value.toString()===b.toString());return O?[...p,O]:[...p]},[]):i.find(t=>t.value.toString()===r?.toString())||null,[i,r,o]);return jsx(me,{ref:V,value:U||y,onInputChange:(e,t,p)=>{if(A&&A(e,t,p),p==="input"){v&&(v(t),T(t));return}T(void 0);},options:i,loading:m,noOptionsText:n,loadingText:s,disabled:m||L,disableListWrap:!0,PopperComponent:D,ListboxComponent:x?void 0:N,filterOptions:(e,t)=>e.filter(p=>`${p.value} ${p.label}`.toLocaleUpperCase().includes(t.inputValue.toLocaleUpperCase())),onChange:(e,t)=>{if(!t){d(o?[]:null);return}if(Array.isArray(t)){d(t.map(W));return}d(typeof t=="string"?t.toString():t.value.toString());},onBlur:e=>{E&&E(e),T(void 0);},renderOption:(e,t,p,b)=>x?x(e,t,p,b):[{...e,showValueInLabel:C},t],renderGroup:e=>e,groupBy:g,multiple:o,renderInput:e=>jsx(ae,{...e,placeholder:l,fullWidth:!0,error:!!c,helperText:f,label:u,required:P,InputProps:{...e.InputProps,...!o&&{startAdornment:y&&!Array.isArray(y)&&y.icon?jsx(a,{icon:y.icon}):void 0},endAdornment:jsxs(Fragment,{children:[m?jsx(le,{color:"primary",size:20}):null,e.InputProps.endAdornment]})},inputProps:{...e.inputProps,tabIndex:X},InputLabelProps:J}),...$})});H.displayName="Autocomplete";var Xe=H;
|
|
16
|
-
|
|
17
|
-
export { Xe as a };
|
package/dist/chunk-ORLVNXTG.js
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import { forwardRef, useState } from 'react';
|
|
2
|
-
import { IMaskMixin } from 'react-imask';
|
|
3
|
-
import m from '@mui/material/TextField';
|
|
4
|
-
import { jsx } from 'react/jsx-runtime';
|
|
5
|
-
|
|
6
|
-
var k=IMaskMixin(a=>{let{inputRef:e,"data-value":p,defaultValue:u,tabIndex:s,...t}=a;return jsx(m,{inputRef:e,fullWidth:!0,...t,inputProps:{...t.inputProps,tabIndex:s},value:p,"data-testid":"masked-input-wrapper"})}),n=forwardRef(({onChange:a,name:e,...p},u)=>{let[s,t]=useState("");return jsx(k,{inputRef:u,name:e,"data-value":s,...p,onAccept:(r,o)=>{t(r),a({target:{name:e,value:o._unmaskedValue}});}})});n.displayName="MaskedInput";var P=n;
|
|
7
|
-
|
|
8
|
-
export { P as a };
|
package/dist/chunk-YNOYR4WX.js
DELETED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { useFormContext, Controller } from 'react-hook-form';
|
|
2
|
-
import g from '@mui/material/TextField';
|
|
3
|
-
import { jsx } from 'react/jsx-runtime';
|
|
4
|
-
|
|
5
|
-
var C=({name:l,helperText:t,rules:n,onChange:r,tabIndex:m,className:u,id:a,forceShowHelperText:d,...e})=>{let{control:f}=useFormContext();return jsx(Controller,{name:l,control:f,rules:n,render:({field:{ref:F,value:P,...p},fieldState:{error:o}})=>jsx(g,{...p,value:P??"",onChange:s=>{p.onChange(s),r&&r(s);},inputRef:F,fullWidth:!0,error:!!o,helperText:d?t||o?.message:o?.message||t,"data-intercom-target":l,...e,InputLabelProps:{...e.InputLabelProps,htmlFor:a},inputProps:{...e.inputProps,tabIndex:m,"aria-label":e.label,id:a},className:`field-${l} ${u}`})})},L=C;
|
|
6
|
-
|
|
7
|
-
export { L as a };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { a } from './chunk-FK7DDO5L.js';
|
|
2
1
|
import { a as a$1 } from './chunk-PUR4ARBY.js';
|
|
2
|
+
import { a } from './chunk-FK7DDO5L.js';
|
|
3
3
|
import x, { useState } from 'react';
|
|
4
4
|
import { GRID_CHECKBOX_SELECTION_COL_DEF, DataGridPremium, GridToolbarContainer, GridToolbarColumnsButton, GridToolbarFilterButton, GridToolbarDensitySelector, GridToolbarExport, useGridApiContext, useGridRootProps, gridColumnsTotalWidthSelector, gridColumnPositionsSelector } from '@mui/x-data-grid-premium';
|
|
5
5
|
import E from '@mui/material/Box';
|