mirror of
https://github.com/Iconica-Development/flutter_chat.git
synced 2025-05-18 18:33:49 +02:00
feat: add color property for icon buttons in chat bottom
This commit is contained in:
parent
9b4ce62392
commit
60bcd1c26a
7 changed files with 28 additions and 10 deletions
|
@ -1,4 +1,9 @@
|
|||
## 0.3.3 - October 10 2023
|
||||
|
||||
- Add icon color property for icon buttons
|
||||
|
||||
## 0.3.2 - September 26 2023
|
||||
|
||||
- Fix fullname getter for nullable values
|
||||
|
||||
## 0.3.1 - July 11 2023
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
name: flutter_community_chat
|
||||
description: A new Flutter package project.
|
||||
version: 0.3.1
|
||||
version: 0.3.3
|
||||
|
||||
publish_to: none
|
||||
|
||||
|
@ -15,12 +15,12 @@ dependencies:
|
|||
git:
|
||||
url: https://github.com/Iconica-Development/flutter_community_chat.git
|
||||
path: packages/flutter_community_chat_view
|
||||
ref: 0.3.1
|
||||
ref: 0.3.3
|
||||
flutter_community_chat_interface:
|
||||
git:
|
||||
url: https://github.com/Iconica-Development/flutter_community_chat.git
|
||||
path: packages/flutter_community_chat_interface
|
||||
ref: 0.3.1
|
||||
ref: 0.3.3
|
||||
|
||||
dev_dependencies:
|
||||
flutter_lints: ^2.0.0
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
name: flutter_community_chat_firebase
|
||||
description: A new Flutter package project.
|
||||
version: 0.3.1
|
||||
version: 0.3.3
|
||||
publish_to: none
|
||||
|
||||
environment:
|
||||
|
@ -19,7 +19,7 @@ dependencies:
|
|||
git:
|
||||
url: https://github.com/Iconica-Development/flutter_community_chat.git
|
||||
path: packages/flutter_community_chat_interface
|
||||
ref: 0.3.1
|
||||
ref: 0.3.3
|
||||
|
||||
dev_dependencies:
|
||||
flutter_lints: ^2.0.0
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
name: flutter_community_chat_interface
|
||||
description: A new Flutter package project.
|
||||
version: 0.3.2
|
||||
version: 0.3.3
|
||||
publish_to: none
|
||||
|
||||
environment:
|
||||
|
|
|
@ -12,6 +12,7 @@ class ChatBottom extends StatefulWidget {
|
|||
required this.messageInputBuilder,
|
||||
required this.translations,
|
||||
this.onPressSelectImage,
|
||||
this.iconColor,
|
||||
super.key,
|
||||
});
|
||||
|
||||
|
@ -20,6 +21,7 @@ class ChatBottom extends StatefulWidget {
|
|||
final VoidCallback? onPressSelectImage;
|
||||
final ChatModel chat;
|
||||
final ChatTranslations translations;
|
||||
final Color? iconColor;
|
||||
|
||||
@override
|
||||
State<ChatBottom> createState() => _ChatBottomState();
|
||||
|
@ -45,7 +47,10 @@ class _ChatBottomState extends State<ChatBottom> {
|
|||
children: [
|
||||
IconButton(
|
||||
onPressed: widget.onPressSelectImage,
|
||||
icon: const Icon(Icons.image),
|
||||
icon: Icon(
|
||||
Icons.image,
|
||||
color: widget.iconColor,
|
||||
),
|
||||
),
|
||||
IconButton(
|
||||
onPressed: () {
|
||||
|
@ -56,7 +61,10 @@ class _ChatBottomState extends State<ChatBottom> {
|
|||
_textEditingController.clear();
|
||||
}
|
||||
},
|
||||
icon: const Icon(Icons.send),
|
||||
icon: Icon(
|
||||
Icons.send,
|
||||
color: widget.iconColor,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
|
|
|
@ -19,6 +19,7 @@ class ChatDetailScreen extends StatelessWidget {
|
|||
this.chat,
|
||||
this.chatMessages,
|
||||
this.onPressChatTitle,
|
||||
this.iconColor,
|
||||
super.key,
|
||||
});
|
||||
|
||||
|
@ -30,6 +31,9 @@ class ChatDetailScreen extends StatelessWidget {
|
|||
final Future<void> Function(String text) onMessageSubmit;
|
||||
final VoidCallback? onPressChatTitle;
|
||||
|
||||
/// The color of the icon buttons in the chat bottom.
|
||||
final Color? iconColor;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
Future<void> onPressSelectImage() => showModalBottomSheet<Uint8List?>(
|
||||
|
@ -118,6 +122,7 @@ class ChatDetailScreen extends StatelessWidget {
|
|||
onPressSelectImage: onPressSelectImage,
|
||||
onMessageSubmit: onMessageSubmit,
|
||||
translations: translations,
|
||||
iconColor: iconColor,
|
||||
),
|
||||
],
|
||||
),
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
|
||||
name: flutter_community_chat_view
|
||||
description: A standard flutter package.
|
||||
version: 0.3.1
|
||||
version: 0.3.3
|
||||
|
||||
publish_to: none
|
||||
|
||||
|
@ -20,7 +20,7 @@ dependencies:
|
|||
git:
|
||||
url: https://github.com/Iconica-Development/flutter_community_chat.git
|
||||
path: packages/flutter_community_chat_interface
|
||||
ref: 0.3.1
|
||||
ref: 0.3.3
|
||||
cached_network_image: ^3.2.2
|
||||
flutter_image_picker:
|
||||
git:
|
||||
|
|
Loading…
Reference in a new issue