chenxuan0000 / svg-progress-bar Goto Github PK
View Code? Open in Web Editor NEW:panda_face: A simple,progress bar for Vue.js
License: MIT License
:panda_face: A simple,progress bar for Vue.js
License: MIT License
options1: function () {
return {
// 进度条半径
radius: 50,
// 进度条线宽
circleWidth: 6,
circleLinecap: 'round',
maxValue: 100,
text: function (value) {
return this.htmlifyNumber(value) + '<span style="font-size: 0.4em;">%</span>';
},
// 进度条文本颜色
textColor: 'pink',
// 进度条填充颜色
pathColors: ['#666', '#999'],
duration: 800
}
}
感谢你的工具,在使用过程中动态设置duration不生效。
请问,环形进度条是不能设置渐变色吗?
I rendered a list of this svg-progress-bar(type="rect", use gradient feature) with different colors, such as these rainbow colors:
But every time Vue render these components, they ware rendered out in non-deterministic result.
Here is a demo: https://jsfiddle.net/Zkerhcy/4ujd375p/
自定义文本格式,是什么原因?
svgProgressOption () {
let that = this
return {
radius: 40,
circleWidth: this.circleWidthnum, // 没变化
circleLineCap: 'round',
pathColors: ['#DDD', '#008FF3'],
text: function (value) {
console.log(that.AttendanceCounts) // 获取的是原始数据,没有更新
return '<span class="circles-num">' + that.AttendanceCounts + '/' + that.totalPeople + '</span><div class="circles-subtitle">出勤人数</div>'
},
textColor: '#008FF3'
}
}
value 大于100没有做处理,比如我的value是456666;
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.