@zydon/common 2.5.13 → 2.5.15

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.
@@ -0,0 +1,11 @@
1
+ import { a } from './chunk-MAK4JF5M.js';
2
+ import { forwardRef, useMemo } from 'react';
3
+ import p from '@mui/material/Box';
4
+ import S from '@mui/material/CircularProgress';
5
+ import b from '@mui/material/IconButton';
6
+ import k from '@mui/material/Tooltip';
7
+ import { jsx } from 'react/jsx-runtime';
8
+
9
+ var f=forwardRef(({icon:t,label:i,color:s="primary",loading:e=!1,disabled:B=!1,boxProps:n={},tooltipProps:I={},iconProps:c={},disableTooltip:d=!1,children:r,...h},M)=>{if(!t&&!r)throw new Error("IconButton: icon or children is required");let a$1=useMemo(()=>t?jsx(a,{icon:t,...c}):r,[t,r,c]),T=useMemo(()=>e?jsx(S,{size:20,color:"inherit"}):a$1,[e,a$1]),l=jsx(b,{ref:M,"aria-label":i,color:"inherit",disabled:e||B,...h,children:T});return d?jsx(p,{...n,color:s,children:l}):jsx(p,{...n,color:s,sx:{...n.sx,"@media (pointer:coarse)":{userSelect:"none",WebkitUserSelect:"none",MozUserSelect:"none",msUserSelect:"none",WebkitTouchCallout:"none",WebkitTapHighlightColor:"transparent",touchAction:"none","&:active":{pointerEvents:"none"}}},children:jsx(k,{"data-testid":"button-tooltip",...I,title:i,children:jsx("span",{children:l})})})});f.displayName="IconButton";var v=f;
10
+
11
+ export { v as a };
@@ -0,0 +1,15 @@
1
+ import { e } from './chunk-ANAHA3L6.js';
2
+ import { i as i$1 } from './chunk-D27ND54J.js';
3
+ import x from '@mui/material/Box';
4
+ import D from '@mui/material/Paper';
5
+ import z from '@mui/material/Typography';
6
+ import { jsx, jsxs } from 'react/jsx-runtime';
7
+ import E from '@mui/material/CircularProgress';
8
+ import i from '@mui/material/IconButton';
9
+ import l from '@mui/material/Stack';
10
+ import { styled, alpha } from '@mui/material/styles';
11
+ import { m } from 'framer-motion';
12
+
13
+ var y=["pdf"],f=["txt"],h=["psd"],k=["doc","docx"],I=["xls","xlsx"],v=["zip","rar","iso"],w=["ai","esp"],C=["ppt","pptx"],F=["wav","aif","mp3","aac"],T=["jpg","jpeg","gif","bmp","png","svg","webp"],R=["m4v","avi","mpg","mp4","webm"];function O(o){let e,t=s(o);switch(o.includes(t)){case f.includes(t):e="txt";break;case v.includes(t):e="zip";break;case F.includes(t):e="audio";break;case T.includes(t):e="image";break;case R.includes(t):e="video";break;case k.includes(t):e="word";break;case I.includes(t):e="excel";break;case C.includes(t):e="powerpoint";break;case y.includes(t):e="pdf";break;case h.includes(t):e="photoshop";break;case w.includes(t):e="illustrator";break;case o?.startsWith("http"):e="image";break;default:e=s(o);}return e}function B(o){let e;switch(O(o)){case"folder":e="IC_FOLDER";break;case"txt":e="IC_TXT";break;case"zip":e="IC_ZIP";break;case"audio":e="IC_AUDIO";break;case"video":e="IC_VIDEO";break;case"word":e="IC_WORD";break;case"excel":e="IC_EXCEL";break;case"powerpoint":e="IC_POWER_POINT";break;case"pdf":e="IC_PDF";break;case"photoshop":e="IC_PTS";break;case"illustrator":e="IC_AI";break;case"image":e="IC_IMG";break;default:e="IC_FILE";}return e}function s(o){return o&&o.split(".").pop()||""}function _(o){return o.split("/").pop()}function g(o){return typeof o=="string"?{key:o,preview:o,name:_(o),type:s(o),size:void 0,path:o,lastModified:void 0,lastModifiedDate:void 0}:{key:`key:${o.name}`,name:o.name,size:o.size,path:o.path,type:o.type,preview:o.preview,lastModified:o.lastModified,lastModifiedDate:o.lastModifiedDate}}function N({files:o}){return o.length?jsx(D,{variant:"outlined",sx:{py:1,px:2,mt:3,textAlign:"left",borderStyle:"dashed",borderColor:"error.main",bgcolor:e=>i$1(e.vars.palette.error.mainChannel,.08)},children:o.map(({file:e$1,errors:t})=>{let{path:n,size:d}=g(e$1),m=d?e(d):"";return jsxs(x,{sx:{my:1},children:[jsxs(z,{variant:"subtitle2",noWrap:!0,children:[n," - ",m," "]}),t.map(c=>jsxs(x,{component:"span",sx:{typography:"caption"},children:["- ",c.message]},c.code))]},n)})}):null}var Y=styled(l)({position:"relative",width:"100%",borderRadius:8,overflow:"hidden","&:hover .actions":{display:"flex"}}),oo=styled(l)(({theme:o})=>({display:"none",position:"absolute",alignItems:"center",justifyContent:"center",flexDirection:"row",gap:12,width:"100%",height:"100%",backgroundColor:alpha(o.palette.primary.main,.9),zIndex:999,button:{"&, &:hover, &:focus":{backgroundColor:"#fff"}}})),eo=styled(E)({position:"absolute",width:"100%",height:"100%",zIndex:99,backgroundColor:"#fff",borderRadius:"50%"}),to=styled(i)(({theme:o})=>({position:"relative",zIndex:999,pointerEvents:"auto",bgcolor:alpha(o.palette.grey[900],.72),"&:hover":{backgroundColor:alpha(o.palette.grey[900],.48)}})),ro=styled("div")({position:"relative",zIndex:1,userSelect:"none",WebkitUserSelect:"none",WebkitTouchCallout:"none","&:hover":{zIndex:2}}),ao=styled(l)(({theme:o,width:e,isDragging:t})=>({width:e,height:80,alignItems:"center",display:"inline-flex",justifyContent:"center",margin:o.spacing(.5),padding:o.spacing(2,1,2,1),borderRadius:o.spacing(1.25),overflow:"hidden",position:"relative",border:`solid 1px ${o.palette.divider}`,backgroundColor:o.palette.common.white,zIndex:1,transition:"box-shadow 150ms ease-in-out",boxShadow:t?`0 0 0 2px ${o.palette.primary.main}, ${o.customShadows.z8}, inset 0 0 0 1000px ${alpha(o.palette.primary.main,.06)}`:"0px 0px 0px 0px rgba(0, 0, 0, 0)"})),io=styled(m.div)(({theme:o,width:e,isDragging:t})=>({width:e,height:60,alignItems:"center",display:"inline-flex",justifyContent:"center",margin:o.spacing(.5),padding:o.spacing(2),borderRadius:o.spacing(1.25),overflow:"hidden",position:"relative",border:`solid 1px ${o.palette.divider}`,backgroundColor:o.palette.common.white,zIndex:1,transition:"box-shadow 150ms ease-in-out",boxShadow:t?`0 0 0 2px ${o.palette.primary.main}, ${o.customShadows.z8}, inset 0 0 0 1000px ${alpha(o.palette.primary.main,.06)}`:"0px 0px 0px 0px rgba(0, 0, 0, 0)"})),no=styled(i)(({theme:o})=>({width:36,height:36,position:"absolute",top:10,right:10,borderRadius:0,zIndex:1,opacity:0,transition:"opacity 50ms ease-in-out",color:o.palette.error.main,backgroundColor:alpha(o.palette.common.white,.8),"&:hover":{backgroundColor:alpha(o.palette.common.white,.8),opacity:1}})),so=styled(i)(({theme:o})=>({width:24,height:24,position:"absolute",top:18,right:8,borderRadius:12,opacity:1,zIndex:1,transition:"opacity 50ms ease-in-out",color:o.palette.grey[500],backgroundColor:o.palette.common.white,"&:hover":{backgroundColor:o.palette.common.white}})),po=styled(i,{shouldForwardProp:o=>o!=="isMainImage"})(({theme:o,isMainImage:e})=>({color:e?o.palette.secondary.main:o.palette.action.disabled,backgroundColor:o.palette.common.white," &:hover":{backgroundColor:o.palette.common.white},top:4,left:8,padding:o.spacing(.5),border:"1px solid",borderColor:e?o.palette.secondary.main:o.palette.divider})),lo=styled(i)(({theme:o})=>({top:16,right:16,zIndex:9,position:"absolute",color:alpha(o.palette.common.white,.8),bgcolor:alpha(o.palette.grey[900],.72),"&:hover":{bgcolor:alpha(o.palette.grey[900],.48)}})),co=styled(x,{shouldForwardProp:o=>o!=="isDragActive"&&o!=="disabled"&&o!=="hasError"})(({theme:o,isDragActive:e,disabled:t,hasError:n})=>({width:64,height:64,flexShrink:0,display:"flex",borderRadius:1,cursor:"pointer",alignItems:"center",color:o.palette.text.disabled,justifyContent:"center",bgcolor:alpha(o.palette.grey[500],.08),border:`dashed 1px ${alpha(o.palette.grey[500],.16)}`,...e&&{opacity:.72},...t&&{opacity:.48,pointerEvents:"none"},...n&&{color:o.palette.error.main,borderColor:o.palette.error.main,bgcolor:alpha(o.palette.error.main,.08)},"&:hover":{opacity:.72}}));
14
+
15
+ export { O as a, B as b, g as c, Y as d, oo as e, eo as f, to as g, ro as h, ao as i, io as j, no as k, so as l, po as m, lo as n, co as o, N as p };
@@ -0,0 +1,9 @@
1
+ import { a as a$1 } from './chunk-MAK4JF5M.js';
2
+ import c from '@mui/material/IconButton';
3
+ import s from '@mui/material/Stack';
4
+ import { styled } from '@mui/material/styles';
5
+ import { jsx, jsxs } from 'react/jsx-runtime';
6
+
7
+ var a=styled(c)(({theme:t})=>({position:"absolute",top:0,left:-2,zIndex:1,color:t.palette.grey[500],padding:"22px 5px",userSelect:"none",WebkitUserSelect:"none",WebkitTouchCallout:"none",cursor:"grab","&:active":{cursor:"grabbing"},"@media (pointer:coarse)":{userSelect:"none",WebkitUserSelect:"none",MozUserSelect:"none",msUserSelect:"none",WebkitTouchCallout:"none",WebkitTapHighlightColor:"transparent",touchAction:"none","&:active":{pointerEvents:"none"}}})),i=styled(s)({flexDirection:"row",alignItems:"center",justifyContent:"center",width:16,height:16,overflow:"hidden",transform:"scale(0.8)"});var u=({disableDrag:t,...l})=>t?null:jsx(a,{className:"dragIcon",disableRipple:!0,"aria-label":"Arrastar para ordenar",onTouchStart:e=>e.preventDefault(),onTouchMove:e=>e.preventDefault(),...l,children:jsxs(i,{children:[jsx(a$1,{sx:{marginLeft:0},icon:"MORE_BOLD",width:16}),jsx(a$1,{sx:{marginLeft:"-10px"},icon:"MORE_BOLD",width:16})]})}),D=u;
8
+
9
+ export { D as a };
@@ -1,4 +1,4 @@
1
- import { p, f } from './chunk-7WCRRQEW.js';
1
+ import { p, f } from './chunk-ISYQXE75.js';
2
2
  import { a as a$3 } from './chunk-2E4HVMRH.js';
3
3
  import { e } from './chunk-ANAHA3L6.js';
4
4
  import { i } from './chunk-D27ND54J.js';
@@ -1,8 +1,8 @@
1
- import { c, g, p, n, d, e as e$1, a as a$6, b, h, i as i$1, l, m as m$1, j as j$1, k } from './chunk-7WCRRQEW.js';
1
+ import { c, g, p, n, d, e as e$1, a as a$6, b, h, i as i$1, l, m as m$1, j as j$1, k } from './chunk-ISYQXE75.js';
2
2
  import { a as a$5 } from './chunk-2E4HVMRH.js';
3
3
  import { a as a$1 } from './chunk-H5L4ARDB.js';
4
4
  import { e } from './chunk-ANAHA3L6.js';
5
- import { a as a$7 } from './chunk-DXACBPEV.js';
5
+ import { a as a$7 } from './chunk-JEBRSFLS.js';
6
6
  import { x } from './chunk-2P4CXK3O.js';
7
7
  import { a as a$4 } from './chunk-FK7DDO5L.js';
8
8
  import { i, o } from './chunk-D27ND54J.js';
@@ -1,21 +1,23 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { ReactNode } from 'react';
3
- import { DateRangePickerProps as DateRangePickerProps$1 } from '@mui/x-date-pickers-pro';
4
- import { Dayjs } from 'dayjs';
2
+ import * as react from 'react';
3
+ import * as _mui_x_date_pickers_pro from '@mui/x-date-pickers-pro';
4
+ import dayjs__default from 'dayjs';
5
5
 
6
- type DateRange = {
7
- startDate?: Date | null | undefined;
8
- endDate?: Date | null | undefined;
9
- };
10
- type DateRangePickerProps = Omit<DateRangePickerProps$1<Dayjs>, 'value' | 'onChange'> & {
11
- name?: string;
12
- value?: DateRange;
13
- onChange(value?: DateRange): void;
14
- tabIndex?: number;
15
- helperText?: ReactNode;
16
- required?: boolean;
17
- };
18
-
19
- declare const DateRangePicker: ({ name, label, value, onChange, tabIndex, helperText, required, ...other }: DateRangePickerProps) => react_jsx_runtime.JSX.Element;
6
+ declare const DateRangePicker: ({ name, label, value, onChange, tabIndex, helperText, required, ...other }: Omit<_mui_x_date_pickers_pro.DateRangePickerProps<dayjs__default.Dayjs, false>, "value" | "onChange"> & {
7
+ name?: string | undefined;
8
+ value?: {
9
+ startDate?: Date | null | undefined;
10
+ endDate?: Date | null | undefined;
11
+ } | undefined;
12
+ onChange(value?: {
13
+ startDate?: Date | null | undefined;
14
+ endDate?: Date | null | undefined;
15
+ } | undefined): void;
16
+ tabIndex?: number | undefined;
17
+ helperText?: react.ReactNode;
18
+ required?: boolean | undefined;
19
+ } & {
20
+ tabIndex?: number | undefined;
21
+ }) => react_jsx_runtime.JSX.Element;
20
22
 
21
23
  export { DateRangePicker as default };
@@ -2,6 +2,6 @@ import { DateRangePicker } from '@mui/x-date-pickers-pro';
2
2
  import o from 'dayjs';
3
3
  import { jsx } from 'react/jsx-runtime';
4
4
 
5
- var d=({name:a,label:l,value:e,onChange:n,tabIndex:f,helperText:s,required:D,...r})=>jsx(DateRangePicker,{format:"DD/MM/YYYY",value:[e?.startDate?o(e.startDate):null,e?.endDate?o(e.endDate):null],onChange:t=>n({startDate:t[0]?t[0].toDate():null,endDate:t[1]?t[1].toDate():null}),...r,slotProps:{textField:({position:t})=>({...r.slotProps?.textField,required:D,helperText:s,autoComplete:"off",spellCheck:"false",fullWidth:!0,label:l,name:t==="start"?`${a}Start`:`${a}End`})},sx:{width:1}}),u=d;
5
+ var p=({name:a,label:l,value:e,onChange:n,tabIndex:s,helperText:D,required:i,...r})=>jsx(DateRangePicker,{format:"DD/MM/YYYY",value:[e?.startDate?o(e.startDate):null,e?.endDate?o(e.endDate):null],onChange:t=>n({startDate:t[0]?t[0].toDate():null,endDate:t[1]?t[1].toDate():null}),...r,slotProps:{textField:({position:t})=>({...r.slotProps?.textField,required:i,helperText:D,autoComplete:"off",tabIndex:s,spellCheck:"false",fullWidth:!0,label:l,name:t==="start"?`${a}Start`:`${a}End`})},sx:{width:1}}),u=p;
6
6
 
7
7
  export { u as default };
@@ -1,3 +1,3 @@
1
- export { a as default } from '../../chunk-DXACBPEV.js';
1
+ export { a as default } from '../../chunk-JEBRSFLS.js';
2
2
  import '../../chunk-MAK4JF5M.js';
3
3
  import '../../chunk-FUB7WQS5.js';
@@ -4,9 +4,9 @@ import { a as a$5 } from '../../chunk-COTMNI3C.js';
4
4
  import '../../chunk-7TFD7ZIP.js';
5
5
  import '../../chunk-5NOG7L7I.js';
6
6
  import { e } from '../../chunk-ANAHA3L6.js';
7
- import { a } from '../../chunk-YXH2ZKVS.js';
7
+ import { a } from '../../chunk-FZ4WZF6K.js';
8
8
  import { f } from '../../chunk-EUL6EPCK.js';
9
- import { a as a$2 } from '../../chunk-DXACBPEV.js';
9
+ import { a as a$2 } from '../../chunk-JEBRSFLS.js';
10
10
  import { x } from '../../chunk-2P4CXK3O.js';
11
11
  import { a as a$7 } from '../../chunk-FK7DDO5L.js';
12
12
  import { j as j$1 } from '../../chunk-DMQW3LDF.js';
@@ -1,4 +1,4 @@
1
- import { a as a$2 } from '../../chunk-YXH2ZKVS.js';
1
+ import { a as a$2 } from '../../chunk-FZ4WZF6K.js';
2
2
  import { a } from '../../chunk-CFD2VTQ3.js';
3
3
  import { a as a$1 } from '../../chunk-26GV7WKC.js';
4
4
  import { a as a$3 } from '../../chunk-MAK4JF5M.js';
@@ -1,3 +1,3 @@
1
- export { a as default } from '../../chunk-YXH2ZKVS.js';
1
+ export { a as default } from '../../chunk-FZ4WZF6K.js';
2
2
  import '../../chunk-MAK4JF5M.js';
3
3
  import '../../chunk-FUB7WQS5.js';
@@ -6,6 +6,6 @@ import 'dayjs';
6
6
  import '../../../types/baseField.js';
7
7
  import 'react-hook-form';
8
8
 
9
- declare const DateRangePicker: ({ name, label, rules, tabIndex, helperText, required, ...other }: DateRangePickerProps) => react_jsx_runtime.JSX.Element;
9
+ declare const DateRangePicker: ({ name, label, rules, helperText, required, ...other }: DateRangePickerProps) => react_jsx_runtime.JSX.Element;
10
10
 
11
11
  export { DateRangePicker as default };
@@ -1,10 +1,10 @@
1
1
  import { useFormContext, Controller } from 'react-hook-form';
2
- import x from '@mui/material/FormHelperText';
3
- import P from '@mui/material/Stack';
2
+ import P from '@mui/material/FormHelperText';
3
+ import k from '@mui/material/Stack';
4
4
  import { DateRangePicker } from '@mui/x-date-pickers-pro';
5
5
  import i from 'dayjs';
6
6
  import { jsx, jsxs } from 'react/jsx-runtime';
7
7
 
8
- var C=({name:e,label:s,rules:d,tabIndex:R,helperText:l,required:D,...r})=>{let{control:f,setError:c}=useFormContext();return jsx(Controller,{name:e,control:f,rules:d,render:({field:{value:a,onChange:p},fieldState:{error:o}})=>jsxs(P,{children:[jsx(DateRangePicker,{"data-intercom-target":e,...r,format:"DD/MM/YYYY",value:[a?.startDate?i(a.startDate):null,a?.endDate?i(a.endDate):null],onChange:t=>{let m={startDate:t[0]?t[0].toDate():null,endDate:t[1]?t[1].toDate():null};p(m),r.onChange&&r.onChange(m);},onError:t=>{c(e,{message:t[0]||t[1]||void 0});},slotProps:{textField:({position:t})=>({...r.slotProps?.textField,required:D,error:!!o,autoComplete:"off",spellCheck:"false",fullWidth:!0,label:t==="start"?`${s} (Dt. In\xEDcio)`:`${s} (Dt. Fim)`,name:t==="start"?`${e}Start`:`${e}End`})},sx:{width:1}}),(o?.message||l)&&jsx(x,{error:!!o,sx:{mx:"14px"},children:o?.message||l})]})})},E=C;
8
+ var C=({name:e,label:s,rules:D,helperText:l,required:d,...r})=>{let{control:f,setError:c}=useFormContext();return jsx(Controller,{name:e,control:f,rules:D,render:({field:{value:o,onChange:p},fieldState:{error:a}})=>jsxs(k,{children:[jsx(DateRangePicker,{"data-intercom-target":e,...r,format:"DD/MM/YYYY",value:[o?.startDate?i(o.startDate):null,o?.endDate?i(o.endDate):null],onChange:t=>{let m={startDate:t[0]?t[0].toDate():null,endDate:t[1]?t[1].toDate():null};p(m),r.onChange&&r.onChange(m);},onError:t=>{c(e,{message:t[0]||t[1]||void 0});},slotProps:{textField:({position:t})=>({...r.slotProps?.textField,required:d,error:!!a,autoComplete:"off",spellCheck:"false",fullWidth:!0,label:t==="start"?`${s} (Dt. In\xEDcio)`:`${s} (Dt. Fim)`,name:t==="start"?`${e}Start`:`${e}End`})},sx:{width:1}}),(a?.message||l)&&jsx(P,{error:!!a,sx:{mx:"14px"},children:a?.message||l})]})})},h=C;
9
9
 
10
- export { E as default };
10
+ export { h as default };
@@ -1,5 +1,5 @@
1
- import { b } from '../../../chunk-GVJPNJEL.js';
2
- import '../../../chunk-7WCRRQEW.js';
1
+ import { b } from '../../../chunk-RBHRP2UE.js';
2
+ import '../../../chunk-ISYQXE75.js';
3
3
  import '../../../chunk-2E4HVMRH.js';
4
4
  import '../../../chunk-T7I256S6.js';
5
5
  import '../../../chunk-5NOG7L7I.js';
@@ -1,11 +1,11 @@
1
- import { e } from '../../../chunk-OYK7T66A.js';
2
- import '../../../chunk-7WCRRQEW.js';
1
+ import { e } from '../../../chunk-XAJTYCRG.js';
2
+ import '../../../chunk-ISYQXE75.js';
3
3
  import '../../../chunk-2E4HVMRH.js';
4
4
  import '../../../chunk-T7I256S6.js';
5
5
  import '../../../chunk-H5L4ARDB.js';
6
6
  import '../../../chunk-5NOG7L7I.js';
7
7
  import '../../../chunk-ANAHA3L6.js';
8
- import '../../../chunk-DXACBPEV.js';
8
+ import '../../../chunk-JEBRSFLS.js';
9
9
  import '../../../chunk-2P4CXK3O.js';
10
10
  import '../../../chunk-FK7DDO5L.js';
11
11
  import '../../../chunk-D27ND54J.js';
@@ -1,13 +1,13 @@
1
- export { a as UploadAvatar, b as UploadAvatarWithCrop } from '../../chunk-GVJPNJEL.js';
2
- export { c as DeleteButton, a as MultiFilePreview, b as SingleFilePreview, d as Upload, e as UploadWithCrop } from '../../chunk-OYK7T66A.js';
3
- import { o } from '../../chunk-7WCRRQEW.js';
4
- export { p as RejectionFiles } from '../../chunk-7WCRRQEW.js';
1
+ export { a as UploadAvatar, b as UploadAvatarWithCrop } from '../../chunk-RBHRP2UE.js';
2
+ export { c as DeleteButton, a as MultiFilePreview, b as SingleFilePreview, d as Upload, e as UploadWithCrop } from '../../chunk-XAJTYCRG.js';
3
+ import { o } from '../../chunk-ISYQXE75.js';
4
+ export { p as RejectionFiles } from '../../chunk-ISYQXE75.js';
5
5
  import '../../chunk-2E4HVMRH.js';
6
6
  import '../../chunk-T7I256S6.js';
7
7
  import '../../chunk-H5L4ARDB.js';
8
8
  import '../../chunk-5NOG7L7I.js';
9
9
  import '../../chunk-ANAHA3L6.js';
10
- import '../../chunk-DXACBPEV.js';
10
+ import '../../chunk-JEBRSFLS.js';
11
11
  import '../../chunk-2P4CXK3O.js';
12
12
  import '../../chunk-FK7DDO5L.js';
13
13
  import '../../chunk-D27ND54J.js';
@@ -443,7 +443,7 @@ declare function paper({ theme, color, dropdown }: PaperProps): {
443
443
  wordWrap?: csstype.Property.WordWrap | readonly NonNullable<csstype.Property.WordWrap | undefined>[] | readonly csstype.Property.WordWrap[] | undefined;
444
444
  writingMode?: csstype.Property.WritingMode | readonly NonNullable<csstype.Property.WritingMode | undefined>[] | readonly csstype.Property.WritingMode[] | undefined;
445
445
  zIndex?: csstype.Property.ZIndex | readonly NonNullable<csstype.Property.ZIndex | undefined>[] | readonly ((string & {}) | csstype.Globals | "auto")[] | undefined;
446
- zoom?: csstype.Property.Zoom | readonly NonNullable<csstype.Property.Zoom | undefined>[] | readonly ("reset" | (string & {}) | csstype.Globals | "normal")[] | undefined;
446
+ zoom?: csstype.Property.Zoom | readonly NonNullable<csstype.Property.Zoom | undefined>[] | readonly ((string & {}) | csstype.Globals | "normal" | "reset")[] | undefined;
447
447
  all?: csstype.Globals | readonly NonNullable<csstype.Globals | undefined>[] | readonly csstype.Globals[] | undefined;
448
448
  animation?: csstype.Property.Animation<string & {}> | readonly NonNullable<csstype.Property.Animation<string & {}> | undefined>[] | readonly ((string & {}) | csstype.Globals | "normal" | "reverse" | "auto" | "none" | "both" | "alternate" | "alternate-reverse" | "backwards" | "forwards" | "infinite" | "paused" | "running" | "ease" | "ease-in" | "ease-in-out" | "ease-out" | "step-end" | "step-start" | "linear")[] | undefined;
449
449
  animationRange?: csstype.Property.AnimationRange<string | number> | readonly NonNullable<csstype.Property.AnimationRange<string | number> | undefined>[] | readonly (string | (string & {}))[] | undefined;
@@ -11,7 +11,6 @@ type DateRange = {
11
11
  type DateRangePickerProps = BaseField<Omit<DateRangePickerProps$1<Dayjs>, 'value' | 'onChange'>> & {
12
12
  value?: DateRange;
13
13
  onChange?(value?: DateRange): void;
14
- tabIndex?: number;
15
14
  helperText?: ReactNode;
16
15
  required?: boolean;
17
16
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zydon/common",
3
- "version": "2.5.13",
3
+ "version": "2.5.15",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "module": "./dist/index.js",
@@ -1,15 +0,0 @@
1
- import { e } from './chunk-ANAHA3L6.js';
2
- import { i as i$1 } from './chunk-D27ND54J.js';
3
- import x from '@mui/material/Box';
4
- import D from '@mui/material/Paper';
5
- import z from '@mui/material/Typography';
6
- import { jsx, jsxs } from 'react/jsx-runtime';
7
- import E from '@mui/material/CircularProgress';
8
- import i from '@mui/material/IconButton';
9
- import l from '@mui/material/Stack';
10
- import { styled, alpha } from '@mui/material/styles';
11
- import { m } from 'framer-motion';
12
-
13
- var y=["pdf"],f=["txt"],h=["psd"],I=["doc","docx"],k=["xls","xlsx"],v=["zip","rar","iso"],w=["ai","esp"],C=["ppt","pptx"],F=["wav","aif","mp3","aac"],R=["jpg","jpeg","gif","bmp","png","svg","webp"],T=["m4v","avi","mpg","mp4","webm"];function O(o){let e,t=s(o);switch(o.includes(t)){case f.includes(t):e="txt";break;case v.includes(t):e="zip";break;case F.includes(t):e="audio";break;case R.includes(t):e="image";break;case T.includes(t):e="video";break;case I.includes(t):e="word";break;case k.includes(t):e="excel";break;case C.includes(t):e="powerpoint";break;case y.includes(t):e="pdf";break;case h.includes(t):e="photoshop";break;case w.includes(t):e="illustrator";break;case o?.startsWith("http"):e="image";break;default:e=s(o);}return e}function B(o){let e;switch(O(o)){case"folder":e="IC_FOLDER";break;case"txt":e="IC_TXT";break;case"zip":e="IC_ZIP";break;case"audio":e="IC_AUDIO";break;case"video":e="IC_VIDEO";break;case"word":e="IC_WORD";break;case"excel":e="IC_EXCEL";break;case"powerpoint":e="IC_POWER_POINT";break;case"pdf":e="IC_PDF";break;case"photoshop":e="IC_PTS";break;case"illustrator":e="IC_AI";break;case"image":e="IC_IMG";break;default:e="IC_FILE";}return e}function s(o){return o&&o.split(".").pop()||""}function _(o){return o.split("/").pop()}function g(o){return typeof o=="string"?{key:o,preview:o,name:_(o),type:s(o),size:void 0,path:o,lastModified:void 0,lastModifiedDate:void 0}:{key:`key:${o.name}`,name:o.name,size:o.size,path:o.path,type:o.type,preview:o.preview,lastModified:o.lastModified,lastModifiedDate:o.lastModifiedDate}}function U({files:o}){return o.length?jsx(D,{variant:"outlined",sx:{py:1,px:2,mt:3,textAlign:"left",borderStyle:"dashed",borderColor:"error.main",bgcolor:e=>i$1(e.vars.palette.error.mainChannel,.08)},children:o.map(({file:e$1,errors:t})=>{let{path:n,size:d}=g(e$1),m=d?e(d):"";return jsxs(x,{sx:{my:1},children:[jsxs(z,{variant:"subtitle2",noWrap:!0,children:[n," - ",m," "]}),t.map(c=>jsxs(x,{component:"span",sx:{typography:"caption"},children:["- ",c.message]},c.code))]},n)})}):null}var Y=styled(l)({position:"relative",width:"100%",borderRadius:8,overflow:"hidden","&:hover .actions":{display:"flex"}}),oo=styled(l)(({theme:o})=>({display:"none",position:"absolute",alignItems:"center",justifyContent:"center",flexDirection:"row",gap:12,width:"100%",height:"100%",backgroundColor:alpha(o.palette.primary.main,.9),zIndex:999,button:{"&, &:hover, &:focus":{backgroundColor:"#fff"}}})),eo=styled(E)({position:"absolute",width:"100%",height:"100%",zIndex:99,backgroundColor:"#fff",borderRadius:"50%"}),to=styled(i)(({theme:o})=>({position:"relative",zIndex:999,pointerEvents:"auto",bgcolor:alpha(o.palette.grey[900],.72),"&:hover":{backgroundColor:alpha(o.palette.grey[900],.48)}})),ro=styled("div")({position:"relative",zIndex:1,userSelect:"none","&:hover":{zIndex:2}}),ao=styled(l)(({theme:o,width:e,isDragging:t})=>({width:e,height:80,alignItems:"center",display:"inline-flex",justifyContent:"center",margin:o.spacing(.5),padding:o.spacing(2,1,2,1),borderRadius:o.spacing(1.25),overflow:"hidden",position:"relative",border:`solid 1px ${o.palette.divider}`,backgroundColor:o.palette.common.white,zIndex:1,transition:"box-shadow 150ms ease-in-out",boxShadow:t?`0 0 0 2px ${o.palette.primary.main}, ${o.customShadows.z8}, inset 0 0 0 1000px ${alpha(o.palette.primary.main,.06)}`:"0px 0px 0px 0px rgba(0, 0, 0, 0)"})),io=styled(m.div)(({theme:o,width:e,isDragging:t})=>({width:e,height:60,alignItems:"center",display:"inline-flex",justifyContent:"center",margin:o.spacing(.5),padding:o.spacing(2),borderRadius:o.spacing(1.25),overflow:"hidden",position:"relative",border:`solid 1px ${o.palette.divider}`,backgroundColor:o.palette.common.white,zIndex:1,transition:"box-shadow 150ms ease-in-out",boxShadow:t?`0 0 0 2px ${o.palette.primary.main}, ${o.customShadows.z8}, inset 0 0 0 1000px ${alpha(o.palette.primary.main,.06)}`:"0px 0px 0px 0px rgba(0, 0, 0, 0)"})),no=styled(i)(({theme:o})=>({width:36,height:36,position:"absolute",top:10,right:10,borderRadius:0,zIndex:1,opacity:0,transition:"opacity 50ms ease-in-out",color:o.palette.error.main,backgroundColor:alpha(o.palette.common.white,.8),"&:hover":{backgroundColor:alpha(o.palette.common.white,.8),opacity:1}})),so=styled(i)(({theme:o})=>({width:24,height:24,position:"absolute",top:18,right:8,borderRadius:12,opacity:1,zIndex:1,transition:"opacity 50ms ease-in-out",color:o.palette.grey[500],backgroundColor:o.palette.common.white,"&:hover":{backgroundColor:o.palette.common.white}})),po=styled(i,{shouldForwardProp:o=>o!=="isMainImage"})(({theme:o,isMainImage:e})=>({color:e?o.palette.secondary.main:o.palette.action.disabled,backgroundColor:o.palette.common.white," &:hover":{backgroundColor:o.palette.common.white},top:4,left:8,padding:o.spacing(.5),border:"1px solid",borderColor:e?o.palette.secondary.main:o.palette.divider})),lo=styled(i)(({theme:o})=>({top:16,right:16,zIndex:9,position:"absolute",color:alpha(o.palette.common.white,.8),bgcolor:alpha(o.palette.grey[900],.72),"&:hover":{bgcolor:alpha(o.palette.grey[900],.48)}})),co=styled(x,{shouldForwardProp:o=>o!=="isDragActive"&&o!=="disabled"&&o!=="hasError"})(({theme:o,isDragActive:e,disabled:t,hasError:n})=>({width:64,height:64,flexShrink:0,display:"flex",borderRadius:1,cursor:"pointer",alignItems:"center",color:o.palette.text.disabled,justifyContent:"center",bgcolor:alpha(o.palette.grey[500],.08),border:`dashed 1px ${alpha(o.palette.grey[500],.16)}`,...e&&{opacity:.72},...t&&{opacity:.48,pointerEvents:"none"},...n&&{color:o.palette.error.main,borderColor:o.palette.error.main,bgcolor:alpha(o.palette.error.main,.08)},"&:hover":{opacity:.72}}));
14
-
15
- export { O as a, B as b, g as c, Y as d, oo as e, eo as f, to as g, ro as h, ao as i, io as j, no as k, so as l, po as m, lo as n, co as o, U as p };
@@ -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",userSelect:"none",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 };
@@ -1,11 +0,0 @@
1
- import { a } from './chunk-MAK4JF5M.js';
2
- import { forwardRef, useMemo } from 'react';
3
- import c from '@mui/material/Box';
4
- import x from '@mui/material/CircularProgress';
5
- import y from '@mui/material/IconButton';
6
- import C from '@mui/material/Tooltip';
7
- import { jsx } from 'react/jsx-runtime';
8
-
9
- var l=forwardRef(({icon:t,label:i,color:e="primary",loading:r=!1,disabled:B=!1,boxProps:m={},tooltipProps:I={},iconProps:u={},disableTooltip:d=!1,children:n,...M},w)=>{if(!t&&!n)throw new Error("IconButton: icon or children is required");let f=useMemo(()=>t?jsx(a,{icon:t,...u}):n,[t,n,u]),T=useMemo(()=>r?jsx(x,{size:20,color:"inherit"}):f,[r,f]),s=jsx(y,{ref:w,"aria-label":i,color:"inherit",disabled:r||B,...M,children:T});return d?jsx(c,{...m,color:e,children:s}):jsx(c,{...m,color:e,children:jsx(C,{"data-testid":"button-tooltip",...I,title:i,children:jsx("span",{children:s})})})});l.displayName="IconButton";var N=l;
10
-
11
- export { N as a };