\n"):e,setAttributes(e,t){for(var n in t)e.setAttribute(n,t[n])},inputToggle(e){if(e.target.classList.contains("input-toggle")){let t=e.target.parentElement.lastElementChild;!0===e.target.checked?(t.style.height=t.scrollHeight+"px",t.classList.remove("hidden")):(t.firstChild.value="",t.style.height=null,t.classList.add("hidden"))}},addInput({parent:e,elm:t,placeholder:n,type:l,name:a,max:i}){i=i||6;let r=document.createElement("div");r.setAttribute("class","new-input");let o=document.createElement("input");o.setAttribute("type",l),o.setAttribute("placeholder",n),o.setAttribute("name",a);let s=document.createElement("button");s.setAttribute("class","remove"),s.setAttribute("type","button"),r.appendChild(o),r.appendChild(s),t.appendChild(r),t.childNodes.length>=i&&(t.nextElementSibling.disabled=!0,t.nextElementSibling.style.cssText="opacity:.3;cursor:not-allowed"),e.style.height=e.scrollHeight+"px"},removeInput({elm:e,target:t,max:n}){if(n=n||6,"remove"===t.className){--n;let a=t.parentElement.parentNode;var l=t.parentElement.getBoundingClientRect().height;t.parentElement.remove(),e.style.height=e.getBoundingClientRect().height-l+"px",a.childNodes.length<=n&&(a.nextElementSibling.disabled=!1,a.nextElementSibling.style.cssText="opacity:1;cursor:pointer;")}}};!function(e){let t=e.getElementById("output-code"),n=e.getElementById("submit"),l=e.querySelector(".error-box"),a=e.getElementById("url-gambar-input"),i=e.getElementById("add-image-url"),r=e.getElementById("add-payment-method"),o=e.getElementById("input-collection2"),s=e.getElementById("hidecheckoutchat");function c(t){let n=e.getElementById(t);n.classList.toggle("notallowed");let l=n.parentElement.lastElementChild;n.classList.contains("notallowed")?(n.disabled=!0,n.checked=!1,l.style.height=null):n.disabled=!1}var d;function p(e,t,n){return""==e?"":''+n+""}function u(e){return Number(e).toLocaleString("id-ID",{style:"currency",currency:"IDR",maximumFractionDigits:0})}d="#url-gambar-input",(d=e.querySelector(d)).style.height=d.scrollHeight+"px",s.addEventListener("change",function(){c("nomorwhatsapp"),c("metodepembayaran")}),i.addEventListener("click",function(){helperFn.addInput({parent:this.previousElementSibling,elm:this.previousElementSibling,placeholder:"https://...",type:"url",name:"url-gambar",max:5})}),r.addEventListener("click",function(){helperFn.addInput({parent:this.previousElementSibling.parentNode,elm:this.previousElementSibling,placeholder:"Contoh: BCA, 1122334400, Sugeng Riyadi",type:"text",name:"metode-pembayaran",max:5})}),a.addEventListener("click",function(e){helperFn.removeInput({elm:this,target:e.target,max:5})}),o.addEventListener("click",function(e){helperFn.removeInput({elm:this,target:e.target,max:5})}),n.addEventListener("click",function(){let n,a=[],i=e.getElementById("url-gambar-input").querySelectorAll("input"),r=e.getElementById("input-metode-pembayaran").querySelectorAll("input"),o=helperFn.getVal("#harga").replace(/\D/g,""),s=helperFn.getVal("#hargapromo").replace(/\D/g,""),c=helperFn.getVal("#status"),d=helperFn.lineToBr(helperFn.getVal("#deskripsi"),"tagbr"),h=helperFn.lineToBr(helperFn.getVal("#deskripsi-long"),"tagbr2"),g=helperFn.getVal("#checkouturl"),m=helperFn.getVal("#hidecheckoutchat"),v=helperFn.getVal("#nomorwhatsapp"),y=helperFn.getVal("#metodepembayaran"),b=helperFn.getVal("#url-checkout"),k=helperFn.getVal("#no-whatsapp"),E=p(helperFn.getVal("#tokopedia"),"link-tokopedia","Tokopedia"),f=p(helperFn.getVal("#shopee"),"link-shopee","Shopee"),L=p(helperFn.getVal("#bukalapak"),"link-bukalapak","Bukalapak"),S=p(helperFn.getVal("#blibli"),"link-blibli","Blibli"),x=p(helperFn.getVal("#lazada"),"link-lazada","Lazada"),F=p(helperFn.getVal("#marketplace-lain"),"link-custom",helperFn.getVal("#marketplace-lain-title")),A=function(e){let t="";for(let l=0;l')}return t}(i),V=y?function(e){let t="themeSetting.rekbank = [";for(let l=0;l'+c+"":"",n=""==s?u(o):""+u(o)+" "+u(s),Array.from(i).forEach(function(e){helperFn.checkURL(e.value)?e.classList.remove("error"):(a.push("Error"),e.classList.add("error"))}),0\n',T+='\t'+A+"\n\t
\n",T+='\t'+c+"\n\t
\n",T+="\n\n",T+='\n\n",T+=''+d+"
\n\n",T+=''+h+"
\n\n",T+='\n\n',T+=''+E+f+L+S+x+F+"
\n\n",T+="