我试图在颤振中包装一些内容但没有成功。我发现我不能像使用 Chips 或 Text 小部件那样包装行。有谁知道为什么?
这是三组 Rows ,每组都有一个 Icon 和一个 Text ,并排放置。但是在较小的屏幕中它会溢出,因为没有足够的空间(宽度)。
我希望当当前行中的空格结束时,最后一组行(一个图标和一个标签)跳到下一行。
谢谢
我试图用容器包装行,但没有奏效。
Row(
children: <Widget>[
Wrap(
children: <Widget>[
Row(
children: <Widget>[
Text('long text 1'),
Text('an icon here'),
],
),
Row(
children: <Widget>[
Text('Anoter Label'),
Text('Anoter icon'),
],
),
// I want this row to jump to next line when there is not space in
// current line
Row(
children: <Widget>[
Text('More Text'),
Text('Moire icon'),
],
),
],
)
],
),
Run Code Online (Sandbox Code Playgroud)
当我在较小的屏幕上时,带有标题的图像会调整大小并适合。但是图像上方的标签和图标溢出了。所以我喜欢最后一组图标/标签与 $ …