modify checkbox to have 3 radius
This commit is contained in:
+35
-24
@@ -235,31 +235,42 @@ class MessageInputState extends State<MessageInput> {
|
|||||||
child: Container(
|
child: Container(
|
||||||
height: 16,
|
height: 16,
|
||||||
width: 16,
|
width: 16,
|
||||||
child: Material(
|
foregroundDecoration: BoxDecoration(
|
||||||
|
border: _sendAsDm
|
||||||
|
? null
|
||||||
|
: Border.all(
|
||||||
|
color: Colors.black.withOpacity(.5),
|
||||||
|
width: 2,
|
||||||
|
),
|
||||||
borderRadius: BorderRadius.circular(3),
|
borderRadius: BorderRadius.circular(3),
|
||||||
color: _sendAsDm
|
),
|
||||||
? StreamChatTheme.of(context).accentColor
|
child: Center(
|
||||||
: Colors.white,
|
child: Material(
|
||||||
child: InkWell(
|
borderRadius: BorderRadius.circular(3),
|
||||||
onTap: () {
|
color: _sendAsDm
|
||||||
setState(() {
|
? StreamChatTheme.of(context).accentColor
|
||||||
_sendAsDm = !_sendAsDm;
|
: Colors.white,
|
||||||
});
|
child: InkWell(
|
||||||
},
|
onTap: () {
|
||||||
child: AnimatedCrossFade(
|
setState(() {
|
||||||
duration: Duration(milliseconds: 300),
|
_sendAsDm = !_sendAsDm;
|
||||||
reverseDuration: Duration(milliseconds: 300),
|
});
|
||||||
crossFadeState: _sendAsDm
|
},
|
||||||
? CrossFadeState.showFirst
|
child: AnimatedCrossFade(
|
||||||
: CrossFadeState.showSecond,
|
duration: Duration(milliseconds: 300),
|
||||||
firstChild: Icon(
|
reverseDuration: Duration(milliseconds: 300),
|
||||||
Icons.check,
|
crossFadeState: _sendAsDm
|
||||||
size: 16.0,
|
? CrossFadeState.showFirst
|
||||||
color: Colors.white,
|
: CrossFadeState.showSecond,
|
||||||
),
|
firstChild: Icon(
|
||||||
secondChild: SizedBox(
|
StreamIcons.check,
|
||||||
height: 16,
|
size: 16.0,
|
||||||
width: 16,
|
color: Colors.white,
|
||||||
|
),
|
||||||
|
secondChild: SizedBox(
|
||||||
|
height: 16,
|
||||||
|
width: 16,
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
Reference in New Issue
Block a user