ApplePayButton constructor

ApplePayButton({
  1. Key? key,
  2. VoidCallback? onPressed,
  3. ApplePayButtonStyle style = ApplePayButtonStyle.black,
  4. ApplePayButtonType type = ApplePayButtonType.plain,
})

Creates an Apple Pay button widget with the parameters specified.

Implementation

ApplePayButton({
  Key? key,
  this.onPressed,
  this.style = ApplePayButtonStyle.black,
  this.type = ApplePayButtonType.plain,
})  : constraints = BoxConstraints.tightFor(
        width: type.minimumAssetWidth,
        height: minimumButtonHeight,
      ),
      super(key: key) {
  assert(constraints.debugAssertIsValid());
}