chartjs-chart-treemap 5.0.0-next.4 → 5.0.0-next.5

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.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * chartjs-chart-treemap v5.0.0-next.4
2
+ * chartjs-chart-treemap v5.0.0-next.5
3
3
  * https://chartjs-chart-treemap.pages.dev/
4
4
  * (c) 2026 Jukka Kurkela
5
5
  * Released under the MIT license
@@ -10,7 +10,7 @@ typeof define === 'function' && define.amd ? define(['exports', 'chart.js', 'cha
10
10
  (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["chartjs-chart-treemap"] = {}, global.Chart, global.Chart.helpers));
11
11
  })(this, (function (exports, chart_js, helpers) { 'use strict';
12
12
 
13
- var version = "5.0.0-next.4";
13
+ var version = "5.0.0-next.5";
14
14
 
15
15
  function scaleRect(sq, xScale, yScale, sp) {
16
16
  const sp2 = sp * 2;
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * chartjs-chart-treemap v5.0.0-next.4
2
+ * chartjs-chart-treemap v5.0.0-next.5
3
3
  * https://chartjs-chart-treemap.pages.dev/
4
4
  * (c) 2026 Jukka Kurkela
5
5
  * Released under the MIT license
@@ -7,7 +7,7 @@
7
7
  import { DatasetController, registry, Chart, Element } from 'chart.js';
8
8
  import { toTRBL, toTRBLCorners, isObject, defined, isArray, isNumber, toFont, valueOrDefault, clipArea, unclipArea, addRoundedRectPath } from 'chart.js/helpers';
9
9
 
10
- var version = "5.0.0-next.4";
10
+ var version = "5.0.0-next.5";
11
11
 
12
12
  function scaleRect(sq, xScale, yScale, sp) {
13
13
  const sp2 = sp * 2;
@@ -1,8 +1,8 @@
1
1
  /*!
2
- * chartjs-chart-treemap v5.0.0-next.4
2
+ * chartjs-chart-treemap v5.0.0-next.5
3
3
  * https://chartjs-chart-treemap.pages.dev/
4
4
  * (c) 2026 Jukka Kurkela
5
5
  * Released under the MIT license
6
6
  */
7
- !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("chart.js"),require("chart.js/helpers")):"function"==typeof define&&define.amd?define(["exports","chart.js","chart.js/helpers"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self)["chartjs-chart-treemap"]={},t.Chart,t.Chart.helpers)}(this,function(t,e,n){"use strict";function i(t,e,n,i){const r=2*i,o=e.getPixelForValue(t.x),s=n.getPixelForValue(t.y),a=e.getPixelForValue(t.x+t.w)-o,h=n.getPixelForValue(t.y+t.h)-s;return{height:h-r,hidden:r>a||r>h,width:a-r,x:o+i,y:s+i}}const r={displayMode:"containerBoxes",rtl:!1,spacing:.5};function o(t,e,n){return Math.max(Math.min(t,n),e)}function s(t,e,i){const r=n.toTRBL(t);return{b:o(r.bottom,0,i),l:o(r.left,0,e),r:o(r.right,0,e),t:o(r.top,0,i)}}function a(t,e,n,i){const r=t._normalized,o=e*r/n,s=Math.sqrt(r*o),a=r/s;return{d1:s,d2:a,h:"_ix"===i?a:s,w:"_ix"===i?s:a}}function h(t,e,n,i){e.a=e._normalized,e.h=n.h,e.s=i,e.w=n.w,e.x=((t,e)=>t.rtl?t.x+t.iw-e:t.x+t._ix)(t,n.w),e.y=t.y+t._iy,delete e._normalized}class l{get area(){return this.w*this.h}get iw(){return this.w-this._ix}get ih(){return this.h-this._iy}get dir(){const t=this.ih;return t<=this.iw&&t>0?"y":"x"}get side(){return"x"===this.dir?this.iw:this.ih}map(t){const{dir:e,side:n}=this,i="x"===e?"_ix":"_iy",r=t.nsum,o=t.get(),s=n*n,l=r*r;let c=0,u=0;for(const e of o){const n=a(e,s,l,i);u+=n.d1,c=Math.max(c,n.d2),h(this,e,n,t.sum),this[i]+=n.d1}this["x"===e?"_iy":"_ix"]+=c,this[i]-=u}constructor(t){t=t||{h:1,w:1},this.rtl=!!t.rtl,this.unsorted=!!t.unsorted,this.x=t.x||t.left||0,this.y=t.y||t.top||0,this._ix=0,this._iy=0,this.w=t.w||t.width||t.right-t.left,this.h=t.h||t.height||t.bottom-t.top}}const c=Math.min,u=Math.max;function d(t,e){const n=+e[t.key],i=n*t.ratio;return e._normalized=i,{max:u(t.max,n),min:c(t.min,n),nmax:u(t.nmax,i),nmin:c(t.nmin,i),nsum:t.nsum+i,sum:t.sum+n}}function f(t,e,n){t._arr.push(e),function(t,e){Object.assign(t,e)}(t,n)}class p{get length(){return this._arr.length}reset(){this._arr=[],this._hist=[],this.sum=0,this.nsum=0,this.min=1/0,this.max=-1/0,this.nmin=1/0,this.nmax=-1/0}push(t){f(this,t,d(this,t))}pushIf(t,e,...n){const i=d(this,t);if(!e((r=this,{max:r.max,min:r.min,nmax:r.nmax,nmin:r.nmin,nsum:r.nsum,sum:r.sum}),i,n))return t;var r;f(this,t,i)}get(){return this._arr}constructor(t,e){this._arr=[],this._hist=[],this.sum=0,this.nsum=0,this.min=1/0,this.max=-1/0,this.nmin=1/0,this.nmax=-1/0,this.key=t,this.ratio=e,this.reset()}}const g=(t,e)=>e>t||t.length>e.length&&t.startsWith(e),m=t=>String(t),x=t=>null!=t&&""!==t;function y(t,e,i,r=[],o=0,s=[]){const a=o-1;if(t[0]in i&&o>0){const n=r.reduce((t,e,n)=>(n!==a&&(t[m(n)]=e),t),{});n[e]=r[a],t.forEach(t=>{n[t]=i[t]}),s.push(n)}else for(const a of Object.keys(i)){const h=i[a];n.isObject(h)&&(r.push(a),y(t,e,h,r,o+1,s))}return r.splice(a,1),s}function b(t,e,n){const i=y(t,e,n);if(!i.length)return i;const r=i.reduce((t,e)=>{const n=Object.keys(e).length-2;return Math.max(t,n)},0);return i.forEach(t=>{for(let e=0;e<r;e++){const n=m(e);t[n]||(t[n]="")}}),i}function w(t,e,n){const i=[];for(const n of t){const t=e[n];x(t)&&i.push(t)}return i.length?i.join("."):n}function v(t,e,n,i){for(let e=i;e<n.length;e++){const i=m(n[e]);if(x(t[i]))return{group:i,groupIndex:e,value:t[i]}}if(x(t[e]))return{group:e,groupIndex:i,value:t[e]}}function _(t,e,n,i){if(n in t)return;t[n]={value:0};const r=t[n];i.forEach(t=>{r[t]=0}),e[n]=[]}function M(t,e,n,i,r,o,s=[],a=s,h=s.length-1){const l=n[0],c=n.slice(1),u=Object.create(null),d=Object.create(null),f=[],p=a.length?a:[e],g=a.length?h:0;let m,x;for(m=0,x=t.length;m<x;++m){const e=t[m];if(r&&e[r]!==o)continue;const n=v(e,i,p,g);if(!n)return[];const s=n.value;_(u,d,s,c),u[s].value+=+e[l],u[s].label=s,u[s].group=n.group,u[s].groupIndex=n.groupIndex;const a=u[s];c.forEach(t=>{a[t]+=e[t]}),u[s].path=w(p.slice(0,n.groupIndex+1),e,s),d[s].push(e)}return Object.keys(u).forEach(t=>{const n={children:d[t]};n[l]=+u[t].value,c.forEach(e=>{n[e]=+u[t][e]}),n[e]=u[t].label,n.group=u[t].group,n.groupIndex=u[t].groupIndex,n.label=t,n.path=u[t].path,r&&(n[r]=o),f.push(n)}),f}function C(t,e){let i,r=t.length;if(!r)return e;const o=n.isObject(t[0]);for(e=o?e:"v",i=0,r=t.length;i<r;++i)o?t[i]._idx=i:t[i]={_idx:i,v:t[i]};return e}function O(t,e){e?t.sort((t,n)=>+n[e]-+t[e]):t.sort((t,e)=>+e-+t)}function j(t,e){let n,i,r;for(n=0,i=0,r=t.length;i<r;++i)n+=e?+t[i][e]:+t[i];return n}function R(t,e,n,i=!0){const r=n.split(".");let o=0;for(const s of e.split(".")){const a=r[o++];if(Number.parseInt(s,10)<Number.parseInt(a,10))break;if(g(a,s)){if(i)throw new Error(`${t} v${n} is not supported. v${e} or newer is required.`);return!1}}return!0}function P(t,e,n){if(0===t.sum)return!0;const[i]=n,r=t.nsum*t.nsum,o=e.nsum*e.nsum,s=i*i,a=Math.max(s*t.nmax/r,r/(s*t.nmin));return Math.max(s*e.nmax/o,o/(s*e.nmin))<=a}function k(t,e,n,i){const r=t?t.slice():[],o=C(r,e[0]);return r.map(r=>{const s={_data:t[r._idx],v:o?+r[o]:+r,vs:void 0};return n&&(s.g=r[n],s.gs=void 0,s.l=r.groupIndex??i,s.vs=e.reduce((t,e)=>(t[e]=+r[e],t),{})),s})}function E(t){O(t,"v")}const L=new Map;function T(t,e,i){if(!i||!1===i.display)return!1;if("headerBoxes"===t)return!0;const{w:r,h:o}=e,s=n.toFont(i.font||{}).lineHeight,a=Math.max(Math.min(2*n.valueOrDefault(i.padding,3),Math.min(r,o)),0);return r-a>s&&o-a>s}function D(t,e,n,i){if("headerBoxes"!==t)return n.lineHeight+2*i;const r=n.lineHeight+2*i;return e.h<2*r?e.h/3:r}function I(t,e,i,r,o,s){const{captions:a,labels:h}=i,{displayMode:l}=s;let c;r&&(!n.defined(r.l)||r.isLeaf)?h.display&&(c=function(t,e,i,r,o){const s=i.labels,a=$(s.formatter,F(o,r));if(!a)return;const h=n.isArray(a)?a:[a];let l=function(t,e){const{font:i,hoverFont:r}=e,o=(t.active?r:i)||i;return Array.isArray(o)?o.map(t=>n.toFont(t)):[n.toFont(o)]}(e,s),c=A(t,h,l);const u=function(t,e,n){const{overflow:i,padding:r}=e,{width:o,height:s}=n;if("hidden"===i)return!(o+2*r>t.w||s+2*r>t.h);if("fit"===i){const e=Math.min(t.w/(o+2*r),t.h/(s+2*r));if(e<1)return e}return!0}(e,s,c);if(!u)return;n.isNumber(u)&&(c={height:c.height*u,width:c.width*u},l=function(t,e){return t.map(t=>{const{lineHeight:i,...r}=t;return n.toFont({...r,size:Math.floor(t.size*e)})})}(l,u));const{color:d,hoverColor:f,align:p,padding:g}=s,m=(e.active?f:d)||d;return{align:p,colors:n.isArray(m)?m:[m],fonts:l,lines:h,padding:g,top:S(e,s,c)}}(t,e,i,r,o)):T(l,e,a)&&(c=function(t,e,i,r,o,s){const{displayMode:a,rtl:h,spacing:l}=s,{captions:c}=i,{color:u,hoverColor:d,font:f,hoverFont:p,padding:g,align:m}=c,x=(e.active?p:f)||f,y=n.toFont(x);if(y.lineHeight>e.h)return;let b=function(t,e,n){return $(t.formatter,F(e,n))||n.g||""}(c,o,r);if(!b)return;const w=[y];A(t,[b],w).width+2*g>e.w&&(b=function(t,e,n,i){const r="...",o=A(t,[r],i).width;if(o>=n)return"";let s,a=1,h=e.length;for(;a<=h;){const r=Math.floor((a+h)/2);s=A(t,[e.slice(0,r)],i).width,s+o>n?h=r-1:a=r+1}const l=e.slice(0,Math.max(0,a-1));return l?l+r:""}(t,b,e.w-2*g,w));const v="headerBoxes"===a?e.y+(e.h-y.lineHeight)/2:e.y+g+l;return{align:m||(h?"right":"left"),colors:[(e.active?d:u)||u],fonts:w,lines:[b],padding:g,top:v}}(t,e,i,r,o,s)),c&&(t.save(),t.beginPath(),t.rect(e.x,e.y,e.w,e.h),t.clip(),function(t,e,n){const{align:i,colors:r,fonts:o,lines:s,padding:a,top:h}=n,l=function(t,e,n){if("left"===e)return t.x+n;if("right"===e)return t.x+t.w-n;return t.x+t.w/2}(e,i,a);t.textAlign=i,t.textBaseline="middle";let c=0;s.forEach((e,n)=>{const i=o[Math.min(n,o.length-1)];t.font=i.string,t.fillStyle=r[Math.min(n,r.length-1)],t.fillText(e,l,h+c+i.lineHeight/2),c+=i.lineHeight})}(t,e,c),t.restore())}function F(t,e){const n=t.$context||{active:!!t.active,raw:e,type:"data"};return n.active=!!t.active,n.raw=e,n}function $(t,e){return"function"==typeof t?t(e):t}function A(t,e,n){const i=n.reduce((t,e)=>t+=e.string,""),r=e.join()+i+(t._measureText?"-spriting":"");let o=L.get(r);if(!o){t.save();const i=e.length;let s=0,a=0;for(let r=0;r<i;r++){const i=n[Math.min(r,n.length-1)];t.font=i.string;const o=e[r];s=Math.max(s,t.measureText(o).width),a+=i.lineHeight}t.restore(),o={height:a,width:s},L.set(r,o)}return o}function S(t,e,n){const{position:i,padding:r}=e;return"top"===i?t.y+r:"bottom"===i?t.y+t.h-r-n.height:t.y+(t.h-n.height)/2+r}function B(t,e,n,i,r){const{groups:o,leafKey:s,unsorted:a}=i,h=o.length,l=m(o[e]),c=M(t,l,n,s,void 0,r,o.filter((t,n)=>n<=e),o,e),u=k(c,n,l,e);a||E(u);for(const t of u){const r=t._data,o=r.groupIndex+1,s=e<h-1&&o<h?B(r.children,o,n,i,t.g):[];Object.defineProperty(t,"_children",{configurable:!0,value:s,writable:!0}),t.isLeaf=!s.length}return u}function z(t){const e=t.slice();for(const n of t)n._children?.length&&e.push(...z(n._children));return e}function H(t,e,n,i){if(void 0!==i)for(const e of t)e.gs=i;!function(t,e){const n=t.length;if(!n)return;const i=new l(e),r=new p("v",i.area/j(t,"v"));let o,s=i.side;for(let e=0;e<n;++e)o=r.pushIf(t[e],P,s),o&&(i.map(r),s=i.side,r.reset(),r.push(o));r.length&&i.map(r)}(t,e);for(const i of t)i._children?.length&&H(i._children,V(i,e,n),n,i.s)}function K(t,e,i){H(t,e,i),function(t,e){const{captions:i,displayMode:r}=e;if("headerBoxes"!==r)return;const o=n.toFont(i.font),s=n.valueOrDefault(i.padding,3);for(const e of t)e.isLeaf||(T(r,e,i)?(e.h=D(r,e,o,s),e.hidden=!1):e.hidden=!0)}(z(t),i)}function V(t,e,i){const{borderWidth:r,captions:o,displayMode:a}=i,h="headerBoxes"===a?0:i.spacing,l="headerBoxes"===a?{b:0,l:0,r:0,t:0}:s(r,t.w/2,t.h/2),c={...e,h:t.h-2*h-l.t-l.b,w:t.w-2*h-l.l-l.r,x:t.x+h+l.l,y:t.y+h+l.t};if(T(a,c,o)){const t=D(a,c,n.toFont(o.font),n.valueOrDefault(o.padding,3));c.y+=t,c.h-=t}return c}function W(t,e,i){const{groups:r,leafKey:o,unsorted:s}=i,a=n.isObject(t)?b(e,o,t):t;if(r.length)return B(a,0,e,i);const h=k(a||[],e);return s||E(h),h}function q(){const t=e.registry.plugins.get("tooltip");t&&!t.positioners.treemap&&(t.positioners.treemap=t=>{if(!t.length)return!1;return t.at(-1).element.tooltipPosition()})}class N extends e.DatasetController{initialize(){q(),this.enableOptionSharing=!0,super.initialize()}getMinMax(t){return{max:"x"===t.axis?t.right-t.left:t.bottom-t.top,min:0}}configure(){super.configure();const{xScale:t,yScale:e}=this.getMeta();if(!t||!e)return;const n=t.right-t.left,i=e.bottom-e.top,r={h:i,rtl:!!this.options.rtl,unsorted:!!this.options.unsorted,w:n,x:0,y:0};var o,s;o=this._rect,s=r,o&&s&&o.x===s.x&&o.y===s.y&&o.w===s.w&&o.h===s.h&&o.rtl===s.rtl&&o.unsorted===s.unsorted||(this._rect=r,this._rectChanged=!0),this._rectChanged&&(t.max=n,t.configure(),e.max=i,e.configure())}_layoutOptions(){const t=this.getDataset(),e=this.options;return{borderWidth:t.borderWidth,captions:t.captions||{},displayMode:e.displayMode,groups:e.groups||[],leafKey:e.leafKey,spacing:n.valueOrDefault(t.spacing,0),unsorted:!!e.unsorted}}buildOrUpdateElements(t){this.parse(0,0);const e=this.getMeta(),n=e._parsed.length,i=e.data;for(i.length>n&&i.splice(n,i.length-n);i.length<n;)i.push(new this.dataElementType)}parse(t,e){const n=this.getDataset();if(void 0!==n.tree)throw new Error('chartjs-chart-treemap v5: the "tree" option was renamed to "data". See https://chartjs-chart-treemap.pages.dev/usage/');const i=this.options,r=[i.key||""].concat(i.sumKeys||[]),o=W(n.data||[],r,this._layoutOptions()),s=z(o),a=s.map(t=>`${t.v}\0${t.g}\0${t.l}`).join("");this._fingerprint!==a&&(this._fingerprint=a,this._nodes=o,this.getMeta()._parsed=s,this._layoutDirty=!0)}getContext(t,n,i){const r=e.DatasetController.prototype.getContext.call(this,t,n,i),o="number"==typeof t?this.getParsed(t):void 0;return o&&(r.raw=o,r.parsed=o),r}getLabelAndValue(t){const e=this.getParsed(t);if(!e)return{label:"",value:""};const n=this.getDataset(),i=e.g??e._data?.label??n.label;return{label:void 0===i?"":`${i}`,value:`${e.v}`}}update(t){const{data:e}=this.getMeta();"reset"===t&&this.configure(),(this._layoutDirty||this._rectChanged)&&(K(this._nodes,this._rect,this._layoutOptions()),this._layoutDirty=!1,this._rectChanged=!1),this.updateElements(e,0,e.length,t)}updateElements(t,e,n,r){const o="reset"===r,s=this.resolveDataElementOptions(e,r);this._rect.options=s;const a=this.getSharedOptions(s),h=this.includeOptions(r,a||{}),{xScale:l,yScale:c}=this.getMeta(),u=this.options.spacing;for(let s=e;s<e+n;s++){const e=a||this.resolveDataElementOptions(s,r),n=this.getParsed(s),d=i(n,l,c,u);d.hidden=d.hidden||!!n.hidden,o&&(d.width=0,d.height=0),h&&(d.options=e),this.updateElement(t[s],s,d,r)}this.updateSharedOptions(a||{},r,s)}draw(){const{ctx:t,chartArea:e}=this.chart,i=this.getMeta().data||[],{displayMode:r,rtl:o,spacing:s}=this.options,a={displayMode:r,rtl:o,spacing:s};n.clipArea(t,e);for(let e=0,n=i.length;e<n;++e){const n=i[e];n.hidden||n.draw(t,this.getParsed(e),a)}n.unclipArea(t)}constructor(t,e){super(t,e),this._rect=void 0,this._rectChanged=!0,this._nodes=[],this._layoutDirty=!0,this._fingerprint=void 0}}function U(t,e){const{x:n,y:i,width:r,height:o}=t.getProps(["x","y","width","height"],e);return{bottom:i+o,left:n,right:n+r,top:i}}function G(t){const e=U(t),i=e.right-e.left,r=e.bottom-e.top,a=s(t.options.borderWidth,i/2,r/2),h=function(t,e,i){const r=n.toTRBLCorners(t),s=Math.min(e,i);return{bottomLeft:o(r.bottomLeft,0,s),bottomRight:o(r.bottomRight,0,s),topLeft:o(r.topLeft,0,s),topRight:o(r.topRight,0,s)}}(t.options.borderRadius,i/2,r/2),l={active:t.active,h:r,radius:h,w:i,x:e.left,y:e.top};return{inner:{active:t.active,h:l.h-a.t-a.b,radius:{bottomLeft:Math.max(0,h.bottomLeft-Math.max(a.b,a.l)),bottomRight:Math.max(0,h.bottomRight-Math.max(a.b,a.r)),topLeft:Math.max(0,h.topLeft-Math.max(a.t,a.l)),topRight:Math.max(0,h.topRight-Math.max(a.t,a.r))},w:l.w-a.l-a.r,x:l.x+a.l,y:l.y+a.t},outer:l}}function X(t,e,n,i){const r=null===e,o=null===n,s=!(!t||r&&o)&&U(t,i);return s&&(r||e>=s.left&&e<=s.right)&&(o||n>=s.top&&n<=s.bottom)}function Y(t,e){t.rect(e.x,e.y,e.w,e.h)}N.id="treemap",N.version="5.0.0-next.4",N.defaults={animations:{numbers:{properties:["x","y","width","height"],type:"number"}},dataElementType:"treemap",displayMode:r.displayMode,groups:[],key:"",leafKey:"_leaf",rtl:r.rtl,spacing:r.spacing,sumKeys:[],unsorted:!1},N.descriptors={_indexable:!1,_scriptable:!0,captions:{_fallback:!0,_scriptable:t=>"formatter"!==t},labels:{_fallback:!0,_scriptable:t=>"formatter"!==t}},N.overrides={hover:{},interaction:{includeInvisible:!0,intersect:!0,mode:"point"},plugins:{tooltip:{callbacks:{label(t){const e=t.parsed,n=e.g||e._data?.label||t.dataset.label;return(n?`${n}: `:"")+e.v},title(t){if(t.length){return t[0].dataset.key||""}return""}},intersect:!0,position:"treemap"}},scales:{x:{alignToPixels:!0,bounds:"data",display:!1,type:"linear"},y:{alignToPixels:!0,bounds:"data",display:!1,reverse:!0,type:"linear"}}},N.beforeRegister=()=>{R("chart.js","4.0",e.Chart.version)},N.afterRegister=()=>{q()},N.afterUnregister=()=>{const t=e.registry.plugins.get("tooltip");t&&delete t.positioners.treemap};class J extends e.Element{draw(t,e,i=r){if(!e)return;const o=this.options,{inner:s,outer:a}=G(this),h=(l=a.radius).topLeft||l.topRight||l.bottomLeft||l.bottomRight?n.addRoundedRectPath:Y;var l;t.save(),a.w===s.w&&a.h===s.h||(t.beginPath(),h(t,a),t.clip(),h(t,s),t.fillStyle=o.borderColor,t.fill("evenodd")),t.beginPath(),h(t,s),t.fillStyle=o.backgroundColor,t.fill(),I(t,s,o,e,this,i),t.restore()}inRange(t,e,n){return X(this,t,e,n)}inXRange(t,e){return X(this,t,null,e)}inYRange(t,e){return X(this,null,t,e)}getCenterPoint(t){const{x:e,y:n,width:i,height:r}=this.getProps(["x","y","width","height"],t);return{x:e+i/2,y:n+r/2}}tooltipPosition(){return this.getCenterPoint()}constructor(t){super(),this.width=void 0,this.height=void 0,t&&Object.assign(this,t)}}J.id="treemap",J.defaults={borderRadius:0,borderWidth:0,captions:{align:void 0,color:"black",display:!0,font:{},formatter:t=>{const e=t.raw._data?.label;return t.raw.g||("string"==typeof e?e:"")},padding:3},labels:{align:"center",color:"black",display:!1,font:{},formatter(t){const e=t.raw._data?.label;return t.raw.g?[t.raw.g,`${t.raw.v}`]:"string"==typeof e?[e,`${t.raw.v}`]:`${t.raw.v}`},overflow:"cut",padding:3,position:"middle"}},J.descriptors={_indexable:!1,_scriptable:!0,captions:{_fallback:!0,_scriptable:t=>"formatter"!==t},labels:{_fallback:!0,_scriptable:t=>"formatter"!==t}},J.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"},e.Chart.register(N,J),t.TreemapController=N,t.TreemapElement=J,t.flatten=function(t){const e=[...t],n=[];for(;e.length;){const t=e.pop();Array.isArray(t)?e.push(...t):n.push(t)}return n.reverse()},t.flattenTree=function(t,e,n){return b(e,n,t)},t.getGroupKey=m,t.group=M,t.index=C,t.normalizeTreeToArray=b,t.requireVersion=R,t.sort=O,t.sum=j});
7
+ !function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("chart.js"),require("chart.js/helpers")):"function"==typeof define&&define.amd?define(["exports","chart.js","chart.js/helpers"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self)["chartjs-chart-treemap"]={},t.Chart,t.Chart.helpers)}(this,function(t,e,n){"use strict";function i(t,e,n,i){const r=2*i,o=e.getPixelForValue(t.x),s=n.getPixelForValue(t.y),a=e.getPixelForValue(t.x+t.w)-o,h=n.getPixelForValue(t.y+t.h)-s;return{height:h-r,hidden:r>a||r>h,width:a-r,x:o+i,y:s+i}}const r={displayMode:"containerBoxes",rtl:!1,spacing:.5};function o(t,e,n){return Math.max(Math.min(t,n),e)}function s(t,e,i){const r=n.toTRBL(t);return{b:o(r.bottom,0,i),l:o(r.left,0,e),r:o(r.right,0,e),t:o(r.top,0,i)}}function a(t,e,n,i){const r=t._normalized,o=e*r/n,s=Math.sqrt(r*o),a=r/s;return{d1:s,d2:a,h:"_ix"===i?a:s,w:"_ix"===i?s:a}}function h(t,e,n,i){e.a=e._normalized,e.h=n.h,e.s=i,e.w=n.w,e.x=((t,e)=>t.rtl?t.x+t.iw-e:t.x+t._ix)(t,n.w),e.y=t.y+t._iy,delete e._normalized}class l{get area(){return this.w*this.h}get iw(){return this.w-this._ix}get ih(){return this.h-this._iy}get dir(){const t=this.ih;return t<=this.iw&&t>0?"y":"x"}get side(){return"x"===this.dir?this.iw:this.ih}map(t){const{dir:e,side:n}=this,i="x"===e?"_ix":"_iy",r=t.nsum,o=t.get(),s=n*n,l=r*r;let c=0,u=0;for(const e of o){const n=a(e,s,l,i);u+=n.d1,c=Math.max(c,n.d2),h(this,e,n,t.sum),this[i]+=n.d1}this["x"===e?"_iy":"_ix"]+=c,this[i]-=u}constructor(t){t=t||{h:1,w:1},this.rtl=!!t.rtl,this.unsorted=!!t.unsorted,this.x=t.x||t.left||0,this.y=t.y||t.top||0,this._ix=0,this._iy=0,this.w=t.w||t.width||t.right-t.left,this.h=t.h||t.height||t.bottom-t.top}}const c=Math.min,u=Math.max;function d(t,e){const n=+e[t.key],i=n*t.ratio;return e._normalized=i,{max:u(t.max,n),min:c(t.min,n),nmax:u(t.nmax,i),nmin:c(t.nmin,i),nsum:t.nsum+i,sum:t.sum+n}}function f(t,e,n){t._arr.push(e),function(t,e){Object.assign(t,e)}(t,n)}class p{get length(){return this._arr.length}reset(){this._arr=[],this._hist=[],this.sum=0,this.nsum=0,this.min=1/0,this.max=-1/0,this.nmin=1/0,this.nmax=-1/0}push(t){f(this,t,d(this,t))}pushIf(t,e,...n){const i=d(this,t);if(!e((r=this,{max:r.max,min:r.min,nmax:r.nmax,nmin:r.nmin,nsum:r.nsum,sum:r.sum}),i,n))return t;var r;f(this,t,i)}get(){return this._arr}constructor(t,e){this._arr=[],this._hist=[],this.sum=0,this.nsum=0,this.min=1/0,this.max=-1/0,this.nmin=1/0,this.nmax=-1/0,this.key=t,this.ratio=e,this.reset()}}const g=(t,e)=>e>t||t.length>e.length&&t.startsWith(e),m=t=>String(t),x=t=>null!=t&&""!==t;function y(t,e,i,r=[],o=0,s=[]){const a=o-1;if(t[0]in i&&o>0){const n=r.reduce((t,e,n)=>(n!==a&&(t[m(n)]=e),t),{});n[e]=r[a],t.forEach(t=>{n[t]=i[t]}),s.push(n)}else for(const a of Object.keys(i)){const h=i[a];n.isObject(h)&&(r.push(a),y(t,e,h,r,o+1,s))}return r.splice(a,1),s}function b(t,e,n){const i=y(t,e,n);if(!i.length)return i;const r=i.reduce((t,e)=>{const n=Object.keys(e).length-2;return Math.max(t,n)},0);return i.forEach(t=>{for(let e=0;e<r;e++){const n=m(e);t[n]||(t[n]="")}}),i}function w(t,e,n){const i=[];for(const n of t){const t=e[n];x(t)&&i.push(t)}return i.length?i.join("."):n}function v(t,e,n,i){for(let e=i;e<n.length;e++){const i=m(n[e]);if(x(t[i]))return{group:i,groupIndex:e,value:t[i]}}if(x(t[e]))return{group:e,groupIndex:i,value:t[e]}}function _(t,e,n,i){if(n in t)return;t[n]={value:0};const r=t[n];i.forEach(t=>{r[t]=0}),e[n]=[]}function M(t,e,n,i,r,o,s=[],a=s,h=s.length-1){const l=n[0],c=n.slice(1),u=Object.create(null),d=Object.create(null),f=[],p=a.length?a:[e],g=a.length?h:0;let m,x;for(m=0,x=t.length;m<x;++m){const e=t[m];if(r&&e[r]!==o)continue;const n=v(e,i,p,g);if(!n)return[];const s=n.value;_(u,d,s,c),u[s].value+=+e[l],u[s].label=s,u[s].group=n.group,u[s].groupIndex=n.groupIndex;const a=u[s];c.forEach(t=>{a[t]+=e[t]}),u[s].path=w(p.slice(0,n.groupIndex+1),e,s),d[s].push(e)}return Object.keys(u).forEach(t=>{const n={children:d[t]};n[l]=+u[t].value,c.forEach(e=>{n[e]=+u[t][e]}),n[e]=u[t].label,n.group=u[t].group,n.groupIndex=u[t].groupIndex,n.label=t,n.path=u[t].path,r&&(n[r]=o),f.push(n)}),f}function C(t,e){let i,r=t.length;if(!r)return e;const o=n.isObject(t[0]);for(e=o?e:"v",i=0,r=t.length;i<r;++i)o?t[i]._idx=i:t[i]={_idx:i,v:t[i]};return e}function O(t,e){e?t.sort((t,n)=>+n[e]-+t[e]):t.sort((t,e)=>+e-+t)}function j(t,e){let n,i,r;for(n=0,i=0,r=t.length;i<r;++i)n+=e?+t[i][e]:+t[i];return n}function R(t,e,n,i=!0){const r=n.split(".");let o=0;for(const s of e.split(".")){const a=r[o++];if(Number.parseInt(s,10)<Number.parseInt(a,10))break;if(g(a,s)){if(i)throw new Error(`${t} v${n} is not supported. v${e} or newer is required.`);return!1}}return!0}function P(t,e,n){if(0===t.sum)return!0;const[i]=n,r=t.nsum*t.nsum,o=e.nsum*e.nsum,s=i*i,a=Math.max(s*t.nmax/r,r/(s*t.nmin));return Math.max(s*e.nmax/o,o/(s*e.nmin))<=a}function k(t,e,n,i){const r=t?t.slice():[],o=C(r,e[0]);return r.map(r=>{const s={_data:t[r._idx],v:o?+r[o]:+r,vs:void 0};return n&&(s.g=r[n],s.gs=void 0,s.l=r.groupIndex??i,s.vs=e.reduce((t,e)=>(t[e]=+r[e],t),{})),s})}function E(t){O(t,"v")}const L=new Map;function T(t,e,i){if(!i||!1===i.display)return!1;if("headerBoxes"===t)return!0;const{w:r,h:o}=e,s=n.toFont(i.font||{}).lineHeight,a=Math.max(Math.min(2*n.valueOrDefault(i.padding,3),Math.min(r,o)),0);return r-a>s&&o-a>s}function D(t,e,n,i){if("headerBoxes"!==t)return n.lineHeight+2*i;const r=n.lineHeight+2*i;return e.h<2*r?e.h/3:r}function I(t,e,i,r,o,s){const{captions:a,labels:h}=i,{displayMode:l}=s;let c;r&&(!n.defined(r.l)||r.isLeaf)?h.display&&(c=function(t,e,i,r,o){const s=i.labels,a=$(s.formatter,F(o,r));if(!a)return;const h=n.isArray(a)?a:[a];let l=function(t,e){const{font:i,hoverFont:r}=e,o=(t.active?r:i)||i;return Array.isArray(o)?o.map(t=>n.toFont(t)):[n.toFont(o)]}(e,s),c=A(t,h,l);const u=function(t,e,n){const{overflow:i,padding:r}=e,{width:o,height:s}=n;if("hidden"===i)return!(o+2*r>t.w||s+2*r>t.h);if("fit"===i){const e=Math.min(t.w/(o+2*r),t.h/(s+2*r));if(e<1)return e}return!0}(e,s,c);if(!u)return;n.isNumber(u)&&(c={height:c.height*u,width:c.width*u},l=function(t,e){return t.map(t=>{const{lineHeight:i,...r}=t;return n.toFont({...r,size:Math.floor(t.size*e)})})}(l,u));const{color:d,hoverColor:f,align:p,padding:g}=s,m=(e.active?f:d)||d;return{align:p,colors:n.isArray(m)?m:[m],fonts:l,lines:h,padding:g,top:S(e,s,c)}}(t,e,i,r,o)):T(l,e,a)&&(c=function(t,e,i,r,o,s){const{displayMode:a,rtl:h,spacing:l}=s,{captions:c}=i,{color:u,hoverColor:d,font:f,hoverFont:p,padding:g,align:m}=c,x=(e.active?p:f)||f,y=n.toFont(x);if(y.lineHeight>e.h)return;let b=function(t,e,n){return $(t.formatter,F(e,n))||n.g||""}(c,o,r);if(!b)return;const w=[y];A(t,[b],w).width+2*g>e.w&&(b=function(t,e,n,i){const r="...",o=A(t,[r],i).width;if(o>=n)return"";let s,a=1,h=e.length;for(;a<=h;){const r=Math.floor((a+h)/2);s=A(t,[e.slice(0,r)],i).width,s+o>n?h=r-1:a=r+1}const l=e.slice(0,Math.max(0,a-1));return l?l+r:""}(t,b,e.w-2*g,w));const v="headerBoxes"===a?e.y+(e.h-y.lineHeight)/2:e.y+g+l;return{align:m||(h?"right":"left"),colors:[(e.active?d:u)||u],fonts:w,lines:[b],padding:g,top:v}}(t,e,i,r,o,s)),c&&(t.save(),t.beginPath(),t.rect(e.x,e.y,e.w,e.h),t.clip(),function(t,e,n){const{align:i,colors:r,fonts:o,lines:s,padding:a,top:h}=n,l=function(t,e,n){if("left"===e)return t.x+n;if("right"===e)return t.x+t.w-n;return t.x+t.w/2}(e,i,a);t.textAlign=i,t.textBaseline="middle";let c=0;s.forEach((e,n)=>{const i=o[Math.min(n,o.length-1)];t.font=i.string,t.fillStyle=r[Math.min(n,r.length-1)],t.fillText(e,l,h+c+i.lineHeight/2),c+=i.lineHeight})}(t,e,c),t.restore())}function F(t,e){const n=t.$context||{active:!!t.active,raw:e,type:"data"};return n.active=!!t.active,n.raw=e,n}function $(t,e){return"function"==typeof t?t(e):t}function A(t,e,n){const i=n.reduce((t,e)=>t+=e.string,""),r=e.join()+i+(t._measureText?"-spriting":"");let o=L.get(r);if(!o){t.save();const i=e.length;let s=0,a=0;for(let r=0;r<i;r++){const i=n[Math.min(r,n.length-1)];t.font=i.string;const o=e[r];s=Math.max(s,t.measureText(o).width),a+=i.lineHeight}t.restore(),o={height:a,width:s},L.set(r,o)}return o}function S(t,e,n){const{position:i,padding:r}=e;return"top"===i?t.y+r:"bottom"===i?t.y+t.h-r-n.height:t.y+(t.h-n.height)/2+r}function B(t,e,n,i,r){const{groups:o,leafKey:s,unsorted:a}=i,h=o.length,l=m(o[e]),c=M(t,l,n,s,void 0,r,o.filter((t,n)=>n<=e),o,e),u=k(c,n,l,e);a||E(u);for(const t of u){const r=t._data,o=r.groupIndex+1,s=e<h-1&&o<h?B(r.children,o,n,i,t.g):[];Object.defineProperty(t,"_children",{configurable:!0,value:s,writable:!0}),t.isLeaf=!s.length}return u}function z(t){const e=t.slice();for(const n of t)n._children?.length&&e.push(...z(n._children));return e}function H(t,e,n,i){if(void 0!==i)for(const e of t)e.gs=i;!function(t,e){const n=t.length;if(!n)return;const i=new l(e),r=new p("v",i.area/j(t,"v"));let o,s=i.side;for(let e=0;e<n;++e)o=r.pushIf(t[e],P,s),o&&(i.map(r),s=i.side,r.reset(),r.push(o));r.length&&i.map(r)}(t,e);for(const i of t)i._children?.length&&H(i._children,V(i,e,n),n,i.s)}function K(t,e,i){H(t,e,i),function(t,e){const{captions:i,displayMode:r}=e;if("headerBoxes"!==r)return;const o=n.toFont(i.font),s=n.valueOrDefault(i.padding,3);for(const e of t)e.isLeaf||(T(r,e,i)?(e.h=D(r,e,o,s),e.hidden=!1):e.hidden=!0)}(z(t),i)}function V(t,e,i){const{borderWidth:r,captions:o,displayMode:a}=i,h="headerBoxes"===a?0:i.spacing,l="headerBoxes"===a?{b:0,l:0,r:0,t:0}:s(r,t.w/2,t.h/2),c={...e,h:t.h-2*h-l.t-l.b,w:t.w-2*h-l.l-l.r,x:t.x+h+l.l,y:t.y+h+l.t};if(T(a,c,o)){const t=D(a,c,n.toFont(o.font),n.valueOrDefault(o.padding,3));c.y+=t,c.h-=t}return c}function W(t,e,i){const{groups:r,leafKey:o,unsorted:s}=i,a=n.isObject(t)?b(e,o,t):t;if(r.length)return B(a,0,e,i);const h=k(a||[],e);return s||E(h),h}function q(){const t=e.registry.plugins.get("tooltip");t&&!t.positioners.treemap&&(t.positioners.treemap=t=>{if(!t.length)return!1;return t.at(-1).element.tooltipPosition()})}class N extends e.DatasetController{initialize(){q(),this.enableOptionSharing=!0,super.initialize()}getMinMax(t){return{max:"x"===t.axis?t.right-t.left:t.bottom-t.top,min:0}}configure(){super.configure();const{xScale:t,yScale:e}=this.getMeta();if(!t||!e)return;const n=t.right-t.left,i=e.bottom-e.top,r={h:i,rtl:!!this.options.rtl,unsorted:!!this.options.unsorted,w:n,x:0,y:0};var o,s;o=this._rect,s=r,o&&s&&o.x===s.x&&o.y===s.y&&o.w===s.w&&o.h===s.h&&o.rtl===s.rtl&&o.unsorted===s.unsorted||(this._rect=r,this._rectChanged=!0),this._rectChanged&&(t.max=n,t.configure(),e.max=i,e.configure())}_layoutOptions(){const t=this.getDataset(),e=this.options;return{borderWidth:t.borderWidth,captions:t.captions||{},displayMode:e.displayMode,groups:e.groups||[],leafKey:e.leafKey,spacing:n.valueOrDefault(t.spacing,0),unsorted:!!e.unsorted}}buildOrUpdateElements(t){this.parse(0,0);const e=this.getMeta(),n=e._parsed.length,i=e.data;for(i.length>n&&i.splice(n,i.length-n);i.length<n;)i.push(new this.dataElementType)}parse(t,e){const n=this.getDataset();if(void 0!==n.tree)throw new Error('chartjs-chart-treemap v5: the "tree" option was renamed to "data". See https://chartjs-chart-treemap.pages.dev/usage/');const i=this.options,r=[i.key||""].concat(i.sumKeys||[]),o=W(n.data||[],r,this._layoutOptions()),s=z(o),a=s.map(t=>`${t.v}\0${t.g}\0${t.l}`).join("");this._fingerprint!==a&&(this._fingerprint=a,this._nodes=o,this.getMeta()._parsed=s,this._layoutDirty=!0)}getContext(t,n,i){const r=e.DatasetController.prototype.getContext.call(this,t,n,i),o="number"==typeof t?this.getParsed(t):void 0;return o&&(r.raw=o,r.parsed=o),r}getLabelAndValue(t){const e=this.getParsed(t);if(!e)return{label:"",value:""};const n=this.getDataset(),i=e.g??e._data?.label??n.label;return{label:void 0===i?"":`${i}`,value:`${e.v}`}}update(t){const{data:e}=this.getMeta();"reset"===t&&this.configure(),(this._layoutDirty||this._rectChanged)&&(K(this._nodes,this._rect,this._layoutOptions()),this._layoutDirty=!1,this._rectChanged=!1),this.updateElements(e,0,e.length,t)}updateElements(t,e,n,r){const o="reset"===r,s=this.resolveDataElementOptions(e,r);this._rect.options=s;const a=this.getSharedOptions(s),h=this.includeOptions(r,a||{}),{xScale:l,yScale:c}=this.getMeta(),u=this.options.spacing;for(let s=e;s<e+n;s++){const e=a||this.resolveDataElementOptions(s,r),n=this.getParsed(s),d=i(n,l,c,u);d.hidden=d.hidden||!!n.hidden,o&&(d.width=0,d.height=0),h&&(d.options=e),this.updateElement(t[s],s,d,r)}this.updateSharedOptions(a||{},r,s)}draw(){const{ctx:t,chartArea:e}=this.chart,i=this.getMeta().data||[],{displayMode:r,rtl:o,spacing:s}=this.options,a={displayMode:r,rtl:o,spacing:s};n.clipArea(t,e);for(let e=0,n=i.length;e<n;++e){const n=i[e];n.hidden||n.draw(t,this.getParsed(e),a)}n.unclipArea(t)}constructor(t,e){super(t,e),this._rect=void 0,this._rectChanged=!0,this._nodes=[],this._layoutDirty=!0,this._fingerprint=void 0}}function U(t,e){const{x:n,y:i,width:r,height:o}=t.getProps(["x","y","width","height"],e);return{bottom:i+o,left:n,right:n+r,top:i}}function G(t){const e=U(t),i=e.right-e.left,r=e.bottom-e.top,a=s(t.options.borderWidth,i/2,r/2),h=function(t,e,i){const r=n.toTRBLCorners(t),s=Math.min(e,i);return{bottomLeft:o(r.bottomLeft,0,s),bottomRight:o(r.bottomRight,0,s),topLeft:o(r.topLeft,0,s),topRight:o(r.topRight,0,s)}}(t.options.borderRadius,i/2,r/2),l={active:t.active,h:r,radius:h,w:i,x:e.left,y:e.top};return{inner:{active:t.active,h:l.h-a.t-a.b,radius:{bottomLeft:Math.max(0,h.bottomLeft-Math.max(a.b,a.l)),bottomRight:Math.max(0,h.bottomRight-Math.max(a.b,a.r)),topLeft:Math.max(0,h.topLeft-Math.max(a.t,a.l)),topRight:Math.max(0,h.topRight-Math.max(a.t,a.r))},w:l.w-a.l-a.r,x:l.x+a.l,y:l.y+a.t},outer:l}}function X(t,e,n,i){const r=null===e,o=null===n,s=!(!t||r&&o)&&U(t,i);return s&&(r||e>=s.left&&e<=s.right)&&(o||n>=s.top&&n<=s.bottom)}function Y(t,e){t.rect(e.x,e.y,e.w,e.h)}N.id="treemap",N.version="5.0.0-next.5",N.defaults={animations:{numbers:{properties:["x","y","width","height"],type:"number"}},dataElementType:"treemap",displayMode:r.displayMode,groups:[],key:"",leafKey:"_leaf",rtl:r.rtl,spacing:r.spacing,sumKeys:[],unsorted:!1},N.descriptors={_indexable:!1,_scriptable:!0,captions:{_fallback:!0,_scriptable:t=>"formatter"!==t},labels:{_fallback:!0,_scriptable:t=>"formatter"!==t}},N.overrides={hover:{},interaction:{includeInvisible:!0,intersect:!0,mode:"point"},plugins:{tooltip:{callbacks:{label(t){const e=t.parsed,n=e.g||e._data?.label||t.dataset.label;return(n?`${n}: `:"")+e.v},title(t){if(t.length){return t[0].dataset.key||""}return""}},intersect:!0,position:"treemap"}},scales:{x:{alignToPixels:!0,bounds:"data",display:!1,type:"linear"},y:{alignToPixels:!0,bounds:"data",display:!1,reverse:!0,type:"linear"}}},N.beforeRegister=()=>{R("chart.js","4.0",e.Chart.version)},N.afterRegister=()=>{q()},N.afterUnregister=()=>{const t=e.registry.plugins.get("tooltip");t&&delete t.positioners.treemap};class J extends e.Element{draw(t,e,i=r){if(!e)return;const o=this.options,{inner:s,outer:a}=G(this),h=(l=a.radius).topLeft||l.topRight||l.bottomLeft||l.bottomRight?n.addRoundedRectPath:Y;var l;t.save(),a.w===s.w&&a.h===s.h||(t.beginPath(),h(t,a),t.clip(),h(t,s),t.fillStyle=o.borderColor,t.fill("evenodd")),t.beginPath(),h(t,s),t.fillStyle=o.backgroundColor,t.fill(),I(t,s,o,e,this,i),t.restore()}inRange(t,e,n){return X(this,t,e,n)}inXRange(t,e){return X(this,t,null,e)}inYRange(t,e){return X(this,null,t,e)}getCenterPoint(t){const{x:e,y:n,width:i,height:r}=this.getProps(["x","y","width","height"],t);return{x:e+i/2,y:n+r/2}}tooltipPosition(){return this.getCenterPoint()}constructor(t){super(),this.width=void 0,this.height=void 0,t&&Object.assign(this,t)}}J.id="treemap",J.defaults={borderRadius:0,borderWidth:0,captions:{align:void 0,color:"black",display:!0,font:{},formatter:t=>{const e=t.raw._data?.label;return t.raw.g||("string"==typeof e?e:"")},padding:3},labels:{align:"center",color:"black",display:!1,font:{},formatter(t){const e=t.raw._data?.label;return t.raw.g?[t.raw.g,`${t.raw.v}`]:"string"==typeof e?[e,`${t.raw.v}`]:`${t.raw.v}`},overflow:"cut",padding:3,position:"middle"}},J.descriptors={_indexable:!1,_scriptable:!0,captions:{_fallback:!0,_scriptable:t=>"formatter"!==t},labels:{_fallback:!0,_scriptable:t=>"formatter"!==t}},J.defaultRoutes={backgroundColor:"backgroundColor",borderColor:"borderColor"},e.Chart.register(N,J),t.TreemapController=N,t.TreemapElement=J,t.flatten=function(t){const e=[...t],n=[];for(;e.length;){const t=e.pop();Array.isArray(t)?e.push(...t):n.push(t)}return n.reverse()},t.flattenTree=function(t,e,n){return b(e,n,t)},t.getGroupKey=m,t.group=M,t.index=C,t.normalizeTreeToArray=b,t.requireVersion=R,t.sort=O,t.sum=j});
8
8
  //# sourceMappingURL=chartjs-chart-treemap.min.js.map
package/package.json CHANGED
@@ -97,7 +97,7 @@
97
97
  "test:integration:node-module": "node test/integration/node-module/test.mjs",
98
98
  "test:integration:webpack": "node test/integration/webpack/test.mjs",
99
99
  "test:unit": "vitest run --config vitest.config.ts --coverage",
100
- "typecheck": "tsc --noEmit && tsc --noEmit -p tsconfig.test.json && tsc -p tsconfig.json --emitDeclarationOnly && tsc --noEmit -p test/types/",
100
+ "typecheck": "tsc --noEmit && tsc --noEmit -p tsconfig.test.json && tsc -p tsconfig.json --emitDeclarationOnly && tsc --noEmit -p test/types/ && tsc --noEmit -p tsconfig.tooling.json",
101
101
  "typecheck:docs": "astro check"
102
102
  },
103
103
  "sideEffects": [
@@ -107,5 +107,5 @@
107
107
  "type": "module",
108
108
  "types": "dist/index.esm.d.ts",
109
109
  "unpkg": "dist/chartjs-chart-treemap.min.js",
110
- "version": "5.0.0-next.4"
110
+ "version": "5.0.0-next.5"
111
111
  }