You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
81 lines
2.8 KiB
81 lines
2.8 KiB
import 'package:flutter/material.dart';
|
|
|
|
buildBottom(
|
|
BuildContext context, TextEditingController controller, Function send) {
|
|
return Container(
|
|
height: 70.0,
|
|
//margin: EdgeInsets.all(10.0),
|
|
width: MediaQuery.of(context).size.width,
|
|
padding: EdgeInsets.all(10.0),
|
|
child: Material(
|
|
color: Theme.of(context).primaryColor,
|
|
elevation: 4.0,
|
|
borderRadius: BorderRadius.circular(12.0),
|
|
shadowColor: Theme.of(context).backgroundColor,
|
|
child: Container(
|
|
decoration: BoxDecoration(
|
|
shape: BoxShape.circle,
|
|
),
|
|
child: ClipRRect(
|
|
borderRadius: BorderRadius.only(
|
|
topLeft: Radius.circular(30.0),
|
|
topRight: Radius.circular(30.0),
|
|
bottomLeft: Radius.circular(30),
|
|
bottomRight: Radius.circular(30),
|
|
),
|
|
child: Row(
|
|
crossAxisAlignment: CrossAxisAlignment.stretch,
|
|
children: [
|
|
//buildSmartSearch(context),
|
|
// InkWell(
|
|
// child: Container(
|
|
// color: Theme.of(context).primaryColor,
|
|
// padding: EdgeInsets.symmetric(horizontal: 10.0),
|
|
// child: Icon(
|
|
// Ionicons.ios_happy,
|
|
// size: 30,
|
|
// color: Theme.of(context).accentColor,
|
|
// ),
|
|
// ),
|
|
// onTap: () => print(":)"),
|
|
// ),
|
|
Container(
|
|
width: MediaQuery.of(context).size.width * 0.78,
|
|
color: Theme.of(context).primaryColor,
|
|
child: TextField(
|
|
autofocus: false,
|
|
maxLines: null,
|
|
textAlign: TextAlign.start,
|
|
controller: controller,
|
|
style: TextStyle(
|
|
color: Theme.of(context).primaryColorLight,
|
|
),
|
|
decoration: InputDecoration(
|
|
border: InputBorder.none,
|
|
//contentPadding: EdgeInsets.only(top: 14.0),
|
|
hintText: "Type a message",
|
|
hintStyle: TextStyle(color: Colors.grey),
|
|
fillColor: Theme.of(context).primaryColor,
|
|
filled: true,
|
|
),
|
|
),
|
|
),
|
|
InkWell(
|
|
child: Container(
|
|
color: Theme.of(context).primaryColor,
|
|
padding: EdgeInsets.symmetric(horizontal: 10.0),
|
|
child: Icon(
|
|
Icons.send,
|
|
size: 30,
|
|
color: Theme.of(context).colorScheme.secondary,
|
|
),
|
|
),
|
|
onTap: () => send(controller.text, 0),
|
|
),
|
|
],
|
|
),
|
|
),
|
|
),
|
|
),
|
|
);
|
|
}
|
|
|