@strabl-engineering/strabl-pay 1.0.2 → 1.0.3
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/dist/index.js +2 -2
- package/dist/index.umd.cjs +1 -1
- package/dist/network/PaymentService.d.ts +2 -1
- package/dist/react.js +1 -1
- package/dist/react.umd.cjs +1 -1
- package/dist/{strabl-input.element-CkJFJ0Zt.cjs → strabl-input.element-D3e1g1EM.cjs} +10 -10
- package/dist/{strabl-input.element-DG84epQi.js → strabl-input.element-D7h9lUA5.js} +156 -138
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { S as a, a as o } from "./strabl-input.element-
|
|
2
|
-
import { c as l, i as s } from "./strabl-input.element-
|
|
1
|
+
import { S as a, a as o } from "./strabl-input.element-D7h9lUA5.js";
|
|
2
|
+
import { c as l, i as s } from "./strabl-input.element-D7h9lUA5.js";
|
|
3
3
|
function c(t) {
|
|
4
4
|
if (typeof document > "u")
|
|
5
5
|
throw new Error(
|
package/dist/index.umd.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./strabl-input.element-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./strabl-input.element-D3e1g1EM.cjs");function m(r){if(typeof document>"u")throw new Error("mountCardForm can only be called in a browser environment");customElements.get("strabl-card-form")||customElements.define("strabl-card-form",n.StrablCardForm);const o=document.querySelector(r.selector);if(!o)throw new Error(`mountCardForm: no element matched selector "${r.selector}"`);const t=document.createElement("strabl-card-form"),a=e=>{e.platformUuid!==void 0&&(t.platformUuid=e.platformUuid),e.apiKey!==void 0&&(t.apiKey=e.apiKey),e.currencyCode!==void 0&&(t.currencyCode=e.currencyCode),e.amount!==void 0&&(t.amount=e.amount),e.language!==void 0&&(t.language=e.language),e.paymentMethods!==void 0&&(t.paymentMethods=e.paymentMethods),e.customstyles!==void 0&&(t.customstyles=e.customstyles),e.customer!==void 0&&(t.customer=e.customer),e.onPaymentSubmission!==void 0&&(t.onPaymentSubmission=e.onPaymentSubmission),e.onPaymentSuccess!==void 0&&(t.onPaymentSuccess=e.onPaymentSuccess),e.onPaymentFailed!==void 0&&(t.onPaymentFailed=e.onPaymentFailed)};return a(r),r.replace?o.replaceChildren(t):o.appendChild(t),{element:t,update:e=>a(e),submit:()=>{window.dispatchEvent(new CustomEvent("strabl-submit-card-form"))},destroy:()=>t.remove()}}typeof customElements<"u"&&(customElements.get("strabl-card-form")||customElements.define("strabl-card-form",n.StrablCardForm),customElements.get("strabl-input")||customElements.define("strabl-input",n.StrablInput));Object.defineProperty(exports,"StrablCardForm",{enumerable:!0,get:()=>n.StrablCardForm});Object.defineProperty(exports,"StrablInput",{enumerable:!0,get:()=>n.StrablInput});exports.configureFonts=n.configureFonts;exports.injectGlobalFonts=n.injectGlobalFonts;exports.mountCardForm=m;
|
|
@@ -66,8 +66,9 @@ export declare class PaymentService {
|
|
|
66
66
|
[key: string]: string;
|
|
67
67
|
};
|
|
68
68
|
}): Promise<CreatePaymentIntentResponse>;
|
|
69
|
-
confirmPayment({ transactionId, }: {
|
|
69
|
+
confirmPayment({ transactionId, meta }: {
|
|
70
70
|
transactionId: string;
|
|
71
|
+
meta: object;
|
|
71
72
|
}): Promise<ConfirmPaymentResponse>;
|
|
72
73
|
createApplePaySession({ validationUrl, }: {
|
|
73
74
|
validationUrl: string;
|
package/dist/react.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as s from "react";
|
|
2
|
-
import { S as u, a as c } from "./strabl-input.element-
|
|
2
|
+
import { S as u, a as c } from "./strabl-input.element-D7h9lUA5.js";
|
|
3
3
|
typeof customElements < "u" && !customElements.get("strabl-card-form") && customElements.define("strabl-card-form", u);
|
|
4
4
|
typeof customElements < "u" && !customElements.get("strabl-input") && customElements.define("strabl-input", c);
|
|
5
5
|
const f = s.forwardRef(function(m, n) {
|
package/dist/react.umd.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("react"),c=require("./strabl-input.element-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("react"),c=require("./strabl-input.element-D3e1g1EM.cjs");function i(o){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const n in o)if(n!=="default"){const s=Object.getOwnPropertyDescriptor(o,n);Object.defineProperty(r,n,s.get?s:{enumerable:!0,get:()=>o[n]})}}return r.default=o,Object.freeze(r)}const a=i(m);typeof customElements<"u"&&!customElements.get("strabl-card-form")&&customElements.define("strabl-card-form",c.StrablCardForm);typeof customElements<"u"&&!customElements.get("strabl-input")&&customElements.define("strabl-input",c.StrablInput);const f=a.forwardRef(function(r,n){const{className:s,style:l,...e}=r,u=a.useRef(null);return a.useLayoutEffect(()=>{const t=u.current;t&&(t.paymentMethods=e.paymentMethods??["card"],t.customstyles=e.customstyles??{},t.customer=e.customer??{},t.onPaymentSubmission=e.onPaymentSubmission,t.onPaymentSuccess=e.onPaymentSuccess,t.onPaymentFailed=e.onPaymentFailed)},[e]),a.createElement("strabl-card-form",{ref:t=>{u.current=t,typeof n=="function"?n(t):n&&(n.current=t)},class:s,style:l,platformUuid:e.platformUuid,apiKey:e.apiKey,currencyCode:e.currencyCode,amount:e.amount,language:e.language||"en",fieldInputStyle:e.fieldInputStyle||"outlined"})});exports.StrablCardPaymentForm=f;
|