We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
第222天 用css实现饼图效果
我也要出题
The text was updated successfully, but these errors were encountered:
.pie { width: 100px; height: 100px; border-radius: 50%; background: yellowgreen; background-image: linear-gradient(to right, transparent 50%, #655 0); } .pie::before { content: ''; display: block; margin-left: 50%; height: 100%; border-radius: 0 100% 100% 0 / 50%; background-color: inherit; transform-origin: left; transform: rotate(.3turn); }
方法二、svg解决方案
<svg width="100" height="100"> <circle r="25" cx="50" cy="50"/> </svg>
circle { fill: yellowgreen; stroke: #655; stroke-width: 50; stroke-dasharray: 60 158; } svg { transform: rotate(-90deg); background: yellowgreen; border-radius: 50%; }
Sorry, something went wrong.
.pie{ width: 200px; height:200px; border-radius: 50%; background: conic-gradient(#2ecc7e 0 30%,#ABCDEF 30% 60%,pink 60% 100%); }
No branches or pull requests
第222天 用css实现饼图效果
我也要出题
The text was updated successfully, but these errors were encountered: