- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
是否可以像级联布局一样在 pinterest 中使用 React Material-UI 库的 GridList
组件?
我使用 Material-UI Card
组件作为 GridList
的子组件:
const cards = props.items.map((item) => <Card key={item.id} {...item} />);
return (
<GridList cols={3} cellHeight={'auto'}>
{React.Children.toArray(cards)}
</GridList>
);
我想删除红色圆圈中的间隙。任何帮助都感激不尽。
最佳答案
您想要的 CSS 等效项是将 flex-direction
设置为 column
而不是 row
,但是 it doesn't look like the material-ui documentation gives you the option to change the order in which things render .
我会尝试使用不同的容器对象或自己构建一些东西,因为 Pinterest 样式布局在确定下一个要呈现的元素应该放在哪里时需要一些更复杂的逻辑。
关于javascript - React Material-UI GridList层叠布局,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42762637/
我有一个 GridList,我用它来显示 Cards。这些组件的样式如下: card.js const useStyles = makeStyles({ card: { max
我正在查看 Angular Material gridList .您可以在 codepen here 中查看示例.我想了解以下属性在此示例中的含义以及如何使用它们。文档似乎对此保持沉默。 md-col
使用 Material-UI GridList 时,单元格不会“正确”包裹在网格中。 在 css 中潜水时,我注意到它使用了 flex-wrap,它假设可以弯曲行,但我确信有一种方法可以使用这个组件,
我正在浏览 Angular Material Design Gridlist他们没有提到任何关于处理悬停/点击网格的事情。那么,有没有办法做到这一点,或者我应该使用每个网格内的按钮来处理点击事件? 最
我有一个使用 Material-UI 的 react-mobx 代码,看起来像这样: render() { // some consts declarations return (
我有一个 GridList,其中包含我从外部服务检索的一堆图像。这用于创建图像库。这些图像会定期更新,因此图像库每次看起来都不同。 如何将图片库变成灰度甚至透明,然后将其用作背景,以便我可以将内容放在
在使用 GridList 组件时,我的标题在滚动列表时会滚动,但我想将它附加到标题顶部的确切位置。像下面这样在滚动时滚动标题。 最佳答案 使用 fixed 作为标题组件的 position 属性 .h
我正在尝试创建一个由 material-ui Cards 组成的网格使用 Grid List成分。但是,在我尝试将卡片放入其中时,底部和阴影被剪掉了。我认为这是一个非常简单的 css 问题,但我看不出
我在 angularJS 中使用网格列表(动态图 block )并使用 标签,但它不工作 这是代码 {{tile.syst
我正在关注 React Material UI 设计,用于水平滚动的水平单行图像网格列表。如何根据屏幕尺寸(xm、sm、md、ls)动态更改“Cols”值?例如 md 屏幕将是“12 列”,sm 屏幕
warning.js:33 Warning: Failed prop type: Invalid prop cellHeight supplied to GridList. 我收到此错误,但该属性有效
我是一名优秀的程序员,十分优秀!