opt mobile chat page style

Signed-off-by: 21pages <pages21@163.com>
This commit is contained in:
21pages 2023-05-29 09:44:38 +08:00
parent 7739946177
commit 3ec13714c9
2 changed files with 22 additions and 24 deletions

View File

@ -47,7 +47,6 @@ class ChatPage extends StatelessWidget implements PageShape {
value: chatModel, value: chatModel,
child: Container( child: Container(
color: Theme.of(context).scaffoldBackgroundColor, color: Theme.of(context).scaffoldBackgroundColor,
padding: EdgeInsets.all(14.0),
child: Consumer<ChatModel>( child: Consumer<ChatModel>(
builder: (context, chatModel, child) { builder: (context, chatModel, child) {
final currentUser = chatModel.currentUser; final currentUser = chatModel.currentUser;
@ -76,13 +75,11 @@ class ChatPage extends StatelessWidget implements PageShape {
fontSize: 14, fontSize: 14,
color: color:
Theme.of(context).textTheme.titleLarge?.color), Theme.of(context).textTheme.titleLarge?.color),
inputDecoration: isDesktop inputDecoration: InputDecoration(
? InputDecoration(
isDense: true, isDense: true,
hintText: translate('Write a message'), hintText: translate('Write a message'),
filled: true, filled: true,
fillColor: fillColor: Theme.of(context).colorScheme.background,
Theme.of(context).colorScheme.background,
contentPadding: EdgeInsets.all(10), contentPadding: EdgeInsets.all(10),
border: OutlineInputBorder( border: OutlineInputBorder(
borderRadius: BorderRadius.circular(10.0), borderRadius: BorderRadius.circular(10.0),
@ -91,11 +88,6 @@ class ChatPage extends StatelessWidget implements PageShape {
style: BorderStyle.solid, style: BorderStyle.solid,
), ),
), ),
)
: defaultInputDecoration(
hintText: translate('Write a message'),
fillColor:
Theme.of(context).colorScheme.background,
), ),
sendButtonBuilder: defaultSendButton( sendButtonBuilder: defaultSendButton(
padding: padding:

View File

@ -71,13 +71,19 @@ class DraggableChatWindow extends StatelessWidget {
onPressed: () { onPressed: () {
chatModel.hideChatWindowOverlay(); chatModel.hideChatWindowOverlay();
}, },
icon: const Icon(Icons.keyboard_arrow_down)), icon: const Icon(
Icons.keyboard_arrow_down,
color: Colors.white,
)),
IconButton( IconButton(
onPressed: () { onPressed: () {
chatModel.hideChatWindowOverlay(); chatModel.hideChatWindowOverlay();
chatModel.hideChatIconOverlay(); chatModel.hideChatIconOverlay();
}, },
icon: const Icon(Icons.close)) icon: const Icon(
Icons.close,
color: Colors.white,
))
], ],
) )
], ],