border static method

InputDecoration border({
  1. String? hintText,
  2. TextStyle? hintStyle,
  3. num? radius,
  4. BorderSide? borderSide,
  5. Color? disabledBorderColor,
  6. Color? enabledBorderColor,
  7. Color? focusedBorderColor,
})

边线

Implementation

static InputDecoration border({
  String? hintText,
  TextStyle? hintStyle,
  num? radius,
  BorderSide? borderSide,
  Color? disabledBorderColor,
  Color? enabledBorderColor,
  Color? focusedBorderColor,
}) {
  var borderR = SBorderRadius.circle(radius: radius);
  var disabledBorder = OutlineInputBorder(
    borderRadius: borderR,
    borderSide: borderSide ??
        BorderSide(
            color: disabledBorderColor ?? CConfig.cDisabledBorderColor),
  );
  var enabledBorder = OutlineInputBorder(
    borderRadius: borderR,
    borderSide: borderSide ??
        BorderSide(color: enabledBorderColor ?? CConfig.cEnabledBorderColor),
  );
  var focusedBorder = OutlineInputBorder(
    borderRadius: borderR,
    borderSide: borderSide ??
        BorderSide(color: focusedBorderColor ?? CConfig.cFocusedBorderColor),
  );

  return InputDecoration(
    hintText: hintText ?? "",
    hintStyle: hintStyle ?? StyleText.grey(size: FConfig.ins.textTwo),
    disabledBorder: disabledBorder,
    enabledBorder: enabledBorder,
    focusedBorder: focusedBorder,
  );
}