Open cwnicoletti opened 2 years ago
I forgot to include this change in the README, if you'd prefer it does let me know
Honestly I was thinking too, that since I'm making this into more of an arc than a circle, maybe instead of these last 2 PR, I could create a completely different loader called Arc.js
Yeah, if your use case is not a Circle, it makes more sense to add a new Arc component like you said 👍
I was looking to use Progress.Circle as a semi-circle loader, however it seemed that the unfilled portion of the Circle.js component is always a constant of
const CIRCLE = Math.PI * 2
. I thought I'd contribute a new prop that allows users to dynamically set the end angle of the unfilled portion of the circle with theunfilledEndAngle
prop. This would allow users to make a semi-circle that's unfilled.It's written basically the same exact way as the
endAngle
prop.This also makes sure no shapes are shown if
unfilledEndAngle
is less than or equal to the currentstartAngle
of the<Shape />
component inside Circle.js. (Can be checked by turning thecolor
prop torgba(0,0,0,0)
)