Skip to content

Commit 017d2a9

Browse files
Merge pull request #4307 from material-components:circular-progress-docs
PiperOrigin-RevId: 533227878
2 parents 8bc7893 + 6596de5 commit 017d2a9

File tree

3 files changed

+103
-1
lines changed

3 files changed

+103
-1
lines changed

docs/components/circular-progress.md

Lines changed: 103 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,11 @@
1+
<!-- catalog-only-start --><!-- ---
2+
name: Circular Progress
3+
dirname: circularprogress
4+
-----><!-- catalog-only-end -->
5+
6+
<catalog-component-header image-align="end">
7+
<catalog-component-header-title slot="title">
8+
19
# Circular progress
210

311
<!--*
@@ -19,23 +27,63 @@ There are two types of progress indicators: Linear and circular.
1927
Circular progress indicators display progress by animating along an invisible
2028
circular track in a clockwise direction.
2129

22-
![An animated image of an indeterminate circular progress indicator.](images/circularprogress/hero.gif "Circular progress indicators are composed of an invisible track and an indicator")
30+
</catalog-component-header-title>
31+
32+
![A circular progress indicator at the end of an image feed.](images/circularprogress/hero.png "Circular progress indicators are composed of an invisible track and an indicator")
33+
34+
</catalog-component-header>
2335

2436
* [Design article](https://m3.material.io/components/progress-indicators)
2537
<!-- {.external} -->
2638
* API Documentation (*coming soon*)
2739
* [Source code](https://github.com/material-components/material-web/tree/main/circularprogress)
2840
<!-- {.external} -->
2941

42+
<!-- catalog-only-start -->
43+
44+
<!--
45+
46+
## Interactive Demo
47+
48+
{% playgroundexample dirname=dirname %}
49+
50+
-->
51+
52+
<!-- catalog-only-end -->
53+
3054
## Usage
3155

3256
Circular progress indicators may be determinate to show progress, or
3357
indeterminate for an unspecified amount of progress.
3458

59+
<!-- github-only-start -->
60+
3561
![Two circular progress indicators, one with three quarters of the track full
3662
and the other
3763
indeterminate.](images/circularprogress/usage.gif "Determinate and indeterminate circular progress indicators.")
3864

65+
<!-- github-only-end -->
66+
<!-- catalog-only-start -->
67+
68+
<!--
69+
70+
<div class="figure-wrapper">
71+
<figure
72+
style="justify-content:center;"
73+
title="Determinate and indeterminate circular progress indicators."
74+
aria-label="Two circular progress indicators, one with three quarters of the track full
75+
and the other
76+
indeterminate.">
77+
<md-circular-progress inert progress="0.75"></md-circular-progress>
78+
79+
<md-circular-progress inert indeterminate></md-circular-progress>
80+
</figure>
81+
</div>
82+
83+
-->
84+
85+
<!-- catalog-only-end -->
86+
3987
```html
4088
<md-circular-progress progress="0.75"></md-circular-progress>
4189

@@ -47,8 +95,30 @@ indeterminate.](images/circularprogress/usage.gif "Determinate and indeterminate
4795
Indeterminate circular progress indicators may cycle between four colors
4896
(primary, primary container, tertiary, and tertiary container by default).
4997

98+
<!-- github-only-start -->
99+
50100
![An indeterminate circular progress indicator that cycles between four colors.](images/circularprogress/usage-four-color.gif "A four-color indeterminate circular progress indicator")
51101

102+
<!-- github-only-end -->
103+
<!-- catalog-only-start -->
104+
105+
<!--
106+
107+
<div class="figure-wrapper">
108+
<figure
109+
style="justify-content:center;"
110+
title="A four-color indeterminate circular progress indicator"
111+
aria-label="An indeterminate circular progress indicator that cycles between four colors.">
112+
<md-circular-progress inert four-color indeterminate></md-circular-progress>
113+
</figure>
114+
</div>
115+
116+
-->
117+
118+
<!-- catalog-only-end -->
119+
120+
121+
52122
```html
53123
<md-circular-progress four-color indeterminate></md-circular-progress>
54124
```
@@ -84,8 +154,40 @@ Token | Default value
84154

85155
### Example
86156

157+
<!-- github-only-start -->
158+
87159
![Image of a circular progress indicator with a different theme applied](images/circularprogress/theming.png "Circular progress indicator theming example.")
88160

161+
<!-- github-only-end -->
162+
<!-- catalog-only-start -->
163+
164+
<!--
165+
166+
<div class="figure-wrapper">
167+
<figure
168+
style="justify-content:center;align-items:center;"
169+
class="styled-example"
170+
title="Circular progress indicator theming example."
171+
aria-label="Image of a circular progress indicator with a different theme applied">
172+
<style>
173+
.styled-example {
174+
background-color: white;
175+
--md-circular-progress-size: 32px;
176+
--md-circular-progress-active-indicator-width: 20;
177+
--md-sys-color-primary: #006A6A;
178+
}
179+
</style>
180+
181+
<md-circular-progress inert progress="0.5"></md-circular-progress>
182+
</figure>
183+
</div>
184+
185+
-->
186+
187+
<!-- catalog-only-end -->
188+
189+
190+
89191
```html
90192
<style>
91193
:root {
-139 KB
Binary file not shown.
181 KB
Loading

0 commit comments

Comments
 (0)