@@ -341,11 +341,11 @@ function useTooltip({ datapoint, seriesIndex }) {
341341 } else {
342342 let html = ' ' ;
343343
344- html += ` <div data-cy="donut -tooltip-name" style="width:100%;text-align:center;border-bottom:1px solid #ccc;padding-bottom:6px;margin-bottom:3px;">${ datapoint .name } </div>` ;
344+ html += ` <div data-cy="treemap -tooltip-name" style="width:100%;text-align:center;border-bottom:1px solid #ccc;padding-bottom:6px;margin-bottom:3px;">${ datapoint .name } </div>` ;
345345
346- html += ` <div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><rect data-cy="donut -tooltip-marker" x="0" y="0" height="12" width="12" stroke="none" fill="${ datapoint .color } "/></svg>` ;
346+ html += ` <div style="display:flex;flex-direction:row;gap:6px;align-items:center;"><svg viewBox="0 0 12 12" height="14" width="14"><rect data-cy="treemap -tooltip-marker" x="0" y="0" height="12" width="12" stroke="none" fill="${ datapoint .color } "/></svg>` ;
347347
348- html += ` <b data-cy="donut -tooltip-value">${ dataLabel ({p: treemapConfig .value .style .chart .layout .labels .prefix , v: datapoint .value , s: treemapConfig .value .style .chart .layout .labels .suffix , r: treemapConfig .value .style .chart .tooltip .roundingValue })} </b>` ;
348+ html += ` <b data-cy="treemap -tooltip-value">${ dataLabel ({p: treemapConfig .value .style .chart .layout .labels .prefix , v: datapoint .value , s: treemapConfig .value .style .chart .layout .labels .suffix , r: treemapConfig .value .style .chart .tooltip .roundingValue })} </b>` ;
349349
350350 tooltipContent .value = ` <div>${ html} </div>` ;
351351 }
@@ -374,7 +374,7 @@ function generateCsv() {
374374 const tableXls = [[treemapConfig .value .style .chart .title .text ],[treemapConfig .value .style .chart .title .subtitle .text ],[[" " ],[" val" ],[" %" ]]].concat (labels);
375375
376376 const csvContent = createCsvContent (tableXls);
377- downloadCsv ({ csvContent, title: treemapConfig .value .style .chart .title .text || " vue-ui-donut " })
377+ downloadCsv ({ csvContent, title: treemapConfig .value .style .chart .title .text || " vue-ui-treemap " })
378378 });
379379}
380380
@@ -443,19 +443,20 @@ defineExpose({
443443 :class =" `vue-ui-treemap ${isFullscreen ? 'vue-data-ui-wrapper-fullscreen' : ''} ${treemapConfig.useCssAnimation ? '' : 'vue-ui-dna'}`"
444444 :style =" `font-family:${treemapConfig.style.fontFamily};width:100%; text-align:center;${!treemapConfig.style.chart.title.text ? 'padding-top:36px' : ''};background:${treemapConfig.style.chart.backgroundColor}`"
445445 :id =" `treemap_${uid}`" >
446+
446447 <!-- TITLE -->
447448 <div v-if =" treemapConfig.style.chart.title.text" :style =" `width:100%;background:${treemapConfig.style.chart.backgroundColor};padding-bottom:6px`" >
448449 <Title
449450 :config =" {
450451 title: {
451- cy: 'donut -div-title',
452+ cy: 'treemap -div-title',
452453 text: treemapConfig.style.chart.title.text,
453454 color: treemapConfig.style.chart.title.color,
454455 fontSize: treemapConfig.style.chart.title.fontSize,
455456 bold: treemapConfig.style.chart.title.bold
456457 },
457458 subtitle: {
458- cy: 'donut -div-subtitle',
459+ cy: 'treemap -div-subtitle',
459460 text: treemapConfig.style.chart.title.subtitle.text,
460461 color: treemapConfig.style.chart.title.subtitle.color,
461462 fontSize: treemapConfig.style.chart.title.subtitle.fontSize,
0 commit comments