@payfurl/client 4.9.10 → 4.10.0

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.
Files changed (28) hide show
  1. package/CHANGELOG.md +109 -0
  2. package/README.md +183 -42
  3. package/dist/sdk/{CloseIcon-DhsqodgI.js → CloseIcon-B65NDIbM.js} +2 -2
  4. package/dist/sdk/{DefaultThreeDsProvider-qhlEMnGb.js → DefaultThreeDsProvider-CzqbXEws.js} +1 -1
  5. package/dist/sdk/{MetricsGlobalThreeDsProvider-BOEA6G5r.js → MetricsGlobalThreeDsProvider-B-EQQsEV.js} +18 -18
  6. package/dist/sdk/{PayWayAppleButton-ziK0EEr8.js → PayWayAppleButton-C-XfcgNS.js} +1 -1
  7. package/dist/sdk/{alerts-2ShoA1hc.js → alerts-BvNnAm_q.js} +1 -1
  8. package/dist/sdk/{cxpay-B2_DeDZt.js → cxpay-VbaQA3_P.js} +1 -1
  9. package/dist/sdk/{default-2G4dbyeg.js → default-Diji0SXY.js} +1 -1
  10. package/dist/sdk/{ecentric-kLMDhKl_.js → ecentric-BlNDCZo_.js} +18 -17
  11. package/dist/sdk/{epna-p_tBGPK3.js → epna-CxmJ_mqR.js} +1 -1
  12. package/dist/sdk/{flashbanc-ChTsnYMc.js → flashbanc-BAxvqtBB.js} +1 -1
  13. package/dist/sdk/{forter-BKH-4F0d.js → forter-R2alfHeE.js} +8 -8
  14. package/dist/sdk/{gpayments-Sa7Ek9FT.js → gpayments-B5KWQV4S.js} +13 -13
  15. package/dist/sdk/{metrics_global-CxURr43F.js → metrics_global-HMMDzPlb.js} +1 -1
  16. package/dist/sdk/{nmi-Bq5IGnP2.js → nmi-Ch7qQ6Av.js} +1 -1
  17. package/dist/sdk/{nuvei-BDdU_s1G.js → nuvei-DRmlfpTL.js} +4 -4
  18. package/dist/sdk/{payabli-4-XnuYBw.js → payabli-CiBJ1-vC.js} +1 -1
  19. package/dist/sdk/payfurl.d.ts +439 -0
  20. package/dist/sdk/payfurl.es.js +1524 -1527
  21. package/dist/sdk/payfurl.umd.js +8 -8
  22. package/dist/sdk/{payglocal-9n0hrZAf.js → payglocal-uAPlijwL.js} +38 -37
  23. package/dist/sdk/{payway_rest-vCmhadiN.js → payway_rest-CjgIP42z.js} +1 -1
  24. package/dist/sdk/redact-Bn_hfytX.js +46 -0
  25. package/dist/sdk/{skybank-BIJrZVJd.js → skybank-D7uRF17E.js} +1 -1
  26. package/dist/sdk/{strings-ahZ6LOKg.js → strings-BthDdeA6.js} +18 -14
  27. package/dist/sdk/style.css +1 -1
  28. package/package.json +9 -2
package/CHANGELOG.md ADDED
@@ -0,0 +1,109 @@
1
+ # Changelog
2
+
3
+ What changed in each version of the payFURL Client SDK. The `@payfurl/client` npm package and the
4
+ script on `assets.payfurl.com` share version numbers, so this covers both. The changelog starts with
5
+ version 4.9.3.
6
+
7
+ ## Unreleased
8
+
9
+ ## 4.10.0 (2026-11-04)
10
+
11
+ ### Added
12
+
13
+ - TypeScript types. The package now includes type definitions for every method, option and handler,
14
+ so your editor suggests them and the TypeScript compiler checks your calls. Import the types by
15
+ name, for example `import payfurl, { type DropInOptionsType, type SuccessResponseType } from "@payfurl/client"`.
16
+ - `setCurrency()` changes the currency of the card, Google Pay, Apple Pay and saved payment method
17
+ components already on the page, as `setAmount()` does for the amount. Add PayPal, PayTo and Checkout
18
+ components again for a new currency.
19
+ - `@payfurl/react-plugin` and `@payfurl/vue-plugin` 1.4.0 use these types for their props and events,
20
+ and their own type definitions now load.
21
+
22
+ ### Fixed
23
+
24
+ - Google Pay errors now reach your failure handler. Closing the Google Pay sheet is still not a
25
+ failure.
26
+ - The close button of the Ecentric 3-D Secure challenge now closes it.
27
+ - `@payfurl/react-plugin` 1.4.0: `PayfurlDropin` no longer fails when it mounts, and no longer rebuilds
28
+ the drop-in, losing what the shopper typed, each time its parent re-renders. A new `amount` or
29
+ `successMessage` updates the drop-in in place.
30
+
31
+ ## 4.9.10 (2026-10-29)
32
+
33
+ ### Added
34
+
35
+ - Forter fraud screening for Google Pay and Apple Pay payments, on accounts that use Forter.
36
+
37
+ ### Fixed
38
+
39
+ - When you add several components at once, each now uses its own options and provider. A component
40
+ added while another was still loading used to take the first one's.
41
+ - The loading spinner no longer reappears after a failed Forter 3-D Secure challenge.
42
+
43
+ ## 4.9.9 (2026-10-25)
44
+
45
+ ### Fixed
46
+
47
+ - PayID through Azupay now appears in the Drop In UI. A Drop In with PayID as its only payment method
48
+ never finished loading.
49
+
50
+ ## 4.9.8 (2026-10-22)
51
+
52
+ ### Added
53
+
54
+ - Forter fraud screening for `tokeniseWith3Ds`, `tokeniseCard`, `addThreeDsWithToken` and
55
+ `addSavedPaymentMethods`, on accounts that use Forter. A payment that Forter declines stops when your
56
+ account is set to stop declined payments.
57
+
58
+ ### Fixed
59
+
60
+ - PayPal payments on accounts that use Forter no longer fail at the fraud check.
61
+ - A card that skips 3-D Secure through network token authentication still gets the fraud check.
62
+ - A payment no longer waits forever when the fraud check or a Forter 3-D Secure result never answers:
63
+ your failure handler is called instead.
64
+
65
+ ## 4.9.7 (2026-10-21)
66
+
67
+ ### Fixed
68
+
69
+ - A Forter 3-D Secure challenge no longer fails when Forter's script loads after the challenge starts.
70
+
71
+ ## 4.9.6 (2026-10-19)
72
+
73
+ ### Added
74
+
75
+ - Google Pay for CyberSource and NAB Gateway.
76
+ - The `billingDetailsRequired` Google Pay option, for `addGooglePay` and the Drop In's
77
+ `googlePayOptions`: `true` asks the shopper for their email address and full billing address.
78
+ CyberSource and NAB Gateway need it unless you pass the customer's name, email and billing address
79
+ yourself.
80
+
81
+ ## 4.9.5 (2026-10-13)
82
+
83
+ ### Changed
84
+
85
+ - Internal improvements. Nothing changes in how you use the SDK.
86
+
87
+ ## 4.9.4 (2026-10-12)
88
+
89
+ ### Security
90
+
91
+ - 3-D Secure on a saved card token (`addThreeDsWithToken`) no longer brings the card's details into the
92
+ browser: it runs on the card your gateway stores.
93
+
94
+ ### Fixed
95
+
96
+ - Nuvei 3-D Secure stops after it reports a failure, instead of opening the challenge as well.
97
+
98
+ ## 4.9.3 (2026-10-08)
99
+
100
+ ### Added
101
+
102
+ - The Apple Pay button now appears in Chrome, Firefox and Edge, where Apple lets shoppers pay with
103
+ their iPhone. It used to appear in Safari only.
104
+ - Forter as a 3-D Secure provider on its own, without Forter fraud screening.
105
+
106
+ ### Fixed
107
+
108
+ - A Forter 3-D Secure challenge whose result is anything but a success now fails the payment.
109
+ - Forter's scripts use your account's Forter site ID.
package/README.md CHANGED
@@ -1,65 +1,206 @@
1
- # PayFURL Client SDK
1
+ # payFURL Client SDK
2
2
 
3
- The Client SDK is used to securely collect payment details in the browser. It seamlessly integrates into your existing payment page.
3
+ Collect payment details in the browser and turn them into a payFURL payment token that your server
4
+ charges through the [payFURL API](https://docs.payfurl.com/guides). Cards, PayPal, Google Pay, Apple
5
+ Pay, PayTo, Click to Pay and more, through one integration.
4
6
 
5
- When initialized, the SDK securely loads an iframe hosted by payFURL.
6
- This iframe collects the payment details, which are then submitted to payFURL and converted to a payment token.
7
- The payment token is added as a hidden input to the form. For PayPal or Buy Now Pay Later payments, the payment details are converted to a transactionId, which is also added as a hidden input to the form.
8
- Payment detail collection is triggered when the form is submitted.
7
+ Card details are typed into fields that payFURL hosts in an iframe, so card numbers never reach your
8
+ page's code.
9
9
 
10
- ## Integrate with your app
10
+ [Documentation](https://docs.payfurl.com/client_sdk/overview) ·
11
+ [API reference](https://docs.payfurl.com/client_sdk/reference) ·
12
+ [Changelog](https://docs.payfurl.com/client_sdk/changelog) ·
13
+ [Support](https://docs.payfurl.com/support)
11
14
 
12
- If you want to use the published PayFURL Client SDK in your application, install it from npm:
15
+ ## Install
13
16
 
14
- ```bash
15
- npm install @payfurl/client
16
- ```
17
+ ```bash
18
+ npm install @payfurl/client
19
+ ```
17
20
 
18
- Import the SDK into your application:
21
+ To load the SDK from a `<script>` tag instead, see
22
+ [Get started](https://docs.payfurl.com/client_sdk/get_started).
19
23
 
20
- ```javascript
21
- import payfurl from '@payfurl/client';
22
- ```
24
+ ## Quick start
23
25
 
24
- ## Usage
26
+ Add a container inside your payment form:
25
27
 
26
- To initialize the SDK, use the following code:
28
+ ```html
29
+ <form method="POST" action="/pay">
30
+ <div id="payment"></div>
31
+ <button type="submit">Pay</button>
32
+ </form>
33
+ ```
27
34
 
28
- ```javascript
29
- import payfurl from '@payfurl/client';
30
- const pf = payfurl.init(
31
- "sandbox", // environment name
32
- "<public-key>", // your public key
33
- true // enable debug mode
34
- );
35
- ```
35
+ Then add the Drop In UI, which shows every payment method your account has for the amount and
36
+ currency:
36
37
 
37
- To create a drop-in UI:
38
+ ```javascript
39
+ import payfurl from "@payfurl/client";
38
40
 
39
- ```javascript
40
- pf.addDropIn('<id-of-div-container>', 20, 'AUD');
41
- ```
41
+ payfurl
42
+ .init("sandbox", "<your public key>")
43
+ .addDropIn("payment", 20, "AUD");
44
+ ```
42
45
 
43
- ## Local development
46
+ When the shopper submits the form, the SDK collects the payment details, adds the result to the form
47
+ as a hidden input, and submits it to your server: `token` for a card, `transactionId` for PayPal and
48
+ other payment types that complete the payment themselves. To keep the shopper on the page, handle the
49
+ result yourself:
50
+
51
+ ```javascript
52
+ payfurl
53
+ .onSuccess((message) => {
54
+ // message.token for a card, message.transactionId for PayPal and other payment types
55
+ // that complete the payment themselves
56
+ })
57
+ .onFailure((message) => console.error(message.error));
58
+ ```
44
59
 
45
- If you are working in this repository, install the project dependencies with:
60
+ Your public key is on **Account Info** in the payFURL dashboard. Use `"production"` and a production
61
+ key to go live.
46
62
 
47
- ```bash
48
- npm install
49
- ```
63
+ ## Payment methods
50
64
 
51
- ## Local testing
65
+ | Method | Adds |
66
+ |---|---|
67
+ | `addDropIn` | Every payment method on your account, in one component |
68
+ | `addCard` | A card form |
69
+ | `addPaypal` | PayPal buttons |
70
+ | `addGooglePay` | A Google Pay button |
71
+ | `addApplePay` | An Apple Pay button |
72
+ | `addPayTo` | A PayTo agreement form |
73
+ | `addCheckout` | A third-party checkout, such as Afterpay or Affirm |
74
+ | `addSavedPaymentMethods` | A customer's saved cards |
52
75
 
53
- To serve the SDK locally for testing, run:
76
+ Each has its own page in the [documentation](https://docs.payfurl.com/client_sdk/overview), with its
77
+ options.
54
78
 
55
- ```bash
56
- npm run server
79
+ ## TypeScript
80
+
81
+ The package includes its type definitions. Every option type can be imported by name:
82
+
83
+ ```typescript
84
+ import payfurl, { type DropInOptionsType, type SuccessResponseType } from "@payfurl/client";
85
+
86
+ const options: DropInOptionsType = { allowedPaymentTypes: ["card", "googlepay"] };
87
+ payfurl.init("sandbox", "<your public key>")
88
+ .addDropIn("payment", 20, "AUD", options)
89
+ .onSuccess((message: SuccessResponseType) => console.log(message.token));
57
90
  ```
58
91
 
59
- This starts a local HTTP server on port `3001`.
92
+ ## React and Vue
93
+
94
+ [`@payfurl/react-plugin`](https://www.npmjs.com/package/@payfurl/react-plugin) and
95
+ [`@payfurl/vue-plugin`](https://www.npmjs.com/package/@payfurl/vue-plugin) wrap the Drop In UI in a
96
+ component: see [React](https://docs.payfurl.com/client_sdk/frameworks/react) and
97
+ [Vue](https://docs.payfurl.com/client_sdk/frameworks/vue).
98
+
99
+ ## Changelog
100
+
101
+ What changed in each version of the payFURL Client SDK. The `@payfurl/client` npm package and the
102
+ script on `assets.payfurl.com` share version numbers, so this covers both. The changelog starts with
103
+ version 4.9.3.
104
+
105
+
106
+ ### 4.10.0 (2026-11-04)
107
+
108
+ #### Added
109
+
110
+ - TypeScript types. The package now includes type definitions for every method, option and handler,
111
+ so your editor suggests them and the TypeScript compiler checks your calls. Import the types by
112
+ name, for example `import payfurl, { type DropInOptionsType, type SuccessResponseType } from "@payfurl/client"`.
113
+ - `setCurrency()` changes the currency of the card, Google Pay, Apple Pay and saved payment method
114
+ components already on the page, as `setAmount()` does for the amount. Add PayPal, PayTo and Checkout
115
+ components again for a new currency.
116
+ - `@payfurl/react-plugin` and `@payfurl/vue-plugin` 1.4.0 use these types for their props and events,
117
+ and their own type definitions now load.
118
+
119
+ #### Fixed
120
+
121
+ - Google Pay errors now reach your failure handler. Closing the Google Pay sheet is still not a
122
+ failure.
123
+ - The close button of the Ecentric 3-D Secure challenge now closes it.
124
+ - `@payfurl/react-plugin` 1.4.0: `PayfurlDropin` no longer fails when it mounts, and no longer rebuilds
125
+ the drop-in, losing what the shopper typed, each time its parent re-renders. A new `amount` or
126
+ `successMessage` updates the drop-in in place.
127
+
128
+ ### 4.9.10 (2026-10-29)
129
+
130
+ #### Added
131
+
132
+ - Forter fraud screening for Google Pay and Apple Pay payments, on accounts that use Forter.
133
+
134
+ #### Fixed
135
+
136
+ - When you add several components at once, each now uses its own options and provider. A component
137
+ added while another was still loading used to take the first one's.
138
+ - The loading spinner no longer reappears after a failed Forter 3-D Secure challenge.
139
+
140
+ ### 4.9.9 (2026-10-25)
141
+
142
+ #### Fixed
143
+
144
+ - PayID through Azupay now appears in the Drop In UI. A Drop In with PayID as its only payment method
145
+ never finished loading.
146
+
147
+ ### 4.9.8 (2026-10-22)
148
+
149
+ #### Added
150
+
151
+ - Forter fraud screening for `tokeniseWith3Ds`, `tokeniseCard`, `addThreeDsWithToken` and
152
+ `addSavedPaymentMethods`, on accounts that use Forter. A payment that Forter declines stops when your
153
+ account is set to stop declined payments.
154
+
155
+ #### Fixed
156
+
157
+ - PayPal payments on accounts that use Forter no longer fail at the fraud check.
158
+ - A card that skips 3-D Secure through network token authentication still gets the fraud check.
159
+ - A payment no longer waits forever when the fraud check or a Forter 3-D Secure result never answers:
160
+ your failure handler is called instead.
161
+
162
+ ### 4.9.7 (2026-10-21)
163
+
164
+ #### Fixed
165
+
166
+ - A Forter 3-D Secure challenge no longer fails when Forter's script loads after the challenge starts.
167
+
168
+ ### 4.9.6 (2026-10-19)
169
+
170
+ #### Added
171
+
172
+ - Google Pay for CyberSource and NAB Gateway.
173
+ - The `billingDetailsRequired` Google Pay option, for `addGooglePay` and the Drop In's
174
+ `googlePayOptions`: `true` asks the shopper for their email address and full billing address.
175
+ CyberSource and NAB Gateway need it unless you pass the customer's name, email and billing address
176
+ yourself.
177
+
178
+ ### 4.9.5 (2026-10-13)
179
+
180
+ #### Changed
181
+
182
+ - Internal improvements. Nothing changes in how you use the SDK.
183
+
184
+ ### 4.9.4 (2026-10-12)
185
+
186
+ #### Security
187
+
188
+ - 3-D Secure on a saved card token (`addThreeDsWithToken`) no longer brings the card's details into the
189
+ browser: it runs on the card your gateway stores.
190
+
191
+ #### Fixed
192
+
193
+ - Nuvei 3-D Secure stops after it reports a failure, instead of opening the challenge as well.
194
+
195
+ ### 4.9.3 (2026-10-08)
196
+
197
+ #### Added
60
198
 
61
- To open the SDK main page in your browser, go to `http://localhost:3001/sdk.html`.
199
+ - The Apple Pay button now appears in Chrome, Firefox and Edge, where Apple lets shoppers pay with
200
+ their iPhone. It used to appear in Safari only.
201
+ - Forter as a 3-D Secure provider on its own, without Forter fraud screening.
62
202
 
63
- ## More info
203
+ #### Fixed
64
204
 
65
- For more thorough documentation, visit [the PayFURL Client SDK docs](https://docs.payfurl.com/client_sdk/).
205
+ - A Forter 3-D Secure challenge whose result is anything but a success now fails the payment.
206
+ - Forter's scripts use your account's Forter site ID.
@@ -3418,7 +3418,7 @@ var as = (e, t) => {
3418
3418
  },
3419
3419
  setup(e) {
3420
3420
  let t = e;
3421
- return t.color, t.size, (n, r) => t.useLocal ? (Ki(), Zi("div", cs, [...r[1] ||= [
3421
+ return (n, r) => t.useLocal ? (Ki(), Zi("div", cs, [...r[1] ||= [
3422
3422
  X("div", null, null, -1),
3423
3423
  X("div", null, null, -1),
3424
3424
  X("div", null, null, -1),
@@ -3446,7 +3446,7 @@ var as = (e, t) => {
3446
3446
  X("div")
3447
3447
  ], -1)]));
3448
3448
  }
3449
- }), [["__scopeId", "data-v-16bb7d59"]]), us = "compact", ds = "payfurl-init", fs = "init-card-form", ps = "checkout-ready", ms = "submit-card-form", hs = "tokenise-card-form", gs = "request-card", _s = "card-details", vs = "secure-orchestrator-ready", ys = "secure-orchestrator-submit", bs = "secure-orchestrator-submit-secondary-3ds", xs = "secure-orchestrator-tokenise", Ss = "secure-orchestrator-failure", Cs = "secure-orchestrator-update-state", ws = "secure-orchestrator-click-to-pay-card", Ts = "secure-orchestrator-click-to-pay-new-card", Es = "secure-orchestrator-show-challenge", Ds = "secure-orchestrator-hide-challenge", Os = "iframe-has-changed", ks = "show-spinner", As = "hide-spinner", js = "set-amount", Ms = "set-currency", Ns = "set-billing-address", Ps = "set-customer-info", Fs = "set-order-info", Is = "tokenise-card-success", Ls = "tokenise-card-failure", Rs = "click2pay-cards", zs = "click2pay-remember-me", Bs = "click2pay-show-learn-more", Vs = "show-card-form", Hs = "start-loading-card-form", Us = "stop-loading-card-form", Ws = "pause-loading-card-form", Gs = "unpause-loading-card-form", Ks = "click2pay-change-user", qs = "click2pay-stop-using", Js = "click2pay-update-available-card-brands", Ys = "card-form-error", Xs = "card-form-info-message", Zs = "card-form-validation-error", Qs = "card-form-validation-status-change", $s = "Payment Details Collected", ec = "3D Secure required", tc = "3D Secure failed", nc = "Unable to process payment details", $ = null;
3449
+ }), [["__scopeId", "data-v-2b4dad6b"]]), us = "compact", ds = "payfurl-init", fs = "init-card-form", ps = "checkout-ready", ms = "submit-card-form", hs = "tokenise-card-form", gs = "request-card", _s = "card-details", vs = "secure-orchestrator-ready", ys = "secure-orchestrator-submit", bs = "secure-orchestrator-submit-secondary-3ds", xs = "secure-orchestrator-tokenise", Ss = "secure-orchestrator-failure", Cs = "secure-orchestrator-update-state", ws = "secure-orchestrator-click-to-pay-card", Ts = "secure-orchestrator-click-to-pay-new-card", Es = "secure-orchestrator-show-challenge", Ds = "secure-orchestrator-hide-challenge", Os = "iframe-has-changed", ks = "show-spinner", As = "hide-spinner", js = "set-amount", Ms = "set-currency", Ns = "set-billing-address", Ps = "set-customer-info", Fs = "set-order-info", Is = "tokenise-card-success", Ls = "tokenise-card-failure", Rs = "click2pay-cards", zs = "click2pay-remember-me", Bs = "click2pay-show-learn-more", Vs = "show-card-form", Hs = "start-loading-card-form", Us = "stop-loading-card-form", Ws = "pause-loading-card-form", Gs = "unpause-loading-card-form", Ks = "click2pay-change-user", qs = "click2pay-stop-using", Js = "click2pay-update-available-card-brands", Ys = "card-form-error", Xs = "card-form-info-message", Zs = "card-form-validation-error", Qs = "card-form-validation-status-change", $s = "Payment Details Collected", ec = "3D Secure required", tc = "3D Secure failed", nc = "Unable to process payment details", $ = null;
3450
3450
  function rc() {
3451
3451
  window.self === window.top ? ($ || ac(), $ && ($.style.display = "none")) : window.parent.postMessage({ status: As }, "*");
3452
3452
  }
@@ -1,4 +1,4 @@
1
- import { A as e, Et as t, It as n, Lt as r, O as i, Ot as a, Tt as o, Z as s, _t as c, ct as l, dt as u, h as d, n as f, t as p, vt as m, wt as h, xt as g } from "./CloseIcon-DhsqodgI.js";
1
+ import { A as e, Et as t, It as n, Lt as r, O as i, Ot as a, Tt as o, Z as s, _t as c, ct as l, dt as u, h as d, n as f, t as p, vt as m, wt as h, xt as g } from "./CloseIcon-B65NDIbM.js";
2
2
  // src/sdk/3ds/ThreeDsChallenge.vue?vue&type=script&setup=true&lang.ts
3
3
  var _ = { class: "mask" }, v = { class: "wrapper" }, y = { class: "container" }, b = ["action"], x = ["value"], S = /*#__PURE__*/ s(/* @__PURE__ */ o({
4
4
  __name: "ThreeDsChallenge",
@@ -1,26 +1,26 @@
1
- import { Dt as e, Et as t, Ft as n, It as r, Ot as i, Tt as a, Z as o, dt as s, mt as c, n as l, t as u, vt as d, wt as f, xt as p } from "./CloseIcon-DhsqodgI.js";
2
- import { t as m } from "./screen-aNRlfrZR.js";
3
- import { t as h } from "./alerts-2ShoA1hc.js";
4
- import { t as g } from "./DefaultThreeDsProvider-qhlEMnGb.js";
1
+ import { t as e } from "./DefaultThreeDsProvider-CzqbXEws.js";
2
+ import { Dt as t, Et as n, Ft as r, It as i, Ot as a, Tt as o, Z as s, dt as c, mt as l, n as u, t as d, vt as f, wt as p, xt as m } from "./CloseIcon-B65NDIbM.js";
3
+ import { t as h } from "./alerts-BvNnAm_q.js";
4
+ import { t as g } from "./screen-aNRlfrZR.js";
5
5
  // src/sdk/3ds/MetricsGlobalThreeDsChallenge.vue?vue&type=script&setup=true&lang.ts
6
- var _ = { class: "mask" }, v = { class: "wrapper" }, y = { class: "container" }, b = /*#__PURE__*/ o(/* @__PURE__ */ a({
6
+ var _ = { class: "mask" }, v = { class: "wrapper" }, y = { class: "container" }, b = /*#__PURE__*/ s(/* @__PURE__ */ o({
7
7
  __name: "MetricsGlobalThreeDsChallenge",
8
8
  emits: ["close", "submit"],
9
- setup(a, { emit: o }) {
10
- let s = o, l = r(!1);
11
- function m(e) {
12
- ["3DS_CHALLENGE_SHOW", "3DS_CHALLENGE_CLOSE"].includes(e.data?.message) && (l.value = e.data.message === "3DS_CHALLENGE_SHOW");
9
+ setup(e, { emit: o }) {
10
+ let s = o, c = i(!1);
11
+ function u(e) {
12
+ ["3DS_CHALLENGE_SHOW", "3DS_CHALLENGE_CLOSE"].includes(e.data?.message) && (c.value = e.data.message === "3DS_CHALLENGE_SHOW");
13
13
  }
14
- return t(() => {
15
- window.addEventListener("message", m);
16
- }), e(() => {
17
- window.removeEventListener("message", m);
18
- }), (e, t) => n((i(), p("div", _, [d("div", v, [d("div", y, [f(u, {
14
+ return n(() => {
15
+ window.addEventListener("message", u);
16
+ }), t(() => {
17
+ window.removeEventListener("message", u);
18
+ }), (e, t) => r((a(), m("div", _, [f("div", v, [f("div", y, [p(d, {
19
19
  onClick: t[0] ||= (e) => s("close"),
20
20
  id: "3ds-challenge-close"
21
- }), t[1] ||= d("div", { id: "ThreeDsChallengeIFrame" }, null, -1)])])], 512)), [[c, l.value]]);
21
+ }), t[1] ||= f("div", { id: "ThreeDsChallengeIFrame" }, null, -1)])])], 512)), [[l, c.value]]);
22
22
  }
23
- }), [["__scopeId", "data-v-8a0b6dcb"]]), { hideSpinner: x, showSpinner: S } = l(), C = 5, w = class extends g {
23
+ }), [["__scopeId", "data-v-8a0b6dcb"]]), { hideSpinner: x, showSpinner: S } = u(), C = 5, w = class extends e {
24
24
  gateway;
25
25
  threeDS;
26
26
  numAttempts = 0;
@@ -75,7 +75,7 @@ var _ = { class: "mask" }, v = { class: "wrapper" }, y = { class: "container" },
75
75
  browserJavascriptEnabled: !0,
76
76
  browserJavaEnabled: !1,
77
77
  browserLanguage: window.navigator.language,
78
- browserColorDepth: String(m()),
78
+ browserColorDepth: String(g()),
79
79
  browserScreenHeight: String(screen.height),
80
80
  browserScreenWidth: String(screen.width),
81
81
  browserTimeZone: String(Math.round((/* @__PURE__ */ new Date()).getTimezoneOffset() / 60)),
@@ -103,7 +103,7 @@ var _ = { class: "mask" }, v = { class: "wrapper" }, y = { class: "container" },
103
103
  });
104
104
  }
105
105
  initChallenge() {
106
- let { destroy: e } = s({
106
+ let { destroy: e } = c({
107
107
  el: document.body,
108
108
  component: b,
109
109
  on: { close: () => {
@@ -1,4 +1,4 @@
1
- import { o as e, r as t, s as n } from "./strings-ahZ6LOKg.js";
1
+ import { o as e, r as t, s as n } from "./strings-BthDdeA6.js";
2
2
  // src/sdk/processors/applepay/PayWayAppleButton.ts
3
3
  var r = {
4
4
  CHECKOUT: "CHECKOUT",
@@ -1,4 +1,4 @@
1
- import { Bt as e, It as t, Ot as n, Tt as r, Z as i, bt as a, dt as o, gt as s, vt as c, xt as l } from "./CloseIcon-DhsqodgI.js";
1
+ import { Bt as e, It as t, Ot as n, Tt as r, Z as i, bt as a, dt as o, gt as s, vt as c, xt as l } from "./CloseIcon-B65NDIbM.js";
2
2
  // src/sdk/components/Error.vue?vue&type=script&setup=true&lang.ts
3
3
  var u = { class: "message" }, d = /*#__PURE__*/ i(/* @__PURE__ */ r({
4
4
  __name: "Error",
@@ -1,4 +1,4 @@
1
- import { t as e } from "./MetricsGlobalThreeDsProvider-BOEA6G5r.js";
1
+ import { t as e } from "./MetricsGlobalThreeDsProvider-B-EQQsEV.js";
2
2
  // src/sdk/3ds/CxPayThreeDsProvider.ts
3
3
  var t = class extends e {
4
4
  getType() {
@@ -1,4 +1,4 @@
1
- import { t as e } from "./DefaultThreeDsProvider-qhlEMnGb.js";
1
+ import { t as e } from "./DefaultThreeDsProvider-CzqbXEws.js";
2
2
  // src/sdk/3ds/default.ts
3
3
  function t(t, n, r) {
4
4
  return new e(t, n, r);
@@ -1,7 +1,7 @@
1
- import { Et as e, It as t, Lt as n, Ot as r, Tt as i, Z as a, _t as o, ct as s, dt as c, t as l, vt as u, wt as d, xt as f } from "./CloseIcon-DhsqodgI.js";
2
- import { t as p } from "./DefaultThreeDsProvider-qhlEMnGb.js";
1
+ import { t as e } from "./DefaultThreeDsProvider-CzqbXEws.js";
2
+ import { Et as t, It as n, Lt as r, Ot as i, Tt as a, Z as o, _t as s, ct as c, dt as l, t as u, vt as d, wt as f, xt as p } from "./CloseIcon-B65NDIbM.js";
3
3
  // src/sdk/3ds/ecentric.vue?vue&type=script&setup=true&lang.ts
4
- var m = { class: "mask" }, h = { class: "wrapper" }, g = { class: "container" }, _ = ["action"], v = ["value"], y = /*#__PURE__*/ a(/* @__PURE__ */ i({
4
+ var m = { class: "mask" }, h = { class: "wrapper" }, g = { class: "container" }, _ = ["action"], v = ["value"], y = /*#__PURE__*/ o(/* @__PURE__ */ a({
5
5
  __name: "ecentric",
6
6
  props: {
7
7
  threeDSServerTransID: {},
@@ -9,27 +9,28 @@ var m = { class: "mask" }, h = { class: "wrapper" }, g = { class: "container" },
9
9
  formAction: {},
10
10
  authenticationValue: {}
11
11
  },
12
- setup(i) {
13
- let a = i, c = o(() => s(a.formAction) ? a.formAction : ""), p = t(null), y = a.authenticationValue;
14
- return e(() => {
15
- c.value && p.value?.submit();
16
- }), (e, t) => (r(), f("div", m, [u("div", h, [u("div", g, [
17
- d(l, { onClick: t[0] ||= (t) => e.emit("close") }),
18
- t[1] ||= u("iframe", { name: "ThreeDsChallengeIFrame" }, null, -1),
19
- u("form", {
20
- action: c.value,
12
+ emits: ["close", "submit"],
13
+ setup(e, { emit: a }) {
14
+ let o = e, l = a, y = s(() => c(o.formAction) ? o.formAction : ""), b = n(null), x = o.authenticationValue;
15
+ return t(() => {
16
+ y.value && b.value?.submit();
17
+ }), (e, t) => (i(), p("div", m, [d("div", h, [d("div", g, [
18
+ f(u, { onClick: t[0] ||= (e) => l("close") }),
19
+ t[1] ||= d("iframe", { name: "ThreeDsChallengeIFrame" }, null, -1),
20
+ d("form", {
21
+ action: y.value,
21
22
  target: "ThreeDsChallengeIFrame",
22
23
  method: "post",
23
24
  ref_key: "form",
24
- ref: p
25
- }, [u("input", {
25
+ ref: b
26
+ }, [d("input", {
26
27
  type: "hidden",
27
28
  name: "PaReq",
28
- value: n(y)
29
+ value: r(x)
29
30
  }, null, 8, v)], 8, _)
30
31
  ])])]));
31
32
  }
32
- }), [["__scopeId", "data-v-8ededb9d"]]), b = class extends p {
33
+ }), [["__scopeId", "data-v-bdfafa40"]]), b = class extends e {
33
34
  paResPayload = "";
34
35
  getType() {
35
36
  return "Ecentric";
@@ -45,7 +46,7 @@ var m = { class: "mask" }, h = { class: "wrapper" }, g = { class: "container" },
45
46
  }
46
47
  doChallenge(e, t, n) {
47
48
  this.log(`[${this.getType()}][doChallenge]`), this.setChallengeFrameVisible(!0);
48
- let { destroy: r } = c({
49
+ let { destroy: r } = l({
49
50
  el: document.body,
50
51
  component: y,
51
52
  props: {
@@ -1,4 +1,4 @@
1
- import { t as e } from "./MetricsGlobalThreeDsProvider-BOEA6G5r.js";
1
+ import { t as e } from "./MetricsGlobalThreeDsProvider-B-EQQsEV.js";
2
2
  // src/sdk/3ds/EpnaThreeDsProvider.ts
3
3
  var t = class extends e {
4
4
  getType() {
@@ -1,4 +1,4 @@
1
- import { t as e } from "./MetricsGlobalThreeDsProvider-BOEA6G5r.js";
1
+ import { t as e } from "./MetricsGlobalThreeDsProvider-B-EQQsEV.js";
2
2
  // src/sdk/3ds/FlashBancThreeDsProvider.ts
3
3
  var t = class extends e {
4
4
  getType() {
@@ -1,17 +1,17 @@
1
- import { n as e } from "./CloseIcon-DhsqodgI.js";
2
- import { t } from "./DefaultThreeDsProvider-qhlEMnGb.js";
3
- import { n, r, t as i } from "./managedOrders-ojoMZ0Ab.js";
1
+ import { t as e } from "./DefaultThreeDsProvider-CzqbXEws.js";
2
+ import { n as t, r as n, t as r } from "./managedOrders-ojoMZ0Ab.js";
3
+ import { n as i } from "./CloseIcon-B65NDIbM.js";
4
4
  // src/sdk/3ds/ForterThreeDsProvider.ts
5
- var { hideSpinner: a } = e(), o = class extends t {
5
+ var { hideSpinner: a } = i(), o = class extends e {
6
6
  getType() {
7
7
  return "Forter";
8
8
  }
9
- onDoAuthSuccess = (e, t) => {
10
- let o = JSON.parse(t);
9
+ onDoAuthSuccess = (e, i) => {
10
+ let o = JSON.parse(i);
11
11
  this.log(`[${this.getType()}][onDoAuthSuccess]`, o);
12
12
  let s = this.options.clientParameters?.SiteId || "", c = o.managedOrderToken;
13
- !c || !i.test(s) ? this.onError(e, "3DS could not be started") : n(s).then(() => {
14
- this.setChallengeFrameVisible(!0), a(), r(c, this.container, (e) => {
13
+ !c || !r.test(s) ? this.onError(e, "3DS could not be started") : t(s).then(() => {
14
+ this.setChallengeFrameVisible(!0), a(), n(c, this.container, (e) => {
15
15
  this.setChallengeFrameVisible(!1), e ? (this.log(`[${this.getType()}]: manageOrder failed`, e), this.onError(400, "3DS failed")) : this.onPostAuth();
16
16
  });
17
17
  }, (e) => {
@@ -1,39 +1,39 @@
1
- import { Ot as e, Tt as t, Z as n, _t as r, ct as i, dt as a, n as o, vt as s, xt as c, zt as l } from "./CloseIcon-DhsqodgI.js";
2
- import { t as u } from "./DefaultThreeDsProvider-qhlEMnGb.js";
1
+ import { t as e } from "./DefaultThreeDsProvider-CzqbXEws.js";
2
+ import { Ot as t, Tt as n, Z as r, _t as i, ct as a, dt as o, n as s, vt as c, xt as l, zt as u } from "./CloseIcon-B65NDIbM.js";
3
3
  // src/sdk/3ds/GPayments.vue?vue&type=script&setup=true&lang.ts
4
- var d = { class: "mask" }, f = { class: "wrapper" }, p = ["src"], m = /*#__PURE__*/ n(/* @__PURE__ */ t({
4
+ var d = { class: "mask" }, f = { class: "wrapper" }, p = ["src"], m = /*#__PURE__*/ r(/* @__PURE__ */ n({
5
5
  __name: "GPayments",
6
6
  props: {
7
7
  url: {},
8
8
  width: {},
9
9
  height: {}
10
10
  },
11
- setup(t) {
12
- let n = t, a = r(() => i(n.url) ? n.url : "");
11
+ setup(e) {
12
+ let n = e, r = i(() => a(n.url) ? n.url : "");
13
13
  function o() {
14
14
  return {
15
15
  width: `${n.width || 650}px`,
16
16
  height: `${n.height || 400}px`
17
17
  };
18
18
  }
19
- return (t, n) => (e(), c("div", d, [s("div", f, [s("div", {
19
+ return (e, n) => (t(), l("div", d, [c("div", f, [c("div", {
20
20
  class: "container",
21
- style: l([o(), {
21
+ style: u([o(), {
22
22
  padding: "0",
23
23
  margin: "0"
24
24
  }])
25
- }, [s("iframe", {
26
- src: a.value,
27
- style: l(o())
25
+ }, [c("iframe", {
26
+ src: r.value,
27
+ style: u(o())
28
28
  }, null, 12, p)], 4)])]));
29
29
  }
30
- }), [["__scopeId", "data-v-cf5aa816"]]), { hideSpinner: h } = o(), g = class extends u {
30
+ }), [["__scopeId", "data-v-cf5aa816"]]), { hideSpinner: h } = s(), g = class extends e {
31
31
  getType() {
32
32
  return "GPayments";
33
33
  }
34
34
  doChallenge(e) {
35
35
  this.log(`[${this.getType()}][doChallenge]`), h(), this.setChallengeFrameVisible(!0);
36
- let { destroy: t } = a({
36
+ let { destroy: t } = o({
37
37
  el: document.body,
38
38
  component: m,
39
39
  props: {
@@ -69,7 +69,7 @@ var d = { class: "mask" }, f = { class: "wrapper" }, p = ["src"], m = /*#__PURE_
69
69
  this.log(`[${this.getType()}][onInitAuthSuccess]`, n), n.threeDSAuthURL ? (this.threeDSRequestorTransID = n.threeDSRequestorTransID, this.threeDSServerTransID = n.threeDSServerTransID, this.threeDSMonitorURL = n.threeDSMonitorURL, this.threeDSAuthURL = n.threeDSAuthURL, n.threeDsServerCallbackUrl ? this.initFrame(n.threeDsServerCallbackUrl) : this.onAuth(!1, "")) : this.onError(e, "No AuthUrl specified");
70
70
  };
71
71
  initFrame(e) {
72
- if (this.log(`[${this.getType()}][init3DSFrame]`, e), !i(e)) return;
72
+ if (this.log(`[${this.getType()}][init3DSFrame]`, e), !a(e)) return;
73
73
  let t = document.createElement("iframe");
74
74
  t.src = e, t.style.width = "1px", t.style.height = "1px", t.style.border = "0", document.body.appendChild(t);
75
75
  }