|
|
|
|
@ -1,5 +1,6 @@
|
|
|
|
|
import 'dart:async';
|
|
|
|
|
|
|
|
|
|
import 'package:fluffychat/components/default_app_bar_search_field.dart';
|
|
|
|
|
import 'package:flushbar/flushbar_helper.dart';
|
|
|
|
|
import 'package:famedlysdk/famedlysdk.dart';
|
|
|
|
|
import 'package:famedlysdk/matrix_api.dart';
|
|
|
|
|
@ -120,35 +121,11 @@ class _InvitationSelectionState extends State<InvitationSelection> {
|
|
|
|
|
firstScaffold: ChatList(activeChat: widget.room.id),
|
|
|
|
|
secondScaffold: Scaffold(
|
|
|
|
|
appBar: AppBar(
|
|
|
|
|
title: Text(L10n.of(context).inviteContact),
|
|
|
|
|
bottom: PreferredSize(
|
|
|
|
|
preferredSize: Size.fromHeight(92),
|
|
|
|
|
child: Padding(
|
|
|
|
|
padding: const EdgeInsets.all(16.0),
|
|
|
|
|
child: TextField(
|
|
|
|
|
controller: controller,
|
|
|
|
|
titleSpacing: 0,
|
|
|
|
|
title: DefaultAppBarSearchField(
|
|
|
|
|
autofocus: true,
|
|
|
|
|
autocorrect: false,
|
|
|
|
|
textInputAction: TextInputAction.search,
|
|
|
|
|
onChanged: (String text) =>
|
|
|
|
|
searchUserWithCoolDown(context, text),
|
|
|
|
|
onSubmitted: (String text) => searchUser(context, text),
|
|
|
|
|
decoration: InputDecoration(
|
|
|
|
|
border: OutlineInputBorder(),
|
|
|
|
|
prefixText: '@',
|
|
|
|
|
hintText: L10n.of(context).username,
|
|
|
|
|
labelText: L10n.of(context).inviteContactToGroup(groupName),
|
|
|
|
|
suffixIcon: loading
|
|
|
|
|
? Container(
|
|
|
|
|
padding: const EdgeInsets.all(8.0),
|
|
|
|
|
width: 12,
|
|
|
|
|
height: 12,
|
|
|
|
|
child: CircularProgressIndicator(),
|
|
|
|
|
)
|
|
|
|
|
: Icon(Icons.search_outlined),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
hintText: L10n.of(context).inviteContactToGroup(groupName),
|
|
|
|
|
onChanged: (String text) => searchUserWithCoolDown(context, text),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
body: foundProfiles.isNotEmpty
|
|
|
|
|
|