check form validateion

This commit is contained in:
tzw
2024-02-19 17:06:36 +06:30
parent 5ed6ace02f
commit f66895963b
5 changed files with 224 additions and 142 deletions

View File

@@ -57,6 +57,7 @@ class InputText extends StatelessWidget {
constraints: constraints,
contentPadding: contentPadding,
// hintText: '',
errorStyle: const TextStyle(color: dangerColor, fontSize: 12),
hintStyle: TextStyle(
height: 1.5,
),
@@ -96,6 +97,22 @@ class InputText extends StatelessWidget {
: UnderlineInputBorder(
borderSide: BorderSide(
color: borderColor ?? primaryColor, width: 1.0)),
errorBorder: withBorder
? OutlineInputBorder(
borderSide: BorderSide(
color: borderColor ?? dangerColor, width: 1.0),
)
: UnderlineInputBorder(
borderSide: BorderSide(
color: borderColor ?? dangerColor, width: 1.0)),
focusedErrorBorder: withBorder
? OutlineInputBorder(
borderSide: BorderSide(
color: borderColor ?? dangerColor, width: 1.0),
)
: UnderlineInputBorder(
borderSide: BorderSide(
color: borderColor ?? dangerColor, width: 1.0)),
),
validator: validator),
);