类似于 HTML/CSS 的浮动布局
在 HTML/CSS 中,如果浮动项目,超出容器宽度的 DIV 会向下移动 1 行。
我想在 FLEX 中实现这一点。我有 3 个宽度可变的组件。我希望当第三个组件不再适合容器时将其向下移动。
In HTML/CSS, if you float items, DIV's that exceed the width of the container are moved down 1 line.
I would like to achieve this in FLEX. I have 3 components with variable width. I would like for the 3rd component to be moved down when it doesnt fit the container any more.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我相信您正在寻找的是 FlowLayout。以下是 Flex 4 的示例:
http://evtimmy.com/2009/06/flowlayout- a-spark-custom-layout-example/
如果您正在寻找在 Flex 4 (Spark) 之前工作的东西,您可以搜索“flex flow layout”或“flex flowbox”并找到几个示例。
希望有帮助。
I believe what you are looking for is a FlowLayout. Here's an example for Flex 4:
http://evtimmy.com/2009/06/flowlayout-a-spark-custom-layout-example/
If you are looking for something that works pre-Flex 4 (Spark), you can search for "flex flow layout" or "flex flowbox" and find several examples.
Hope that helps.