!function r(i,o,a){function s(t,e){if(!o[t]){if(!i[t]){var n="function"==typeof require&&require;if(!e&&n)return n(t,!0);if(u)return u(t,!0);throw(e=new Error("Cannot find module '"+t+"'")).code="MODULE_NOT_FOUND",e}n=o[t]={exports:{}},i[t][0].call(n.exports,function(e){return s(i[t][1][e]||e)},n,n.exports,r,i,o,a)}return o[t].exports}for(var u="function"==typeof require&&require,e=0;e"));var e=a("[api_login_id]"),r=(e.length<1&&(e=a("[api_access_id]")),null);window.addEventListener&&window.addEventListener("message",function(t){var n;"applepayabort"===t.data.type&&r.abort(),"applepaycomplete"===t.data.type&&r.completePayment(window.ApplePaySession.STATUS_SUCCESS),"applepaycompletepm"===t.data.type&&r.completePaymentMethodSelection(t.data.total,t.data.lineItems),"applepaycompletemv"===t.data.type&&r.completeMerchantValidation(t.data.data),"applepay"===t.data.type&&(n=t.data.data,(r=new window.ApplePaySession(1,n)).onvalidatemerchant=function(e){t.source.postMessage({type:"validatemerchant",validationUrl:e.validationURL,domain:window.location.host},"*")},r.onpaymentmethodselected=function(e){t.source.postMessage({type:"paymentmethodselected",request:n,paymentMethod:e.paymentMethod},"*")},r.onpaymentauthorized=function(e){t.source.postMessage({type:"paymentauthorized",request:n,payment:e.payment},"*")},r.oncancel=function(e){console.log("oncancel called")},r.begin())}),e.click(function(e){e.preventDefault(),e.stopPropagation();var t,n,r=this,i=(e.preventDefault(),e.stopPropagation(),a(r)),o=i.attr("data-id"),i=(a('
').appendTo(document.body),i.attr("callback")&&""!=i.attr("callback")&&i.after('