<div>
<el-progress style="margin-left:20px" type="circle" :width="140" :height="100" :stroke-width="10" :backgrounColor="'#fff'" :percentage="state.cpuUse" :format="format"></el-progress>
</div>
加上/n
const format = (percentage) => {
return `容器组\n\n ${percentage} / ${state.cpuTotal} `;
}
设置一下css换行
::v-deep .el-progress__text {
white-space: pre;
}
效果图
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)