Refine styles of menus, toasts, popovers, and modals (#12332)
* Refine styles of menus, toasts, popovers, and modals This is a reintroduction of https://github.com/matrix-org/matrix-react-sdk/pull/12247, with the difference that modal styles have now been refreshed as well. * Restore the fixed heights of some dialogs * Fix formatting and flaky screenshot
This commit is contained in:
parent
0f251d8a55
commit
80c4c3c28c
65 changed files with 323 additions and 414 deletions
|
@ -155,9 +155,6 @@ export default class BaseDialog extends React.Component<IProps> {
|
|||
lockProps["aria-labelledby"] = "mx_BaseDialog_title";
|
||||
}
|
||||
|
||||
const isHeaderWithCancelOnly =
|
||||
!!cancelButton && !this.props.title && !this.props.headerButton && !this.props.headerImage;
|
||||
|
||||
return (
|
||||
<MatrixClientContext.Provider value={this.matrixClient}>
|
||||
{this.props.screenName && <PosthogScreenTracker screenName={this.props.screenName} />}
|
||||
|
@ -172,8 +169,6 @@ export default class BaseDialog extends React.Component<IProps> {
|
|||
<div
|
||||
className={classNames("mx_Dialog_header", {
|
||||
mx_Dialog_headerWithButton: !!this.props.headerButton,
|
||||
mx_Dialog_headerWithCancel: !!cancelButton,
|
||||
mx_Dialog_headerWithCancelOnly: isHeaderWithCancelOnly,
|
||||
})}
|
||||
>
|
||||
{!!(this.props.title || headerImage) && (
|
||||
|
@ -188,8 +183,8 @@ export default class BaseDialog extends React.Component<IProps> {
|
|||
</Heading>
|
||||
)}
|
||||
{this.props.headerButton}
|
||||
{cancelButton}
|
||||
</div>
|
||||
{cancelButton}
|
||||
{this.props.children}
|
||||
</FocusLock>
|
||||
</MatrixClientContext.Provider>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue