javascript - 从顶点圆环图Angular中删除白线
问题描述
我想从使用以下配置制作的顶点图表中隐藏这条白线。我已经尝试了很多使用属性来删除它,但它仍然保持原样。如何删除两个不同数据之间的那些白线。
在屏幕截图中,它用红色箭头标记。我想删除的那些白线。
HTML
<apx-chart class=""
[chart]="newVsReturningOptions.chart"
[colors]="newVsReturningOptions.colors"
[labels]="newVsReturningOptions.labels"
[plotOptions]="newVsReturningOptions.plotOptions"
[series]="newVsReturningOptions.series"
[states]="newVsReturningOptions.states"
[tooltip]="newVsReturningOptions.tooltip"></apx-chart>
我的配置
this.newVsReturningOptions = {
chart : {
animations: {
speed : 0,
animateGradually: {
enabled: false
}
},
fontFamily: 'inherit',
foreColor : 'inherit',
height : '56px',
width : '70px',
type : 'donut',
sparkline : {
enabled: true
}
},
colors : ['#0694A2', '#E2E2E2'],
labels : this.data.labels,
plotOptions: {
pie: {
expandOnClick: false,
donut : {
size: '80%'
}
}
},
series : this.data.series,
states : {
hover : {
filter: {
type: 'none'
}
},
active: {
filter: {
type: 'none'
}
}
},
grid: {
padding: {
left: 0,
right: 0
}
},
stroke: {
width: 0,
},
tooltip : {
enabled : true,
fillSeriesColor: false,
theme : 'dark',
custom : ({seriesIndex, w}) => {
return `<div class="flex items-center h-8 min-h-8 max-h-8 px-3">
<div class="w-3 h-3 rounded-full" style="background-color: ${w.config.colors[seriesIndex]};"></div>
<div class="ml-2 text-md leading-none">${w.config.labels[seriesIndex]}:</div>
<div class="ml-2 text-md font-bold leading-none">${w.config.series[seriesIndex]}%</div>
</div>`;
}
}
};
}
解决方案
我想你忘记通过了。组件中的 [stroke] 输入<apx-start></apx-start>
。
尝试通过它,它应该为您解决问题。
<apx-chart [chart]="newVsReturningOptions.chart"
[colors]="newVsReturningOptions.colors"
[labels]="newVsReturningOptions.labels"
[plotOptions]="newVsReturningOptions.plotOptions"
[series]="newVsReturningOptions.series"
[states]="newVsReturningOptions.states"
[tooltip]="newVsReturningOptions.tooltip"
[stroke]="newVsReturningOptions.stroke">
</apx-chart>
推荐阅读
- phantomjs - 使用 PhatomJS,您可以将 CSS 注入 page.content 吗?
- python - 在python中使用for in循环解析Json
- spring - 从 config.properties 文件配置 RabbitMQ 主机和端口
- javascript - 无法在 intellij 中执行我的功能文件
- php - PHP MySQLi参数化查询不起作用
- regex - 谷歌表格:从字符串中删除除十进制之外的特定字符
- javascript - 表格内的可点击按钮
- azure - 从 Key Vault 将证书添加到 Azure VM
- sql-server - 使用 SQL Server 数据库表配置 SSIS 项目参数和变量
- django - 如何在 Django Rest Framework 中查看应用程序日志?