FButtonCustomStyle.inherit constructor

FButtonCustomStyle.inherit({
  1. required FTypography typography,
  2. required FStyle style,
  3. required Color enabledBoxColor,
  4. required Color enabledHoveredBoxColor,
  5. required Color disabledBoxColor,
  6. required Color enabledContentColor,
  7. required Color disabledContentColor,
})

Creates a FButtonCustomStyle that inherits its properties from the given arguments.

Implementation

FButtonCustomStyle.inherit({
  required FTypography typography,
  required FStyle style,
  required Color enabledBoxColor,
  required Color enabledHoveredBoxColor,
  required Color disabledBoxColor,
  required Color enabledContentColor,
  required Color disabledContentColor,
}) : this(
        enabledBoxDecoration: BoxDecoration(
          borderRadius: style.borderRadius,
          color: enabledBoxColor,
        ),
        enabledHoverBoxDecoration: BoxDecoration(
          borderRadius: style.borderRadius,
          color: enabledHoveredBoxColor,
        ),
        disabledBoxDecoration: BoxDecoration(
          borderRadius: style.borderRadius,
          color: disabledBoxColor,
        ),
        focusedOutlineStyle: style.focusedOutlineStyle,
        contentStyle: FButtonContentStyle.inherit(
          typography: typography,
          enabled: enabledContentColor,
          disabled: disabledContentColor,
        ),
        iconContentStyle: FButtonIconContentStyle(
          enabledColor: enabledContentColor,
          disabledColor: disabledContentColor,
        ),
        spinnerStyle: FButtonSpinnerStyle.inherit(
          enabled: enabledContentColor,
          disabled: disabledContentColor,
        ),
      );