I want to give bottom right corner radius to Container. For that I have set right and bottom border of the Container.
However, it is not allowing me to set the bottom right corder radius.
The following is the code.
Container(
padding: EdgeInsets.all(8),
decoration: BoxDecoration(
borderRadius: BorderRadius.only(
bottomRight: Radius.circular(6),
),
border: Border(
right: BorderSide(
color: Colors.red,
width: 1),
bottom: BorderSide(
color: Colors.red,
width: 1),
),
),
child: Text(
blockName,
textAlign: TextAlign.left,
),
)
When I ran above code on console I was getting following error.
════════ Exception caught by rendering library ═════════════════════════════════
A borderRadius can only be given for a uniform Border.
The relevant error-causing widget was
Container transfer_content_screen.dart:537
════════════════════════════════════════════════════════════════════════════════
2
Answers
Please try this code
I found a workaround, try this