Software Engineer/Angular Consultant
v 1.0 (11/07/2018)
v 1.0 (11/07/2018)
// For desktop
@media only screen and (min-width: 768px) {
.elem-1 { width: 8.33%; }
.elem-2 { width: 16.66%; }
.elem-3 { width: 25%; }
.elem-4 { width: 33.33%; }
.elem-5 { width: 41.66%; }
.elem-6 { width: 50%; }
.elem-7 { width: 58.33%; }
.elem-8 { width: 66.66%; }
.elem-9 { width: 75%; }
.elem-10 { width: 83.33%; }
}
// Small devices (landscape phones, 576px and up)
@media (min-width: 576px) { ... }
// Medium devices (tablets, 768px and up)
@media (min-width: 768px) { ... }
// Large devices (desktops, 992px and up)
@media (min-width: 992px) { ... }
// Extra large devices (large desktops, 1200px and up)
@media (min-width: 1200px) { ... }
The Flex Layout engine intelligently automates the process of applying appropriate Flexbox CSS to browser view hierarchies.
The real power of Flex Layout, however, is its responsive engine. The Responsive API enables developers to easily specify different layouts, sizing, visibilities for different viewport sizes and display devices.
(c) docsnpm i @angular/flex-layout
// OR
yarn add @angular/flex-layout
imports: [
FlexLayoutModule.withConfig({useColumnBasisZero: false}),
],
first-section
second-section
third-section
github.com/angular/flex-layout/wiki/Responsive-API
first-section
second-section
third-section
github.com/angular/flex-layout/wiki/Responsive-API
With Beta 16, we have added support + API for CSS Grid. Now @angular/flex-layout supports both Flexbox and CSS Grid layouts.
(c) CHANGELOG.md