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

[CircularProgress] should start at the top #4747

Closed
mpretty-cyro opened this issue Jul 20, 2016 · 5 comments · Fixed by #6966
Closed

[CircularProgress] should start at the top #4747

mpretty-cyro opened this issue Jul 20, 2016 · 5 comments · Fixed by #6966
Assignees
Labels
component: CircularProgress The React component component: progress This is the name of the generic UI component, not the React module! design: material This is about Material Design, please involve a visual or UX designer in the process

Comments

@mpretty-cyro
Copy link

Problem description

Currently the CircularProgress indicator starts from the right (90 degrees), but should start from the top. The closest example I can find in https://material.google.com/components/progress-activity.html#progress-activity-types-of-indicators is the 'determinate' circular indicator, while it's spinning you can't really tell but when it finishes you can see that it finishes at the top of the circle.

Versions

  • Material-UI: 0.15.0, 0.15.1, 0.15.2
  • React: 15.2.1
  • Browser: All
@oliviertassinari oliviertassinari added the design: material This is about Material Design, please involve a visual or UX designer in the process label Jul 20, 2016
@nathanmarks nathanmarks modified the milestone: 0.16.0 Release Jul 22, 2016
@peetzweg
Copy link

peetzweg commented Nov 24, 2016

I was waiting for this to be fixed. However you could just use CSS3 transform to rotate it

const style = {
    transform: "rotate(-90deg)",
    webkitTransform: "rotate(-89deg)", // vendor prefix, cause it's still experimental in Safari. Also multiples of 90 degrees did not work for me, don't know why
}

<CircularProgress style={style} value={42} mode="determinate" />

@oliviertassinari
Copy link
Member

@mpretty-cyro You are right, I have added this issue in #4757 so we don't forget it when migrating the component to the next branch.

@lilasquared
Copy link

@oliviertassinari I was wondering if it would be possible to have the stroke-linecap be configurable as well for the Circular Progress? One use case is that If you set the thickness to 1/2 the size and then set the linecap to 'butt' you get a really nice looking pie slice rather than a hoop. Any thoughts on that?

@oliviertassinari oliviertassinari added component: CircularProgress The React component and removed component: CircularProgress The React component labels Dec 18, 2016
@oliviertassinari oliviertassinari changed the title CircularProgress should start at the top [CircularProgress] should start at the top Dec 18, 2016
@slavab89
Copy link
Contributor

I believe its possible to change the initial transform values inside the css to -90 and 270. here
The origin or the transformation of SVG is the center of the SVG however the rotation is always from the X Axis.
Can submit a small PR for this (2 lines basically)

@oliviertassinari
Copy link
Member

@slavab89 Yes, a PR would be appreciated. Also, we haven't migrated determinate CircularProgress to the next branch yet.

@oliviertassinari oliviertassinari added the component: progress This is the name of the generic UI component, not the React module! label Nov 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component: CircularProgress The React component component: progress This is the name of the generic UI component, not the React module! design: material This is about Material Design, please involve a visual or UX designer in the process
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants