TF-191 Fix keyboard to email input type when input for Url, Email, To, Cc, Bcc
This commit is contained in:
@@ -10,6 +10,7 @@ class TextFieldBuilder {
|
|||||||
bool? _obscureText;
|
bool? _obscureText;
|
||||||
int? _maxLines = 1;
|
int? _maxLines = 1;
|
||||||
TextEditingController? _textController;
|
TextEditingController? _textController;
|
||||||
|
TextInputType? _keyboardType;
|
||||||
|
|
||||||
void key(Key key) {
|
void key(Key key) {
|
||||||
_key = key;
|
_key = key;
|
||||||
@@ -47,6 +48,10 @@ class TextFieldBuilder {
|
|||||||
_maxLines = value;
|
_maxLines = value;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void keyboardType(TextInputType? value) {
|
||||||
|
_keyboardType = value;
|
||||||
|
}
|
||||||
|
|
||||||
TextField build() {
|
TextField build() {
|
||||||
return TextField(
|
return TextField(
|
||||||
key: _key ?? Key('TextFieldBuilder'),
|
key: _key ?? Key('TextFieldBuilder'),
|
||||||
@@ -60,6 +65,7 @@ class TextFieldBuilder {
|
|||||||
keyboardAppearance: Brightness.light,
|
keyboardAppearance: Brightness.light,
|
||||||
style: _textStyle ?? TextStyle(color: AppColor.textFieldTextColor),
|
style: _textStyle ?? TextStyle(color: AppColor.textFieldTextColor),
|
||||||
obscureText: _obscureText ?? false,
|
obscureText: _obscureText ?? false,
|
||||||
|
keyboardType: _keyboardType,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -123,6 +123,7 @@ class EmailAddressComposerWidgetBuilder {
|
|||||||
autofocus: prefixEmailAddress == PrefixEmailAddress.to ? true : false,
|
autofocus: prefixEmailAddress == PrefixEmailAddress.to ? true : false,
|
||||||
textStyle: TextStyle(color: AppColor.nameUserColor, fontSize: 14, fontWeight: FontWeight.w500),
|
textStyle: TextStyle(color: AppColor.nameUserColor, fontSize: 14, fontWeight: FontWeight.w500),
|
||||||
cursorColor: AppColor.primaryColor,
|
cursorColor: AppColor.primaryColor,
|
||||||
|
inputType: TextInputType.emailAddress,
|
||||||
decoration: InputDecoration(
|
decoration: InputDecoration(
|
||||||
border: InputBorder.none,
|
border: InputBorder.none,
|
||||||
hintText: AppLocalizations.of(_context).hint_text_email_address,
|
hintText: AppLocalizations.of(_context).hint_text_email_address,
|
||||||
|
|||||||
@@ -95,6 +95,7 @@ class LoginView extends GetWidget<LoginController> {
|
|||||||
..key(Key('login_url_input'))
|
..key(Key('login_url_input'))
|
||||||
..onChange((value) => loginController.setUrlText(value))
|
..onChange((value) => loginController.setUrlText(value))
|
||||||
..textInputAction(TextInputAction.next)
|
..textInputAction(TextInputAction.next)
|
||||||
|
..keyboardType(TextInputType.emailAddress)
|
||||||
..textDecoration(LoginInputDecorationBuilder()
|
..textDecoration(LoginInputDecorationBuilder()
|
||||||
.setLabelText(AppLocalizations.of(context).prefix_https)
|
.setLabelText(AppLocalizations.of(context).prefix_https)
|
||||||
.setPrefixText(AppLocalizations.of(context).prefix_https)
|
.setPrefixText(AppLocalizations.of(context).prefix_https)
|
||||||
@@ -111,6 +112,7 @@ class LoginView extends GetWidget<LoginController> {
|
|||||||
..key(Key('login_username_input'))
|
..key(Key('login_username_input'))
|
||||||
..onChange((value) => loginController.setUserNameText(value))
|
..onChange((value) => loginController.setUserNameText(value))
|
||||||
..textInputAction(TextInputAction.next)
|
..textInputAction(TextInputAction.next)
|
||||||
|
..keyboardType(TextInputType.emailAddress)
|
||||||
..textDecoration(LoginInputDecorationBuilder()
|
..textDecoration(LoginInputDecorationBuilder()
|
||||||
.setLabelText(AppLocalizations.of(context).username)
|
.setLabelText(AppLocalizations.of(context).username)
|
||||||
.setHintText(AppLocalizations.of(context).username)
|
.setHintText(AppLocalizations.of(context).username)
|
||||||
|
|||||||
Reference in New Issue
Block a user