Can I change Dialog's content css for only one dialog?

I know I can write css for rz-dialog-content and change it globally but I'd like to know if it's possible to change it for only selected content

Hi @marekm294,

You can try setting CssClass or WrapperCssClass when opening the dialog:

DialogService.OpenAsync<MyPage>("My dialog", new Dictionary<string, object>(), new DialogOptions
{
   CssClass = "my-class",
   WrapperCssClass = "my-wrapper-class"
});

I know I can but I'd like to change rz-dialog-content padding and CssClass/WrapperCssClass aren't so much helpful.

You can always use nested CSS selectors.

.my-class .rz-dialog-content
{
}
1 Like