Skip to content

Commit

Permalink
button: Add guidance about customising loadingLabel (#1915)
Browse files Browse the repository at this point in the history
Co-authored-by: Matt Stow <[email protected]>
  • Loading branch information
adrian-yee and stowball authored Dec 19, 2024
1 parent 73ef00c commit 2fff6d2
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/large-eels-push.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@ag.ds-next/react": patch
---

button: Add guidance about customising `loadingLabel`.
1 change: 1 addition & 0 deletions packages/react/src/button/docs/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ Make sure you include a [meaningful text label](/components/button/rationale#mea
- create a meaningful button label with a verb and a noun that makes the action obvious to all users - e.g. ‘Register establishment’
- avoid general labels that don’t provide full context. - e.g. ‘Click here’
- use the `loading` property to let users know their action is being processed
- customise the `loadingLabel` property announcement to make it more contextual
- add an icon if it helps users understand the action, and only in conjunction with a text label
- use only one Primary button on a page. You can use more than one Secondary or Tertiary button.

Expand Down

0 comments on commit 2fff6d2

Please sign in to comment.