@spot-flow/checkout-inline-js 0.1.45 → 0.1.46-dev.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +78 -78
- package/dist/checkout-class.d.ts +1 -0
- package/dist/checkout-inline.es.js +16540 -9385
- package/dist/checkout-inline.js +1604 -1576
- package/dist/data/countryStateCode.json.d.ts +22016 -22016
- package/dist/index.css +1 -1
- package/dist/modules/Card.d.ts +5 -1
- package/dist/types.d.ts +1 -0
- package/dist/utils/encryption.d.ts +3 -3
- package/dist/utils.d.ts +1 -0
- package/dist/views/shared/main-footer.d.ts +5 -1
- package/dist/views/shared/main-page.d.ts +3 -1
- package/package.json +64 -64
package/README.md
CHANGED
|
@@ -1,78 +1,78 @@
|
|
|
1
|
-
|
|
2
|
-
# Spotflow Checkout Inline
|
|
3
|
-
|
|
4
|
-
This project is an inline library that enables users to make payments seamlessly. It integrates smoothly into your application, providing a streamlined checkout experience.
|
|
5
|
-
|
|
6
|
-
For React components and usage, [React NPM Package](https://www.npmjs.com/package/@spot-flow/react-spotflow-checkout)
|
|
7
|
-
|
|
8
|
-
For Vue.js components and usage, [Vue NPM Package](https://www.npmjs.com/package/@spot-flow/vue-spotflow-checkout)
|
|
9
|
-
|
|
10
|
-
For Angular components and usage, [Angular NPM Package](https://www.npmjs.com/package/@spot-flow/ng-spotflow-checkout)
|
|
11
|
-
|
|
12
|
-
## Demo
|
|
13
|
-
|
|
14
|
-
<img width="808" alt="Screenshot 2024-07-26 at 16 05 52" src="https://github.com/user-attachments/assets/4dbb0b2e-2142-4f04-994a-5c352de7d30e">
|
|
15
|
-
|
|
16
|
-
## Installation
|
|
17
|
-
|
|
18
|
-
```sh
|
|
19
|
-
npm install @spot-flow/checkout-inline-js
|
|
20
|
-
```
|
|
21
|
-
|
|
22
|
-
## Usage
|
|
23
|
-
|
|
24
|
-
```javascript
|
|
25
|
-
import { CheckoutForm } from "@spot-flow/checkout-inline-js";
|
|
26
|
-
|
|
27
|
-
const { CheckoutForm } = SpotflowCheckout;
|
|
28
|
-
const checkout = new CheckoutForm();
|
|
29
|
-
checkout.setup({
|
|
30
|
-
email: "oluXXXXXX@gmail.com",
|
|
31
|
-
encryptionKey: "g4ryXXXXXXXXXXXX=",
|
|
32
|
-
merchantKey: "sk_test_d96889XXXXXXX684adXXXXX5b69",
|
|
33
|
-
amount: 5,
|
|
34
|
-
metadata: {
|
|
35
|
-
productName: "",
|
|
36
|
-
title: ""
|
|
37
|
-
},
|
|
38
|
-
amount: 20,
|
|
39
|
-
currency: "USD",
|
|
40
|
-
localCurrency: "NGN"
|
|
41
|
-
|
|
42
|
-
});
|
|
43
|
-
```
|
|
44
|
-
|
|
45
|
-
Alternatively, you can include it directly in your HTML via a CDN:
|
|
46
|
-
|
|
47
|
-
```sh
|
|
48
|
-
<script src="https://v2.inline-checkout.spotflow.one/dist/checkout-inline.js"></script>
|
|
49
|
-
```
|
|
50
|
-
|
|
51
|
-
```sh
|
|
52
|
-
<button onclick="openCheckout()">
|
|
53
|
-
Make Payment
|
|
54
|
-
</button>
|
|
55
|
-
```
|
|
56
|
-
|
|
57
|
-
```javascript
|
|
58
|
-
<script>
|
|
59
|
-
|
|
60
|
-
const openCheckout = () => {
|
|
61
|
-
const { CheckoutForm } = SpotflowCheckout;
|
|
62
|
-
const checkout = new CheckoutForm();
|
|
63
|
-
checkout.setup({
|
|
64
|
-
email: "oluXXXXXX@gmail.com",
|
|
65
|
-
encryptionKey: "g4ryXXXXXXXXXXXX=",
|
|
66
|
-
merchantKey: "sk_test_d96889XXXXXXX684adXXXXX5b69",
|
|
67
|
-
metadata: {
|
|
68
|
-
productName: "",
|
|
69
|
-
title: ""
|
|
70
|
-
},
|
|
71
|
-
amount: 20,
|
|
72
|
-
currency: "USD",
|
|
73
|
-
localCurrency: "NGN"
|
|
74
|
-
});
|
|
75
|
-
};
|
|
76
|
-
|
|
77
|
-
</script>
|
|
78
|
-
```
|
|
1
|
+
|
|
2
|
+
# Spotflow Checkout Inline
|
|
3
|
+
|
|
4
|
+
This project is an inline library that enables users to make payments seamlessly. It integrates smoothly into your application, providing a streamlined checkout experience.
|
|
5
|
+
|
|
6
|
+
For React components and usage, [React NPM Package](https://www.npmjs.com/package/@spot-flow/react-spotflow-checkout)
|
|
7
|
+
|
|
8
|
+
For Vue.js components and usage, [Vue NPM Package](https://www.npmjs.com/package/@spot-flow/vue-spotflow-checkout)
|
|
9
|
+
|
|
10
|
+
For Angular components and usage, [Angular NPM Package](https://www.npmjs.com/package/@spot-flow/ng-spotflow-checkout)
|
|
11
|
+
|
|
12
|
+
## Demo
|
|
13
|
+
|
|
14
|
+
<img width="808" alt="Screenshot 2024-07-26 at 16 05 52" src="https://github.com/user-attachments/assets/4dbb0b2e-2142-4f04-994a-5c352de7d30e">
|
|
15
|
+
|
|
16
|
+
## Installation
|
|
17
|
+
|
|
18
|
+
```sh
|
|
19
|
+
npm install @spot-flow/checkout-inline-js
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
## Usage
|
|
23
|
+
|
|
24
|
+
```javascript
|
|
25
|
+
import { CheckoutForm } from "@spot-flow/checkout-inline-js";
|
|
26
|
+
|
|
27
|
+
const { CheckoutForm } = SpotflowCheckout;
|
|
28
|
+
const checkout = new CheckoutForm();
|
|
29
|
+
checkout.setup({
|
|
30
|
+
email: "oluXXXXXX@gmail.com",
|
|
31
|
+
encryptionKey: "g4ryXXXXXXXXXXXX=",
|
|
32
|
+
merchantKey: "sk_test_d96889XXXXXXX684adXXXXX5b69",
|
|
33
|
+
amount: 5,
|
|
34
|
+
metadata: {
|
|
35
|
+
productName: "",
|
|
36
|
+
title: ""
|
|
37
|
+
},
|
|
38
|
+
amount: 20,
|
|
39
|
+
currency: "USD",
|
|
40
|
+
localCurrency: "NGN"
|
|
41
|
+
|
|
42
|
+
});
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
Alternatively, you can include it directly in your HTML via a CDN:
|
|
46
|
+
|
|
47
|
+
```sh
|
|
48
|
+
<script src="https://v2.inline-checkout.spotflow.one/dist/checkout-inline.js"></script>
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
```sh
|
|
52
|
+
<button onclick="openCheckout()">
|
|
53
|
+
Make Payment
|
|
54
|
+
</button>
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
```javascript
|
|
58
|
+
<script>
|
|
59
|
+
|
|
60
|
+
const openCheckout = () => {
|
|
61
|
+
const { CheckoutForm } = SpotflowCheckout;
|
|
62
|
+
const checkout = new CheckoutForm();
|
|
63
|
+
checkout.setup({
|
|
64
|
+
email: "oluXXXXXX@gmail.com",
|
|
65
|
+
encryptionKey: "g4ryXXXXXXXXXXXX=",
|
|
66
|
+
merchantKey: "sk_test_d96889XXXXXXX684adXXXXX5b69",
|
|
67
|
+
metadata: {
|
|
68
|
+
productName: "",
|
|
69
|
+
title: ""
|
|
70
|
+
},
|
|
71
|
+
amount: 20,
|
|
72
|
+
currency: "USD",
|
|
73
|
+
localCurrency: "NGN"
|
|
74
|
+
});
|
|
75
|
+
};
|
|
76
|
+
|
|
77
|
+
</script>
|
|
78
|
+
```
|
package/dist/checkout-class.d.ts
CHANGED