Custom Card Shape Flutter SDK

前端 未结 4 1791
迷失自我
迷失自我 2021-01-30 12:10

I just started learning Flutter and I have developed an app with GridView. GridView items are Card. Default card shape is Rectangle with a radius of 4.

I know there is s

4条回答
  •  南笙
    南笙 (楼主)
    2021-01-30 12:44

    An Alternative Solution to the above

    Card(
      shape: RoundedRectangleBorder(
         borderRadius: BorderRadius.only(topLeft: Radius.circular(20), topRight: Radius.circular(20))),
      color: Colors.white,
      child: ...
    )
    

    You can use BorderRadius.only() to customize the corners you wish to manage.

提交回复
热议问题