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.
 
 
 
 
 

100 lines
3.0 KiB

import 'package:dating_touchme_app/generated/assets.dart';
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:tdesign_flutter/tdesign_flutter.dart';
class LiveRoomActionBar extends StatelessWidget {
const LiveRoomActionBar({
super.key,
required this.messageController,
required this.onMessageChanged,
required this.onSendTap,
required this.onGiftTap,
required this.onChargeTap,
required this.onInputTap,
});
final TextEditingController messageController;
final ValueChanged<String> onMessageChanged;
final VoidCallback onSendTap;
final VoidCallback onGiftTap;
final VoidCallback onChargeTap;
final VoidCallback onInputTap;
@override
Widget build(BuildContext context) {
return Row(
children: [
SizedBox(width: 16.w),
TDButton(
width: 38.w,
height: 38.w,
iconWidget: Image.asset(Assets.imagesGiftIcon, width: 28.w, height: 28.w),
padding: EdgeInsets.all(5.w),
type: TDButtonType.fill,
shape: TDButtonShape.circle,
theme: TDButtonTheme.primary,
style: TDButtonStyle(
backgroundColor: const Color.fromRGBO(0, 0, 0, .3),
),
activeStyle: TDButtonStyle(
backgroundColor: const Color.fromRGBO(0, 0, 0, .2),
),
onTap: onGiftTap,
),
SizedBox(width: 9.w),
Expanded(
child: InkWell(
onTap: onInputTap,
child: Container(
height: 38.w,
decoration: BoxDecoration(
borderRadius: BorderRadius.all(Radius.circular(38.w)),
color: const Color.fromRGBO(0, 0, 0, .3),
),
alignment: Alignment.centerLeft,
child: Padding(
padding: EdgeInsets.symmetric(horizontal: 15.w),
child: Text(
"聊点什么吧~",
style: TextStyle(
fontSize: ScreenUtil().setWidth(14),
height: 1.2,
color: const Color.fromRGBO(144, 144, 144, 1),
),
),
),
),
),
),
SizedBox(width: 8.w),
// InkWell(
// onTap: onSendTap,
// child: Container(
// width: 38.w,
// height: 38.w,
// decoration: BoxDecoration(
// borderRadius: BorderRadius.all(Radius.circular(38.w)),
// color: const Color.fromRGBO(0, 0, 0, .3),
// ),
// child: Center(
// child: Image.asset(
// Assets.imagesArrowR,
// width: 16.w,
// height: 16.w,
// ),
// ),
// ),
// ),
// SizedBox(width: 8.w),
TextButton(
onPressed: onChargeTap,
child: Text('充值', style: TextStyle(
color: Colors.white
),)
),
SizedBox(width: 16.w),
],
);
}
}