vrfi-design-system 1.2.20 → 1.2.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/main.es.js +27 -13
- package/dist/main.umd.js +1 -1
- package/package.json +1 -1
package/dist/main.es.js
CHANGED
|
@@ -79320,16 +79320,16 @@ function Uze({
|
|
|
79320
79320
|
height: r = 300,
|
|
79321
79321
|
info: o
|
|
79322
79322
|
}) {
|
|
79323
|
-
const a = (
|
|
79324
|
-
labels:
|
|
79323
|
+
const a = (c, d) => Array.isArray(n) ? n[c % n.length] : (n == null ? void 0 : n[d]) ?? pr.PALETTE[c % pr.PALETTE.length], i = t.filter((c) => Number(c.percentage) > 0), l = {
|
|
79324
|
+
labels: i.map((c) => c.label),
|
|
79325
79325
|
datasets: [
|
|
79326
79326
|
{
|
|
79327
|
-
data:
|
|
79328
|
-
backgroundColor:
|
|
79327
|
+
data: i.map((c) => Number(c.percentage)),
|
|
79328
|
+
backgroundColor: i.map((c, d) => a(d, c.key)),
|
|
79329
79329
|
borderWidth: pr.BORDER_WIDTH
|
|
79330
79330
|
}
|
|
79331
79331
|
]
|
|
79332
|
-
},
|
|
79332
|
+
}, s = {
|
|
79333
79333
|
cutout: pr.CUTOUT,
|
|
79334
79334
|
maintainAspectRatio: !1,
|
|
79335
79335
|
layout: { padding: 12 },
|
|
@@ -79339,21 +79339,35 @@ function Uze({
|
|
|
79339
79339
|
labels: {
|
|
79340
79340
|
usePointStyle: !0,
|
|
79341
79341
|
pointStyle: pr.POINT_STYLE,
|
|
79342
|
-
padding: 12
|
|
79342
|
+
padding: 12,
|
|
79343
|
+
filter: (c, d) => {
|
|
79344
|
+
var v, p;
|
|
79345
|
+
const A = c.index ?? 0, f = (v = d.datasets) == null ? void 0 : v[0];
|
|
79346
|
+
return Number(
|
|
79347
|
+
((p = f == null ? void 0 : f.data) == null ? void 0 : p[A]) ?? 0
|
|
79348
|
+
) > 0;
|
|
79349
|
+
}
|
|
79343
79350
|
}
|
|
79344
79351
|
},
|
|
79345
79352
|
tooltip: {
|
|
79346
79353
|
callbacks: {
|
|
79347
|
-
label: (
|
|
79348
|
-
const
|
|
79349
|
-
|
|
79354
|
+
label: (c) => {
|
|
79355
|
+
const d = c.dataIndex, A = Number(c.parsed ?? 0);
|
|
79356
|
+
if (A <= 0) return "";
|
|
79357
|
+
const f = i[d], g = (f == null ? void 0 : f.label) ?? "", v = (f == null ? void 0 : f.count) ?? 0;
|
|
79358
|
+
return `${g}: ${A}${pr.PCT} ${pr.LPAREN}${v.toLocaleString()}${pr.RPAREN}`;
|
|
79350
79359
|
}
|
|
79351
79360
|
}
|
|
79352
79361
|
},
|
|
79353
79362
|
datalabels: {
|
|
79354
|
-
formatter: (
|
|
79355
|
-
|
|
79356
|
-
|
|
79363
|
+
formatter: (c, d) => {
|
|
79364
|
+
var p, m, h;
|
|
79365
|
+
const A = d.dataIndex, f = Number(
|
|
79366
|
+
((h = (m = (p = d.chart.data.datasets) == null ? void 0 : p[0]) == null ? void 0 : m.data) == null ? void 0 : h[A]) ?? 0
|
|
79367
|
+
);
|
|
79368
|
+
if (f <= 0) return "";
|
|
79369
|
+
const g = i[A], v = (g == null ? void 0 : g.count) ?? 0;
|
|
79370
|
+
return `${f}${pr.PCT}${pr.NEWLINE}${pr.LPAREN}${v.toLocaleString()}${pr.RPAREN}`;
|
|
79357
79371
|
},
|
|
79358
79372
|
color: pr.LABEL_COLOR,
|
|
79359
79373
|
align: pr.ALIGN,
|
|
@@ -79369,7 +79383,7 @@ function Uze({
|
|
|
79369
79383
|
/* @__PURE__ */ M.jsx("span", { children: e }),
|
|
79370
79384
|
o && /* @__PURE__ */ M.jsx(Ss, { content: o, placement: uv.TOP_RIGHT, children: /* @__PURE__ */ M.jsx("img", { src: g_, alt: pr.INFO }) })
|
|
79371
79385
|
] }),
|
|
79372
|
-
/* @__PURE__ */ M.jsx("div", { className: JC.chartWrap, children: /* @__PURE__ */ M.jsx(oBe, { data:
|
|
79386
|
+
/* @__PURE__ */ M.jsx("div", { className: JC.chartWrap, children: /* @__PURE__ */ M.jsx(oBe, { data: l, options: s }) })
|
|
79373
79387
|
] });
|
|
79374
79388
|
}
|
|
79375
79389
|
export {
|
package/dist/main.umd.js
CHANGED
|
@@ -646,4 +646,4 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
646
646
|
* (c) 2017-2022 chartjs-plugin-datalabels contributors
|
|
647
647
|
* Released under the MIT license
|
|
648
648
|
*/var a$=function(){if(typeof window<"u"){if(window.devicePixelRatio)return window.devicePixelRatio;var e=window.screen;if(e)return(e.deviceXDPI||1)/(e.logicalXDPI||1)}return 1}(),tf={toTextLines:function(e){var t=[],n;for(e=[].concat(e);e.length;)n=e.pop(),typeof n=="string"?t.unshift.apply(t,n.split(`
|
|
649
|
-
`)):Array.isArray(n)?e.push.apply(e,n):rr(e)||t.unshift(""+n);return t},textSize:function(e,t,n){var r=[].concat(t),o=r.length,a=e.font,i=0,l;for(e.font=n.string,l=0;l<o;++l)i=Math.max(e.measureText(r[l]).width,i);return e.font=a,{height:o*n.lineHeight,width:i}},bound:function(e,t,n){return Math.max(e,Math.min(t,n))},arrayDiff:function(e,t){var n=e.slice(),r=[],o,a,i,l;for(o=0,i=t.length;o<i;++o)l=t[o],a=n.indexOf(l),a===-1?r.push([l,1]):n.splice(a,1);for(o=0,i=n.length;o<i;++o)r.push([n[o],-1]);return r},rasterize:function(e){return Math.round(e*a$)/a$}};function x1(e,t){var n=t.x,r=t.y;if(n===null)return{x:0,y:-1};if(r===null)return{x:1,y:0};var o=e.x-n,a=e.y-r,i=Math.sqrt(o*o+a*a);return{x:i?o/i:0,y:i?a/i:-1}}function yIe(e,t,n,r,o){switch(o){case"center":n=r=0;break;case"bottom":n=0,r=1;break;case"right":n=1,r=0;break;case"left":n=-1,r=0;break;case"top":n=0,r=-1;break;case"start":n=-n,r=-r;break;case"end":break;default:o*=Math.PI/180,n=Math.cos(o),r=Math.sin(o);break}return{x:e,y:t,vx:n,vy:r}}var xIe=0,i$=1,l$=2,s$=4,c$=8;function b0(e,t,n){var r=xIe;return e<n.left?r|=i$:e>n.right&&(r|=l$),t<n.top?r|=c$:t>n.bottom&&(r|=s$),r}function wIe(e,t){for(var n=e.x0,r=e.y0,o=e.x1,a=e.y1,i=b0(n,r,t),l=b0(o,a,t),s,c,d;!(!(i|l)||i&l);)s=i||l,s&c$?(c=n+(o-n)*(t.top-r)/(a-r),d=t.top):s&s$?(c=n+(o-n)*(t.bottom-r)/(a-r),d=t.bottom):s&l$?(d=r+(a-r)*(t.right-n)/(o-n),c=t.right):s&i$&&(d=r+(a-r)*(t.left-n)/(o-n),c=t.left),s===i?(n=c,r=d,i=b0(n,r,t)):(o=c,a=d,l=b0(o,a,t));return{x0:n,x1:o,y0:r,y1:a}}function C0(e,t){var n=t.anchor,r=e,o,a;return t.clamp&&(r=wIe(r,t.area)),n==="start"?(o=r.x0,a=r.y0):n==="end"?(o=r.x1,a=r.y1):(o=(r.x0+r.x1)/2,a=(r.y0+r.y1)/2),yIe(o,a,e.vx,e.vy,t.align)}var y0={arc:function(e,t){var n=(e.startAngle+e.endAngle)/2,r=Math.cos(n),o=Math.sin(n),a=e.innerRadius,i=e.outerRadius;return C0({x0:e.x+r*a,y0:e.y+o*a,x1:e.x+r*i,y1:e.y+o*i,vx:r,vy:o},t)},point:function(e,t){var n=x1(e,t.origin),r=n.x*e.options.radius,o=n.y*e.options.radius;return C0({x0:e.x-r,y0:e.y-o,x1:e.x+r,y1:e.y+o,vx:n.x,vy:n.y},t)},bar:function(e,t){var n=x1(e,t.origin),r=e.x,o=e.y,a=0,i=0;return e.horizontal?(r=Math.min(e.x,e.base),a=Math.abs(e.base-e.x)):(o=Math.min(e.y,e.base),i=Math.abs(e.base-e.y)),C0({x0:r,y0:o+i,x1:r+a,y1:o,vx:n.x,vy:n.y},t)},fallback:function(e,t){var n=x1(e,t.origin);return C0({x0:e.x,y0:e.y,x1:e.x+(e.width||0),y1:e.y+(e.height||0),vx:n.x,vy:n.y},t)}},Ti=tf.rasterize;function EIe(e){var t=e.borderWidth||0,n=e.padding,r=e.size.height,o=e.size.width,a=-o/2,i=-r/2;return{frame:{x:a-n.left-t,y:i-n.top-t,w:o+n.width+t*2,h:r+n.height+t*2},text:{x:a,y:i,w:o,h:r}}}function SIe(e,t){var n=t.chart.getDatasetMeta(t.datasetIndex).vScale;if(!n)return null;if(n.xCenter!==void 0&&n.yCenter!==void 0)return{x:n.xCenter,y:n.yCenter};var r=n.getBasePixel();return e.horizontal?{x:r,y:null}:{x:null,y:r}}function PIe(e){return e instanceof Ed?y0.arc:e instanceof f0?y0.point:e instanceof g0?y0.bar:y0.fallback}function OIe(e,t,n,r,o,a){var i=Math.PI/2;if(a){var l=Math.min(a,o/2,r/2),s=t+l,c=n+l,d=t+r-l,A=n+o-l;e.moveTo(t,c),s<d&&c<A?(e.arc(s,c,l,-Math.PI,-i),e.arc(d,c,l,-i,0),e.arc(d,A,l,0,i),e.arc(s,A,l,i,Math.PI)):s<d?(e.moveTo(s,n),e.arc(d,c,l,-i,i),e.arc(s,c,l,i,Math.PI+i)):c<A?(e.arc(s,c,l,-Math.PI,0),e.arc(s,A,l,0,Math.PI)):e.arc(s,c,l,-Math.PI,Math.PI),e.closePath(),e.moveTo(t,n)}else e.rect(t,n,r,o)}function IIe(e,t,n){var r=n.backgroundColor,o=n.borderColor,a=n.borderWidth;!r&&(!o||!a)||(e.beginPath(),OIe(e,Ti(t.x)+a/2,Ti(t.y)+a/2,Ti(t.w)-a,Ti(t.h)-a,n.borderRadius),e.closePath(),r&&(e.fillStyle=r,e.fill()),o&&a&&(e.strokeStyle=o,e.lineWidth=a,e.lineJoin="miter",e.stroke()))}function DIe(e,t,n){var r=n.lineHeight,o=e.w,a=e.x,i=e.y+r/2;return t==="center"?a+=o/2:(t==="end"||t==="right")&&(a+=o),{h:r,w:o,x:a,y:i}}function TIe(e,t,n){var r=e.shadowBlur,o=n.stroked,a=Ti(n.x),i=Ti(n.y),l=Ti(n.w);o&&e.strokeText(t,a,i,l),n.filled&&(r&&o&&(e.shadowBlur=0),e.fillText(t,a,i,l),r&&o&&(e.shadowBlur=r))}function NIe(e,t,n,r){var o=r.textAlign,a=r.color,i=!!a,l=r.font,s=t.length,c=r.textStrokeColor,d=r.textStrokeWidth,A=c&&d,f;if(!(!s||!i&&!A))for(n=DIe(n,o,l),e.font=l.string,e.textAlign=o,e.textBaseline="middle",e.shadowBlur=r.textShadowBlur,e.shadowColor=r.textShadowColor,i&&(e.fillStyle=a),A&&(e.lineJoin="round",e.lineWidth=d,e.strokeStyle=c),f=0,s=t.length;f<s;++f)TIe(e,t[f],{stroked:A,filled:i,w:n.w,x:n.x,y:n.y+n.h*f})}var d$=function(e,t,n,r){var o=this;o._config=e,o._index=r,o._model=null,o._rects=null,o._ctx=t,o._el=n};Ga(d$.prototype,{_modelize:function(e,t,n,r){var o=this,a=o._index,i=Xr(kn([n.font,{}],r,a)),l=kn([n.color,Vn.color],r,a);return{align:kn([n.align,"center"],r,a),anchor:kn([n.anchor,"center"],r,a),area:r.chart.chartArea,backgroundColor:kn([n.backgroundColor,null],r,a),borderColor:kn([n.borderColor,null],r,a),borderRadius:kn([n.borderRadius,0],r,a),borderWidth:kn([n.borderWidth,0],r,a),clamp:kn([n.clamp,!1],r,a),clip:kn([n.clip,!1],r,a),color:l,display:e,font:i,lines:t,offset:kn([n.offset,4],r,a),opacity:kn([n.opacity,1],r,a),origin:SIe(o._el,r),padding:Wo(kn([n.padding,4],r,a)),positioner:PIe(o._el),rotation:kn([n.rotation,0],r,a)*(Math.PI/180),size:tf.textSize(o._ctx,t,i),textAlign:kn([n.textAlign,"start"],r,a),textShadowBlur:kn([n.textShadowBlur,0],r,a),textShadowColor:kn([n.textShadowColor,l],r,a),textStrokeColor:kn([n.textStrokeColor,l],r,a),textStrokeWidth:kn([n.textStrokeWidth,0],r,a)}},update:function(e){var t=this,n=null,r=null,o=t._index,a=t._config,i,l,s,c=kn([a.display,!0],e,o);c&&(i=e.dataset.data[o],l=bn(Tn(a.formatter,[i,e]),i),s=rr(l)?[]:tf.toTextLines(l),s.length&&(n=t._modelize(c,s,a,e),r=EIe(n))),t._model=n,t._rects=r},geometry:function(){return this._rects?this._rects.frame:{}},rotation:function(){return this._model?this._model.rotation:0},visible:function(){return this._model&&this._model.opacity},model:function(){return this._model},draw:function(e,t){var n=this,r=e.ctx,o=n._model,a=n._rects,i;this.visible()&&(r.save(),o.clip&&(i=o.area,r.beginPath(),r.rect(i.left,i.top,i.right-i.left,i.bottom-i.top),r.clip()),r.globalAlpha=tf.bound(0,o.opacity,1),r.translate(Ti(t.x),Ti(t.y)),r.rotate(o.rotation),IIe(r,a.frame,o),NIe(r,o.lines,a.text,o),r.restore())}});var MIe=Number.MIN_SAFE_INTEGER||-9007199254740991,BIe=Number.MAX_SAFE_INTEGER||9007199254740991;function nf(e,t,n){var r=Math.cos(n),o=Math.sin(n),a=t.x,i=t.y;return{x:a+r*(e.x-a)-o*(e.y-i),y:i+o*(e.x-a)+r*(e.y-i)}}function u$(e,t){var n=BIe,r=MIe,o=t.origin,a,i,l,s,c;for(a=0;a<e.length;++a)i=e[a],l=i.x-o.x,s=i.y-o.y,c=t.vx*l+t.vy*s,n=Math.min(n,c),r=Math.max(r,c);return{min:n,max:r}}function x0(e,t){var n=t.x-e.x,r=t.y-e.y,o=Math.sqrt(n*n+r*r);return{vx:(t.x-e.x)/o,vy:(t.y-e.y)/o,origin:e,ln:o}}var A$=function(){this._rotation=0,this._rect={x:0,y:0,w:0,h:0}};Ga(A$.prototype,{center:function(){var e=this._rect;return{x:e.x+e.w/2,y:e.y+e.h/2}},update:function(e,t,n){this._rotation=n,this._rect={x:t.x+e.x,y:t.y+e.y,w:t.w,h:t.h}},contains:function(e){var t=this,n=1,r=t._rect;return e=nf(e,t.center(),-t._rotation),!(e.x<r.x-n||e.y<r.y-n||e.x>r.x+r.w+n*2||e.y>r.y+r.h+n*2)},intersects:function(e){var t=this._points(),n=e._points(),r=[x0(t[0],t[1]),x0(t[0],t[3])],o,a,i;for(this._rotation!==e._rotation&&r.push(x0(n[0],n[1]),x0(n[0],n[3])),o=0;o<r.length;++o)if(a=u$(t,r[o]),i=u$(n,r[o]),a.max<i.min||i.max<a.min)return!1;return!0},_points:function(){var e=this,t=e._rect,n=e._rotation,r=e.center();return[nf({x:t.x,y:t.y},r,n),nf({x:t.x+t.w,y:t.y},r,n),nf({x:t.x+t.w,y:t.y+t.h},r,n),nf({x:t.x,y:t.y+t.h},r,n)]}});function f$(e,t,n){var r=t.positioner(e,t),o=r.vx,a=r.vy;if(!o&&!a)return{x:r.x,y:r.y};var i=n.w,l=n.h,s=t.rotation,c=Math.abs(i/2*Math.cos(s))+Math.abs(l/2*Math.sin(s)),d=Math.abs(i/2*Math.sin(s))+Math.abs(l/2*Math.cos(s)),A=1/Math.max(Math.abs(o),Math.abs(a));return c*=o*A,d*=a*A,c+=t.offset*o,d+=t.offset*a,{x:r.x+c,y:r.y+d}}function zIe(e,t){var n,r,o,a;for(n=e.length-1;n>=0;--n)for(o=e[n].$layout,r=n-1;r>=0&&o._visible;--r)a=e[r].$layout,a._visible&&o._box.intersects(a._box)&&t(o,a);return e}function RIe(e){var t,n,r,o,a,i,l;for(t=0,n=e.length;t<n;++t)r=e[t],o=r.$layout,o._visible&&(l=new Proxy(r._el,{get:(s,c)=>s.getProps([c],!0)[c]}),a=r.geometry(),i=f$(l,r.model(),a),o._box.update(i,a,r.rotation()));return zIe(e,function(s,c){var d=s._hidable,A=c._hidable;d&&A||A?c._visible=!1:d&&(s._visible=!1)})}var rf={prepare:function(e){var t=[],n,r,o,a,i;for(n=0,o=e.length;n<o;++n)for(r=0,a=e[n].length;r<a;++r)i=e[n][r],t.push(i),i.$layout={_box:new A$,_hidable:!1,_visible:!0,_set:n,_idx:i._index};return t.sort(function(l,s){var c=l.$layout,d=s.$layout;return c._idx===d._idx?d._set-c._set:d._idx-c._idx}),this.update(t),t},update:function(e){var t=!1,n,r,o,a,i;for(n=0,r=e.length;n<r;++n)o=e[n],a=o.model(),i=o.$layout,i._hidable=a&&a.display==="auto",i._visible=o.visible(),t|=i._hidable;t&&RIe(e)},lookup:function(e,t){var n,r;for(n=e.length-1;n>=0;--n)if(r=e[n].$layout,r&&r._visible&&r._box.contains(t))return e[n];return null},draw:function(e,t){var n,r,o,a,i,l;for(n=0,r=t.length;n<r;++n)o=t[n],a=o.$layout,a._visible&&(i=o.geometry(),l=f$(o._el,o.model(),i),a._box.update(l,i,o.rotation()),o.draw(e,l))}},HIe=function(e){if(rr(e))return null;var t=e,n,r,o;if(un(e))if(!rr(e.label))t=e.label;else if(!rr(e.r))t=e.r;else for(t="",n=Object.keys(e),o=0,r=n.length;o<r;++o)t+=(o!==0?", ":"")+n[o]+": "+e[n[o]];return""+t},jIe={align:"center",anchor:"center",backgroundColor:null,borderColor:null,borderRadius:0,borderWidth:0,clamp:!1,clip:!1,color:void 0,display:!0,font:{family:void 0,lineHeight:1.2,size:void 0,style:void 0,weight:null},formatter:HIe,labels:void 0,listeners:{},offset:4,opacity:1,padding:{top:4,right:4,bottom:4,left:4},rotation:0,textAlign:"start",textStrokeColor:void 0,textStrokeWidth:0,textShadowBlur:0,textShadowColor:void 0},uo="$datalabels",g$="$default";function _Ie(e,t){var n=e.datalabels,r={},o=[],a,i;return n===!1?null:(n===!0&&(n={}),t=Ga({},[t,n]),a=t.labels||{},i=Object.keys(a),delete t.labels,i.length?i.forEach(function(l){a[l]&&o.push(Ga({},[t,a[l],{_key:l}]))}):o.push(t),r=o.reduce(function(l,s){return Cn(s.listeners||{},function(c,d){l[d]=l[d]||{},l[d][s._key||g$]=c}),delete s.listeners,l},{}),{labels:o,listeners:r})}function w1(e,t,n,r){if(t){var o=n.$context,a=n.$groups,i;t[a._set]&&(i=t[a._set][a._key],i&&Tn(i,[o,r])===!0&&(e[uo]._dirty=!0,n.update(o)))}}function $Ie(e,t,n,r,o){var a,i;!n&&!r||(n?r?n!==r&&(i=a=!0):i=!0:a=!0,i&&w1(e,t.leave,n,o),a&&w1(e,t.enter,r,o))}function kIe(e,t){var n=e[uo],r=n._listeners,o,a;if(!(!r.enter&&!r.leave)){if(t.type==="mousemove")a=rf.lookup(n._labels,t);else if(t.type!=="mouseout")return;o=n._hovered,n._hovered=a,$Ie(e,r,o,a,t)}}function LIe(e,t){var n=e[uo],r=n._listeners.click,o=r&&rf.lookup(n._labels,t);o&&w1(e,r,o,t)}var FIe={id:"datalabels",defaults:jIe,beforeInit:function(e){e[uo]={_actives:[]}},beforeUpdate:function(e){var t=e[uo];t._listened=!1,t._listeners={},t._datasets=[],t._labels=[]},afterDatasetUpdate:function(e,t,n){var r=t.index,o=e[uo],a=o._datasets[r]=[],i=e.isDatasetVisible(r),l=e.data.datasets[r],s=_Ie(l,n),c=t.meta.data||[],d=e.ctx,A,f,g,v,p,m,h,b;for(d.save(),A=0,g=c.length;A<g;++A)if(h=c[A],h[uo]=[],i&&h&&e.getDataVisibility(A)&&!h.skip)for(f=0,v=s.labels.length;f<v;++f)p=s.labels[f],m=p._key,b=new d$(p,d,h,A),b.$groups={_set:r,_key:m||g$},b.$context={active:!1,chart:e,dataIndex:A,dataset:l,datasetIndex:r},b.update(b.$context),h[uo].push(b),a.push(b);d.restore(),Ga(o._listeners,s.listeners,{merger:function(C,y,x){y[C]=y[C]||{},y[C][t.index]=x[C],o._listened=!0}})},afterUpdate:function(e){e[uo]._labels=rf.prepare(e[uo]._datasets)},afterDatasetsDraw:function(e){rf.draw(e,e[uo]._labels)},beforeEvent:function(e,t){if(e[uo]._listened){var n=t.event;switch(n.type){case"mousemove":case"mouseout":kIe(e,n);break;case"click":LIe(e,n);break}}},afterEvent:function(e){var t=e[uo],n=t._actives,r=t._actives=e.getActiveElements(),o=tf.arrayDiff(n,r),a,i,l,s,c,d,A;for(a=0,i=o.length;a<i;++a)if(c=o[a],c[1])for(A=c[0].element[uo]||[],l=0,s=A.length;l<s;++l)d=A[l],d.$context.active=c[1]===1,d.update(d.$context);(t._dirty||o.length)&&(rf.update(t._labels),e.render()),delete t._dirty}};const E1={card:"_card_16ceq_24",header:"_header_16ceq_33",chartWrap:"_chartWrap_16ceq_44"};u0.register(Ed,uIe,rIe,FIe);function WIe({title:e=yr.DEFAULT_TITLE,data:t,colors:n,height:r=300,info:o}){const a=(s,c)=>Array.isArray(n)?n[s%n.length]:(n==null?void 0:n[c])??yr.PALETTE[s%yr.PALETTE.length],i={labels:t.map(s=>s.label),datasets:[{data:t.map(s=>s.count),backgroundColor:t.map((s,c)=>a(c,s.key)),borderWidth:yr.BORDER_WIDTH}]},l={cutout:yr.CUTOUT,maintainAspectRatio:!1,layout:{padding:12},plugins:{legend:{position:yr.LEGEND_POSITION,labels:{usePointStyle:!0,pointStyle:yr.POINT_STYLE,padding:12}},tooltip:{callbacks:{label:s=>{const c=s.dataIndex,d=t[c];return`${d.label}: ${d.percentage}${yr.PCT} ${yr.LPAREN}${d.count.toLocaleString()}${yr.RPAREN}`}}},datalabels:{formatter:(s,c)=>{const d=c.dataIndex,A=t[d];return`${A.percentage}${yr.PCT}${yr.NEWLINE}${yr.LPAREN}${A.count.toLocaleString()}${yr.RPAREN}`},color:yr.LABEL_COLOR,align:yr.ALIGN,anchor:yr.ANCHOR,clip:!0,clamp:!0,font:{weight:500}}}};return B.jsxs("div",{className:E1.card,style:{height:`${r}px`},children:[B.jsxs("div",{className:E1.header,children:[B.jsx("span",{children:e}),o&&B.jsx(Fl,{content:o,placement:Dd.TOP_RIGHT,children:B.jsx("img",{src:g_,alt:yr.INFO})})]}),B.jsx("div",{className:E1.chartWrap,children:B.jsx(CIe,{data:i,options:l})})]})}Te.Accordian=fEe,Te.ActionType=Id,Te.AgencyDocumentCard=mEe,Te.AgencyJobCard=oEe,Te.Align=Od,Te.AllowedCountries=z1,Te.ApplicationHeader=wxe,Te.AuthBanner=ICe,Te.AuthBannerTextType=SB,Te.AuthForm=MCe,Te.AvatarSize=eo,Te.AvatarWithDetailsCard=ese,Te.AvatarWithInitials=Uu,Te.Badge=qu,Te.BadgeType=N1,Te.Bookmark=nEe,Te.Button=Xx,Te.ButtonType=zs,Te.Calendar=cq,Te.Card=Fle,Te.CardStats=QSe,Te.CardWithIconAndText=kCe,Te.ChatDetails=$Se,Te.ChatList=kSe,Te.CheckBoxWithFormWrapper=Hxe,Te.Checkbox=NB,Te.CheckboxGroup=TB,Te.CheckboxSelectField=Cxe,Te.Colors=zo,Te.ColumnSortOrder=EB,Te.CustomAvatar=yo,Te.CustomModal=dEe,Te.CustomModalTypes=Wc,Te.DOM_ELEMENT_ROLE=kx,Te.DashboardCard=Gwe,Te.DashboardStats=JSe,Te.DatePicker=Zse,Te.Disclaimer=mxe,Te.DocVerificationStatus=Qu,Te.DocumentCard=YB,Te.DocumentStatus=gse,Te.DocumentStatusEnum=lf,Te.DocumentView=mse,Te.Drawer=qse,Te.Dropdown=Tm,Te.EllipsisWithTooltip=ci,Te.Error=Ro,Te.FileUpload=bse,Te.FileUploadWithDropdown=_B,Te.FloatingLabel=za,Te.Form=JCe,Te.FormValidationTriggers=xB,Te.GenderProfileEnum=R1,Te.GenderValueEnum=H1,Te.HtmlButtonType=Sd,Te.Icons=vt,Te.InputField=IB,Te.InputTypes=Ni,Te.InputWithCountry=gce,Te.JobCard=eEe,Te.JobTrackingCard=Vwe,Te.JobTypeEnum=_1,Te.Justify=P0,Te.Label=lv,Te.LabelType=Ju,Te.Layout=Qi,Te.ListItem=TS,Te.ListingTableHeader=ij,Te.Loader=Fse,Te.Menu=wu,Te.MenuMode=rv,Te.Modal=$x,Te.ModalTypeEnum=nv,Te.NoData=rj,Te.NoInternetScreen=KB,Te.NoRecords=fxe,Te.Notification=sv,Te.NotificationCard=pce,Te.NotificationPanel=Nse,Te.NotificationTypes=Mi,Te.Offline=$se,Te.Pagination=lEe,Te.Password=rw,Te.PasswordField=rw,Te.PasswordValidation=Axe,Te.PathIcon=Rxe,Te.PieChart=WIe,Te.Placement=Dd,Te.PopoverIconCard=Uwe,Te.PreviewCard=aj,Te.PreviewDocumentsCard=pxe,Te.PreviewModal=Yse,Te.ProfileAssignedCard=nj,Te.ProfileAssignedEmployer=zCe,Te.ProfileAttachments=QCe,Te.ProfileDetail=$Ce,Te.ProfileDetailFooterTypes=ma,Te.RadioGroup=Rse,Te.Rate=Mj,Te.RatingCard=vEe,Te.RatingProgressBar=FSe,Te.RatingStar=sse,Te.RoleManagement=tEe,Te.SearchField=Vx,Te.SearchWithSuggestions=LSe,Te.Segmented=Oxe,Te.Select=jB,Te.SelectType=oa,Te.Sidebar=zse,Te.Size=of,Te.Slider=Sxe,Te.SliderRangeWithForm=kle,Te.SliderWithForm=Wle,Te.SortOrderKeys=wB,Te.SoundEnum=j1,Te.Space=oxe,Te.StatsBanner=ixe,Te.StatusTypes=sf,Te.SummaryCard=el,Te.SwitchComponent=rEe,Te.TImerPicker=iEe,Te.TableComponent=UB,Te.TableLayout=B1,Te.TableType=af,Te.Tabs=hxe,Te.TextArea=Txe,Te.TextAreaWithController=Dxe,Te.Timer=bxe,Te.TitleHeader=axe,Te.TitleHeaderStatus=M1,Te.Tooltip=Jx,Te.Typography=Fc,Te.Upload=wse,Te.UploadWithDropdown=Sse,Te.UserBadge=Ase,Te.UserStatus=Ise,Te.UserType=Yi,Te.VerificationStatus=Pse,Te.VerificationTypes=Pd,Te.formatTimeAgo=$le,Te.useForm=cj,Object.defineProperty(Te,Symbol.toStringTag,{value:"Module"})});
|
|
649
|
+
`)):Array.isArray(n)?e.push.apply(e,n):rr(e)||t.unshift(""+n);return t},textSize:function(e,t,n){var r=[].concat(t),o=r.length,a=e.font,i=0,l;for(e.font=n.string,l=0;l<o;++l)i=Math.max(e.measureText(r[l]).width,i);return e.font=a,{height:o*n.lineHeight,width:i}},bound:function(e,t,n){return Math.max(e,Math.min(t,n))},arrayDiff:function(e,t){var n=e.slice(),r=[],o,a,i,l;for(o=0,i=t.length;o<i;++o)l=t[o],a=n.indexOf(l),a===-1?r.push([l,1]):n.splice(a,1);for(o=0,i=n.length;o<i;++o)r.push([n[o],-1]);return r},rasterize:function(e){return Math.round(e*a$)/a$}};function x1(e,t){var n=t.x,r=t.y;if(n===null)return{x:0,y:-1};if(r===null)return{x:1,y:0};var o=e.x-n,a=e.y-r,i=Math.sqrt(o*o+a*a);return{x:i?o/i:0,y:i?a/i:-1}}function yIe(e,t,n,r,o){switch(o){case"center":n=r=0;break;case"bottom":n=0,r=1;break;case"right":n=1,r=0;break;case"left":n=-1,r=0;break;case"top":n=0,r=-1;break;case"start":n=-n,r=-r;break;case"end":break;default:o*=Math.PI/180,n=Math.cos(o),r=Math.sin(o);break}return{x:e,y:t,vx:n,vy:r}}var xIe=0,i$=1,l$=2,s$=4,c$=8;function b0(e,t,n){var r=xIe;return e<n.left?r|=i$:e>n.right&&(r|=l$),t<n.top?r|=c$:t>n.bottom&&(r|=s$),r}function wIe(e,t){for(var n=e.x0,r=e.y0,o=e.x1,a=e.y1,i=b0(n,r,t),l=b0(o,a,t),s,c,d;!(!(i|l)||i&l);)s=i||l,s&c$?(c=n+(o-n)*(t.top-r)/(a-r),d=t.top):s&s$?(c=n+(o-n)*(t.bottom-r)/(a-r),d=t.bottom):s&l$?(d=r+(a-r)*(t.right-n)/(o-n),c=t.right):s&i$&&(d=r+(a-r)*(t.left-n)/(o-n),c=t.left),s===i?(n=c,r=d,i=b0(n,r,t)):(o=c,a=d,l=b0(o,a,t));return{x0:n,x1:o,y0:r,y1:a}}function C0(e,t){var n=t.anchor,r=e,o,a;return t.clamp&&(r=wIe(r,t.area)),n==="start"?(o=r.x0,a=r.y0):n==="end"?(o=r.x1,a=r.y1):(o=(r.x0+r.x1)/2,a=(r.y0+r.y1)/2),yIe(o,a,e.vx,e.vy,t.align)}var y0={arc:function(e,t){var n=(e.startAngle+e.endAngle)/2,r=Math.cos(n),o=Math.sin(n),a=e.innerRadius,i=e.outerRadius;return C0({x0:e.x+r*a,y0:e.y+o*a,x1:e.x+r*i,y1:e.y+o*i,vx:r,vy:o},t)},point:function(e,t){var n=x1(e,t.origin),r=n.x*e.options.radius,o=n.y*e.options.radius;return C0({x0:e.x-r,y0:e.y-o,x1:e.x+r,y1:e.y+o,vx:n.x,vy:n.y},t)},bar:function(e,t){var n=x1(e,t.origin),r=e.x,o=e.y,a=0,i=0;return e.horizontal?(r=Math.min(e.x,e.base),a=Math.abs(e.base-e.x)):(o=Math.min(e.y,e.base),i=Math.abs(e.base-e.y)),C0({x0:r,y0:o+i,x1:r+a,y1:o,vx:n.x,vy:n.y},t)},fallback:function(e,t){var n=x1(e,t.origin);return C0({x0:e.x,y0:e.y,x1:e.x+(e.width||0),y1:e.y+(e.height||0),vx:n.x,vy:n.y},t)}},Ti=tf.rasterize;function EIe(e){var t=e.borderWidth||0,n=e.padding,r=e.size.height,o=e.size.width,a=-o/2,i=-r/2;return{frame:{x:a-n.left-t,y:i-n.top-t,w:o+n.width+t*2,h:r+n.height+t*2},text:{x:a,y:i,w:o,h:r}}}function SIe(e,t){var n=t.chart.getDatasetMeta(t.datasetIndex).vScale;if(!n)return null;if(n.xCenter!==void 0&&n.yCenter!==void 0)return{x:n.xCenter,y:n.yCenter};var r=n.getBasePixel();return e.horizontal?{x:r,y:null}:{x:null,y:r}}function PIe(e){return e instanceof Ed?y0.arc:e instanceof f0?y0.point:e instanceof g0?y0.bar:y0.fallback}function OIe(e,t,n,r,o,a){var i=Math.PI/2;if(a){var l=Math.min(a,o/2,r/2),s=t+l,c=n+l,d=t+r-l,A=n+o-l;e.moveTo(t,c),s<d&&c<A?(e.arc(s,c,l,-Math.PI,-i),e.arc(d,c,l,-i,0),e.arc(d,A,l,0,i),e.arc(s,A,l,i,Math.PI)):s<d?(e.moveTo(s,n),e.arc(d,c,l,-i,i),e.arc(s,c,l,i,Math.PI+i)):c<A?(e.arc(s,c,l,-Math.PI,0),e.arc(s,A,l,0,Math.PI)):e.arc(s,c,l,-Math.PI,Math.PI),e.closePath(),e.moveTo(t,n)}else e.rect(t,n,r,o)}function IIe(e,t,n){var r=n.backgroundColor,o=n.borderColor,a=n.borderWidth;!r&&(!o||!a)||(e.beginPath(),OIe(e,Ti(t.x)+a/2,Ti(t.y)+a/2,Ti(t.w)-a,Ti(t.h)-a,n.borderRadius),e.closePath(),r&&(e.fillStyle=r,e.fill()),o&&a&&(e.strokeStyle=o,e.lineWidth=a,e.lineJoin="miter",e.stroke()))}function DIe(e,t,n){var r=n.lineHeight,o=e.w,a=e.x,i=e.y+r/2;return t==="center"?a+=o/2:(t==="end"||t==="right")&&(a+=o),{h:r,w:o,x:a,y:i}}function TIe(e,t,n){var r=e.shadowBlur,o=n.stroked,a=Ti(n.x),i=Ti(n.y),l=Ti(n.w);o&&e.strokeText(t,a,i,l),n.filled&&(r&&o&&(e.shadowBlur=0),e.fillText(t,a,i,l),r&&o&&(e.shadowBlur=r))}function NIe(e,t,n,r){var o=r.textAlign,a=r.color,i=!!a,l=r.font,s=t.length,c=r.textStrokeColor,d=r.textStrokeWidth,A=c&&d,f;if(!(!s||!i&&!A))for(n=DIe(n,o,l),e.font=l.string,e.textAlign=o,e.textBaseline="middle",e.shadowBlur=r.textShadowBlur,e.shadowColor=r.textShadowColor,i&&(e.fillStyle=a),A&&(e.lineJoin="round",e.lineWidth=d,e.strokeStyle=c),f=0,s=t.length;f<s;++f)TIe(e,t[f],{stroked:A,filled:i,w:n.w,x:n.x,y:n.y+n.h*f})}var d$=function(e,t,n,r){var o=this;o._config=e,o._index=r,o._model=null,o._rects=null,o._ctx=t,o._el=n};Ga(d$.prototype,{_modelize:function(e,t,n,r){var o=this,a=o._index,i=Xr(kn([n.font,{}],r,a)),l=kn([n.color,Vn.color],r,a);return{align:kn([n.align,"center"],r,a),anchor:kn([n.anchor,"center"],r,a),area:r.chart.chartArea,backgroundColor:kn([n.backgroundColor,null],r,a),borderColor:kn([n.borderColor,null],r,a),borderRadius:kn([n.borderRadius,0],r,a),borderWidth:kn([n.borderWidth,0],r,a),clamp:kn([n.clamp,!1],r,a),clip:kn([n.clip,!1],r,a),color:l,display:e,font:i,lines:t,offset:kn([n.offset,4],r,a),opacity:kn([n.opacity,1],r,a),origin:SIe(o._el,r),padding:Wo(kn([n.padding,4],r,a)),positioner:PIe(o._el),rotation:kn([n.rotation,0],r,a)*(Math.PI/180),size:tf.textSize(o._ctx,t,i),textAlign:kn([n.textAlign,"start"],r,a),textShadowBlur:kn([n.textShadowBlur,0],r,a),textShadowColor:kn([n.textShadowColor,l],r,a),textStrokeColor:kn([n.textStrokeColor,l],r,a),textStrokeWidth:kn([n.textStrokeWidth,0],r,a)}},update:function(e){var t=this,n=null,r=null,o=t._index,a=t._config,i,l,s,c=kn([a.display,!0],e,o);c&&(i=e.dataset.data[o],l=bn(Tn(a.formatter,[i,e]),i),s=rr(l)?[]:tf.toTextLines(l),s.length&&(n=t._modelize(c,s,a,e),r=EIe(n))),t._model=n,t._rects=r},geometry:function(){return this._rects?this._rects.frame:{}},rotation:function(){return this._model?this._model.rotation:0},visible:function(){return this._model&&this._model.opacity},model:function(){return this._model},draw:function(e,t){var n=this,r=e.ctx,o=n._model,a=n._rects,i;this.visible()&&(r.save(),o.clip&&(i=o.area,r.beginPath(),r.rect(i.left,i.top,i.right-i.left,i.bottom-i.top),r.clip()),r.globalAlpha=tf.bound(0,o.opacity,1),r.translate(Ti(t.x),Ti(t.y)),r.rotate(o.rotation),IIe(r,a.frame,o),NIe(r,o.lines,a.text,o),r.restore())}});var MIe=Number.MIN_SAFE_INTEGER||-9007199254740991,BIe=Number.MAX_SAFE_INTEGER||9007199254740991;function nf(e,t,n){var r=Math.cos(n),o=Math.sin(n),a=t.x,i=t.y;return{x:a+r*(e.x-a)-o*(e.y-i),y:i+o*(e.x-a)+r*(e.y-i)}}function u$(e,t){var n=BIe,r=MIe,o=t.origin,a,i,l,s,c;for(a=0;a<e.length;++a)i=e[a],l=i.x-o.x,s=i.y-o.y,c=t.vx*l+t.vy*s,n=Math.min(n,c),r=Math.max(r,c);return{min:n,max:r}}function x0(e,t){var n=t.x-e.x,r=t.y-e.y,o=Math.sqrt(n*n+r*r);return{vx:(t.x-e.x)/o,vy:(t.y-e.y)/o,origin:e,ln:o}}var A$=function(){this._rotation=0,this._rect={x:0,y:0,w:0,h:0}};Ga(A$.prototype,{center:function(){var e=this._rect;return{x:e.x+e.w/2,y:e.y+e.h/2}},update:function(e,t,n){this._rotation=n,this._rect={x:t.x+e.x,y:t.y+e.y,w:t.w,h:t.h}},contains:function(e){var t=this,n=1,r=t._rect;return e=nf(e,t.center(),-t._rotation),!(e.x<r.x-n||e.y<r.y-n||e.x>r.x+r.w+n*2||e.y>r.y+r.h+n*2)},intersects:function(e){var t=this._points(),n=e._points(),r=[x0(t[0],t[1]),x0(t[0],t[3])],o,a,i;for(this._rotation!==e._rotation&&r.push(x0(n[0],n[1]),x0(n[0],n[3])),o=0;o<r.length;++o)if(a=u$(t,r[o]),i=u$(n,r[o]),a.max<i.min||i.max<a.min)return!1;return!0},_points:function(){var e=this,t=e._rect,n=e._rotation,r=e.center();return[nf({x:t.x,y:t.y},r,n),nf({x:t.x+t.w,y:t.y},r,n),nf({x:t.x+t.w,y:t.y+t.h},r,n),nf({x:t.x,y:t.y+t.h},r,n)]}});function f$(e,t,n){var r=t.positioner(e,t),o=r.vx,a=r.vy;if(!o&&!a)return{x:r.x,y:r.y};var i=n.w,l=n.h,s=t.rotation,c=Math.abs(i/2*Math.cos(s))+Math.abs(l/2*Math.sin(s)),d=Math.abs(i/2*Math.sin(s))+Math.abs(l/2*Math.cos(s)),A=1/Math.max(Math.abs(o),Math.abs(a));return c*=o*A,d*=a*A,c+=t.offset*o,d+=t.offset*a,{x:r.x+c,y:r.y+d}}function zIe(e,t){var n,r,o,a;for(n=e.length-1;n>=0;--n)for(o=e[n].$layout,r=n-1;r>=0&&o._visible;--r)a=e[r].$layout,a._visible&&o._box.intersects(a._box)&&t(o,a);return e}function RIe(e){var t,n,r,o,a,i,l;for(t=0,n=e.length;t<n;++t)r=e[t],o=r.$layout,o._visible&&(l=new Proxy(r._el,{get:(s,c)=>s.getProps([c],!0)[c]}),a=r.geometry(),i=f$(l,r.model(),a),o._box.update(i,a,r.rotation()));return zIe(e,function(s,c){var d=s._hidable,A=c._hidable;d&&A||A?c._visible=!1:d&&(s._visible=!1)})}var rf={prepare:function(e){var t=[],n,r,o,a,i;for(n=0,o=e.length;n<o;++n)for(r=0,a=e[n].length;r<a;++r)i=e[n][r],t.push(i),i.$layout={_box:new A$,_hidable:!1,_visible:!0,_set:n,_idx:i._index};return t.sort(function(l,s){var c=l.$layout,d=s.$layout;return c._idx===d._idx?d._set-c._set:d._idx-c._idx}),this.update(t),t},update:function(e){var t=!1,n,r,o,a,i;for(n=0,r=e.length;n<r;++n)o=e[n],a=o.model(),i=o.$layout,i._hidable=a&&a.display==="auto",i._visible=o.visible(),t|=i._hidable;t&&RIe(e)},lookup:function(e,t){var n,r;for(n=e.length-1;n>=0;--n)if(r=e[n].$layout,r&&r._visible&&r._box.contains(t))return e[n];return null},draw:function(e,t){var n,r,o,a,i,l;for(n=0,r=t.length;n<r;++n)o=t[n],a=o.$layout,a._visible&&(i=o.geometry(),l=f$(o._el,o.model(),i),a._box.update(l,i,o.rotation()),o.draw(e,l))}},HIe=function(e){if(rr(e))return null;var t=e,n,r,o;if(un(e))if(!rr(e.label))t=e.label;else if(!rr(e.r))t=e.r;else for(t="",n=Object.keys(e),o=0,r=n.length;o<r;++o)t+=(o!==0?", ":"")+n[o]+": "+e[n[o]];return""+t},jIe={align:"center",anchor:"center",backgroundColor:null,borderColor:null,borderRadius:0,borderWidth:0,clamp:!1,clip:!1,color:void 0,display:!0,font:{family:void 0,lineHeight:1.2,size:void 0,style:void 0,weight:null},formatter:HIe,labels:void 0,listeners:{},offset:4,opacity:1,padding:{top:4,right:4,bottom:4,left:4},rotation:0,textAlign:"start",textStrokeColor:void 0,textStrokeWidth:0,textShadowBlur:0,textShadowColor:void 0},uo="$datalabels",g$="$default";function _Ie(e,t){var n=e.datalabels,r={},o=[],a,i;return n===!1?null:(n===!0&&(n={}),t=Ga({},[t,n]),a=t.labels||{},i=Object.keys(a),delete t.labels,i.length?i.forEach(function(l){a[l]&&o.push(Ga({},[t,a[l],{_key:l}]))}):o.push(t),r=o.reduce(function(l,s){return Cn(s.listeners||{},function(c,d){l[d]=l[d]||{},l[d][s._key||g$]=c}),delete s.listeners,l},{}),{labels:o,listeners:r})}function w1(e,t,n,r){if(t){var o=n.$context,a=n.$groups,i;t[a._set]&&(i=t[a._set][a._key],i&&Tn(i,[o,r])===!0&&(e[uo]._dirty=!0,n.update(o)))}}function $Ie(e,t,n,r,o){var a,i;!n&&!r||(n?r?n!==r&&(i=a=!0):i=!0:a=!0,i&&w1(e,t.leave,n,o),a&&w1(e,t.enter,r,o))}function kIe(e,t){var n=e[uo],r=n._listeners,o,a;if(!(!r.enter&&!r.leave)){if(t.type==="mousemove")a=rf.lookup(n._labels,t);else if(t.type!=="mouseout")return;o=n._hovered,n._hovered=a,$Ie(e,r,o,a,t)}}function LIe(e,t){var n=e[uo],r=n._listeners.click,o=r&&rf.lookup(n._labels,t);o&&w1(e,r,o,t)}var FIe={id:"datalabels",defaults:jIe,beforeInit:function(e){e[uo]={_actives:[]}},beforeUpdate:function(e){var t=e[uo];t._listened=!1,t._listeners={},t._datasets=[],t._labels=[]},afterDatasetUpdate:function(e,t,n){var r=t.index,o=e[uo],a=o._datasets[r]=[],i=e.isDatasetVisible(r),l=e.data.datasets[r],s=_Ie(l,n),c=t.meta.data||[],d=e.ctx,A,f,g,v,p,m,h,b;for(d.save(),A=0,g=c.length;A<g;++A)if(h=c[A],h[uo]=[],i&&h&&e.getDataVisibility(A)&&!h.skip)for(f=0,v=s.labels.length;f<v;++f)p=s.labels[f],m=p._key,b=new d$(p,d,h,A),b.$groups={_set:r,_key:m||g$},b.$context={active:!1,chart:e,dataIndex:A,dataset:l,datasetIndex:r},b.update(b.$context),h[uo].push(b),a.push(b);d.restore(),Ga(o._listeners,s.listeners,{merger:function(C,y,x){y[C]=y[C]||{},y[C][t.index]=x[C],o._listened=!0}})},afterUpdate:function(e){e[uo]._labels=rf.prepare(e[uo]._datasets)},afterDatasetsDraw:function(e){rf.draw(e,e[uo]._labels)},beforeEvent:function(e,t){if(e[uo]._listened){var n=t.event;switch(n.type){case"mousemove":case"mouseout":kIe(e,n);break;case"click":LIe(e,n);break}}},afterEvent:function(e){var t=e[uo],n=t._actives,r=t._actives=e.getActiveElements(),o=tf.arrayDiff(n,r),a,i,l,s,c,d,A;for(a=0,i=o.length;a<i;++a)if(c=o[a],c[1])for(A=c[0].element[uo]||[],l=0,s=A.length;l<s;++l)d=A[l],d.$context.active=c[1]===1,d.update(d.$context);(t._dirty||o.length)&&(rf.update(t._labels),e.render()),delete t._dirty}};const E1={card:"_card_16ceq_24",header:"_header_16ceq_33",chartWrap:"_chartWrap_16ceq_44"};u0.register(Ed,uIe,rIe,FIe);function WIe({title:e=yr.DEFAULT_TITLE,data:t,colors:n,height:r=300,info:o}){const a=(c,d)=>Array.isArray(n)?n[c%n.length]:(n==null?void 0:n[d])??yr.PALETTE[c%yr.PALETTE.length],i=t.filter(c=>Number(c.percentage)>0),l={labels:i.map(c=>c.label),datasets:[{data:i.map(c=>Number(c.percentage)),backgroundColor:i.map((c,d)=>a(d,c.key)),borderWidth:yr.BORDER_WIDTH}]},s={cutout:yr.CUTOUT,maintainAspectRatio:!1,layout:{padding:12},plugins:{legend:{position:yr.LEGEND_POSITION,labels:{usePointStyle:!0,pointStyle:yr.POINT_STYLE,padding:12,filter:(c,d)=>{var v,p;const A=c.index??0,f=(v=d.datasets)==null?void 0:v[0];return Number(((p=f==null?void 0:f.data)==null?void 0:p[A])??0)>0}}},tooltip:{callbacks:{label:c=>{const d=c.dataIndex,A=Number(c.parsed??0);if(A<=0)return"";const f=i[d],g=(f==null?void 0:f.label)??"",v=(f==null?void 0:f.count)??0;return`${g}: ${A}${yr.PCT} ${yr.LPAREN}${v.toLocaleString()}${yr.RPAREN}`}}},datalabels:{formatter:(c,d)=>{var p,m,h;const A=d.dataIndex,f=Number(((h=(m=(p=d.chart.data.datasets)==null?void 0:p[0])==null?void 0:m.data)==null?void 0:h[A])??0);if(f<=0)return"";const g=i[A],v=(g==null?void 0:g.count)??0;return`${f}${yr.PCT}${yr.NEWLINE}${yr.LPAREN}${v.toLocaleString()}${yr.RPAREN}`},color:yr.LABEL_COLOR,align:yr.ALIGN,anchor:yr.ANCHOR,clip:!0,clamp:!0,font:{weight:500}}}};return B.jsxs("div",{className:E1.card,style:{height:`${r}px`},children:[B.jsxs("div",{className:E1.header,children:[B.jsx("span",{children:e}),o&&B.jsx(Fl,{content:o,placement:Dd.TOP_RIGHT,children:B.jsx("img",{src:g_,alt:yr.INFO})})]}),B.jsx("div",{className:E1.chartWrap,children:B.jsx(CIe,{data:l,options:s})})]})}Te.Accordian=fEe,Te.ActionType=Id,Te.AgencyDocumentCard=mEe,Te.AgencyJobCard=oEe,Te.Align=Od,Te.AllowedCountries=z1,Te.ApplicationHeader=wxe,Te.AuthBanner=ICe,Te.AuthBannerTextType=SB,Te.AuthForm=MCe,Te.AvatarSize=eo,Te.AvatarWithDetailsCard=ese,Te.AvatarWithInitials=Uu,Te.Badge=qu,Te.BadgeType=N1,Te.Bookmark=nEe,Te.Button=Xx,Te.ButtonType=zs,Te.Calendar=cq,Te.Card=Fle,Te.CardStats=QSe,Te.CardWithIconAndText=kCe,Te.ChatDetails=$Se,Te.ChatList=kSe,Te.CheckBoxWithFormWrapper=Hxe,Te.Checkbox=NB,Te.CheckboxGroup=TB,Te.CheckboxSelectField=Cxe,Te.Colors=zo,Te.ColumnSortOrder=EB,Te.CustomAvatar=yo,Te.CustomModal=dEe,Te.CustomModalTypes=Wc,Te.DOM_ELEMENT_ROLE=kx,Te.DashboardCard=Gwe,Te.DashboardStats=JSe,Te.DatePicker=Zse,Te.Disclaimer=mxe,Te.DocVerificationStatus=Qu,Te.DocumentCard=YB,Te.DocumentStatus=gse,Te.DocumentStatusEnum=lf,Te.DocumentView=mse,Te.Drawer=qse,Te.Dropdown=Tm,Te.EllipsisWithTooltip=ci,Te.Error=Ro,Te.FileUpload=bse,Te.FileUploadWithDropdown=_B,Te.FloatingLabel=za,Te.Form=JCe,Te.FormValidationTriggers=xB,Te.GenderProfileEnum=R1,Te.GenderValueEnum=H1,Te.HtmlButtonType=Sd,Te.Icons=vt,Te.InputField=IB,Te.InputTypes=Ni,Te.InputWithCountry=gce,Te.JobCard=eEe,Te.JobTrackingCard=Vwe,Te.JobTypeEnum=_1,Te.Justify=P0,Te.Label=lv,Te.LabelType=Ju,Te.Layout=Qi,Te.ListItem=TS,Te.ListingTableHeader=ij,Te.Loader=Fse,Te.Menu=wu,Te.MenuMode=rv,Te.Modal=$x,Te.ModalTypeEnum=nv,Te.NoData=rj,Te.NoInternetScreen=KB,Te.NoRecords=fxe,Te.Notification=sv,Te.NotificationCard=pce,Te.NotificationPanel=Nse,Te.NotificationTypes=Mi,Te.Offline=$se,Te.Pagination=lEe,Te.Password=rw,Te.PasswordField=rw,Te.PasswordValidation=Axe,Te.PathIcon=Rxe,Te.PieChart=WIe,Te.Placement=Dd,Te.PopoverIconCard=Uwe,Te.PreviewCard=aj,Te.PreviewDocumentsCard=pxe,Te.PreviewModal=Yse,Te.ProfileAssignedCard=nj,Te.ProfileAssignedEmployer=zCe,Te.ProfileAttachments=QCe,Te.ProfileDetail=$Ce,Te.ProfileDetailFooterTypes=ma,Te.RadioGroup=Rse,Te.Rate=Mj,Te.RatingCard=vEe,Te.RatingProgressBar=FSe,Te.RatingStar=sse,Te.RoleManagement=tEe,Te.SearchField=Vx,Te.SearchWithSuggestions=LSe,Te.Segmented=Oxe,Te.Select=jB,Te.SelectType=oa,Te.Sidebar=zse,Te.Size=of,Te.Slider=Sxe,Te.SliderRangeWithForm=kle,Te.SliderWithForm=Wle,Te.SortOrderKeys=wB,Te.SoundEnum=j1,Te.Space=oxe,Te.StatsBanner=ixe,Te.StatusTypes=sf,Te.SummaryCard=el,Te.SwitchComponent=rEe,Te.TImerPicker=iEe,Te.TableComponent=UB,Te.TableLayout=B1,Te.TableType=af,Te.Tabs=hxe,Te.TextArea=Txe,Te.TextAreaWithController=Dxe,Te.Timer=bxe,Te.TitleHeader=axe,Te.TitleHeaderStatus=M1,Te.Tooltip=Jx,Te.Typography=Fc,Te.Upload=wse,Te.UploadWithDropdown=Sse,Te.UserBadge=Ase,Te.UserStatus=Ise,Te.UserType=Yi,Te.VerificationStatus=Pse,Te.VerificationTypes=Pd,Te.formatTimeAgo=$le,Te.useForm=cj,Object.defineProperty(Te,Symbol.toStringTag,{value:"Module"})});
|