Change color of buttons within alerts

Not really the answer to your question, but I had the same problem and I solved it by not using the alert buttons.

If you add your own buttons to the alert, they look and feel like all other buttons on your app.

I always use alert2 defined in the InputBox custom component, which behaves similarly to the normal alert.

It has the limitation that doesn’t accept a form as content, but it is usually not a problem for me, because if I need to show a form in an alert, then I put the buttons in the form itself and show the alert without buttons, while when I want to show a message, alert2 uses buttons with the same style as the rest of the app, plus I can use markup.

2 Likes