@coinflowlabs/angular 1.7.2 → 1.9.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.
@@ -10,6 +10,7 @@ var WithdrawCategory;
10
10
  (function (WithdrawCategory) {
11
11
  WithdrawCategory["USER"] = "user";
12
12
  WithdrawCategory["BUSINESS"] = "business";
13
+ WithdrawCategory["FIRST_PARTY"] = "firstParty";
13
14
  })(WithdrawCategory || (WithdrawCategory = {}));
14
15
  var WithdrawSpeed;
15
16
  (function (WithdrawSpeed) {
@@ -67,8 +68,8 @@ var PaymentMethods;
67
68
  PaymentMethods["applePay"] = "applePay";
68
69
  PaymentMethods["credits"] = "credits";
69
70
  PaymentMethods["crypto"] = "crypto";
70
- PaymentMethods["instantBankTransfer"] = "instantBankTransfer";
71
71
  PaymentMethods["wire"] = "wire";
72
+ PaymentMethods["cashApp"] = "cashApp";
72
73
  })(PaymentMethods || (PaymentMethods = {}));
73
74
  const paymentMethodLabels = {
74
75
  [PaymentMethods.card]: 'Card',
@@ -81,8 +82,8 @@ const paymentMethodLabels = {
81
82
  [PaymentMethods.applePay]: 'Apple Pay',
82
83
  [PaymentMethods.credits]: 'Credits',
83
84
  [PaymentMethods.crypto]: 'Crypto',
84
- [PaymentMethods.instantBankTransfer]: 'Instant Bank Transfer',
85
85
  [PaymentMethods.wire]: 'Wire Transfer',
86
+ [PaymentMethods.cashApp]: 'CashApp',
86
87
  };
87
88
  var CardType;
88
89
  (function (CardType) {
@@ -483,8 +484,20 @@ function getCurrencyDecimals(currency) {
483
484
  function isTypedCurrencyCents(cents, currency) {
484
485
  return cents.currency === currency;
485
486
  }
487
+ function invertRate(ex) {
488
+ return {
489
+ base: ex.to,
490
+ rate: 1 / ex.rate,
491
+ to: ex.base,
492
+ };
493
+ }
486
494
 
487
- function fun() {
495
+ function getNSureDeviceId() {
496
+ if (typeof window !== 'undefined') {
497
+ const urlDeviceId = new URLSearchParams(window.location.search).get('deviceId');
498
+ if (urlDeviceId)
499
+ return urlDeviceId;
500
+ }
488
501
  if (nsureSDK)
489
502
  return nsureSDK.getDeviceId();
490
503
  return null;
@@ -536,7 +549,7 @@ class CoinflowUtils {
536
549
  return 'http://localhost:5000';
537
550
  return `https://api-${env}.coinflow.cash`;
538
551
  }
539
- static getCoinflowUrl({ walletPubkey, sessionKey, route, routePrefix, env, subtotal, customPayInFees, presentment, transaction, blockchain = 'solana', webhookInfo, email, loaderBackground, handleHeightChangeId, bankAccountLinkRedirect, additionalWallets, chargebackProtectionData, chargebackProtectionAccountType, merchantCss, color, rent, lockDefaultToken, tokens, planCode, disableApplePay, disableGooglePay, customerInfo, settlementType, lockAmount, nativeSolToConvert, theme, usePermit, transactionSigner, authOnly, deviceId, jwtToken, origins, threeDsChallengePreference, supportEmail, destinationAuthKey, allowedPaymentMethods, accountFundingTransaction, partialUsdcChecked, redemptionCheck, allowedWithdrawSpeeds, isZeroAuthorization, zeroAuthorizationConfig, baseUrl, }) {
552
+ static getCoinflowUrl({ walletPubkey, sessionKey, route, routePrefix, env, subtotal, customPayInFees, presentment, transaction, blockchain = 'solana', webhookInfo, email, loaderBackground, handleHeightChangeId, bankAccountLinkRedirect, additionalWallets, chargebackProtectionData, chargebackProtectionAccountType, merchantCss, color, rent, lockDefaultToken, tokens, planCode, disableApplePay, disableGooglePay, customerInfo, settlementType, lockAmount, nativeSolToConvert, theme, usePermit, transactionSigner, authOnly, deviceId, jwtToken, origins, threeDsChallengePreference, supportEmail, destinationAuthKey, allowedPaymentMethods, accountFundingTransaction, partialUsdcChecked, redemptionCheck, allowedWithdrawSpeeds, isZeroAuthorization, zeroAuthorizationConfig, userLocation, baseUrl, }) {
540
553
  const prefix = routePrefix
541
554
  ? `/${routePrefix}/${blockchain}`
542
555
  : `/${blockchain}`;
@@ -604,7 +617,7 @@ class CoinflowUtils {
604
617
  url.searchParams.append('deviceId', deviceId);
605
618
  }
606
619
  else {
607
- const deviceId = fun();
620
+ const deviceId = getNSureDeviceId();
608
621
  if (deviceId)
609
622
  url.searchParams.append('deviceId', deviceId);
610
623
  }
@@ -659,6 +672,10 @@ class CoinflowUtils {
659
672
  url.searchParams.append('accountFundingTransaction', LZString.compressToEncodedURIComponent(JSON.stringify(accountFundingTransaction)));
660
673
  if (allowedWithdrawSpeeds)
661
674
  url.searchParams.append('allowedWithdrawSpeeds', allowedWithdrawSpeeds.join(','));
675
+ if (userLocation) {
676
+ url.searchParams.append('lat', userLocation.lat.toString());
677
+ url.searchParams.append('lng', userLocation.lng.toString());
678
+ }
662
679
  return url.toString();
663
680
  }
664
681
  static getTransaction(props) {
@@ -719,6 +736,12 @@ class CoinflowUtils {
719
736
  const { transaction } = props;
720
737
  return LZString.compressToEncodedURIComponent(JSON.stringify(transaction));
721
738
  },
739
+ tempo: () => {
740
+ if (!('transaction' in props))
741
+ return undefined;
742
+ const { transaction } = props;
743
+ return LZString.compressToEncodedURIComponent(JSON.stringify(transaction));
744
+ },
722
745
  user: () => {
723
746
  return undefined;
724
747
  },
@@ -740,6 +763,8 @@ class CoinflowUtils {
740
763
  return args.stellar;
741
764
  case 'monad':
742
765
  return args.monad;
766
+ case 'tempo':
767
+ return args.tempo;
743
768
  case 'user':
744
769
  return args.user;
745
770
  default:
@@ -766,6 +791,18 @@ function getCustomerName(info) {
766
791
  };
767
792
  return undefined;
768
793
  }
794
+ function recordFrontendError({ event, error, env, merchantId, }) {
795
+ const isError = error instanceof Error;
796
+ const message = isError ? error.message : error;
797
+ const stackTrace = isError ? error.stack : '';
798
+ fetch(`${CoinflowUtils.getCoinflowApiUrl(env)}/api/telemetry/frontend-error`, {
799
+ method: 'POST',
800
+ body: JSON.stringify({ message, stackTrace, merchantId, event }),
801
+ headers: {
802
+ 'Content-Type': 'application/json',
803
+ },
804
+ }).catch(() => { });
805
+ }
769
806
 
770
807
  var IFrameMessageMethods;
771
808
  (function (IFrameMessageMethods) {
@@ -777,6 +814,7 @@ var IFrameMessageMethods;
777
814
  IFrameMessageMethods["AuthDeclined"] = "authDeclined";
778
815
  IFrameMessageMethods["Loaded"] = "loaded";
779
816
  IFrameMessageMethods["AccountLinked"] = "accountLinked";
817
+ IFrameMessageMethods["Redirect"] = "redirect";
780
818
  })(IFrameMessageMethods || (IFrameMessageMethods = {}));
781
819
  function getWalletPubkey(input) {
782
820
  let wallet;
@@ -840,6 +878,9 @@ function handleIFrameMessage(rawMessage, handlers, handleHeightChangeId) {
840
878
  return;
841
879
  case IFrameMessageMethods.AccountLinked:
842
880
  return;
881
+ case IFrameMessageMethods.Redirect:
882
+ window.open(data, '_blank');
883
+ return;
843
884
  }
844
885
  console.warn(`Didn't expect to get here, handleIFrameMessage method:${method} is not one of ${Object.values(IFrameMessageMethods)}`);
845
886
  }
@@ -909,6 +950,11 @@ function getHandlers(props) {
909
950
  onSuccess: props.onSuccess,
910
951
  onAuthDeclined: props.onAuthDeclined,
911
952
  }),
953
+ tempo: () => getEvmWalletHandlers({
954
+ wallet: wallet,
955
+ onSuccess: props.onSuccess,
956
+ onAuthDeclined: props.onAuthDeclined,
957
+ }),
912
958
  user: () => getSessionKeyHandlers(props),
913
959
  })();
914
960
  }
@@ -1228,6 +1274,111 @@ var nftCartItem;
1228
1274
  })(productType = nftCartItem.productType || (nftCartItem.productType = {}));
1229
1275
  })(nftCartItem || (nftCartItem = {}));
1230
1276
 
1277
+ let cachedSessionId = null;
1278
+ async function initProtectionSession({ merchantId, env, }) {
1279
+ if (cachedSessionId)
1280
+ return;
1281
+ if (typeof window !== 'undefined') {
1282
+ try {
1283
+ const result = await window.Verisoul?.session();
1284
+ if (result?.session_id)
1285
+ cachedSessionId = result.session_id;
1286
+ }
1287
+ catch (e) {
1288
+ console.error(e);
1289
+ recordFrontendError({ event: 'ProtectionInit', env, merchantId, error: e });
1290
+ }
1291
+ }
1292
+ }
1293
+ function getProtectionSessionId() {
1294
+ return cachedSessionId;
1295
+ }
1296
+
1297
+ const DEVICE_ID_HEADER = 'x-device-id';
1298
+ const SESSION_ID_HEADER = 'x-session-id';
1299
+ const REFERRER_HEADER = 'x-coinflow-referrer';
1300
+ function getCoinflowProtectionHeaders() {
1301
+ return {
1302
+ [DEVICE_ID_HEADER]: getNSureDeviceId(),
1303
+ [SESSION_ID_HEADER]: getProtectionSessionId(),
1304
+ };
1305
+ }
1306
+ function getReferrer() {
1307
+ try {
1308
+ return document.referrer || null;
1309
+ }
1310
+ catch {
1311
+ return null;
1312
+ }
1313
+ }
1314
+ function getCoinflowPurchaseHeaders() {
1315
+ return {
1316
+ ...getCoinflowProtectionHeaders(),
1317
+ [REFERRER_HEADER]: getReferrer(),
1318
+ };
1319
+ }
1320
+
1321
+ const NSURE_APP_IDS = {
1322
+ prod: '9JBW2RHC7JNJN8ZQ',
1323
+ sandbox: 'SANDBOX_CTCE4XK53ZW0R7V1',
1324
+ };
1325
+ const PROTECTION_SESSION_PROJECT_IDS = {
1326
+ prod: '315da543-c486-435a-aa21-53844c469822',
1327
+ sandbox: 'e9f629c4-80ee-4c6d-967e-62af47d8679e',
1328
+ };
1329
+ async function initCoinflowProtection({ coinflowEnv, merchantId, }) {
1330
+ const env = coinflowEnv === 'prod' ? 'prod' : 'sandbox';
1331
+ const hasUrlDeviceId = typeof window !== 'undefined' &&
1332
+ new URLSearchParams(window.location.search).has('deviceId');
1333
+ if (!hasUrlDeviceId) {
1334
+ const partnerId = await new CoinflowUtils(coinflowEnv).getNSurePartnerId(merchantId);
1335
+ if (partnerId) {
1336
+ const appId = NSURE_APP_IDS[env] ?? NSURE_APP_IDS['sandbox'];
1337
+ try {
1338
+ nsureSDK.init(appId, partnerId);
1339
+ }
1340
+ catch (e) {
1341
+ console.error('Failed to initialize nSure SDK:', e);
1342
+ recordFrontendError({
1343
+ event: 'NSureInit',
1344
+ error: e,
1345
+ env: coinflowEnv,
1346
+ merchantId,
1347
+ });
1348
+ }
1349
+ }
1350
+ }
1351
+ // Initialize protection session (Verisoul)
1352
+ if (typeof document !== 'undefined') {
1353
+ const existing = document.querySelector('script[verisoul-project-id]');
1354
+ if (!existing) {
1355
+ const projectId = PROTECTION_SESSION_PROJECT_IDS[env] ??
1356
+ PROTECTION_SESSION_PROJECT_IDS['sandbox'];
1357
+ if (projectId) {
1358
+ await new Promise(resolve => {
1359
+ const script = document.createElement('script');
1360
+ script.src = `https://js.v.coinflow.sh/${env}/bundle.js`;
1361
+ script.async = true;
1362
+ script.setAttribute('verisoul-project-id', projectId);
1363
+ script.onload = () => {
1364
+ initProtectionSession({ merchantId, env: coinflowEnv }).then(resolve);
1365
+ };
1366
+ script.onerror = e => {
1367
+ recordFrontendError({
1368
+ event: 'ProtectionError',
1369
+ error: e,
1370
+ env: coinflowEnv,
1371
+ merchantId,
1372
+ });
1373
+ resolve();
1374
+ };
1375
+ document.head.appendChild(script);
1376
+ });
1377
+ }
1378
+ }
1379
+ }
1380
+ }
1381
+
1231
1382
  class CoinflowIFrameComponent {
1232
1383
  constructor(sanitizer) {
1233
1384
  this.sanitizer = sanitizer;
@@ -1275,13 +1426,13 @@ class CoinflowIFrameComponent {
1275
1426
  this.isLoading = false;
1276
1427
  this.onLoad?.();
1277
1428
  }
1278
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowIFrameComponent, deps: [{ token: i1.DomSanitizer }], target: i0.ɵɵFactoryTarget.Component }); }
1279
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowIFrameComponent, isStandalone: true, selector: "lib-coinflow-iframe", inputs: { iframeProps: "iframeProps", messageHandlers: "messageHandlers", onLoad: "onLoad", waitForLoadedMessage: "waitForLoadedMessage" }, outputs: { messageEvent: "messageEvent" }, host: { listeners: { "window:message": "onPostMessage($event)" } }, viewQueries: [{ propertyName: "iframe", first: true, predicate: ["iframe"], descendants: true }], ngImport: i0, template: ` <iframe
1429
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowIFrameComponent, deps: [{ token: i1.DomSanitizer }], target: i0.ɵɵFactoryTarget.Component }); }
1430
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowIFrameComponent, isStandalone: true, selector: "lib-coinflow-iframe", inputs: { iframeProps: "iframeProps", messageHandlers: "messageHandlers", onLoad: "onLoad", waitForLoadedMessage: "waitForLoadedMessage" }, outputs: { messageEvent: "messageEvent" }, host: { listeners: { "window:message": "onPostMessage($event)" } }, viewQueries: [{ propertyName: "iframe", first: true, predicate: ["iframe"], descendants: true }], ngImport: i0, template: ` <iframe
1280
1431
  width="100%"
1281
1432
  height="100%"
1282
1433
  #iframe
1283
1434
  scrolling="{{ iframeProps?.handleHeightChangeId ? 'no' : 'yes' }}"
1284
- allow="payment;camera;clipboard-write"
1435
+ allow="payment;camera;clipboard-write;geolocation"
1285
1436
  title="withdraw"
1286
1437
  frameBorder="0"
1287
1438
  [src]="dynamicUrl"
@@ -1289,7 +1440,7 @@ class CoinflowIFrameComponent {
1289
1440
  (load)="handleIframeLoad()"
1290
1441
  ></iframe>`, isInline: true }); }
1291
1442
  }
1292
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowIFrameComponent, decorators: [{
1443
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowIFrameComponent, decorators: [{
1293
1444
  type: Component,
1294
1445
  args: [{
1295
1446
  selector: 'lib-coinflow-iframe',
@@ -1300,7 +1451,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
1300
1451
  height="100%"
1301
1452
  #iframe
1302
1453
  scrolling="{{ iframeProps?.handleHeightChangeId ? 'no' : 'yes' }}"
1303
- allow="payment;camera;clipboard-write"
1454
+ allow="payment;camera;clipboard-write;geolocation"
1304
1455
  title="withdraw"
1305
1456
  frameBorder="0"
1306
1457
  [src]="dynamicUrl"
@@ -1341,10 +1492,10 @@ class CoinflowPurchaseComponent {
1341
1492
  handleHeightChangeId,
1342
1493
  };
1343
1494
  }
1344
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowPurchaseComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1345
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowPurchaseComponent, isStandalone: true, selector: "lib-coinflow-purchase", inputs: { purchaseProps: "purchaseProps" }, ngImport: i0, template: ' <lib-coinflow-iframe ng-if="iframeProps && messageHandlers" [iframeProps]="iframeProps!" [messageHandlers]="messageHandlers!" [onLoad]="purchaseProps?.onLoad" [waitForLoadedMessage]="true"></lib-coinflow-iframe> ', isInline: true, dependencies: [{ kind: "component", type: CoinflowIFrameComponent, selector: "lib-coinflow-iframe", inputs: ["iframeProps", "messageHandlers", "onLoad", "waitForLoadedMessage"], outputs: ["messageEvent"] }] }); }
1495
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowPurchaseComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1496
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowPurchaseComponent, isStandalone: true, selector: "lib-coinflow-purchase", inputs: { purchaseProps: "purchaseProps" }, ngImport: i0, template: ' <lib-coinflow-iframe ng-if="iframeProps && messageHandlers" [iframeProps]="iframeProps!" [messageHandlers]="messageHandlers!" [onLoad]="purchaseProps?.onLoad" [waitForLoadedMessage]="true"></lib-coinflow-iframe> ', isInline: true, dependencies: [{ kind: "component", type: CoinflowIFrameComponent, selector: "lib-coinflow-iframe", inputs: ["iframeProps", "messageHandlers", "onLoad", "waitForLoadedMessage"], outputs: ["messageEvent"] }] }); }
1346
1497
  }
1347
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowPurchaseComponent, decorators: [{
1498
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowPurchaseComponent, decorators: [{
1348
1499
  type: Component,
1349
1500
  args: [{
1350
1501
  selector: 'lib-coinflow-purchase',
@@ -1357,10 +1508,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
1357
1508
  }] } });
1358
1509
 
1359
1510
  class CoinflowPurchaseHistoryComponent {
1360
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowPurchaseHistoryComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1361
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowPurchaseHistoryComponent, isStandalone: true, selector: "lib-coinflow-purchase-history", ngImport: i0, template: ' <p>coinflow-purchase-history works!</p> ', isInline: true }); }
1511
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowPurchaseHistoryComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1512
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowPurchaseHistoryComponent, isStandalone: true, selector: "lib-coinflow-purchase-history", ngImport: i0, template: ' <p>coinflow-purchase-history works!</p> ', isInline: true }); }
1362
1513
  }
1363
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowPurchaseHistoryComponent, decorators: [{
1514
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowPurchaseHistoryComponent, decorators: [{
1364
1515
  type: Component,
1365
1516
  args: [{
1366
1517
  selector: 'lib-coinflow-purchase-history',
@@ -1371,10 +1522,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
1371
1522
  }] });
1372
1523
 
1373
1524
  class CoinflowPurchaseProtectionComponent {
1374
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowPurchaseProtectionComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1375
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowPurchaseProtectionComponent, isStandalone: true, selector: "lib-coinflow-purchase-protection", ngImport: i0, template: ' <p>coinflow-purchase-protection works!</p> ', isInline: true }); }
1525
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowPurchaseProtectionComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1526
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowPurchaseProtectionComponent, isStandalone: true, selector: "lib-coinflow-purchase-protection", ngImport: i0, template: ' <p>coinflow-purchase-protection works!</p> ', isInline: true }); }
1376
1527
  }
1377
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowPurchaseProtectionComponent, decorators: [{
1528
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowPurchaseProtectionComponent, decorators: [{
1378
1529
  type: Component,
1379
1530
  args: [{
1380
1531
  selector: 'lib-coinflow-purchase-protection',
@@ -1399,10 +1550,10 @@ class CoinflowWithdrawComponent {
1399
1550
  handleHeightChangeId,
1400
1551
  };
1401
1552
  }
1402
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowWithdrawComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1403
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowWithdrawComponent, isStandalone: true, selector: "lib-coinflow-withdraw", inputs: { withdrawProps: "withdrawProps" }, ngImport: i0, template: ' <lib-coinflow-iframe ng-if="iframeProps && messageHandlers" [iframeProps]="iframeProps!" [messageHandlers]="messageHandlers!" [onLoad]="withdrawProps?.onLoad"></lib-coinflow-iframe> ', isInline: true, dependencies: [{ kind: "component", type: CoinflowIFrameComponent, selector: "lib-coinflow-iframe", inputs: ["iframeProps", "messageHandlers", "onLoad", "waitForLoadedMessage"], outputs: ["messageEvent"] }] }); }
1553
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowWithdrawComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1554
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowWithdrawComponent, isStandalone: true, selector: "lib-coinflow-withdraw", inputs: { withdrawProps: "withdrawProps" }, ngImport: i0, template: ' <lib-coinflow-iframe ng-if="iframeProps && messageHandlers" [iframeProps]="iframeProps!" [messageHandlers]="messageHandlers!" [onLoad]="withdrawProps?.onLoad"></lib-coinflow-iframe> ', isInline: true, dependencies: [{ kind: "component", type: CoinflowIFrameComponent, selector: "lib-coinflow-iframe", inputs: ["iframeProps", "messageHandlers", "onLoad", "waitForLoadedMessage"], outputs: ["messageEvent"] }] }); }
1404
1555
  }
1405
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowWithdrawComponent, decorators: [{
1556
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowWithdrawComponent, decorators: [{
1406
1557
  type: Component,
1407
1558
  args: [{
1408
1559
  selector: 'lib-coinflow-withdraw',
@@ -1415,10 +1566,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
1415
1566
  }] } });
1416
1567
 
1417
1568
  class CoinflowWithdrawHistoryComponent {
1418
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowWithdrawHistoryComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1419
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowWithdrawHistoryComponent, isStandalone: true, selector: "lib-coinflow-withdraw-history", ngImport: i0, template: ' <p>coinflow-withdraw-history works!</p> ', isInline: true }); }
1569
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowWithdrawHistoryComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1570
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowWithdrawHistoryComponent, isStandalone: true, selector: "lib-coinflow-withdraw-history", ngImport: i0, template: ' <p>coinflow-withdraw-history works!</p> ', isInline: true }); }
1420
1571
  }
1421
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowWithdrawHistoryComponent, decorators: [{
1572
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowWithdrawHistoryComponent, decorators: [{
1422
1573
  type: Component,
1423
1574
  args: [{
1424
1575
  selector: 'lib-coinflow-withdraw-history',
@@ -1479,10 +1630,10 @@ class CardFormService {
1479
1630
  iframe.load();
1480
1631
  return iframe;
1481
1632
  }
1482
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CardFormService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1483
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CardFormService, providedIn: 'root' }); }
1633
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CardFormService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
1634
+ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CardFormService, providedIn: 'root' }); }
1484
1635
  }
1485
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CardFormService, decorators: [{
1636
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CardFormService, decorators: [{
1486
1637
  type: Injectable,
1487
1638
  args: [{
1488
1639
  providedIn: 'root',
@@ -1523,10 +1674,10 @@ class CoinflowCardNumberInput {
1523
1674
  tokenize() {
1524
1675
  return this.iframe.tokenize();
1525
1676
  }
1526
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowCardNumberInput, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1527
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowCardNumberInput, isStandalone: true, selector: "lib-coinflow-card-number-input", inputs: { args: "args" }, ngImport: i0, template: '<div id="{{TokenExCardNumberIframeId}}"></div>', isInline: true }); }
1677
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowCardNumberInput, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1678
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowCardNumberInput, isStandalone: true, selector: "lib-coinflow-card-number-input", inputs: { args: "args" }, ngImport: i0, template: '<div id="{{TokenExCardNumberIframeId}}"></div>', isInline: true }); }
1528
1679
  }
1529
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowCardNumberInput, decorators: [{
1680
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowCardNumberInput, decorators: [{
1530
1681
  type: Component,
1531
1682
  args: [{
1532
1683
  selector: 'lib-coinflow-card-number-input',
@@ -1572,10 +1723,10 @@ class CoinflowCardNumberOnlyInput {
1572
1723
  tokenize() {
1573
1724
  return this.iframe.tokenize();
1574
1725
  }
1575
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowCardNumberOnlyInput, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1576
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowCardNumberOnlyInput, isStandalone: true, selector: "lib-coinflow-card-number-only-input", inputs: { args: "args" }, ngImport: i0, template: '<div id="{{TokenExCardNumberIframeId}}"></div>', isInline: true }); }
1726
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowCardNumberOnlyInput, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1727
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowCardNumberOnlyInput, isStandalone: true, selector: "lib-coinflow-card-number-only-input", inputs: { args: "args" }, ngImport: i0, template: '<div id="{{TokenExCardNumberIframeId}}"></div>', isInline: true }); }
1577
1728
  }
1578
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowCardNumberOnlyInput, decorators: [{
1729
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowCardNumberOnlyInput, decorators: [{
1579
1730
  type: Component,
1580
1731
  args: [{
1581
1732
  selector: 'lib-coinflow-card-number-only-input',
@@ -1591,10 +1742,10 @@ class CoinflowCvvInputComponent {
1591
1742
  constructor() {
1592
1743
  this.TokenExCvvContainerID = TokenExCvvContainerID;
1593
1744
  }
1594
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowCvvInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1595
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowCvvInputComponent, isStandalone: true, selector: "lib-coinflow-cvv-input", ngImport: i0, template: '<div id="{{TokenExCvvContainerID}}" ></div>', isInline: true }); }
1745
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowCvvInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1746
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowCvvInputComponent, isStandalone: true, selector: "lib-coinflow-cvv-input", ngImport: i0, template: '<div id="{{TokenExCvvContainerID}}" ></div>', isInline: true }); }
1596
1747
  }
1597
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowCvvInputComponent, decorators: [{
1748
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowCvvInputComponent, decorators: [{
1598
1749
  type: Component,
1599
1750
  args: [{
1600
1751
  selector: 'lib-coinflow-cvv-input',
@@ -1655,10 +1806,10 @@ class CoinflowCvvOnlyInputComponent {
1655
1806
  tokenize() {
1656
1807
  return this.iframe.tokenize();
1657
1808
  }
1658
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowCvvOnlyInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1659
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowCvvOnlyInputComponent, isStandalone: true, selector: "lib-coinflow-cvv-only-input", inputs: { args: "args" }, usesOnChanges: true, ngImport: i0, template: '<div id="{{TokenExCvvContainerID}}"></div>', isInline: true }); }
1809
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowCvvOnlyInputComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1810
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowCvvOnlyInputComponent, isStandalone: true, selector: "lib-coinflow-cvv-only-input", inputs: { args: "args" }, usesOnChanges: true, ngImport: i0, template: '<div id="{{TokenExCvvContainerID}}"></div>', isInline: true }); }
1660
1811
  }
1661
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowCvvOnlyInputComponent, decorators: [{
1812
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowCvvOnlyInputComponent, decorators: [{
1662
1813
  type: Component,
1663
1814
  args: [{
1664
1815
  selector: 'lib-coinflow-cvv-only-input',
@@ -1670,6 +1821,126 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
1670
1821
  type: Input
1671
1822
  }] } });
1672
1823
 
1824
+ class CoinflowCardForm {
1825
+ constructor() {
1826
+ this.url = '';
1827
+ this.loaded = false;
1828
+ }
1829
+ ngOnInit() {
1830
+ this.buildUrl();
1831
+ this.messageHandler = (event) => this.handleMessage(event.data, event.origin);
1832
+ window.addEventListener('message', this.messageHandler);
1833
+ }
1834
+ ngOnDestroy() {
1835
+ if (this.messageHandler) {
1836
+ window.removeEventListener('message', this.messageHandler);
1837
+ }
1838
+ }
1839
+ buildUrl() {
1840
+ const baseUrl = CoinflowUtils.getCoinflowBaseUrl(this.args.env);
1841
+ const iframeUrl = new URL(`/form/v2/${this.args.variant}`, baseUrl);
1842
+ iframeUrl.searchParams.append('merchantId', this.args.merchantId);
1843
+ if (this.args.theme) {
1844
+ iframeUrl.searchParams.append('theme', LZString.compressToEncodedURIComponent(JSON.stringify(this.args.theme)));
1845
+ }
1846
+ if (this.args.token) {
1847
+ iframeUrl.searchParams.append('token', this.args.token);
1848
+ }
1849
+ this.url = iframeUrl.toString();
1850
+ }
1851
+ handleMessage(data, origin) {
1852
+ const expectedOrigin = new URL(CoinflowUtils.getCoinflowBaseUrl(this.args.env)).origin;
1853
+ if (origin !== expectedOrigin)
1854
+ return;
1855
+ try {
1856
+ const parsed = JSON.parse(data);
1857
+ if (parsed.method === IFrameMessageMethods.Loaded) {
1858
+ this.loaded = true;
1859
+ this.args.onLoad?.();
1860
+ }
1861
+ }
1862
+ catch {
1863
+ // not JSON
1864
+ }
1865
+ }
1866
+ tokenize() {
1867
+ return new Promise((resolve, reject) => {
1868
+ const iframe = this.iframeRef?.nativeElement;
1869
+ if (!iframe?.contentWindow) {
1870
+ reject(new Error('Card form iframe not loaded'));
1871
+ return;
1872
+ }
1873
+ const handler = (event) => {
1874
+ const { data, origin } = event;
1875
+ const expectedOrigin = new URL(CoinflowUtils.getCoinflowBaseUrl(this.args.env)).origin;
1876
+ if (origin !== expectedOrigin)
1877
+ return;
1878
+ try {
1879
+ const parsed = JSON.parse(data);
1880
+ if (parsed.method !== 'tokenize')
1881
+ return;
1882
+ window.removeEventListener('message', handler);
1883
+ if (typeof parsed.data === 'string' &&
1884
+ parsed.data.startsWith('ERROR')) {
1885
+ reject(new Error(parsed.data.replace('ERROR ', '')));
1886
+ return;
1887
+ }
1888
+ const responseData = typeof parsed.data === 'string'
1889
+ ? JSON.parse(parsed.data)
1890
+ : parsed.data;
1891
+ resolve(responseData);
1892
+ }
1893
+ catch {
1894
+ // not relevant
1895
+ }
1896
+ };
1897
+ window.addEventListener('message', handler);
1898
+ const targetOrigin = new URL(CoinflowUtils.getCoinflowBaseUrl(this.args.env)).origin;
1899
+ iframe.contentWindow.postMessage('tokenize', targetOrigin);
1900
+ });
1901
+ }
1902
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowCardForm, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1903
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowCardForm, isStandalone: true, selector: "lib-coinflow-card-form", inputs: { args: "args" }, viewQueries: [{ propertyName: "iframeRef", first: true, predicate: ["cardFormIframe"], descendants: true, static: true }], ngImport: i0, template: `<iframe
1904
+ #cardFormIframe
1905
+ [src]="url"
1906
+ title="Card Form"
1907
+ frameBorder="0"
1908
+ allow="payment"
1909
+ [style.width]="'100%'"
1910
+ [style.height]="'60px'"
1911
+ [style.border]="'none'"
1912
+ [style.opacity]="loaded ? 1 : 0"
1913
+ [style.transition]="'opacity 300ms linear'"
1914
+ ></iframe>`, isInline: true }); }
1915
+ }
1916
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowCardForm, decorators: [{
1917
+ type: Component,
1918
+ args: [{
1919
+ selector: 'lib-coinflow-card-form',
1920
+ standalone: true,
1921
+ imports: [],
1922
+ template: `<iframe
1923
+ #cardFormIframe
1924
+ [src]="url"
1925
+ title="Card Form"
1926
+ frameBorder="0"
1927
+ allow="payment"
1928
+ [style.width]="'100%'"
1929
+ [style.height]="'60px'"
1930
+ [style.border]="'none'"
1931
+ [style.opacity]="loaded ? 1 : 0"
1932
+ [style.transition]="'opacity 300ms linear'"
1933
+ ></iframe>`,
1934
+ }]
1935
+ }], propDecorators: { args: [{
1936
+ type: Input
1937
+ }], iframeRef: [{
1938
+ type: ViewChild,
1939
+ args: ['cardFormIframe', { static: true }]
1940
+ }] } });
1941
+ /** @deprecated Use CoinflowCardForm instead */
1942
+ const CoinflowCardFormV2 = CoinflowCardForm;
1943
+
1673
1944
  class CoinflowMobileWalletButtonComponent {
1674
1945
  constructor() {
1675
1946
  this.opacity = 0.8;
@@ -1707,8 +1978,8 @@ class CoinflowMobileWalletButtonComponent {
1707
1978
  handleHeightChangeId,
1708
1979
  };
1709
1980
  }
1710
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowMobileWalletButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1711
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowMobileWalletButtonComponent, isStandalone: true, selector: "lib-coinflow-mobile-wallet-button", inputs: { purchaseProps: "purchaseProps", route: "route", overlayDisplayOverride: "overlayDisplayOverride", alignItems: "alignItems" }, ngImport: i0, template: ` <div style="position: relative; height: 100%;">
1981
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowMobileWalletButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1982
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowMobileWalletButtonComponent, isStandalone: true, selector: "lib-coinflow-mobile-wallet-button", inputs: { purchaseProps: "purchaseProps", route: "route", overlayDisplayOverride: "overlayDisplayOverride", alignItems: "alignItems" }, ngImport: i0, template: ` <div style="position: relative; height: 100%;">
1712
1983
  <div
1713
1984
  [style.background-color]="purchaseProps.color"
1714
1985
  [style.display]="overlayDisplayOverride ?? display"
@@ -1730,7 +2001,7 @@ class CoinflowMobileWalletButtonComponent {
1730
2001
  </div>
1731
2002
  </div>`, isInline: true, dependencies: [{ kind: "component", type: CoinflowIFrameComponent, selector: "lib-coinflow-iframe", inputs: ["iframeProps", "messageHandlers", "onLoad", "waitForLoadedMessage"], outputs: ["messageEvent"] }] }); }
1732
2003
  }
1733
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowMobileWalletButtonComponent, decorators: [{
2004
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowMobileWalletButtonComponent, decorators: [{
1734
2005
  type: Component,
1735
2006
  args: [{
1736
2007
  selector: 'lib-coinflow-mobile-wallet-button',
@@ -1772,8 +2043,8 @@ class CoinflowApplePayButtonComponent {
1772
2043
  fill() {
1773
2044
  return this.purchaseProps.color === 'white' ? '#000' : '#FFF';
1774
2045
  }
1775
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowApplePayButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1776
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowApplePayButtonComponent, isStandalone: true, selector: "lib-coinflow-apple-pay-button", inputs: { purchaseProps: "purchaseProps" }, ngImport: i0, template: ` <lib-coinflow-mobile-wallet-button
2046
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowApplePayButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
2047
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowApplePayButtonComponent, isStandalone: true, selector: "lib-coinflow-apple-pay-button", inputs: { purchaseProps: "purchaseProps" }, ngImport: i0, template: ` <lib-coinflow-mobile-wallet-button
1777
2048
  ng-if="iframeProps && messageHandlers"
1778
2049
  [purchaseProps]="purchaseProps"
1779
2050
  route="apple-pay"
@@ -1815,7 +2086,7 @@ class CoinflowApplePayButtonComponent {
1815
2086
  </svg>
1816
2087
  </lib-coinflow-mobile-wallet-button>`, isInline: true, dependencies: [{ kind: "component", type: CoinflowMobileWalletButtonComponent, selector: "lib-coinflow-mobile-wallet-button", inputs: ["purchaseProps", "route", "overlayDisplayOverride", "alignItems"] }] }); }
1817
2088
  }
1818
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowApplePayButtonComponent, decorators: [{
2089
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowApplePayButtonComponent, decorators: [{
1819
2090
  type: Component,
1820
2091
  args: [{
1821
2092
  selector: 'lib-coinflow-apple-pay-button',
@@ -1868,8 +2139,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
1868
2139
  }] } });
1869
2140
 
1870
2141
  class CoinflowGooglePayOverlayComponent {
1871
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowGooglePayOverlayComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1872
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.0", type: CoinflowGooglePayOverlayComponent, isStandalone: true, selector: "coinflow-google-pay-overlay", inputs: { color: "color" }, ngImport: i0, template: `
2142
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowGooglePayOverlayComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
2143
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.10", type: CoinflowGooglePayOverlayComponent, isStandalone: true, selector: "coinflow-google-pay-overlay", inputs: { color: "color" }, ngImport: i0, template: `
1873
2144
  @if (color === 'white') {
1874
2145
  <svg xmlns="http://www.w3.org/2000/svg" width="41" height="17">
1875
2146
  <g fill="none" fill-rule="evenodd">
@@ -1924,7 +2195,7 @@ class CoinflowGooglePayOverlayComponent {
1924
2195
  }
1925
2196
  `, isInline: true }); }
1926
2197
  }
1927
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowGooglePayOverlayComponent, decorators: [{
2198
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowGooglePayOverlayComponent, decorators: [{
1928
2199
  type: Component,
1929
2200
  args: [{
1930
2201
  selector: 'coinflow-google-pay-overlay',
@@ -1990,8 +2261,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
1990
2261
  }] } });
1991
2262
 
1992
2263
  class CoinflowGooglePayButtonComponent {
1993
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowGooglePayButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
1994
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.0", type: CoinflowGooglePayButtonComponent, isStandalone: true, selector: "lib-coinflow-google-pay-button", inputs: { purchaseProps: "purchaseProps" }, ngImport: i0, template: `<lib-coinflow-mobile-wallet-button
2264
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowGooglePayButtonComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
2265
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.10", type: CoinflowGooglePayButtonComponent, isStandalone: true, selector: "lib-coinflow-google-pay-button", inputs: { purchaseProps: "purchaseProps" }, ngImport: i0, template: `<lib-coinflow-mobile-wallet-button
1995
2266
  ng-if="iframeProps && messageHandlers"
1996
2267
  [purchaseProps]="purchaseProps"
1997
2268
  route="google-pay"
@@ -2003,7 +2274,7 @@ class CoinflowGooglePayButtonComponent {
2003
2274
  ></coinflow-google-pay-overlay>
2004
2275
  </lib-coinflow-mobile-wallet-button> `, isInline: true, dependencies: [{ kind: "component", type: CoinflowMobileWalletButtonComponent, selector: "lib-coinflow-mobile-wallet-button", inputs: ["purchaseProps", "route", "overlayDisplayOverride", "alignItems"] }, { kind: "component", type: CoinflowGooglePayOverlayComponent, selector: "coinflow-google-pay-overlay", inputs: ["color"] }] }); }
2005
2276
  }
2006
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImport: i0, type: CoinflowGooglePayButtonComponent, decorators: [{
2277
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.10", ngImport: i0, type: CoinflowGooglePayButtonComponent, decorators: [{
2007
2278
  type: Component,
2008
2279
  args: [{
2009
2280
  selector: 'lib-coinflow-google-pay-button',
@@ -2036,5 +2307,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.0", ngImpor
2036
2307
  * Generated bundle index. Do not edit.
2037
2308
  */
2038
2309
 
2039
- export { BankingCurrencies, CARD_TYPE_MAPPING, CardType, ChargebackProtectionAccountType, CoinflowApplePayButtonComponent, CoinflowCardNumberInput, CoinflowCardNumberOnlyInput, CoinflowCvvInputComponent, CoinflowCvvOnlyInputComponent, CoinflowGooglePayButtonComponent, CoinflowIFrameComponent, CoinflowPurchaseComponent, CoinflowPurchaseHistoryComponent, CoinflowPurchaseProtectionComponent, CoinflowUtils, CoinflowWithdrawComponent, CoinflowWithdrawHistoryComponent, Currency, CurrencyToISO4217, EventBus, IFrameMessageMethods, MerchantStyle, PaymentMethods, RN_REDIRECT_MESSAGE_NAME, SettlementType, ThreeDsChallengePreference, TokenExCardNumberIframeId, TokenExCvvContainerID, WithdrawCategory, WithdrawCurrencies, WithdrawSpeed, doInitializeCvvOnlyTokenExIframe, doInitializeTokenExCardOnlyIframe, doInitializeTokenExIframe, getCurrencyDecimals, getCustomerName, getHandlers, getIframeConfig, getWalletPubkey, handleIFrameMessage, isBankingCurrency, isTypedCurrencyCents, isWithdrawCurrency, isZeroAuthSavedPaymentMethods, isZeroAuthVerifyCard, nftCartItem, paymentMethodLabels, setTokenExScriptTag };
2310
+ export { BankingCurrencies, CARD_TYPE_MAPPING, CardType, ChargebackProtectionAccountType, CoinflowApplePayButtonComponent, CoinflowCardForm, CoinflowCardFormV2, CoinflowCardNumberInput, CoinflowCardNumberOnlyInput, CoinflowCvvInputComponent, CoinflowCvvOnlyInputComponent, CoinflowGooglePayButtonComponent, CoinflowIFrameComponent, CoinflowPurchaseComponent, CoinflowPurchaseHistoryComponent, CoinflowPurchaseProtectionComponent, CoinflowUtils, CoinflowWithdrawComponent, CoinflowWithdrawHistoryComponent, Currency, CurrencyToISO4217, DEVICE_ID_HEADER, EventBus, IFrameMessageMethods, MerchantStyle, PaymentMethods, REFERRER_HEADER, RN_REDIRECT_MESSAGE_NAME, SESSION_ID_HEADER, SettlementType, ThreeDsChallengePreference, TokenExCardNumberIframeId, TokenExCvvContainerID, WithdrawCategory, WithdrawCurrencies, WithdrawSpeed, doInitializeCvvOnlyTokenExIframe, doInitializeTokenExCardOnlyIframe, doInitializeTokenExIframe, getCoinflowProtectionHeaders, getCoinflowPurchaseHeaders, getCurrencyDecimals, getCustomerName, getHandlers, getIframeConfig, getWalletPubkey, handleIFrameMessage, initCoinflowProtection, invertRate, isBankingCurrency, isTypedCurrencyCents, isWithdrawCurrency, isZeroAuthSavedPaymentMethods, isZeroAuthVerifyCard, nftCartItem, paymentMethodLabels, recordFrontendError, setTokenExScriptTag };
2040
2311
  //# sourceMappingURL=coinflowlabs-angular.mjs.map