onTapWithEffect method
Widget
onTapWithEffect(
- VoidCallback? onTap, {
- Color? effectColor,
- ShapeBorder? shape,
- BorderRadius? borderRadius,
Implementation
Widget onTapWithEffect(VoidCallback? onTap, {Color? effectColor, ShapeBorder? shape, BorderRadius? borderRadius}) {
var config = JBConfig.tapEffectConfig;
return Material(
color: Colors.transparent,
shape: shape,
child: InkWell(
onTap: onTap,
splashColor: effectColor ?? config.splashColor,
highlightColor: effectColor ?? config.highlightColor,
hoverColor: config.hoverColor,
hoverDuration: config.hoverDuration,
focusColor: config.focusColor,
mouseCursor: config.mouseCursor,
customBorder: shape,
borderRadius: borderRadius,
child: this,
),
);
}