!function(t,e){function i(){e.BaseGateway.call(this,wc_stripe_googlepay_product_params),window.addEventListener("hashchange",this.hashchange.bind(this))}(i.prototype=t.extend({},e.BaseGateway.prototype,e.ProductGateway.prototype,e.GooglePay.prototype)).initialize=function(){if(!t(this.container).length)return setTimeout(this.initialize.bind(this),1e3);e.ProductGateway.call(this),this.createPaymentsClient(),this.isReadyToPay().then(function(){t(this.container).show(),t(this.container).parent().parent().addClass("active")}.bind(this))},i.prototype.create_button=function(){e.GooglePay.prototype.create_button.apply(this,arguments),t("#wc-stripe-googlepay-container").append(this.$button),this.is_variable_product()&&(this.variable_product_selected()?this.enable_payment_button():this.disable_payment_button())},i.prototype.get_button=function(){return this.$button.find("button")},i.prototype.start=function(){0<this.get_quantity()?this.add_to_cart().then(function(){e.GooglePay.prototype.start.apply(this,arguments)}.bind(this)):this.submit_error(this.params.messages.invalid_amount)},i.prototype.found_variation=function(){e.ProductGateway.prototype.found_variation.apply(this,arguments),this.enable_payment_button()},new i}(jQuery,wc_stripe);