{"version":3,"file":"google-pay-button-angular.mjs","sources":["../../../lib/load-script.ts","../../../lib/button-manager.ts","../../../lib/debounce.ts","../../lib/google-pay-button.component.ts","../../lib/google-pay-button.module.ts","../../../angular-public-api.ts","../../../google-pay-button-angular.ts"],"sourcesContent":["/**\n * Copyright 2020 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n *      http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * Keeps track scripts that have been requested by loadScript.\n */\nlet cachedScripts: Record<string, Promise<any>> = {};\n\n/**\n * Asynchronously loads a script keeping track of which scripts have already\n * requested and loaded.\n *\n * Multiple requests to the same resource will return the same promise.\n *\n * @param src Script URL to load\n * @param nonce CSP nonce string\n */\nexport function loadScript(src: string, nonce?: string): Promise<void> {\n  const existing = cachedScripts[src];\n  if (existing) {\n    return existing;\n  }\n\n  const promise = new Promise<void>((resolve, reject) => {\n    // Create script\n    const script = document.createElement('script');\n    script.src = src;\n    script.async = true;\n    if (nonce) {\n      script.nonce = nonce;\n    }\n\n    // Script event listener callbacks for load and error\n    const onScriptLoad = (): void => {\n      resolve();\n    };\n\n    const onScriptError = (): void => {\n      // eslint-disable-next-line @typescript-eslint/no-use-before-define\n      cleanup();\n\n      // Remove from cachedScripts so that we can try loading again\n      delete cachedScripts[src];\n      script.remove();\n\n      reject(new Error(`Unable to load script ${src}`));\n    };\n\n    script.addEventListener('load', onScriptLoad);\n    script.addEventListener('error', onScriptError);\n\n    // Add script to document body\n    document.body.appendChild(script);\n\n    // Remove event listeners on cleanup\n    function cleanup(): void {\n      script.removeEventListener('load', onScriptLoad);\n      script.removeEventListener('error', onScriptError);\n    }\n  });\n\n  cachedScripts[src] = promise;\n\n  return promise;\n}\n\n/**\n * Clears the script cache. Used for testing purposes only.\n */\nexport function clearScriptCache(): void {\n  cachedScripts = {};\n}\n","/**\n * Copyright 2020 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n *      http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/* eslint-disable react/no-is-mounted */\n\nimport { loadScript } from '../lib/load-script';\n\ndeclare const global: typeof globalThis;\n\nexport interface ReadyToPayChangeResponse {\n  isButtonVisible: boolean;\n  isReadyToPay: boolean;\n  paymentMethodPresent?: boolean;\n}\n\nexport interface Config {\n  environment: google.payments.api.Environment;\n  existingPaymentMethodRequired?: boolean;\n  paymentRequest: google.payments.api.PaymentDataRequest;\n  onPaymentDataChanged?: google.payments.api.PaymentDataChangedHandler;\n  onPaymentAuthorized?: google.payments.api.PaymentAuthorizedHandler;\n  onLoadPaymentData?: (paymentData: google.payments.api.PaymentData) => void;\n  onCancel?: (reason: google.payments.api.PaymentsError) => void;\n  onError?: (error: Error | google.payments.api.PaymentsError) => void;\n  onReadyToPayChange?: (result: ReadyToPayChangeResponse) => void;\n  onClick?: (event: Event) => void;\n  buttonType?: google.payments.api.ButtonType;\n  buttonColor?: google.payments.api.ButtonColor;\n  buttonRadius?: number;\n  buttonSizeMode?: google.payments.api.ButtonSizeMode;\n  buttonLocale?: string;\n  buttonBorderType?: google.payments.api.ButtonBorderType;\n  nonce?: string;\n}\n\ninterface ButtonManagerOptions {\n  cssSelector: string;\n  softwareInfoId: string;\n  softwareInfoVersion: string;\n}\n\n/**\n * Manages the lifecycle of the Google Pay button.\n *\n * Includes lifecycle management of the `PaymentsClient` instance,\n * `isReadyToPay`, `onClick`, `loadPaymentData`, and other callback methods.\n */\nexport class ButtonManager {\n  private client?: google.payments.api.PaymentsClient;\n  private config?: Config;\n  private element?: Element;\n  private options: ButtonManagerOptions;\n  private oldInvalidationValues?: any[];\n\n  isReadyToPay?: boolean;\n  paymentMethodPresent?: boolean;\n\n  constructor(options: ButtonManagerOptions) {\n    this.options = options;\n  }\n\n  getElement(): Element | undefined {\n    return this.element;\n  }\n\n  private isGooglePayLoaded(): boolean {\n    return 'google' in (window || global) && !!google?.payments?.api?.PaymentsClient;\n  }\n\n  async mount(element: Element): Promise<void> {\n    if (!this.isGooglePayLoaded()) {\n      try {\n        await loadScript('https://pay.google.com/gp/p/js/pay.js', this.config?.nonce);\n      } catch (err) {\n        if (this.config?.onError) {\n          this.config.onError(err as Error);\n        } else {\n          console.error(err);\n        }\n        return;\n      }\n    }\n\n    this.element = element;\n    if (element) {\n      this.appendStyles();\n      if (this.config) {\n        this.updateElement();\n      }\n    }\n  }\n\n  unmount(): void {\n    this.element = undefined;\n  }\n\n  configure(newConfig: Config): Promise<void> {\n    let promise: Promise<void> | undefined = undefined;\n    this.config = newConfig;\n    if (!this.oldInvalidationValues || this.isClientInvalidated(newConfig)) {\n      promise = this.updateElement();\n    }\n    this.oldInvalidationValues = this.getInvalidationValues(newConfig);\n\n    return promise ?? Promise.resolve();\n  }\n\n  /**\n   * Creates client configuration options based on button configuration\n   * options.\n   *\n   * This method would normally be private but has been made public for\n   * testing purposes.\n   *\n   * @private\n   */\n  createClientOptions(config: Config): google.payments.api.PaymentOptions {\n    const clientConfig: google.payments.api.PaymentOptions = {\n      environment: config.environment,\n      merchantInfo: this.createMerchantInfo(config),\n    };\n\n    if (config.nonce) {\n      clientConfig.nonce = config.nonce;\n    }\n\n    if (config.onPaymentDataChanged || config.onPaymentAuthorized) {\n      clientConfig.paymentDataCallbacks = {};\n\n      if (config.onPaymentDataChanged) {\n        // eslint-disable-next-line @typescript-eslint/explicit-function-return-type\n        clientConfig.paymentDataCallbacks.onPaymentDataChanged = paymentData => {\n          const result = config.onPaymentDataChanged!(paymentData);\n          return result || ({} as google.payments.api.PaymentDataRequestUpdate);\n        };\n      }\n\n      if (config.onPaymentAuthorized) {\n        // eslint-disable-next-line @typescript-eslint/explicit-function-return-type\n        clientConfig.paymentDataCallbacks.onPaymentAuthorized = paymentData => {\n          const result = config.onPaymentAuthorized!(paymentData);\n          return result || ({} as google.payments.api.PaymentAuthorizationResult);\n        };\n      }\n    }\n\n    return clientConfig;\n  }\n\n  private createIsReadyToPayRequest(config: Config): google.payments.api.IsReadyToPayRequest {\n    const paymentRequest = config.paymentRequest;\n    const request: google.payments.api.IsReadyToPayRequest = {\n      apiVersion: paymentRequest.apiVersion,\n      apiVersionMinor: paymentRequest.apiVersionMinor,\n      allowedPaymentMethods: paymentRequest.allowedPaymentMethods,\n      existingPaymentMethodRequired: config.existingPaymentMethodRequired,\n    };\n\n    return request;\n  }\n\n  /**\n   * Constructs `loadPaymentData` request object based on button configuration.\n   *\n   * It infers request properties like `shippingAddressRequired`,\n   * `shippingOptionRequired`, and `billingAddressRequired` if not already set\n   * based on the presence of their associated options and parameters. It also\n   * infers `callbackIntents` based on the callback methods defined in button\n   * configuration.\n   *\n   * This method would normally be private but has been made public for\n   * testing purposes.\n   *\n   * @private\n   */\n  createLoadPaymentDataRequest(config: Config): google.payments.api.PaymentDataRequest {\n    const request = {\n      ...config.paymentRequest,\n      merchantInfo: this.createMerchantInfo(config),\n    };\n\n    // TODO: #13 re-enable inferrence if/when we agree as a team\n\n    return request;\n  }\n\n  private createMerchantInfo(config: Config): google.payments.api.MerchantInfo {\n    const merchantInfo: google.payments.api.MerchantInfo = {\n      ...config.paymentRequest.merchantInfo,\n    };\n\n    // apply softwareInfo if not set\n    if (!merchantInfo.softwareInfo) {\n      merchantInfo.softwareInfo = {\n        id: this.options.softwareInfoId,\n        version: this.options.softwareInfoVersion,\n      };\n    }\n\n    return merchantInfo;\n  }\n\n  private isMounted(): boolean {\n    return this.element != null && this.element.isConnected !== false;\n  }\n\n  private removeButton(): void {\n    if (this.element instanceof ShadowRoot || this.element instanceof Element) {\n      for (const child of Array.from(this.element.children)) {\n        if (child.tagName !== 'STYLE') {\n          child.remove();\n        }\n      }\n    }\n  }\n\n  private async updateElement(): Promise<void> {\n    if (!this.isMounted()) return;\n    const element = this.getElement()!;\n\n    if (!this.config) {\n      throw new Error('google-pay-button: Missing configuration');\n    }\n\n    // remove existing button\n    this.removeButton();\n\n    try {\n      this.client = new google.payments.api.PaymentsClient(this.createClientOptions(this.config));\n    } catch (err) {\n      if (this.config.onError) {\n        this.config.onError(err as Error);\n      } else {\n        console.error(err);\n      }\n      return;\n    }\n\n    const buttonOptions: google.payments.api.ButtonOptions = {\n      buttonType: this.config.buttonType,\n      buttonColor: this.config.buttonColor,\n      buttonRadius: this.config.buttonRadius,\n      buttonSizeMode: this.config.buttonSizeMode,\n      buttonLocale: this.config.buttonLocale,\n      buttonBorderType: this.config.buttonBorderType,\n      onClick: this.handleClick,\n      allowedPaymentMethods: this.config.paymentRequest.allowedPaymentMethods,\n    };\n\n    const rootNode = element.getRootNode();\n    if (rootNode instanceof ShadowRoot) {\n      buttonOptions.buttonRootNode = rootNode;\n    }\n\n    // pre-create button\n    const button = this.client.createButton(buttonOptions);\n\n    this.setClassName(element, [element.className, 'not-ready']);\n    element.appendChild(button);\n\n    let showButton = false;\n    let readyToPay: google.payments.api.IsReadyToPayResponse | undefined;\n\n    try {\n      readyToPay = await this.client.isReadyToPay(this.createIsReadyToPayRequest(this.config));\n      showButton =\n        (readyToPay.result && !this.config.existingPaymentMethodRequired) ||\n        (readyToPay.result && readyToPay.paymentMethodPresent && this.config.existingPaymentMethodRequired) ||\n        false;\n    } catch (err) {\n      if (this.config.onError) {\n        this.config.onError(err as Error);\n      } else {\n        console.error(err);\n      }\n    }\n\n    if (!this.isMounted()) return;\n\n    if (showButton) {\n      try {\n        this.client.prefetchPaymentData(this.createLoadPaymentDataRequest(this.config));\n      } catch (err) {\n        console.log('Error with prefetch', err);\n      }\n\n      // remove hidden className\n      this.setClassName(\n        element,\n        (element.className || '').split(' ').filter(className => className && className !== 'not-ready'),\n      );\n    }\n\n    if (this.isReadyToPay !== readyToPay?.result || this.paymentMethodPresent !== readyToPay?.paymentMethodPresent) {\n      this.isReadyToPay = !!readyToPay?.result;\n      this.paymentMethodPresent = readyToPay?.paymentMethodPresent;\n\n      if (this.config.onReadyToPayChange) {\n        const readyToPayResponse: ReadyToPayChangeResponse = {\n          isButtonVisible: showButton,\n          isReadyToPay: this.isReadyToPay,\n        };\n\n        if (this.paymentMethodPresent) {\n          readyToPayResponse.paymentMethodPresent = this.paymentMethodPresent;\n        }\n\n        this.config.onReadyToPayChange(readyToPayResponse);\n      }\n    }\n  }\n\n  /**\n   * Handles the click event of the Google Pay button.\n   *\n   * This method would normally be private but has been made public for\n   * testing purposes.\n   *\n   * @private\n   */\n  handleClick = async (event: Event): Promise<void> => {\n    const config = this.config;\n    if (!config) {\n      throw new Error('google-pay-button: Missing configuration');\n    }\n\n    const request = this.createLoadPaymentDataRequest(config);\n\n    try {\n      if (config.onClick) {\n        config.onClick(event);\n      }\n\n      if (event.defaultPrevented) {\n        return;\n      }\n\n      const result = await this.client!.loadPaymentData(request);\n\n      if (config.onLoadPaymentData) {\n        config.onLoadPaymentData(result);\n      }\n    } catch (err) {\n      if ((err as google.payments.api.PaymentsError).statusCode === 'CANCELED') {\n        if (config.onCancel) {\n          config.onCancel(err as google.payments.api.PaymentsError);\n        }\n      } else if (config.onError) {\n        config.onError(err as google.payments.api.PaymentsError);\n      } else {\n        console.error(err);\n      }\n    }\n  };\n\n  private setClassName(element: Element, classNames: string[]): void {\n    const className = classNames.filter(name => name).join(' ');\n    if (className) {\n      element.className = className;\n    } else {\n      element.removeAttribute('class');\n    }\n  }\n\n  private appendStyles(): void {\n    if (typeof document === 'undefined') return;\n\n    const rootNode = this.element?.getRootNode() as Document | ShadowRoot | undefined;\n    const styleId = `default-google-style-${this.options.cssSelector.replace(/[^\\w-]+/g, '')}-${\n      this.config?.buttonLocale\n    }`;\n\n    // initialize styles if rendering on the client:\n    if (rootNode) {\n      if (!rootNode.getElementById?.(styleId)) {\n        const style = document.createElement('style');\n        style.id = styleId;\n        style.type = 'text/css';\n        style.innerHTML = `\n          ${this.options.cssSelector} {\n            display: inline-block;\n          }\n          ${this.options.cssSelector}.not-ready {\n            width: 0;\n            height: 0;\n            overflow: hidden;\n          }\n        `;\n\n        if (rootNode instanceof Document && rootNode.head) {\n          rootNode.head.appendChild(style);\n        } else {\n          rootNode.appendChild(style);\n        }\n      }\n    }\n  }\n\n  private isClientInvalidated(newConfig: Config): boolean {\n    if (!this.oldInvalidationValues) return true;\n\n    const newValues = this.getInvalidationValues(newConfig);\n    return newValues.some(\n      (value, index) => JSON.stringify(value) !== JSON.stringify(this.oldInvalidationValues![index]),\n    );\n  }\n\n  private getInvalidationValues(config: Config): any[] {\n    return [\n      config.environment,\n      config.existingPaymentMethodRequired,\n      !!config.onPaymentDataChanged,\n      !!config.onPaymentAuthorized,\n      config.buttonType,\n      config.buttonColor,\n      config.buttonRadius,\n      config.buttonLocale,\n      config.buttonSizeMode,\n      config.buttonBorderType,\n      config.paymentRequest.merchantInfo.merchantId,\n      config.paymentRequest.merchantInfo.merchantName,\n      config.paymentRequest.merchantInfo.softwareInfo?.id,\n      config.paymentRequest.merchantInfo.softwareInfo?.version,\n      config.paymentRequest.allowedPaymentMethods,\n      config.nonce,\n    ];\n  }\n}\n","/**\n * Copyright 2020 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n *      http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/**\n * Returns a new function that delays invocations to the original function\n * within a specified wait period. The last invocation within this time period\n * gets invoked. All earlier invocations are ignore.\n *\n * @param func The function to invoke.\n * @param wait The time in milliseconds to wait for idle invocations.\n */\nexport function debounce<T>(func: (...params: any[]) => T, wait = 0): () => Promise<T> {\n  let timeout: number | undefined;\n\n  return function (...args: any[]): Promise<any> {\n    window.clearTimeout(timeout);\n\n    const later = function (): any {\n      timeout = undefined;\n      return func(...args);\n    };\n\n    return new Promise(resolve => {\n      timeout = window.setTimeout(() => {\n        const result = later();\n        resolve(result);\n      }, wait);\n    });\n  };\n}\n","/**\n * Copyright 2020 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n *      http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { ButtonManager, Config } from '../../lib/button-manager';\nimport { Directive, ElementRef, Input, OnChanges, OnInit } from '@angular/core';\nimport { name as softwareId, version as softwareVersion } from '../package.json';\nimport { debounce } from '../../lib/debounce';\n\n@Directive({\n  selector: 'google-pay-button',\n  standalone: false,\n})\nexport class GooglePayButtonComponent implements OnInit, OnChanges {\n  private manager = new ButtonManager({\n    cssSelector: 'google-pay-button',\n    softwareInfoId: softwareId,\n    softwareInfoVersion: softwareVersion,\n  });\n\n  @Input() paymentRequest!: google.payments.api.PaymentDataRequest;\n  @Input() environment!: google.payments.api.Environment;\n  @Input() existingPaymentMethodRequired!: boolean;\n  @Input() buttonColor?: google.payments.api.ButtonColor;\n  @Input() buttonType?: google.payments.api.ButtonType;\n  @Input() buttonRadius?: number;\n  @Input() buttonSizeMode?: google.payments.api.ButtonSizeMode;\n  @Input() buttonLocale?: string;\n  @Input() buttonBorderType?: google.payments.api.ButtonBorderType;\n  @Input() nonce?: string;\n  @Input() paymentDataChangedCallback?: google.payments.api.PaymentDataChangedHandler;\n  @Input() paymentAuthorizedCallback?: google.payments.api.PaymentAuthorizedHandler;\n  @Input() readyToPayChangeCallback?: (result: any) => void;\n  @Input() loadPaymentDataCallback?: (paymentData: google.payments.api.PaymentData) => void;\n  @Input() cancelCallback?: (reason: google.payments.api.PaymentsError) => void;\n  @Input() errorCallback?: (error: Error | google.payments.api.PaymentsError) => void;\n  @Input() clickCallback?: (event: Event) => void;\n\n  constructor(private elementRef: ElementRef) {}\n\n  get isReadyToPay(): boolean | undefined {\n    return this.manager.isReadyToPay;\n  }\n\n  ngOnInit(): Promise<void> {\n    return this.manager.mount(this.elementRef.nativeElement);\n  }\n\n  ngOnChanges(): Promise<void> {\n    return this.initializeButton();\n  }\n\n  private initializeButton = debounce(() => {\n    if (!this.assertRequiredProperty('paymentRequest')) {\n      return;\n    }\n\n    if (!this.assertRequiredProperty('environment')) {\n      return;\n    }\n\n    const config: Config = {\n      paymentRequest: this.paymentRequest,\n      environment: this.environment,\n      existingPaymentMethodRequired: this.existingPaymentMethodRequired,\n      onPaymentDataChanged: this.paymentDataChangedCallback,\n      onPaymentAuthorized: this.paymentAuthorizedCallback,\n      buttonColor: this.buttonColor,\n      buttonType: this.buttonType,\n      buttonRadius: this.buttonRadius,\n      buttonSizeMode: this.buttonSizeMode,\n      buttonLocale: this.buttonLocale,\n      buttonBorderType: this.buttonBorderType,\n      nonce: this.nonce,\n      onReadyToPayChange: result => {\n        if (this.readyToPayChangeCallback) {\n          this.readyToPayChangeCallback(result);\n        }\n        this.dispatch('readytopaychange', result);\n      },\n      onCancel: reason => {\n        if (this.cancelCallback) {\n          this.cancelCallback(reason);\n        }\n        this.dispatch('cancel', reason);\n      },\n      onError: error => {\n        if (this.errorCallback) {\n          this.errorCallback?.(error);\n        }\n        this.elementRef.nativeElement.dispatchEvent(new ErrorEvent('error', { error }));\n      },\n      onLoadPaymentData: paymentData => {\n        if (this.loadPaymentDataCallback) {\n          this.loadPaymentDataCallback(paymentData);\n        }\n        this.dispatch('loadpaymentdata', paymentData);\n      },\n      onClick: event => {\n        if (this.clickCallback) {\n          this.clickCallback?.(event);\n        }\n      },\n    };\n\n    this.manager.configure(config);\n  });\n\n  private assertRequiredProperty(name: string): boolean {\n    const value = (this as any)[name];\n    if (value === null || value === undefined) {\n      this.throwError(Error(`Required property not set: ${name}`));\n      return false;\n    }\n\n    return true;\n  }\n\n  /**\n   * Throws an error.\n   *\n   * Used for testing purposes so that the method can be spied on.\n   */\n  private throwError(error: Error): never {\n    throw error;\n  }\n\n  private dispatch<T>(type: string, detail: T): void {\n    this.elementRef.nativeElement.dispatchEvent(\n      new CustomEvent(type, {\n        bubbles: true,\n        cancelable: false,\n        detail,\n      }),\n    );\n  }\n}\n","/**\n * Copyright 2020 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n *      http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport { GooglePayButtonComponent } from './google-pay-button.component';\nimport { NgModule } from '@angular/core';\n\n@NgModule({\n  declarations: [GooglePayButtonComponent],\n  imports: [],\n  exports: [GooglePayButtonComponent],\n})\nexport class GooglePayButtonModule {}\n","/**\n * Copyright 2020 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n *      http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\n/*\n * Public API Surface of google-pay-button\n */\n\nexport * from './button-angular/lib/google-pay-button.component';\nexport * from './button-angular/lib/google-pay-button.module';\n\nexport { ReadyToPayChangeResponse } from './lib/button-manager';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './angular-public-api';\n"],"names":["softwareId","softwareVersion"],"mappings":";;;AAAA;;;;;;;;;;;;;;AAcG;AAEH;;AAEG;AACH,IAAI,aAAa,GAAiC,EAAE;AAEpD;;;;;;;;AAQG;AACG,SAAU,UAAU,CAAC,GAAW,EAAE,KAAc,EAAA;AACpD,IAAA,MAAM,QAAQ,GAAG,aAAa,CAAC,GAAG,CAAC;IACnC,IAAI,QAAQ,EAAE;AACZ,QAAA,OAAO,QAAQ;IACjB;IAEA,MAAM,OAAO,GAAG,IAAI,OAAO,CAAO,CAAC,OAAO,EAAE,MAAM,KAAI;;QAEpD,MAAM,MAAM,GAAG,QAAQ,CAAC,aAAa,CAAC,QAAQ,CAAC;AAC/C,QAAA,MAAM,CAAC,GAAG,GAAG,GAAG;AAChB,QAAA,MAAM,CAAC,KAAK,GAAG,IAAI;QACnB,IAAI,KAAK,EAAE;AACT,YAAA,MAAM,CAAC,KAAK,GAAG,KAAK;QACtB;;QAGA,MAAM,YAAY,GAAG,MAAW;AAC9B,YAAA,OAAO,EAAE;AACX,QAAA,CAAC;QAED,MAAM,aAAa,GAAG,MAAW;;AAE/B,YAAA,OAAO,EAAE;;AAGT,YAAA,OAAO,aAAa,CAAC,GAAG,CAAC;YACzB,MAAM,CAAC,MAAM,EAAE;YAEf,MAAM,CAAC,IAAI,KAAK,CAAC,yBAAyB,GAAG,CAAA,CAAE,CAAC,CAAC;AACnD,QAAA,CAAC;AAED,QAAA,MAAM,CAAC,gBAAgB,CAAC,MAAM,EAAE,YAAY,CAAC;AAC7C,QAAA,MAAM,CAAC,gBAAgB,CAAC,OAAO,EAAE,aAAa,CAAC;;AAG/C,QAAA,QAAQ,CAAC,IAAI,CAAC,WAAW,CAAC,MAAM,CAAC;;AAGjC,QAAA,SAAS,OAAO,GAAA;AACd,YAAA,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