angular - 如何以响应方式使用 Angular flex 布局扭曲和居中多个 div

标签 angular angular-flex-layout

如何使用 angular/flex-layout 在图片中创建效果.我一直在试验 fxLayoutWrap 但它不会生成以下布局 enter image description here

最佳答案

这里是 Angular 6flex-layout 6.0.0-beta.16 的版本,因为 fxLayoutWrap 已被弃用版本

<div fxLayout="column" fxLayoutAlign=" none">
  <div fxFlex="100" fxLayout="row wrap" fxLayoutAlign="space-around stretch" fxLayout.xs="column">
    <div *ngFor="let item of items | async" fxFlex.xs="100" fxFlex.sm="50" fxFlex.md="33" fxFlex.lg="33" fxFlex.xl="33">
     {{item}}
    </div>
  </div>
</div>

关于angular - 如何以响应方式使用 Angular flex 布局扭曲和居中多个 div,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46132649/

相关文章:

angular - 如何创建 Angular Flex-Layout 样式生成器来生成默认的 fxLayoutGap?

angular - Material Angular 卡片展示

json - tsconfig.json 的目的是什么?

sql - MEAN-Stack - 无法从服务器读取第二个 SQL 表

html - *ngFor 中的 ngStyle 不起作用

css - 如何在 Flex Layout 中的单个元素上启用滚动?

angular - chartjs 高度不跟随父容器

Angular 2 : replace host element with component's template

Angular2 没有将 "exportAs"设置为 "ngModel"Karma/Jasmine 的指令

typescript - 角度垫表分页不起作用,整个数据加载到垫表的第一页上