2016-06-07 19:09:47 +02:00
|
|
|
Template.radialProgressBar.helpers({
|
|
|
|
|
progressComplete() {
|
|
|
|
|
const instance = Template.instance();
|
|
|
|
|
return instance.data.progressPercent === 100;
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
progressRadius() {
|
2016-06-10 15:05:33 -03:00
|
|
|
var radius = 21 * 2 * Math.PI;
|
2016-06-07 19:09:47 +02:00
|
|
|
const instance = Template.instance();
|
|
|
|
|
var percentLeft = (100 - instance.data.progressPercent) / 100;
|
|
|
|
|
return percentLeft * radius;
|
|
|
|
|
}
|
|
|
|
|
});
|