MudBlazor: Custom MudDialog class not rendered.

Bug description When setting the Class property of a MudDialog, the class name not rendered to the class attribute of the mud-dialog div.

Expected behavior Custom class name set in Class property should be rendered to the rendered div class attribute.

E.g:

<MudDialog Class="**make-text-red**" />

… should render the outer div as :

<div id="..." class="mud-dialog mud-dialog-width-xs mud-dialog-width-full **make-text-red**">
...
</div>

TryMudBlazor Click here snippet link demonstrating the bug.

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 17 (2 by maintainers)

Commits related to this issue

Most upvoted comments

Done.

@PeterKottas is right, use ClassContent for styling the dialog body.

You always can use the traditional web method and overwrite the CSS directly, like

.mud-dialog-title {
    color: red;
}

Combine it with CSS isolation and you will have more control