nemesischart 2.0.9 → 2.0.11
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/README.md +32 -15
- package/dist/nemesischart.js +1368 -1476
- package/dist/nemesischart.umd.cjs +1 -1
- package/dist/style.css +1 -1
- package/package.json +2 -15
|
@@ -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,u)=>{const o=t.__vccOpts||t;for(const[f,a]of u)o[f]=a;return o},Q=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:u}){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,f=e.ref(null),a=e.shallowRef(null),x={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{position:"top"}}};function b(){return{...x,...o.options}}function S(){f.value&&(a.value=new X.Chart(f.value,{type:o.type,data:o.data,options:b(),plugins:o.plugins}))}function q(){a.value&&(a.value.destroy(),a.value=null)}return e.onMounted(S),e.onBeforeUnmount(q),e.watch(()=>o.data,B=>{if(!a.value)return;a.value.data.labels=B.labels;const k=a.value.data.datasets,C=B.datasets;k.length!==C.length?a.value.data.datasets=C:C.forEach((P,D)=>Object.assign(k[D],P)),a.value.update()},{deep:!0}),e.watch(()=>o.options,()=>{a.value&&(a.value.options=b(),a.value.update())},{deep:!0}),u({chart:a}),(B,k)=>(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:f},null,512)],4))}},[["__scopeId","data-v-9828990e"]]);function ke(t){const u=t.replace("#",""),o=u.length===3?u.split("").map(P=>P+P).join(""):u,f=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(f,a,x),S=Math.min(f,a,x),q=(b+S)/2;if(b===S)return[0,0,q*100];const B=b-S,k=q>.5?B/(2-b-S):B/(b+S);let C;return b===f?C=((a-x)/B+(a<x?6:0))/6:b===a?C=((x-f)/B+2)/6:C=((f-a)/B+4)/6,[C*360,k*100,q*100]}function Be(t,u,o){t/=360,u/=100,o/=100;const f=o<.5?o*(1+u):o+u-o*u,a=2*o-f,x=B=>(B<0&&(B+=1),B>1&&(B-=1),B<1/6?a+(f-a)*6*B:B<1/2?f:B<2/3?a+(f-a)*(2/3-B)*6:a),b=u===0?o:x(t+1/3),S=u===0?o:x(t),q=u===0?o:x(t-1/3);return"#"+[b,S,q].map(B=>Math.round(B*255).toString(16).padStart(2,"0")).join("")}function re(t,u=7){if(!(t!=null&&t.startsWith("#")))return Array.from({length:u},()=>t??"#3B82F6");const[o,f]=ke(t),a=20,x=72;return Array.from({length:u},(b,S)=>{const q=u===1?.5:S/(u-1),B=a+q*(x-a),k=Math.max(50,f-Math.max(0,B-55)*.6);return Be(o,k,B)})}const Ce={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 N(t,u){if(!t)return`rgba(59,130,246,${u})`;if(t.startsWith("#")){const o=t.replace("#",""),f=o.length===3?o.split("").map(S=>S+S).join(""):o,a=parseInt(f.slice(0,2),16),x=parseInt(f.slice(2,4),16),b=parseInt(f.slice(4,6),16);return`rgba(${a},${x},${b},${u})`}if(t.startsWith("rgb")){const o=t.match(/[\d.]+/g);if(o&&o.length>=3)return`rgba(${o[0]},${o[1]},${o[2]},${u})`}return t}function U(t){const u=e.computed(()=>{const f=Ce[t.tema],a=f?{...f,bg:t.corFundo||f.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:u.value.bg,color:u.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:u,cardStyle:o,toRgba:N}}function oe(t){const u=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(f){if(f==null)return"";const a=Number(f);return Number.isNaN(a)?String(f):t.tipoValor==="percentual"?u.value.format(a/100):u.value.format(a)}return{formatador:u,formatar:o}}function ae(t,{caretFlexivel:u=!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:u?"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 f=document.createElement("div");f.className="nc-tt__caret";const a={position:"absolute",left:"50%",width:"10px",height:"10px",background:"#ffffff",transform:"translateX(-50%) rotate(45deg)",borderRadius:"2px"};u?Object.assign(f.style,a):Object.assign(f.style,a,{bottom:"-5px",borderRight:"1px solid rgba(15,23,42,.06)",borderBottom:"1px solid rgba(15,23,42,.06)"}),o.appendChild(f);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 Z(t){const u=t.canvas.parentNode;return u?(getComputedStyle(u).position==="static"&&(u.style.position="relative"),u):null}function _(t,u,o,f=4){const a=u/2;return t-a<f?a+f:t+a>o-f?o-a-f:t}function le(t,u){const o=window.getComputedStyle(t);let f="";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;f+=`${x}:${b};`}u.setAttribute("style",f)}function Ee(t,u){le(t,u);const o=t.querySelectorAll("*"),f=u.querySelectorAll("*");for(let a=0;a<o.length;a++)f[a]&&le(o[a],f[a])}function $e(t,u){const o=t.querySelectorAll("canvas"),f=u.querySelectorAll("canvas");o.forEach((a,x)=>{if(!f[x])return;const b=document.createElement("img");try{b.src=a.toDataURL("image/png")}catch{return}const S=a.getBoundingClientRect();b.setAttribute("style",`width:${S.width}px;height:${S.height}px;display:block;`),f[x].replaceWith(b)})}async function v(t,u={}){if(!t)return;const{nomeArquivo:o="componente.png",escala:f=2,corFundo:a=null}=u,x=t.getBoundingClientRect(),b=Math.ceil(x.width),S=Math.ceil(x.height),q=t.cloneNode(!0);Ee(t,q),$e(t,q),q.style.margin="0",q.style.transform="none";const B=new XMLSerializer().serializeToString(q),k=`<svg xmlns="http://www.w3.org/2000/svg" width="${b}" height="${S}"><foreignObject width="100%" height="100%"><div xmlns="http://www.w3.org/1999/xhtml" style="width:${b}px;height:${S}px;">`+B+"</div></foreignObject></svg>",P="data:image/svg+xml;base64,"+(typeof window<"u"&&window.btoa?window.btoa(unescape(encodeURIComponent(k))):""),D=new Image;await new Promise((J,d)=>{D.onload=J,D.onerror=d,D.src=P});const K=document.createElement("canvas");K.width=b*f,K.height=S*f;const I=K.getContext("2d");I.scale(f,f),a&&(I.fillStyle=a,I.fillRect(0,0,b,S)),I.drawImage(D,0,0);let Y;try{Y=K.toDataURL("image/png")}catch(J){console.error("Falha ao exportar imagem: canvas contaminado.",J);return}const W=document.createElement("a");W.download=o,W.href=Y,document.body.appendChild(W),W.click(),document.body.removeChild(W)}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"},we={key:1,class:"nc-actions inline-flex align-items-center gap-2"},ze=["innerHTML"],Ae={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:u}){const o=t,f=u,{palette:a,cardStyle:x}=U(o),{formatar:b}=oe(o),S=e.ref(null),q=ee;async function B(){await v(S.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),f("exportado")}const k=e.computed(()=>`card-linhas--${o.direcao}`),C=e.computed(()=>o.linhasReferencia?(Array.isArray(o.linhasReferencia)?o.linhasReferencia:[o.linhasReferencia]).filter(r=>r&&(typeof r=="number"||typeof r.valor=="number")).map(r=>typeof r=="number"?{valor:r,rotulo:null,cor:"#0F172A",corRotulo:"#0F172A",corTexto:"#FFFFFF",tracejado:[6,6],espessura:1}:{valor:r.valor,rotulo:r.rotulo??null,cor:r.cor||"#0F172A",corRotulo:r.corRotulo||r.cor||"#0F172A",corTexto:r.corTexto||"#FFFFFF",tracejado:r.tracejado||[6,6],espessura:r.espessura??1}):[]),P=[];let D=null;const I=[{id:"linhaReferencia",afterDatasetsDraw(l){const r=C.value;if(P.length=0,!r.length)return;const{ctx:n,chartArea:s,scales:y}=l,i=y.y;i&&r.forEach(m=>{const c=i.getPixelForValue(m.valor);if(P.push({linha:m,pos:c,chartArea:s}),n.save(),n.beginPath(),n.setLineDash(m.tracejado),n.lineWidth=m.espessura,n.strokeStyle=m.cor,c<s.top||c>s.bottom){n.restore();return}if(n.moveTo(s.left,c),n.lineTo(s.right,c),n.stroke(),n.setLineDash([]),m.rotulo){n.font="600 11px 'Inter', sans-serif";const p=8,g=5,E=n.measureText(m.rotulo).width,V=12,h=E+p*2,F=V+g*2,A=F/2;let T=s.left-h-6,w=c-F/2;T<0&&(T=s.left+6),n.fillStyle=m.corRotulo,n.beginPath(),n.roundRect?n.roundRect(T,w,h,F,A):(n.moveTo(T+A,w),n.lineTo(T+h-A,w),n.quadraticCurveTo(T+h,w,T+h,w+A),n.lineTo(T+h,w+F-A),n.quadraticCurveTo(T+h,w+F,T+h-A,w+F),n.lineTo(T+A,w+F),n.quadraticCurveTo(T,w+F,T,w+F-A),n.lineTo(T,w+A),n.quadraticCurveTo(T,w,T+A,w)),n.fill(),n.fillStyle=m.corTexto,n.textBaseline="middle",n.textAlign="center",n.fillText(m.rotulo,T+h/2,w+F/2)}n.restore()})},beforeEvent(l,r){if(!P.length){D=null;return}const n=r.event;if(!n||n.type==="mouseout"||n.x==null||n.y==null){D=null;return}const s=8;let y=null,i=1/0;for(const m of P){const c=Math.abs(n.y-m.pos),p=n.x>=m.chartArea.left&&n.x<=m.chartArea.right;c<=s&&p&&c<i&&(i=c,y=m)}D=y},afterEvent(l,r){if(!P.length)return;const n=r.event;if(!n)return;const s=Z(l);if(!s)return;let y=s.querySelector(".nc-tt-linhaRef");if(!D){y&&(y.style.opacity="0");return}const i=D;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"}),s.appendChild(y));const m=i.linha.cor||"#0F172A",c=b(i.linha.valor),p=i.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:${m};box-shadow:0 0 0 2px ${N(m,.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 g=l.canvas;y.style.opacity="1",y.style.visibility="hidden",y.style.left="0px",y.style.top="0px";const z=y.offsetWidth,E=y.offsetHeight,V=4,h=g.offsetLeft+n.x,F=g.offsetTop+i.pos,A=_(h,z,s.clientWidth,V);let T=F;const w=E+16+V;T<w&&(T=w),y.style.left=A+"px",y.style.top=T+"px",y.style.visibility="visible"}}],Y=e.computed(()=>({labels:o.data.map(l=>l.rotulo),datasets:[{data:o.data.map(l=>l.quantidade),borderColor:o.corDetalhes,borderWidth:3,borderJoinStyle:"round",borderCapStyle:"round",backgroundColor:l=>{const{chart:r}=l,{ctx:n,chartArea:s}=r;if(!s)return"transparent";const y=o.corDetalhes||"#0400FF",i="#7C7C7C",m=n.createLinearGradient(0,s.top,0,s.bottom);return m.addColorStop(.16,N(y,.2)),m.addColorStop(1,N(i,0)),m},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 W(l){const{chart:r,tooltip:n}=l,s=Z(r);if(!s)return;const y=ae(s);if(n.opacity===0||D){y.style.opacity="0";return}const i=n.title||[],m=(n.body||[]).flatMap(O=>O.lines),c=y.querySelector(".nc-tt__content"),p=o.corDetalhes||"#3B82F6";c.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:${p};box-shadow:0 0 0 2px ${N(p,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${m.join(" ")}</span></div>`;const{offsetLeft:g,offsetTop:z}=r.canvas;y.style.opacity="1",y.style.visibility="hidden",y.style.left="0px",y.style.top="0px";const E=y.offsetWidth,V=y.offsetHeight,h=4,F=g+n.caretX,A=z+n.caretY,T=_(F,E,s.clientWidth,h),w=V+16+h,$=A<w;let j;$?(y.style.transform="translateX(-50%) translateY(16px)",j=A):(y.style.transform="translate(-50%, calc(-100% - 16px))",j=A),y.style.left=T+"px",y.style.top=j+"px";const R=y.querySelector(".nc-tt__caret");if(R){const O=F-T,L=E/2,H=Math.max(-L+8,Math.min(L-8,O));R.style.left=`calc(50% + ${H}px)`,$?(R.style.bottom="",R.style.top="-5px",R.style.borderRight="",R.style.borderBottom="",R.style.borderLeft="1px solid rgba(15,23,42,.06)",R.style.borderTop="1px solid rgba(15,23,42,.06)"):(R.style.top="",R.style.bottom="-5px",R.style.borderLeft="",R.style.borderTop="",R.style.borderRight="1px solid rgba(15,23,42,.06)",R.style.borderBottom="1px solid rgba(15,23,42,.06)")}y.style.visibility="visible"}const J=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,interaction:{intersect:!1,mode:"index"},layout:{padding:{top:C.value.length?24:0,right:0,bottom:0,left:0}},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:W,callbacks:{title:l=>{var r;return((r=l[0])==null?void 0:r.label)??""},label:l=>b(l.parsed.y)}}},scales:{x:{display:!0,afterFit:l=>{l.paddingLeft=0,l.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:C.value.length?Math.max(...C.value.map(l=>l.valor)):void 0}}}));function d(){f("botaoAcao")}return(l,r)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:S,class:e.normalizeClass(["card-linhas p-4 flex",k.value]),style:e.normalizeStyle(e.unref(x))},[e.createElementVNode("div",Ve,[e.createElementVNode("div",Ne,[l.$slots.legenda||t.legenda||l.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",Te,[l.$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(l.$slots,"legenda",{},()=>[e.createTextVNode(e.toDisplayString(t.legenda),1)],!0)],4)):e.createCommentVNode("",!0),l.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-xs",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(l.$slots,"sublegenda",{},()=>[e.createTextVNode(e.toDisplayString(t.sublegenda),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),l.$slots.actions||t.botaoVisivel||t.exportar?(e.openBlock(),e.createElementBlock("div",we,[e.renderSlot(l.$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(N)(e.unref(a).text,.18)}),onClick:d},[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(N)(e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:e.unref(q)},null,12,ze)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),l.$slots.titulo||t.titulo||l.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",Ae,[l.$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(l.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(t.titulo),1)],!0)],4)):e.createCommentVNode("",!0),l.$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(l.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(t.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",Re,[e.createVNode(Q,{type:"line",data:Y.value,options:J.value,plugins:I,height:t.height},null,8,["data","options","height"])]),l.$slots.footer?(e.openBlock(),e.createElementBlock("div",Fe,[e.renderSlot(l.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-513bd6fe"]]),qe={class:"card-pizza__topo flex align-items-start justify-content-between gap-3"},Le={key:0,class:"nc-legendas-flex flex flex-column"},De={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"},Ie={class:"nc-tabela-valor"},je=["role","tabindex","onMouseenter","onFocus","onClick","onKeydown"],Oe={class:"nc-tabela-rotulo inline-flex align-items-center gap-2"},We={class:"nc-tabela-valor"},Xe={class:"card-pizza__chart-wrap flex align-items-center justify-content-center"},Ye={class:"card-pizza__chart"},Ke={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"},itensClicaveis:{type:Boolean,default:!1}},emits:["botaoAcao","exportado","itemClicado"],setup(t,{emit:u}){const o=t,f=u,{palette:a,cardStyle:x}=U(o),{formatar:b}=oe(o),S=e.ref(null);async function q(){await v(S.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),f("exportado")}const B=e.computed(()=>`card-pizza--${o.direcao}`),k=e.computed(()=>{const d=re(o.corDetalhes,o.data.length);return o.data.map((l,r)=>l.cor??d[r])}),C=e.computed(()=>({labels:o.data.map(d=>d.rotulo),datasets:[{data:o.data.map(d=>d.quantidade),backgroundColor:k.value,borderWidth:0,borderColor:"transparent",hoverOffset:6,borderRadius:0,spacing:0}]}));function P(d){const{chart:l,tooltip:r}=d,n=Z(l);if(!n)return;const s=ae(n);if(r.opacity===0){s.style.opacity="0";return}const y=r.title||[],i=r.dataPoints&&r.dataPoints[0],m=i?k.value[i.dataIndex]:"#3B82F6",c=i?b(i.parsed):"",p=s.querySelector(".nc-tt__content");p.innerHTML=`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${y.join(" ")}</div><div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${m};box-shadow:0 0 0 2px ${N(m,.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{offsetLeft:g,offsetTop:z}=l.canvas;s.style.opacity="1",s.style.visibility="hidden",s.style.left="0px",s.style.top="0px";const E=s.offsetWidth,V=s.offsetHeight,h=4,F=g+r.caretX,A=z+r.caretY,T=_(F,E,n.clientWidth,h),w=A<V+16+h;s.style.transform=w?"translate(-50%, 16px)":"translate(-50%, calc(-100% - 16px))";const $=s.querySelector(".nc-tt__caret");$&&(w?($.style.bottom="",$.style.top="-5px",$.style.borderRight="",$.style.borderBottom="",$.style.borderLeft="1px solid rgba(15,23,42,.06)",$.style.borderTop="1px solid rgba(15,23,42,.06)"):($.style.top="",$.style.bottom="-5px",$.style.borderLeft="",$.style.borderTop="",$.style.borderRight="1px solid rgba(15,23,42,.06)",$.style.borderBottom="1px solid rgba(15,23,42,.06)")),s.style.left=T+"px",s.style.top=A+"px",s.style.visibility="visible"}function D(d){const l=o.data[d];l&&f("itemClicado",{item:l,index:d,cor:k.value[d]})}function K(d,l){o.itensClicaveis&&f("itemClicado",{item:d,index:l,cor:k.value[l]})}const I=e.ref(null),Y=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,cutout:o.cutout,layout:{padding:4},onHover:(d,l,r)=>{const n=l.length?l[0].index:null;I.value=n,r.canvas.style.cursor=o.itensClicaveis&&l.length?"pointer":"default"},onClick:(d,l)=>{!o.itensClicaveis||!l.length||D(l[0].index)},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:P,callbacks:{title:d=>{var l;return((l=d[0])==null?void 0:l.label)??""},label:d=>b(d.parsed)}}}}));function W(){f("botaoAcao")}const J=ee;return(d,l)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:S,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",Le,[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",De,[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(N)(e.unref(a).text,.18)}),onClick:W},[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(N)(e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:q,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(N)(e.unref(a).muted,.25)})},[e.createElementVNode("span",null,e.toDisplayString(t.rotuloCategoria),1),e.createElementVNode("span",Ie,e.toDisplayString(t.rotuloQuantidade),1)],4)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.data,(r,n)=>(e.openBlock(),e.createElementBlock("div",{key:n,class:e.normalizeClass(["nc-tabela-linha flex align-items-center justify-content-between",{"nc-tabela-linha--clicavel":t.itensClicaveis,"nc-tabela-linha--ativa":I.value===n}]),style:e.normalizeStyle({color:e.unref(a).text,cursor:t.itensClicaveis?"pointer":"default","--nc-linha-bg":e.unref(N)(k.value[n],.05),"--nc-linha-bg-forte":e.unref(N)(k.value[n],.08)}),role:t.itensClicaveis?"button":null,tabindex:t.itensClicaveis?0:null,onMouseenter:s=>I.value=n,onMouseleave:l[0]||(l[0]=s=>I.value=null),onFocus:s=>I.value=n,onBlur:l[1]||(l[1]=s=>I.value=null),onClick:s=>K(r,n),onKeydown:[e.withKeys(e.withModifiers(s=>K(r,n),["prevent"]),["enter"]),e.withKeys(e.withModifiers(s=>K(r,n),["prevent"]),["space"])]},[e.createElementVNode("span",Oe,[e.createElementVNode("span",{class:"nc-bolinha",style:e.normalizeStyle({background:k.value[n]})},null,4),e.createElementVNode("span",null,e.toDisplayString(r.rotulo),1)]),e.createElementVNode("span",We,e.toDisplayString(e.unref(b)(r.quantidade)),1)],46,je))),128))]),e.createElementVNode("div",Xe,[e.createElementVNode("div",Ye,[e.createVNode(Q,{type:"doughnut",data:C.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",Ke,[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-eda43720"]]),Ge={class:"card-barra__header flex flex-column"},Qe={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"},_e=["innerHTML"],ve={key:0,class:"card-barra__titulos mt-3 mb-2 flex flex-column"},et={class:"card-barra__chart flex-1"},tt={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:u}){e.useCssVars(i=>({c9bf3d56:C.value}));const o=t,f=u,{palette:a,cardStyle:x}=U(o),{formatar:b}=oe(o),S=e.ref(null),q=ee;async function B(){await v(S.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),f("exportado")}const k=e.computed(()=>`card-barra--${o.direcao}`),C=e.computed(()=>typeof o.height=="number"?`${o.height}px`:o.height),P=e.computed(()=>o.orientacao==="horizontal"),D=e.computed(()=>Array.isArray(o.series)&&o.series.length>0?o.series.map((i,m)=>({nome:i.nome??`Série ${m+1}`,cor:i.cor||o.cores[m%o.cores.length],dados:Array.isArray(i.dados)?i.dados:[]})):[{nome:o.legenda||"Valores",cor:o.corDetalhes,dados:o.data}]),K=e.computed(()=>{const i=D.value[0];return i?i.dados.map(m=>m.rotulo):[]}),I=e.computed(()=>{const i=D.value,m=i.length-1,c=typeof o.larguraBarra=="number"?o.larguraBarra:Number(o.larguraBarra)||.6,p=o.raioBarra,g=P.value;function z(E){if(!o.empilhado||i.length===1)return p;const V=E===0,h=E===m;return g?{topLeft:V?p:0,bottomLeft:V?p:0,topRight:h?p:0,bottomRight:h?p:0}:{bottomLeft:V?p:0,bottomRight:V?p:0,topLeft:h?p:0,topRight:h?p:0}}return{labels:K.value,datasets:i.map((E,V)=>({label:E.nome,data:E.dados.map(h=>h.quantidade),previstos:E.dados.map(h=>h.previsto!=null?h.previsto:null),backgroundColor:N(E.cor,.72),hoverBackgroundColor:o.corHover||E.cor,borderWidth:0,borderRadius:z(V),borderSkipped:!1,categoryPercentage:1,barPercentage:c}))}});function Y(i,m){m?Object.assign(i.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(i.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 W=null;function J(i){var he,xe;const{chart:m,tooltip:c}=i,p=Z(m);if(!p)return;const g=ae(p,{caretFlexivel:!0});if(c.opacity===0||W){g.style.opacity="0";return}const z=c.title||[],E=c.dataPoints||[],V=g.querySelector(".nc-tt__content"),h=E.map(te=>{var Se;const ne=((Se=D.value[te.datasetIndex])==null?void 0:Se.cor)||o.corDetalhes,jt=b(P.value?te.parsed.x:te.parsed.y),Ot=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 ${N(ne,.15)};flex:0 0 auto;"></span>`+Ot+`<span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;margin-left:auto;">${jt}</span></div>`}).join(""),F=(he=E[0])==null?void 0:he.dataIndex;let A=null;if(F!=null)for(const te of m.data.datasets){const ne=(xe=te.previstos)==null?void 0:xe[F];if(ne!=null){A=ne;break}}const T=A!=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(A)}</span></div>`:"";V.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>`+h+T;const{offsetLeft:w,offsetTop:$}=m.canvas;g.style.opacity="1",g.style.visibility="hidden",g.style.left="0px",g.style.top="0px";const j=g.offsetWidth,R=g.offsetHeight,O=4,L=w+c.caretX,H=$+c.caretY,ue=_(L,j,p.clientWidth,O),Mt=j/2,pe=14,ge=H-pe-R,ye=ge<O,Ht=ye?H+pe:ge,be=g.querySelector(".nc-tt__caret");Y(be,ye);const Pt=L-(ue-Mt),It=Math.max(10,Math.min(j-10,Pt));be.style.left=It+"px",g.style.left=ue+"px",g.style.top=Ht+"px",g.style.visibility="visible"}const d=e.computed(()=>{const i=P.value,m={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},c={display:!1,grid:{display:!1},beginAtZero:!0,stacked:o.empilhado,suggestedMax:r.value.length?Math.max(...r.value.map(p=>p.valor)):void 0};return{responsive:!0,maintainAspectRatio:!1,indexAxis:i?"y":"x",interaction:{intersect:!1,mode:"index",axis:i?"y":"x"},layout:{padding:{top:r.value.length&&!i?24:12,right:i?12:0,bottom:0,left:r.value.length&&i?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:J,callbacks:{title:p=>{var g;return((g=p[0])==null?void 0:g.label)??""},label:p=>b(i?p.parsed.x:p.parsed.y)}}},scales:{x:i?c:m,y:i?m:c}}});function l(){f("botaoAcao")}const r=e.computed(()=>o.linhasReferencia?(Array.isArray(o.linhasReferencia)?o.linhasReferencia:[o.linhasReferencia]).filter(m=>m&&(typeof m=="number"||typeof m.valor=="number")).map(m=>typeof m=="number"?{valor:m,rotulo:null,cor:"#0F172A",corRotulo:"#0F172A",corTexto:"#FFFFFF",tracejado:[6,6],espessura:1}:{valor:m.valor,rotulo:m.rotulo??null,cor:m.cor||"#0F172A",corRotulo:m.corRotulo||m.cor||"#0F172A",corTexto:m.corTexto||"#FFFFFF",tracejado:m.tracejado||[6,6],espessura:m.espessura??1}):[]),n=[],s={id:"linhaReferencia",afterDatasetsDraw(i){const m=r.value;if(n.length=0,!m.length)return;const{ctx:c,chartArea:p,scales:g}=i,z=P.value,E=z?g.x:g.y;E&&m.forEach(V=>{const h=E.getPixelForValue(V.valor);if(n.push({linha:V,pos:h,horizontal:z,chartArea:p}),c.save(),c.beginPath(),c.setLineDash(V.tracejado),c.lineWidth=V.espessura,c.strokeStyle=V.cor,z){if(h<p.left||h>p.right){c.restore();return}c.moveTo(h,p.top),c.lineTo(h,p.bottom)}else{if(h<p.top||h>p.bottom){c.restore();return}c.moveTo(p.left,h),c.lineTo(p.right,h)}if(c.stroke(),c.setLineDash([]),V.rotulo){c.font="600 11px 'Inter', sans-serif";const F=8,A=5,w=c.measureText(V.rotulo).width,$=12,j=w+F*2,R=$+A*2,O=R/2;let L,H;z?(L=h-j/2,H=p.top-R-6,H<0&&(H=p.top+6)):(L=p.left-j-6,H=h-R/2,L<0&&(L=p.left+6)),c.fillStyle=V.corRotulo,c.beginPath(),c.roundRect?c.roundRect(L,H,j,R,O):(c.moveTo(L+O,H),c.lineTo(L+j-O,H),c.quadraticCurveTo(L+j,H,L+j,H+O),c.lineTo(L+j,H+R-O),c.quadraticCurveTo(L+j,H+R,L+j-O,H+R),c.lineTo(L+O,H+R),c.quadraticCurveTo(L,H+R,L,H+R-O),c.lineTo(L,H+O),c.quadraticCurveTo(L,H,L+O,H)),c.fill(),c.fillStyle=V.corTexto,c.textBaseline="middle",c.textAlign="center",c.fillText(V.rotulo,L+j/2,H+R/2)}c.restore()})},beforeEvent(i,m){if(!n.length){W=null;return}const c=m.event;if(!c||c.type==="mouseout"||c.x==null||c.y==null){W=null;return}const p=8;let g=null,z=1/0;for(const E of n){const V=E.horizontal?Math.abs(c.x-E.pos):Math.abs(c.y-E.pos),h=E.horizontal?c.y>=E.chartArea.top&&c.y<=E.chartArea.bottom:c.x>=E.chartArea.left&&c.x<=E.chartArea.right;V<=p&&h&&V<z&&(z=V,g=E)}W=g},afterEvent(i,m){if(!n.length)return;const c=m.event;if(!c)return;const p=Z(i);if(!p)return;let g=p.querySelector(".nc-tt-linhaRef");if(!W){g&&(g.style.opacity="0");return}const z=W;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",V=b(z.linha.valor),h=z.linha.rotulo;g.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:${E};box-shadow:0 0 0 2px ${N(E,.15)};flex:0 0 auto;"></span><span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;">${V}</span></div>`;const F=i.canvas;g.style.opacity="1",g.style.visibility="hidden",g.style.left="0px",g.style.top="0px";const A=g.offsetWidth,T=g.offsetHeight,w=4;let $,j;z.horizontal?($=F.offsetLeft+z.pos,j=F.offsetTop+c.y):($=F.offsetLeft+c.x,j=F.offsetTop+z.pos);const R=_($,A,p.clientWidth,w);let O=j;const L=T+16+w;O<L&&(O=L),g.style.left=R+"px",g.style.top=O+"px",g.style.visibility="visible"}},y=e.computed(()=>r.value.length?[s]:[]);return(i,m)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:S,class:e.normalizeClass(["card-barra p-4 flex",k.value]),style:e.normalizeStyle(e.unref(x))},[e.createElementVNode("div",Ge,[e.createElementVNode("div",Qe,[i.$slots.legenda||t.legenda||i.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",Ue,[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:.85})},[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",Ze,[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(N)(e.unref(a).text,.18)}),onClick:l},[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(N)(e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:e.unref(q)},null,12,_e)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),i.$slots.titulo||t.titulo||i.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",ve,[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",et,[e.createVNode(Q,{type:"bar",data:I.value,options:d.value,plugins:y.value,height:"100%"},null,8,["data","options","plugins"])]),i.$slots.footer?(e.openBlock(),e.createElementBlock("div",tt,[e.renderSlot(i.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-474043e8"]]),ot={class:"card-polar__topo flex align-items-start justify-content-between gap-3"},at={key:0,class:"nc-legendas-flex flex flex-column"},nt={key:1,class:"nc-actions inline-flex align-items-center gap-2"},rt=["innerHTML"],lt={class:"card-polar__corpo flex align-items-center"},st={class:"nc-tabela flex flex-column"},it={class:"nc-tabela-valor"},ct=["role","tabindex","onMouseenter","onFocus","onClick","onKeydown"],dt={class:"nc-tabela-rotulo inline-flex align-items-center gap-2"},ft={class:"nc-tabela-valor"},mt={class:"card-polar__chart-wrap flex align-items-center justify-content-center"},ut={class:"card-polar__chart"},pt={key:0,class:"card-polar__centro-bottom"},gt={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"},itensClicaveis:{type:Boolean,default:!1}},emits:["botaoAcao","exportado","itemClicado"],setup(t,{emit:u}){const o=t,f=u,{palette:a,cardStyle:x}=U(o),{formatar:b}=oe(o),S=e.ref(null),q=ee;async function B(){await v(S.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),f("exportado")}const k=e.computed(()=>`card-polar--${o.direcao}`),C=e.computed(()=>{const d=re(o.corDetalhes,o.data.length);return o.data.map((l,r)=>l.cor??d[r])}),P=e.computed(()=>({labels:o.data.map(d=>d.rotulo),datasets:[{data:o.data.map(d=>d.quantidade),backgroundColor:C.value,borderColor:C.value,borderWidth:0,hoverOffset:6}]}));function D(d){const{chart:l,tooltip:r}=d,n=Z(l);if(!n)return;const s=ae(n);if(r.opacity===0){s.style.opacity="0";return}const y=r.title||[],i=r.dataPoints&&r.dataPoints[0],m=i?C.value[i.dataIndex]:"#3B82F6",c=i?b(i.parsed.r??i.parsed):"",p=s.querySelector(".nc-tt__content");p.innerHTML=`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${y.join(" ")}</div><div style="display:flex;align-items:center;gap:6px;"><span style="width:6px;height:6px;border-radius:999px;background:${m};box-shadow:0 0 0 2px ${N(m,.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{offsetLeft:g,offsetTop:z}=l.canvas;s.style.opacity="1",s.style.visibility="hidden",s.style.left="0px",s.style.top="0px";const E=s.offsetWidth,V=s.offsetHeight,h=4,F=g+r.caretX,A=z+r.caretY,T=_(F,E,n.clientWidth,h),w=A<V+16+h;s.style.transform=w?"translate(-50%, 16px)":"translate(-50%, calc(-100% - 16px))";const $=s.querySelector(".nc-tt__caret");$&&(w?($.style.bottom="",$.style.top="-5px",$.style.borderRight="",$.style.borderBottom="",$.style.borderLeft="1px solid rgba(15,23,42,.06)",$.style.borderTop="1px solid rgba(15,23,42,.06)"):($.style.top="",$.style.bottom="-5px",$.style.borderLeft="",$.style.borderTop="",$.style.borderRight="1px solid rgba(15,23,42,.06)",$.style.borderBottom="1px solid rgba(15,23,42,.06)")),s.style.left=T+"px",s.style.top=A+"px",s.style.visibility="visible"}function K(d){const l=o.data[d];l&&f("itemClicado",{item:l,index:d,cor:C.value[d]})}function I(d,l){o.itensClicaveis&&f("itemClicado",{item:d,index:l,cor:C.value[l]})}const Y=e.ref(null),W=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,layout:{padding:4},onHover:(d,l,r)=>{const n=l.length?l[0].index:null;Y.value=n,r.canvas.style.cursor=o.itensClicaveis&&l.length?"pointer":"default"},onClick:(d,l)=>{!o.itensClicaveis||!l.length||K(l[0].index)},scales:{r:{beginAtZero:!0,ticks:{display:!1,backdropColor:"transparent"},grid:{display:o.mostrarLinhasGrade,color:N(a.value.muted,.18)},angleLines:{display:o.mostrarLinhasGrade,color:N(a.value.muted,.18)},pointLabels:{display:!1}}},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:D,callbacks:{title:d=>{var l;return((l=d[0])==null?void 0:l.label)??""},label:d=>{var l;return b(((l=d.parsed)==null?void 0:l.r)??d.parsed)}}}}}));function J(){f("botaoAcao")}return(d,l)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:S,class:e.normalizeClass(["card-polar p-4 flex flex-column",k.value]),style:e.normalizeStyle(e.unref(x))},[e.createElementVNode("div",ot,[d.$slots.legenda||t.legenda||d.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",at,[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",nt,[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(N)(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(N)(e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:e.unref(q)},null,12,rt)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",lt,[e.createElementVNode("div",st,[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(N)(e.unref(a).muted,.25)})},[e.createElementVNode("span",null,e.toDisplayString(t.rotuloCategoria),1),e.createElementVNode("span",it,e.toDisplayString(t.rotuloQuantidade),1)],4)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.data,(r,n)=>(e.openBlock(),e.createElementBlock("div",{key:n,class:e.normalizeClass(["nc-tabela-linha flex align-items-center justify-content-between",{"nc-tabela-linha--clicavel":t.itensClicaveis,"nc-tabela-linha--ativa":Y.value===n}]),style:e.normalizeStyle({color:e.unref(a).text,cursor:t.itensClicaveis?"pointer":"default","--nc-linha-bg":e.unref(N)(C.value[n],.05),"--nc-linha-bg-forte":e.unref(N)(C.value[n],.08)}),role:t.itensClicaveis?"button":null,tabindex:t.itensClicaveis?0:null,onMouseenter:s=>Y.value=n,onMouseleave:l[0]||(l[0]=s=>Y.value=null),onFocus:s=>Y.value=n,onBlur:l[1]||(l[1]=s=>Y.value=null),onClick:s=>I(r,n),onKeydown:[e.withKeys(e.withModifiers(s=>I(r,n),["prevent"]),["enter"]),e.withKeys(e.withModifiers(s=>I(r,n),["prevent"]),["space"])]},[e.createElementVNode("span",dt,[e.createElementVNode("span",{class:"nc-bolinha",style:e.normalizeStyle({background:C.value[n]})},null,4),e.createElementVNode("span",null,e.toDisplayString(r.rotulo),1)]),e.createElementVNode("span",ft,e.toDisplayString(e.unref(b)(r.quantidade)),1)],46,ct))),128))]),e.createElementVNode("div",mt,[e.createElementVNode("div",ut,[e.createVNode(Q,{type:"polarArea",data:P.value,options:W.value,height:t.height},null,8,["data","options","height"]),d.$slots.titulo||t.titulo||d.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",pt,[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",gt,[e.renderSlot(d.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-c384afa9"]]),yt={class:"card-progresso__topo flex align-items-start justify-content-between gap-3"},bt={key:0,class:"nc-legendas-flex flex flex-column"},ht={key:1,class:"nc-actions inline-flex align-items-center gap-2"},xt=["innerHTML"],St={key:0,class:"card-progresso__titulos mt-3 mb-2 flex flex-column"},kt={class:"card-progresso__corpo flex align-items-center flex-wrap"},Bt={key:0,class:"card-progresso__chart-wrap flex align-items-center justify-content-center"},Ct={class:"card-progresso__chart"},Et={class:"nc-centro flex flex-column align-items-center justify-content-center"},$t={class:"card-progresso__lista flex flex-column"},Vt={class:"card-progresso__item-cab flex align-items-center justify-content-between"},Nt={key:0,class:"card-progresso__item-valor inline-flex align-items-center gap-2"},Tt={key:0},wt={key:1,class:"card-progresso__footer mt-3"},fe=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:u}){const o=t,f=u,{palette:a,cardStyle:x}=U(o),{formatar:b}=oe(o),S=e.ref(null),q=ee;async function B(){await v(S.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),f("exportado")}const k=e.computed(()=>`card-progresso--${o.direcao}`),C=e.computed(()=>{const r=re(o.corDetalhes,o.data.length);return o.data.map((n,s)=>{const y=Number(n.meta??o.metaPadrao)||0,i=Number(n.quantidade)||0,m=n.cor??r[s],c=n.modo==="reducao";let p;if(c){const g=Number(n.valor_referencia)||0,z=g-y;p=z>0?Math.max(0,Math.min(100,(g-i)/z*100)):0}else p=y>0?Math.max(0,Math.min(100,i/y*100)):0;return{rotulo:n.rotulo,quantidade:i,meta:y,valorReferencia:n.valor_referencia??null,cor:m,percentual:p,reducao:c}})}),P=e.computed(()=>typeof o.alturaBarra=="number"?`${o.alturaBarra}px`:o.alturaBarra),D=e.computed(()=>typeof o.raioBarra=="number"?`${o.raioBarra}px`:o.raioBarra);e.computed(()=>C.value.reduce((r,n)=>r+n.quantidade,0)),e.computed(()=>C.value.reduce((r,n)=>r+n.meta,0));const K=e.computed(()=>C.value.length?C.value.reduce((r,n)=>r+n.percentual,0)/C.value.length:0),I=e.computed(()=>C.value.every(r=>r.reducao)),Y=e.computed(()=>{const r=Math.min(K.value,100),n=Math.max(0,100-r),s=I.value?o.corExcesso:o.corDetalhes;return{labels:["Progresso","Restante"],datasets:[{data:[r,n],backgroundColor:[s,N(a.value.muted,.15)],borderWidth:0,borderColor:"transparent",hoverOffset:0,spacing:0}]}}),W=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,cutout:o.cutout,rotation:-90,circumference:360,layout:{padding:4},plugins:{legend:{display:!1},tooltip:{enabled:!1}}}));function J(r){const n=S.value;if(!n)return;getComputedStyle(n).position==="static"&&(n.style.position="relative");const s=ae(n);s.style.whiteSpace="normal";const y=s.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>',s.style.opacity="1",s.style.visibility="hidden",s.style.left="0px",s.style.top="0px",s.offsetWidth;const i=r.currentTarget.getBoundingClientRect(),m=n.getBoundingClientRect(),c=i.left-m.left+i.width/2,p=i.top-m.top;s.style.transform="translate(-50%, calc(-100% - 8px))";const g=s.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)"}),s.style.left=c+"px",s.style.top=p+"px",s.style.visibility="visible"}function d(){var n;const r=(n=S.value)==null?void 0:n.querySelector(".nc-tt");r&&(r.style.opacity="0")}function l(){f("botaoAcao")}return(r,n)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:S,class:e.normalizeClass(["card-progresso p-4 flex flex-column",k.value]),style:e.normalizeStyle(e.unref(x))},[e.createElementVNode("div",yt,[r.$slots.legenda||t.legenda||r.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",bt,[r.$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(r.$slots,"legenda",{},()=>[e.createTextVNode(e.toDisplayString(t.legenda),1)],!0)],4)):e.createCommentVNode("",!0),r.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-xs",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(r.$slots,"sublegenda",{},()=>[e.createTextVNode(e.toDisplayString(t.sublegenda),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),r.$slots.actions||t.botaoVisivel||t.exportar?(e.openBlock(),e.createElementBlock("div",ht,[e.renderSlot(r.$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(N)(e.unref(a).text,.18)}),onClick:l},[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(N)(e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:B,innerHTML:e.unref(q)},null,12,xt)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),r.$slots.titulo||t.titulo||r.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",St,[r.$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(r.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(t.titulo),1)],!0)],4)):e.createCommentVNode("",!0),r.$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(r.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(t.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),e.createElementVNode("div",kt,[t.formato==="circular"?(e.openBlock(),e.createElementBlock("div",Bt,[e.createElementVNode("div",Ct,[e.createVNode(Q,{type:"doughnut",data:Y.value,options:W.value,height:t.height},null,8,["data","options","height"]),e.createElementVNode("div",Et,[e.createElementVNode("div",{class:"nc-centro-titulo",style:e.normalizeStyle({color:I.value?o.corExcesso:e.unref(a).text})},e.toDisplayString(Math.round(K.value))+"% ",5)])])])):e.createCommentVNode("",!0),e.createElementVNode("div",$t,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(C.value,(s,y)=>(e.openBlock(),e.createElementBlock("div",{key:y,class:"card-progresso__item flex flex-column"},[e.createElementVNode("div",Vt,[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:s.cor})},null,4),e.createElementVNode("span",null,e.toDisplayString(s.rotulo),1),s.reducao?(e.openBlock(),e.createElementBlock("span",{key:0,class:"card-progresso__item-modo",style:e.normalizeStyle({color:e.unref(a).muted}),onMouseenter:J,onMouseleave:d},"↓",36)):e.createCommentVNode("",!0)],4),t.mostrarValor||t.mostrarPercentual?(e.openBlock(),e.createElementBlock("span",Nt,[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)(s.quantidade)),1),s.meta?(e.openBlock(),e.createElementBlock("span",Tt," / "+e.toDisplayString(e.unref(b)(s.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(N)(s.cor,.12),color:s.cor})},e.toDisplayString(Math.round(s.percentual))+"% ",5)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",{class:"card-progresso__trilha w-full",style:e.normalizeStyle({height:P.value,borderRadius:D.value,background:s.reducao?e.unref(N)(o.corExcesso,.18):e.unref(N)(e.unref(a).muted,.15)})},[e.createElementVNode("div",{class:"card-progresso__preenchimento",style:e.normalizeStyle({width:s.percentual+"%",background:s.cor,borderRadius:D.value})},null,4)],4)]))),128))])]),r.$slots.footer?(e.openBlock(),e.createElementBlock("div",wt,[e.renderSlot(r.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-f738fbcc"]]),zt={key:0,class:"card-base__topo"},At=["innerHTML"],Rt={class:"card-base__legendas flex flex-column"},Ft={key:1,class:"card-base__titulos flex flex-column"},qt={key:2,class:"card-base__acao flex"},Lt={key:3,class:"card-base__footer"},me=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:u}){const o=t,f=u,{palette:a,cardStyle:x}=U(o),b=e.ref(null),S=ee;function q(){f("botaoAcao")}async function B(){await v(b.value,{nomeArquivo:o.nomeArquivoExport,corFundo:a.value.bg!=="transparent"?a.value.bg:null}),f("exportado")}return(k,C)=>(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",zt,[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(N)(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(S)},null,12,At)])):e.createCommentVNode("",!0),e.createElementVNode("div",Rt,[k.$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(k.$slots,"legenda",{},()=>[e.createTextVNode(e.toDisplayString(t.legenda),1)],!0)],4)):e.createCommentVNode("",!0),k.$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(k.$slots,"sublegenda",{},()=>[e.createTextVNode(e.toDisplayString(t.sublegenda),1)],!0)],4)):e.createCommentVNode("",!0)]),k.$slots.titulo||t.titulo||k.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",Ft,[k.$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(k.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(t.titulo),1)],!0)],4)):e.createCommentVNode("",!0),k.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",{key:1,class:"text-sm",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(k.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(t.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),k.$slots.acao||t.botaoVisivel?(e.openBlock(),e.createElementBlock("div",qt,[e.renderSlot(k.$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:q},[e.createElementVNode("span",null,e.toDisplayString(t.textoBotao),1),C[0]||(C[0]=e.createElementVNode("span",{class:"card-base__chevron","aria-hidden":"true"},"›",-1))],4)):e.createCommentVNode("",!0)],!0)])):e.createCommentVNode("",!0),k.$slots.footer?(e.openBlock(),e.createElementBlock("div",Lt,[e.renderSlot(k.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},[["__scopeId","data-v-d1b84008"]]),Dt={install(t){t.component("ChartBase",Q),t.component("CardBase",me),t.component("CardLinhas",se),t.component("CardPizza",ie),t.component("CardBarra",ce),t.component("CardPolar",de),t.component("CardProgresso",fe)}};M.CardBarra=ce,M.CardBase=me,M.CardLinhas=se,M.CardPizza=ie,M.CardPolar=de,M.CardProgresso=fe,M.ChartBase=Q,M.ICONE_EXPORTAR_SVG=ee,M.clampHorizontal=_,M.criarTooltipEl=ae,M.default=Dt,M.exportarElementoComoImagem=v,M.gerarPaleta=re,M.prepararTooltipParent=Z,M.toRgba=N,M.useFormatadorValor=oe,M.useTema=U,Object.defineProperties(M,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
1
|
+
(function(B,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):(B=typeof globalThis<"u"?globalThis:B||self,e(B.NemesisChart={},B.Vue,B.Chart))})(this,function(B,e,T){"use strict";const F=(t,l)=>{const o=t.__vccOpts||t;for(const[r,a]of l)o[r]=a;return o},M=F({__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:l}){T.Chart.register(T.Title,T.Tooltip,T.Legend,T.Filler,T.LineController,T.LineElement,T.PointElement,T.BarController,T.BarElement,T.PieController,T.PolarAreaController,T.ArcElement,T.CategoryScale,T.LinearScale,T.RadialLinearScale);const o=t,r=e.ref(null),a=e.shallowRef(null),p={responsive:!0,maintainAspectRatio:!1,plugins:{legend:{position:"top"}}};function d(){return{...p,...o.options}}function m(){r.value&&(a.value=new T.Chart(r.value,{type:o.type,data:o.data,options:d(),plugins:o.plugins}))}function k(){a.value&&(a.value.destroy(),a.value=null)}return e.onMounted(m),e.onBeforeUnmount(k),e.watch(()=>o.data,s=>{if(!a.value)return;a.value.data.labels=s.labels;const u=a.value.data.datasets,f=s.datasets;u.length!==f.length?a.value.data.datasets=f:f.forEach((g,b)=>Object.assign(u[b],g)),a.value.update()},{deep:!0}),e.watch(()=>o.options,()=>{a.value&&(a.value.options=d(),a.value.update())},{deep:!0}),e.watch(()=>o.type,()=>{k(),m()}),l({chart:a}),(s,u)=>(e.openBlock(),e.createElementBlock("div",{class:"nc-chart-wrapper",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:r},null,512)],4))}},[["__scopeId","data-v-cafc7888"]]);function qe(t){const l=t.replace("#",""),o=l.length===3?l.split("").map(g=>g+g).join(""):l,r=parseInt(o.slice(0,2),16)/255,a=parseInt(o.slice(2,4),16)/255,p=parseInt(o.slice(4,6),16)/255,d=Math.max(r,a,p),m=Math.min(r,a,p),k=(d+m)/2;if(d===m)return[0,0,k*100];const s=d-m,u=k>.5?s/(2-d-m):s/(d+m);let f;return d===r?f=((a-p)/s+(a<p?6:0))/6:d===a?f=((p-r)/s+2)/6:f=((r-a)/s+4)/6,[f*360,u*100,k*100]}function De(t,l,o){t/=360,l/=100,o/=100;const r=o<.5?o*(1+l):o+l-o*l,a=2*o-r,p=s=>(s<0&&(s+=1),s>1&&(s-=1),s<1/6?a+(r-a)*6*s:s<1/2?r:s<2/3?a+(r-a)*(2/3-s)*6:a),d=l===0?o:p(t+1/3),m=l===0?o:p(t),k=l===0?o:p(t-1/3);return"#"+[d,m,k].map(s=>Math.round(s*255).toString(16).padStart(2,"0")).join("")}function Y(t,l=7){if(!(t!=null&&t.startsWith("#")))return Array.from({length:l},()=>t??"#3B82F6");const[o,r]=qe(t),a=20,p=72;return Array.from({length:l},(d,m)=>{const k=l===1?.5:m/(l-1),s=a+k*(p-a),u=Math.max(50,r-Math.max(0,s-55)*.6);return De(o,u,s)})}const Fe={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 w(t,l){if(!t)return`rgba(59,130,246,${l})`;if(t.startsWith("#")){const o=t.replace("#",""),r=o.length===3?o.split("").map(m=>m+m).join(""):o,a=parseInt(r.slice(0,2),16),p=parseInt(r.slice(2,4),16),d=parseInt(r.slice(4,6),16);return`rgba(${a},${p},${d},${l})`}if(t.startsWith("rgb")){const o=t.match(/[\d.]+/g);if(o&&o.length>=3)return`rgba(${o[0]},${o[1]},${o[2]},${l})`}return t}function P(t){const l=e.computed(()=>{const r=Fe[t.tema],a=r?{...r,bg:t.corFundo||r.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:l.value.bg,color:l.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:l,cardStyle:o,toRgba:w}}function de(t,l){const o=window.getComputedStyle(t);let r="";for(let a=0;a<o.length;a++){const p=o[a];let d=o.getPropertyValue(p);if(d&&d.indexOf("url(")!==-1&&!/url\(["']?data:/.test(d))if(p==="background-image"||p==="background"||p==="mask-image"||p==="border-image"||p==="border-image-source")d="none";else continue;r+=`${p}:${d};`}l.setAttribute("style",r)}function Le(t,l){de(t,l);const o=t.querySelectorAll("*"),r=l.querySelectorAll("*");for(let a=0;a<o.length;a++)r[a]&&de(o[a],r[a])}function Ie(t,l){const o=t.querySelectorAll("canvas"),r=l.querySelectorAll("canvas");o.forEach((a,p)=>{if(!r[p])return;const d=document.createElement("img");try{d.src=a.toDataURL("image/png")}catch{return}const m=a.getBoundingClientRect();d.setAttribute("style",`width:${m.width}px;height:${m.height}px;display:block;`),r[p].replaceWith(d)})}async function ue(t,l={}){if(!t)return;const{nomeArquivo:o="componente.png",escala:r=2,corFundo:a=null}=l,p=t.getBoundingClientRect(),d=Math.ceil(p.width),m=Math.ceil(p.height),k=t.cloneNode(!0);Le(t,k),Ie(t,k),k.style.margin="0",k.style.transform="none";const s=new XMLSerializer().serializeToString(k),u=`<svg xmlns="http://www.w3.org/2000/svg" width="${d}" height="${m}"><foreignObject width="100%" height="100%"><div xmlns="http://www.w3.org/1999/xhtml" style="width:${d}px;height:${m}px;">`+s+"</div></foreignObject></svg>",g="data:image/svg+xml;base64,"+(typeof window<"u"&&window.btoa?window.btoa(unescape(encodeURIComponent(u))):""),b=new Image;await new Promise((i,x)=>{b.onload=i,b.onerror=x,b.src=g});const h=document.createElement("canvas");h.width=d*r,h.height=m*r;const S=h.getContext("2d");S.scale(r,r),a&&(S.fillStyle=a,S.fillRect(0,0,d,m)),S.drawImage(b,0,0);let A;try{A=h.toDataURL("image/png")}catch(i){console.error("Falha ao exportar imagem: canvas contaminado.",i);return}const n=document.createElement("a");n.download=o,n.href=A,document.body.appendChild(n),n.click(),document.body.removeChild(n)}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>';function O(t,l,o){const r=e.ref(null);async function a(){await ue(r.value,{nomeArquivo:t.nomeArquivoExport,corFundo:l.value.bg!=="transparent"?l.value.bg:null}),o("exportado")}return{cardRef:r,onExportar:a,iconeExportar:ee}}const Me={class:"nc-topo nc-flex nc-align-items-start nc-justify-content-between nc-gap-3"},Pe={key:0,class:"nc-legendas-flex nc-flex nc-flex-column"},Oe={key:1,class:"nc-actions nc-inline-flex nc-align-items-center nc-gap-2"},He=["innerHTML"],U=F({__name:"CardCabecalho",props:{legenda:{type:String,default:null},sublegenda:{type:String,default:null},palette:{type:Object,required:!0},textoBotao:{type:String,default:"Ver mais"},botaoVisivel:{type:Boolean,default:!1},exportar:{type:Boolean,default:!1},opacidadeLegenda:{type:[Number,String],default:.95}},emits:["botaoAcao","exportar"],setup(t,{emit:l}){const o=l,r=ee;return(a,p)=>(e.openBlock(),e.createElementBlock("div",Me,[a.$slots.legenda||t.legenda||a.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",Pe,[a.$slots.legenda||t.legenda?(e.openBlock(),e.createElementBlock("div",{key:0,class:"nc-text-xs nc-font-medium",style:e.normalizeStyle({color:t.palette.text,opacity:t.opacidadeLegenda})},[e.renderSlot(a.$slots,"legenda",{},()=>[e.createTextVNode(e.toDisplayString(t.legenda),1)],!0)],4)):e.createCommentVNode("",!0),a.$slots.sublegenda||t.sublegenda?(e.openBlock(),e.createElementBlock("div",{key:1,class:"nc-text-xs",style:e.normalizeStyle({color:t.palette.muted})},[e.renderSlot(a.$slots,"sublegenda",{},()=>[e.createTextVNode(e.toDisplayString(t.sublegenda),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),a.$slots.actions||t.botaoVisivel||t.exportar?(e.openBlock(),e.createElementBlock("div",Oe,[e.renderSlot(a.$slots,"actions",{},()=>[t.botaoVisivel?(e.openBlock(),e.createElementBlock("button",{key:0,class:"nc-btn nc-inline-flex nc-align-items-center",style:e.normalizeStyle({color:t.palette.text,borderColor:e.unref(w)(t.palette.text,.18)}),onClick:p[0]||(p[0]=d=>o("botaoAcao"))},[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 nc-inline-flex nc-align-items-center nc-justify-content-center",style:e.normalizeStyle({color:t.palette.muted,borderColor:e.unref(w)(t.palette.text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:p[1]||(p[1]=d=>o("exportar")),innerHTML:e.unref(r)},null,12,He)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]))}},[["__scopeId","data-v-35f0d105"]]),je={class:"nc-titulos nc-flex nc-flex-column"},te={__name:"CardTitulos",props:{titulo:{type:String,default:null},descricao:{type:String,default:null},palette:{type:Object,required:!0}},setup(t){return(l,o)=>(e.openBlock(),e.createElementBlock("div",je,[l.$slots.titulo||t.titulo?(e.openBlock(),e.createElementBlock("div",{key:0,class:"nc-m-0 nc-text-3xl nc-font-semibold",style:e.normalizeStyle({color:t.palette.text,lineHeight:"33px",letterSpacing:"-1px"})},[e.renderSlot(l.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(t.titulo),1)])],4)):e.createCommentVNode("",!0),l.$slots.descricao||t.descricao?(e.openBlock(),e.createElementBlock("div",{key:1,class:"nc-text-sm nc-mt-1",style:e.normalizeStyle({color:t.palette.muted})},[e.renderSlot(l.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(t.descricao),1)])],4)):e.createCommentVNode("",!0)]))}};function j(t){const l=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(r){if(r==null)return"";const a=Number(r);return Number.isNaN(a)?String(r):t.tipoValor==="percentual"?l.value.format(a/100):l.value.format(a)}return{formatador:l,formatar:o}}const J="1px solid rgba(15,23,42,.06)";function Q(t,{caretFlexivel:l=!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:l?"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 r=document.createElement("div");r.className="nc-tt__caret";const a={position:"absolute",left:"50%",width:"10px",height:"10px",background:"#ffffff",transform:"translateX(-50%) rotate(45deg)",borderRadius:"2px"};l?Object.assign(r.style,a):Object.assign(r.style,a,{bottom:"-5px",borderRight:"1px solid rgba(15,23,42,.06)",borderBottom:"1px solid rgba(15,23,42,.06)"}),o.appendChild(r);const p=document.createElement("div");return p.className="nc-tt__content",Object.assign(p.style,{position:"relative",background:"#fff",borderRadius:"8px"}),o.appendChild(p),t.appendChild(o),o}function G(t){const l=t.canvas.parentNode;return l?(getComputedStyle(l).position==="static"&&(l.style.position="relative"),l):null}function K(t,l,o,r=4){const a=l/2;return t-a<r?a+r:t+a>o-r?o-a-r:t}function Z(t){return t?`<div style="font-size:9px;font-weight:500;color:#94A3B8;letter-spacing:.04em;text-transform:uppercase;line-height:1;margin-bottom:4px;">${t}</div>`:""}function oe(t){return t?`<div style="font-size:11px;font-weight:500;color:#64748B;line-height:1.3;margin-top:3px;">${t}</div>`:""}function _(t,l,{nome:o="",alinharDireita:r=!1,margemTopo:a=!1}={}){const p=o?`<span style="font-size:11px;color:#64748B;margin-right:6px;">${o}</span>`:"";return`<div style="display:flex;align-items:center;gap:6px;${a?"margin-top:2px;":""}"><span style="width:6px;height:6px;border-radius:999px;background:${t};box-shadow:0 0 0 2px ${w(t,.15)};flex:0 0 auto;"></span>`+p+`<span style="font-size:12px;font-weight:700;color:#0F172A;letter-spacing:-.01em;line-height:1.1;${r?"margin-left:auto;":""}">${l}</span></div>`}function ae(t,l){t&&(l?Object.assign(t.style,{top:"-5px",bottom:"",borderLeft:J,borderTop:J,borderRight:"",borderBottom:""}):Object.assign(t.style,{top:"",bottom:"-5px",borderRight:J,borderBottom:J,borderLeft:"",borderTop:""}))}function v({corDe:t,valorDe:l,linhasExtrasDe:o=null,deveOcultar:r=()=>!1}){return function(p){const{chart:d,tooltip:m}=p,k=G(d);if(!k)return;const s=Q(k);if(m.opacity===0||r()){s.style.opacity="0";return}const u=m.dataPoints&&m.dataPoints[0],f=s.querySelector(".nc-tt__content"),g=u&&o?o(u):[],b=(Array.isArray(g)?g:[g]).filter(Boolean);f.innerHTML=Z((m.title||[]).join(" "))+_(u?t(u):"#3B82F6",u?l(u):"")+b.map(N=>oe(N)).join("");const{offsetLeft:h,offsetTop:S}=d.canvas;s.style.opacity="1",s.style.visibility="hidden",s.style.left="0px",s.style.top="0px";const A=s.offsetWidth,n=s.offsetHeight,i=4,x=h+m.caretX,y=S+m.caretY,C=K(x,A,k.clientWidth,i),c=y<n+16+i;s.style.transform=c?"translate(-50%, 16px)":"translate(-50%, calc(-100% - 16px))";const $=s.querySelector(".nc-tt__caret");if(ae($,c),$){const N=x-C,E=A/2,V=Math.max(-E+8,Math.min(E-8,N));$.style.left=`calc(50% + ${V}px)`}s.style.left=C+"px",s.style.top=y+"px",s.style.visibility="visible"}}function We(t,l,o,r,a,p,d){t.fillStyle=l.corRotulo,t.beginPath(),t.roundRect?t.roundRect(o,r,a,p,d):(t.moveTo(o+d,r),t.lineTo(o+a-d,r),t.quadraticCurveTo(o+a,r,o+a,r+d),t.lineTo(o+a,r+p-d),t.quadraticCurveTo(o+a,r+p,o+a-d,r+p),t.lineTo(o+d,r+p),t.quadraticCurveTo(o,r+p,o,r+p-d),t.lineTo(o,r+d),t.quadraticCurveTo(o,r,o+d,r)),t.fill(),t.fillStyle=l.corTexto,t.textBaseline="middle",t.textAlign="center",t.fillText(l.rotulo,o+a/2,r+p/2)}function Xe(t){let l=t.querySelector(".nc-tt-linhaRef");return l||(l=document.createElement("div"),l.className="nc-tt-linhaRef",Object.assign(l.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"}),t.appendChild(l),l)}function ne({linhasReferencia:t,horizontal:l=()=>!1,formatar:o}){const r=e.computed(()=>{const m=t();return m?(Array.isArray(m)?m:[m]).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}):[]}),a=[];let p=null;return{linhasNormalizadas:r,pluginLinhaReferencia:{id:"linhaReferencia",afterDatasetsDraw(m){const k=r.value;if(a.length=0,!k.length)return;const{ctx:s,chartArea:u,scales:f}=m,g=l(),b=g?f.x:f.y;b&&k.forEach(h=>{const S=b.getPixelForValue(h.valor);if(a.push({linha:h,pos:S,horizontal:g,chartArea:u}),s.save(),s.beginPath(),s.setLineDash(h.tracejado),s.lineWidth=h.espessura,s.strokeStyle=h.cor,g){if(S<u.left||S>u.right){s.restore();return}s.moveTo(S,u.top),s.lineTo(S,u.bottom)}else{if(S<u.top||S>u.bottom){s.restore();return}s.moveTo(u.left,S),s.lineTo(u.right,S)}if(s.stroke(),s.setLineDash([]),h.rotulo){s.font="600 11px 'Inter', sans-serif";const A=8,n=5,x=s.measureText(h.rotulo).width,y=12,C=x+A*2,c=y+n*2,$=c/2;let N,E;g?(N=S-C/2,E=u.top-c-6,E<0&&(E=u.top+6)):(N=u.left-C-6,E=S-c/2,N<0&&(N=u.left+6)),We(s,h,N,E,C,c,$)}s.restore()})},beforeEvent(m,k){if(!a.length){p=null;return}const s=k.event;if(!s||s.type==="mouseout"||s.x==null||s.y==null){p=null;return}const u=8;let f=null,g=1/0;for(const b of a){const h=b.horizontal?Math.abs(s.x-b.pos):Math.abs(s.y-b.pos),S=b.horizontal?s.y>=b.chartArea.top&&s.y<=b.chartArea.bottom:s.x>=b.chartArea.left&&s.x<=b.chartArea.right;h<=u&&S&&h<g&&(g=h,f=b)}p=f},afterEvent(m,k){if(!a.length)return;const s=k.event;if(!s)return;const u=G(m);if(!u)return;if(!p){const $=u.querySelector(".nc-tt-linhaRef");$&&($.style.opacity="0");return}const f=p,g=Xe(u),b=f.linha.cor||"#0F172A";g.innerHTML=Z(f.linha.rotulo)+_(b,o(f.linha.valor));const h=m.canvas;g.style.opacity="1",g.style.visibility="hidden",g.style.left="0px",g.style.top="0px";const S=g.offsetWidth,A=g.offsetHeight,n=4;let i,x;f.horizontal?(i=h.offsetLeft+f.pos,x=h.offsetTop+s.y):(i=h.offsetLeft+s.x,x=h.offsetTop+f.pos);const y=K(i,S,u.clientWidth,n);let C=x;const c=A+16+n;C<c&&(C=c),g.style.left=y+"px",g.style.top=C+"px",g.style.visibility="visible"}},temLinhaHover:()=>!!p}}const pe="0 1px 2px rgba(0, 0, 0, 0.04), 0 4px 16px rgba(0, 0, 0, 0.06)";function re(t,l){if(!l)return t;const o={...t};for(const[r,a]of Object.entries(l))o[r]&&(o[r]={...o[r],default:a});return o}function H(t){return re({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:pe},textoBotao:{type:String,default:"Ver mais"},botaoVisivel:{type:Boolean,default:!1},exportar:{type:Boolean,default:!1},nomeArquivoExport:{type:String,default:"card.png"}},t)}function W(t){return re({tipoValor:{type:String,default:"numero",validator:l=>["numero","moeda","percentual"].includes(l)},locale:{type:String,default:"pt-BR"},moeda:{type:String,default:"BRL"}},t)}function X(t="top"){return{direcao:{type:String,default:t,validator:l=>["top","bottom","left","right"].includes(l)}}}function le(t){return re({rotuloCategoria:{type:String,default:"Categoria"},rotuloQuantidade:{type:String,default:"Quantidade"},mostrarCabecalho:{type:Boolean,default:!0},itensClicaveis:{type:Boolean,default:!1},tooltipLinha:{type:Function,default:null}},t)}const Ue={class:"card-linhas__header nc-flex nc-flex-column"},Ye={class:"card-linhas__chart nc-flex-1"},Je={key:0,class:"card-linhas__footer nc-mt-3"},Qe={__name:"CardLinhas",props:{...H({nomeArquivoExport:"card-linhas.png"}),...W(),...X("top"),corDetalhes:{type:String,default:"#3B82F6"},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},linhasReferencia:{type:[Object,Array],default:null},detalheTooltip:{type:Function,default:null}},emits:["botaoAcao","exportado"],setup(t,{emit:l}){const o=t,r=l,{palette:a,cardStyle:p}=P(o),{formatar:d}=j(o),{cardRef:m,onExportar:k,iconeExportar:s}=O(o,a,r),u=e.computed(()=>`card-linhas--${o.direcao}`),{linhasNormalizadas:f,pluginLinhaReferencia:g,temLinhaHover:b}=ne({linhasReferencia:()=>o.linhasReferencia,formatar:d}),h=[g],S=e.computed(()=>({labels:o.data.map(i=>i.rotulo),datasets:[{data:o.data.map(i=>i.quantidade),borderColor:o.corDetalhes,borderWidth:3,borderJoinStyle:"round",borderCapStyle:"round",backgroundColor:i=>{const{chart:x}=i,{ctx:y,chartArea:C}=x;if(!C)return"transparent";const c=o.corDetalhes||"#0400FF",$="#7C7C7C",N=y.createLinearGradient(0,C.top,0,C.bottom);return N.addColorStop(.16,w(c,.2)),N.addColorStop(1,w($,0)),N},fill:!0,tension:.45,pointRadius:0,pointHoverRadius:6,pointHoverBorderWidth:3,pointHoverBackgroundColor:o.corDetalhes,pointHoverBorderColor:a.value.bg==="transparent"?"#fff":a.value.bg,clip:!1}]})),A=v({corDe:()=>o.corDetalhes||"#3B82F6",valorDe:i=>d(i.parsed.y),linhasExtrasDe:o.detalheTooltip?i=>o.detalheTooltip(o.data[i.dataIndex],i.dataIndex):null,deveOcultar:b}),n=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,interaction:{intersect:!1,mode:"index"},layout:{padding:{top:f.value.length?24:0,right:0,bottom:0,left:0}},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:A,callbacks:{title:i=>{var x;return((x=i[0])==null?void 0:x.label)??""},label:i=>d(i.parsed.y)}}},scales:{x:{display:!0,afterFit:i=>{i.paddingLeft=0,i.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:f.value.length?Math.max(...f.value.map(i=>i.valor)):void 0}}}));return(i,x)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:m,class:e.normalizeClass(["card-linhas nc-p-4 nc-flex",u.value]),style:e.normalizeStyle(e.unref(p))},[e.createElementVNode("div",Ue,[e.createVNode(U,{class:"card-linhas__topo",legenda:i.legenda,sublegenda:i.sublegenda,palette:e.unref(a),"texto-botao":i.textoBotao,"botao-visivel":i.botaoVisivel,exportar:i.exportar,"opacidade-legenda":"0.85",onBotaoAcao:x[0]||(x[0]=y=>r("botaoAcao")),onExportar:e.unref(k)},e.createSlots({_:2},[i.$slots.legenda?{name:"legenda",fn:e.withCtx(()=>[e.renderSlot(i.$slots,"legenda",{},void 0,!0)]),key:"0"}:void 0,i.$slots.sublegenda?{name:"sublegenda",fn:e.withCtx(()=>[e.renderSlot(i.$slots,"sublegenda",{},void 0,!0)]),key:"1"}:void 0,i.$slots.actions?{name:"actions",fn:e.withCtx(()=>[e.renderSlot(i.$slots,"actions",{},void 0,!0)]),key:"2"}:void 0]),1032,["legenda","sublegenda","palette","texto-botao","botao-visivel","exportar","onExportar"]),i.$slots.titulo||i.titulo||i.$slots.descricao||i.descricao?(e.openBlock(),e.createBlock(te,{key:0,class:"card-linhas__titulos nc-mt-3 nc-mb-2",titulo:i.titulo,descricao:i.descricao,palette:e.unref(a)},e.createSlots({_:2},[i.$slots.titulo?{name:"titulo",fn:e.withCtx(()=>[e.renderSlot(i.$slots,"titulo",{},void 0,!0)]),key:"0"}:void 0,i.$slots.descricao?{name:"descricao",fn:e.withCtx(()=>[e.renderSlot(i.$slots,"descricao",{},void 0,!0)]),key:"1"}:void 0]),1032,["titulo","descricao","palette"])):e.createCommentVNode("",!0)]),e.createElementVNode("div",Ye,[e.createVNode(M,{type:"line",data:S.value,options:n.value,plugins:h,height:t.height},null,8,["data","options","height"])]),i.$slots.footer?(e.openBlock(),e.createElementBlock("div",Je,[e.renderSlot(i.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},fe=F(Qe,[["__scopeId","data-v-7715a094"]]),Ge={class:"nc-tabela-valor"},Ke=["role","tabindex","onMouseenter","onFocus","onClick","onKeydown"],Ze={class:"nc-tabela-rotulo nc-inline-flex nc-align-items-center nc-gap-2"},_e={class:"nc-tabela-valor"},me=F({__name:"TabelaDados",props:{data:{type:Array,required:!0},coresAplicadas:{type:Array,required:!0},palette:{type:Object,required:!0},formatar:{type:Function,required:!0},rotuloCategoria:{type:String,default:"Categoria"},rotuloQuantidade:{type:String,default:"Quantidade"},mostrarCabecalho:{type:Boolean,default:!0},itensClicaveis:{type:Boolean,default:!1},hoverIndex:{type:Number,default:null},padAtiva:{type:String,default:"0.40rem"},tooltipLinha:{type:Function,default:null}},emits:["update:hoverIndex","itemClicado"],setup(t,{emit:l}){const o=t,r=l;function a(f,g){o.itensClicaveis&&r("itemClicado",{item:f,index:g,cor:o.coresAplicadas[g]})}function p(f,g){return(o.tooltipLinha?o.tooltipLinha(f,g):f==null?void 0:f.descricao)||""}const d=e.ref({visivel:!1,texto:"",x:0,y:0});function m(f){const b=Math.min(Math.max(f.clientX,150),window.innerWidth-150),h=Math.max(f.clientY-12,80);d.value.x=b,d.value.y=h}function k(f,g,b){r("update:hoverIndex",b);const h=p(g,b);h&&(d.value.texto=h,d.value.visivel=!0,m(f))}function s(f){d.value.visivel&&m(f)}function u(){r("update:hoverIndex",null),d.value.visivel=!1}return(f,g)=>(e.openBlock(),e.createElementBlock("div",{class:"nc-tabela nc-flex nc-flex-column",style:e.normalizeStyle({"--nc-tabela-pad-ativa":t.padAtiva})},[t.mostrarCabecalho?(e.openBlock(),e.createElementBlock("div",{key:0,class:"nc-tabela-cab nc-flex nc-align-items-center nc-justify-content-between",style:e.normalizeStyle({color:t.palette.muted,borderColor:e.unref(w)(t.palette.muted,.25)})},[e.createElementVNode("span",null,e.toDisplayString(t.rotuloCategoria),1),e.createElementVNode("span",Ge,e.toDisplayString(t.rotuloQuantidade),1)],4)):e.createCommentVNode("",!0),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.data,(b,h)=>(e.openBlock(),e.createElementBlock("div",{key:h,class:e.normalizeClass(["nc-tabela-linha nc-flex nc-align-items-center nc-justify-content-between",{"nc-tabela-linha--clicavel":t.itensClicaveis,"nc-tabela-linha--ativa":t.hoverIndex===h}]),style:e.normalizeStyle({color:t.palette.text,cursor:t.itensClicaveis?"pointer":"default","--nc-linha-bg":e.unref(w)(t.coresAplicadas[h],.05),"--nc-linha-bg-forte":e.unref(w)(t.coresAplicadas[h],.08)}),role:t.itensClicaveis?"button":null,tabindex:t.itensClicaveis?0:null,onMouseenter:S=>k(S,b,h),onMousemove:s,onMouseleave:u,onFocus:S=>r("update:hoverIndex",h),onBlur:g[0]||(g[0]=S=>r("update:hoverIndex",null)),onClick:S=>a(b,h),onKeydown:[e.withKeys(e.withModifiers(S=>a(b,h),["prevent"]),["enter"]),e.withKeys(e.withModifiers(S=>a(b,h),["prevent"]),["space"])]},[e.createElementVNode("span",Ze,[e.createElementVNode("span",{class:"nc-bolinha",style:e.normalizeStyle({background:t.coresAplicadas[h]})},null,4),e.createElementVNode("span",null,e.toDisplayString(b.rotulo),1)]),e.createElementVNode("span",_e,e.toDisplayString(t.formatar(b.quantidade)),1)],46,Ke))),128)),(e.openBlock(),e.createBlock(e.Teleport,{to:"body"},[d.value.visivel?(e.openBlock(),e.createElementBlock("div",{key:0,class:"nc-tabela-tt",style:e.normalizeStyle({left:d.value.x+"px",top:d.value.y+"px"})},e.toDisplayString(d.value.texto),5)):e.createCommentVNode("",!0)]))],4))}},[["__scopeId","data-v-8e7c823a"]]),ve={class:"card-pizza__corpo nc-flex nc-align-items-center"},et={class:"card-pizza__chart-wrap nc-flex nc-align-items-center nc-justify-content-center"},tt={class:"card-pizza__chart"},ot={key:0,class:"nc-centro nc-flex nc-flex-column nc-align-items-center nc-justify-content-center"},at={key:0,class:"card-pizza__footer nc-mt-3"},nt={__name:"CardPizza",props:{...H({nomeArquivoExport:"card-pizza.png"}),...W(),...X("right"),...le(),corDetalhes:{type:String,default:"#3B82F6"},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%"},detalheTooltip:{type:Function,default:null}},emits:["botaoAcao","exportado","itemClicado"],setup(t,{emit:l}){const o=t,r=l,{palette:a,cardStyle:p}=P(o),{formatar:d}=j(o),{cardRef:m,onExportar:k,iconeExportar:s}=O(o,a,r),u=e.computed(()=>`card-pizza--${o.direcao}`),f=e.computed(()=>{const n=Y(o.corDetalhes,o.data.length);return o.data.map((i,x)=>i.cor??n[x])}),g=e.computed(()=>({labels:o.data.map(n=>n.rotulo),datasets:[{data:o.data.map(n=>n.quantidade),backgroundColor:f.value,borderWidth:0,borderColor:"transparent",hoverOffset:6,borderRadius:0,spacing:0}]})),b=v({corDe:n=>f.value[n.dataIndex],valorDe:n=>d(n.parsed),linhasExtrasDe:o.detalheTooltip?n=>o.detalheTooltip(o.data[n.dataIndex],n.dataIndex):null}),h=e.ref(null);function S(n){r("itemClicado",n)}const A=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,cutout:o.cutout,layout:{padding:4},onHover:(n,i,x)=>{h.value=i.length?i[0].index:null,x.canvas.style.cursor=o.itensClicaveis&&i.length?"pointer":"default"},onClick:(n,i)=>{if(!o.itensClicaveis||!i.length)return;const x=i[0].index,y=o.data[x];y&&S({item:y,index:x,cor:f.value[x]})},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:b,callbacks:{title:n=>{var i;return((i=n[0])==null?void 0:i.label)??""},label:n=>d(n.parsed)}}}}));return(n,i)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:m,class:e.normalizeClass(["card-pizza nc-p-4 nc-flex nc-flex-column",u.value]),style:e.normalizeStyle(e.unref(p))},[e.createVNode(U,{class:"card-pizza__topo",legenda:n.legenda,sublegenda:n.sublegenda,palette:e.unref(a),"texto-botao":n.textoBotao,"botao-visivel":n.botaoVisivel,exportar:n.exportar,onBotaoAcao:i[0]||(i[0]=x=>r("botaoAcao")),onExportar:e.unref(k)},e.createSlots({_:2},[n.$slots.legenda?{name:"legenda",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"legenda",{},void 0,!0)]),key:"0"}:void 0,n.$slots.sublegenda?{name:"sublegenda",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"sublegenda",{},void 0,!0)]),key:"1"}:void 0,n.$slots.actions?{name:"actions",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"actions",{},void 0,!0)]),key:"2"}:void 0]),1032,["legenda","sublegenda","palette","texto-botao","botao-visivel","exportar","onExportar"]),e.createElementVNode("div",ve,[e.createVNode(me,{data:t.data,"cores-aplicadas":f.value,palette:e.unref(a),formatar:e.unref(d),"rotulo-categoria":n.rotuloCategoria,"rotulo-quantidade":n.rotuloQuantidade,"mostrar-cabecalho":n.mostrarCabecalho,"itens-clicaveis":n.itensClicaveis,"tooltip-linha":n.tooltipLinha,"hover-index":h.value,"onUpdate:hoverIndex":i[1]||(i[1]=x=>h.value=x),onItemClicado:S},null,8,["data","cores-aplicadas","palette","formatar","rotulo-categoria","rotulo-quantidade","mostrar-cabecalho","itens-clicaveis","tooltip-linha","hover-index"]),e.createElementVNode("div",et,[e.createElementVNode("div",tt,[e.createVNode(M,{type:"doughnut",data:g.value,options:A.value,height:t.height},null,8,["data","options","height"]),n.$slots.titulo||n.titulo||n.$slots.descricao||n.descricao?(e.openBlock(),e.createElementBlock("div",ot,[n.$slots.titulo||n.titulo?(e.openBlock(),e.createElementBlock("div",{key:0,class:"nc-centro-titulo nc-m-0 nc-font-semibold",style:e.normalizeStyle({color:e.unref(a).text})},[e.renderSlot(n.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(n.titulo),1)],!0)],4)):e.createCommentVNode("",!0),n.$slots.descricao||n.descricao?(e.openBlock(),e.createElementBlock("div",{key:1,class:"nc-centro-desc",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(n.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(n.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])])]),n.$slots.footer?(e.openBlock(),e.createElementBlock("div",at,[e.renderSlot(n.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},ge=F(nt,[["__scopeId","data-v-ecbe8798"]]),rt={class:"card-barra__header nc-flex nc-flex-column"},lt={class:"card-barra__chart nc-flex-1"},st={key:0,class:"card-barra__footer nc-mt-3"},it={__name:"CardBarra",props:{...H({nomeArquivoExport:"card-barra.png"}),...W(),...X("top"),corDetalhes:{type:String,default:"#3B82F6"},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},larguraBarra:{type:[String,Number],default:.92},raioBarra:{type:Number,default:6},linhasReferencia:{type:[Object,Array],default:null},corHover:{type:String,default:null},detalheTooltip:{type:Function,default:null}},emits:["botaoAcao","exportado"],setup(t,{emit:l}){e.useCssVars(c=>({v655f41dd:f.value}));const o=t,r=l,{palette:a,cardStyle:p}=P(o),{formatar:d}=j(o),{cardRef:m,onExportar:k,iconeExportar:s}=O(o,a,r),u=e.computed(()=>`card-barra--${o.direcao}`),f=e.computed(()=>typeof o.height=="number"?`${o.height}px`:o.height),g=e.computed(()=>o.orientacao==="horizontal"),{linhasNormalizadas:b,pluginLinhaReferencia:h,temLinhaHover:S}=ne({linhasReferencia:()=>o.linhasReferencia,horizontal:()=>g.value,formatar:d}),A=[h],n=e.computed(()=>Array.isArray(o.series)&&o.series.length>0?o.series.map((c,$)=>({nome:c.nome??`Série ${$+1}`,cor:c.cor||o.cores[$%o.cores.length],dados:Array.isArray(c.dados)?c.dados:[]})):[{nome:o.legenda||"Valores",cor:o.corDetalhes,dados:o.data}]),i=e.computed(()=>{const c=n.value[0];return c?c.dados.map($=>$.rotulo):[]}),x=e.computed(()=>{const c=n.value,$=c.length-1,N=typeof o.larguraBarra=="number"?o.larguraBarra:Number(o.larguraBarra)||.6,E=o.raioBarra,V=g.value;function D(R){if(!o.empilhado||c.length===1)return E;const q=R===0,z=R===$;return V?{topLeft:q?E:0,bottomLeft:q?E:0,topRight:z?E:0,bottomRight:z?E:0}:{bottomLeft:q?E:0,bottomRight:q?E:0,topLeft:z?E:0,topRight:z?E:0}}return{labels:i.value,datasets:c.map((R,q)=>({label:R.nome,data:R.dados.map(z=>z.quantidade),previstos:R.dados.map(z=>z.previsto!=null?z.previsto:null),backgroundColor:w(R.cor,.72),hoverBackgroundColor:o.corHover||R.cor,borderWidth:0,borderRadius:D(q),borderSkipped:!1,categoryPercentage:1,barPercentage:N}))}});function y(c){var we,Te,Re;const{chart:$,tooltip:N}=c,E=G($);if(!E)return;const V=Q(E,{caretFlexivel:!0});if(N.opacity===0||S()){V.style.opacity="0";return}const D=N.dataPoints||[],R=n.value.length>1,q=D.map(L=>{var ze;const I=((ze=n.value[L.datasetIndex])==null?void 0:ze.cor)||o.corDetalhes,ce=d(g.value?L.parsed.x:L.parsed.y);return _(I,ce,{nome:R?L.dataset.label:"",alinharDireita:!0,margemTopo:!0})}).join(""),z=(we=D[0])==null?void 0:we.dataIndex;let se=null;if(z!=null)for(const L of $.data.datasets){const I=(Te=L.previstos)==null?void 0:Te[z];if(I!=null){se=I;break}}const qt=se!=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;">${d(se)}</span></div>`:"";let ke="";if(o.detalheTooltip&&z!=null){const L=(Re=n.value[0])==null?void 0:Re.dados[z],I=o.detalheTooltip(L,z);ke=(Array.isArray(I)?I:[I]).filter(Boolean).map(ce=>oe(ce)).join("")}const Dt=V.querySelector(".nc-tt__content");Dt.innerHTML=Z((N.title||[]).join(" "))+q+qt+ke;const{offsetLeft:Ft,offsetTop:Lt}=$.canvas;V.style.opacity="1",V.style.visibility="hidden",V.style.left="0px",V.style.top="0px";const ie=V.offsetWidth,It=V.offsetHeight,Se=4,Ce=Ft+N.caretX,Be=Lt+N.caretY,$e=K(Ce,ie,E.clientWidth,Se),Mt=ie/2,Ee=14,Ne=Be-Ee-It,Ve=Ne<Se,Pt=Ve?Be+Ee:Ne,Ae=V.querySelector(".nc-tt__caret");ae(Ae,Ve);const Ot=Ce-($e-Mt),Ht=Math.max(10,Math.min(ie-10,Ot));Ae.style.left=Ht+"px",V.style.left=$e+"px",V.style.top=Pt+"px",V.style.visibility="visible"}const C=e.computed(()=>{const c=g.value,$={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:b.value.length?Math.max(...b.value.map(E=>E.valor)):void 0};return{responsive:!0,maintainAspectRatio:!1,indexAxis:c?"y":"x",interaction:{intersect:!1,mode:"index",axis:c?"y":"x"},layout:{padding:{top:b.value.length&&!c?24:12,right:c?12:0,bottom:0,left:b.value.length&&c?60:0}},plugins:{legend:{display:o.mostrarLegendaSeries&&n.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:y,callbacks:{title:E=>{var V;return((V=E[0])==null?void 0:V.label)??""},label:E=>d(c?E.parsed.x:E.parsed.y)}}},scales:{x:c?N:$,y:c?$:N}}});return(c,$)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:m,class:e.normalizeClass(["card-barra nc-p-4 nc-flex",u.value]),style:e.normalizeStyle(e.unref(p))},[e.createElementVNode("div",rt,[e.createVNode(U,{class:"card-barra__topo",legenda:c.legenda,sublegenda:c.sublegenda,palette:e.unref(a),"texto-botao":c.textoBotao,"botao-visivel":c.botaoVisivel,exportar:c.exportar,"opacidade-legenda":"0.85",onBotaoAcao:$[0]||($[0]=N=>r("botaoAcao")),onExportar:e.unref(k)},e.createSlots({_:2},[c.$slots.legenda?{name:"legenda",fn:e.withCtx(()=>[e.renderSlot(c.$slots,"legenda",{},void 0,!0)]),key:"0"}:void 0,c.$slots.sublegenda?{name:"sublegenda",fn:e.withCtx(()=>[e.renderSlot(c.$slots,"sublegenda",{},void 0,!0)]),key:"1"}:void 0,c.$slots.actions?{name:"actions",fn:e.withCtx(()=>[e.renderSlot(c.$slots,"actions",{},void 0,!0)]),key:"2"}:void 0]),1032,["legenda","sublegenda","palette","texto-botao","botao-visivel","exportar","onExportar"]),c.$slots.titulo||c.titulo||c.$slots.descricao||c.descricao?(e.openBlock(),e.createBlock(te,{key:0,class:"card-barra__titulos nc-mt-3 nc-mb-2",titulo:c.titulo,descricao:c.descricao,palette:e.unref(a)},e.createSlots({_:2},[c.$slots.titulo?{name:"titulo",fn:e.withCtx(()=>[e.renderSlot(c.$slots,"titulo",{},void 0,!0)]),key:"0"}:void 0,c.$slots.descricao?{name:"descricao",fn:e.withCtx(()=>[e.renderSlot(c.$slots,"descricao",{},void 0,!0)]),key:"1"}:void 0]),1032,["titulo","descricao","palette"])):e.createCommentVNode("",!0)]),e.createElementVNode("div",lt,[e.createVNode(M,{type:"bar",data:x.value,options:C.value,plugins:A,height:"100%"},null,8,["data","options"])]),c.$slots.footer?(e.openBlock(),e.createElementBlock("div",st,[e.renderSlot(c.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},he=F(it,[["__scopeId","data-v-857f5e5b"]]),ct={class:"card-polar__corpo nc-flex nc-align-items-center"},dt={class:"card-polar__chart-wrap nc-flex nc-align-items-center nc-justify-content-center"},ut={class:"card-polar__chart"},pt={key:0,class:"card-polar__centro-bottom"},ft={key:0,class:"card-polar__footer nc-mt-3"},mt={__name:"CardPolar",props:{...H({nomeArquivoExport:"card-polar.png"}),...W(),...X("right"),...le(),corDetalhes:{type:String,default:"#3B82F6"},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},detalheTooltip:{type:Function,default:null}},emits:["botaoAcao","exportado","itemClicado"],setup(t,{emit:l}){const o=t,r=l,{palette:a,cardStyle:p}=P(o),{formatar:d}=j(o),{cardRef:m,onExportar:k,iconeExportar:s}=O(o,a,r),u=e.computed(()=>`card-polar--${o.direcao}`),f=e.computed(()=>{const n=Y(o.corDetalhes,o.data.length);return o.data.map((i,x)=>i.cor??n[x])}),g=e.computed(()=>({labels:o.data.map(n=>n.rotulo),datasets:[{data:o.data.map(n=>n.quantidade),backgroundColor:f.value,borderColor:f.value,borderWidth:0,hoverOffset:6}]})),b=v({corDe:n=>f.value[n.dataIndex],valorDe:n=>d(n.parsed.r??n.parsed),linhasExtrasDe:o.detalheTooltip?n=>o.detalheTooltip(o.data[n.dataIndex],n.dataIndex):null}),h=e.ref(null);function S(n){r("itemClicado",n)}const A=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,layout:{padding:4},onHover:(n,i,x)=>{h.value=i.length?i[0].index:null,x.canvas.style.cursor=o.itensClicaveis&&i.length?"pointer":"default"},onClick:(n,i)=>{if(!o.itensClicaveis||!i.length)return;const x=i[0].index,y=o.data[x];y&&S({item:y,index:x,cor:f.value[x]})},scales:{r:{beginAtZero:!0,ticks:{display:!1,backdropColor:"transparent"},grid:{display:o.mostrarLinhasGrade,color:w(a.value.muted,.18)},angleLines:{display:o.mostrarLinhasGrade,color:w(a.value.muted,.18)},pointLabels:{display:!1}}},plugins:{legend:{display:!1},tooltip:{enabled:!1,external:b,callbacks:{title:n=>{var i;return((i=n[0])==null?void 0:i.label)??""},label:n=>{var i;return d(((i=n.parsed)==null?void 0:i.r)??n.parsed)}}}}}));return(n,i)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:m,class:e.normalizeClass(["card-polar nc-p-4 nc-flex nc-flex-column",u.value]),style:e.normalizeStyle(e.unref(p))},[e.createVNode(U,{class:"card-polar__topo",legenda:n.legenda,sublegenda:n.sublegenda,palette:e.unref(a),"texto-botao":n.textoBotao,"botao-visivel":n.botaoVisivel,exportar:n.exportar,onBotaoAcao:i[0]||(i[0]=x=>r("botaoAcao")),onExportar:e.unref(k)},e.createSlots({_:2},[n.$slots.legenda?{name:"legenda",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"legenda",{},void 0,!0)]),key:"0"}:void 0,n.$slots.sublegenda?{name:"sublegenda",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"sublegenda",{},void 0,!0)]),key:"1"}:void 0,n.$slots.actions?{name:"actions",fn:e.withCtx(()=>[e.renderSlot(n.$slots,"actions",{},void 0,!0)]),key:"2"}:void 0]),1032,["legenda","sublegenda","palette","texto-botao","botao-visivel","exportar","onExportar"]),e.createElementVNode("div",ct,[e.createVNode(me,{data:t.data,"cores-aplicadas":f.value,palette:e.unref(a),formatar:e.unref(d),"rotulo-categoria":n.rotuloCategoria,"rotulo-quantidade":n.rotuloQuantidade,"mostrar-cabecalho":n.mostrarCabecalho,"itens-clicaveis":n.itensClicaveis,"tooltip-linha":n.tooltipLinha,"pad-ativa":"0.25rem","hover-index":h.value,"onUpdate:hoverIndex":i[1]||(i[1]=x=>h.value=x),onItemClicado:S},null,8,["data","cores-aplicadas","palette","formatar","rotulo-categoria","rotulo-quantidade","mostrar-cabecalho","itens-clicaveis","tooltip-linha","hover-index"]),e.createElementVNode("div",dt,[e.createElementVNode("div",ut,[e.createVNode(M,{type:"polarArea",data:g.value,options:A.value,height:t.height},null,8,["data","options","height"]),n.$slots.titulo||n.titulo||n.$slots.descricao||n.descricao?(e.openBlock(),e.createElementBlock("div",pt,[n.$slots.titulo||n.titulo?(e.openBlock(),e.createElementBlock("div",{key:0,class:"card-polar__centro-titulo nc-m-0 nc-text-3xl nc-font-semibold",style:e.normalizeStyle({color:e.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[e.renderSlot(n.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(n.titulo),1)],!0)],4)):e.createCommentVNode("",!0),n.$slots.descricao||n.descricao?(e.openBlock(),e.createElementBlock("div",{key:1,class:"card-polar__centro-desc",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(n.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(n.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)])])]),n.$slots.footer?(e.openBlock(),e.createElementBlock("div",ft,[e.renderSlot(n.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},ye=F(mt,[["__scopeId","data-v-9f63090f"]]),gt={class:"card-progresso__corpo nc-flex nc-align-items-center nc-flex-wrap"},ht={key:0,class:"card-progresso__chart-wrap nc-flex nc-align-items-center nc-justify-content-center"},yt={class:"card-progresso__chart"},bt={class:"nc-centro nc-flex nc-flex-column nc-align-items-center nc-justify-content-center"},xt={class:"card-progresso__lista nc-flex nc-flex-column"},kt={class:"card-progresso__item-cab nc-flex nc-align-items-center nc-justify-content-between"},St={key:0,class:"card-progresso__item-valor nc-inline-flex nc-align-items-center nc-gap-2"},Ct={key:0},Bt={key:1,class:"card-progresso__footer nc-mt-3"},$t={__name:"CardProgresso",props:{...H({nomeArquivoExport:"card-progresso.png"}),...W(),...X("top"),corDetalhes:{type:String,default:"#3B82F6"},corExcesso:{type:String,default:"#EF4444"},formato:{type:String,default:"linear",validator:t=>["linear","circular"].includes(t)},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%"}},emits:["botaoAcao","exportado"],setup(t,{emit:l}){const o=t,r=l,{palette:a,cardStyle:p}=P(o),{formatar:d}=j(o),{cardRef:m,onExportar:k,iconeExportar:s}=O(o,a,r),u=e.computed(()=>`card-progresso--${o.direcao}`),f=e.computed(()=>{const y=Y(o.corDetalhes,o.data.length);return o.data.map((C,c)=>{const $=Number(C.meta??o.metaPadrao)||0,N=Number(C.quantidade)||0,E=C.cor??y[c],V=C.modo==="reducao";let D;if(V){const R=Number(C.valor_referencia)||0,q=R-$;D=q>0?Math.max(0,Math.min(100,(R-N)/q*100)):0}else D=$>0?Math.max(0,Math.min(100,N/$*100)):0;return{rotulo:C.rotulo,quantidade:N,meta:$,valorReferencia:C.valor_referencia??null,cor:E,percentual:D,reducao:V}})}),g=e.computed(()=>typeof o.alturaBarra=="number"?`${o.alturaBarra}px`:o.alturaBarra),b=e.computed(()=>typeof o.raioBarra=="number"?`${o.raioBarra}px`:o.raioBarra),h=e.computed(()=>f.value.length?f.value.reduce((y,C)=>y+C.percentual,0)/f.value.length:0),S=e.computed(()=>f.value.every(y=>y.reducao)),A=e.computed(()=>{const y=Math.min(h.value,100),C=Math.max(0,100-y),c=S.value?o.corExcesso:o.corDetalhes;return{labels:["Progresso","Restante"],datasets:[{data:[y,C],backgroundColor:[c,w(a.value.muted,.15)],borderWidth:0,borderColor:"transparent",hoverOffset:0,spacing:0}]}}),n=e.computed(()=>({responsive:!0,maintainAspectRatio:!1,cutout:o.cutout,rotation:-90,circumference:360,layout:{padding:4},plugins:{legend:{display:!1},tooltip:{enabled:!1}}}));function i(y){const C=m.value;if(!C)return;getComputedStyle(C).position==="static"&&(C.style.position="relative");const c=Q(C);c.style.whiteSpace="normal";const $=c.querySelector(".nc-tt__content");$.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>',c.style.opacity="1",c.style.visibility="hidden",c.style.left="0px",c.style.top="0px";const N=y.currentTarget.getBoundingClientRect(),E=C.getBoundingClientRect(),V=N.left-E.left+N.width/2,D=N.top-E.top;c.style.transform="translate(-50%, calc(-100% - 8px))";const R=c.querySelector(".nc-tt__caret");R&&Object.assign(R.style,{top:"",bottom:"-5px",borderLeft:"",borderTop:"",borderRight:"1px solid rgba(15,23,42,.06)",borderBottom:"1px solid rgba(15,23,42,.06)"}),c.style.left=V+"px",c.style.top=D+"px",c.style.visibility="visible"}function x(){var C;const y=(C=m.value)==null?void 0:C.querySelector(".nc-tt");y&&(y.style.opacity="0")}return(y,C)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:m,class:e.normalizeClass(["card-progresso nc-p-4 nc-flex nc-flex-column",u.value]),style:e.normalizeStyle(e.unref(p))},[e.createVNode(U,{class:"card-progresso__topo",legenda:y.legenda,sublegenda:y.sublegenda,palette:e.unref(a),"texto-botao":y.textoBotao,"botao-visivel":y.botaoVisivel,exportar:y.exportar,onBotaoAcao:C[0]||(C[0]=c=>r("botaoAcao")),onExportar:e.unref(k)},e.createSlots({_:2},[y.$slots.legenda?{name:"legenda",fn:e.withCtx(()=>[e.renderSlot(y.$slots,"legenda",{},void 0,!0)]),key:"0"}:void 0,y.$slots.sublegenda?{name:"sublegenda",fn:e.withCtx(()=>[e.renderSlot(y.$slots,"sublegenda",{},void 0,!0)]),key:"1"}:void 0,y.$slots.actions?{name:"actions",fn:e.withCtx(()=>[e.renderSlot(y.$slots,"actions",{},void 0,!0)]),key:"2"}:void 0]),1032,["legenda","sublegenda","palette","texto-botao","botao-visivel","exportar","onExportar"]),y.$slots.titulo||y.titulo||y.$slots.descricao||y.descricao?(e.openBlock(),e.createBlock(te,{key:0,class:"card-progresso__titulos nc-mt-3 nc-mb-2",titulo:y.titulo,descricao:y.descricao,palette:e.unref(a)},e.createSlots({_:2},[y.$slots.titulo?{name:"titulo",fn:e.withCtx(()=>[e.renderSlot(y.$slots,"titulo",{},void 0,!0)]),key:"0"}:void 0,y.$slots.descricao?{name:"descricao",fn:e.withCtx(()=>[e.renderSlot(y.$slots,"descricao",{},void 0,!0)]),key:"1"}:void 0]),1032,["titulo","descricao","palette"])):e.createCommentVNode("",!0),e.createElementVNode("div",gt,[t.formato==="circular"?(e.openBlock(),e.createElementBlock("div",ht,[e.createElementVNode("div",yt,[e.createVNode(M,{type:"doughnut",data:A.value,options:n.value,height:t.height},null,8,["data","options","height"]),e.createElementVNode("div",bt,[e.createElementVNode("div",{class:"nc-centro-titulo",style:e.normalizeStyle({color:S.value?o.corExcesso:e.unref(a).text})},e.toDisplayString(Math.round(h.value))+"% ",5)])])])):e.createCommentVNode("",!0),e.createElementVNode("div",xt,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(c,$)=>(e.openBlock(),e.createElementBlock("div",{key:$,class:"card-progresso__item nc-flex nc-flex-column"},[e.createElementVNode("div",kt,[e.createElementVNode("span",{class:"card-progresso__item-rotulo nc-inline-flex nc-align-items-center nc-gap-2",style:e.normalizeStyle({color:e.unref(a).text})},[e.createElementVNode("span",{class:"nc-bolinha",style:e.normalizeStyle({background:c.cor})},null,4),e.createElementVNode("span",null,e.toDisplayString(c.rotulo),1),c.reducao?(e.openBlock(),e.createElementBlock("span",{key:0,class:"card-progresso__item-modo",style:e.normalizeStyle({color:e.unref(a).muted}),onMouseenter:i,onMouseleave:x},"↓",36)):e.createCommentVNode("",!0)],4),t.mostrarValor||t.mostrarPercentual?(e.openBlock(),e.createElementBlock("span",St,[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(d)(c.quantidade)),1),c.meta?(e.openBlock(),e.createElementBlock("span",Ct," / "+e.toDisplayString(e.unref(d)(c.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(w)(c.cor,.12),color:c.cor})},e.toDisplayString(Math.round(c.percentual))+"% ",5)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)]),e.createElementVNode("div",{class:"card-progresso__trilha nc-w-full",style:e.normalizeStyle({height:g.value,borderRadius:b.value,background:c.reducao?e.unref(w)(o.corExcesso,.18):e.unref(w)(e.unref(a).muted,.15)})},[e.createElementVNode("div",{class:"card-progresso__preenchimento",style:e.normalizeStyle({width:c.percentual+"%",background:c.cor,borderRadius:b.value})},null,4)],4)]))),128))])]),y.$slots.footer?(e.openBlock(),e.createElementBlock("div",Bt,[e.renderSlot(y.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},be=F($t,[["__scopeId","data-v-8002d271"]]),Et={key:0,class:"card-base__topo"},Nt=["innerHTML"],Vt={class:"card-base__legendas nc-flex nc-flex-column"},At={key:1,class:"card-base__titulos nc-flex nc-flex-column"},wt={key:2,class:"card-base__acao nc-flex"},Tt={key:3,class:"card-base__footer"},Rt={__name:"CardBase",props:{...H({sombra:"none",textoBotao:"Ver Todos",botaoVisivel:!0,nomeArquivoExport:"card-base.png"}),alinhamento:{type:String,default:"left",validator:t=>["left","center","right"].includes(t)}},emits:["botaoAcao","exportado"],setup(t,{emit:l}){const o=t,r=l,{palette:a,cardStyle:p}=P(o),{cardRef:d,onExportar:m,iconeExportar:k}=O(o,a,r);function s(){r("botaoAcao")}return(u,f)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"cardRef",ref:d,class:e.normalizeClass(["card-base nc-flex nc-flex-column",`card-base--${t.alinhamento}`]),style:e.normalizeStyle(e.unref(p))},[u.exportar?(e.openBlock(),e.createElementBlock("div",Et,[e.createElementVNode("button",{type:"button",class:"nc-exportar card-base__exportar nc-inline-flex nc-align-items-center nc-justify-content-center",style:e.normalizeStyle({color:e.unref(a).muted,borderColor:e.unref(w)(e.unref(a).text==="inherit"?"#0F172A":e.unref(a).text,.18)}),title:"Exportar como imagem","aria-label":"Exportar como imagem",onClick:f[0]||(f[0]=(...g)=>e.unref(m)&&e.unref(m)(...g)),innerHTML:e.unref(k)},null,12,Nt)])):e.createCommentVNode("",!0),e.createElementVNode("div",Vt,[u.$slots.legenda||u.legenda?(e.openBlock(),e.createElementBlock("div",{key:0,class:"card-base__legenda nc-font-medium nc-text-xs",style:e.normalizeStyle({color:e.unref(a).text})},[e.renderSlot(u.$slots,"legenda",{},()=>[e.createTextVNode(e.toDisplayString(u.legenda),1)],!0)],4)):e.createCommentVNode("",!0),u.$slots.sublegenda||u.sublegenda?(e.openBlock(),e.createElementBlock("div",{key:1,class:"card-base__sublegenda nc-text-xs",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(u.$slots,"sublegenda",{},()=>[e.createTextVNode(e.toDisplayString(u.sublegenda),1)],!0)],4)):e.createCommentVNode("",!0)]),u.$slots.titulo||u.titulo||u.$slots.descricao||u.descricao?(e.openBlock(),e.createElementBlock("div",At,[u.$slots.titulo||u.titulo?(e.openBlock(),e.createElementBlock("div",{key:0,class:"card-base__titulo nc-m-0 nc-text-3xl nc-font-semibold",style:e.normalizeStyle({color:e.unref(a).text,lineHeight:"33px",letterSpacing:"-1px"})},[e.renderSlot(u.$slots,"titulo",{},()=>[e.createTextVNode(e.toDisplayString(u.titulo),1)],!0)],4)):e.createCommentVNode("",!0),u.$slots.descricao||u.descricao?(e.openBlock(),e.createElementBlock("div",{key:1,class:"nc-text-sm",style:e.normalizeStyle({color:e.unref(a).muted})},[e.renderSlot(u.$slots,"descricao",{},()=>[e.createTextVNode(e.toDisplayString(u.descricao),1)],!0)],4)):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0),u.$slots.acao||u.botaoVisivel?(e.openBlock(),e.createElementBlock("div",wt,[e.renderSlot(u.$slots,"acao",{},()=>[u.botaoVisivel?(e.openBlock(),e.createElementBlock("button",{key:0,type:"button",class:"card-base__link nc-text-xs nc-inline-flex nc-align-items-center",style:e.normalizeStyle({color:e.unref(a).text}),onClick:s},[e.createElementVNode("span",null,e.toDisplayString(u.textoBotao),1),f[1]||(f[1]=e.createElementVNode("span",{class:"card-base__chevron","aria-hidden":"true"},"›",-1))],4)):e.createCommentVNode("",!0)],!0)])):e.createCommentVNode("",!0),u.$slots.footer?(e.openBlock(),e.createElementBlock("div",Tt,[e.renderSlot(u.$slots,"footer",{},void 0,!0)])):e.createCommentVNode("",!0)],6))}},xe=F(Rt,[["__scopeId","data-v-6fe4b0aa"]]),zt={install(t){t.component("ChartBase",M),t.component("CardBase",xe),t.component("CardLinhas",fe),t.component("CardPizza",ge),t.component("CardBarra",he),t.component("CardPolar",ye),t.component("CardProgresso",be)}};B.CardBarra=he,B.CardBase=xe,B.CardLinhas=fe,B.CardPizza=ge,B.CardPolar=ye,B.CardProgresso=be,B.ChartBase=M,B.ICONE_EXPORTAR_SVG=ee,B.SOMBRA_PADRAO=pe,B.aplicarCaretFlip=ae,B.clampHorizontal=K,B.criarTooltipEl=Q,B.criarTooltipExternoPadrao=v,B.default=zt,B.exportarElementoComoImagem=ue,B.gerarPaleta=Y,B.prepararTooltipParent=G,B.propsCartao=H,B.propsDirecao=X,B.propsTabela=le,B.propsValor=W,B.toRgba=w,B.ttLinhaTexto=oe,B.ttLinhaValor=_,B.ttTitulo=Z,B.useExportarCard=O,B.useFormatadorValor=j,B.useLinhasReferencia=ne,B.useTema=P,Object.defineProperties(B,{__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-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-eda43720]{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-eda43720]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-pizza__corpo[data-v-eda43720]{display:flex;gap:3.5rem;align-items:center;flex:1 1 auto;min-height:0}.card-pizza--right .card-pizza__corpo[data-v-eda43720]{flex-direction:row}.card-pizza--left .card-pizza__corpo[data-v-eda43720]{flex-direction:row-reverse}.card-pizza--bottom .card-pizza__corpo[data-v-eda43720]{flex-direction:column;align-items:stretch}.card-pizza--top .card-pizza__corpo[data-v-eda43720]{flex-direction:column-reverse;align-items:stretch}.card-pizza--top .card-pizza__chart[data-v-eda43720],.card-pizza--bottom .card-pizza__chart[data-v-eda43720]{max-width:320px;margin:0 auto}.card-pizza--right .nc-tabela[data-v-eda43720],.card-pizza--left .nc-tabela[data-v-eda43720]{flex:1 1 0;min-width:0;overflow:hidden}.card-pizza--top .nc-tabela[data-v-eda43720],.card-pizza--bottom .nc-tabela[data-v-eda43720]{width:100%}.card-pizza--right .card-pizza__chart-wrap[data-v-eda43720],.card-pizza--left .card-pizza__chart-wrap[data-v-eda43720]{flex:0 0 clamp(140px,38%,240px);width:clamp(140px,38%,240px)}.card-pizza__chart-wrap[data-v-eda43720]{display:flex;align-items:center;justify-content:center}.card-pizza__chart[data-v-eda43720]{position:relative;width:100%;min-width:0}.nc-tabela-linha[data-v-eda43720]{position:relative;border-radius:8px;padding-inline:0;transition:background .18s ease,padding-inline .18s ease}.nc-tabela-linha--ativa[data-v-eda43720]{background:var(--nc-linha-bg, rgba(15, 23, 42, .03));padding-inline:.4rem}.nc-tabela-linha--clicavel[data-v-eda43720]:hover,.nc-tabela-linha--clicavel[data-v-eda43720]:focus-visible{background:var(--nc-linha-bg-forte, rgba(15, 23, 42, .04));padding-inline:.4rem;outline:none}@container (max-width: 520px){.card-pizza[data-v-eda43720]{gap:.75rem}.card-pizza__topo[data-v-eda43720]{flex-wrap:wrap}.card-pizza--left .card-pizza__corpo[data-v-eda43720],.card-pizza--right .card-pizza__corpo[data-v-eda43720]{flex-direction:column-reverse;align-items:stretch;gap:1rem}.card-pizza--left .nc-tabela[data-v-eda43720],.card-pizza--right .nc-tabela[data-v-eda43720]{flex:1 1 auto;width:100%}.card-pizza--left .card-pizza__chart-wrap[data-v-eda43720],.card-pizza--right .card-pizza__chart-wrap[data-v-eda43720]{flex:0 0 auto;width:100%}.card-pizza__chart[data-v-eda43720]{max-width:260px;margin:0 auto}.nc-centro-titulo[data-v-eda43720]{font-size:1.05rem}.nc-centro-desc[data-v-eda43720]{font-size:.58rem}.nc-tabela-linha[data-v-eda43720]{font-size:.78rem}}@container (max-width: 340px){.card-pizza__chart[data-v-eda43720]{max-width:200px}.nc-centro-titulo[data-v-eda43720]{font-size:.9rem}.nc-tabela-linha[data-v-eda43720]{font-size:.72rem}.nc-tabela-cab[data-v-eda43720]{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-c384afa9]{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-c384afa9]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-polar__corpo[data-v-c384afa9]{display:flex;gap:3.5rem;align-items:center;flex:1 1 auto;min-height:0}.card-polar--right .card-polar__corpo[data-v-c384afa9]{flex-direction:row}.card-polar--left .card-polar__corpo[data-v-c384afa9]{flex-direction:row-reverse}.card-polar--bottom .card-polar__corpo[data-v-c384afa9]{flex-direction:column;align-items:stretch}.card-polar--top .card-polar__corpo[data-v-c384afa9]{flex-direction:column-reverse;align-items:stretch}.card-polar--top .card-polar__chart[data-v-c384afa9],.card-polar--bottom .card-polar__chart[data-v-c384afa9]{max-width:320px;margin:0 auto}.card-polar--right .nc-tabela[data-v-c384afa9],.card-polar--left .nc-tabela[data-v-c384afa9]{flex:1 1 0;min-width:0;overflow:hidden}.card-polar--top .nc-tabela[data-v-c384afa9],.card-polar--bottom .nc-tabela[data-v-c384afa9]{width:100%}.card-polar--right .card-polar__chart-wrap[data-v-c384afa9],.card-polar--left .card-polar__chart-wrap[data-v-c384afa9]{flex:0 0 clamp(140px,38%,240px);width:clamp(140px,38%,240px)}.card-polar__chart-wrap[data-v-c384afa9]{display:flex;align-items:center;justify-content:center}.card-polar__chart[data-v-c384afa9]{position:relative;width:100%;min-width:0}.card-polar__centro-bottom[data-v-c384afa9]{text-align:center;margin-top:.5rem}.card-polar__centro-titulo[data-v-c384afa9]{font-size:1.15rem;font-weight:600;line-height:1.2}.card-polar__centro-desc[data-v-c384afa9]{font-size:.85rem;margin-top:.15rem}.nc-tabela-linha[data-v-c384afa9]{position:relative;border-radius:8px;padding-inline:0;transition:background .18s ease,padding-inline .18s ease}.nc-tabela-linha--ativa[data-v-c384afa9]{background:var(--nc-linha-bg, rgba(15, 23, 42, .03));padding-inline:.25rem}.nc-tabela-linha--clicavel[data-v-c384afa9]:hover,.nc-tabela-linha--clicavel[data-v-c384afa9]:focus-visible{background:var(--nc-linha-bg-forte, rgba(15, 23, 42, .04));padding-inline:.25rem;outline:none}@container (max-width: 520px){.card-polar[data-v-c384afa9]{gap:.75rem}.card-polar__topo[data-v-c384afa9]{flex-wrap:wrap}.card-polar--left .card-polar__corpo[data-v-c384afa9],.card-polar--right .card-polar__corpo[data-v-c384afa9]{flex-direction:column-reverse;align-items:stretch;gap:1rem}.card-polar--left .nc-tabela[data-v-c384afa9],.card-polar--right .nc-tabela[data-v-c384afa9]{flex:1 1 auto;width:100%}.card-polar--left .card-polar__chart-wrap[data-v-c384afa9],.card-polar--right .card-polar__chart-wrap[data-v-c384afa9]{flex:0 0 auto;width:100%}.card-polar__chart[data-v-c384afa9]{max-width:260px;margin:0 auto}.card-polar__centro-titulo[data-v-c384afa9]{font-size:1rem}.card-polar__centro-desc[data-v-c384afa9],.nc-tabela-linha[data-v-c384afa9]{font-size:.78rem}}@container (max-width: 340px){.card-polar__chart[data-v-c384afa9]{max-width:200px}.card-polar__centro-titulo[data-v-c384afa9]{font-size:.9rem}.nc-tabela-linha[data-v-c384afa9]{font-size:.72rem}.nc-tabela-cab[data-v-c384afa9]{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}}
|
|
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-cafc7888]{position:relative}.nc-topo[data-v-35f0d105]{display:flex;align-items:flex-start;justify-content:space-between;gap:1rem}.card-linhas[data-v-7715a094]{display:flex;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Inter,sans-serif}.card-linhas__header[data-v-7715a094]{display:flex;flex-direction:column;padding:1.5rem}.card-linhas__chart[data-v-7715a094]{flex:1 1 auto;min-width:0;min-height:0}.card-linhas--top[data-v-7715a094]{flex-direction:column;padding:0!important}.card-linhas--bottom[data-v-7715a094]{flex-direction:column-reverse;padding:0!important}.card-linhas--top .card-linhas__chart[data-v-7715a094],.card-linhas--bottom .card-linhas__chart[data-v-7715a094]{margin-left:0;margin-right:0}.card-linhas--top .card-linhas__chart[data-v-7715a094]{margin-bottom:0}.card-linhas--bottom .card-linhas__chart[data-v-7715a094]{margin-top:0}.card-linhas--left[data-v-7715a094],.card-linhas--right[data-v-7715a094]{padding:0!important}.card-linhas--left[data-v-7715a094]{flex-direction:row;align-items:stretch}.card-linhas--left .card-linhas__header[data-v-7715a094]{flex:0 0 35%;justify-content:center}.card-linhas--right[data-v-7715a094]{flex-direction:row-reverse;align-items:stretch}.card-linhas--right .card-linhas__header[data-v-7715a094]{flex:0 0 35%;justify-content:center}@media (max-width: 640px){.card-linhas[data-v-7715a094]{gap:.75rem}.card-linhas__topo[data-v-7715a094]{flex-wrap:wrap}.card-linhas--left[data-v-7715a094],.card-linhas--right[data-v-7715a094]{flex-direction:column;align-items:stretch}.card-linhas--left .card-linhas__header[data-v-7715a094],.card-linhas--right .card-linhas__header[data-v-7715a094]{flex:0 0 auto}.card-linhas--left .card-linhas__chart[data-v-7715a094],.card-linhas--right .card-linhas__chart[data-v-7715a094]{margin-left:0;margin-right:0}}.nc-tabela-linha[data-v-8e7c823a]{position:relative;border-radius:8px;padding-inline:0;transition:background .18s ease,padding-inline .18s ease}.nc-tabela-linha--ativa[data-v-8e7c823a]{background:var(--nc-linha-bg, rgba(15, 23, 42, .03));padding-inline:var(--nc-tabela-pad-ativa, .4rem)}.nc-tabela-linha--clicavel[data-v-8e7c823a]:hover,.nc-tabela-linha--clicavel[data-v-8e7c823a]:focus-visible{background:var(--nc-linha-bg-forte, rgba(15, 23, 42, .04));padding-inline:var(--nc-tabela-pad-ativa, .4rem);outline:none}.nc-tabela-tt[data-v-8e7c823a]{position:fixed;transform:translate(-50%,-100%);pointer-events:none;z-index:9999;max-width:280px;white-space:normal;font-family:Geist,sans-serif;font-size:12px;line-height:1.35;color:#0f172a;background:#fff;border:1px solid rgba(15,23,42,.06);border-radius:8px;box-shadow:0 1px 2px #0f172a0f,0 8px 24px #0f172a1f;padding:8px 11px}@container (max-width: 520px){.nc-tabela-linha[data-v-8e7c823a]{font-size:.78rem}}@container (max-width: 340px){.nc-tabela-linha[data-v-8e7c823a]{font-size:.72rem}.nc-tabela-cab[data-v-8e7c823a]{font-size:.68rem}}.card-pizza[data-v-ecbe8798]{container-type:inline-size;display:flex;flex-direction:column;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Geist,sans-serif}.card-pizza__corpo[data-v-ecbe8798]{display:flex;gap:3.5rem;align-items:center;flex:1 1 auto;min-height:0}.card-pizza--right .card-pizza__corpo[data-v-ecbe8798]{flex-direction:row}.card-pizza--left .card-pizza__corpo[data-v-ecbe8798]{flex-direction:row-reverse}.card-pizza--bottom .card-pizza__corpo[data-v-ecbe8798]{flex-direction:column;align-items:stretch}.card-pizza--top .card-pizza__corpo[data-v-ecbe8798]{flex-direction:column-reverse;align-items:stretch}.card-pizza--top .card-pizza__chart[data-v-ecbe8798],.card-pizza--bottom .card-pizza__chart[data-v-ecbe8798]{max-width:320px;margin:0 auto}.card-pizza--right .nc-tabela[data-v-ecbe8798],.card-pizza--left .nc-tabela[data-v-ecbe8798]{flex:1 1 0;min-width:0;overflow:hidden}.card-pizza--top .nc-tabela[data-v-ecbe8798],.card-pizza--bottom .nc-tabela[data-v-ecbe8798]{width:100%}.card-pizza--right .card-pizza__chart-wrap[data-v-ecbe8798],.card-pizza--left .card-pizza__chart-wrap[data-v-ecbe8798]{flex:0 0 clamp(140px,38%,240px);width:clamp(140px,38%,240px)}.card-pizza__chart-wrap[data-v-ecbe8798]{display:flex;align-items:center;justify-content:center}.card-pizza__chart[data-v-ecbe8798]{position:relative;width:100%;min-width:0}@container (max-width: 520px){.card-pizza[data-v-ecbe8798]{gap:.75rem}.card-pizza__topo[data-v-ecbe8798]{flex-wrap:wrap}.card-pizza--left .card-pizza__corpo[data-v-ecbe8798],.card-pizza--right .card-pizza__corpo[data-v-ecbe8798]{flex-direction:column-reverse;align-items:stretch;gap:1rem}.card-pizza--left .nc-tabela[data-v-ecbe8798],.card-pizza--right .nc-tabela[data-v-ecbe8798]{flex:1 1 auto;width:100%}.card-pizza--left .card-pizza__chart-wrap[data-v-ecbe8798],.card-pizza--right .card-pizza__chart-wrap[data-v-ecbe8798]{flex:0 0 auto;width:100%}.card-pizza__chart[data-v-ecbe8798]{max-width:260px;margin:0 auto}.nc-centro-titulo[data-v-ecbe8798]{font-size:1.05rem}.nc-centro-desc[data-v-ecbe8798]{font-size:.58rem}}@container (max-width: 340px){.card-pizza__chart[data-v-ecbe8798]{max-width:200px}.nc-centro-titulo[data-v-ecbe8798]{font-size:.9rem}}.card-barra[data-v-857f5e5b]{display:flex;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Inter,sans-serif}.card-barra__header[data-v-857f5e5b]{display:flex;flex-direction:column}.card-barra__chart[data-v-857f5e5b]{flex:1 1 auto;min-width:0;min-height:var(--v655f41dd);display:flex;flex-direction:column}.card-barra__chart[data-v-857f5e5b] .nc-chart-wrapper{flex:1 1 auto;min-height:0}.card-barra--top[data-v-857f5e5b]{flex-direction:column;align-items:stretch}.card-barra--bottom[data-v-857f5e5b]{flex-direction:column-reverse;align-items:stretch}.card-barra--top .card-barra__chart[data-v-857f5e5b],.card-barra--bottom .card-barra__chart[data-v-857f5e5b]{margin-left:-.5rem;margin-right:-.5rem}.card-barra--top .card-barra__chart[data-v-857f5e5b]{margin-bottom:-.5rem}.card-barra--bottom .card-barra__chart[data-v-857f5e5b]{margin-top:-.5rem}.card-barra--left[data-v-857f5e5b]{flex-direction:row;align-items:stretch}.card-barra--left .card-barra__header[data-v-857f5e5b]{flex:0 0 35%;justify-content:center}.card-barra--right[data-v-857f5e5b]{flex-direction:row-reverse;align-items:stretch}.card-barra--right .card-barra__header[data-v-857f5e5b]{flex:0 0 35%;justify-content:center}.card-polar[data-v-9f63090f]{container-type:inline-size;display:flex;flex-direction:column;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Geist,sans-serif}.card-polar__corpo[data-v-9f63090f]{display:flex;gap:3.5rem;align-items:center;flex:1 1 auto;min-height:0}.card-polar--right .card-polar__corpo[data-v-9f63090f]{flex-direction:row}.card-polar--left .card-polar__corpo[data-v-9f63090f]{flex-direction:row-reverse}.card-polar--bottom .card-polar__corpo[data-v-9f63090f]{flex-direction:column;align-items:stretch}.card-polar--top .card-polar__corpo[data-v-9f63090f]{flex-direction:column-reverse;align-items:stretch}.card-polar--top .card-polar__chart[data-v-9f63090f],.card-polar--bottom .card-polar__chart[data-v-9f63090f]{max-width:320px;margin:0 auto}.card-polar--right .nc-tabela[data-v-9f63090f],.card-polar--left .nc-tabela[data-v-9f63090f]{flex:1 1 0;min-width:0;overflow:hidden}.card-polar--top .nc-tabela[data-v-9f63090f],.card-polar--bottom .nc-tabela[data-v-9f63090f]{width:100%}.card-polar--right .card-polar__chart-wrap[data-v-9f63090f],.card-polar--left .card-polar__chart-wrap[data-v-9f63090f]{flex:0 0 clamp(140px,38%,240px);width:clamp(140px,38%,240px)}.card-polar__chart-wrap[data-v-9f63090f]{display:flex;align-items:center;justify-content:center}.card-polar__chart[data-v-9f63090f]{position:relative;width:100%;min-width:0}.card-polar__centro-bottom[data-v-9f63090f]{text-align:center;margin-top:.5rem}.card-polar__centro-titulo[data-v-9f63090f]{font-size:1.15rem;font-weight:600;line-height:1.2}.card-polar__centro-desc[data-v-9f63090f]{font-size:.85rem;margin-top:.15rem}@container (max-width: 520px){.card-polar[data-v-9f63090f]{gap:.75rem}.card-polar__topo[data-v-9f63090f]{flex-wrap:wrap}.card-polar--left .card-polar__corpo[data-v-9f63090f],.card-polar--right .card-polar__corpo[data-v-9f63090f]{flex-direction:column-reverse;align-items:stretch;gap:1rem}.card-polar--left .nc-tabela[data-v-9f63090f],.card-polar--right .nc-tabela[data-v-9f63090f]{flex:1 1 auto;width:100%}.card-polar--left .card-polar__chart-wrap[data-v-9f63090f],.card-polar--right .card-polar__chart-wrap[data-v-9f63090f]{flex:0 0 auto;width:100%}.card-polar__chart[data-v-9f63090f]{max-width:260px;margin:0 auto}.card-polar__centro-titulo[data-v-9f63090f]{font-size:1rem}.card-polar__centro-desc[data-v-9f63090f]{font-size:.78rem}}@container (max-width: 340px){.card-polar__chart[data-v-9f63090f]{max-width:200px}.card-polar__centro-titulo[data-v-9f63090f]{font-size:.9rem}}.card-progresso[data-v-8002d271]{container-type:inline-size;display:flex;flex-direction:column;gap:1rem;transition:background .2s ease;overflow:hidden;font-family:Inter,sans-serif}.card-progresso__corpo[data-v-8002d271]{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-8002d271]{flex-direction:column;align-items:stretch;flex-wrap:nowrap}.card-progresso--bottom .card-progresso__corpo[data-v-8002d271]{flex-direction:column-reverse;align-items:stretch;flex-wrap:nowrap}.card-progresso--right .card-progresso__corpo[data-v-8002d271]{flex-direction:row-reverse;flex-wrap:nowrap}.card-progresso--left .card-progresso__corpo[data-v-8002d271]{flex-direction:row;flex-wrap:nowrap}.card-progresso--left .card-progresso__chart-wrap[data-v-8002d271],.card-progresso--right .card-progresso__chart-wrap[data-v-8002d271]{align-self:center}.card-progresso__chart-wrap[data-v-8002d271]{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-8002d271],.card-progresso--bottom .card-progresso__chart-wrap[data-v-8002d271]{flex:0 0 auto;width:100%;max-width:280px;margin:0 auto}.card-progresso__chart[data-v-8002d271]{position:relative;width:100%}@container (max-width: 520px){.card-progresso[data-v-8002d271]{gap:.75rem}.card-progresso__topo[data-v-8002d271]{flex-wrap:wrap}.card-progresso--left .card-progresso__corpo[data-v-8002d271],.card-progresso--right .card-progresso__corpo[data-v-8002d271]{flex-direction:column;align-items:stretch;flex-wrap:nowrap}.card-progresso--left .card-progresso__chart-wrap[data-v-8002d271],.card-progresso--right .card-progresso__chart-wrap[data-v-8002d271]{flex:0 0 auto;width:100%;max-width:240px;margin:0 auto}.nc-centro-titulo[data-v-8002d271]{font-size:1.05rem}.nc-centro-desc[data-v-8002d271]{font-size:.58rem}.card-progresso__item-cab[data-v-8002d271]{font-size:.78rem;gap:.5rem}}@container (max-width: 380px){.card-progresso__item-cab[data-v-8002d271]{flex-wrap:wrap}}.nc-centro-titulo[data-v-8002d271]{font-size:1.6rem;font-weight:700;font-variant-numeric:tabular-nums}.card-progresso__lista[data-v-8002d271]{display:flex;flex-direction:column;gap:.85rem;flex:1 1 auto;min-width:0;width:100%}.card-progresso--left .card-progresso__lista[data-v-8002d271],.card-progresso--right .card-progresso__lista[data-v-8002d271]{flex:1 1 0;width:100%;min-width:0}.card-progresso__item[data-v-8002d271]{display:flex;flex-direction:column;gap:.4rem}.card-progresso__item-cab[data-v-8002d271]{display:flex;justify-content:space-between;align-items:center;gap:.75rem;font-size:.82rem}.card-progresso__item-rotulo[data-v-8002d271]{display:inline-flex;align-items:center;gap:.55rem;min-width:0;font-weight:500}.card-progresso__item-valor[data-v-8002d271]{display:inline-flex;align-items:center;gap:.5rem}.card-progresso__item-modo[data-v-8002d271]{font-size:.7rem;font-weight:500;line-height:1}.card-progresso__item-nums[data-v-8002d271]{font-size:.78rem;font-variant-numeric:tabular-nums;font-weight:400}.card-progresso__item-pct[data-v-8002d271]{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-8002d271]{width:100%;overflow:hidden;position:relative}.card-progresso__preenchimento[data-v-8002d271]{height:100%;transition:width .4s ease}.card-base[data-v-6fe4b0aa]{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-6fe4b0aa]{text-align:left;align-items:stretch}.card-base--center[data-v-6fe4b0aa]{text-align:center;align-items:center}.card-base--right[data-v-6fe4b0aa]{text-align:right;align-items:flex-end}.card-base__topo[data-v-6fe4b0aa]{position:absolute;top:.75rem;right:.75rem}.card-base__legendas[data-v-6fe4b0aa]{display:flex;flex-direction:column;gap:.15rem}.card-base__legenda[data-v-6fe4b0aa]{line-height:1.2;letter-spacing:-.005em}.card-base__sublegenda[data-v-6fe4b0aa]{font-size:.78rem;font-weight:400;line-height:1.2}.card-base__titulos[data-v-6fe4b0aa]{display:flex;flex-direction:column;gap:.25rem}.card-base__titulo[data-v-6fe4b0aa]{font-size:1.85rem;font-weight:700;line-height:1.15;letter-spacing:-.015em}.card-base__acao[data-v-6fe4b0aa]{display:flex}.card-base--center .card-base__acao[data-v-6fe4b0aa]{justify-content:center}.card-base--right .card-base__acao[data-v-6fe4b0aa]{justify-content:flex-end}.card-base__link[data-v-6fe4b0aa]{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-6fe4b0aa]:hover{opacity:.7}.card-base__chevron[data-v-6fe4b0aa]{font-size:1.1rem;line-height:1;font-weight:400;transform:translateY(-1px)}.card-base__exportar[data-v-6fe4b0aa]{width:28px;height:28px}.card-base__footer[data-v-6fe4b0aa]{margin-top:.25rem}.nc-flex{display:flex!important}.nc-inline-flex{display:inline-flex!important}.nc-flex-column{flex-direction:column!important}.nc-flex-wrap{flex-wrap:wrap!important}.nc-flex-1{flex:1 1 0%!important}.nc-align-items-start{align-items:flex-start!important}.nc-align-items-center{align-items:center!important}.nc-justify-content-center{justify-content:center!important}.nc-justify-content-between{justify-content:space-between!important}.nc-gap-2{gap:.5rem!important}.nc-gap-3{gap:1rem!important}.nc-p-4{padding:1.5rem!important}.nc-m-0{margin:0!important}.nc-mt-1{margin-top:.25rem!important}.nc-mt-3{margin-top:1rem!important}.nc-mb-2{margin-bottom:.5rem!important}.nc-w-full{width:100%!important}.nc-text-xs{font-size:.75rem!important}.nc-text-sm{font-size:.875rem!important}.nc-text-3xl{font-size:1.75rem!important}.nc-font-medium{font-weight:500!important}.nc-font-semibold{font-weight:600!important}.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}}
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "nemesischart",
|
|
3
|
-
"version": "2.0.
|
|
3
|
+
"version": "2.0.11",
|
|
4
4
|
"private": false,
|
|
5
|
-
"description": "Lib de componentes Vue 3 para charts usando Chart.js,
|
|
5
|
+
"description": "Lib de componentes Vue 3 para charts usando Chart.js, sem dependências de UI externas",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"main": "./dist/nemesischart.umd.cjs",
|
|
8
8
|
"module": "./dist/nemesischart.js",
|
|
@@ -28,8 +28,6 @@
|
|
|
28
28
|
"charts",
|
|
29
29
|
"chartjs",
|
|
30
30
|
"chart.js",
|
|
31
|
-
"primevue",
|
|
32
|
-
"primeflex",
|
|
33
31
|
"dashboard",
|
|
34
32
|
"card",
|
|
35
33
|
"components",
|
|
@@ -58,16 +56,8 @@
|
|
|
58
56
|
},
|
|
59
57
|
"peerDependencies": {
|
|
60
58
|
"chart.js": "^4.0.0",
|
|
61
|
-
"primeflex": "^3.0.0 || ^4.0.0",
|
|
62
|
-
"primeicons": "^6.0.0 || ^7.0.0",
|
|
63
|
-
"primevue": "^3.0.0 || ^4.0.0",
|
|
64
59
|
"vue": "^3.4.0"
|
|
65
60
|
},
|
|
66
|
-
"peerDependenciesMeta": {
|
|
67
|
-
"primeflex": { "optional": true },
|
|
68
|
-
"primeicons": { "optional": true },
|
|
69
|
-
"primevue": { "optional": true }
|
|
70
|
-
},
|
|
71
61
|
"devDependencies": {
|
|
72
62
|
"@storybook/addon-essentials": "^8.0.0",
|
|
73
63
|
"@storybook/addon-interactions": "^8.0.0",
|
|
@@ -78,9 +68,6 @@
|
|
|
78
68
|
"@storybook/vue3-vite": "^8.0.0",
|
|
79
69
|
"@vitejs/plugin-vue": "^5.0.4",
|
|
80
70
|
"chart.js": "^4.4.1",
|
|
81
|
-
"primeflex": "^3.3.1",
|
|
82
|
-
"primeicons": "^6.0.1",
|
|
83
|
-
"primevue": "^3.53.0",
|
|
84
71
|
"storybook": "^8.0.0",
|
|
85
72
|
"vite": "^5.2.0",
|
|
86
73
|
"vue": "^3.4.0",
|