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

Add loading property to Button #1876

Closed
AykutBurak opened this issue Mar 16, 2021 · 2 comments
Closed

Add loading property to Button #1876

AykutBurak opened this issue Mar 16, 2021 · 2 comments
Assignees
Labels
Type: New Feature Issue contains a new feature or new component request
Milestone

Comments

@AykutBurak
Copy link

[ ] bug report
[x] feature request
[ ] support request

Current behavior
Button component doesn't have any support for loading status.

Expected behavior
Having a "loading" prop on Button component, which indicates the loading status of a button, would be a good addition to the library. Button's that have a loading prop should indicate a spinner and disable any input during loading state.

Like antd; https://ant.design/components/button/#components-button-demo-loading

@augustosnk12
Copy link

You can do this way by passing icon prop:

icon={${isLoading ? 'pi pi-spin pi-spinner' : 'pi pi-check'}}

@AykutBurak
Copy link
Author

AykutBurak commented Mar 17, 2021

I know, I did a workaround like this. But it is not as declarative as a "loading" prop.

@mcandu mcandu self-assigned this Apr 2, 2021
@mcandu mcandu added the Type: New Feature Issue contains a new feature or new component request label Apr 2, 2021
@mcandu mcandu added this to the 6.2.2 milestone Apr 2, 2021
mertsincan added a commit that referenced this issue Apr 13, 2021
mertsincan added a commit that referenced this issue Apr 13, 2021
mertsincan added a commit that referenced this issue Apr 13, 2021
mertsincan added a commit that referenced this issue Apr 14, 2021
mertsincan added a commit that referenced this issue Apr 16, 2021
@mertsincan mertsincan changed the title support loading status for Button component Add loading property to Button Apr 21, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: New Feature Issue contains a new feature or new component request
Projects
None yet
Development

No branches or pull requests

3 participants