# Tree

const config = {
  type: 'treemap',
  data: {
    datasets: [{
      tree: Data.objectsTree,
      treeLeafKey: 'name',
      key: 'value',
      groups: [],
      spacing: 1,
      borderWidth: 0.5,
      borderColor: '#FF8F00',
      backgroundColor: 'rgba(255,167,38,0.3)',
      hoverBackgroundColor: 'rgba(238,238,238,0.5)',
      captions: {
        align: 'center'
      },
      labels: {
        display: true,
        formatter: (ctx) => {
          return ctx.raw.v;
        }
      }
    }]
  },
  options
};
Last Updated: 12/4/2024, 2:49:50 PM