This repository was archived by the owner on Jan 6, 2025. It is now read-only.
This repository was archived by the owner on Jan 6, 2025. It is now read-only.
FxLayout element with fxHide.xs doesn't hide on media changes #945
Closed
Description
Bug Report
What is the expected behavior?
<div fxLayout fxHide.xs></div>
respects media changes and hides the element at extra-small screen sizes.
<div fxLayout [fxHide.xs]="booleanVariable"></div>
respects media changes and hides the element at extra-small screen sizes if the booleanVariable
is true. This case is specific to my own code, and I want to make sure it works.
What is the current behavior?
<div fxLayout [fxHide.xs]="booleanVariable"></div>
- On initial load at extra-small screen sizes hides the element
- On resize to a larger size, displays the element
- On resize back to extra-small, does not hide the element.
Note: When the element doesn't have fxLayout
(e.g. <div [fxHide.xs]="booleanVariable"></div>
), it works properly.
What are the steps to reproduce?
Providing a StackBlitz (or similar) is the best way to get the team to see your issue.
https://stackblitz.com/edit/angular-flex-layout-seed-k1oskk?file=app%2Ftest.component.ts
What is the use-case or motivation for changing an existing behavior?
It's broken.
Which versions of Angular, Material, OS, TypeScript, browsers are affected?
Angular 7.1.4
Material 7.2.0
TypeScript 3.1.6