
如圖所示,如何創建方框陰影、查看更多選項和 15% 折扣標簽?
uj5u.com熱心網友回復:
您可以單獨Row使用container. Container 可以有一個Text孩子來創建 15% off 的標簽。
Widget build(BuildContext context) {
return Padding(
padding: EdgeInsets.symmetric(vertical: 16.0),
child: Material(
elevation: 5.0,
color: color,
borderRadius: BorderRadius.circular(30.0),
child: MaterialButton(
onPressed: onPressed, //may not be needed if the aim is to show % discount only
minWidth: 200.0,
height: 42.0,
child: Text(
"15% off",
),
ElevatedButton可用于查看更多。
你能發一個快照來說明你所說的 Box Shadow 是什么意思嗎?
轉載請註明出處,本文鏈接:https://www.uj5u.com/net/451235.html
上一篇:HerokuPostgres中的持久資料-臨時檔案系統
下一篇:在Flutter中制作搜索欄
