@tap-payments/apple-pay-button 0.0.78-development → 0.0.79-development

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.
@@ -130,7 +130,7 @@ interface Assests {
130
130
  theme: Theme;
131
131
  web: Theme;
132
132
  }
133
- declare type Theme = Record<ThemeMode, string> & {
133
+ type Theme = Record<ThemeMode, string> & {
134
134
  card: {
135
135
  light: string;
136
136
  dark: string;
@@ -1,4 +1,4 @@
1
- export declare type TapLocalizationResponse = Record<string, TapLocalization>;
1
+ export type TapLocalizationResponse = Record<string, TapLocalization>;
2
2
  export interface TapLocalization {
3
3
  ActionButton: ActionButton;
4
4
  Common: Common;
package/build/api.js CHANGED
@@ -24,7 +24,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
24
24
  function verb(n) { return function (v) { return step([n, v]); }; }
25
25
  function step(op) {
26
26
  if (f) throw new TypeError("Generator is already executing.");
27
- while (_) try {
27
+ while (g && (g = 0, op[0] && (_ = 0)), _) try {
28
28
  if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
29
29
  if (y = 0, t) op = [op[0] & 2, t.value];
30
30
  switch (op[0]) {
@@ -1,5 +1,4 @@
1
- /// <reference types="react" />
2
1
  import { ApplePayButtonProps, ApplePayRequestData } from '../../@types';
3
2
  export type { ApplePayButtonProps, ApplePayRequestData };
4
- export declare function ApplePayButton(props: ApplePayButtonProps): JSX.Element;
3
+ export declare function ApplePayButton(props: ApplePayButtonProps): import("react/jsx-runtime").JSX.Element;
5
4
  export declare const renderApplePayButton: (props: ApplePayButtonProps, elementId: string) => any;
@@ -24,7 +24,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
24
24
  function verb(n) { return function (v) { return step([n, v]); }; }
25
25
  function step(op) {
26
26
  if (f) throw new TypeError("Generator is already executing.");
27
- while (_) try {
27
+ while (g && (g = 0, op[0] && (_ = 0)), _) try {
28
28
  if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
29
29
  if (y = 0, t) op = [op[0] & 2, t.value];
30
30
  switch (op[0]) {
@@ -283,13 +283,13 @@ export var useApplePay = function (_a) {
283
283
  }
284
284
  return [3, 11];
285
285
  case 2:
286
- onSuccess === null || onSuccess === void 0 ? void 0 : onSuccess(event.payment.token.paymentData);
286
+ onSuccess === null || onSuccess === void 0 ? void 0 : onSuccess(event.payment.token);
287
287
  session_1.completePayment({ status: ApplePaySession.STATUS_SUCCESS });
288
288
  return [3, 12];
289
289
  case 3:
290
290
  setLoading(true);
291
291
  session_1.completePayment({ status: ApplePaySession.STATUS_SUCCESS });
292
- return [4, appService.tapTokenization(event.payment.token.paymentData)];
292
+ return [4, appService.tapTokenization(__assign(__assign(__assign({}, event.payment.token.paymentData), event.payment.token), { paymentData: undefined }))];
293
293
  case 4:
294
294
  data = _t.sent();
295
295
  setSuccess === null || setSuccess === void 0 ? void 0 : setSuccess(true);
@@ -298,7 +298,7 @@ export var useApplePay = function (_a) {
298
298
  case 5:
299
299
  setLoading(true);
300
300
  session_1.completePayment({ status: ApplePaySession.STATUS_SUCCESS });
301
- return [4, appService.tapTokenization(event.payment.token.paymentData)];
301
+ return [4, appService.tapTokenization(__assign(__assign(__assign({}, event.payment.token.paymentData), event.payment.token), { paymentData: undefined }))];
302
302
  case 6:
303
303
  tokenId = (_t.sent()).id;
304
304
  supportCurrency = ((_d = (_c = profileData === null || profileData === void 0 ? void 0 : profileData.payment_options) === null || _c === void 0 ? void 0 : _c.supported_currencies) !== null && _d !== void 0 ? _d : [])[0];
@@ -13,7 +13,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
13
13
  function verb(n) { return function (v) { return step([n, v]); }; }
14
14
  function step(op) {
15
15
  if (f) throw new TypeError("Generator is already executing.");
16
- while (_) try {
16
+ while (g && (g = 0, op[0] && (_ = 0)), _) try {
17
17
  if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
18
18
  if (y = 0, t) op = [op[0] & 2, t.value];
19
19
  switch (op[0]) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tap-payments/apple-pay-button",
3
- "version": "0.0.78-development",
3
+ "version": "0.0.79-development",
4
4
  "description": "Apple Pay Button React Component",
5
5
  "main": "build/index.js",
6
6
  "module": "build/index.js",