theme static method

ThemeData theme(
  1. BuildContext context
)

Returns a ThemeData to decorate a ReactiveTextField with.

Implementation

static ThemeData theme(BuildContext context) {
  final style = Theme.of(context).style;

  final OutlineInputBorder border = OutlineInputBorder(
    borderRadius: BorderRadius.circular(25),
    borderSide: BorderSide.none,
  );

  return Theme.of(context).copyWith(
    shadowColor: style.colors.onBackgroundOpacity27,
    iconTheme: IconThemeData(color: style.colors.primaryHighlight),
    inputDecorationTheme: Theme.of(context).inputDecorationTheme.copyWith(
      border: border,
      errorBorder: border,
      enabledBorder: border,
      focusedBorder: border,
      disabledBorder: border,
      focusedErrorBorder: border,
      focusColor: style.colors.onPrimary,
      fillColor: style.colors.onPrimary,
      hoverColor: style.colors.transparent,
      filled: true,
      isDense: true,
      contentPadding: EdgeInsets.fromLTRB(
        15,
        PlatformUtils.isDesktop ? 30 : 23,
        15,
        0,
      ),
    ),
  );
}