MoosylPaymentMethods constructor

const MoosylPaymentMethods({
  1. Key? key,
  2. required String publishableApiKey,
  3. String? transactionId,
  4. double amountToPay = 0.0,
  5. double tax = 0.0,
  6. double? totalAmount,
  7. String? selectedMethodId,
  8. ValueChanged<ConfigurationListDataInner>? onSelectMethod,
  9. FutureOr<void> onPaymentSuccess(
    1. bool isSuccess
    )?,
  10. ValueChanged<Object>? onPaymentError,
  11. ValueChanged<bool>? onContinueLoadingChange,
  12. MoosylPaymentMethodsController? controller,
  13. Color? primaryColor,
  14. MoosylPaymentMethodBuilder? renderMethod,
  15. Widget? loadingComponent,
  16. MoosylPaymentMethodsLoadingBuilder? loadingBuilder,
  17. bool showDefaultTitle = true,
  18. bool isMasriviInBottomSheet = true,
  19. MasriviWebViewPresentation masriviPresentation = MasriviWebViewPresentation.fullPage,
  20. String? masriviPhoneNumber,
  21. double masriviBottomSheetHeight = 0.88,
})

Creates a reusable payment method picker.

Implementation

const MoosylPaymentMethods({
  super.key,
  required this.publishableApiKey,
  this.transactionId,
  this.amountToPay = 0.0,
  this.tax = 0.0,
  this.totalAmount,
  this.selectedMethodId,
  this.onSelectMethod,
  this.onPaymentSuccess,
  this.onPaymentError,
  this.onContinueLoadingChange,
  this.controller,
  this.primaryColor,
  this.renderMethod,
  this.loadingComponent,
  this.loadingBuilder,
  this.showDefaultTitle = true,
  this.isMasriviInBottomSheet = true,
  this.masriviPresentation = MasriviWebViewPresentation.fullPage,
  this.masriviPhoneNumber,
  this.masriviBottomSheetHeight = 0.88,
});