fix(sidenav): box shadow visible while closed when rendering on the server (#10969)

This commit is contained in:
Kristiyan Kostadinov
2018-05-01 10:32:57 -04:00
committed by Joey Perrott
parent 7d2c31efaa
commit cfe6c1d40d
+5 -3
View File
@@ -21,11 +21,13 @@ export const matDrawerAnimations: {
/** Animation that slides a drawer in and out. */
transformDrawer: trigger('transform', [
state('open, open-instant', style({
transform: 'translate3d(0, 0, 0)',
visibility: 'visible',
'transform': 'translate3d(0, 0, 0)',
'visibility': 'visible',
})),
state('void', style({
visibility: 'hidden',
// Avoids the shadow showing up when closed in SSR.
'box-shadow': 'none',
'visibility': 'hidden',
})),
transition('void => open-instant', animate('0ms')),
transition('void <=> open, open-instant => void',