@fractalpay/fractalpay-next-dev 0.0.17 → 0.0.19
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 +103 -2
- package/dist/index.d.mts +5 -16
- package/dist/index.d.ts +5 -16
- package/dist/index.js +10 -10
- package/dist/index.mjs +9 -9
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# 🧩 FractalPay React Components
|
|
1
|
+
<!-- # 🧩 FractalPay React Components
|
|
2
2
|
|
|
3
3
|
A collection of React components to easily integrate FractalPay payment flows into your React applications.
|
|
4
4
|
|
|
@@ -117,4 +117,105 @@ Add a card with a simplified experience.
|
|
|
117
117
|
|
|
118
118
|
## 📄 License
|
|
119
119
|
|
|
120
|
-
MIT License © 2025 FractalPay Inc.
|
|
120
|
+
MIT License © 2025 FractalPay Inc. -->
|
|
121
|
+
|
|
122
|
+
|
|
123
|
+
|
|
124
|
+
|
|
125
|
+
|
|
126
|
+
|
|
127
|
+
|
|
128
|
+
|
|
129
|
+
<!-- ####################New Readme.md file -->
|
|
130
|
+
|
|
131
|
+
|
|
132
|
+
<!-- # React Payment Components
|
|
133
|
+
|
|
134
|
+
A set of reusable React components to handle various payment-related actions such as requesting payments, pre-authorizations, and adding cards.
|
|
135
|
+
|
|
136
|
+
## Components
|
|
137
|
+
|
|
138
|
+
### `RequestPayment`
|
|
139
|
+
|
|
140
|
+
Sends a payment request to a customer.
|
|
141
|
+
|
|
142
|
+
**Props:**
|
|
143
|
+
- `merchantPublicKey` (string) – **required**
|
|
144
|
+
- `amount` (string) – **required**
|
|
145
|
+
- `customerId`, `orderID`, `name`, `email`, `phone`, `from`, `webname`, `discount`, `tax`, `surcharge`, `require_3ds` – *optional*
|
|
146
|
+
|
|
147
|
+
---
|
|
148
|
+
|
|
149
|
+
### `RequestPreAuthPayment`
|
|
150
|
+
|
|
151
|
+
Requests a pre-authorized payment.
|
|
152
|
+
|
|
153
|
+
**Props:**
|
|
154
|
+
- `merchantPublicKey` (string) – **required**
|
|
155
|
+
- `amount` (string) – **required**
|
|
156
|
+
- `customerId`, `orderID`, `name`, `email`, `phone`, `from`, `webname`, `discount`, `tax`, `surcharge`, `require_3ds` – *optional*
|
|
157
|
+
|
|
158
|
+
---
|
|
159
|
+
|
|
160
|
+
### `GetPaymentPage`
|
|
161
|
+
|
|
162
|
+
Renders a hosted payment page.
|
|
163
|
+
|
|
164
|
+
**Props:**
|
|
165
|
+
- `merchantPublicKey` (string) – **required**
|
|
166
|
+
- `amount` (string) – **required**
|
|
167
|
+
- `customerId`, `orderID`, `from`, `discount`, `tax`, `surcharge` – *optional*
|
|
168
|
+
|
|
169
|
+
---
|
|
170
|
+
|
|
171
|
+
### `PreAuthPayment`
|
|
172
|
+
|
|
173
|
+
Renders a pre-authorization payment page.
|
|
174
|
+
|
|
175
|
+
**Props:**
|
|
176
|
+
- `merchantPublicKey` (string) – **required**
|
|
177
|
+
- `amount` (string) – **required**
|
|
178
|
+
- `customerId`, `orderID`, `from`, `discount`, `tax`, `surcharge` – *optional*
|
|
179
|
+
|
|
180
|
+
---
|
|
181
|
+
|
|
182
|
+
### `AddCardEasyPay`
|
|
183
|
+
|
|
184
|
+
Allows adding a card via EasyPay.
|
|
185
|
+
|
|
186
|
+
**Props:**
|
|
187
|
+
- `merchantPublicKey` (string) – **required**
|
|
188
|
+
- `customerId` – *optional*
|
|
189
|
+
|
|
190
|
+
---
|
|
191
|
+
|
|
192
|
+
### `AddCardSky`
|
|
193
|
+
|
|
194
|
+
Renders a card input flow with additional options.
|
|
195
|
+
|
|
196
|
+
**Props:**
|
|
197
|
+
- `session_token` (string) – **required**
|
|
198
|
+
- `callback` (function) – **required**
|
|
199
|
+
- `isloading` (boolean) – **required**
|
|
200
|
+
- `onCancel` (function) – **required**
|
|
201
|
+
- `showChecks` (boolean) – **required**
|
|
202
|
+
- `merchantName` (string) – **required**
|
|
203
|
+
|
|
204
|
+
---
|
|
205
|
+
|
|
206
|
+
## Usage
|
|
207
|
+
|
|
208
|
+
```tsx
|
|
209
|
+
import {
|
|
210
|
+
RequestPayment,
|
|
211
|
+
RequestPreAuthPayment,
|
|
212
|
+
GetPaymentPage,
|
|
213
|
+
PreAuthPayment,
|
|
214
|
+
AddCard,
|
|
215
|
+
AddCardSky
|
|
216
|
+
} from './[path-to-component]';
|
|
217
|
+
|
|
218
|
+
<RequestPayment
|
|
219
|
+
merchantPublicKey="your_public_key"
|
|
220
|
+
amount="100.00"
|
|
221
|
+
/> -->
|
package/dist/index.d.mts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
3
|
interface Props$5 {
|
|
4
|
-
|
|
4
|
+
merchantPublicKey: string;
|
|
5
5
|
customerId?: string;
|
|
6
6
|
orderID?: string;
|
|
7
7
|
name?: string;
|
|
@@ -18,7 +18,7 @@ interface Props$5 {
|
|
|
18
18
|
declare function RequestPayment(props: Props$5): React.JSX.Element;
|
|
19
19
|
|
|
20
20
|
interface Props$4 {
|
|
21
|
-
|
|
21
|
+
merchantPublicKey: string;
|
|
22
22
|
customerId?: string;
|
|
23
23
|
orderID?: string;
|
|
24
24
|
name?: string;
|
|
@@ -35,15 +35,11 @@ interface Props$4 {
|
|
|
35
35
|
declare function RequestPreAuthPayment(props: Props$4): React.JSX.Element;
|
|
36
36
|
|
|
37
37
|
type Props$3 = {
|
|
38
|
-
|
|
38
|
+
merchantPublicKey: string;
|
|
39
39
|
customerId?: string;
|
|
40
40
|
orderID?: string;
|
|
41
|
-
name?: string;
|
|
42
|
-
email?: string;
|
|
43
|
-
phone?: string;
|
|
44
41
|
from?: string;
|
|
45
42
|
amount: string;
|
|
46
|
-
webname?: string;
|
|
47
43
|
discount?: string;
|
|
48
44
|
tax?: string;
|
|
49
45
|
surcharge?: string;
|
|
@@ -51,15 +47,11 @@ type Props$3 = {
|
|
|
51
47
|
declare function GetPaymentPage(props: Props$3): React.JSX.Element;
|
|
52
48
|
|
|
53
49
|
type Props$2 = {
|
|
54
|
-
|
|
50
|
+
merchantPublicKey: string;
|
|
55
51
|
customerId?: string;
|
|
56
52
|
orderID?: string;
|
|
57
|
-
name?: string;
|
|
58
|
-
email?: string;
|
|
59
|
-
phone?: string;
|
|
60
53
|
from?: string;
|
|
61
54
|
amount: string;
|
|
62
|
-
webname?: string;
|
|
63
55
|
discount?: string;
|
|
64
56
|
tax?: string;
|
|
65
57
|
surcharge?: string;
|
|
@@ -67,11 +59,8 @@ type Props$2 = {
|
|
|
67
59
|
declare function PreAuthPayment(props: Props$2): React.JSX.Element;
|
|
68
60
|
|
|
69
61
|
type Props$1 = {
|
|
70
|
-
|
|
62
|
+
merchantPublicKey: string;
|
|
71
63
|
customerId?: string;
|
|
72
|
-
name?: string;
|
|
73
|
-
email?: string;
|
|
74
|
-
phone?: string;
|
|
75
64
|
};
|
|
76
65
|
declare function AddCardEasyPay(props: Props$1): React.JSX.Element;
|
|
77
66
|
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
|
|
3
3
|
interface Props$5 {
|
|
4
|
-
|
|
4
|
+
merchantPublicKey: string;
|
|
5
5
|
customerId?: string;
|
|
6
6
|
orderID?: string;
|
|
7
7
|
name?: string;
|
|
@@ -18,7 +18,7 @@ interface Props$5 {
|
|
|
18
18
|
declare function RequestPayment(props: Props$5): React.JSX.Element;
|
|
19
19
|
|
|
20
20
|
interface Props$4 {
|
|
21
|
-
|
|
21
|
+
merchantPublicKey: string;
|
|
22
22
|
customerId?: string;
|
|
23
23
|
orderID?: string;
|
|
24
24
|
name?: string;
|
|
@@ -35,15 +35,11 @@ interface Props$4 {
|
|
|
35
35
|
declare function RequestPreAuthPayment(props: Props$4): React.JSX.Element;
|
|
36
36
|
|
|
37
37
|
type Props$3 = {
|
|
38
|
-
|
|
38
|
+
merchantPublicKey: string;
|
|
39
39
|
customerId?: string;
|
|
40
40
|
orderID?: string;
|
|
41
|
-
name?: string;
|
|
42
|
-
email?: string;
|
|
43
|
-
phone?: string;
|
|
44
41
|
from?: string;
|
|
45
42
|
amount: string;
|
|
46
|
-
webname?: string;
|
|
47
43
|
discount?: string;
|
|
48
44
|
tax?: string;
|
|
49
45
|
surcharge?: string;
|
|
@@ -51,15 +47,11 @@ type Props$3 = {
|
|
|
51
47
|
declare function GetPaymentPage(props: Props$3): React.JSX.Element;
|
|
52
48
|
|
|
53
49
|
type Props$2 = {
|
|
54
|
-
|
|
50
|
+
merchantPublicKey: string;
|
|
55
51
|
customerId?: string;
|
|
56
52
|
orderID?: string;
|
|
57
|
-
name?: string;
|
|
58
|
-
email?: string;
|
|
59
|
-
phone?: string;
|
|
60
53
|
from?: string;
|
|
61
54
|
amount: string;
|
|
62
|
-
webname?: string;
|
|
63
55
|
discount?: string;
|
|
64
56
|
tax?: string;
|
|
65
57
|
surcharge?: string;
|
|
@@ -67,11 +59,8 @@ type Props$2 = {
|
|
|
67
59
|
declare function PreAuthPayment(props: Props$2): React.JSX.Element;
|
|
68
60
|
|
|
69
61
|
type Props$1 = {
|
|
70
|
-
|
|
62
|
+
merchantPublicKey: string;
|
|
71
63
|
customerId?: string;
|
|
72
|
-
name?: string;
|
|
73
|
-
email?: string;
|
|
74
|
-
phone?: string;
|
|
75
64
|
};
|
|
76
65
|
declare function AddCardEasyPay(props: Props$1): React.JSX.Element;
|
|
77
66
|
|