Skip to content

Drawer should use makeResetStyles for base styles #29205

Description

@ling1726

image

The DrawerOverlay has 87 classes applied to it. Having more classes can affect performance negatively. None of the Drawer components use makeResetStyles which will apply the base styles into one since css class.

Also instead of additional hooks, like useDrawerBaseClassNames it's possible just to share mixins

const useDrawerRootStyles = makeStyles({
  root: {
    ...drawerBaseStyles(),
   // overrides to base styles
    position: 'fixed',
    top: 0,
    bottom: 0,
    opacity: 0,
    boxShadow: '0px transparent',
    transitionProperty: 'transform, box-shadow, opacity',
    willChange: 'transform, box-shadow, opacity',
  },

This should make it much easier to use makeResetStyles in each of the drware components

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions