https://github.com/programmerhasan/payment_dialog
A simple Flutter package for displaying customizable payment dialogs in your app.
https://github.com/programmerhasan/payment_dialog
dart flutter payment-gateway payment-integration
Last synced: 6 months ago
JSON representation
A simple Flutter package for displaying customizable payment dialogs in your app.
- Host: GitHub
- URL: https://github.com/programmerhasan/payment_dialog
- Owner: ProgrammerHasan
- License: other
- Created: 2025-08-11T17:20:32.000Z (7 months ago)
- Default Branch: master
- Last Pushed: 2025-08-11T17:54:20.000Z (7 months ago)
- Last Synced: 2025-08-11T19:38:44.592Z (7 months ago)
- Topics: dart, flutter, payment-gateway, payment-integration
- Language: Dart
- Homepage:
- Size: 1.18 MB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
Payment Dialog.
A simple Flutter package for displaying customizable payment dialogs in your app.
---
## Features
- Show a payment confirmation dialog.
- Customize title, message, and buttons.
---
## Quickstart
### Add dependency to your pubspec file
Add this to your `pubspec.yaml`:
```yaml
dependencies:
payment_dialog: ^1.0.0
```
### Add PaymentDialog to your app
```dart
import 'package:flutter/material.dart';
import 'package:payment_dialog/payment_dialog.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
body: Center(
child: ElevatedButton(
onPressed: () async {
final success = await showPaymentDialog(
context: context,
paymentUrl: 'https://yourpaymentgateway.com/start',
succeededUrl: 'https://your-payment-website.com/success',
failedUrl: 'https://your-payment-website.com/failed',
cancelledUrl: 'https://your-payment-website.com/cancelled',
);
debugPrint(success ? "Payment Success" : "Payment Failed/Cancelled");
},
child: const Text("Pay Now"),
),
),
),
);
}
}
```