Sticky header md-table-container angular js material design

心已入冬 提交于 2019-12-12 17:11:51

问题


table-container to display records. I have a requirement, when table reaches to top of the screen it's header stick to top. Please guide me to implement this requirement.

For example see this link http://angular-data-grid.github.io/demo/fixed-header/angular-md-grid.html#!?page=1&itemsPerPage=75

Thank you, Java4you.


回答1:


Using the Angular Material table, adding the following to the .scss file for the containing component will now achieve this, but not in IE unfortunately:

.mat-header-row {
  position: sticky;
  position: -webkit-sticky;
  top: 0;
  background-color: inherit;
}

See this for discussion.



来源:https://stackoverflow.com/questions/46468665/sticky-header-md-table-container-angular-js-material-design

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!