Reputation: 103
I am trying to implement dialog which should have a custom card of some sort where the child widgets can partially come out as shown in this sample image
Please help me how to recreate it in flutter.
Upvotes: 0
Views: 1069
Reputation: 1069
I will suggest to use a dialog with container inside it and then the container can have a column or stack and you can reposition your widget here is a little example
return Dialog(
child: Container(
decoration: BoxDecoration(borderRadius: BorderRadius.circular(10.0)),
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
Stack(
alignment: Alignment.topCenter,
overflow: Overflow.visible,
children: <Widget>[
Container(
child: Text('a widget'),
),
Positioned(
child: Container( ),
),
Positioned(
child: Image.asset(
'your image link here'
),
),
],
),
],
),
),
);
Upvotes: 1