onFeedBackTap method

Widget onFeedBackTap(
  1. VoidCallback? onTap, {
  2. Key? key,
  3. HitTestBehavior hitTestBehavior = HitTestBehavior.deferToChild,
  4. bool touchFeedBack = false,
})

it is very much like onTap extension but when you put your finger on it, its color will change, and you can decide that whether it will have a touchFeedBack (vibration on your phone)

Implementation

Widget onFeedBackTap(VoidCallback? onTap,
    {Key? key,
    HitTestBehavior hitTestBehavior = HitTestBehavior.deferToChild,
    bool touchFeedBack = false}) {
  return _CallbackButton(
    key: key,
    onTap: onTap,
    needHaptic: touchFeedBack,
    hitTestBehavior: hitTestBehavior,
    normalColor: Colors.transparent,
    pressedColor: Colors.black12,
    child: this,
  );
}