mirror of
https://github.com/Iconica-Development/flutter_registration.git
synced 2025-05-18 21:23:43 +02:00
feat: expose input decoration in authtextfield
This commit is contained in:
parent
d1ad003c22
commit
f1663afa1b
1 changed files with 8 additions and 5 deletions
|
@ -19,6 +19,7 @@ class AuthTextField extends AuthField {
|
|||
this.onChange,
|
||||
this.hidden,
|
||||
this.onPassChanged,
|
||||
this.textFieldDecoration,
|
||||
}) {
|
||||
textController =
|
||||
textEditingController ?? TextEditingController(text: value);
|
||||
|
@ -32,6 +33,7 @@ class AuthTextField extends AuthField {
|
|||
final Function(String value)? onChange;
|
||||
final bool? hidden;
|
||||
final Function(bool value)? onPassChanged;
|
||||
final InputDecoration? textFieldDecoration;
|
||||
|
||||
@override
|
||||
Widget build() {
|
||||
|
@ -57,11 +59,12 @@ class AuthTextField extends AuthField {
|
|||
|
||||
return TextFormField(
|
||||
style: textStyle,
|
||||
decoration: InputDecoration(
|
||||
label: label,
|
||||
hintText: hintText,
|
||||
suffix: suffix,
|
||||
),
|
||||
decoration: textFieldDecoration ??
|
||||
InputDecoration(
|
||||
label: label,
|
||||
hintText: hintText,
|
||||
suffix: suffix,
|
||||
),
|
||||
controller: textController,
|
||||
obscureText: hidden ?? obscureText,
|
||||
onChanged: (v) {
|
||||
|
|
Loading…
Reference in a new issue