mirror of
https://github.com/Iconica-Development/flutter_chat.git
synced 2025-05-19 02:43:50 +02:00
fix: change the backgroundcolors
This commit is contained in:
parent
d46c83e847
commit
2f2e2be6dd
7 changed files with 3 additions and 18 deletions
|
@ -4,6 +4,7 @@
|
||||||
- fix bug where you would route back to the user selection screen insterad of routing back to the chat overview screen
|
- fix bug where you would route back to the user selection screen insterad of routing back to the chat overview screen
|
||||||
- Add onPopInvoked callback to the userstory to add custom behaviour for the back button on the chatscreen
|
- Add onPopInvoked callback to the userstory to add custom behaviour for the back button on the chatscreen
|
||||||
- Handle overflows for users with a long name.
|
- Handle overflows for users with a long name.
|
||||||
|
- Remove the scaffold backgrounds because they should be inherited from the scaffold theme
|
||||||
|
|
||||||
## 3.0.0
|
## 3.0.0
|
||||||
|
|
||||||
|
|
|
@ -14,7 +14,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
GoRoute(
|
GoRoute(
|
||||||
path: ChatUserStoryRoutes.chatScreen,
|
path: ChatUserStoryRoutes.chatScreen,
|
||||||
pageBuilder: (context, state) {
|
pageBuilder: (context, state) {
|
||||||
var theme = Theme.of(context);
|
|
||||||
var service = configuration.chatServiceBuilder?.call(context) ??
|
var service = configuration.chatServiceBuilder?.call(context) ??
|
||||||
configuration.chatService;
|
configuration.chatService;
|
||||||
var chatScreen = ChatScreen(
|
var chatScreen = ChatScreen(
|
||||||
|
@ -52,7 +51,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
chatScreen,
|
chatScreen,
|
||||||
) ??
|
) ??
|
||||||
Scaffold(
|
Scaffold(
|
||||||
backgroundColor: theme.colorScheme.surface,
|
|
||||||
body: chatScreen,
|
body: chatScreen,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
@ -65,7 +63,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
var chatId = state.pathParameters["id"];
|
var chatId = state.pathParameters["id"];
|
||||||
var service = configuration.chatServiceBuilder?.call(context) ??
|
var service = configuration.chatServiceBuilder?.call(context) ??
|
||||||
configuration.chatService;
|
configuration.chatService;
|
||||||
var theme = Theme.of(context);
|
|
||||||
|
|
||||||
var chatDetailScreen = ChatDetailScreen(
|
var chatDetailScreen = ChatDetailScreen(
|
||||||
chatTitleBuilder: configuration.chatTitleBuilder,
|
chatTitleBuilder: configuration.chatTitleBuilder,
|
||||||
|
@ -127,7 +124,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
chatDetailScreen,
|
chatDetailScreen,
|
||||||
) ??
|
) ??
|
||||||
Scaffold(
|
Scaffold(
|
||||||
backgroundColor: theme.colorScheme.surface,
|
|
||||||
body: chatDetailScreen,
|
body: chatDetailScreen,
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
@ -138,7 +134,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
pageBuilder: (context, state) {
|
pageBuilder: (context, state) {
|
||||||
var service = configuration.chatServiceBuilder?.call(context) ??
|
var service = configuration.chatServiceBuilder?.call(context) ??
|
||||||
configuration.chatService;
|
configuration.chatService;
|
||||||
var theme = Theme.of(context);
|
|
||||||
|
|
||||||
var newChatScreen = NewChatScreen(
|
var newChatScreen = NewChatScreen(
|
||||||
options: configuration.chatOptionsBuilder(context),
|
options: configuration.chatOptionsBuilder(context),
|
||||||
|
@ -177,7 +172,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
newChatScreen,
|
newChatScreen,
|
||||||
) ??
|
) ??
|
||||||
Scaffold(
|
Scaffold(
|
||||||
backgroundColor: theme.colorScheme.surface,
|
|
||||||
body: newChatScreen,
|
body: newChatScreen,
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
@ -188,7 +182,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
pageBuilder: (context, state) {
|
pageBuilder: (context, state) {
|
||||||
var service = configuration.chatServiceBuilder?.call(context) ??
|
var service = configuration.chatServiceBuilder?.call(context) ??
|
||||||
configuration.chatService;
|
configuration.chatService;
|
||||||
var theme = Theme.of(context);
|
|
||||||
|
|
||||||
var newGroupChatScreen = NewGroupChatScreen(
|
var newGroupChatScreen = NewGroupChatScreen(
|
||||||
options: configuration.chatOptionsBuilder(context),
|
options: configuration.chatOptionsBuilder(context),
|
||||||
|
@ -208,7 +201,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
newGroupChatScreen,
|
newGroupChatScreen,
|
||||||
) ??
|
) ??
|
||||||
Scaffold(
|
Scaffold(
|
||||||
backgroundColor: theme.colorScheme.surface,
|
|
||||||
body: newGroupChatScreen,
|
body: newGroupChatScreen,
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
@ -220,7 +212,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
var service = configuration.chatServiceBuilder?.call(context) ??
|
var service = configuration.chatServiceBuilder?.call(context) ??
|
||||||
configuration.chatService;
|
configuration.chatService;
|
||||||
var users = state.extra! as List<ChatUserModel>;
|
var users = state.extra! as List<ChatUserModel>;
|
||||||
var theme = Theme.of(context);
|
|
||||||
|
|
||||||
var newGroupChatOverviewScreen = NewGroupChatOverviewScreen(
|
var newGroupChatOverviewScreen = NewGroupChatOverviewScreen(
|
||||||
options: configuration.chatOptionsBuilder(context),
|
options: configuration.chatOptionsBuilder(context),
|
||||||
|
@ -255,7 +246,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
newGroupChatOverviewScreen,
|
newGroupChatOverviewScreen,
|
||||||
) ??
|
) ??
|
||||||
Scaffold(
|
Scaffold(
|
||||||
backgroundColor: theme.colorScheme.surface,
|
|
||||||
body: newGroupChatOverviewScreen,
|
body: newGroupChatOverviewScreen,
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
@ -269,7 +259,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
var id = userId == "null" ? null : userId;
|
var id = userId == "null" ? null : userId;
|
||||||
var service = configuration.chatServiceBuilder?.call(context) ??
|
var service = configuration.chatServiceBuilder?.call(context) ??
|
||||||
configuration.chatService;
|
configuration.chatService;
|
||||||
var theme = Theme.of(context);
|
|
||||||
|
|
||||||
var profileScreen = ChatProfileScreen(
|
var profileScreen = ChatProfileScreen(
|
||||||
translations: configuration.translationsBuilder?.call(context) ??
|
translations: configuration.translationsBuilder?.call(context) ??
|
||||||
|
@ -295,7 +284,6 @@ List<GoRoute> getChatStoryRoutes(
|
||||||
profileScreen,
|
profileScreen,
|
||||||
) ??
|
) ??
|
||||||
Scaffold(
|
Scaffold(
|
||||||
backgroundColor: theme.colorScheme.surface,
|
|
||||||
body: profileScreen,
|
body: profileScreen,
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|
|
@ -177,6 +177,7 @@ Scaffold _createScaffold(
|
||||||
Scaffold(
|
Scaffold(
|
||||||
appBar: appbar,
|
appBar: appbar,
|
||||||
body: body,
|
body: body,
|
||||||
|
backgroundColor: backgroundColor,
|
||||||
);
|
);
|
||||||
|
|
||||||
Widget _createUserAvatar(
|
Widget _createUserAvatar(
|
||||||
|
|
|
@ -174,7 +174,6 @@ class _ChatDetailScreenState extends State<ChatDetailScreen> {
|
||||||
: "";
|
: "";
|
||||||
|
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
backgroundColor: theme.colorScheme.surface,
|
|
||||||
appBar: AppBar(
|
appBar: AppBar(
|
||||||
backgroundColor: theme.appBarTheme.backgroundColor,
|
backgroundColor: theme.appBarTheme.backgroundColor,
|
||||||
iconTheme: theme.appBarTheme.iconTheme ??
|
iconTheme: theme.appBarTheme.iconTheme ??
|
||||||
|
|
|
@ -66,7 +66,6 @@ class _ProfileScreenState extends State<ChatProfileScreen> {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
backgroundColor: theme.colorScheme.surface,
|
|
||||||
appBar: AppBar(
|
appBar: AppBar(
|
||||||
backgroundColor: theme.appBarTheme.backgroundColor,
|
backgroundColor: theme.appBarTheme.backgroundColor,
|
||||||
iconTheme: theme.appBarTheme.iconTheme ??
|
iconTheme: theme.appBarTheme.iconTheme ??
|
||||||
|
|
|
@ -147,9 +147,7 @@ class _ChatScreenState extends State<ChatScreen> {
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
border: Border(
|
border: Border(
|
||||||
bottom: BorderSide(
|
bottom: BorderSide(
|
||||||
color: Theme.of(context)
|
color: theme.colorScheme.secondary
|
||||||
.colorScheme
|
|
||||||
.secondary
|
|
||||||
.withOpacity(0.3),
|
.withOpacity(0.3),
|
||||||
width: 0.5,
|
width: 0.5,
|
||||||
),
|
),
|
||||||
|
|
|
@ -47,7 +47,6 @@ class _NewChatScreenState extends State<NewChatScreen> {
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context) {
|
||||||
var theme = Theme.of(context);
|
var theme = Theme.of(context);
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
backgroundColor: theme.colorScheme.surface,
|
|
||||||
appBar: AppBar(
|
appBar: AppBar(
|
||||||
iconTheme: theme.appBarTheme.iconTheme ??
|
iconTheme: theme.appBarTheme.iconTheme ??
|
||||||
const IconThemeData(color: Colors.white),
|
const IconThemeData(color: Colors.white),
|
||||||
|
|
Loading…
Reference in a new issue