react-native-paper icon indicating copy to clipboard operation
react-native-paper copied to clipboard

feat: add loading prop to IconButton

Open pynner opened this issue 3 years ago • 6 comments

Summary

Added a loading prop to the IconButton - related issue https://github.com/callstack/react-native-paper/issues/1112 - if the Button has a loading prop, makes sense the IconButton does as well.

Test plan

  1. Download this branch
  2. Create IconButton (or take a peak at the example)
  3. Pass in loading prop
  4. Presto

pynner avatar Mar 01 '21 08:03 pynner

Hey @pynner, thank you for your pull request 🤗. The documentation from this branch can be viewed here.

callstack-bot avatar Mar 01 '21 08:03 callstack-bot

Hello @pynner,

Thanks for your contribution.

Could you point us to the material guidelines if icon button loading follows the design principles? Personally, I've tried to find it, but could not get it.

wojteg1337 avatar Mar 01 '21 11:03 wojteg1337

Hey @wojteg1337

Best I could find was here, scroll to Integrating with actions where it states that the loading indicator can be integrated into a button or actionable icon. I believe an actionable icon === IconButton.

In the official Material button docs I don't see a mention of a loading state nor a demonstration of it, only from the page I linked.

Unrelated to this PR, but it looks like the actual paper Button loading state does not follow the design spec of the page I linked. Instead of having the ActivityIndicator as an icon, it should be centred and replace the text.

pynner avatar Mar 01 '21 17:03 pynner

Would love this feature.

sagegwatkin avatar Mar 06 '21 01:03 sagegwatkin

Hello 👋, this pull request has been open for more than 2 months with no activity on it. If you think this is still necessary with the latest version, please comment and ping a maintainer to get this reviewed, otherwise it will be closed automatically in 7 days.

github-actions[bot] avatar May 06 '21 00:05 github-actions[bot]

Any update on this @wojteg1337?

sagegwatkin avatar May 06 '21 00:05 sagegwatkin

Would love this! Currently it's hard to have an activityIndicator without layout shifts

RichardLindhout avatar Dec 24 '22 09:12 RichardLindhout