I am trying to align the icon button to the right of the Text field, I tried the row which made the icon button not centered vertically and now I am trying out the Stack widget. Here is my code -
Column(
mainAxisSize: MainAxisSize.min,
children: [
Image.asset(
assets/images/phone_number.png ,
width: 400,
height: 400,
opacity: const AlwaysStoppedAnimation(.5),
),
Stack(
alignment: AlignmentDirectional.bottomCenter,
children: [
IntlPhoneField(
decoration: const InputDecoration(
labelText: Lets start with your phone number ,
focusedBorder: OutlineInputBorder(
borderSide: BorderSide(color: Colors.green, width: 1.0),
),
),
),
IconButton(
color: Colors.green,
iconSize: 90,
icon: const Icon(Icons.arrow_right),
onPressed: () => nextScreen(2),
),
],
),
],
),
UPDATE - 23/05/2023
Seyit - You answer was my first attempt at this. The issue I had with that setup was the icon button was not centered horizontally.
The second option I tried which is the code above I was able to center everything horizontally but was not able to push the icon button to the far right.
The first one is with the row and the second one is with the Stack widget.