Circular progress indicator #6061
srambach
started this conversation in
Feature requests
Replies: 3 comments 3 replies
|
The example code is all in .progres-pie; the rest is how it'd work when enclosed with wrappers (which would be elements in your PatternFly UI, such as a button, toolbar, and so on). .progress-pie {
--progress-fill: #333;
--progress-empty: #ccc;
/* Width can be set to 100% for a filled circle or to any units, including px */
--progress-width: 40%;
/* Size from the edge, add a px for antialiasing */
--mask-image: radial-gradient(
circle farthest-side,
transparent calc(100% - var(--progress-width)),
black calc(100% - var(--progress-width) + 1px)
);
aspect-ratio: 1 / 1;
border-radius: 100%;
display: inline-block;
height: 100%;
min-height: 16px;
/* Multiply by a float for a bit of anti-aliasing, while preserving 0% and 100% */
background: conic-gradient(
var(--progress-fill) var(--progress, 0),
var(--progress-empty) calc(var(--progress, 0) * 1.005)
);
mask-image: var(--mask-image);
-webkit-mask-image: var(--mask-image);
}This would be adjusted to for PatternFly naming conventions and so on. |
0 replies
|
Also: Apologies for developing it on the development version of Chrome (instead of stable) and not realizing that Chrome has been lagging behind both Firefox and Safari (yet again). Anway, it's now fixed with the duplication with a prefixed |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

Uh oh!
There was an error while loading. Please reload this page.
@garrett proposes a circular progress indicator - details below. What other products would have a use case for this?
All reactions