如何使用material.io中的颤振来实现这个材料卡?

问题描述 投票:-1回答:2

在material.io他们有一个材料卡的标准解剖:https://material.io/design/components/cards.html#anatomy

Material Card

Anatomy

我想知道你将如何实现这一点并且/或者如果有一些抽象可以用来使卡看起来像这样。谢谢!

flutter
2个回答
1
投票
card -> column [
ListTile -> title, subtitle, leading,
Row -> expanded -> image.asset,
Row -> text,
Row mainaxisalignment: spacebetween ->  Row(buttons here as a child) , Row(Icons here as a child)
]

我没有时间在flutter中编写所有代码,你可以通过使用它来创建它


0
投票

最接近的似乎是Card类(https://docs.flutter.io/flutter/material/Card-class.html)以及顶部的ListTile和底部的卡主题按钮,就像该组件页面中的示例一样。

© www.soinside.com 2019 - 2024. All rights reserved.