mui / mui/material-ui

[Dialog] DialogTitle overrides DialogContent className

Open
#26,795 26 comments 3 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

breaking change ready to take scope: dialog type: bug
Dominant language
JavaScript
Stars
99.1k
Forks
32.5k
Avg merge
2d 17h
Merged PRs (30d)
106

Description

  • The issue is present in the latest release.
  • I have searched the issues of this repository and believe that this is not a duplicate.

Current Behavior 😯

The DialogTitle className (MuiDialogTitle-root) is overriding the set className to DialogContent.

Expected Behavior 🤔

The DialogTitle className should not override the set className to DialogContent.

Steps to Reproduce 🕹

https://codesandbox.io/s/sparkling-architecture-47w73?file=/src/index.tsx

This is happening after @material-ui/core@5.0.0-alpha.35

To reproduce, change the package dependency in the codepen @material-ui/core to 5.0.0-alpha.36 or higher.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open the linked CodeSandbox and inspect /src/index.tsx, then compare the behavior with @material-ui/core 5.0.0-alpha.35 and alpha.36 or later. Done means DialogContent keeps its supplied className and is not overridden by the MuiDialogTitle-root class.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react, typescript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.