-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathmessage_bubble.dart
33 lines (30 loc) · 952 Bytes
/
message_bubble.dart
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
import 'package:flutter/material.dart';
import 'package:sizer/sizer.dart';
import 'package:rsa_secured_messages_app/utilities/constants.dart';
class MessageBubble extends StatelessWidget {
MessageBubble({required this.text});
final String text;
@override
Widget build(BuildContext context) {
return SingleChildScrollView(
physics: BouncingScrollPhysics(),
child: Padding(
padding: EdgeInsets.only(
left: 7.0.w, right: 7.0.w, top: 4.0.h, bottom: 4.0.h),
child: Container(
decoration: BoxDecoration(
color: kSecondaryColor,
borderRadius: BorderRadius.all(Radius.circular(20.sp))),
child: Padding(
padding: EdgeInsets.only(
left: 8.0.w, right: 8.0.w, top: 4.0.h, bottom: 4.0.h),
child: Text(
text,
style: kSimpleTextStyle,
),
),
),
),
);
}
}