hectahertz / react-native-material-dialog

Material design dialogs for React Native 💬
MIT License
141 stars 55 forks source link

how to change the font size of ok and cancel button? #31

Closed longdw closed 6 years ago

longdw commented 6 years ago

how to change the font size of ok and cancel button? how to hide cancel button that has only one ok button show?

hectahertz commented 6 years ago

Hi @longdw,

Hiding the cancel button is not recommended by the Material Design guidelines.

It's not considered a good UX practice as you can also press the back button or click outside the dialog to close it.

As per the font size, it's not supported as this library just follows the Material Design guidelines.

Thanks for your questions!

peacechen commented 6 years ago

@hectahertz There are cases where only a single button is needed. For example, my app pops up a dialog to notify the user if the internet connection has dropped. The only button needed is an acknowledgement.

Indeed, Google's Material Design guidelines state the same thing about acknowledgement actions.

Acknowledgement actions When user acknowledgement is required to proceed, a single action may be presented. Alternatively, use a snackbar to communicate this type of information.

https://material.io/design/components/dialogs.html#actions

hectahertz commented 6 years ago

Hi @peacechen ,

There's a more appropriate issue for that, please continue the discussion here: https://github.com/hectahertz/react-native-material-dialog/issues/39

Thanks!