Allow the option to format the value of extraAvatars in AvatarGroup #39204
Labels
component: avatar
This is the name of the generic UI component, not the React module!
enhancement
This is not a bug, nor a new feature
package: material-ui
Specific to @mui/material
Duplicates
Latest version
Summary 💡
I am using the AvatarGroup component with the
total
prop. In my case, thetotal
is a very large number (in the thousands) so I want to format it so it would look like this:4K
instead of+4012
.The solution can be in the form of a formatter prop which accepts the number and returns the formatted value.
Examples 🌈
No response
Motivation 🔦
The lack of this feature causes me to implement the
total
prop logic by myself, which is unfortunate considering the only thing I need is formatting the value.The text was updated successfully, but these errors were encountered: