nemesischart 2.0.7 → 2.0.8
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/nemesischart.js +744 -723
- package/dist/nemesischart.umd.cjs +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(M,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("chart.js")):typeof define=="function"&&define.amd?define(["exports","vue","chart.js"],e):(M=typeof globalThis<"u"?globalThis:M||self,e(M.NemesisChart={},M.Vue,M.Chart))})(this,function(M,e,X){"use strict";const G=(t,f)=>{const o=t.__vccOpts||t;for(const[l,a]of f)o[l]=a;return o},U=G({__name:"ChartBase",props:{type:{type:String,required:!0},data:{type:Object,required:!0},options:{type:Object,default:()=>({})},plugins:{type:Array,default:()=>[]},height:{type:[String,Number],default:300},width:{type:[String,Number],default:null}},setup(t,{expose:f}){X.Chart.register(X.Title,X.Tooltip,X.Legend,X.Filler,X.LineController,X.LineElement,X.PointElement,X.BarController,X.BarElement,X.PieController,X.PolarAreaController,X.ArcElement,X.CategoryScale,X.LinearScale,X.RadialLinearScale);const o=t,l=e.ref(null),a=e.shallowRef(null),x={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{position:"top"}}};function b(){return{...x,...o.options}}function k(){l.value&&(a.value=new X.Chart(l.value,{type:o.type,data:o.data,options:b(),plugins:o.plugins}))}function R(){a.value&&(a.value.destroy(),a.value=null)}return e.onMounted(k),e.onBeforeUnmount(R),e.watch(()=>o.data,B=>{if(!a.value)return;a.value.data.labels=B.labels;const $=a.value.data.datasets,V=B.datasets;$.length!==V.length?a.value.data.datasets=V:V.forEach((j,D)=>Object.assign($[D],j)),a.value.update()},{deep:!0}),e.watch(()=>o.options,()=>{a.value&&(a.value.options=b(),a.value.update())},{deep:!0}),f({chart:a}),(B,$)=>(e.openBlock(),e.createElementBlock("div",{class:"nc-chart-wrapper w-full",style:e.normalizeStyle({height:typeof t.height=="number"?`${t.height}px`:t.height,width:t.width?typeof t.width=="number"?`${t.width}px`:t.width:"100%"})},[e.createElementVNode("canvas",{ref_key:"canvasRef",ref:l},null,512)],4))}},[["__scopeId","data-v-9828990e"]]);function ke(t){const f=t.replace("#",""),o=f.length===3?f.split("").map(j=>j+j).join(""):f,l=parseInt(o.slice(0,2),16)/255,a=parseInt(o.slice(2,4),16)/255,x=parseInt(o.slice(4,6),16)/255,b=Math.max(l,a,x),k=Math.min(l,a,x),R=(b+k)/2;if(b===k)return[0,0,R*100];const B=b-k,$=R>.5?B/(2-b-k):B/(b+k);let V;return b===l?V=((a-x)/B+(a<x?6:0))/6:b===a?V=((x-l)/B+2)/6:V=((l-a)/B+4)/6,[V*360,$*100,R*100]}function Be(t,f,o){t/=360,f/=100,o/=100;const l=o<.5?o*(1+f):o+f-o*f,a=2*o-l,x=B=>(B<0&&(B+=1),B>1&&(B-=1),B<1/6?a+(l-a)*6*B:B<1/2?l:B<2/3?a+(l-a)*(2/3-B)*6:a),b=f===0?o:x(t+1/3),k=f===0?o:x(t),R=f===0?o:x(t-1/3);return"#"+[b,k,R].map(B=>Math.round(B*255).toString(16).padStart(2,"0")).join("")}function re(t,f=7){if(!(t!=null&&t.startsWith("#")))return Array.from({length:f},()=>t??"#3B82F6");const[o,l]=ke(t),a=20,x=72;return Array.from({length:f},(b,k)=>{const R=f===1?.5:k/(f-1),B=a+R*(x-a),$=Math.max(50,l-Math.max(0,B-55)*.6);return Be(o,$,B)})}const Ee={light:{bg:"#ffffff",text:"#000000",muted:"#64748B",grid:"rgba(15,23,42,0.06)"},dark:{bg:"#000000",text:"#ffffff",muted:"#7b7b7b",grid:"rgba(255,255,255,0.08)"},transparent:{bg:"transparent",text:"inherit",muted:"#7b7b7b",grid:"rgba(127,127,127,0.15)"}};function z(t,f){if(!t)return`rgba(59,130,246,${f})`;if(t.startsWith("#")){const o=t.replace("#",""),l=o.length===3?o.split("").map(k=>k+k).join(""):o,a=parseInt(l.slice(0,2),16),x=parseInt(l.slice(2,4),16),b=parseInt(l.slice(4,6),16);return`rgba(${a},${x},${b},${f})`}if(t.startsWith("rgb")){const o=t.match(/[\d.]+/g);if(o&&o.length>=3)return`rgba(${o[0]},${o[1]},${o[2]},${f})`}return t}function Z(t){const f=e.computed(()=>{const l=Ee[t.tema],a=l?{...l,bg:t.corFundo||l.bg}:{bg:t.corFundo||t.tema,text:"#F8FAFC",muted:"#7b7b7b",grid:"rgba(255,255,255,0.08)"};return{...a,text:t.corTexto||a.text,muted:t.corTexto||a.muted}}),o=e.computed(()=>({background:f.value.bg,color:f.value.text,borderRadius:typeof t.borderRadius=="number"?`${t.borderRadius}px`:t.borderRadius,boxShadow:t.sombra,border:t.corBorda?`1px solid ${t.corBorda}`:"none"}));return{palette:f,cardStyle:o,toRgba:z}}function oe(t){const f=e.computed(()=>t.tipoValor==="moeda"?new Intl.NumberFormat(t.locale,{style:"currency",currency:t.moeda}):t.tipoValor==="percentual"?new Intl.NumberFormat(t.locale,{style:"percent",maximumFractionDigits:2}):new Intl.NumberFormat(t.locale,{maximumFractionDigits:2}));function o(l){if(l==null)return"";const a=Number(l);return Number.isNaN(a)?String(l):t.tipoValor==="percentual"?f.value.format(a/100):f.value.format(a)}return{formatador:f,formatar:o}}function ae(t,{caretFlexivel:f=!1}={}){let o=t.querySelector(".nc-tt");if(o)return o;o=document.createElement("div"),o.className="nc-tt",Object.assign(o.style,{position:"absolute",pointerEvents:"none",transform:f?"translateX(-50%)":"translate(-50%, calc(-100% - 16px))",transition:"opacity .18s ease, left .12s ease, top .12s ease",opacity:"0",background:"#ffffff",borderRadius:"10px",padding:"8px 11px",boxShadow:"0 1px 2px rgba(15,23,42,.06), 0 8px 24px rgba(15,23,42,.12)",border:"1px solid rgba(15,23,42,.06)",minWidth:"90px",whiteSpace:"nowrap",zIndex:"10",fontFamily:"inherit",textAlign:"left"});const l=document.createElement("div");l.className="nc-tt__caret";const a={position:"absolute",left:"50%",width:"10px",height:"10px",background:"#ffffff",transform:"translateX(-50%) rotate(45deg)",borderRadius:"2px"};f?Object.assign(l.style,a):Object.assign(l.style,a,{bottom:"-5px",borderRight:"1px solid rgba(15,23,42,.06)",borderBottom:"1px solid rgba(15,23,42,.06)"}),o.appendChild(l);const x=document.createElement("div");return x.className="nc-tt__content",Object.assign(x.style,{position:"relative",background:"#fff",borderRadius:"8px"}),o.appendChild(x),t.appendChild(o),o}function K(t){const f=t.canvas.parentNode;return f?(getComputedStyle(f).position==="static"&&(f.style.position="relative"),f):null}function _(t,f,o,l=4){const a=f/2;return t-a<l?a+l:t+a>o-l?o-a-l:t}function le(t,f){const o=window.getComputedStyle(t);let l="";for(let a=0;a<o.length;a++){const x=o[a];let b=o.getPropertyValue(x);if(b&&b.indexOf("url(")!==-1&&!/url\(["']?data:/.test(b))if(x==="background-image"||x==="background"||x==="mask-image"||x==="border-image"||x==="border-image-source")b="none";else continue;l+=`${x}:${b};`}f.setAttribute("style",l)}function Ce(t,f){le(t,f);const o=t.querySelectorAll("*"),l=f.querySelectorAll("*");for(let a=0;a<o.length;a++)l[a]&&le(o[a],l[a])}function $e(t,f){const o=t.querySelectorAll("canvas"),l=f.querySelectorAll("canvas");o.forEach((a,x)=>{if(!l[x])return;const b=document.createElement("img");try{b.src=a.toDataURL("image/png")}catch{return}const k=a.getBoundingClientRect();b.setAttribute("style",`width:${k.width}px;height:${k.height}px;display:block;`),l[x].replaceWith(b)})}async function v(t,f={}){if(!t)return;const{nomeArquivo:o="componente.png",escala:l=2,corFundo:a=null}=f,x=t.getBoundingClientRect(),b=Math.ceil(x.width),k=Math.ceil(x.height),R=t.cloneNode(!0);Ce(t,R),$e(t,R),R.style.margin="0",R.style.transform="none";const B=new XMLSerializer().serializeToString(R),$=`<svg xmlns="http://www.w3.org/2000/svg" width="${b}" height="${k}"><foreignObject width="100%" height="100%"><div xmlns="http://www.w3.org/1999/xhtml" style="width:${b}px;height:${k}px;">`+B+"</div></foreignObject></svg>",j="data:image/svg+xml;base64,"+(typeof window<"u"&&window.btoa?window.btoa(unescape(encodeURIComponent($))):""),D=new Image;await new Promise((N,O)=>{D.onload=N,D.onerror=O,D.src=j});const Y=document.createElement("canvas");Y.width=b*l,Y.height=k*l;const J=Y.getContext("2d");J.scale(l,l),a&&(J.fillStyle=a,J.fillRect(0,0,b,k)),J.drawImage(D,0,0);let d;try{d=Y.toDataURL("image/png")}catch(N){console.error("Falha ao exportar imagem: canvas contaminado.",N);return}const E=document.createElement("a");E.download=o,E.href=d,document.body.appendChild(E),E.click(),document.body.removeChild(E)}const ee='<svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"/><polyline points="7 10 12 15 17 10"/><line x1="12" y1="15" x2="12" y2="3"/></svg>',Ve={class:"card-linhas__header flex flex-column"},Ne={class:"card-linhas__topo flex align-items-start justify-content-between gap-3"},Te={key:0,class:"nc-legendas-flex flex flex-column"},ze={key:1,class:"nc-actions inline-flex align-items-center gap-2"},Ae=["innerHTML"],we={key:0,class:"card-linhas__titulos mt-3 mb-2 flex flex-column"},Re={class:"card-linhas__chart flex-1"},Fe={key:0,class:"card-linhas__footer mt-3"},se=G({__name:"CardLinhas",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corDetalhes:{type:String,default:"#3B82F6"},corTexto:{type:String,default:null},textoBotao:{type:String,default:"Ver mais"},direcao:{type:String,default:"top",validator:t=>["top","bottom","left","right"].includes(t)},botaoVisivel:{type:Boolean,default:!1},tipoValor:{type:String,default:"numero",validator:t=>["numero","moeda","percentual"].includes(t)},locale:{type:String,default:"pt-BR"},moeda:{type:String,default:"BRL"},data:{type:Array,default:()=>[{rotulo:"Jan",quantidade:22},{rotulo:"Fev",quantidade:35},{rotulo:"Mar",quantidade:28},{rotulo:"Abr",quantidade:45},{rotulo:"Mai",quantidade:30},{rotulo:"Jun",quantidade:55},{rotulo:"Jul",quantidade:42},{rotulo:"Ago",quantidade:60},{rotulo:"Set",quantidade:48},{rotulo:"Out",quantidade:70},{rotulo:"Nov",quantidade:58},{rotulo:"Dez",quantidade:75}]},height:{type:[String,Number],default:280},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06)"},corBorda:{type:String,default:"#EAE8E8"},linhasReferencia:{type:[Object,Array],default:null},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-linhas.png"}},emits:["botaoAcao","exportado"],setup(t,{emit:f}){const o=t,l=f,{palette:a,cardStyle:x}=Z(o),{formatar:b}=oe(o),k=e.ref(null),R=ee;async function B(){await v(k.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),l("exportado")}const $=e.computed(()=>`card-linhas--${o.direcao}`),V=e.computed(()=>o.linhasReferencia?(Array.isArray(o.linhasReferencia)?o.linhasReferencia:[o.linhasReferencia]).filter(i=>i&&(typeof i=="number"||typeof i.valor=="number")).map(i=>typeof i=="number"?{valor:i,rotulo:null,cor:"#0F172A",corRotulo:"#0F172A",corTexto:"#FFFFFF",tracejado:[6,6],espessura:1}:{valor:i.valor,rotulo:i.rotulo??null,cor:i.cor||"#0F172A",corRotulo:i.corRotulo||i.cor||"#0F172A",corTexto:i.corTexto||"#FFFFFF",tracejado:i.tracejado||[6,6],espessura:i.espessura??1}):[]),j=[];let D=null;const Y={id:"linhaReferencia",afterDatasetsDraw(m){const i=V.value;if(j.length=0,!i.length)return;const{ctx:n,chartArea:u,scales:g}=m,s=g.y;s&&i.forEach(c=>{const r=s.getPixelForValue(c.valor);if(j.push({linha:c,pos:r,chartArea:u}),n.save(),n.beginPath(),n.setLineDash(c.tracejado),n.lineWidth=c.espessura,n.strokeStyle=c.cor,r<u.top||r>u.bottom){n.restore();return}if(n.moveTo(u.left,r),n.lineTo(u.right,r),n.stroke(),n.setLineDash([]),c.rotulo){n.font="600 11px 'Inter', sans-serif";const p=8,y=5,C=n.measureText(c.rotulo).width,S=12,h=C+p*2,L=S+y*2,H=L/2;let w=u.left-h-6,q=r-L/2;w<0&&(w=u.left+6),n.fillStyle=c.corRotulo,n.beginPath(),n.roundRect?n.roundRect(w,q,h,L,H):(n.moveTo(w+H,q),n.lineTo(w+h-H,q),n.quadraticCurveTo(w+h,q,w+h,q+H),n.lineTo(w+h,q+L-H),n.quadraticCurveTo(w+h,q+L,w+h-H,q+L),n.lineTo(w+H,q+L),n.quadraticCurveTo(w,q+L,w,q+L-H),n.lineTo(w,q+H),n.quadraticCurveTo(w,q,w+H,q)),n.fill(),n.fillStyle=c.corTexto,n.textBaseline="middle",n.textAlign="center",n.fillText(c.rotulo,w+h/2,q+L/2)}n.restore()})},beforeEvent(m,i){if(!j.length){D=null;return}const n=i.event;if(!n||n.type==="mouseout"||n.x==null||n.y==null){D=null;return}const u=8;let g=null,s=1/0;for(const c of j){const r=Math.abs(n.y-c.pos),p=n.x>=c.chartArea.left&&n.x<=c.chartArea.right;r<=u&&p&&r<s&&(s=r,g=c)}D=g},afterEvent(m,i){if(!j.length)return;const n=i.event;if(!n)return;const u=K(m);if(!u)return;let g=u.querySelector(".nc-tt-linhaRef");if(!D){g&&(g.style.opacity="0");return}const s=D;g||(g=document.createElement("div"),g.className="nc-tt-linhaRef",Object.assign(g.style,{position:"absolute",pointerEvents:"none",transform:"translate(-50%, calc(-100% - 12px))",transition:"opacity .18s ease, left .12s ease, top .12s ease",opacity:"0",background:"#ffffff",borderRadius:"10px",padding:"8px 11px",boxShadow:"0 1px 2px rgba(15,23,42,.06), 0 8px 24px rgba(15,23,42,.12)",border:"1px solid rgba(15,23,42,.06)",whiteSpace:"nowrap",zIndex:"11",fontFamily:"'Inter', sans-serif",textAlign:"left"}),u.appendChild(g));const c=s.linha.cor||"#0F172A",r=b(s.linha.valor),p=s.linha.rotulo;g.innerHTML=(p?`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${p}</div>`:"")+`<div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${c};box-shadow:0 0 0 2px ${z(c,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${r}</span></div>`;const y=m.canvas;g.style.opacity="1",g.style.visibility="hidden",g.style.left="0px",g.style.top="0px";const T=g.offsetWidth,C=g.offsetHeight,S=4,h=y.offsetLeft+n.x,L=y.offsetTop+s.pos,H=_(h,T,u.clientWidth,S);let w=L;const q=C+16+S;w<q&&(w=q),g.style.left=H+"px",g.style.top=w+"px",g.style.visibility="visible"}},J=e.computed(()=>V.value.length?[Y]:[]),d=e.computed(()=>({labels:o.data.map(m=>m.rotulo),datasets:[{data:o.data.map(m=>m.quantidade),borderColor:o.corDetalhes,borderWidth:3,borderJoinStyle:"round",borderCapStyle:"round",backgroundColor:m=>{const{chart:i}=m,{ctx:n,chartArea:u}=i;if(!u)return"transparent";const g=o.corDetalhes||"#0400FF",s="#7C7C7C",c=n.createLinearGradient(0,u.top,0,u.bottom);return c.addColorStop(.16,z(g,.2)),c.addColorStop(1,z(s,0)),c},fill:!0,tension:.45,pointRadius:0,pointHoverRadius:6,pointHoverBorderWidth:3,pointHoverBackgroundColor:o.corDetalhes,pointHoverBorderColor:a.value.bg==="transparent"?"#fff":a.value.bg,clip:!1}]}));function E(m){const{chart:i,tooltip:n}=m,u=K(i);if(!u)return;const g=ae(u);if(n.opacity===0||D){g.style.opacity="0";return}const s=n.title||[],c=(n.body||[]).flatMap(W=>W.lines),r=g.querySelector(".nc-tt__content"),p=o.corDetalhes||"#3B82F6";r.innerHTML=`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${s.join(" ")}</div><div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${p};box-shadow:0 0 0 2px ${z(p,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${c.join(" ")}</span></div>`;const{offsetLeft:y,offsetTop:T}=i.canvas;g.style.opacity="1",g.style.visibility="hidden",g.style.left="0px",g.style.top="0px";const C=g.offsetWidth,S=g.offsetHeight,h=4,L=y+n.caretX,H=T+n.caretY,w=_(L,C,u.clientWidth,h),q=S+16+h,Q=H<q;let I;Q?(g.style.transform="translateX(-50%) translateY(16px)",I=H):(g.style.transform="translate(-50%, calc(-100% - 16px))",I=H),g.style.left=w+"px",g.style.top=I+"px";const A=g.querySelector(".nc-tt__caret");if(A){const W=L-w,F=C/2,P=Math.max(-F+8,Math.min(F-8,W));A.style.left=`calc(50% + ${P}px)`,Q?(A.style.bottom="",A.style.top="-5px",A.style.borderRight="",A.style.borderBottom="",A.style.borderLeft="1px solid rgba(15,23,42,.06)",A.style.borderTop="1px solid rgba(15,23,42,.06)"):(A.style.top="",A.style.bottom="-5px",A.style.borderLeft="",A.style.borderTop="",A.style.borderRight="1px solid rgba(15,23,42,.06)",A.style.borderBottom="1px solid rgba(15,23,42,.06)")}g.style.visibility="visible"}const N=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,interaction:{intersect:!1,mode:"index"},layout:{padding:{top:V.value.length?24:0,right:0,bottom:0,left:0}},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:E,callbacks:{title:m=>{var i;return((i=m[0])==null?void 0:i.label)??""},label:m=>b(m.parsed.y)}}},scales:{x:{display:!0,afterFit:m=>{m.paddingLeft=0,m.paddingRight=0},grid:{display:!1,drawBorder:!1},border:{display:!1},ticks:{color:a.value.muted,font:{size:10,family:"'Inter', sans-serif"},padding:8,align:"inner"}},y:{display:!1,grid:{display:!1},beginAtZero:!0,suggestedMax:V.value.length?Math.max(...V.value.map(m=>m.valor)):void 0}}}));function O(){l("botaoAcao")}return(m,i)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:k,class:e.normalizeClass(["card-linhas p-4 flex",$.value]),style:e.normalizeStyle(e.unref(x))},[e.createElementVNode("div",Ve,[e.createElementVNode("div",Ne,[m.$slots.legenda||t.legenda||m.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",Te,[m.$slots.legenda||t.legenda?(e.openBlock(),e.createElementBlock("div",{key:0,class:"text-xs font-medium",style:e.normalizeStyle({color:e.unref(a).text,opacity:.85})},[e.renderSlot(m.$slots,"legenda",{},()=>[e.createTextVNode(e.toDisplayString(t.legenda),1)],!0)],4)):e.createCommentVNode("",!0),m.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-xs",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(m.$slots,"sublegenda",{},()=>[e.createTextVNode(e.toDisplayString(t.sublegenda),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),m.$slots.actions||t.botaoVisivel||t.exportar?(e.openBlock(),e.createElementBlock("div",ze,[e.renderSlot(m.$slots,"actions",{},()=>[t.botaoVisivel?(e.openBlock(),e.createElementBlock("button",{key:0,class:"nc-btn inline-flex align-items-center",style:e.normalizeStyle({color:e.unref(a).text,borderColor:e.unref(z)(e.unref(a).text,.18)}),onClick:O},[e.createElementVNode("span",null,e.toDisplayString(t.textoBotao),1)],4)):e.createCommentVNode("",!0)],!0),t.exportar?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"nc-exportar inline-flex align-items-center justify-content-center",style:e.normalizeStyle({color:e.unref(a).muted,borderColor:e.unref(z)(e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:e.unref(R)},null,12,Ae)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),m.$slots.titulo||t.titulo||m.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",we,[m.$slots.titulo||t.titulo?(e.openBlock(),e.createElementBlock("div",{key:0,class:"m-0 text-3xl font-semibold",style:e.normalizeStyle({color:e.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[e.renderSlot(m.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(t.titulo),1)],!0)],4)):e.createCommentVNode("",!0),m.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-sm mt-1",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(m.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(t.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",Re,[e.createVNode(U,{type:"line",data:d.value,options:N.value,plugins:J.value,height:t.height},null,8,["data","options","plugins","height"])]),m.$slots.footer?(e.openBlock(),e.createElementBlock("div",Fe,[e.renderSlot(m.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-364ce1d1"]]),qe={class:"card-pizza__topo flex align-items-start justify-content-between gap-3"},De={key:0,class:"nc-legendas-flex flex flex-column"},Le={key:1,class:"nc-actions inline-flex align-items-center gap-2"},Me=["innerHTML"],He={class:"card-pizza__corpo flex align-items-center"},Pe={class:"nc-tabela flex flex-column"},je={class:"nc-tabela-valor"},Ie={class:"nc-tabela-rotulo inline-flex align-items-center gap-2"},Oe={class:"nc-tabela-valor"},We={class:"card-pizza__chart-wrap flex align-items-center justify-content-center"},Xe={class:"card-pizza__chart"},Ye={key:0,class:"nc-centro flex flex-column align-items-center justify-content-center"},Je={key:0,class:"card-pizza__footer mt-3"},ie=G({__name:"CardPizza",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corTexto:{type:String,default:null},corBorda:{type:String,default:"#EAE8E8"},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06)"},corDetalhes:{type:String,default:"#3B82F6"},textoBotao:{type:String,default:"Ver mais"},botaoVisivel:{type:Boolean,default:!1},direcao:{type:String,default:"right",validator:t=>["left","right","top","bottom"].includes(t)},rotuloCategoria:{type:String,default:"Categoria"},rotuloQuantidade:{type:String,default:"Quantidade"},mostrarCabecalho:{type:Boolean,default:!0},tipoValor:{type:String,default:"numero",validator:t=>["numero","moeda","percentual"].includes(t)},locale:{type:String,default:"pt-BR"},moeda:{type:String,default:"BRL"},data:{type:Array,default:()=>[{rotulo:"Vendas",quantidade:4200},{rotulo:"Serviços",quantidade:3100},{rotulo:"Assinaturas",quantidade:2450},{rotulo:"Licenças",quantidade:1800},{rotulo:"Suporte",quantidade:1250},{rotulo:"Treinamentos",quantidade:820},{rotulo:"Outros",quantidade:410}]},height:{type:[String,Number],default:260},cutout:{type:[String,Number],default:"70%"},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-pizza.png"}},emits:["botaoAcao","exportado"],setup(t,{emit:f}){const o=t,l=f,{palette:a,cardStyle:x}=Z(o),{formatar:b}=oe(o),k=e.ref(null);async function R(){await v(k.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),l("exportado")}const B=e.computed(()=>`card-pizza--${o.direcao}`),$=e.computed(()=>{const d=re(o.corDetalhes,o.data.length);return o.data.map((E,N)=>E.cor??d[N])}),V=e.computed(()=>({labels:o.data.map(d=>d.rotulo),datasets:[{data:o.data.map(d=>d.quantidade),backgroundColor:$.value,borderWidth:0,borderColor:"transparent",hoverOffset:6,borderRadius:0,spacing:0}]}));function j(d){const{chart:E,tooltip:N}=d,O=K(E);if(!O)return;const m=ae(O);if(N.opacity===0){m.style.opacity="0";return}const i=N.title||[],n=N.dataPoints&&N.dataPoints[0],u=n?$.value[n.dataIndex]:"#3B82F6",g=n?b(n.parsed):"",s=m.querySelector(".nc-tt__content");s.innerHTML=`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${i.join(" ")}</div><div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${u};box-shadow:0 0 0 2px ${z(u,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${g}</span></div>`;const{offsetLeft:c,offsetTop:r}=E.canvas;m.style.opacity="1",m.style.visibility="hidden",m.style.left="0px",m.style.top="0px";const p=m.offsetWidth,y=m.offsetHeight,T=4,C=_(c+N.caretX,p,O.clientWidth,T);let S=r+N.caretY;const h=y+16+T;S<h&&(S=h),m.style.left=C+"px",m.style.top=S+"px",m.style.visibility="visible"}const D=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,cutout:o.cutout,layout:{padding:4},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:j,callbacks:{title:d=>{var E;return((E=d[0])==null?void 0:E.label)??""},label:d=>b(d.parsed)}}}}));function Y(){l("botaoAcao")}const J=ee;return(d,E)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:k,class:e.normalizeClass(["card-pizza p-4 flex flex-column",B.value]),style:e.normalizeStyle(e.unref(x))},[e.createElementVNode("div",qe,[d.$slots.legenda||t.legenda||d.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",De,[d.$slots.legenda||t.legenda?(e.openBlock(),e.createElementBlock("div",{key:0,class:"text-xs font-medium",style:e.normalizeStyle({color:e.unref(a).text,opacity:.95})},[e.renderSlot(d.$slots,"legenda",{},()=>[e.createTextVNode(e.toDisplayString(t.legenda),1)],!0)],4)):e.createCommentVNode("",!0),d.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-xs",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(d.$slots,"sublegenda",{},()=>[e.createTextVNode(e.toDisplayString(t.sublegenda),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),d.$slots.actions||t.botaoVisivel||t.exportar?(e.openBlock(),e.createElementBlock("div",Le,[e.renderSlot(d.$slots,"actions",{},()=>[t.botaoVisivel?(e.openBlock(),e.createElementBlock("button",{key:0,class:"nc-btn inline-flex align-items-center",style:e.normalizeStyle({color:e.unref(a).text,borderColor:e.unref(z)(e.unref(a).text,.18)}),onClick:Y},[e.createElementVNode("span",null,e.toDisplayString(t.textoBotao),1)],4)):e.createCommentVNode("",!0)],!0),t.exportar?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"nc-exportar inline-flex align-items-center justify-content-center",style:e.normalizeStyle({color:e.unref(a).muted,borderColor:e.unref(z)(e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:R,innerHTML:e.unref(J)},null,12,Me)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",He,[e.createElementVNode("div",Pe,[t.mostrarCabecalho?(e.openBlock(),e.createElementBlock("div",{key:0,class:"nc-tabela-cab flex align-items-center justify-content-between",style:e.normalizeStyle({color:e.unref(a).muted,borderColor:e.unref(z)(e.unref(a).muted,.25)})},[e.createElementVNode("span",null,e.toDisplayString(t.rotuloCategoria),1),e.createElementVNode("span",je,e.toDisplayString(t.rotuloQuantidade),1)],4)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.data,(N,O)=>(e.openBlock(),e.createElementBlock("div",{key:O,class:"nc-tabela-linha flex align-items-center justify-content-between",style:e.normalizeStyle({color:e.unref(a).text})},[e.createElementVNode("span",Ie,[e.createElementVNode("span",{class:"nc-bolinha",style:e.normalizeStyle({background:$.value[O]})},null,4),e.createElementVNode("span",null,e.toDisplayString(N.rotulo),1)]),e.createElementVNode("span",Oe,e.toDisplayString(e.unref(b)(N.quantidade)),1)],4))),128))]),e.createElementVNode("div",We,[e.createElementVNode("div",Xe,[e.createVNode(U,{type:"doughnut",data:V.value,options:D.value,height:t.height},null,8,["data","options","height"]),d.$slots.titulo||t.titulo||d.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",Ye,[d.$slots.titulo||t.titulo?(e.openBlock(),e.createElementBlock("div",{key:0,class:"nc-centro-titulo m-0 font-semibold",style:e.normalizeStyle({color:e.unref(a).text})},[e.renderSlot(d.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(t.titulo),1)],!0)],4)):e.createCommentVNode("",!0),d.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",{key:1,class:"nc-centro-desc",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(d.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(t.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])])]),d.$slots.footer?(e.openBlock(),e.createElementBlock("div",Je,[e.renderSlot(d.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-2a65258f"]]),Qe={class:"card-barra__header flex flex-column"},Ge={class:"card-barra__topo flex align-items-start justify-content-between gap-3"},Ue={key:0,class:"nc-legendas-flex flex flex-column"},Ze={key:1,class:"nc-actions inline-flex align-items-center gap-2"},Ke=["innerHTML"],_e={key:0,class:"card-barra__titulos mt-3 mb-2 flex flex-column"},ve={class:"card-barra__chart flex-1"},et={key:0,class:"card-barra__footer mt-3"},ce=G({__name:"CardBarra",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corDetalhes:{type:String,default:"#3B82F6"},corTexto:{type:String,default:null},textoBotao:{type:String,default:"Ver mais"},direcao:{type:String,default:"top",validator:t=>["top","bottom","left","right"].includes(t)},botaoVisivel:{type:Boolean,default:!1},tipoValor:{type:String,default:"numero",validator:t=>["numero","moeda","percentual"].includes(t)},locale:{type:String,default:"pt-BR"},moeda:{type:String,default:"BRL"},data:{type:Array,default:()=>[{rotulo:"Jan",quantidade:22},{rotulo:"Fev",quantidade:35},{rotulo:"Mar",quantidade:28},{rotulo:"Abr",quantidade:45},{rotulo:"Mai",quantidade:30},{rotulo:"Jun",quantidade:55},{rotulo:"Jul",quantidade:42},{rotulo:"Ago",quantidade:60},{rotulo:"Set",quantidade:48},{rotulo:"Out",quantidade:70},{rotulo:"Nov",quantidade:58},{rotulo:"Dez",quantidade:75}]},series:{type:Array,default:null},cores:{type:Array,default:()=>["#3B82F6","#10B981","#F59E0B","#EF4444","#8B5CF6","#06B6D4","#EC4899"]},orientacao:{type:String,default:"vertical",validator:t=>["vertical","horizontal"].includes(t)},empilhado:{type:Boolean,default:!1},mostrarLegendaSeries:{type:Boolean,default:!0},height:{type:[String,Number],default:280},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06)"},corBorda:{type:String,default:"#EAE8E8"},larguraBarra:{type:[String,Number],default:.92},raioBarra:{type:Number,default:6},linhasReferencia:{type:[Object,Array],default:null},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-barra.png"},corHover:{type:String,default:null}},emits:["botaoAcao","exportado"],setup(t,{emit:f}){e.useCssVars(s=>({c9bf3d56:V.value}));const o=t,l=f,{palette:a,cardStyle:x}=Z(o),{formatar:b}=oe(o),k=e.ref(null),R=ee;async function B(){await v(k.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),l("exportado")}const $=e.computed(()=>`card-barra--${o.direcao}`),V=e.computed(()=>typeof o.height=="number"?`${o.height}px`:o.height),j=e.computed(()=>o.orientacao==="horizontal"),D=e.computed(()=>Array.isArray(o.series)&&o.series.length>0?o.series.map((s,c)=>({nome:s.nome??`Série ${c+1}`,cor:s.cor||o.cores[c%o.cores.length],dados:Array.isArray(s.dados)?s.dados:[]})):[{nome:o.legenda||"Valores",cor:o.corDetalhes,dados:o.data}]),Y=e.computed(()=>{const s=D.value[0];return s?s.dados.map(c=>c.rotulo):[]}),J=e.computed(()=>{const s=D.value,c=s.length-1,r=typeof o.larguraBarra=="number"?o.larguraBarra:Number(o.larguraBarra)||.6,p=o.raioBarra,y=j.value;function T(C){if(!o.empilhado||s.length===1)return p;const S=C===0,h=C===c;return y?{topLeft:S?p:0,bottomLeft:S?p:0,topRight:h?p:0,bottomRight:h?p:0}:{bottomLeft:S?p:0,bottomRight:S?p:0,topLeft:h?p:0,topRight:h?p:0}}return{labels:Y.value,datasets:s.map((C,S)=>({label:C.nome,data:C.dados.map(h=>h.quantidade),previstos:C.dados.map(h=>h.previsto!=null?h.previsto:null),backgroundColor:z(C.cor,.72),hoverBackgroundColor:o.corHover||C.cor,borderWidth:0,borderRadius:T(S),borderSkipped:!1,categoryPercentage:1,barPercentage:r}))}});function d(s,c){c?Object.assign(s.style,{top:"-5px",bottom:"auto",borderTop:"1px solid rgba(15,23,42,.06)",borderLeft:"1px solid rgba(15,23,42,.06)",borderRight:"none",borderBottom:"none"}):Object.assign(s.style,{bottom:"-5px",top:"auto",borderRight:"1px solid rgba(15,23,42,.06)",borderBottom:"1px solid rgba(15,23,42,.06)",borderTop:"none",borderLeft:"none"})}let E=null;function N(s){var he,xe;const{chart:c,tooltip:r}=s,p=K(c);if(!p)return;const y=ae(p,{caretFlexivel:!0});if(r.opacity===0||E){y.style.opacity="0";return}const T=r.title||[],C=r.dataPoints||[],S=y.querySelector(".nc-tt__content"),h=C.map(te=>{var Se;const ne=((Se=D.value[te.datasetIndex])==null?void 0:Se.cor)||o.corDetalhes,Pt=b(j.value?te.parsed.x:te.parsed.y),jt=te.dataset.label&&D.value.length>1?`<span style="font-size:11px;color:#64748B;margin-right:6px;">${te.dataset.label}</span>`:"";return`<div style="display:flex;align-items:center;gap:6px;margin-top:2px;"><span style="width:6px;height:6px;border-radius:999px;background:${ne};box-shadow:0 0 0 2px ${z(ne,.15)};flex:0 0 auto;"></span>`+jt+`<span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;margin-left:auto;">${Pt}</span></div>`}).join(""),L=(he=C[0])==null?void 0:he.dataIndex;let H=null;if(L!=null)for(const te of c.data.datasets){const ne=(xe=te.previstos)==null?void 0:xe[L];if(ne!=null){H=ne;break}}const w=H!=null?`<div style="display:flex;align-items:center;gap:6px;margin-top:6px;padding-top:4px;border-top:1px dashed rgba(15,23,42,.08);"><span style="font-size:11px;color:#64748B;margin-right:6px;">Previsto</span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;margin-left:auto;">${b(H)}</span></div>`:"";S.innerHTML=`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${T.join(" ")}</div>`+h+w;const{offsetLeft:q,offsetTop:Q}=c.canvas;y.style.opacity="1",y.style.visibility="hidden",y.style.left="0px",y.style.top="0px";const I=y.offsetWidth,A=y.offsetHeight,W=4,F=q+r.caretX,P=Q+r.caretY,pe=_(F,I,p.clientWidth,W),Dt=I/2,ue=14,ge=P-ue-A,ye=ge<W,Lt=ye?P+ue:ge,be=y.querySelector(".nc-tt__caret");d(be,ye);const Mt=F-(pe-Dt),Ht=Math.max(10,Math.min(I-10,Mt));be.style.left=Ht+"px",y.style.left=pe+"px",y.style.top=Lt+"px",y.style.visibility="visible"}const O=e.computed(()=>{const s=j.value,c={grid:{display:!1,drawBorder:!1},border:{display:!1},ticks:{color:a.value.muted,font:{size:10,family:"'Inter', sans-serif"},padding:8},stacked:o.empilhado},r={display:!1,grid:{display:!1},beginAtZero:!0,stacked:o.empilhado,suggestedMax:i.value.length?Math.max(...i.value.map(p=>p.valor)):void 0};return{responsive:!0,maintainAspectRatio:!1,indexAxis:s?"y":"x",interaction:{intersect:!1,mode:"index",axis:s?"y":"x"},layout:{padding:{top:i.value.length&&!s?24:12,right:s?12:0,bottom:0,left:i.value.length&&s?60:0}},plugins:{legend:{display:o.mostrarLegendaSeries&&D.value.length>1,position:"bottom",align:"start",labels:{color:a.value.muted,boxWidth:8,boxHeight:8,usePointStyle:!0,pointStyle:"circle",font:{size:10,family:"'Inter', sans-serif"},padding:12}},tooltip:{enabled:!1,external:N,callbacks:{title:p=>{var y;return((y=p[0])==null?void 0:y.label)??""},label:p=>b(s?p.parsed.x:p.parsed.y)}}},scales:{x:s?r:c,y:s?c:r}}});function m(){l("botaoAcao")}const i=e.computed(()=>o.linhasReferencia?(Array.isArray(o.linhasReferencia)?o.linhasReferencia:[o.linhasReferencia]).filter(c=>c&&(typeof c=="number"||typeof c.valor=="number")).map(c=>typeof c=="number"?{valor:c,rotulo:null,cor:"#0F172A",corRotulo:"#0F172A",corTexto:"#FFFFFF",tracejado:[6,6],espessura:1}:{valor:c.valor,rotulo:c.rotulo??null,cor:c.cor||"#0F172A",corRotulo:c.corRotulo||c.cor||"#0F172A",corTexto:c.corTexto||"#FFFFFF",tracejado:c.tracejado||[6,6],espessura:c.espessura??1}):[]),n=[],u={id:"linhaReferencia",afterDatasetsDraw(s){const c=i.value;if(n.length=0,!c.length)return;const{ctx:r,chartArea:p,scales:y}=s,T=j.value,C=T?y.x:y.y;C&&c.forEach(S=>{const h=C.getPixelForValue(S.valor);if(n.push({linha:S,pos:h,horizontal:T,chartArea:p}),r.save(),r.beginPath(),r.setLineDash(S.tracejado),r.lineWidth=S.espessura,r.strokeStyle=S.cor,T){if(h<p.left||h>p.right){r.restore();return}r.moveTo(h,p.top),r.lineTo(h,p.bottom)}else{if(h<p.top||h>p.bottom){r.restore();return}r.moveTo(p.left,h),r.lineTo(p.right,h)}if(r.stroke(),r.setLineDash([]),S.rotulo){r.font="600 11px 'Inter', sans-serif";const L=8,H=5,q=r.measureText(S.rotulo).width,Q=12,I=q+L*2,A=Q+H*2,W=A/2;let F,P;T?(F=h-I/2,P=p.top-A-6,P<0&&(P=p.top+6)):(F=p.left-I-6,P=h-A/2,F<0&&(F=p.left+6)),r.fillStyle=S.corRotulo,r.beginPath(),r.roundRect?r.roundRect(F,P,I,A,W):(r.moveTo(F+W,P),r.lineTo(F+I-W,P),r.quadraticCurveTo(F+I,P,F+I,P+W),r.lineTo(F+I,P+A-W),r.quadraticCurveTo(F+I,P+A,F+I-W,P+A),r.lineTo(F+W,P+A),r.quadraticCurveTo(F,P+A,F,P+A-W),r.lineTo(F,P+W),r.quadraticCurveTo(F,P,F+W,P)),r.fill(),r.fillStyle=S.corTexto,r.textBaseline="middle",r.textAlign="center",r.fillText(S.rotulo,F+I/2,P+A/2)}r.restore()})},beforeEvent(s,c){if(!n.length){E=null;return}const r=c.event;if(!r||r.type==="mouseout"||r.x==null||r.y==null){E=null;return}const p=8;let y=null,T=1/0;for(const C of n){const S=C.horizontal?Math.abs(r.x-C.pos):Math.abs(r.y-C.pos),h=C.horizontal?r.y>=C.chartArea.top&&r.y<=C.chartArea.bottom:r.x>=C.chartArea.left&&r.x<=C.chartArea.right;S<=p&&h&&S<T&&(T=S,y=C)}E=y},afterEvent(s,c){if(!n.length)return;const r=c.event;if(!r)return;const p=K(s);if(!p)return;let y=p.querySelector(".nc-tt-linhaRef");if(!E){y&&(y.style.opacity="0");return}const T=E;y||(y=document.createElement("div"),y.className="nc-tt-linhaRef",Object.assign(y.style,{position:"absolute",pointerEvents:"none",transform:"translate(-50%, calc(-100% - 12px))",transition:"opacity .18s ease, left .12s ease, top .12s ease",opacity:"0",background:"#ffffff",borderRadius:"10px",padding:"8px 11px",boxShadow:"0 1px 2px rgba(15,23,42,.06), 0 8px 24px rgba(15,23,42,.12)",border:"1px solid rgba(15,23,42,.06)",whiteSpace:"nowrap",zIndex:"11",fontFamily:"'Inter', sans-serif",textAlign:"left"}),p.appendChild(y));const C=T.linha.cor||"#0F172A",S=b(T.linha.valor),h=T.linha.rotulo;y.innerHTML=(h?`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${h}</div>`:"")+`<div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${C};box-shadow:0 0 0 2px ${z(C,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${S}</span></div>`;const L=s.canvas;y.style.opacity="1",y.style.visibility="hidden",y.style.left="0px",y.style.top="0px";const H=y.offsetWidth,w=y.offsetHeight,q=4;let Q,I;T.horizontal?(Q=L.offsetLeft+T.pos,I=L.offsetTop+r.y):(Q=L.offsetLeft+r.x,I=L.offsetTop+T.pos);const A=_(Q,H,p.clientWidth,q);let W=I;const F=w+16+q;W<F&&(W=F),y.style.left=A+"px",y.style.top=W+"px",y.style.visibility="visible"}},g=e.computed(()=>i.value.length?[u]:[]);return(s,c)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:k,class:e.normalizeClass(["card-barra p-4 flex",$.value]),style:e.normalizeStyle(e.unref(x))},[e.createElementVNode("div",Qe,[e.createElementVNode("div",Ge,[s.$slots.legenda||t.legenda||s.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",Ue,[s.$slots.legenda||t.legenda?(e.openBlock(),e.createElementBlock("div",{key:0,class:"text-xs font-medium",style:e.normalizeStyle({color:e.unref(a).text,opacity:.85})},[e.renderSlot(s.$slots,"legenda",{},()=>[e.createTextVNode(e.toDisplayString(t.legenda),1)],!0)],4)):e.createCommentVNode("",!0),s.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-xs",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(s.$slots,"sublegenda",{},()=>[e.createTextVNode(e.toDisplayString(t.sublegenda),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),s.$slots.actions||t.botaoVisivel||t.exportar?(e.openBlock(),e.createElementBlock("div",Ze,[e.renderSlot(s.$slots,"actions",{},()=>[t.botaoVisivel?(e.openBlock(),e.createElementBlock("button",{key:0,class:"nc-btn inline-flex align-items-center",style:e.normalizeStyle({color:e.unref(a).text,borderColor:e.unref(z)(e.unref(a).text,.18)}),onClick:m},[e.createElementVNode("span",null,e.toDisplayString(t.textoBotao),1)],4)):e.createCommentVNode("",!0)],!0),t.exportar?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"nc-exportar inline-flex align-items-center justify-content-center",style:e.normalizeStyle({color:e.unref(a).muted,borderColor:e.unref(z)(e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:e.unref(R)},null,12,Ke)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),s.$slots.titulo||t.titulo||s.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",_e,[s.$slots.titulo||t.titulo?(e.openBlock(),e.createElementBlock("div",{key:0,class:"m-0 text-3xl font-semibold",style:e.normalizeStyle({color:e.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[e.renderSlot(s.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(t.titulo),1)],!0)],4)):e.createCommentVNode("",!0),s.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-sm mt-1",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(s.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(t.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",ve,[e.createVNode(U,{type:"bar",data:J.value,options:O.value,plugins:g.value,height:"100%"},null,8,["data","options","plugins"])]),s.$slots.footer?(e.openBlock(),e.createElementBlock("div",et,[e.renderSlot(s.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-474043e8"]]),tt={class:"card-polar__topo flex align-items-start justify-content-between gap-3"},ot={key:0,class:"nc-legendas-flex flex flex-column"},at={key:1,class:"nc-actions inline-flex align-items-center gap-2"},nt=["innerHTML"],rt={class:"card-polar__corpo flex align-items-center"},lt={class:"nc-tabela flex flex-column"},st={class:"nc-tabela-valor"},it={class:"nc-tabela-rotulo inline-flex align-items-center gap-2"},ct={class:"nc-tabela-valor"},dt={class:"card-polar__chart-wrap flex align-items-center justify-content-center"},mt={class:"card-polar__chart"},ft={key:0,class:"card-polar__centro-bottom"},pt={key:0,class:"card-polar__footer mt-3"},de=G({__name:"CardPolar",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corTexto:{type:String,default:null},corBorda:{type:String,default:"#EAE8E8"},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06)"},corDetalhes:{type:String,default:"#3B82F6"},textoBotao:{type:String,default:"Ver mais"},botaoVisivel:{type:Boolean,default:!1},direcao:{type:String,default:"right",validator:t=>["left","right","top","bottom"].includes(t)},rotuloCategoria:{type:String,default:"Categoria"},rotuloQuantidade:{type:String,default:"Quantidade"},mostrarCabecalho:{type:Boolean,default:!0},tipoValor:{type:String,default:"numero",validator:t=>["numero","moeda","percentual"].includes(t)},locale:{type:String,default:"pt-BR"},moeda:{type:String,default:"BRL"},data:{type:Array,default:()=>[{rotulo:"Vendas",quantidade:4200},{rotulo:"Serviços",quantidade:3100},{rotulo:"Assinaturas",quantidade:2450},{rotulo:"Licenças",quantidade:1800},{rotulo:"Suporte",quantidade:1250},{rotulo:"Treinamentos",quantidade:820},{rotulo:"Outros",quantidade:410}]},height:{type:[String,Number],default:260},mostrarLinhasGrade:{type:Boolean,default:!0},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-polar.png"}},emits:["botaoAcao","exportado"],setup(t,{emit:f}){const o=t,l=f,{palette:a,cardStyle:x}=Z(o),{formatar:b}=oe(o),k=e.ref(null),R=ee;async function B(){await v(k.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),l("exportado")}const $=e.computed(()=>`card-polar--${o.direcao}`),V=e.computed(()=>{const d=re(o.corDetalhes,o.data.length);return o.data.map((E,N)=>E.cor??d[N])}),j=e.computed(()=>({labels:o.data.map(d=>d.rotulo),datasets:[{data:o.data.map(d=>d.quantidade),backgroundColor:V.value,borderColor:V.value,borderWidth:0,hoverOffset:6}]}));function D(d){const{chart:E,tooltip:N}=d,O=K(E);if(!O)return;const m=ae(O);if(N.opacity===0){m.style.opacity="0";return}const i=N.title||[],n=N.dataPoints&&N.dataPoints[0],u=n?V.value[n.dataIndex]:"#3B82F6",g=n?b(n.parsed.r??n.parsed):"",s=m.querySelector(".nc-tt__content");s.innerHTML=`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${i.join(" ")}</div><div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${u};box-shadow:0 0 0 2px ${z(u,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${g}</span></div>`;const{offsetLeft:c,offsetTop:r}=E.canvas;m.style.opacity="1",m.style.visibility="hidden",m.style.left="0px",m.style.top="0px";const p=m.offsetWidth,y=m.offsetHeight,T=4,C=_(c+N.caretX,p,O.clientWidth,T);let S=r+N.caretY;const h=y+16+T;S<h&&(S=h),m.style.left=C+"px",m.style.top=S+"px",m.style.visibility="visible"}const Y=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,layout:{padding:4},scales:{r:{beginAtZero:!0,ticks:{display:!1,backdropColor:"transparent"},grid:{display:o.mostrarLinhasGrade,color:z(a.value.muted,.18)},angleLines:{display:o.mostrarLinhasGrade,color:z(a.value.muted,.18)},pointLabels:{display:!1}}},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:D,callbacks:{title:d=>{var E;return((E=d[0])==null?void 0:E.label)??""},label:d=>{var E;return b(((E=d.parsed)==null?void 0:E.r)??d.parsed)}}}}}));function J(){l("botaoAcao")}return(d,E)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:k,class:e.normalizeClass(["card-polar p-4 flex flex-column",$.value]),style:e.normalizeStyle(e.unref(x))},[e.createElementVNode("div",tt,[d.$slots.legenda||t.legenda||d.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",ot,[d.$slots.legenda||t.legenda?(e.openBlock(),e.createElementBlock("div",{key:0,class:"text-xs font-medium",style:e.normalizeStyle({color:e.unref(a).text,opacity:.95})},[e.renderSlot(d.$slots,"legenda",{},()=>[e.createTextVNode(e.toDisplayString(t.legenda),1)],!0)],4)):e.createCommentVNode("",!0),d.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-xs",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(d.$slots,"sublegenda",{},()=>[e.createTextVNode(e.toDisplayString(t.sublegenda),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),d.$slots.actions||t.botaoVisivel||t.exportar?(e.openBlock(),e.createElementBlock("div",at,[e.renderSlot(d.$slots,"actions",{},()=>[t.botaoVisivel?(e.openBlock(),e.createElementBlock("button",{key:0,class:"nc-btn inline-flex align-items-center",style:e.normalizeStyle({color:e.unref(a).text,borderColor:e.unref(z)(e.unref(a).text,.18)}),onClick:J},[e.createElementVNode("span",null,e.toDisplayString(t.textoBotao),1)],4)):e.createCommentVNode("",!0)],!0),t.exportar?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"nc-exportar inline-flex align-items-center justify-content-center",style:e.normalizeStyle({color:e.unref(a).muted,borderColor:e.unref(z)(e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:e.unref(R)},null,12,nt)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",rt,[e.createElementVNode("div",lt,[t.mostrarCabecalho?(e.openBlock(),e.createElementBlock("div",{key:0,class:"nc-tabela-cab flex align-items-center justify-content-between",style:e.normalizeStyle({color:e.unref(a).muted,borderColor:e.unref(z)(e.unref(a).muted,.25)})},[e.createElementVNode("span",null,e.toDisplayString(t.rotuloCategoria),1),e.createElementVNode("span",st,e.toDisplayString(t.rotuloQuantidade),1)],4)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.data,(N,O)=>(e.openBlock(),e.createElementBlock("div",{key:O,class:"nc-tabela-linha flex align-items-center justify-content-between",style:e.normalizeStyle({color:e.unref(a).text})},[e.createElementVNode("span",it,[e.createElementVNode("span",{class:"nc-bolinha",style:e.normalizeStyle({background:V.value[O]})},null,4),e.createElementVNode("span",null,e.toDisplayString(N.rotulo),1)]),e.createElementVNode("span",ct,e.toDisplayString(e.unref(b)(N.quantidade)),1)],4))),128))]),e.createElementVNode("div",dt,[e.createElementVNode("div",mt,[e.createVNode(U,{type:"polarArea",data:j.value,options:Y.value,height:t.height},null,8,["data","options","height"]),d.$slots.titulo||t.titulo||d.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",ft,[d.$slots.titulo||t.titulo?(e.openBlock(),e.createElementBlock("div",{key:0,class:"card-polar__centro-titulo m-0 text-3xl font-semibold",style:e.normalizeStyle({color:e.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[e.renderSlot(d.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(t.titulo),1)],!0)],4)):e.createCommentVNode("",!0),d.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",{key:1,class:"card-polar__centro-desc",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(d.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(t.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])])]),d.$slots.footer?(e.openBlock(),e.createElementBlock("div",pt,[e.renderSlot(d.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-94cbf2b0"]]),ut={class:"card-progresso__topo flex align-items-start justify-content-between gap-3"},gt={key:0,class:"nc-legendas-flex flex flex-column"},yt={key:1,class:"nc-actions inline-flex align-items-center gap-2"},bt=["innerHTML"],ht={key:0,class:"card-progresso__titulos mt-3 mb-2 flex flex-column"},xt={class:"card-progresso__corpo flex align-items-center flex-wrap"},St={key:0,class:"card-progresso__chart-wrap flex align-items-center justify-content-center"},kt={class:"card-progresso__chart"},Bt={class:"nc-centro flex flex-column align-items-center justify-content-center"},Et={class:"card-progresso__lista flex flex-column"},Ct={class:"card-progresso__item-cab flex align-items-center justify-content-between"},$t={key:0,class:"card-progresso__item-valor inline-flex align-items-center gap-2"},Vt={key:0},Nt={key:1,class:"card-progresso__footer mt-3"},me=G({__name:"CardProgresso",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corTexto:{type:String,default:null},corBorda:{type:String,default:"#EAE8E8"},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06)"},corDetalhes:{type:String,default:"#3B82F6"},corExcesso:{type:String,default:"#EF4444"},textoBotao:{type:String,default:"Ver mais"},botaoVisivel:{type:Boolean,default:!1},direcao:{type:String,default:"top",validator:t=>["top","bottom","left","right"].includes(t)},formato:{type:String,default:"linear",validator:t=>["linear","circular"].includes(t)},tipoValor:{type:String,default:"numero",validator:t=>["numero","moeda","percentual"].includes(t)},locale:{type:String,default:"pt-BR"},moeda:{type:String,default:"BRL"},data:{type:Array,default:()=>[{rotulo:"Vendas",quantidade:72,meta:100},{rotulo:"Serviços",quantidade:48,meta:80},{rotulo:"Assinaturas",quantidade:35,meta:60},{rotulo:"Suporte",quantidade:18,meta:40}]},metaPadrao:{type:Number,default:100},mostrarValor:{type:Boolean,default:!0},mostrarPercentual:{type:Boolean,default:!0},alturaBarra:{type:[String,Number],default:8},raioBarra:{type:[String,Number],default:"999px"},height:{type:[String,Number],default:220},cutout:{type:[String,Number],default:"78%"},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-progresso.png"}},emits:["botaoAcao","exportado"],setup(t,{emit:f}){const o=t,l=f,{palette:a,cardStyle:x}=Z(o),{formatar:b}=oe(o),k=e.ref(null),R=ee;async function B(){await v(k.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),l("exportado")}const $=e.computed(()=>`card-progresso--${o.direcao}`),V=e.computed(()=>{const i=re(o.corDetalhes,o.data.length);return o.data.map((n,u)=>{const g=Number(n.meta??o.metaPadrao)||0,s=Number(n.quantidade)||0,c=n.cor??i[u],r=n.modo==="reducao";let p;if(r){const y=Number(n.valor_referencia)||0,T=y-g;p=T>0?Math.max(0,Math.min(100,(y-s)/T*100)):0}else p=g>0?Math.max(0,Math.min(100,s/g*100)):0;return{rotulo:n.rotulo,quantidade:s,meta:g,valorReferencia:n.valor_referencia??null,cor:c,percentual:p,reducao:r}})}),j=e.computed(()=>typeof o.alturaBarra=="number"?`${o.alturaBarra}px`:o.alturaBarra),D=e.computed(()=>typeof o.raioBarra=="number"?`${o.raioBarra}px`:o.raioBarra),Y=e.computed(()=>V.value.reduce((i,n)=>i+n.quantidade,0)),J=e.computed(()=>V.value.reduce((i,n)=>i+n.meta,0)),d=e.computed(()=>{if(!V.value.length)return 0;const i=u=>u.reducao&&u.valorReferencia!=null?Math.max(0,Number(u.valorReferencia)-u.meta):u.meta,n=V.value.reduce((u,g)=>u+i(g),0);return n<=0?0:V.value.reduce((u,g)=>u+g.percentual*i(g),0)/n}),E=e.computed(()=>V.value.every(i=>i.reducao)),N=e.computed(()=>{const i=Math.min(d.value,100),n=Math.max(0,100-i),u=E.value?o.corExcesso:o.corDetalhes;return{labels:["Progresso","Restante"],datasets:[{data:[i,n],backgroundColor:[u,z(a.value.muted,.15)],borderWidth:0,borderColor:"transparent",hoverOffset:0,spacing:0}]}}),O=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,cutout:o.cutout,rotation:-90,circumference:360,layout:{padding:4},plugins:{legend:{display:!1},tooltip:{enabled:!1}}}));function m(){l("botaoAcao")}return(i,n)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:k,class:e.normalizeClass(["card-progresso p-4 flex flex-column",$.value]),style:e.normalizeStyle(e.unref(x))},[e.createElementVNode("div",ut,[i.$slots.legenda||t.legenda||i.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",gt,[i.$slots.legenda||t.legenda?(e.openBlock(),e.createElementBlock("div",{key:0,class:"text-xs font-medium",style:e.normalizeStyle({color:e.unref(a).text,opacity:.95})},[e.renderSlot(i.$slots,"legenda",{},()=>[e.createTextVNode(e.toDisplayString(t.legenda),1)],!0)],4)):e.createCommentVNode("",!0),i.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-xs",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(i.$slots,"sublegenda",{},()=>[e.createTextVNode(e.toDisplayString(t.sublegenda),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),i.$slots.actions||t.botaoVisivel||t.exportar?(e.openBlock(),e.createElementBlock("div",yt,[e.renderSlot(i.$slots,"actions",{},()=>[t.botaoVisivel?(e.openBlock(),e.createElementBlock("button",{key:0,class:"nc-btn inline-flex align-items-center",style:e.normalizeStyle({color:e.unref(a).text,borderColor:e.unref(z)(e.unref(a).text,.18)}),onClick:m},[e.createElementVNode("span",null,e.toDisplayString(t.textoBotao),1)],4)):e.createCommentVNode("",!0)],!0),t.exportar?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"nc-exportar inline-flex align-items-center justify-content-center",style:e.normalizeStyle({color:e.unref(a).muted,borderColor:e.unref(z)(e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:e.unref(R)},null,12,bt)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),i.$slots.titulo||t.titulo||i.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",ht,[i.$slots.titulo||t.titulo?(e.openBlock(),e.createElementBlock("div",{key:0,class:"m-0 text-3xl font-semibold",style:e.normalizeStyle({color:e.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[e.renderSlot(i.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(t.titulo),1)],!0)],4)):e.createCommentVNode("",!0),i.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-sm mt-1",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(i.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(t.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",xt,[t.formato==="circular"?(e.openBlock(),e.createElementBlock("div",St,[e.createElementVNode("div",kt,[e.createVNode(U,{type:"doughnut",data:N.value,options:O.value,height:t.height},null,8,["data","options","height"]),e.createElementVNode("div",Bt,[e.createElementVNode("div",{class:"nc-centro-titulo",style:e.normalizeStyle({color:E.value?o.corExcesso:e.unref(a).text})},e.toDisplayString(Math.round(d.value))+"% ",5),e.createElementVNode("div",{class:"nc-centro-desc",style:e.normalizeStyle({color:e.unref(a).muted})},e.toDisplayString(e.unref(b)(Y.value))+" / "+e.toDisplayString(e.unref(b)(J.value)),5)])])])):e.createCommentVNode("",!0),e.createElementVNode("div",Et,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(V.value,(u,g)=>(e.openBlock(),e.createElementBlock("div",{key:g,class:"card-progresso__item flex flex-column"},[e.createElementVNode("div",Ct,[e.createElementVNode("span",{class:"card-progresso__item-rotulo inline-flex align-items-center gap-2",style:e.normalizeStyle({color:e.unref(a).text})},[e.createElementVNode("span",{class:"nc-bolinha",style:e.normalizeStyle({background:u.cor})},null,4),e.createElementVNode("span",null,e.toDisplayString(u.rotulo),1),u.reducao?(e.openBlock(),e.createElementBlock("span",{key:0,class:"card-progresso__item-modo",style:e.normalizeStyle({color:e.unref(a).muted})},"↓",4)):e.createCommentVNode("",!0)],4),t.mostrarValor||t.mostrarPercentual?(e.openBlock(),e.createElementBlock("span",$t,[t.mostrarValor?(e.openBlock(),e.createElementBlock("span",{key:0,class:"card-progresso__item-nums",style:e.normalizeStyle({color:e.unref(a).muted})},[e.createTextVNode(e.toDisplayString(e.unref(b)(u.quantidade)),1),u.meta?(e.openBlock(),e.createElementBlock("span",Vt," / "+e.toDisplayString(e.unref(b)(u.meta)),1)):e.createCommentVNode("",!0)],4)):e.createCommentVNode("",!0),t.mostrarPercentual?(e.openBlock(),e.createElementBlock("span",{key:1,class:"card-progresso__item-pct",style:e.normalizeStyle({background:e.unref(z)(u.cor,.12),color:u.cor})},e.toDisplayString(Math.round(u.percentual))+"% ",5)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",{class:"card-progresso__trilha w-full",style:e.normalizeStyle({height:j.value,borderRadius:D.value,background:u.reducao?e.unref(z)(o.corExcesso,.18):e.unref(z)(e.unref(a).muted,.15)})},[e.createElementVNode("div",{class:"card-progresso__preenchimento",style:e.normalizeStyle({width:u.percentual+"%",background:u.cor,borderRadius:D.value})},null,4)],4)]))),128))])]),i.$slots.footer?(e.openBlock(),e.createElementBlock("div",Nt,[e.renderSlot(i.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-36cee8f0"]]),Tt={key:0,class:"card-base__topo"},zt=["innerHTML"],At={class:"card-base__legendas flex flex-column"},wt={key:1,class:"card-base__titulos flex flex-column"},Rt={key:2,class:"card-base__acao flex"},Ft={key:3,class:"card-base__footer"},fe=G({__name:"CardBase",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corTexto:{type:String,default:null},corBorda:{type:String,default:"#EAE8E8"},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"none"},textoBotao:{type:String,default:"Ver Todos"},botaoVisivel:{type:Boolean,default:!0},alinhamento:{type:String,default:"left",validator:t=>["left","center","right"].includes(t)},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-base.png"}},emits:["botaoAcao","exportado"],setup(t,{emit:f}){const o=t,l=f,{palette:a,cardStyle:x}=Z(o),b=e.ref(null),k=ee;function R(){l("botaoAcao")}async function B(){await v(b.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),l("exportado")}return($,V)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:b,class:e.normalizeClass(["card-base flex flex-column",`card-base--${t.alinhamento}`]),style:e.normalizeStyle(e.unref(x))},[t.exportar?(e.openBlock(),e.createElementBlock("div",Tt,[e.createElementVNode("button",{type:"button",class:"nc-exportar card-base__exportar inline-flex align-items-center justify-content-center",style:e.normalizeStyle({color:e.unref(a).muted,borderColor:e.unref(z)(e.unref(a).text==="inherit"?"#0F172A":e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:e.unref(k)},null,12,zt)])):e.createCommentVNode("",!0),e.createElementVNode("div",At,[$.$slots.legenda||t.legenda?(e.openBlock(),e.createElementBlock("div",{key:0,class:"card-base__legenda font-medium text-xs",style:e.normalizeStyle({color:e.unref(a).text})},[e.renderSlot($.$slots,"legenda",{},()=>[e.createTextVNode(e.toDisplayString(t.legenda),1)],!0)],4)):e.createCommentVNode("",!0),$.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",{key:1,class:"card-base__sublegenda text-xs",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot($.$slots,"sublegenda",{},()=>[e.createTextVNode(e.toDisplayString(t.sublegenda),1)],!0)],4)):e.createCommentVNode("",!0)]),$.$slots.titulo||t.titulo||$.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",wt,[$.$slots.titulo||t.titulo?(e.openBlock(),e.createElementBlock("div",{key:0,class:"card-base__titulo m-0 text-3xl font-semibold",style:e.normalizeStyle({color:e.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[e.renderSlot($.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(t.titulo),1)],!0)],4)):e.createCommentVNode("",!0),$.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-sm",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot($.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(t.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),$.$slots.acao||t.botaoVisivel?(e.openBlock(),e.createElementBlock("div",Rt,[e.renderSlot($.$slots,"acao",{},()=>[t.botaoVisivel?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"card-base__link text-xs inline-flex align-items-center",style:e.normalizeStyle({color:e.unref(a).text}),onClick:R},[e.createElementVNode("span",null,e.toDisplayString(t.textoBotao),1),V[0]||(V[0]=e.createElementVNode("span",{class:"card-base__chevron","aria-hidden":"true"},"›",-1))],4)):e.createCommentVNode("",!0)],!0)])):e.createCommentVNode("",!0),$.$slots.footer?(e.openBlock(),e.createElementBlock("div",Ft,[e.renderSlot($.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-61091b7c"]]),qt={install(t){t.component("ChartBase",U),t.component("CardBase",fe),t.component("CardLinhas",se),t.component("CardPizza",ie),t.component("CardBarra",ce),t.component("CardPolar",de),t.component("CardProgresso",me)}};M.CardBarra=ce,M.CardBase=fe,M.CardLinhas=se,M.CardPizza=ie,M.CardPolar=de,M.CardProgresso=me,M.ChartBase=U,M.ICONE_EXPORTAR_SVG=ee,M.clampHorizontal=_,M.criarTooltipEl=ae,M.default=qt,M.exportarElementoComoImagem=v,M.gerarPaleta=re,M.prepararTooltipParent=K,M.toRgba=z,M.useFormatadorValor=oe,M.useTema=Z,Object.defineProperties(M,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
1
|
+
(function(H,t){typeof exports=="object"&&typeof module<"u"?t(exports,require("vue"),require("chart.js")):typeof define=="function"&&define.amd?define(["exports","vue","chart.js"],t):(H=typeof globalThis<"u"?globalThis:H||self,t(H.NemesisChart={},H.Vue,H.Chart))})(this,function(H,t,X){"use strict";const Q=(e,f)=>{const o=e.__vccOpts||e;for(const[i,a]of f)o[i]=a;return o},U=Q({__name:"ChartBase",props:{type:{type:String,required:!0},data:{type:Object,required:!0},options:{type:Object,default:()=>({})},plugins:{type:Array,default:()=>[]},height:{type:[String,Number],default:300},width:{type:[String,Number],default:null}},setup(e,{expose:f}){X.Chart.register(X.Title,X.Tooltip,X.Legend,X.Filler,X.LineController,X.LineElement,X.PointElement,X.BarController,X.BarElement,X.PieController,X.PolarAreaController,X.ArcElement,X.CategoryScale,X.LinearScale,X.RadialLinearScale);const o=e,i=t.ref(null),a=t.shallowRef(null),S={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{position:"top"}}};function b(){return{...S,...o.options}}function k(){i.value&&(a.value=new X.Chart(i.value,{type:o.type,data:o.data,options:b(),plugins:o.plugins}))}function F(){a.value&&(a.value.destroy(),a.value=null)}return t.onMounted(k),t.onBeforeUnmount(F),t.watch(()=>o.data,B=>{if(!a.value)return;a.value.data.labels=B.labels;const V=a.value.data.datasets,N=B.datasets;V.length!==N.length?a.value.data.datasets=N:N.forEach((j,M)=>Object.assign(V[M],j)),a.value.update()},{deep:!0}),t.watch(()=>o.options,()=>{a.value&&(a.value.options=b(),a.value.update())},{deep:!0}),f({chart:a}),(B,V)=>(t.openBlock(),t.createElementBlock("div",{class:"nc-chart-wrapper w-full",style:t.normalizeStyle({height:typeof e.height=="number"?`${e.height}px`:e.height,width:e.width?typeof e.width=="number"?`${e.width}px`:e.width:"100%"})},[t.createElementVNode("canvas",{ref_key:"canvasRef",ref:i},null,512)],4))}},[["__scopeId","data-v-9828990e"]]);function kt(e){const f=e.replace("#",""),o=f.length===3?f.split("").map(j=>j+j).join(""):f,i=parseInt(o.slice(0,2),16)/255,a=parseInt(o.slice(2,4),16)/255,S=parseInt(o.slice(4,6),16)/255,b=Math.max(i,a,S),k=Math.min(i,a,S),F=(b+k)/2;if(b===k)return[0,0,F*100];const B=b-k,V=F>.5?B/(2-b-k):B/(b+k);let N;return b===i?N=((a-S)/B+(a<S?6:0))/6:b===a?N=((S-i)/B+2)/6:N=((i-a)/B+4)/6,[N*360,V*100,F*100]}function Bt(e,f,o){e/=360,f/=100,o/=100;const i=o<.5?o*(1+f):o+f-o*f,a=2*o-i,S=B=>(B<0&&(B+=1),B>1&&(B-=1),B<1/6?a+(i-a)*6*B:B<1/2?i:B<2/3?a+(i-a)*(2/3-B)*6:a),b=f===0?o:S(e+1/3),k=f===0?o:S(e),F=f===0?o:S(e-1/3);return"#"+[b,k,F].map(B=>Math.round(B*255).toString(16).padStart(2,"0")).join("")}function nt(e,f=7){if(!(e!=null&&e.startsWith("#")))return Array.from({length:f},()=>e??"#3B82F6");const[o,i]=kt(e),a=20,S=72;return Array.from({length:f},(b,k)=>{const F=f===1?.5:k/(f-1),B=a+F*(S-a),V=Math.max(50,i-Math.max(0,B-55)*.6);return Bt(o,V,B)})}const Et={light:{bg:"#ffffff",text:"#000000",muted:"#64748B",grid:"rgba(15,23,42,0.06)"},dark:{bg:"#000000",text:"#ffffff",muted:"#7b7b7b",grid:"rgba(255,255,255,0.08)"},transparent:{bg:"transparent",text:"inherit",muted:"#7b7b7b",grid:"rgba(127,127,127,0.15)"}};function R(e,f){if(!e)return`rgba(59,130,246,${f})`;if(e.startsWith("#")){const o=e.replace("#",""),i=o.length===3?o.split("").map(k=>k+k).join(""):o,a=parseInt(i.slice(0,2),16),S=parseInt(i.slice(2,4),16),b=parseInt(i.slice(4,6),16);return`rgba(${a},${S},${b},${f})`}if(e.startsWith("rgb")){const o=e.match(/[\d.]+/g);if(o&&o.length>=3)return`rgba(${o[0]},${o[1]},${o[2]},${f})`}return e}function Z(e){const f=t.computed(()=>{const i=Et[e.tema],a=i?{...i,bg:e.corFundo||i.bg}:{bg:e.corFundo||e.tema,text:"#F8FAFC",muted:"#7b7b7b",grid:"rgba(255,255,255,0.08)"};return{...a,text:e.corTexto||a.text,muted:e.corTexto||a.muted}}),o=t.computed(()=>({background:f.value.bg,color:f.value.text,borderRadius:typeof e.borderRadius=="number"?`${e.borderRadius}px`:e.borderRadius,boxShadow:e.sombra,border:e.corBorda?`1px solid ${e.corBorda}`:"none"}));return{palette:f,cardStyle:o,toRgba:R}}function ot(e){const f=t.computed(()=>e.tipoValor==="moeda"?new Intl.NumberFormat(e.locale,{style:"currency",currency:e.moeda}):e.tipoValor==="percentual"?new Intl.NumberFormat(e.locale,{style:"percent",maximumFractionDigits:2}):new Intl.NumberFormat(e.locale,{maximumFractionDigits:2}));function o(i){if(i==null)return"";const a=Number(i);return Number.isNaN(a)?String(i):e.tipoValor==="percentual"?f.value.format(a/100):f.value.format(a)}return{formatador:f,formatar:o}}function at(e,{caretFlexivel:f=!1}={}){let o=e.querySelector(".nc-tt");if(o)return o;o=document.createElement("div"),o.className="nc-tt",Object.assign(o.style,{position:"absolute",pointerEvents:"none",transform:f?"translateX(-50%)":"translate(-50%, calc(-100% - 16px))",transition:"opacity .18s ease, left .12s ease, top .12s ease",opacity:"0",background:"#ffffff",borderRadius:"10px",padding:"8px 11px",boxShadow:"0 1px 2px rgba(15,23,42,.06), 0 8px 24px rgba(15,23,42,.12)",border:"1px solid rgba(15,23,42,.06)",minWidth:"90px",whiteSpace:"nowrap",zIndex:"10",fontFamily:"inherit",textAlign:"left"});const i=document.createElement("div");i.className="nc-tt__caret";const a={position:"absolute",left:"50%",width:"10px",height:"10px",background:"#ffffff",transform:"translateX(-50%) rotate(45deg)",borderRadius:"2px"};f?Object.assign(i.style,a):Object.assign(i.style,a,{bottom:"-5px",borderRight:"1px solid rgba(15,23,42,.06)",borderBottom:"1px solid rgba(15,23,42,.06)"}),o.appendChild(i);const S=document.createElement("div");return S.className="nc-tt__content",Object.assign(S.style,{position:"relative",background:"#fff",borderRadius:"8px"}),o.appendChild(S),e.appendChild(o),o}function K(e){const f=e.canvas.parentNode;return f?(getComputedStyle(f).position==="static"&&(f.style.position="relative"),f):null}function _(e,f,o,i=4){const a=f/2;return e-a<i?a+i:e+a>o-i?o-a-i:e}function lt(e,f){const o=window.getComputedStyle(e);let i="";for(let a=0;a<o.length;a++){const S=o[a];let b=o.getPropertyValue(S);if(b&&b.indexOf("url(")!==-1&&!/url\(["']?data:/.test(b))if(S==="background-image"||S==="background"||S==="mask-image"||S==="border-image"||S==="border-image-source")b="none";else continue;i+=`${S}:${b};`}f.setAttribute("style",i)}function Ct(e,f){lt(e,f);const o=e.querySelectorAll("*"),i=f.querySelectorAll("*");for(let a=0;a<o.length;a++)i[a]&<(o[a],i[a])}function $t(e,f){const o=e.querySelectorAll("canvas"),i=f.querySelectorAll("canvas");o.forEach((a,S)=>{if(!i[S])return;const b=document.createElement("img");try{b.src=a.toDataURL("image/png")}catch{return}const k=a.getBoundingClientRect();b.setAttribute("style",`width:${k.width}px;height:${k.height}px;display:block;`),i[S].replaceWith(b)})}async function v(e,f={}){if(!e)return;const{nomeArquivo:o="componente.png",escala:i=2,corFundo:a=null}=f,S=e.getBoundingClientRect(),b=Math.ceil(S.width),k=Math.ceil(S.height),F=e.cloneNode(!0);Ct(e,F),$t(e,F),F.style.margin="0",F.style.transform="none";const B=new XMLSerializer().serializeToString(F),V=`<svg xmlns="http://www.w3.org/2000/svg" width="${b}" height="${k}"><foreignObject width="100%" height="100%"><div xmlns="http://www.w3.org/1999/xhtml" style="width:${b}px;height:${k}px;">`+B+"</div></foreignObject></svg>",j="data:image/svg+xml;base64,"+(typeof window<"u"&&window.btoa?window.btoa(unescape(encodeURIComponent(V))):""),M=new Image;await new Promise((T,O)=>{M.onload=T,M.onerror=O,M.src=j});const J=document.createElement("canvas");J.width=b*i,J.height=k*i;const Y=J.getContext("2d");Y.scale(i,i),a&&(Y.fillStyle=a,Y.fillRect(0,0,b,k)),Y.drawImage(M,0,0);let m;try{m=J.toDataURL("image/png")}catch(T){console.error("Falha ao exportar imagem: canvas contaminado.",T);return}const $=document.createElement("a");$.download=o,$.href=m,document.body.appendChild($),$.click(),document.body.removeChild($)}const tt='<svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"/><polyline points="7 10 12 15 17 10"/><line x1="12" y1="15" x2="12" y2="3"/></svg>',Vt={class:"card-linhas__header flex flex-column"},Nt={class:"card-linhas__topo flex align-items-start justify-content-between gap-3"},Tt={key:0,class:"nc-legendas-flex flex flex-column"},zt={key:1,class:"nc-actions inline-flex align-items-center gap-2"},At=["innerHTML"],Rt={key:0,class:"card-linhas__titulos mt-3 mb-2 flex flex-column"},wt={class:"card-linhas__chart flex-1"},qt={key:0,class:"card-linhas__footer mt-3"},st=Q({__name:"CardLinhas",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corDetalhes:{type:String,default:"#3B82F6"},corTexto:{type:String,default:null},textoBotao:{type:String,default:"Ver mais"},direcao:{type:String,default:"top",validator:e=>["top","bottom","left","right"].includes(e)},botaoVisivel:{type:Boolean,default:!1},tipoValor:{type:String,default:"numero",validator:e=>["numero","moeda","percentual"].includes(e)},locale:{type:String,default:"pt-BR"},moeda:{type:String,default:"BRL"},data:{type:Array,default:()=>[{rotulo:"Jan",quantidade:22},{rotulo:"Fev",quantidade:35},{rotulo:"Mar",quantidade:28},{rotulo:"Abr",quantidade:45},{rotulo:"Mai",quantidade:30},{rotulo:"Jun",quantidade:55},{rotulo:"Jul",quantidade:42},{rotulo:"Ago",quantidade:60},{rotulo:"Set",quantidade:48},{rotulo:"Out",quantidade:70},{rotulo:"Nov",quantidade:58},{rotulo:"Dez",quantidade:75}]},height:{type:[String,Number],default:280},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06)"},corBorda:{type:String,default:"#EAE8E8"},linhasReferencia:{type:[Object,Array],default:null},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-linhas.png"}},emits:["botaoAcao","exportado"],setup(e,{emit:f}){const o=e,i=f,{palette:a,cardStyle:S}=Z(o),{formatar:b}=ot(o),k=t.ref(null),F=tt;async function B(){await v(k.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),i("exportado")}const V=t.computed(()=>`card-linhas--${o.direcao}`),N=t.computed(()=>o.linhasReferencia?(Array.isArray(o.linhasReferencia)?o.linhasReferencia:[o.linhasReferencia]).filter(s=>s&&(typeof s=="number"||typeof s.valor=="number")).map(s=>typeof s=="number"?{valor:s,rotulo:null,cor:"#0F172A",corRotulo:"#0F172A",corTexto:"#FFFFFF",tracejado:[6,6],espessura:1}:{valor:s.valor,rotulo:s.rotulo??null,cor:s.cor||"#0F172A",corRotulo:s.corRotulo||s.cor||"#0F172A",corTexto:s.corTexto||"#FFFFFF",tracejado:s.tracejado||[6,6],espessura:s.espessura??1}):[]),j=[];let M=null;const Y=[{id:"linhaReferencia",afterDatasetsDraw(c){const s=N.value;if(j.length=0,!s.length)return;const{ctx:r,chartArea:u,scales:y}=c,l=y.y;l&&s.forEach(d=>{const n=l.getPixelForValue(d.valor);if(j.push({linha:d,pos:n,chartArea:u}),r.save(),r.beginPath(),r.setLineDash(d.tracejado),r.lineWidth=d.espessura,r.strokeStyle=d.cor,n<u.top||n>u.bottom){r.restore();return}if(r.moveTo(u.left,n),r.lineTo(u.right,n),r.stroke(),r.setLineDash([]),d.rotulo){r.font="600 11px 'Inter', sans-serif";const p=8,g=5,E=r.measureText(d.rotulo).width,C=12,x=E+p*2,A=C+g*2,h=A/2;let q=u.left-x-6,D=n-A/2;q<0&&(q=u.left+6),r.fillStyle=d.corRotulo,r.beginPath(),r.roundRect?r.roundRect(q,D,x,A,h):(r.moveTo(q+h,D),r.lineTo(q+x-h,D),r.quadraticCurveTo(q+x,D,q+x,D+h),r.lineTo(q+x,D+A-h),r.quadraticCurveTo(q+x,D+A,q+x-h,D+A),r.lineTo(q+h,D+A),r.quadraticCurveTo(q,D+A,q,D+A-h),r.lineTo(q,D+h),r.quadraticCurveTo(q,D,q+h,D)),r.fill(),r.fillStyle=d.corTexto,r.textBaseline="middle",r.textAlign="center",r.fillText(d.rotulo,q+x/2,D+A/2)}r.restore()})},beforeEvent(c,s){if(!j.length){M=null;return}const r=s.event;if(!r||r.type==="mouseout"||r.x==null||r.y==null){M=null;return}const u=8;let y=null,l=1/0;for(const d of j){const n=Math.abs(r.y-d.pos),p=r.x>=d.chartArea.left&&r.x<=d.chartArea.right;n<=u&&p&&n<l&&(l=n,y=d)}M=y},afterEvent(c,s){if(!j.length)return;const r=s.event;if(!r)return;const u=K(c);if(!u)return;let y=u.querySelector(".nc-tt-linhaRef");if(!M){y&&(y.style.opacity="0");return}const l=M;y||(y=document.createElement("div"),y.className="nc-tt-linhaRef",Object.assign(y.style,{position:"absolute",pointerEvents:"none",transform:"translate(-50%, calc(-100% - 12px))",transition:"opacity .18s ease, left .12s ease, top .12s ease",opacity:"0",background:"#ffffff",borderRadius:"10px",padding:"8px 11px",boxShadow:"0 1px 2px rgba(15,23,42,.06), 0 8px 24px rgba(15,23,42,.12)",border:"1px solid rgba(15,23,42,.06)",whiteSpace:"nowrap",zIndex:"11",fontFamily:"'Inter', sans-serif",textAlign:"left"}),u.appendChild(y));const d=l.linha.cor||"#0F172A",n=b(l.linha.valor),p=l.linha.rotulo;y.innerHTML=(p?`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${p}</div>`:"")+`<div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${d};box-shadow:0 0 0 2px ${R(d,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${n}</span></div>`;const g=c.canvas;y.style.opacity="1",y.style.visibility="hidden",y.style.left="0px",y.style.top="0px";const z=y.offsetWidth,E=y.offsetHeight,C=4,x=g.offsetLeft+r.x,A=g.offsetTop+l.pos,h=_(x,z,u.clientWidth,C);let q=A;const D=E+16+C;q<D&&(q=D),y.style.left=h+"px",y.style.top=q+"px",y.style.visibility="visible"}}],m=t.computed(()=>({labels:o.data.map(c=>c.rotulo),datasets:[{data:o.data.map(c=>c.quantidade),borderColor:o.corDetalhes,borderWidth:3,borderJoinStyle:"round",borderCapStyle:"round",backgroundColor:c=>{const{chart:s}=c,{ctx:r,chartArea:u}=s;if(!u)return"transparent";const y=o.corDetalhes||"#0400FF",l="#7C7C7C",d=r.createLinearGradient(0,u.top,0,u.bottom);return d.addColorStop(.16,R(y,.2)),d.addColorStop(1,R(l,0)),d},fill:!0,tension:.45,pointRadius:0,pointHoverRadius:6,pointHoverBorderWidth:3,pointHoverBackgroundColor:o.corDetalhes,pointHoverBorderColor:a.value.bg==="transparent"?"#fff":a.value.bg,clip:!1}]}));function $(c){const{chart:s,tooltip:r}=c,u=K(s);if(!u)return;const y=at(u);if(r.opacity===0||M){y.style.opacity="0";return}const l=r.title||[],d=(r.body||[]).flatMap(W=>W.lines),n=y.querySelector(".nc-tt__content"),p=o.corDetalhes||"#3B82F6";n.innerHTML=`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${l.join(" ")}</div><div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${p};box-shadow:0 0 0 2px ${R(p,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${d.join(" ")}</span></div>`;const{offsetLeft:g,offsetTop:z}=s.canvas;y.style.opacity="1",y.style.visibility="hidden",y.style.left="0px",y.style.top="0px";const E=y.offsetWidth,C=y.offsetHeight,x=4,A=g+r.caretX,h=z+r.caretY,q=_(A,E,u.clientWidth,x),D=C+16+x,G=h<D;let I;G?(y.style.transform="translateX(-50%) translateY(16px)",I=h):(y.style.transform="translate(-50%, calc(-100% - 16px))",I=h),y.style.left=q+"px",y.style.top=I+"px";const w=y.querySelector(".nc-tt__caret");if(w){const W=A-q,L=E/2,P=Math.max(-L+8,Math.min(L-8,W));w.style.left=`calc(50% + ${P}px)`,G?(w.style.bottom="",w.style.top="-5px",w.style.borderRight="",w.style.borderBottom="",w.style.borderLeft="1px solid rgba(15,23,42,.06)",w.style.borderTop="1px solid rgba(15,23,42,.06)"):(w.style.top="",w.style.bottom="-5px",w.style.borderLeft="",w.style.borderTop="",w.style.borderRight="1px solid rgba(15,23,42,.06)",w.style.borderBottom="1px solid rgba(15,23,42,.06)")}y.style.visibility="visible"}const T=t.computed(()=>({responsive:!0,maintainAspectRatio:!1,interaction:{intersect:!1,mode:"index"},layout:{padding:{top:N.value.length?24:0,right:0,bottom:0,left:0}},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:$,callbacks:{title:c=>{var s;return((s=c[0])==null?void 0:s.label)??""},label:c=>b(c.parsed.y)}}},scales:{x:{display:!0,afterFit:c=>{c.paddingLeft=0,c.paddingRight=0},grid:{display:!1,drawBorder:!1},border:{display:!1},ticks:{color:a.value.muted,font:{size:10,family:"'Inter', sans-serif"},padding:8,align:"inner"}},y:{display:!1,grid:{display:!1},beginAtZero:!0,suggestedMax:N.value.length?Math.max(...N.value.map(c=>c.valor)):void 0}}}));function O(){i("botaoAcao")}return(c,s)=>(t.openBlock(),t.createElementBlock("div",{ref_key:"cardRef",ref:k,class:t.normalizeClass(["card-linhas p-4 flex",V.value]),style:t.normalizeStyle(t.unref(S))},[t.createElementVNode("div",Vt,[t.createElementVNode("div",Nt,[c.$slots.legenda||e.legenda||c.$slots.sublegenda||e.sublegenda?(t.openBlock(),t.createElementBlock("div",Tt,[c.$slots.legenda||e.legenda?(t.openBlock(),t.createElementBlock("div",{key:0,class:"text-xs font-medium",style:t.normalizeStyle({color:t.unref(a).text,opacity:.85})},[t.renderSlot(c.$slots,"legenda",{},()=>[t.createTextVNode(t.toDisplayString(e.legenda),1)],!0)],4)):t.createCommentVNode("",!0),c.$slots.sublegenda||e.sublegenda?(t.openBlock(),t.createElementBlock("div",{key:1,class:"text-xs",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(c.$slots,"sublegenda",{},()=>[t.createTextVNode(t.toDisplayString(e.sublegenda),1)],!0)],4)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),c.$slots.actions||e.botaoVisivel||e.exportar?(t.openBlock(),t.createElementBlock("div",zt,[t.renderSlot(c.$slots,"actions",{},()=>[e.botaoVisivel?(t.openBlock(),t.createElementBlock("button",{key:0,class:"nc-btn inline-flex align-items-center",style:t.normalizeStyle({color:t.unref(a).text,borderColor:t.unref(R)(t.unref(a).text,.18)}),onClick:O},[t.createElementVNode("span",null,t.toDisplayString(e.textoBotao),1)],4)):t.createCommentVNode("",!0)],!0),e.exportar?(t.openBlock(),t.createElementBlock("button",{key:0,type:"button",class:"nc-exportar inline-flex align-items-center justify-content-center",style:t.normalizeStyle({color:t.unref(a).muted,borderColor:t.unref(R)(t.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:t.unref(F)},null,12,At)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)]),c.$slots.titulo||e.titulo||c.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",Rt,[c.$slots.titulo||e.titulo?(t.openBlock(),t.createElementBlock("div",{key:0,class:"m-0 text-3xl font-semibold",style:t.normalizeStyle({color:t.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[t.renderSlot(c.$slots,"titulo",{},()=>[t.createTextVNode(t.toDisplayString(e.titulo),1)],!0)],4)):t.createCommentVNode("",!0),c.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",{key:1,class:"text-sm mt-1",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(c.$slots,"descricao",{},()=>[t.createTextVNode(t.toDisplayString(e.descricao),1)],!0)],4)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)]),t.createElementVNode("div",wt,[t.createVNode(U,{type:"line",data:m.value,options:T.value,plugins:Y,height:e.height},null,8,["data","options","height"])]),c.$slots.footer?(t.openBlock(),t.createElementBlock("div",qt,[t.renderSlot(c.$slots,"footer",{},void 0,!0)])):t.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-513bd6fe"]]),Ft={class:"card-pizza__topo flex align-items-start justify-content-between gap-3"},Lt={key:0,class:"nc-legendas-flex flex flex-column"},Dt={key:1,class:"nc-actions inline-flex align-items-center gap-2"},Mt=["innerHTML"],Ht={class:"card-pizza__corpo flex align-items-center"},Pt={class:"nc-tabela flex flex-column"},jt={class:"nc-tabela-valor"},It={class:"nc-tabela-rotulo inline-flex align-items-center gap-2"},Ot={class:"nc-tabela-valor"},Wt={class:"card-pizza__chart-wrap flex align-items-center justify-content-center"},Xt={class:"card-pizza__chart"},Yt={key:0,class:"nc-centro flex flex-column align-items-center justify-content-center"},Jt={key:0,class:"card-pizza__footer mt-3"},it=Q({__name:"CardPizza",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corTexto:{type:String,default:null},corBorda:{type:String,default:"#EAE8E8"},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06)"},corDetalhes:{type:String,default:"#3B82F6"},textoBotao:{type:String,default:"Ver mais"},botaoVisivel:{type:Boolean,default:!1},direcao:{type:String,default:"right",validator:e=>["left","right","top","bottom"].includes(e)},rotuloCategoria:{type:String,default:"Categoria"},rotuloQuantidade:{type:String,default:"Quantidade"},mostrarCabecalho:{type:Boolean,default:!0},tipoValor:{type:String,default:"numero",validator:e=>["numero","moeda","percentual"].includes(e)},locale:{type:String,default:"pt-BR"},moeda:{type:String,default:"BRL"},data:{type:Array,default:()=>[{rotulo:"Vendas",quantidade:4200},{rotulo:"Serviços",quantidade:3100},{rotulo:"Assinaturas",quantidade:2450},{rotulo:"Licenças",quantidade:1800},{rotulo:"Suporte",quantidade:1250},{rotulo:"Treinamentos",quantidade:820},{rotulo:"Outros",quantidade:410}]},height:{type:[String,Number],default:260},cutout:{type:[String,Number],default:"70%"},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-pizza.png"}},emits:["botaoAcao","exportado"],setup(e,{emit:f}){const o=e,i=f,{palette:a,cardStyle:S}=Z(o),{formatar:b}=ot(o),k=t.ref(null);async function F(){await v(k.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),i("exportado")}const B=t.computed(()=>`card-pizza--${o.direcao}`),V=t.computed(()=>{const m=nt(o.corDetalhes,o.data.length);return o.data.map(($,T)=>$.cor??m[T])}),N=t.computed(()=>({labels:o.data.map(m=>m.rotulo),datasets:[{data:o.data.map(m=>m.quantidade),backgroundColor:V.value,borderWidth:0,borderColor:"transparent",hoverOffset:6,borderRadius:0,spacing:0}]}));function j(m){const{chart:$,tooltip:T}=m,O=K($);if(!O)return;const c=at(O);if(T.opacity===0){c.style.opacity="0";return}const s=T.title||[],r=T.dataPoints&&T.dataPoints[0],u=r?V.value[r.dataIndex]:"#3B82F6",y=r?b(r.parsed):"",l=c.querySelector(".nc-tt__content");l.innerHTML=`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${s.join(" ")}</div><div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${u};box-shadow:0 0 0 2px ${R(u,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${y}</span></div>`;const{offsetLeft:d,offsetTop:n}=$.canvas;c.style.opacity="1",c.style.visibility="hidden",c.style.left="0px",c.style.top="0px";const p=c.offsetWidth,g=c.offsetHeight,z=4,E=d+T.caretX,C=n+T.caretY,x=_(E,p,O.clientWidth,z),A=C<g+16+z;c.style.transform=A?"translate(-50%, 16px)":"translate(-50%, calc(-100% - 16px))";const h=c.querySelector(".nc-tt__caret");h&&(A?(h.style.bottom="",h.style.top="-5px",h.style.borderRight="",h.style.borderBottom="",h.style.borderLeft="1px solid rgba(15,23,42,.06)",h.style.borderTop="1px solid rgba(15,23,42,.06)"):(h.style.top="",h.style.bottom="-5px",h.style.borderLeft="",h.style.borderTop="",h.style.borderRight="1px solid rgba(15,23,42,.06)",h.style.borderBottom="1px solid rgba(15,23,42,.06)")),c.style.left=x+"px",c.style.top=C+"px",c.style.visibility="visible"}const M=t.computed(()=>({responsive:!0,maintainAspectRatio:!1,cutout:o.cutout,layout:{padding:4},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:j,callbacks:{title:m=>{var $;return(($=m[0])==null?void 0:$.label)??""},label:m=>b(m.parsed)}}}}));function J(){i("botaoAcao")}const Y=tt;return(m,$)=>(t.openBlock(),t.createElementBlock("div",{ref_key:"cardRef",ref:k,class:t.normalizeClass(["card-pizza p-4 flex flex-column",B.value]),style:t.normalizeStyle(t.unref(S))},[t.createElementVNode("div",Ft,[m.$slots.legenda||e.legenda||m.$slots.sublegenda||e.sublegenda?(t.openBlock(),t.createElementBlock("div",Lt,[m.$slots.legenda||e.legenda?(t.openBlock(),t.createElementBlock("div",{key:0,class:"text-xs font-medium",style:t.normalizeStyle({color:t.unref(a).text,opacity:.95})},[t.renderSlot(m.$slots,"legenda",{},()=>[t.createTextVNode(t.toDisplayString(e.legenda),1)],!0)],4)):t.createCommentVNode("",!0),m.$slots.sublegenda||e.sublegenda?(t.openBlock(),t.createElementBlock("div",{key:1,class:"text-xs",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(m.$slots,"sublegenda",{},()=>[t.createTextVNode(t.toDisplayString(e.sublegenda),1)],!0)],4)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),m.$slots.actions||e.botaoVisivel||e.exportar?(t.openBlock(),t.createElementBlock("div",Dt,[t.renderSlot(m.$slots,"actions",{},()=>[e.botaoVisivel?(t.openBlock(),t.createElementBlock("button",{key:0,class:"nc-btn inline-flex align-items-center",style:t.normalizeStyle({color:t.unref(a).text,borderColor:t.unref(R)(t.unref(a).text,.18)}),onClick:J},[t.createElementVNode("span",null,t.toDisplayString(e.textoBotao),1)],4)):t.createCommentVNode("",!0)],!0),e.exportar?(t.openBlock(),t.createElementBlock("button",{key:0,type:"button",class:"nc-exportar inline-flex align-items-center justify-content-center",style:t.normalizeStyle({color:t.unref(a).muted,borderColor:t.unref(R)(t.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:F,innerHTML:t.unref(Y)},null,12,Mt)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)]),t.createElementVNode("div",Ht,[t.createElementVNode("div",Pt,[e.mostrarCabecalho?(t.openBlock(),t.createElementBlock("div",{key:0,class:"nc-tabela-cab flex align-items-center justify-content-between",style:t.normalizeStyle({color:t.unref(a).muted,borderColor:t.unref(R)(t.unref(a).muted,.25)})},[t.createElementVNode("span",null,t.toDisplayString(e.rotuloCategoria),1),t.createElementVNode("span",jt,t.toDisplayString(e.rotuloQuantidade),1)],4)):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.data,(T,O)=>(t.openBlock(),t.createElementBlock("div",{key:O,class:"nc-tabela-linha flex align-items-center justify-content-between",style:t.normalizeStyle({color:t.unref(a).text})},[t.createElementVNode("span",It,[t.createElementVNode("span",{class:"nc-bolinha",style:t.normalizeStyle({background:V.value[O]})},null,4),t.createElementVNode("span",null,t.toDisplayString(T.rotulo),1)]),t.createElementVNode("span",Ot,t.toDisplayString(t.unref(b)(T.quantidade)),1)],4))),128))]),t.createElementVNode("div",Wt,[t.createElementVNode("div",Xt,[t.createVNode(U,{type:"doughnut",data:N.value,options:M.value,height:e.height},null,8,["data","options","height"]),m.$slots.titulo||e.titulo||m.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",Yt,[m.$slots.titulo||e.titulo?(t.openBlock(),t.createElementBlock("div",{key:0,class:"nc-centro-titulo m-0 font-semibold",style:t.normalizeStyle({color:t.unref(a).text})},[t.renderSlot(m.$slots,"titulo",{},()=>[t.createTextVNode(t.toDisplayString(e.titulo),1)],!0)],4)):t.createCommentVNode("",!0),m.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",{key:1,class:"nc-centro-desc",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(m.$slots,"descricao",{},()=>[t.createTextVNode(t.toDisplayString(e.descricao),1)],!0)],4)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)])])]),m.$slots.footer?(t.openBlock(),t.createElementBlock("div",Jt,[t.renderSlot(m.$slots,"footer",{},void 0,!0)])):t.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-e0fe217f"]]),Gt={class:"card-barra__header flex flex-column"},Qt={class:"card-barra__topo flex align-items-start justify-content-between gap-3"},Ut={key:0,class:"nc-legendas-flex flex flex-column"},Zt={key:1,class:"nc-actions inline-flex align-items-center gap-2"},Kt=["innerHTML"],_t={key:0,class:"card-barra__titulos mt-3 mb-2 flex flex-column"},vt={class:"card-barra__chart flex-1"},te={key:0,class:"card-barra__footer mt-3"},ct=Q({__name:"CardBarra",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corDetalhes:{type:String,default:"#3B82F6"},corTexto:{type:String,default:null},textoBotao:{type:String,default:"Ver mais"},direcao:{type:String,default:"top",validator:e=>["top","bottom","left","right"].includes(e)},botaoVisivel:{type:Boolean,default:!1},tipoValor:{type:String,default:"numero",validator:e=>["numero","moeda","percentual"].includes(e)},locale:{type:String,default:"pt-BR"},moeda:{type:String,default:"BRL"},data:{type:Array,default:()=>[{rotulo:"Jan",quantidade:22},{rotulo:"Fev",quantidade:35},{rotulo:"Mar",quantidade:28},{rotulo:"Abr",quantidade:45},{rotulo:"Mai",quantidade:30},{rotulo:"Jun",quantidade:55},{rotulo:"Jul",quantidade:42},{rotulo:"Ago",quantidade:60},{rotulo:"Set",quantidade:48},{rotulo:"Out",quantidade:70},{rotulo:"Nov",quantidade:58},{rotulo:"Dez",quantidade:75}]},series:{type:Array,default:null},cores:{type:Array,default:()=>["#3B82F6","#10B981","#F59E0B","#EF4444","#8B5CF6","#06B6D4","#EC4899"]},orientacao:{type:String,default:"vertical",validator:e=>["vertical","horizontal"].includes(e)},empilhado:{type:Boolean,default:!1},mostrarLegendaSeries:{type:Boolean,default:!0},height:{type:[String,Number],default:280},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06)"},corBorda:{type:String,default:"#EAE8E8"},larguraBarra:{type:[String,Number],default:.92},raioBarra:{type:Number,default:6},linhasReferencia:{type:[Object,Array],default:null},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-barra.png"},corHover:{type:String,default:null}},emits:["botaoAcao","exportado"],setup(e,{emit:f}){t.useCssVars(l=>({c9bf3d56:N.value}));const o=e,i=f,{palette:a,cardStyle:S}=Z(o),{formatar:b}=ot(o),k=t.ref(null),F=tt;async function B(){await v(k.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),i("exportado")}const V=t.computed(()=>`card-barra--${o.direcao}`),N=t.computed(()=>typeof o.height=="number"?`${o.height}px`:o.height),j=t.computed(()=>o.orientacao==="horizontal"),M=t.computed(()=>Array.isArray(o.series)&&o.series.length>0?o.series.map((l,d)=>({nome:l.nome??`Série ${d+1}`,cor:l.cor||o.cores[d%o.cores.length],dados:Array.isArray(l.dados)?l.dados:[]})):[{nome:o.legenda||"Valores",cor:o.corDetalhes,dados:o.data}]),J=t.computed(()=>{const l=M.value[0];return l?l.dados.map(d=>d.rotulo):[]}),Y=t.computed(()=>{const l=M.value,d=l.length-1,n=typeof o.larguraBarra=="number"?o.larguraBarra:Number(o.larguraBarra)||.6,p=o.raioBarra,g=j.value;function z(E){if(!o.empilhado||l.length===1)return p;const C=E===0,x=E===d;return g?{topLeft:C?p:0,bottomLeft:C?p:0,topRight:x?p:0,bottomRight:x?p:0}:{bottomLeft:C?p:0,bottomRight:C?p:0,topLeft:x?p:0,topRight:x?p:0}}return{labels:J.value,datasets:l.map((E,C)=>({label:E.nome,data:E.dados.map(x=>x.quantidade),previstos:E.dados.map(x=>x.previsto!=null?x.previsto:null),backgroundColor:R(E.cor,.72),hoverBackgroundColor:o.corHover||E.cor,borderWidth:0,borderRadius:z(C),borderSkipped:!1,categoryPercentage:1,barPercentage:n}))}});function m(l,d){d?Object.assign(l.style,{top:"-5px",bottom:"auto",borderTop:"1px solid rgba(15,23,42,.06)",borderLeft:"1px solid rgba(15,23,42,.06)",borderRight:"none",borderBottom:"none"}):Object.assign(l.style,{bottom:"-5px",top:"auto",borderRight:"1px solid rgba(15,23,42,.06)",borderBottom:"1px solid rgba(15,23,42,.06)",borderTop:"none",borderLeft:"none"})}let $=null;function T(l){var ht,xt;const{chart:d,tooltip:n}=l,p=K(d);if(!p)return;const g=at(p,{caretFlexivel:!0});if(n.opacity===0||$){g.style.opacity="0";return}const z=n.title||[],E=n.dataPoints||[],C=g.querySelector(".nc-tt__content"),x=E.map(et=>{var St;const rt=((St=M.value[et.datasetIndex])==null?void 0:St.cor)||o.corDetalhes,Pe=b(j.value?et.parsed.x:et.parsed.y),je=et.dataset.label&&M.value.length>1?`<span style="font-size:11px;color:#64748B;margin-right:6px;">${et.dataset.label}</span>`:"";return`<div style="display:flex;align-items:center;gap:6px;margin-top:2px;"><span style="width:6px;height:6px;border-radius:999px;background:${rt};box-shadow:0 0 0 2px ${R(rt,.15)};flex:0 0 auto;"></span>`+je+`<span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;margin-left:auto;">${Pe}</span></div>`}).join(""),A=(ht=E[0])==null?void 0:ht.dataIndex;let h=null;if(A!=null)for(const et of d.data.datasets){const rt=(xt=et.previstos)==null?void 0:xt[A];if(rt!=null){h=rt;break}}const q=h!=null?`<div style="display:flex;align-items:center;gap:6px;margin-top:6px;padding-top:4px;border-top:1px dashed rgba(15,23,42,.08);"><span style="font-size:11px;color:#64748B;margin-right:6px;">Previsto</span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;margin-left:auto;">${b(h)}</span></div>`:"";C.innerHTML=`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${z.join(" ")}</div>`+x+q;const{offsetLeft:D,offsetTop:G}=d.canvas;g.style.opacity="1",g.style.visibility="hidden",g.style.left="0px",g.style.top="0px";const I=g.offsetWidth,w=g.offsetHeight,W=4,L=D+n.caretX,P=G+n.caretY,pt=_(L,I,p.clientWidth,W),Le=I/2,ut=14,gt=P-ut-w,yt=gt<W,De=yt?P+ut:gt,bt=g.querySelector(".nc-tt__caret");m(bt,yt);const Me=L-(pt-Le),He=Math.max(10,Math.min(I-10,Me));bt.style.left=He+"px",g.style.left=pt+"px",g.style.top=De+"px",g.style.visibility="visible"}const O=t.computed(()=>{const l=j.value,d={grid:{display:!1,drawBorder:!1},border:{display:!1},ticks:{color:a.value.muted,font:{size:10,family:"'Inter', sans-serif"},padding:8},stacked:o.empilhado},n={display:!1,grid:{display:!1},beginAtZero:!0,stacked:o.empilhado,suggestedMax:s.value.length?Math.max(...s.value.map(p=>p.valor)):void 0};return{responsive:!0,maintainAspectRatio:!1,indexAxis:l?"y":"x",interaction:{intersect:!1,mode:"index",axis:l?"y":"x"},layout:{padding:{top:s.value.length&&!l?24:12,right:l?12:0,bottom:0,left:s.value.length&&l?60:0}},plugins:{legend:{display:o.mostrarLegendaSeries&&M.value.length>1,position:"bottom",align:"start",labels:{color:a.value.muted,boxWidth:8,boxHeight:8,usePointStyle:!0,pointStyle:"circle",font:{size:10,family:"'Inter', sans-serif"},padding:12}},tooltip:{enabled:!1,external:T,callbacks:{title:p=>{var g;return((g=p[0])==null?void 0:g.label)??""},label:p=>b(l?p.parsed.x:p.parsed.y)}}},scales:{x:l?n:d,y:l?d:n}}});function c(){i("botaoAcao")}const s=t.computed(()=>o.linhasReferencia?(Array.isArray(o.linhasReferencia)?o.linhasReferencia:[o.linhasReferencia]).filter(d=>d&&(typeof d=="number"||typeof d.valor=="number")).map(d=>typeof d=="number"?{valor:d,rotulo:null,cor:"#0F172A",corRotulo:"#0F172A",corTexto:"#FFFFFF",tracejado:[6,6],espessura:1}:{valor:d.valor,rotulo:d.rotulo??null,cor:d.cor||"#0F172A",corRotulo:d.corRotulo||d.cor||"#0F172A",corTexto:d.corTexto||"#FFFFFF",tracejado:d.tracejado||[6,6],espessura:d.espessura??1}):[]),r=[],u={id:"linhaReferencia",afterDatasetsDraw(l){const d=s.value;if(r.length=0,!d.length)return;const{ctx:n,chartArea:p,scales:g}=l,z=j.value,E=z?g.x:g.y;E&&d.forEach(C=>{const x=E.getPixelForValue(C.valor);if(r.push({linha:C,pos:x,horizontal:z,chartArea:p}),n.save(),n.beginPath(),n.setLineDash(C.tracejado),n.lineWidth=C.espessura,n.strokeStyle=C.cor,z){if(x<p.left||x>p.right){n.restore();return}n.moveTo(x,p.top),n.lineTo(x,p.bottom)}else{if(x<p.top||x>p.bottom){n.restore();return}n.moveTo(p.left,x),n.lineTo(p.right,x)}if(n.stroke(),n.setLineDash([]),C.rotulo){n.font="600 11px 'Inter', sans-serif";const A=8,h=5,D=n.measureText(C.rotulo).width,G=12,I=D+A*2,w=G+h*2,W=w/2;let L,P;z?(L=x-I/2,P=p.top-w-6,P<0&&(P=p.top+6)):(L=p.left-I-6,P=x-w/2,L<0&&(L=p.left+6)),n.fillStyle=C.corRotulo,n.beginPath(),n.roundRect?n.roundRect(L,P,I,w,W):(n.moveTo(L+W,P),n.lineTo(L+I-W,P),n.quadraticCurveTo(L+I,P,L+I,P+W),n.lineTo(L+I,P+w-W),n.quadraticCurveTo(L+I,P+w,L+I-W,P+w),n.lineTo(L+W,P+w),n.quadraticCurveTo(L,P+w,L,P+w-W),n.lineTo(L,P+W),n.quadraticCurveTo(L,P,L+W,P)),n.fill(),n.fillStyle=C.corTexto,n.textBaseline="middle",n.textAlign="center",n.fillText(C.rotulo,L+I/2,P+w/2)}n.restore()})},beforeEvent(l,d){if(!r.length){$=null;return}const n=d.event;if(!n||n.type==="mouseout"||n.x==null||n.y==null){$=null;return}const p=8;let g=null,z=1/0;for(const E of r){const C=E.horizontal?Math.abs(n.x-E.pos):Math.abs(n.y-E.pos),x=E.horizontal?n.y>=E.chartArea.top&&n.y<=E.chartArea.bottom:n.x>=E.chartArea.left&&n.x<=E.chartArea.right;C<=p&&x&&C<z&&(z=C,g=E)}$=g},afterEvent(l,d){if(!r.length)return;const n=d.event;if(!n)return;const p=K(l);if(!p)return;let g=p.querySelector(".nc-tt-linhaRef");if(!$){g&&(g.style.opacity="0");return}const z=$;g||(g=document.createElement("div"),g.className="nc-tt-linhaRef",Object.assign(g.style,{position:"absolute",pointerEvents:"none",transform:"translate(-50%, calc(-100% - 12px))",transition:"opacity .18s ease, left .12s ease, top .12s ease",opacity:"0",background:"#ffffff",borderRadius:"10px",padding:"8px 11px",boxShadow:"0 1px 2px rgba(15,23,42,.06), 0 8px 24px rgba(15,23,42,.12)",border:"1px solid rgba(15,23,42,.06)",whiteSpace:"nowrap",zIndex:"11",fontFamily:"'Inter', sans-serif",textAlign:"left"}),p.appendChild(g));const E=z.linha.cor||"#0F172A",C=b(z.linha.valor),x=z.linha.rotulo;g.innerHTML=(x?`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${x}</div>`:"")+`<div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${E};box-shadow:0 0 0 2px ${R(E,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${C}</span></div>`;const A=l.canvas;g.style.opacity="1",g.style.visibility="hidden",g.style.left="0px",g.style.top="0px";const h=g.offsetWidth,q=g.offsetHeight,D=4;let G,I;z.horizontal?(G=A.offsetLeft+z.pos,I=A.offsetTop+n.y):(G=A.offsetLeft+n.x,I=A.offsetTop+z.pos);const w=_(G,h,p.clientWidth,D);let W=I;const L=q+16+D;W<L&&(W=L),g.style.left=w+"px",g.style.top=W+"px",g.style.visibility="visible"}},y=t.computed(()=>s.value.length?[u]:[]);return(l,d)=>(t.openBlock(),t.createElementBlock("div",{ref_key:"cardRef",ref:k,class:t.normalizeClass(["card-barra p-4 flex",V.value]),style:t.normalizeStyle(t.unref(S))},[t.createElementVNode("div",Gt,[t.createElementVNode("div",Qt,[l.$slots.legenda||e.legenda||l.$slots.sublegenda||e.sublegenda?(t.openBlock(),t.createElementBlock("div",Ut,[l.$slots.legenda||e.legenda?(t.openBlock(),t.createElementBlock("div",{key:0,class:"text-xs font-medium",style:t.normalizeStyle({color:t.unref(a).text,opacity:.85})},[t.renderSlot(l.$slots,"legenda",{},()=>[t.createTextVNode(t.toDisplayString(e.legenda),1)],!0)],4)):t.createCommentVNode("",!0),l.$slots.sublegenda||e.sublegenda?(t.openBlock(),t.createElementBlock("div",{key:1,class:"text-xs",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(l.$slots,"sublegenda",{},()=>[t.createTextVNode(t.toDisplayString(e.sublegenda),1)],!0)],4)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),l.$slots.actions||e.botaoVisivel||e.exportar?(t.openBlock(),t.createElementBlock("div",Zt,[t.renderSlot(l.$slots,"actions",{},()=>[e.botaoVisivel?(t.openBlock(),t.createElementBlock("button",{key:0,class:"nc-btn inline-flex align-items-center",style:t.normalizeStyle({color:t.unref(a).text,borderColor:t.unref(R)(t.unref(a).text,.18)}),onClick:c},[t.createElementVNode("span",null,t.toDisplayString(e.textoBotao),1)],4)):t.createCommentVNode("",!0)],!0),e.exportar?(t.openBlock(),t.createElementBlock("button",{key:0,type:"button",class:"nc-exportar inline-flex align-items-center justify-content-center",style:t.normalizeStyle({color:t.unref(a).muted,borderColor:t.unref(R)(t.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:t.unref(F)},null,12,Kt)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)]),l.$slots.titulo||e.titulo||l.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",_t,[l.$slots.titulo||e.titulo?(t.openBlock(),t.createElementBlock("div",{key:0,class:"m-0 text-3xl font-semibold",style:t.normalizeStyle({color:t.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[t.renderSlot(l.$slots,"titulo",{},()=>[t.createTextVNode(t.toDisplayString(e.titulo),1)],!0)],4)):t.createCommentVNode("",!0),l.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",{key:1,class:"text-sm mt-1",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(l.$slots,"descricao",{},()=>[t.createTextVNode(t.toDisplayString(e.descricao),1)],!0)],4)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)]),t.createElementVNode("div",vt,[t.createVNode(U,{type:"bar",data:Y.value,options:O.value,plugins:y.value,height:"100%"},null,8,["data","options","plugins"])]),l.$slots.footer?(t.openBlock(),t.createElementBlock("div",te,[t.renderSlot(l.$slots,"footer",{},void 0,!0)])):t.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-474043e8"]]),ee={class:"card-polar__topo flex align-items-start justify-content-between gap-3"},oe={key:0,class:"nc-legendas-flex flex flex-column"},ae={key:1,class:"nc-actions inline-flex align-items-center gap-2"},re=["innerHTML"],ne={class:"card-polar__corpo flex align-items-center"},le={class:"nc-tabela flex flex-column"},se={class:"nc-tabela-valor"},ie={class:"nc-tabela-rotulo inline-flex align-items-center gap-2"},ce={class:"nc-tabela-valor"},de={class:"card-polar__chart-wrap flex align-items-center justify-content-center"},me={class:"card-polar__chart"},fe={key:0,class:"card-polar__centro-bottom"},pe={key:0,class:"card-polar__footer mt-3"},dt=Q({__name:"CardPolar",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corTexto:{type:String,default:null},corBorda:{type:String,default:"#EAE8E8"},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06)"},corDetalhes:{type:String,default:"#3B82F6"},textoBotao:{type:String,default:"Ver mais"},botaoVisivel:{type:Boolean,default:!1},direcao:{type:String,default:"right",validator:e=>["left","right","top","bottom"].includes(e)},rotuloCategoria:{type:String,default:"Categoria"},rotuloQuantidade:{type:String,default:"Quantidade"},mostrarCabecalho:{type:Boolean,default:!0},tipoValor:{type:String,default:"numero",validator:e=>["numero","moeda","percentual"].includes(e)},locale:{type:String,default:"pt-BR"},moeda:{type:String,default:"BRL"},data:{type:Array,default:()=>[{rotulo:"Vendas",quantidade:4200},{rotulo:"Serviços",quantidade:3100},{rotulo:"Assinaturas",quantidade:2450},{rotulo:"Licenças",quantidade:1800},{rotulo:"Suporte",quantidade:1250},{rotulo:"Treinamentos",quantidade:820},{rotulo:"Outros",quantidade:410}]},height:{type:[String,Number],default:260},mostrarLinhasGrade:{type:Boolean,default:!0},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-polar.png"}},emits:["botaoAcao","exportado"],setup(e,{emit:f}){const o=e,i=f,{palette:a,cardStyle:S}=Z(o),{formatar:b}=ot(o),k=t.ref(null),F=tt;async function B(){await v(k.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),i("exportado")}const V=t.computed(()=>`card-polar--${o.direcao}`),N=t.computed(()=>{const m=nt(o.corDetalhes,o.data.length);return o.data.map(($,T)=>$.cor??m[T])}),j=t.computed(()=>({labels:o.data.map(m=>m.rotulo),datasets:[{data:o.data.map(m=>m.quantidade),backgroundColor:N.value,borderColor:N.value,borderWidth:0,hoverOffset:6}]}));function M(m){const{chart:$,tooltip:T}=m,O=K($);if(!O)return;const c=at(O);if(T.opacity===0){c.style.opacity="0";return}const s=T.title||[],r=T.dataPoints&&T.dataPoints[0],u=r?N.value[r.dataIndex]:"#3B82F6",y=r?b(r.parsed.r??r.parsed):"",l=c.querySelector(".nc-tt__content");l.innerHTML=`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${s.join(" ")}</div><div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${u};box-shadow:0 0 0 2px ${R(u,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${y}</span></div>`;const{offsetLeft:d,offsetTop:n}=$.canvas;c.style.opacity="1",c.style.visibility="hidden",c.style.left="0px",c.style.top="0px";const p=c.offsetWidth,g=c.offsetHeight,z=4,E=d+T.caretX,C=n+T.caretY,x=_(E,p,O.clientWidth,z),A=C<g+16+z;c.style.transform=A?"translate(-50%, 16px)":"translate(-50%, calc(-100% - 16px))";const h=c.querySelector(".nc-tt__caret");h&&(A?(h.style.bottom="",h.style.top="-5px",h.style.borderRight="",h.style.borderBottom="",h.style.borderLeft="1px solid rgba(15,23,42,.06)",h.style.borderTop="1px solid rgba(15,23,42,.06)"):(h.style.top="",h.style.bottom="-5px",h.style.borderLeft="",h.style.borderTop="",h.style.borderRight="1px solid rgba(15,23,42,.06)",h.style.borderBottom="1px solid rgba(15,23,42,.06)")),c.style.left=x+"px",c.style.top=C+"px",c.style.visibility="visible"}const J=t.computed(()=>({responsive:!0,maintainAspectRatio:!1,layout:{padding:4},scales:{r:{beginAtZero:!0,ticks:{display:!1,backdropColor:"transparent"},grid:{display:o.mostrarLinhasGrade,color:R(a.value.muted,.18)},angleLines:{display:o.mostrarLinhasGrade,color:R(a.value.muted,.18)},pointLabels:{display:!1}}},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:M,callbacks:{title:m=>{var $;return(($=m[0])==null?void 0:$.label)??""},label:m=>{var $;return b((($=m.parsed)==null?void 0:$.r)??m.parsed)}}}}}));function Y(){i("botaoAcao")}return(m,$)=>(t.openBlock(),t.createElementBlock("div",{ref_key:"cardRef",ref:k,class:t.normalizeClass(["card-polar p-4 flex flex-column",V.value]),style:t.normalizeStyle(t.unref(S))},[t.createElementVNode("div",ee,[m.$slots.legenda||e.legenda||m.$slots.sublegenda||e.sublegenda?(t.openBlock(),t.createElementBlock("div",oe,[m.$slots.legenda||e.legenda?(t.openBlock(),t.createElementBlock("div",{key:0,class:"text-xs font-medium",style:t.normalizeStyle({color:t.unref(a).text,opacity:.95})},[t.renderSlot(m.$slots,"legenda",{},()=>[t.createTextVNode(t.toDisplayString(e.legenda),1)],!0)],4)):t.createCommentVNode("",!0),m.$slots.sublegenda||e.sublegenda?(t.openBlock(),t.createElementBlock("div",{key:1,class:"text-xs",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(m.$slots,"sublegenda",{},()=>[t.createTextVNode(t.toDisplayString(e.sublegenda),1)],!0)],4)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),m.$slots.actions||e.botaoVisivel||e.exportar?(t.openBlock(),t.createElementBlock("div",ae,[t.renderSlot(m.$slots,"actions",{},()=>[e.botaoVisivel?(t.openBlock(),t.createElementBlock("button",{key:0,class:"nc-btn inline-flex align-items-center",style:t.normalizeStyle({color:t.unref(a).text,borderColor:t.unref(R)(t.unref(a).text,.18)}),onClick:Y},[t.createElementVNode("span",null,t.toDisplayString(e.textoBotao),1)],4)):t.createCommentVNode("",!0)],!0),e.exportar?(t.openBlock(),t.createElementBlock("button",{key:0,type:"button",class:"nc-exportar inline-flex align-items-center justify-content-center",style:t.normalizeStyle({color:t.unref(a).muted,borderColor:t.unref(R)(t.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:t.unref(F)},null,12,re)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)]),t.createElementVNode("div",ne,[t.createElementVNode("div",le,[e.mostrarCabecalho?(t.openBlock(),t.createElementBlock("div",{key:0,class:"nc-tabela-cab flex align-items-center justify-content-between",style:t.normalizeStyle({color:t.unref(a).muted,borderColor:t.unref(R)(t.unref(a).muted,.25)})},[t.createElementVNode("span",null,t.toDisplayString(e.rotuloCategoria),1),t.createElementVNode("span",se,t.toDisplayString(e.rotuloQuantidade),1)],4)):t.createCommentVNode("",!0),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(e.data,(T,O)=>(t.openBlock(),t.createElementBlock("div",{key:O,class:"nc-tabela-linha flex align-items-center justify-content-between",style:t.normalizeStyle({color:t.unref(a).text})},[t.createElementVNode("span",ie,[t.createElementVNode("span",{class:"nc-bolinha",style:t.normalizeStyle({background:N.value[O]})},null,4),t.createElementVNode("span",null,t.toDisplayString(T.rotulo),1)]),t.createElementVNode("span",ce,t.toDisplayString(t.unref(b)(T.quantidade)),1)],4))),128))]),t.createElementVNode("div",de,[t.createElementVNode("div",me,[t.createVNode(U,{type:"polarArea",data:j.value,options:J.value,height:e.height},null,8,["data","options","height"]),m.$slots.titulo||e.titulo||m.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",fe,[m.$slots.titulo||e.titulo?(t.openBlock(),t.createElementBlock("div",{key:0,class:"card-polar__centro-titulo m-0 text-3xl font-semibold",style:t.normalizeStyle({color:t.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[t.renderSlot(m.$slots,"titulo",{},()=>[t.createTextVNode(t.toDisplayString(e.titulo),1)],!0)],4)):t.createCommentVNode("",!0),m.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",{key:1,class:"card-polar__centro-desc",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(m.$slots,"descricao",{},()=>[t.createTextVNode(t.toDisplayString(e.descricao),1)],!0)],4)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)])])]),m.$slots.footer?(t.openBlock(),t.createElementBlock("div",pe,[t.renderSlot(m.$slots,"footer",{},void 0,!0)])):t.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-352f2f67"]]),ue={class:"card-progresso__topo flex align-items-start justify-content-between gap-3"},ge={key:0,class:"nc-legendas-flex flex flex-column"},ye={key:1,class:"nc-actions inline-flex align-items-center gap-2"},be=["innerHTML"],he={key:0,class:"card-progresso__titulos mt-3 mb-2 flex flex-column"},xe={class:"card-progresso__corpo flex align-items-center flex-wrap"},Se={key:0,class:"card-progresso__chart-wrap flex align-items-center justify-content-center"},ke={class:"card-progresso__chart"},Be={class:"nc-centro flex flex-column align-items-center justify-content-center"},Ee={class:"card-progresso__lista flex flex-column"},Ce={class:"card-progresso__item-cab flex align-items-center justify-content-between"},$e={key:0,class:"card-progresso__item-valor inline-flex align-items-center gap-2"},Ve={key:0},Ne={key:1,class:"card-progresso__footer mt-3"},mt=Q({__name:"CardProgresso",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corTexto:{type:String,default:null},corBorda:{type:String,default:"#EAE8E8"},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06)"},corDetalhes:{type:String,default:"#3B82F6"},corExcesso:{type:String,default:"#EF4444"},textoBotao:{type:String,default:"Ver mais"},botaoVisivel:{type:Boolean,default:!1},direcao:{type:String,default:"top",validator:e=>["top","bottom","left","right"].includes(e)},formato:{type:String,default:"linear",validator:e=>["linear","circular"].includes(e)},tipoValor:{type:String,default:"numero",validator:e=>["numero","moeda","percentual"].includes(e)},locale:{type:String,default:"pt-BR"},moeda:{type:String,default:"BRL"},data:{type:Array,default:()=>[{rotulo:"Vendas",quantidade:72,meta:100},{rotulo:"Serviços",quantidade:48,meta:80},{rotulo:"Assinaturas",quantidade:35,meta:60},{rotulo:"Suporte",quantidade:18,meta:40}]},metaPadrao:{type:Number,default:100},mostrarValor:{type:Boolean,default:!0},mostrarPercentual:{type:Boolean,default:!0},alturaBarra:{type:[String,Number],default:8},raioBarra:{type:[String,Number],default:"999px"},height:{type:[String,Number],default:220},cutout:{type:[String,Number],default:"78%"},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-progresso.png"}},emits:["botaoAcao","exportado"],setup(e,{emit:f}){const o=e,i=f,{palette:a,cardStyle:S}=Z(o),{formatar:b}=ot(o),k=t.ref(null),F=tt;async function B(){await v(k.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),i("exportado")}const V=t.computed(()=>`card-progresso--${o.direcao}`),N=t.computed(()=>{const s=nt(o.corDetalhes,o.data.length);return o.data.map((r,u)=>{const y=Number(r.meta??o.metaPadrao)||0,l=Number(r.quantidade)||0,d=r.cor??s[u],n=r.modo==="reducao";let p;if(n){const g=Number(r.valor_referencia)||0,z=g-y;p=z>0?Math.max(0,Math.min(100,(g-l)/z*100)):0}else p=y>0?Math.max(0,Math.min(100,l/y*100)):0;return{rotulo:r.rotulo,quantidade:l,meta:y,valorReferencia:r.valor_referencia??null,cor:d,percentual:p,reducao:n}})}),j=t.computed(()=>typeof o.alturaBarra=="number"?`${o.alturaBarra}px`:o.alturaBarra),M=t.computed(()=>typeof o.raioBarra=="number"?`${o.raioBarra}px`:o.raioBarra);t.computed(()=>N.value.reduce((s,r)=>s+r.quantidade,0)),t.computed(()=>N.value.reduce((s,r)=>s+r.meta,0));const J=t.computed(()=>N.value.length?N.value.reduce((s,r)=>s+r.percentual,0)/N.value.length:0),Y=t.computed(()=>N.value.every(s=>s.reducao)),m=t.computed(()=>{const s=Math.min(J.value,100),r=Math.max(0,100-s),u=Y.value?o.corExcesso:o.corDetalhes;return{labels:["Progresso","Restante"],datasets:[{data:[s,r],backgroundColor:[u,R(a.value.muted,.15)],borderWidth:0,borderColor:"transparent",hoverOffset:0,spacing:0}]}}),$=t.computed(()=>({responsive:!0,maintainAspectRatio:!1,cutout:o.cutout,rotation:-90,circumference:360,layout:{padding:4},plugins:{legend:{display:!1},tooltip:{enabled:!1}}}));function T(s){const r=k.value;if(!r)return;getComputedStyle(r).position==="static"&&(r.style.position="relative");const u=at(r);u.style.whiteSpace="normal";const y=u.querySelector(".nc-tt__content");y.innerHTML='<span style="font-size:11px;color:#0F172A;display:block;max-width:140px;line-height:1.5;"><strong>Modo Redução</strong>: o progresso aumenta conforme o valor diminui</span>',u.style.opacity="1",u.style.visibility="hidden",u.style.left="0px",u.style.top="0px",u.offsetWidth;const l=s.currentTarget.getBoundingClientRect(),d=r.getBoundingClientRect(),n=l.left-d.left+l.width/2,p=l.top-d.top;u.style.transform="translate(-50%, calc(-100% - 8px))";const g=u.querySelector(".nc-tt__caret");g&&Object.assign(g.style,{top:"",bottom:"-5px",borderLeft:"",borderTop:"",borderRight:"1px solid rgba(15,23,42,.06)",borderBottom:"1px solid rgba(15,23,42,.06)"}),u.style.left=n+"px",u.style.top=p+"px",u.style.visibility="visible"}function O(){var r;const s=(r=k.value)==null?void 0:r.querySelector(".nc-tt");s&&(s.style.opacity="0")}function c(){i("botaoAcao")}return(s,r)=>(t.openBlock(),t.createElementBlock("div",{ref_key:"cardRef",ref:k,class:t.normalizeClass(["card-progresso p-4 flex flex-column",V.value]),style:t.normalizeStyle(t.unref(S))},[t.createElementVNode("div",ue,[s.$slots.legenda||e.legenda||s.$slots.sublegenda||e.sublegenda?(t.openBlock(),t.createElementBlock("div",ge,[s.$slots.legenda||e.legenda?(t.openBlock(),t.createElementBlock("div",{key:0,class:"text-xs font-medium",style:t.normalizeStyle({color:t.unref(a).text,opacity:.95})},[t.renderSlot(s.$slots,"legenda",{},()=>[t.createTextVNode(t.toDisplayString(e.legenda),1)],!0)],4)):t.createCommentVNode("",!0),s.$slots.sublegenda||e.sublegenda?(t.openBlock(),t.createElementBlock("div",{key:1,class:"text-xs",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(s.$slots,"sublegenda",{},()=>[t.createTextVNode(t.toDisplayString(e.sublegenda),1)],!0)],4)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),s.$slots.actions||e.botaoVisivel||e.exportar?(t.openBlock(),t.createElementBlock("div",ye,[t.renderSlot(s.$slots,"actions",{},()=>[e.botaoVisivel?(t.openBlock(),t.createElementBlock("button",{key:0,class:"nc-btn inline-flex align-items-center",style:t.normalizeStyle({color:t.unref(a).text,borderColor:t.unref(R)(t.unref(a).text,.18)}),onClick:c},[t.createElementVNode("span",null,t.toDisplayString(e.textoBotao),1)],4)):t.createCommentVNode("",!0)],!0),e.exportar?(t.openBlock(),t.createElementBlock("button",{key:0,type:"button",class:"nc-exportar inline-flex align-items-center justify-content-center",style:t.normalizeStyle({color:t.unref(a).muted,borderColor:t.unref(R)(t.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:t.unref(F)},null,12,be)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)]),s.$slots.titulo||e.titulo||s.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",he,[s.$slots.titulo||e.titulo?(t.openBlock(),t.createElementBlock("div",{key:0,class:"m-0 text-3xl font-semibold",style:t.normalizeStyle({color:t.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[t.renderSlot(s.$slots,"titulo",{},()=>[t.createTextVNode(t.toDisplayString(e.titulo),1)],!0)],4)):t.createCommentVNode("",!0),s.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",{key:1,class:"text-sm mt-1",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(s.$slots,"descricao",{},()=>[t.createTextVNode(t.toDisplayString(e.descricao),1)],!0)],4)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),t.createElementVNode("div",xe,[e.formato==="circular"?(t.openBlock(),t.createElementBlock("div",Se,[t.createElementVNode("div",ke,[t.createVNode(U,{type:"doughnut",data:m.value,options:$.value,height:e.height},null,8,["data","options","height"]),t.createElementVNode("div",Be,[t.createElementVNode("div",{class:"nc-centro-titulo",style:t.normalizeStyle({color:Y.value?o.corExcesso:t.unref(a).text})},t.toDisplayString(Math.round(J.value))+"% ",5)])])])):t.createCommentVNode("",!0),t.createElementVNode("div",Ee,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(N.value,(u,y)=>(t.openBlock(),t.createElementBlock("div",{key:y,class:"card-progresso__item flex flex-column"},[t.createElementVNode("div",Ce,[t.createElementVNode("span",{class:"card-progresso__item-rotulo inline-flex align-items-center gap-2",style:t.normalizeStyle({color:t.unref(a).text})},[t.createElementVNode("span",{class:"nc-bolinha",style:t.normalizeStyle({background:u.cor})},null,4),t.createElementVNode("span",null,t.toDisplayString(u.rotulo),1),u.reducao?(t.openBlock(),t.createElementBlock("span",{key:0,class:"card-progresso__item-modo",style:t.normalizeStyle({color:t.unref(a).muted}),onMouseenter:T,onMouseleave:O},"↓",36)):t.createCommentVNode("",!0)],4),e.mostrarValor||e.mostrarPercentual?(t.openBlock(),t.createElementBlock("span",$e,[e.mostrarValor?(t.openBlock(),t.createElementBlock("span",{key:0,class:"card-progresso__item-nums",style:t.normalizeStyle({color:t.unref(a).muted})},[t.createTextVNode(t.toDisplayString(t.unref(b)(u.quantidade)),1),u.meta?(t.openBlock(),t.createElementBlock("span",Ve," / "+t.toDisplayString(t.unref(b)(u.meta)),1)):t.createCommentVNode("",!0)],4)):t.createCommentVNode("",!0),e.mostrarPercentual?(t.openBlock(),t.createElementBlock("span",{key:1,class:"card-progresso__item-pct",style:t.normalizeStyle({background:t.unref(R)(u.cor,.12),color:u.cor})},t.toDisplayString(Math.round(u.percentual))+"% ",5)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0)]),t.createElementVNode("div",{class:"card-progresso__trilha w-full",style:t.normalizeStyle({height:j.value,borderRadius:M.value,background:u.reducao?t.unref(R)(o.corExcesso,.18):t.unref(R)(t.unref(a).muted,.15)})},[t.createElementVNode("div",{class:"card-progresso__preenchimento",style:t.normalizeStyle({width:u.percentual+"%",background:u.cor,borderRadius:M.value})},null,4)],4)]))),128))])]),s.$slots.footer?(t.openBlock(),t.createElementBlock("div",Ne,[t.renderSlot(s.$slots,"footer",{},void 0,!0)])):t.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-f738fbcc"]]),Te={key:0,class:"card-base__topo"},ze=["innerHTML"],Ae={class:"card-base__legendas flex flex-column"},Re={key:1,class:"card-base__titulos flex flex-column"},we={key:2,class:"card-base__acao flex"},qe={key:3,class:"card-base__footer"},ft=Q({__name:"CardBase",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},titulo:{type:String,default:null},descricao:{type:String,default:null},tema:{type:String,default:"light"},corFundo:{type:String,default:null},corTexto:{type:String,default:null},corBorda:{type:String,default:"#EAE8E8"},borderRadius:{type:[String,Number],default:"0.75rem"},sombra:{type:String,default:"none"},textoBotao:{type:String,default:"Ver Todos"},botaoVisivel:{type:Boolean,default:!0},alinhamento:{type:String,default:"left",validator:e=>["left","center","right"].includes(e)},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card-base.png"}},emits:["botaoAcao","exportado"],setup(e,{emit:f}){const o=e,i=f,{palette:a,cardStyle:S}=Z(o),b=t.ref(null),k=tt;function F(){i("botaoAcao")}async function B(){await v(b.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),i("exportado")}return(V,N)=>(t.openBlock(),t.createElementBlock("div",{ref_key:"cardRef",ref:b,class:t.normalizeClass(["card-base flex flex-column",`card-base--${e.alinhamento}`]),style:t.normalizeStyle(t.unref(S))},[e.exportar?(t.openBlock(),t.createElementBlock("div",Te,[t.createElementVNode("button",{type:"button",class:"nc-exportar card-base__exportar inline-flex align-items-center justify-content-center",style:t.normalizeStyle({color:t.unref(a).muted,borderColor:t.unref(R)(t.unref(a).text==="inherit"?"#0F172A":t.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:t.unref(k)},null,12,ze)])):t.createCommentVNode("",!0),t.createElementVNode("div",Ae,[V.$slots.legenda||e.legenda?(t.openBlock(),t.createElementBlock("div",{key:0,class:"card-base__legenda font-medium text-xs",style:t.normalizeStyle({color:t.unref(a).text})},[t.renderSlot(V.$slots,"legenda",{},()=>[t.createTextVNode(t.toDisplayString(e.legenda),1)],!0)],4)):t.createCommentVNode("",!0),V.$slots.sublegenda||e.sublegenda?(t.openBlock(),t.createElementBlock("div",{key:1,class:"card-base__sublegenda text-xs",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(V.$slots,"sublegenda",{},()=>[t.createTextVNode(t.toDisplayString(e.sublegenda),1)],!0)],4)):t.createCommentVNode("",!0)]),V.$slots.titulo||e.titulo||V.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",Re,[V.$slots.titulo||e.titulo?(t.openBlock(),t.createElementBlock("div",{key:0,class:"card-base__titulo m-0 text-3xl font-semibold",style:t.normalizeStyle({color:t.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[t.renderSlot(V.$slots,"titulo",{},()=>[t.createTextVNode(t.toDisplayString(e.titulo),1)],!0)],4)):t.createCommentVNode("",!0),V.$slots.descricao||e.descricao?(t.openBlock(),t.createElementBlock("div",{key:1,class:"text-sm",style:t.normalizeStyle({color:t.unref(a).muted})},[t.renderSlot(V.$slots,"descricao",{},()=>[t.createTextVNode(t.toDisplayString(e.descricao),1)],!0)],4)):t.createCommentVNode("",!0)])):t.createCommentVNode("",!0),V.$slots.acao||e.botaoVisivel?(t.openBlock(),t.createElementBlock("div",we,[t.renderSlot(V.$slots,"acao",{},()=>[e.botaoVisivel?(t.openBlock(),t.createElementBlock("button",{key:0,type:"button",class:"card-base__link text-xs inline-flex align-items-center",style:t.normalizeStyle({color:t.unref(a).text}),onClick:F},[t.createElementVNode("span",null,t.toDisplayString(e.textoBotao),1),N[0]||(N[0]=t.createElementVNode("span",{class:"card-base__chevron","aria-hidden":"true"},"›",-1))],4)):t.createCommentVNode("",!0)],!0)])):t.createCommentVNode("",!0),V.$slots.footer?(t.openBlock(),t.createElementBlock("div",qe,[t.renderSlot(V.$slots,"footer",{},void 0,!0)])):t.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-d1b84008"]]),Fe={install(e){e.component("ChartBase",U),e.component("CardBase",ft),e.component("CardLinhas",st),e.component("CardPizza",it),e.component("CardBarra",ct),e.component("CardPolar",dt),e.component("CardProgresso",mt)}};H.CardBarra=ct,H.CardBase=ft,H.CardLinhas=st,H.CardPizza=it,H.CardPolar=dt,H.CardProgresso=mt,H.ChartBase=U,H.ICONE_EXPORTAR_SVG=tt,H.clampHorizontal=_,H.criarTooltipEl=at,H.default=Fe,H.exportarElementoComoImagem=v,H.gerarPaleta=nt,H.prepararTooltipParent=K,H.toRgba=R,H.useFormatadorValor=ot,H.useTema=Z,Object.defineProperties(H,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
package/dist/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
@import"https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap";@import"https://fonts.googleapis.com/css2?family=Geist:wght@100..900&display=swap";.nc-chart-wrapper[data-v-9828990e]{position:relative}.card-linhas[data-v-364ce1d1]{display:flex;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Inter,sans-serif}.card-linhas__header[data-v-364ce1d1]{display:flex;flex-direction:column;padding:1.5rem}.card-linhas__topo[data-v-364ce1d1]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-linhas__chart[data-v-364ce1d1]{flex:1 1 auto;min-width:0;min-height:0}.card-linhas--top[data-v-364ce1d1]{flex-direction:column;padding:0!important}.card-linhas--bottom[data-v-364ce1d1]{flex-direction:column-reverse;padding:0!important}.card-linhas--top .card-linhas__chart[data-v-364ce1d1],.card-linhas--bottom .card-linhas__chart[data-v-364ce1d1]{margin-left:0;margin-right:0}.card-linhas--top .card-linhas__chart[data-v-364ce1d1]{margin-bottom:0}.card-linhas--bottom .card-linhas__chart[data-v-364ce1d1]{margin-top:0}.card-linhas--left[data-v-364ce1d1]{flex-direction:row;align-items:stretch}.card-linhas--left .card-linhas__header[data-v-364ce1d1]{flex:0 0 35%;justify-content:center}.card-linhas--right[data-v-364ce1d1]{flex-direction:row-reverse;align-items:stretch}.card-linhas--right .card-linhas__header[data-v-364ce1d1]{flex:0 0 35%;justify-content:center}@media (max-width: 640px){.card-linhas[data-v-364ce1d1]{gap:.75rem}.card-linhas__topo[data-v-364ce1d1]{flex-wrap:wrap}.card-linhas--left[data-v-364ce1d1],.card-linhas--right[data-v-364ce1d1]{flex-direction:column;align-items:stretch}.card-linhas--left .card-linhas__header[data-v-364ce1d1],.card-linhas--right .card-linhas__header[data-v-364ce1d1]{flex:0 0 auto}.card-linhas--left .card-linhas__chart[data-v-364ce1d1],.card-linhas--right .card-linhas__chart[data-v-364ce1d1]{margin-left:0;margin-right:0}}.card-pizza[data-v-2a65258f]{container-type:inline-size;display:flex;flex-direction:column;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Geist,sans-serif}.card-pizza__topo[data-v-2a65258f]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-pizza__corpo[data-v-2a65258f]{display:flex;gap:3.5rem;align-items:center;flex:1 1 auto;min-height:0}.card-pizza--right .card-pizza__corpo[data-v-2a65258f]{flex-direction:row}.card-pizza--left .card-pizza__corpo[data-v-2a65258f]{flex-direction:row-reverse}.card-pizza--bottom .card-pizza__corpo[data-v-2a65258f]{flex-direction:column;align-items:stretch}.card-pizza--top .card-pizza__corpo[data-v-2a65258f]{flex-direction:column-reverse;align-items:stretch}.card-pizza--top .card-pizza__chart[data-v-2a65258f],.card-pizza--bottom .card-pizza__chart[data-v-2a65258f]{max-width:320px;margin:0 auto}.card-pizza--right .nc-tabela[data-v-2a65258f],.card-pizza--left .nc-tabela[data-v-2a65258f]{flex:1 1 0;min-width:0;overflow:hidden}.card-pizza--top .nc-tabela[data-v-2a65258f],.card-pizza--bottom .nc-tabela[data-v-2a65258f]{width:100%}.card-pizza--right .card-pizza__chart-wrap[data-v-2a65258f],.card-pizza--left .card-pizza__chart-wrap[data-v-2a65258f]{flex:0 0 clamp(140px,38%,240px);width:clamp(140px,38%,240px)}.card-pizza__chart-wrap[data-v-2a65258f]{display:flex;align-items:center;justify-content:center}.card-pizza__chart[data-v-2a65258f]{position:relative;width:100%;min-width:0}@container (max-width: 520px){.card-pizza[data-v-2a65258f]{gap:.75rem}.card-pizza__topo[data-v-2a65258f]{flex-wrap:wrap}.card-pizza--left .card-pizza__corpo[data-v-2a65258f],.card-pizza--right .card-pizza__corpo[data-v-2a65258f]{flex-direction:column;align-items:stretch;gap:1rem}.card-pizza--left .nc-tabela[data-v-2a65258f],.card-pizza--right .nc-tabela[data-v-2a65258f]{flex:1 1 auto;width:100%}.card-pizza--left .card-pizza__chart-wrap[data-v-2a65258f],.card-pizza--right .card-pizza__chart-wrap[data-v-2a65258f]{flex:0 0 auto;width:100%}.card-pizza__chart[data-v-2a65258f]{max-width:260px;margin:0 auto}.nc-centro-titulo[data-v-2a65258f]{font-size:1.05rem}.nc-centro-desc[data-v-2a65258f]{font-size:.58rem}.nc-tabela-linha[data-v-2a65258f]{font-size:.78rem}}@container (max-width: 340px){.card-pizza__chart[data-v-2a65258f]{max-width:200px}.nc-centro-titulo[data-v-2a65258f]{font-size:.9rem}.nc-tabela-linha[data-v-2a65258f]{font-size:.72rem}.nc-tabela-cab[data-v-2a65258f]{font-size:.68rem}}.card-barra[data-v-474043e8]{display:flex;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Inter,sans-serif}.card-barra__header[data-v-474043e8]{display:flex;flex-direction:column}.card-barra__topo[data-v-474043e8]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-barra__chart[data-v-474043e8]{flex:1 1 auto;min-width:0;min-height:var(--c9bf3d56)}.card-barra--top[data-v-474043e8]{flex-direction:column;align-items:stretch}.card-barra--bottom[data-v-474043e8]{flex-direction:column-reverse;align-items:stretch}.card-barra--top .card-barra__chart[data-v-474043e8],.card-barra--bottom .card-barra__chart[data-v-474043e8]{margin-left:-.5rem;margin-right:-.5rem}.card-barra--top .card-barra__chart[data-v-474043e8]{margin-bottom:-.5rem}.card-barra--bottom .card-barra__chart[data-v-474043e8]{margin-top:-.5rem}.card-barra--left[data-v-474043e8]{flex-direction:row;align-items:stretch}.card-barra--left .card-barra__header[data-v-474043e8]{flex:0 0 35%;justify-content:center}.card-barra--right[data-v-474043e8]{flex-direction:row-reverse;align-items:stretch}.card-barra--right .card-barra__header[data-v-474043e8]{flex:0 0 35%;justify-content:center}.card-polar[data-v-94cbf2b0]{container-type:inline-size;display:flex;flex-direction:column;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Geist,sans-serif}.card-polar__topo[data-v-94cbf2b0]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-polar__corpo[data-v-94cbf2b0]{display:flex;gap:3.5rem;align-items:center;flex:1 1 auto;min-height:0}.card-polar--right .card-polar__corpo[data-v-94cbf2b0]{flex-direction:row}.card-polar--left .card-polar__corpo[data-v-94cbf2b0]{flex-direction:row-reverse}.card-polar--bottom .card-polar__corpo[data-v-94cbf2b0]{flex-direction:column;align-items:stretch}.card-polar--top .card-polar__corpo[data-v-94cbf2b0]{flex-direction:column-reverse;align-items:stretch}.card-polar--top .card-polar__chart[data-v-94cbf2b0],.card-polar--bottom .card-polar__chart[data-v-94cbf2b0]{max-width:320px;margin:0 auto}.card-polar--right .nc-tabela[data-v-94cbf2b0],.card-polar--left .nc-tabela[data-v-94cbf2b0]{flex:1 1 0;min-width:0;overflow:hidden}.card-polar--top .nc-tabela[data-v-94cbf2b0],.card-polar--bottom .nc-tabela[data-v-94cbf2b0]{width:100%}.card-polar--right .card-polar__chart-wrap[data-v-94cbf2b0],.card-polar--left .card-polar__chart-wrap[data-v-94cbf2b0]{flex:0 0 clamp(140px,38%,240px);width:clamp(140px,38%,240px)}.card-polar__chart-wrap[data-v-94cbf2b0]{display:flex;align-items:center;justify-content:center}.card-polar__chart[data-v-94cbf2b0]{position:relative;width:100%;min-width:0}.card-polar__centro-bottom[data-v-94cbf2b0]{text-align:center;margin-top:.5rem}.card-polar__centro-titulo[data-v-94cbf2b0]{font-size:1.15rem;font-weight:600;line-height:1.2}.card-polar__centro-desc[data-v-94cbf2b0]{font-size:.85rem;margin-top:.15rem}@container (max-width: 520px){.card-polar[data-v-94cbf2b0]{gap:.75rem}.card-polar__topo[data-v-94cbf2b0]{flex-wrap:wrap}.card-polar--left .card-polar__corpo[data-v-94cbf2b0],.card-polar--right .card-polar__corpo[data-v-94cbf2b0]{flex-direction:column;align-items:stretch;gap:1rem}.card-polar--left .nc-tabela[data-v-94cbf2b0],.card-polar--right .nc-tabela[data-v-94cbf2b0]{flex:1 1 auto;width:100%}.card-polar--left .card-polar__chart-wrap[data-v-94cbf2b0],.card-polar--right .card-polar__chart-wrap[data-v-94cbf2b0]{flex:0 0 auto;width:100%}.card-polar__chart[data-v-94cbf2b0]{max-width:260px;margin:0 auto}.card-polar__centro-titulo[data-v-94cbf2b0]{font-size:1rem}.card-polar__centro-desc[data-v-94cbf2b0],.nc-tabela-linha[data-v-94cbf2b0]{font-size:.78rem}}@container (max-width: 340px){.card-polar__chart[data-v-94cbf2b0]{max-width:200px}.card-polar__centro-titulo[data-v-94cbf2b0]{font-size:.9rem}.nc-tabela-linha[data-v-94cbf2b0]{font-size:.72rem}.nc-tabela-cab[data-v-94cbf2b0]{font-size:.68rem}}.card-progresso[data-v-36cee8f0]{container-type:inline-size;display:flex;flex-direction:column;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Inter,sans-serif}.card-progresso__topo[data-v-36cee8f0]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-progresso__corpo[data-v-36cee8f0]{display:flex;gap:3.5rem;align-items:stretch;flex:1 1 auto;min-height:0;flex-wrap:wrap}.card-progresso--top .card-progresso__corpo[data-v-36cee8f0]{flex-direction:column;align-items:stretch;flex-wrap:nowrap}.card-progresso--bottom .card-progresso__corpo[data-v-36cee8f0]{flex-direction:column-reverse;align-items:stretch;flex-wrap:nowrap}.card-progresso--right .card-progresso__corpo[data-v-36cee8f0]{flex-direction:row-reverse;flex-wrap:nowrap}.card-progresso--left .card-progresso__corpo[data-v-36cee8f0]{flex-direction:row;flex-wrap:nowrap}.card-progresso--left .card-progresso__chart-wrap[data-v-36cee8f0],.card-progresso--right .card-progresso__chart-wrap[data-v-36cee8f0]{align-self:center}.card-progresso__chart-wrap[data-v-36cee8f0]{flex:0 0 clamp(140px,38%,220px);width:clamp(140px,38%,220px);display:flex;align-items:center;justify-content:center;min-width:0}.card-progresso--top .card-progresso__chart-wrap[data-v-36cee8f0],.card-progresso--bottom .card-progresso__chart-wrap[data-v-36cee8f0]{flex:0 0 auto;width:100%;max-width:280px;margin:0 auto}.card-progresso__chart[data-v-36cee8f0]{position:relative;width:100%}@container (max-width: 520px){.card-progresso[data-v-36cee8f0]{gap:.75rem}.card-progresso__topo[data-v-36cee8f0]{flex-wrap:wrap}.card-progresso--left .card-progresso__corpo[data-v-36cee8f0],.card-progresso--right .card-progresso__corpo[data-v-36cee8f0]{flex-direction:column;align-items:stretch;flex-wrap:nowrap}.card-progresso--left .card-progresso__chart-wrap[data-v-36cee8f0],.card-progresso--right .card-progresso__chart-wrap[data-v-36cee8f0]{flex:0 0 auto;width:100%;max-width:240px;margin:0 auto}.nc-centro-titulo[data-v-36cee8f0]{font-size:1.05rem}.nc-centro-desc[data-v-36cee8f0]{font-size:.58rem}.card-progresso__item-cab[data-v-36cee8f0]{font-size:.78rem;gap:.5rem}}@container (max-width: 380px){.card-progresso__item-cab[data-v-36cee8f0]{flex-wrap:wrap}}.nc-centro-desc[data-v-36cee8f0]{font-variant-numeric:tabular-nums}.card-progresso__lista[data-v-36cee8f0]{display:flex;flex-direction:column;gap:.85rem;flex:1 1 auto;min-width:0;width:100%}.card-progresso--left .card-progresso__lista[data-v-36cee8f0],.card-progresso--right .card-progresso__lista[data-v-36cee8f0]{flex:1 1 0;width:100%;min-width:0}.card-progresso__item[data-v-36cee8f0]{display:flex;flex-direction:column;gap:.4rem}.card-progresso__item-cab[data-v-36cee8f0]{display:flex;justify-content:space-between;align-items:center;gap:.75rem;font-size:.82rem}.card-progresso__item-rotulo[data-v-36cee8f0]{display:inline-flex;align-items:center;gap:.55rem;min-width:0;font-weight:500}.card-progresso__item-valor[data-v-36cee8f0]{display:inline-flex;align-items:center;gap:.5rem}.card-progresso__item-modo[data-v-36cee8f0]{font-size:.7rem;font-weight:500;line-height:1}.card-progresso__item-nums[data-v-36cee8f0]{font-size:.78rem;font-variant-numeric:tabular-nums;font-weight:400}.card-progresso__item-pct[data-v-36cee8f0]{font-size:.7rem;font-weight:600;padding:.15rem .45rem;border-radius:999px;font-variant-numeric:tabular-nums;white-space:nowrap;line-height:1.4}.card-progresso__trilha[data-v-36cee8f0]{width:100%;overflow:hidden;position:relative}.card-progresso__preenchimento[data-v-36cee8f0]{height:100%;transition:width .4s ease}.card-base[data-v-61091b7c]{display:flex;flex-direction:column;gap:1.25rem;padding:1.25rem;transition:background .2s ease;overflow:hidden;font-family:Geist,sans-serif;position:relative}.card-base--left[data-v-61091b7c]{text-align:left;align-items:stretch}.card-base--center[data-v-61091b7c]{text-align:center;align-items:center}.card-base--right[data-v-61091b7c]{text-align:right;align-items:flex-end}.card-base__topo[data-v-61091b7c]{position:absolute;top:.75rem;right:.75rem}.card-base__legendas[data-v-61091b7c]{display:flex;flex-direction:column;gap:.15rem}.card-base__legenda[data-v-61091b7c]{line-height:1.2;letter-spacing:-.005em}.card-base__sublegenda[data-v-61091b7c]{font-size:.78rem;font-weight:400;line-height:1.2}.card-base__titulos[data-v-61091b7c]{display:flex;flex-direction:column;gap:.25rem}.card-base__titulo[data-v-61091b7c]{font-size:1.85rem;font-weight:700;line-height:1.15;letter-spacing:-.015em;word-break:break-word}.card-base__acao[data-v-61091b7c]{display:flex}.card-base--center .card-base__acao[data-v-61091b7c]{justify-content:center}.card-base--right .card-base__acao[data-v-61091b7c]{justify-content:flex-end}.card-base__link[data-v-61091b7c]{display:inline-flex;align-items:center;gap:.35rem;background:transparent;border:none;padding:0;font-weight:500;cursor:pointer;font-family:inherit;transition:opacity .2s ease}.card-base__link[data-v-61091b7c]:hover{opacity:.7}.card-base__chevron[data-v-61091b7c]{font-size:1.1rem;line-height:1;font-weight:400;transform:translateY(-1px)}.card-base__exportar[data-v-61091b7c]{width:28px;height:28px}.card-base__footer[data-v-61091b7c]{margin-top:.25rem}.nc-actions{flex:0 0 auto;display:inline-flex;align-items:center;gap:.5rem}.nc-legendas-flex{min-width:0;flex:1 1 auto}.nc-exportar{display:inline-flex;align-items:center;justify-content:center;width:30px;height:30px;padding:0;background:transparent;border:1px solid rgba(15,23,42,.18);border-radius:8px;cursor:pointer;transition:opacity .2s ease,background .2s ease;font-family:inherit}.nc-exportar:hover{opacity:.7}.nc-exportar svg{display:block}.nc-btn{display:inline-flex;align-items:center;gap:.4rem;background:transparent;border:1px solid rgba(15,23,42,.18);border-radius:10px;padding:.5rem 1.1rem;font-size:.9rem;font-weight:500;cursor:pointer;transition:opacity .2s ease,background .2s ease;align-self:flex-start;font-family:inherit}.nc-btn:hover{opacity:.75}.nc-bolinha{width:8px;height:8px;border-radius:999px;flex:0 0 auto;display:inline-block}.nc-centro{position:absolute;top:0;right:0;bottom:0;left:0;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;pointer-events:none;padding:0 1rem}.nc-centro-titulo{font-size:1.25rem;font-weight:600;line-height:1.2;letter-spacing:-.5px}.nc-centro-desc{font-size:.6rem;line-height:1.3;max-width:80px;margin-top:.15rem}.nc-tabela{display:flex;flex-direction:column;flex:1 1 auto;min-width:0}.nc-tabela-cab{display:flex;justify-content:space-between;align-items:center;font-size:.72rem;font-weight:500;padding:0 0 .5rem;border-bottom:1px solid}.nc-tabela-linha{display:flex;justify-content:space-between;align-items:center;padding:.4rem 0;font-size:.8rem}.nc-tabela-rotulo{display:inline-flex;align-items:center;gap:.65rem;min-width:0;flex:1 1 0;overflow:hidden}.nc-tabela-rotulo>span:last-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.nc-tabela-valor{font-variant-numeric:tabular-nums;font-weight:500;flex-shrink:0;white-space:nowrap;padding-left:.5rem}@media (max-width: 640px){.nc-btn{padding:.4rem .85rem;font-size:.82rem}}
|
|
1
|
+
@import"https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap";@import"https://fonts.googleapis.com/css2?family=Geist:wght@100..900&display=swap";.nc-chart-wrapper[data-v-9828990e]{position:relative}.card-linhas[data-v-513bd6fe]{display:flex;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Inter,sans-serif}.card-linhas__header[data-v-513bd6fe]{display:flex;flex-direction:column;padding:1.5rem}.card-linhas__topo[data-v-513bd6fe]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-linhas__chart[data-v-513bd6fe]{flex:1 1 auto;min-width:0;min-height:0}.card-linhas--top[data-v-513bd6fe]{flex-direction:column;padding:0!important}.card-linhas--bottom[data-v-513bd6fe]{flex-direction:column-reverse;padding:0!important}.card-linhas--top .card-linhas__chart[data-v-513bd6fe],.card-linhas--bottom .card-linhas__chart[data-v-513bd6fe]{margin-left:0;margin-right:0}.card-linhas--top .card-linhas__chart[data-v-513bd6fe]{margin-bottom:0}.card-linhas--bottom .card-linhas__chart[data-v-513bd6fe]{margin-top:0}.card-linhas--left[data-v-513bd6fe]{flex-direction:row;align-items:stretch}.card-linhas--left .card-linhas__header[data-v-513bd6fe]{flex:0 0 35%;justify-content:center}.card-linhas--right[data-v-513bd6fe]{flex-direction:row-reverse;align-items:stretch}.card-linhas--right .card-linhas__header[data-v-513bd6fe]{flex:0 0 35%;justify-content:center}@media (max-width: 640px){.card-linhas[data-v-513bd6fe]{gap:.75rem}.card-linhas__topo[data-v-513bd6fe]{flex-wrap:wrap}.card-linhas--left[data-v-513bd6fe],.card-linhas--right[data-v-513bd6fe]{flex-direction:column;align-items:stretch}.card-linhas--left .card-linhas__header[data-v-513bd6fe],.card-linhas--right .card-linhas__header[data-v-513bd6fe]{flex:0 0 auto}.card-linhas--left .card-linhas__chart[data-v-513bd6fe],.card-linhas--right .card-linhas__chart[data-v-513bd6fe]{margin-left:0;margin-right:0}}.card-pizza[data-v-e0fe217f]{container-type:inline-size;display:flex;flex-direction:column;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Geist,sans-serif}.card-pizza__topo[data-v-e0fe217f]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-pizza__corpo[data-v-e0fe217f]{display:flex;gap:3.5rem;align-items:center;flex:1 1 auto;min-height:0}.card-pizza--right .card-pizza__corpo[data-v-e0fe217f]{flex-direction:row}.card-pizza--left .card-pizza__corpo[data-v-e0fe217f]{flex-direction:row-reverse}.card-pizza--bottom .card-pizza__corpo[data-v-e0fe217f]{flex-direction:column;align-items:stretch}.card-pizza--top .card-pizza__corpo[data-v-e0fe217f]{flex-direction:column-reverse;align-items:stretch}.card-pizza--top .card-pizza__chart[data-v-e0fe217f],.card-pizza--bottom .card-pizza__chart[data-v-e0fe217f]{max-width:320px;margin:0 auto}.card-pizza--right .nc-tabela[data-v-e0fe217f],.card-pizza--left .nc-tabela[data-v-e0fe217f]{flex:1 1 0;min-width:0;overflow:hidden}.card-pizza--top .nc-tabela[data-v-e0fe217f],.card-pizza--bottom .nc-tabela[data-v-e0fe217f]{width:100%}.card-pizza--right .card-pizza__chart-wrap[data-v-e0fe217f],.card-pizza--left .card-pizza__chart-wrap[data-v-e0fe217f]{flex:0 0 clamp(140px,38%,240px);width:clamp(140px,38%,240px)}.card-pizza__chart-wrap[data-v-e0fe217f]{display:flex;align-items:center;justify-content:center}.card-pizza__chart[data-v-e0fe217f]{position:relative;width:100%;min-width:0}@container (max-width: 520px){.card-pizza[data-v-e0fe217f]{gap:.75rem}.card-pizza__topo[data-v-e0fe217f]{flex-wrap:wrap}.card-pizza--left .card-pizza__corpo[data-v-e0fe217f],.card-pizza--right .card-pizza__corpo[data-v-e0fe217f]{flex-direction:column-reverse;align-items:stretch;gap:1rem}.card-pizza--left .nc-tabela[data-v-e0fe217f],.card-pizza--right .nc-tabela[data-v-e0fe217f]{flex:1 1 auto;width:100%}.card-pizza--left .card-pizza__chart-wrap[data-v-e0fe217f],.card-pizza--right .card-pizza__chart-wrap[data-v-e0fe217f]{flex:0 0 auto;width:100%}.card-pizza__chart[data-v-e0fe217f]{max-width:260px;margin:0 auto}.nc-centro-titulo[data-v-e0fe217f]{font-size:1.05rem}.nc-centro-desc[data-v-e0fe217f]{font-size:.58rem}.nc-tabela-linha[data-v-e0fe217f]{font-size:.78rem}}@container (max-width: 340px){.card-pizza__chart[data-v-e0fe217f]{max-width:200px}.nc-centro-titulo[data-v-e0fe217f]{font-size:.9rem}.nc-tabela-linha[data-v-e0fe217f]{font-size:.72rem}.nc-tabela-cab[data-v-e0fe217f]{font-size:.68rem}}.card-barra[data-v-474043e8]{display:flex;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Inter,sans-serif}.card-barra__header[data-v-474043e8]{display:flex;flex-direction:column}.card-barra__topo[data-v-474043e8]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-barra__chart[data-v-474043e8]{flex:1 1 auto;min-width:0;min-height:var(--c9bf3d56)}.card-barra--top[data-v-474043e8]{flex-direction:column;align-items:stretch}.card-barra--bottom[data-v-474043e8]{flex-direction:column-reverse;align-items:stretch}.card-barra--top .card-barra__chart[data-v-474043e8],.card-barra--bottom .card-barra__chart[data-v-474043e8]{margin-left:-.5rem;margin-right:-.5rem}.card-barra--top .card-barra__chart[data-v-474043e8]{margin-bottom:-.5rem}.card-barra--bottom .card-barra__chart[data-v-474043e8]{margin-top:-.5rem}.card-barra--left[data-v-474043e8]{flex-direction:row;align-items:stretch}.card-barra--left .card-barra__header[data-v-474043e8]{flex:0 0 35%;justify-content:center}.card-barra--right[data-v-474043e8]{flex-direction:row-reverse;align-items:stretch}.card-barra--right .card-barra__header[data-v-474043e8]{flex:0 0 35%;justify-content:center}.card-polar[data-v-352f2f67]{container-type:inline-size;display:flex;flex-direction:column;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Geist,sans-serif}.card-polar__topo[data-v-352f2f67]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-polar__corpo[data-v-352f2f67]{display:flex;gap:3.5rem;align-items:center;flex:1 1 auto;min-height:0}.card-polar--right .card-polar__corpo[data-v-352f2f67]{flex-direction:row}.card-polar--left .card-polar__corpo[data-v-352f2f67]{flex-direction:row-reverse}.card-polar--bottom .card-polar__corpo[data-v-352f2f67]{flex-direction:column;align-items:stretch}.card-polar--top .card-polar__corpo[data-v-352f2f67]{flex-direction:column-reverse;align-items:stretch}.card-polar--top .card-polar__chart[data-v-352f2f67],.card-polar--bottom .card-polar__chart[data-v-352f2f67]{max-width:320px;margin:0 auto}.card-polar--right .nc-tabela[data-v-352f2f67],.card-polar--left .nc-tabela[data-v-352f2f67]{flex:1 1 0;min-width:0;overflow:hidden}.card-polar--top .nc-tabela[data-v-352f2f67],.card-polar--bottom .nc-tabela[data-v-352f2f67]{width:100%}.card-polar--right .card-polar__chart-wrap[data-v-352f2f67],.card-polar--left .card-polar__chart-wrap[data-v-352f2f67]{flex:0 0 clamp(140px,38%,240px);width:clamp(140px,38%,240px)}.card-polar__chart-wrap[data-v-352f2f67]{display:flex;align-items:center;justify-content:center}.card-polar__chart[data-v-352f2f67]{position:relative;width:100%;min-width:0}.card-polar__centro-bottom[data-v-352f2f67]{text-align:center;margin-top:.5rem}.card-polar__centro-titulo[data-v-352f2f67]{font-size:1.15rem;font-weight:600;line-height:1.2}.card-polar__centro-desc[data-v-352f2f67]{font-size:.85rem;margin-top:.15rem}@container (max-width: 520px){.card-polar[data-v-352f2f67]{gap:.75rem}.card-polar__topo[data-v-352f2f67]{flex-wrap:wrap}.card-polar--left .card-polar__corpo[data-v-352f2f67],.card-polar--right .card-polar__corpo[data-v-352f2f67]{flex-direction:column-reverse;align-items:stretch;gap:1rem}.card-polar--left .nc-tabela[data-v-352f2f67],.card-polar--right .nc-tabela[data-v-352f2f67]{flex:1 1 auto;width:100%}.card-polar--left .card-polar__chart-wrap[data-v-352f2f67],.card-polar--right .card-polar__chart-wrap[data-v-352f2f67]{flex:0 0 auto;width:100%}.card-polar__chart[data-v-352f2f67]{max-width:260px;margin:0 auto}.card-polar__centro-titulo[data-v-352f2f67]{font-size:1rem}.card-polar__centro-desc[data-v-352f2f67],.nc-tabela-linha[data-v-352f2f67]{font-size:.78rem}}@container (max-width: 340px){.card-polar__chart[data-v-352f2f67]{max-width:200px}.card-polar__centro-titulo[data-v-352f2f67]{font-size:.9rem}.nc-tabela-linha[data-v-352f2f67]{font-size:.72rem}.nc-tabela-cab[data-v-352f2f67]{font-size:.68rem}}.card-progresso[data-v-f738fbcc]{container-type:inline-size;display:flex;flex-direction:column;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Inter,sans-serif}.card-progresso__topo[data-v-f738fbcc]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-progresso__corpo[data-v-f738fbcc]{display:flex;gap:3.5rem;align-items:stretch;flex:1 1 auto;min-height:0;flex-wrap:wrap}.card-progresso--top .card-progresso__corpo[data-v-f738fbcc]{flex-direction:column;align-items:stretch;flex-wrap:nowrap}.card-progresso--bottom .card-progresso__corpo[data-v-f738fbcc]{flex-direction:column-reverse;align-items:stretch;flex-wrap:nowrap}.card-progresso--right .card-progresso__corpo[data-v-f738fbcc]{flex-direction:row-reverse;flex-wrap:nowrap}.card-progresso--left .card-progresso__corpo[data-v-f738fbcc]{flex-direction:row;flex-wrap:nowrap}.card-progresso--left .card-progresso__chart-wrap[data-v-f738fbcc],.card-progresso--right .card-progresso__chart-wrap[data-v-f738fbcc]{align-self:center}.card-progresso__chart-wrap[data-v-f738fbcc]{flex:0 0 clamp(140px,38%,220px);width:clamp(140px,38%,220px);display:flex;align-items:center;justify-content:center;min-width:0}.card-progresso--top .card-progresso__chart-wrap[data-v-f738fbcc],.card-progresso--bottom .card-progresso__chart-wrap[data-v-f738fbcc]{flex:0 0 auto;width:100%;max-width:280px;margin:0 auto}.card-progresso__chart[data-v-f738fbcc]{position:relative;width:100%}@container (max-width: 520px){.card-progresso[data-v-f738fbcc]{gap:.75rem}.card-progresso__topo[data-v-f738fbcc]{flex-wrap:wrap}.card-progresso--left .card-progresso__corpo[data-v-f738fbcc],.card-progresso--right .card-progresso__corpo[data-v-f738fbcc]{flex-direction:column;align-items:stretch;flex-wrap:nowrap}.card-progresso--left .card-progresso__chart-wrap[data-v-f738fbcc],.card-progresso--right .card-progresso__chart-wrap[data-v-f738fbcc]{flex:0 0 auto;width:100%;max-width:240px;margin:0 auto}.nc-centro-titulo[data-v-f738fbcc]{font-size:1.05rem}.nc-centro-desc[data-v-f738fbcc]{font-size:.58rem}.card-progresso__item-cab[data-v-f738fbcc]{font-size:.78rem;gap:.5rem}}@container (max-width: 380px){.card-progresso__item-cab[data-v-f738fbcc]{flex-wrap:wrap}}.nc-centro-titulo[data-v-f738fbcc]{font-size:1.6rem;font-weight:700;font-variant-numeric:tabular-nums}.card-progresso__lista[data-v-f738fbcc]{display:flex;flex-direction:column;gap:.85rem;flex:1 1 auto;min-width:0;width:100%}.card-progresso--left .card-progresso__lista[data-v-f738fbcc],.card-progresso--right .card-progresso__lista[data-v-f738fbcc]{flex:1 1 0;width:100%;min-width:0}.card-progresso__item[data-v-f738fbcc]{display:flex;flex-direction:column;gap:.4rem}.card-progresso__item-cab[data-v-f738fbcc]{display:flex;justify-content:space-between;align-items:center;gap:.75rem;font-size:.82rem}.card-progresso__item-rotulo[data-v-f738fbcc]{display:inline-flex;align-items:center;gap:.55rem;min-width:0;font-weight:500}.card-progresso__item-valor[data-v-f738fbcc]{display:inline-flex;align-items:center;gap:.5rem}.card-progresso__item-modo[data-v-f738fbcc]{font-size:.7rem;font-weight:500;line-height:1}.card-progresso__item-nums[data-v-f738fbcc]{font-size:.78rem;font-variant-numeric:tabular-nums;font-weight:400}.card-progresso__item-pct[data-v-f738fbcc]{font-size:.7rem;font-weight:600;padding:.15rem .45rem;border-radius:999px;font-variant-numeric:tabular-nums;white-space:nowrap;line-height:1.4}.card-progresso__trilha[data-v-f738fbcc]{width:100%;overflow:hidden;position:relative}.card-progresso__preenchimento[data-v-f738fbcc]{height:100%;transition:width .4s ease}.card-base[data-v-d1b84008]{display:flex;flex-direction:column;gap:1.25rem;padding:1.25rem;transition:background .2s ease;overflow:hidden;font-family:Geist,sans-serif;position:relative}.card-base--left[data-v-d1b84008]{text-align:left;align-items:stretch}.card-base--center[data-v-d1b84008]{text-align:center;align-items:center}.card-base--right[data-v-d1b84008]{text-align:right;align-items:flex-end}.card-base__topo[data-v-d1b84008]{position:absolute;top:.75rem;right:.75rem}.card-base__legendas[data-v-d1b84008]{display:flex;flex-direction:column;gap:.15rem}.card-base__legenda[data-v-d1b84008]{line-height:1.2;letter-spacing:-.005em}.card-base__sublegenda[data-v-d1b84008]{font-size:.78rem;font-weight:400;line-height:1.2}.card-base__titulos[data-v-d1b84008]{display:flex;flex-direction:column;gap:.25rem}.card-base__titulo[data-v-d1b84008]{font-size:1.85rem;font-weight:700;line-height:1.15;letter-spacing:-.015em}.card-base__acao[data-v-d1b84008]{display:flex}.card-base--center .card-base__acao[data-v-d1b84008]{justify-content:center}.card-base--right .card-base__acao[data-v-d1b84008]{justify-content:flex-end}.card-base__link[data-v-d1b84008]{display:inline-flex;align-items:center;gap:.35rem;background:transparent;border:none;padding:0;font-weight:500;cursor:pointer;font-family:inherit;transition:opacity .2s ease}.card-base__link[data-v-d1b84008]:hover{opacity:.7}.card-base__chevron[data-v-d1b84008]{font-size:1.1rem;line-height:1;font-weight:400;transform:translateY(-1px)}.card-base__exportar[data-v-d1b84008]{width:28px;height:28px}.card-base__footer[data-v-d1b84008]{margin-top:.25rem}.nc-actions{flex:0 0 auto;display:inline-flex;align-items:center;gap:.5rem}.nc-legendas-flex{min-width:0;flex:1 1 auto}.nc-exportar{display:inline-flex;align-items:center;justify-content:center;width:30px;height:30px;padding:0;background:transparent;border:1px solid rgba(15,23,42,.18);border-radius:8px;cursor:pointer;transition:opacity .2s ease,background .2s ease;font-family:inherit}.nc-exportar:hover{opacity:.7}.nc-exportar svg{display:block}.nc-btn{display:inline-flex;align-items:center;gap:.4rem;background:transparent;border:1px solid rgba(15,23,42,.18);border-radius:10px;padding:.5rem 1.1rem;font-size:.9rem;font-weight:500;cursor:pointer;transition:opacity .2s ease,background .2s ease;align-self:flex-start;font-family:inherit}.nc-btn:hover{opacity:.75}.nc-bolinha{width:8px;height:8px;border-radius:999px;flex:0 0 auto;display:inline-block}.nc-centro{position:absolute;top:0;right:0;bottom:0;left:0;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;pointer-events:none;padding:0 1rem}.nc-centro-titulo{font-size:1.25rem;font-weight:600;line-height:1.2;letter-spacing:-.5px}.nc-centro-desc{font-size:.6rem;line-height:1.3;max-width:80px;margin-top:.15rem}.nc-tabela{display:flex;flex-direction:column;flex:1 1 auto;min-width:0}.nc-tabela-cab{display:flex;justify-content:space-between;align-items:center;font-size:.72rem;font-weight:500;padding:0 0 .5rem;border-bottom:1px solid}.nc-tabela-linha{display:flex;justify-content:space-between;align-items:center;padding:.4rem 0;font-size:.8rem}.nc-tabela-rotulo{display:inline-flex;align-items:center;gap:.65rem;min-width:0;flex:1 1 0;overflow:hidden}.nc-tabela-rotulo>span:last-child{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.nc-tabela-valor{font-variant-numeric:tabular-nums;font-weight:500;flex-shrink:0;white-space:nowrap;padding-left:.5rem}@media (max-width: 640px){.nc-btn{padding:.4rem .85rem;font-size:.82rem}}
|