@zydon/common 2.1.88 → 2.1.90
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-HLUQMO6K.js → chunk-3YZHNOL6.js} +2 -2
- package/dist/chunk-ANAHA3L6.js +3 -0
- package/dist/chunk-FMUKZOVG.js +17 -0
- package/dist/{chunk-ZXSJOGEK.js → chunk-H3BSTE4Q.js} +1 -1
- package/dist/{chunk-B5ZOMQSS.js → chunk-JBH4Q2LO.js} +2 -2
- package/dist/chunk-WVDC62Z6.js +12 -0
- package/dist/{chunk-OBGBWREO.js → chunk-XQYZ3UC2.js} +1 -1
- package/dist/components/Autocomplete/index.js +1 -1
- package/dist/components/Incrementer/index.js +2 -2
- package/dist/components/form/Address/index.js +2 -2
- package/dist/components/form/Autocomplete/index.js +2 -2
- package/dist/components/form/Incrementer/index.js +2 -2
- package/dist/components/form/UploadAvatarWithCrop/index.js +3 -3
- package/dist/components/form/UploadWithCrop/index.js +3 -3
- package/dist/components/form/Webhook/index.js +2 -2
- package/dist/components/upload/index.js +4 -4
- package/dist/utils/formatNumber.d.ts +1 -1
- package/dist/utils/formatNumber.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-HIZ3EEIX.js +0 -3
- package/dist/chunk-MRYCD62T.js +0 -17
- package/dist/chunk-UDH5COZZ.js +0 -12
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { c, f } from './chunk-
|
|
1
|
+
import { c, f } from './chunk-XQYZ3UC2.js';
|
|
2
2
|
import { a as a$3 } from './chunk-KVL7ASVR.js';
|
|
3
|
-
import { e } from './chunk-
|
|
3
|
+
import { e } from './chunk-ANAHA3L6.js';
|
|
4
4
|
import { i } from './chunk-D27ND54J.js';
|
|
5
5
|
import { a } from './chunk-4Z2JJGWA.js';
|
|
6
6
|
import { a as a$2 } from './chunk-KFZEM7KS.js';
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
var i={code:"pt-BR",currency:"BRL"};function u(t){return t==null||Number.isNaN(t)?null:Number(t)}function s(t,n){let e=i,r=u(t);return r===null?"":new Intl.NumberFormat(e.code,{minimumFractionDigits:0,maximumFractionDigits:2,...n}).format(r)}function a(t,n){let e=i,r=u(t);return r===null?"":new Intl.NumberFormat(e.code,{style:"currency",currency:e.currency,minimumFractionDigits:0,maximumFractionDigits:2,...n}).format(r)}function l(t,n){let e=i,r=u(t);return r===null?"":new Intl.NumberFormat(e.code,{style:"percent",minimumFractionDigits:0,maximumFractionDigits:1,...n}).format(r/100)}function f(t,n){let e=i,r=u(t);return r===null?"":new Intl.NumberFormat(e.code,{notation:"compact",maximumFractionDigits:2,...n}).format(r).replace(/[A-Z]/g,m=>m.toLowerCase())}function b(t){let n=u(t);if(n===null||n===0)return "0 bytes";let e=["bytes","Kb","Mb","Gb","Tb","Pb","Eb","Zb","Yb"],r=2,o=1024,m=Math.floor(Math.log(n)/Math.log(o));return `${parseFloat((n/o**m).toFixed(r))} ${e[m]}`}var p=(t,n=12)=>+Number(t).toFixed(n);function N(t){return t===0||t==="0"?"0":typeof t=="string"?t.padStart(2,"0"):t.toString().padStart(2,"0")}var g=t=>new Intl.NumberFormat("pt-BR",{style:"currency",currency:"BRL"}).format(t||0);
|
|
2
|
+
|
|
3
|
+
export { s as a, a as b, l as c, f as d, b as e, p as f, N as g, g as h };
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { a } from './chunk-4Z2JJGWA.js';
|
|
2
|
+
import { createContext, forwardRef, useContext, useMemo, useRef, useEffect } from 'react';
|
|
3
|
+
import ne, { autocompleteClasses } from '@mui/material/Autocomplete';
|
|
4
|
+
import ie from '@mui/material/CircularProgress';
|
|
5
|
+
import se from '@mui/material/TextField';
|
|
6
|
+
import { VariableSizeList } from 'react-window';
|
|
7
|
+
import G from '@mui/material/ListSubheader';
|
|
8
|
+
import _ from '@mui/material/Stack';
|
|
9
|
+
import { useTheme, styled } from '@mui/material/styles';
|
|
10
|
+
import v from '@mui/material/Typography';
|
|
11
|
+
import F from '@mui/material/useMediaQuery';
|
|
12
|
+
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
13
|
+
import ee from '@mui/material/Popper';
|
|
14
|
+
|
|
15
|
+
var I=8,Q=m=>{let{data:o,index:s,style:p}=m,n=o[s],{showValueInLabel:i,...f}=n[0],c={...p,top:p.top+I,paddingTop:8};return Object.prototype.hasOwnProperty.call(n,"group")?jsx(G,{component:"div",style:c,children:n.group},n.key):jsx(v,{component:"li",...f,noWrap:!0,style:c,children:jsxs(_,{component:"div",direction:"row",flex:1,gap:1,justifyContent:"start",children:[n[1].icon&&jsx(a,{icon:n[1].icon}),n[1].label,i&&jsxs(v,{variant:"inherit",color:"grey.400",children:["(",n[1].value,")"]})]})})},R=createContext({}),z=forwardRef((m,o)=>{let s=useContext(R);return jsx("div",{ref:o,...m,...s})});z.displayName="OuterElementType";var K=m=>{let o=useRef(null);return useEffect(()=>{o.current!=null&&o.current.resetAfterIndex(0,!0);},[m]),o},Y=forwardRef(function(o,s){let{children:p,...n}=o,i=[];p.forEach(r=>{i.push(r),i.push(...r.children||[]);});let f=useTheme(),c=F(f.breakpoints.up("sm")),y=i.length,l=c?36:48,h=r=>Object.prototype.hasOwnProperty.call(r,"group")?48:l,C=()=>y>8?8*l:i.map(h).reduce((r,P)=>r+P,0),L=K(y);return jsx("div",{ref:s,children:jsx(R.Provider,{value:n,children:jsx(VariableSizeList,{itemData:i,height:C()+2*I,width:"100%",ref:L,outerElementType:z,innerElementType:"ul",itemSize:r=>h(i[r]),overscanCount:5,itemCount:y,children:Q})})})}),M=Y;var k=styled(ee)({[`& .${autocompleteClasses.listbox}`]:{boxSizing:"border-box","& ul":{padding:0,margin:0}}});var N=forwardRef(({label:m,value:o,options:s=[],loading:p,noOptionsText:n="Nenhum resultado encontrado.",loadingText:i="Carregando op\xE7\xF5es...",error:f,helperText:c,placeholder:y,onChange:l,groupBy:h,showValueInLabel:C,disabled:L,multiple:r,required:P,renderOption:x,tabIndex:D,onInputChange:A,onSearch:T,...H},X)=>{let J=e=>e&&typeof e=="object"?e.value.toString():e.toString(),d=useMemo(()=>r?(Array.isArray(o)?o:[]).reduce((u,b)=>{let E=s.find(V=>V.value.toString()===b.toString());return E?[...u,E]:[...u]},[]):s.find(t=>t.value.toString()===o?.toString())||null,[s,o,r]);return jsx(ne,{ref:X,value:d,onInputChange:(e,t,u)=>{!p&&!d&&l(r?[]:null),A&&A(e,t,u),T&&e&&(e.type==="change"||e.type==="blur")&&T(t);},options:s,loading:p,noOptionsText:p?i:n,loadingText:i,disabled:p||L,disableListWrap:!0,PopperComponent:k,ListboxComponent:x?void 0:M,filterOptions:(e,t)=>e.filter(u=>`${u.value} ${u.label}`.toLocaleUpperCase().includes(t.inputValue.toLocaleUpperCase())),onChange:(e,t)=>{if(!t){l(r?[]:null);return}if(Array.isArray(t)){l(t.map(J));return}l(typeof t=="string"?t.toString():t.value.toString());},renderOption:(e,t,u,b)=>x?x(e,t,u,b):[{...e,showValueInLabel:C},t],renderGroup:e=>e,groupBy:h,multiple:r,renderInput:e=>jsx(se,{...e,placeholder:y,fullWidth:!0,error:!!f,helperText:c,label:m,required:P,InputProps:{...e.InputProps,...!r&&{startAdornment:d&&!Array.isArray(d)&&d.icon?jsx(a,{icon:d.icon}):void 0},endAdornment:jsxs(Fragment,{children:[p?jsx(ie,{color:"primary",size:20}):null,e.InputProps.endAdornment]})},inputProps:{...e.inputProps,tabIndex:D}}),...H})});N.displayName="Autocomplete";var Me=N;
|
|
16
|
+
|
|
17
|
+
export { Me as a };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { a, b, c } from './chunk-
|
|
2
|
-
import { e } from './chunk-
|
|
1
|
+
import { a, b, c } from './chunk-XQYZ3UC2.js';
|
|
2
|
+
import { e } from './chunk-ANAHA3L6.js';
|
|
3
3
|
import { j } from './chunk-OJKIWVED.js';
|
|
4
4
|
import { i } from './chunk-D27ND54J.js';
|
|
5
5
|
import { a as a$1 } from './chunk-4Z2JJGWA.js';
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { a } from './chunk-TLENQZN5.js';
|
|
2
|
+
import { f } from './chunk-ANAHA3L6.js';
|
|
3
|
+
import { a as a$1 } from './chunk-PV522B4W.js';
|
|
4
|
+
import { a as a$2 } from './chunk-4Z2JJGWA.js';
|
|
5
|
+
import { forwardRef } from 'react';
|
|
6
|
+
import k from '@mui/material/IconButton';
|
|
7
|
+
import D from '@mui/material/InputAdornment';
|
|
8
|
+
import { jsx } from 'react/jsx-runtime';
|
|
9
|
+
|
|
10
|
+
var w=forwardRef(({name:N,increment:t=1,updadteForMultiple:l,allowNegative:u=!1,value:e=0,onChange:r,minValue:n,maxValue:s,decimalScale:p,disabled:I,tabIndex:b,...y},g)=>{let M=a(e,t,p);return jsx(a$1,{ref:g,name:N,value:e,minValue:n,maxValue:s,allowNegative:u,decimalScale:p,InputProps:{startAdornment:jsx(D,{position:"start",children:jsx(k,{size:"medium",disabled:I||(u?!1:!e),onClick:()=>{if(!u&&e-t<0)return;let i=e-t,o=Math.floor(e/t)*t,f$1=!M&&l?o:i;n!==void 0&&i<n?r(n):r(f(f$1,p));},children:jsx(a$2,{icon:"MINUS_SIGN",width:14,height:14,color:"primary.main"})})}),endAdornment:jsx(D,{position:"end",children:jsx(k,{size:"medium",onClick:()=>{let i=Number(e)+t,o=Math.ceil(e/t)*t,c=f(!M&&l?o:i,p);s!==void 0&&i>=s?r(s):r(n!==void 0&&c<=n?n:c);},disabled:I,children:jsx(a$2,{icon:"SIMPLE_ADD",width:14,height:14,color:"primary.main"})})}),inputProps:{style:{textAlign:"center"}}},inputProps:{tabIndex:b},onChange:i=>{let o=f(i.target.value||0,p),f$1=Math.ceil(o/t)*t,c=l?f$1:o;if(n!==void 0&&o<=n){r(n);return}if(s!==void 0&&o>=s){r(s);return}r(c);},disabled:I,...y})});w.displayName="Incrementer";var T=w;
|
|
11
|
+
|
|
12
|
+
export { T as a };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { a as default } from '../../chunk-
|
|
1
|
+
export { a as default } from '../../chunk-WVDC62Z6.js';
|
|
2
2
|
import '../../chunk-TLENQZN5.js';
|
|
3
|
-
import '../../chunk-
|
|
3
|
+
import '../../chunk-ANAHA3L6.js';
|
|
4
4
|
import '../../chunk-PV522B4W.js';
|
|
5
5
|
import '../../chunk-4Z2JJGWA.js';
|
|
6
6
|
import '../../chunk-QDDGXWNG.js';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { a as a$2 } from '../../../chunk-P46BBUKR.js';
|
|
2
2
|
import { a as a$1 } from '../../../chunk-U7BKKRLD.js';
|
|
3
|
-
import { a as a$3 } from '../../../chunk-
|
|
3
|
+
import { a as a$3 } from '../../../chunk-H3BSTE4Q.js';
|
|
4
4
|
import '../../../chunk-QNAXGE5H.js';
|
|
5
|
-
import '../../../chunk-
|
|
5
|
+
import '../../../chunk-FMUKZOVG.js';
|
|
6
6
|
import '../../../chunk-4Z2JJGWA.js';
|
|
7
7
|
import '../../../chunk-QDDGXWNG.js';
|
|
8
8
|
import E from '@mui/material/CircularProgress';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { a as default } from '../../../chunk-
|
|
2
|
-
import '../../../chunk-
|
|
1
|
+
export { a as default } from '../../../chunk-H3BSTE4Q.js';
|
|
2
|
+
import '../../../chunk-FMUKZOVG.js';
|
|
3
3
|
import '../../../chunk-4Z2JJGWA.js';
|
|
4
4
|
import '../../../chunk-QDDGXWNG.js';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { a } from '../../../chunk-
|
|
1
|
+
import { a } from '../../../chunk-WVDC62Z6.js';
|
|
2
2
|
import '../../../chunk-TLENQZN5.js';
|
|
3
|
-
import '../../../chunk-
|
|
3
|
+
import '../../../chunk-ANAHA3L6.js';
|
|
4
4
|
import '../../../chunk-PV522B4W.js';
|
|
5
5
|
import '../../../chunk-4Z2JJGWA.js';
|
|
6
6
|
import '../../../chunk-QDDGXWNG.js';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { b } from '../../../chunk-
|
|
2
|
-
import '../../../chunk-
|
|
1
|
+
import { b } from '../../../chunk-3YZHNOL6.js';
|
|
2
|
+
import '../../../chunk-XQYZ3UC2.js';
|
|
3
3
|
import '../../../chunk-KVL7ASVR.js';
|
|
4
4
|
import '../../../chunk-QQ3PMR6M.js';
|
|
5
5
|
import '../../../chunk-T7I256S6.js';
|
|
6
|
-
import '../../../chunk-
|
|
6
|
+
import '../../../chunk-ANAHA3L6.js';
|
|
7
7
|
import '../../../chunk-D27ND54J.js';
|
|
8
8
|
import '../../../chunk-4Z2JJGWA.js';
|
|
9
9
|
import '../../../chunk-QDDGXWNG.js';
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { d as d$1 } from '../../../chunk-
|
|
2
|
-
import { d, e as e$1 } from '../../../chunk-
|
|
1
|
+
import { d as d$1 } from '../../../chunk-JBH4Q2LO.js';
|
|
2
|
+
import { d, e as e$1 } from '../../../chunk-XQYZ3UC2.js';
|
|
3
3
|
import { a as a$5 } from '../../../chunk-KVL7ASVR.js';
|
|
4
4
|
import '../../../chunk-QQ3PMR6M.js';
|
|
5
5
|
import '../../../chunk-T7I256S6.js';
|
|
6
|
-
import { e } from '../../../chunk-
|
|
6
|
+
import { e } from '../../../chunk-ANAHA3L6.js';
|
|
7
7
|
import { a as a$3 } from '../../../chunk-YWEB6IAI.js';
|
|
8
8
|
import '../../../chunk-OJKIWVED.js';
|
|
9
9
|
import '../../../chunk-D27ND54J.js';
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { a } from '../../../chunk-P46BBUKR.js';
|
|
2
|
-
import { a as a$2 } from '../../../chunk-
|
|
2
|
+
import { a as a$2 } from '../../../chunk-H3BSTE4Q.js';
|
|
3
3
|
import { a as a$3 } from '../../../chunk-AKR4HFCK.js';
|
|
4
|
-
import '../../../chunk-
|
|
4
|
+
import '../../../chunk-FMUKZOVG.js';
|
|
5
5
|
import { a as a$1 } from '../../../chunk-4Z2JJGWA.js';
|
|
6
6
|
import '../../../chunk-QDDGXWNG.js';
|
|
7
7
|
import { useFormContext, useFieldArray } from 'react-hook-form';
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
export { a as UploadAvatar, b as UploadAvatarWithCrop, b as UploadWithCrop } from '../../chunk-
|
|
2
|
-
export { c as DeleteButton, a as MultiFilePreview, b as SingleFilePreview, d as Upload } from '../../chunk-
|
|
3
|
-
export { c as RejectionFiles } from '../../chunk-
|
|
1
|
+
export { a as UploadAvatar, b as UploadAvatarWithCrop, b as UploadWithCrop } from '../../chunk-3YZHNOL6.js';
|
|
2
|
+
export { c as DeleteButton, a as MultiFilePreview, b as SingleFilePreview, d as Upload } from '../../chunk-JBH4Q2LO.js';
|
|
3
|
+
export { c as RejectionFiles } from '../../chunk-XQYZ3UC2.js';
|
|
4
4
|
import '../../chunk-KVL7ASVR.js';
|
|
5
5
|
import '../../chunk-QQ3PMR6M.js';
|
|
6
6
|
import '../../chunk-T7I256S6.js';
|
|
7
|
-
import '../../chunk-
|
|
7
|
+
import '../../chunk-ANAHA3L6.js';
|
|
8
8
|
import '../../chunk-OJKIWVED.js';
|
|
9
9
|
import { i } from '../../chunk-D27ND54J.js';
|
|
10
10
|
import '../../chunk-4Z2JJGWA.js';
|
|
@@ -5,7 +5,7 @@ declare function fCurrency(inputValue: InputNumberValue, options?: Options): str
|
|
|
5
5
|
declare function fPercent(inputValue: InputNumberValue, options?: Options): string;
|
|
6
6
|
declare function fShortenNumber(inputValue: InputNumberValue, options?: Options): string;
|
|
7
7
|
declare function fData(inputValue: InputNumberValue): string;
|
|
8
|
-
declare const fWithDecimalPlacesOrNot: (value: string | number) => number;
|
|
8
|
+
declare const fWithDecimalPlacesOrNot: (value: string | number, decimalPlaces?: number) => number;
|
|
9
9
|
declare function fTwoDigits(value: number | string): string;
|
|
10
10
|
declare const fCurrencyBRL: (value?: number | null) => string;
|
|
11
11
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { b as fCurrency, h as fCurrencyBRL, e as fData, a as fNumber, c as fPercent, d as fShortenNumber, g as fTwoDigits, f as fWithDecimalPlacesOrNot } from '../chunk-
|
|
1
|
+
export { b as fCurrency, h as fCurrencyBRL, e as fData, a as fNumber, c as fPercent, d as fShortenNumber, g as fTwoDigits, f as fWithDecimalPlacesOrNot } from '../chunk-ANAHA3L6.js';
|
package/package.json
CHANGED
package/dist/chunk-HIZ3EEIX.js
DELETED
|
@@ -1,3 +0,0 @@
|
|
|
1
|
-
var i={code:"pt-BR",currency:"BRL"};function u(t){return t==null||Number.isNaN(t)?null:Number(t)}function s(t,r){let e=i,n=u(t);return n===null?"":new Intl.NumberFormat(e.code,{minimumFractionDigits:0,maximumFractionDigits:2,...r}).format(n)}function a(t,r){let e=i,n=u(t);return n===null?"":new Intl.NumberFormat(e.code,{style:"currency",currency:e.currency,minimumFractionDigits:0,maximumFractionDigits:2,...r}).format(n)}function l(t,r){let e=i,n=u(t);return n===null?"":new Intl.NumberFormat(e.code,{style:"percent",minimumFractionDigits:0,maximumFractionDigits:1,...r}).format(n/100)}function f(t,r){let e=i,n=u(t);return n===null?"":new Intl.NumberFormat(e.code,{notation:"compact",maximumFractionDigits:2,...r}).format(n).replace(/[A-Z]/g,m=>m.toLowerCase())}function b(t){let r=u(t);if(r===null||r===0)return "0 bytes";let e=["bytes","Kb","Mb","Gb","Tb","Pb","Eb","Zb","Yb"],n=2,o=1024,m=Math.floor(Math.log(r)/Math.log(o));return `${parseFloat((r/o**m).toFixed(n))} ${e[m]}`}var p=t=>+Number(t).toFixed(12);function N(t){return t===0||t==="0"?"0":typeof t=="string"?t.padStart(2,"0"):t.toString().padStart(2,"0")}var g=t=>new Intl.NumberFormat("pt-BR",{style:"currency",currency:"BRL"}).format(t||0);
|
|
2
|
-
|
|
3
|
-
export { s as a, a as b, l as c, f as d, b as e, p as f, N as g, g as h };
|
package/dist/chunk-MRYCD62T.js
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { a } from './chunk-4Z2JJGWA.js';
|
|
2
|
-
import { createContext, forwardRef, useContext, useMemo, useRef, useEffect } from 'react';
|
|
3
|
-
import ne, { autocompleteClasses } from '@mui/material/Autocomplete';
|
|
4
|
-
import ie from '@mui/material/CircularProgress';
|
|
5
|
-
import se from '@mui/material/TextField';
|
|
6
|
-
import { VariableSizeList } from 'react-window';
|
|
7
|
-
import G from '@mui/material/ListSubheader';
|
|
8
|
-
import _ from '@mui/material/Stack';
|
|
9
|
-
import { useTheme, styled } from '@mui/material/styles';
|
|
10
|
-
import v from '@mui/material/Typography';
|
|
11
|
-
import F from '@mui/material/useMediaQuery';
|
|
12
|
-
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
13
|
-
import ee from '@mui/material/Popper';
|
|
14
|
-
|
|
15
|
-
var I=8,Q=m=>{let{data:o,index:i,style:p}=m,n=o[i],{showValueInLabel:s,...f}=n[0],c={...p,top:p.top+I,paddingTop:8};return Object.prototype.hasOwnProperty.call(n,"group")?jsx(G,{component:"div",style:c,children:n.group},n.key):jsx(v,{component:"li",...f,noWrap:!0,style:c,children:jsxs(_,{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(v,{variant:"inherit",color:"grey.400",children:["(",n[1].value,")"]})]})})},R=createContext({}),z=forwardRef((m,o)=>{let i=useContext(R);return jsx("div",{ref:o,...m,...i})});z.displayName="OuterElementType";var K=m=>{let o=useRef(null);return useEffect(()=>{o.current!=null&&o.current.resetAfterIndex(0,!0);},[m]),o},Y=forwardRef(function(o,i){let{children:p,...n}=o,s=[];p.forEach(r=>{s.push(r),s.push(...r.children||[]);});let f=useTheme(),c=F(f.breakpoints.up("sm")),y=s.length,l=c?36:48,h=r=>Object.prototype.hasOwnProperty.call(r,"group")?48:l,C=()=>y>8?8*l:s.map(h).reduce((r,P)=>r+P,0),L=K(y);return jsx("div",{ref:i,children:jsx(R.Provider,{value:n,children:jsx(VariableSizeList,{itemData:s,height:C()+2*I,width:"100%",ref:L,outerElementType:z,innerElementType:"ul",itemSize:r=>h(s[r]),overscanCount:5,itemCount:y,children:Q})})})}),M=Y;var k=styled(ee)({[`& .${autocompleteClasses.listbox}`]:{boxSizing:"border-box","& ul":{padding:0,margin:0}}});var N=forwardRef(({label:m,value:o,options:i=[],loading:p,noOptionsText:n="Nenhuma resultado encontrado.",loadingText:s="Carregando op\xE7\xF5es...",error:f,helperText:c,placeholder:y,onChange:l,groupBy:h,showValueInLabel:C,disabled:L,multiple:r,required:P,renderOption:x,tabIndex:D,onInputChange:T,onSearch:A,...H},X)=>{let J=e=>e&&typeof e=="object"?e.value.toString():e.toString(),d=useMemo(()=>r?(Array.isArray(o)?o:[]).reduce((u,g)=>{let E=i.find(V=>V.value.toString()===g.toString());return E?[...u,E]:[...u]},[]):i.find(t=>t.value.toString()===o?.toString())||null,[i,o,r]);return jsx(ne,{ref:X,value:d,onInputChange:(e,t,u)=>{!p&&!d&&l(r?[]:null),T&&T(e,t,u),A&&e&&(e.type==="change"||e.type==="blur")&&A(t);},options:i,loading:p,noOptionsText:n,loadingText:s,disabled:p||L,disableListWrap:!0,PopperComponent:k,ListboxComponent:x?void 0:M,filterOptions:(e,t)=>e.filter(u=>`${u.value} ${u.label}`.toLocaleUpperCase().includes(t.inputValue.toLocaleUpperCase())),onChange:(e,t)=>{if(!t){l(r?[]:null);return}if(Array.isArray(t)){l(t.map(J));return}l(typeof t=="string"?t.toString():t.value.toString());},renderOption:(e,t,u,g)=>x?x(e,t,u,g):[{...e,showValueInLabel:C},t],renderGroup:e=>e,groupBy:h,multiple:r,renderInput:e=>jsx(se,{...e,placeholder:y,fullWidth:!0,error:!!f,helperText:c,label:m,required:P,InputProps:{...e.InputProps,...!r&&{startAdornment:d&&!Array.isArray(d)&&d.icon?jsx(a,{icon:d.icon}):void 0},endAdornment:jsxs(Fragment,{children:[p?jsx(ie,{color:"primary",size:20}):null,e.InputProps.endAdornment]})},inputProps:{...e.inputProps,tabIndex:D}}),...H})});N.displayName="Autocomplete";var Me=N;
|
|
16
|
-
|
|
17
|
-
export { Me as a };
|
package/dist/chunk-UDH5COZZ.js
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { a } from './chunk-TLENQZN5.js';
|
|
2
|
-
import { f } from './chunk-HIZ3EEIX.js';
|
|
3
|
-
import { a as a$1 } from './chunk-PV522B4W.js';
|
|
4
|
-
import { a as a$2 } from './chunk-4Z2JJGWA.js';
|
|
5
|
-
import { forwardRef } from 'react';
|
|
6
|
-
import P from '@mui/material/IconButton';
|
|
7
|
-
import k from '@mui/material/InputAdornment';
|
|
8
|
-
import { jsx } from 'react/jsx-runtime';
|
|
9
|
-
|
|
10
|
-
var D=forwardRef(({name:N,increment:t=1,updadteForMultiple:f$1,allowNegative:l=!1,value:n=0,onChange:r,minValue:e,maxValue:s,decimalScale:h,disabled:m,tabIndex:b,...w},y)=>{let M=a(n,t,h);return jsx(a$1,{ref:y,name:N,value:n,minValue:e,maxValue:s,allowNegative:l,decimalScale:h,InputProps:{startAdornment:jsx(k,{position:"start",children:jsx(P,{size:"medium",disabled:m||(l?!1:!n),onClick:()=>{if(!l&&n-t<0)return;let i=n-t,o=Math.floor(n/t)*t,d=!M&&f$1?o:i;e!==void 0&&i<e?r(e):r(f(d));},children:jsx(a$2,{icon:"MINUS_SIGN",width:14,height:14,color:"primary.main"})})}),endAdornment:jsx(k,{position:"end",children:jsx(P,{size:"medium",onClick:()=>{let i=Number(n)+t,o=Math.ceil(n/t)*t,p=f(!M&&f$1?o:i);s!==void 0&&i>=s?r(s):r(e!==void 0&&p<=e?e:p);},disabled:m,children:jsx(a$2,{icon:"SIMPLE_ADD",width:14,height:14,color:"primary.main"})})}),inputProps:{style:{textAlign:"center"}}},inputProps:{tabIndex:b},onChange:i=>{let o=Number(i.target.value),d=Math.ceil(o/t)*t,p=f$1?d:o;if(e!==void 0&&o<=e){r(e);return}if(s!==void 0&&o>=s){r(s);return}r(p);},disabled:m,...w})});D.displayName="Incrementer";var R=D;
|
|
11
|
-
|
|
12
|
-
export { R as a };
|