首页 > 解决方案 > 如何在flutter中使用flutter_typeahead

问题描述

我在我的应用程序中使用了flutter_typeahead pacakge,它工作正常,问题是键盘掩盖了建议列表,任何想法都会很棒。

SingleChildScrollView(
            
            child: new Column(
              children: [
                TypeAheadFormField(
                  textFieldConfiguration: TextFieldConfiguration(
                    controller: _typeAheadController,
                    decoration: InputDecoration(
                      labelText: 'کاربر',
                    ),
                  ),
                  suggestionsCallback: (pattern) async {
                    _preferences = await SharedPreferences.getInstance();
                    GetUserInfoDto getUserInfoDto = new GetUserInfoDto(
                      apiToken: _preferences.getString('apiToken'),
                      searchText: pattern,
                    );
                    

                    return await _mourdakRepository
                        .getUserInfo(getUserInfoDto);
                  },
                  
                ),
               
              ],
            ),
          ),

标签: flutterdart

解决方案


推荐阅读