ScaleTap

Scale and opacity animated Button for Flutter

Getting Started

Wrap your widget with ScaleTap

ScaleTap(
  onTap: (){
    //Tap
  },
  onLongPress: (){
    //Long press
  },
  child: Container(
    child: Text("Tap Me"),
  ),
)

Parameters

ScaleTap

Parameter nameTypeDescriptionRequiredDefault value
childWidgetyour childyes-
onTapFunction()On tap callbackno-
onLongPressFunction()On long press callbackno-
durationDurationAnimation durationnoDuration(milliseconds:300)
scaleMinValuedoubleMin scale valueno0.95
scaleCurveCurveCurve for scalingnoSpring curve
opacityMinValuedoubleMin opacity valueno0.9
opacityCurveCurveCurve for opacitynoCurve.ease

Libraries

flutter_scale_tap