Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: Progress circle #141

Merged
merged 11 commits into from
May 8, 2022
Merged

refactor: Progress circle #141

merged 11 commits into from
May 8, 2022

Conversation

@vercel
Copy link

vercel bot commented May 8, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated
progress ✅ Ready (Inspect) Visit Preview May 8, 2022 at 8:45AM (UTC)

Reduce half value of storkeWidth when strokeLinecap="round"
@afc163 afc163 force-pushed the refactor/progress-circle branch from 5cc4ba9 to e32bbdf Compare May 8, 2022 07:51
@afc163 afc163 marked this pull request as ready for review May 8, 2022 07:51
@codecov
Copy link

codecov bot commented May 8, 2022

Codecov Report

Merging #141 (94fe10d) into master (2ea3828) will decrease coverage by 0.08%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #141      +/-   ##
==========================================
- Coverage   99.20%   99.11%   -0.09%     
==========================================
  Files           4        4              
  Lines         125      113      -12     
  Branches       34       32       -2     
==========================================
- Hits          124      112      -12     
  Misses          1        1              
Impacted Files Coverage Δ
src/Line.tsx 100.00% <ø> (ø)
src/Circle.tsx 100.00% <100.00%> (ø)
src/common.ts 94.73% <100.00%> (ø)

📣 Codecov can now indicate which changes are the most critical in Pull Requests. Learn more

@afc163 afc163 merged commit 703ce38 into master May 8, 2022
@delete-merged-branch delete-merged-branch bot deleted the refactor/progress-circle branch May 8, 2022 08:48
Comment on lines +41 to +48
// Fix percent accuracy when strokeLinecap is round
// https://github.com/ant-design/ant-design/issues/35009
if (strokeLinecap === 'round' && percent !== 100) {
strokeDashoffset += strokeWidth / 2;
// when percent is small enough (<= 1%), keep smallest value to avoid it's disapperance
if (strokeDashoffset >= perimeterWithoutGap) {
strokeDashoffset = perimeterWithoutGap - 0.01;
}
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant