PageSourceSearch

https://silverbirdcinemas.com/wp-content/plugins/holler-box/assets/js/popups.min.js?ver=2.3.13

js silverbirdcinemas.com collected 2026-10-02 10:01:52 UTC 48,018 bytes, 326 lines download raw bytes

1(()=>{const Cookies={MINUTE_IN_SECONDS:60,HOUR_IN_SECONDS:this.MINUTE_IN_SECONDS*60,DAY_IN_SECONDS:this.HOUR_IN_SECONDS*24,WEEK_IN_SECONDS:this.DAY_IN_SECONDS*7,MONTH_IN_SECONDS:this.DAY_IN_SECONDS*30,closedPopups:"holler-closed-popups",popupConversions:"holler-popup-conversions",popupViews:"holler-popup-views",pageViews:"holler-page-views",contentViews:"holler-content-views",potentialViews:"holler-potential-views",sessions:"holler-sessions",addClosedPopup(id){let allClosed=this.getCookie(this.closedPopups,"").split(",");allClosed.push(id);this.setCookie(this.closedPopups,allClosed.join(),HollerBox.cookie_lifetime)},isClosed(id){let allClosed=this.getCookie(this.closedPopups,"").split(",").map(id=>parseInt(id));return allClosed.includes(id)},addPopupCount(cookie,id,ttl=false){if(ttl===false){ttl=HollerBox.cookie_lifetime}let counts=JSON.parse(this.getCookie(cookie,"{}"));if(!counts){counts={}}if(counts[id]){counts[id]+=1}else{counts[id]=1}this.setCookie(cookie,JSON.stringify(counts),ttl)},getPopupCount(cookie,id){let counts=JSON.parse(this.getCookie(cookie,"{}"));return parseInt(counts[id]??0)},addPopupConversion(id){this.addPopupCount(this.popupConversions,id)},getPopupConversions(id){return this.getPopupCount(this.popupConversions,id)},addPopupView(id){this.addPopupCount(this.popupViews,id)},addContentView(id){this.addPopupCount(this.contentViews,id)},addPotentialView(id){this.addPopupCount(this.potentialViews,id)},getPopupViews(id){return this.getPopupCount(this.popupViews,id)},getContentViews(id){return this.getPopupCount(this.contentViews,id)},getPotentialViews(id){return this.getPopupCount(this.potentialViews,id)},addPageView(){this.setCookie(this.pageViews,this.getPageViews()+1,this.DAY_IN_SECONDS)},getPageViews(){return parseInt(this.getCookie(this.pageViews,0))},setCookie(name,value,duration){if(isBuilderPreview()){return}let d=new Date;d.setTime(d.getTime()+duration*1e3);let expires="expires="+d.toUTCString();document.cookie=name+"="+value+";"+expires+";path=/"},getCookie(cname,_default=null){let name=cname+"=";let ca=document.cookie.split(";");for(let i=0;i<ca.length;i++){let c=ca[i];while(c.charAt(0)==" "){c=c.substring(1)}if(c.indexOf(name)==0){return c.substring(name.length,c.length)}}return _default},getSessions(){let obj=JSON.parse(this.getCookie(this.sessions,"{}"));return parseInt(obj.sessions||0)},maybeAddSession(){let obj=JSON.parse(this.getCookie(this.sessions,"{}"));let lastSession=new Date(obj.lastSession);lastSession.setDate(lastSession.getDate()+1);let now=new Date;if(now>lastSession){this.setCookie(this.sessions,JSON.stringify({sessions:parseInt(obj.sessions)+1,lastSession:now.toString()}),HollerBox.cookie_lifetime)}},hasAccepted(){if(!HollerBox.settings.cookie_compliance){return true}let{cookie_name="",cookie_value=""}=HollerBox.settings;return this.getCookie(cookie_name)===cookie_value}};function ApiError(message){this.name="ApiError";this.message=message}ApiError.prototype=Error.prototype;async function apiPost(url="",data={},opts={}){const response=await fetch(url,{method:"POST",headers:{"Content-Type":"application/json","X-WP-Nonce":HollerBox.nonces._wprest},body:JSON.stringify(data),...opts});let json=await response.json();if(!response.ok){throw new ApiError(json.message)}return json}const maybeLog=error=>{if(HollerBox.settings?.script_debug_mode){console.debug(error)}};const overlay=()=>{return`
2        <div class="holler-box-overlay"></div>`};const closeButton=()=>{let curr=currentPopup();if(curr&&!curr.isCloseable()){return""}let{close_button_size="small",close_button_icon="normal"}=curr;if(curr.isNotification()){close_button_icon="normal"}const closeIcons={normal:`
3          <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 365.7 365.7">
4              <path fill="currentColor"
5                    d="M243 183 356 70c13-13 13-33 0-46L341 9a32 32 0 0 0-45 0L183 123 70 9a32 32 0 0 0-46 0L9 24a32 32 0 0 0 0 46l114 113L9 296a32 32 0 0 0 0 45l15 15c13 13 33 13 46 0l113-113 113 113c12 13 33 13 45 0l15-15c13-12 13-33 0-45zm0 0"/>
6          </svg>`,filled:`
7          <svg viewBox="0 0 511.8 511.8" xmlns="http://www.w3.org/2000/svg">
8              <path
9                      d="M 286 256 L 361 180 C 366.359 174.641 368.452 166.83 366.49 159.51 C 362.264 143.736 342.547 138.453 331 150 L 256 226 L 180 150 C 174.641 144.641 166.83 142.548 159.51 144.51 C 143.736 148.736 138.453 168.453 150 180 L 226 256 L 150 331 C 144.641 336.359 142.548 344.17 144.51 351.49 C 148.736 367.264 168.453 372.547 180 361 L 256 286 L 331 361 C 336.359 366.359 344.17 368.452 351.49 366.49 C 367.264 362.264 372.547 342.547 361 331 Z"
10                      style="fill: rgb(255, 255, 255);"/>
11              <path fill="currentColor"
12                    d="M 436.9 74.4 C 297.181 -64.934 59.024 -0.768 8.216 189.899 C -15.363 278.388 10.056 372.735 74.9 437.4 C 214.619 576.734 452.776 512.568 503.584 321.901 C 527.163 233.412 501.744 139.065 436.9 74.4 Z M 360.9 330.4 C 372.447 341.947 367.164 361.664 351.39 365.89 C 344.07 367.852 336.259 365.759 330.9 360.4 L 255.9 285.4 L 179.9 360.4 C 168.353 371.947 148.636 366.664 144.41 350.89 C 142.448 343.57 144.541 335.759 149.9 330.4 L 225.9 255.4 L 149.9 179.4 C 138.353 167.853 143.636 148.136 159.41 143.91 C 166.73 141.948 174.541 144.041 179.9 149.4 L 255.9 225.4 L 330.9 149.4 C 342.447 137.853 362.164 143.136 366.39 158.91 C 368.352 166.23 366.259 174.041 360.9 179.4 L 285.9 255.4 L 360.9 330.4 Z"/>
13          </svg>`};let classes=[close_button_size,close_button_icon];if(curr.isBanner()||curr.isSidebar()){classes.push("icon-inside")}return`
14        <button class="holler-box-modal-close ${classes.join(" ")}">
15            ${closeIcons[close_button_icon]}
16        </button>`};const credit=()=>{if(HollerBox.settings?.credit_disabled){return""}return`
17        <div class="holler-box-credit"><a href="https://hollerwp.com/">⚡ by
18            HollerBox</a></div>`};const createHTML=HTML=>{let div=document.createElement("div");div.innerHTML=HTML;return div.firstElementChild};const escapeStr=string=>{return string.replace(/&/g,"&amp;").replace(/>/g,"&gt;").replace(/</g,"&lt;").replace(/"/g,"&quot;")};const gdprInput=()=>{const HTML=createHTML(HollerBox.settings.gdpr_text);return`<label class="holler-gdpr-consent">
19        <input type="checkbox"
20               name="gdpr_consent"
21               value="yes" required>
22        <span>${HTML.innerHTML}</span></label>`};const nameInput=(placeholder="Your name",required=true)=>{return`<input class="holler-box-input" type="text" name="name"
23                   placeholder="${escapeStr(placeholder)}" ${required?"required":""}>`};const phoneInput=(placeholder="Mobile Number",required=false)=>{return`<input class="holler-box-input" type="tel" name="phone"
24                   placeholder="${escapeStr(placeholder)}" ${required?"required":""}>`};const emailInput=(placeholder="Your email")=>{return`<input class="holler-box-input" type="email" name="email"
25                   placeholder="${escapeStr(placeholder)}" required>`};const submitButton=(text,type="submit")=>{return`
26        <button type="${type}" class="holler-box-button">${text}</button>`};const __title=title=>{return`
27        <h2 class="holler-box-modal-title">${title}</h2>
28    `};const __content=content=>{return`
29        <div class="holler-box-modal-content">
30            ${content}
31        </div>
32    `};const __chatResponse=content=>{return`
33        <div class="holler-box-chat-response">
34            <div class="content">
35                ${content}
36            </div>
37        </div>
38    `};const __chatMessage=({content,avatar})=>{content=`<div class="content">${content}</div>`;return`
39        <div class="holler-box-chat-message">
40            ${avatar?`<img src="${avatar}" class="avatar" alt="">`:""}
41            ${content}
42        </div>
43    `};const notificationClosedTemplate=({id,position})=>{return`
44        <div id="${id}" class="holler-box holler-notification-box">
45            <div class="positioner ${position}">
46                <div class="animation slide-in">
47                    <div class="holler-box-modal notification-closed">
48                        <svg xmlns="http://www.w3.org/2000/svg"
49                             viewBox="0 0 512 512">
50                            <rect width="107.6" height="145.6" x="319.1"
51                                  y="76.6" fill="#fff" rx="5" ry="5"/>
52                            <path fill="#f44336"
53                                  d="M373 0a139 139 0 1 0 1 278 139 139 0 0 0-1-278zm22 187a16 16 0 0 1-32 0v-70h-11a16 16 0 0 1 0-32h27c8 0 16 8 16 16zm0 0"/>
54                            <path fill="#ffa000"
55                                  d="M299 427a85 85 0 1 1-171 0 85 85 0 0 1 171 0zm0 0"/>
56                            <path fill="#ffc107"
57                                  d="M380 320h-7A182 182 0 0 1 220 43h-7c-82 0-149 67-149 149v59c0 43-18 83-51 110a37 37 0 0 0 24 66h352a37 37 0 0 0 24-66c-13-12-24-26-33-41zm0 0"/>
58                        </svg>
59                    </div>
60                </div>
61            </div>
62        </div>`};const removeTrailingSlash=string=>{return string.replace(/\/$/,"")};const makeURL=url=>{try{return new URL(url)}catch(e){try{return new URL(`${removeTrailingSlash(HollerBox.nav.home)}${url.startsWith("/")?"":"/"}${url}`)}catch(e){return new URL(HollerBox.nav.home)}}};const SubmitActions={close:popup=>{popup.close()},redirect:popup=>{let{redirect_url=""}=popup;let url=makeURL(redirect_url);let home=new URL(HollerBox.home_url);if(isBuilderPreview()){if(url.hostname!==home.hostname){popup.close();return}url.searchParams.append("suppress_hollerbox",1)}window.open(url,"_self")},message:popup=>{popup.open()}};function sanitizeTextField(string){const map={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#x27;","/":"&#x2F;"};const reg=/[&<>"'/]/gi;return string.replace(reg,match=>map[match])}const CommonActions={maybeDisableScrolling:popup=>{if(popup.disable_scrolling){document.body.classList.add("disable-scrolling")}},enableScrolling:()=>{document.body.classList.remove("disable-scrolling")},notificationClosed:popup=>{localStorage.setItem(`holler_chat_${popup.ID}_status`,"closed");popup.closed=true;popup.open()},notificationOpened:popup=>{if(popup.closed){document.getElementById(popup.id).addEventListener("click",e=>{popup.close().then(()=>{localStorage.setItem(`holler_chat_${popup.ID}_status`,"open");popup.closed=false;popup.open()})})}},formSubmitted:(popup,filters={})=>{const isCustomForm=popup.use_custom_form;if(isCustomForm){let customForm;let parser=new DOMParser;let doc=parser.parseFromString(popup.custom_form_html,"text/html");customForm=document.importNode(doc.querySelector("form"),true);if(!customForm){throw new Error("Invalid form object")}let form=popup.querySelector("form.holler-box-form");customForm.classList.add("holler-box-form","custom-form");let newForm=document.createElement("form");newForm.setAttribute("action",customForm.getAttribute("action"));newForm.setAttribute("method",customForm.getAttribute("method"));newForm.classList.add("holler-box-form","custom-form");Array.from(customForm.elements).forEach(el=>{el.removeAttribute("style");switch(el.tagName){case"INPUT":switch(el.type){default:el.classList.add("holler-box-input");break;case"submit":case"button":el.classList.add("holler-box-button");break;case"radio":case"checkbox":if(el.parentNode.tagName==="LABEL"){el=el.parentNode;break}if(!el.id){break}let label=customForm.querySelector(`label[for='${el.id}']`);if(!label){break}let div=document.createElement("div");div.appendChild(label);div.appendChild(el);el=div;break}break;case"TEXTAREA":case"SELECT":el.classList.add("holler-box-input");break;case"BUTTON":el.classList.add("holler-box-button");break}newForm.append(el)});form.replaceWith(newForm)}const{modifyFormData=fd=>{},modifyPayload=pl=>{}}=filters;const{id,after_submit="close"}=popup;let theForm=popup.querySelector("form.holler-box-form");const handleFormSubmit=e=>{e.preventDefault();let form=e.target;let formData=new FormData(form);if(isCustomForm){let propertiesMap={email:"email",name:"name",first:"name",last:"name",phone:"phone",tel:"phone"};for(const pair of formData.entries()){for(const prop in propertiesMap){if(pair[0].match(new RegExp(prop,"i"))){let mapTo=propertiesMap[prop];if(formData.has(mapTo)&&formData.get(mapTo)!==pair[1]){formData.set(mapTo,`${formData.get(mapTo)} ${pair[1]}`)}else if(!formData.has(mapTo)){formData.append(mapTo,pair[1])}}}}}formData.append("location",window.location.href);formData.append("referer",document.referrer);modifyFormData(formData);form.querySelector("button").innerHTML='<span class="holler-spinner"></span>';let payload=Object.fromEntries(formData);modifyPayload(payload);return popup.submit({...payload,content:"Form Submitted"}).then(({status="success",failures=[]})=>{if(isCustomForm){return}if(status==="failed"){if(!failures.length){alert("Something when wrong, please try again later.");popup.close();return}console.log(failures);popup.querySelector("form").innerHTML=[`<div class="hollerbox-integration-errors">`,`<p>There are issues with some of your integrations:</p>`,`<ul>`,...failures.map(f=>`<li>${f}</li>`),`</ul>`,`<p>Only admins see this message.</p>`,`</div>`].join("");return}SubmitActions[after_submit](popup)}).catch(e=>{maybeLog(e);
62if(isBuilderPreview()){SubmitActions[after_submit](popup);return}if(!isCustomForm){popup.close()}}).finally(()=>{if(isBuilderPreview()){return}if(isCustomForm){form.removeEventListener("submit",handleFormSubmit);form.submit()}})};theForm.addEventListener("submit",handleFormSubmit)},buttonClicked:popup=>{const{id,button_link}=popup;let button=document.querySelector(`#${id} button.holler-box-button`);let url=makeURL(button_link);let home=new URL(HollerBox.home_url);button.addEventListener("click",e=>{e.preventDefault();button.innerHTML='<span class="holler-spinner"></span>';popup.converted("Clicked Button").then(()=>{if(isBuilderPreview()){if(url.hostname!==home.hostname){popup.close();return}url.searchParams.append("suppress_hollerbox",1)}window.open(url,"_self")})})}};const isGDPREnabled=()=>{return HollerBox.settings?.gdpr_enabled??false};const formProps=({enable_name=true,enable_phone=false,...props})=>({name:enable_name,phone:enable_phone,...props});const form=props=>{const{email=true,name=true,phone=false,direction="vertical",name_placeholder="Name",email_placeholder="Email",phone_placeholder="Phone",button_text="Subscribe",phone_required=false,name_required=true}=formProps(props);let classes=["holler-box-form",direction,name?"has-name":"",phone?"has-phone":"",isGDPREnabled()?"has-gdpr":""];return`
63        <form class="${classes.join(" ")}">
64            <div class="fields">
65                ${name?nameInput(name_placeholder,name_required):""}
66                ${email?emailInput(email_placeholder):""}
67                ${phone?phoneInput(phone_placeholder,phone_required):""}
68                ${direction==="vertical"&&isGDPREnabled()?gdprInput():""}
69                ${submitButton(button_text)}
70            </div>
71            ${direction==="horizontal"&&isGDPREnabled()?gdprInput():""}
72        </form>`};const PopupTemplates={notification_box:{render:({id="",position="bottom-right",post_content="",avatar="",closed=false})=>{if(closed){return notificationClosedTemplate({id:id,position:position})}return`
73            <div id="${id}" class="holler-box holler-notification-box">
74                <div class="positioner ${position}">
75                    <div class="animation slide-in">
76                        <div class="holler-box-modal">
77                            ${closeButton()}
78                            <div class="display-flex">
79                                ${avatar?`<img src="${avatar}" alt="">`:""}
80                                ${__content(post_content)}
81                            </div>
82                            ${credit()}
83                        </div>
84                    </div>
85                </div>
86            </div>`},onOpen:CommonActions.notificationOpened,onClosed:CommonActions.notificationClosed},notification_box_with_button:{render:({id="",position="bottom-right",post_content="",avatar="",button_text="",closed=false})=>{if(closed){return notificationClosedTemplate({id:id,position:position})}return`
87            <div id="${id}"
88                 class="holler-box holler-notification-box with-button">
89                <div class="positioner ${position}">
90                    <div class="animation slide-in">
91                        <div class="holler-box-modal ">
92                            ${closeButton()}
93                            <div class="display-flex">
94                                ${avatar?`<img src="${avatar}" alt="">`:""}
95                                ${__content(post_content)}
96                            </div>
97                            <div class="holler-button-cta">
98                                ${submitButton(button_text,"button")}
99                            </div>
100                            ${credit()}
101                        </div>
102                    </div>
103                </div>
104            </div>`},onOpen:popup=>{CommonActions.notificationOpened(popup);CommonActions.buttonClicked(popup)},onClosed:CommonActions.notificationClosed},notification_box_with_form:{render:({id="",position="bottom-right",post_content="",avatar="",button_text="Signup",email_placeholder="Email",success_message="",closed=false,submitted=false})=>
104{if(closed){return notificationClosedTemplate({id:id,position:position})}return`
105            <div id="${id}"
106                 class="holler-box holler-notification-box with-form ${submitted?"no-animation":""}">
107                <div class="positioner ${position}">
108                    <div class="animation slide-in">
109                        <div class="holler-box-modal">
110                            ${closeButton()}
111                            <div class="display-flex">
112                                ${avatar?`<img src="${avatar}" alt="">`:""}
113                                ${__content(submitted?success_message:post_content)}
114                            </div>
115                            ${submitted?"":form({direction:"horizontal",name:false,button_text:button_text,email_placeholder:email_placeholder})}
116                            ${credit()}
117                        </div>
118                    </div>
119                </div>
120            </div>`},onOpen:popup=>{CommonActions.notificationOpened(popup);CommonActions.formSubmitted(popup)},onClosed:CommonActions.notificationClosed},fake_chat:{render:popup=>{const{id="",position="bottom-right",post_content="",avatar="",button_text="",message_placeholder="Type your message",state="message",closed=false,doAnimations=true}=popup;if(closed){return`
121              <div id="${id}" class="holler-box holler-notification-box">
122                  <div class="positioner ${position}">
123                      <div class="animation slide-in">
124                          <div class="holler-box-modal notification-closed">
125                              <svg xmlns="http://www.w3.org/2000/svg"
126                                   viewBox="0 0 512 512">
127                                  <path fill="#fff"
128                                        d="M303.4 61.4A207 207 0 0 0 195 31C89 31 0 110 0 211a169 169 0 0 0 32 98.7L2.6 401.4a15 15 0 0 0 21.1 18l88.8-45.2c3.6 1.6 7.3 3 11 4.3A198.2 198.2 0 0 1 92 271c0-114.9 96.7-203.2 211.4-209.6z"/>
129                                  <path fill="#fff"
130                                        d="M480 369.7a169 169 0 0 0 32-98.7c0-101.1-89-180-195-180s-195 79-195 180c0 101.1 89 180 195 180 28.4 0 56.7-5.8 82.4-16.8l88.8 45.2a15 15 0 0 0 21-18zM256 286a15 15 0 1 1 0-30 15 15 0 0 1 0 30zm60 0a15 15 0 1 1 0-30 15 15 0 0 1 0 30zm60 0a15 15 0 1 1 0-30 15 15 0 0 1 0 30z"/>
131                              </svg>
132                          </div>
133                      </div>
134                  </div>
135              </div>`}if(!popup.messages){popup.messages=[]}if(!popup.messages.length){popup.messages.push(__chatMessage({avatar:avatar,content:post_content}))}let input;switch(state){default:case"message":case"message_2":input=`<textarea rows="1" name="message"
136                               placeholder="${message_placeholder}"
137                               class="holler-box-input" required></textarea>`;break;case"name":input=nameInput();break;case"email":input=emailInput();break}if(state==="done"){return`
138              <div id="${id}"
139                   class="holler-box holler-notification-box with-chat">
140                  <div class="positioner ${position}">
141                      <div class="animation ${doAnimations?"slide-in":""}">
142                          <div class="holler-box-modal ">
143                              ${closeButton()}
144                              ${popup.messages.join("")}
145                              <div class="close-chat-wrap">
146                                  <button class="close-chat">&times; Close
147                                      chat
148                                  </button>
149                              </div>
150                              ${credit()}
151                          </div>
152                      </div>
153                  </div>
154              </div>`}return`
155            <div id="${id}"
156                 class="holler-box holler-notification-box with-chat">
157                <div class="positioner ${position}">
158                    <div class="animation ${doAnimations?"slide-in":""}">
159                        <div class="holler-box-modal ">
160                            ${closeButton()}
161                            ${popup.messages.join("")}
162                            <form class="holler-chat-form">
163                                ${input}
164                                <button type="submit" class="send-message">
165                                    <svg xmlns="http://www.w3.org/2000/svg"
166                                         viewBox="0 0 404.644 404.644">
167                                        <path fill="currentColor"
168                                              d="M5.535 386.177c-3.325 15.279 8.406 21.747 19.291 16.867l367.885-188.638h.037c4.388-2.475 6.936-6.935 6.936-12.08 0-5.148-2.548-9.611-6.936-12.085h-.037L24.826 1.6C13.941-3.281 2.21 3.189 5.535 18.469c.225 1.035 21.974 97.914 33.799 150.603l192.042 33.253-192.042 33.249C27.509 288.26 5.759 385.141 5.535 386.177z"/>
169                                    </svg>
170                                </button>
171                            </form>
172                            ${credit()}
173                        </div>
174                    </div>
175                </div>
176            </div>`},beforeOpen:popup=>{if(!popup.state){popup.state="message"}if(!popup.responses){popup.responses={}}if(!popup.messages){popup.messages=[]}let status=localStorage.getItem(`holler_chat_${popup.ID}_status`);popup.closed=status==="closed"},onOpen:popup=>{if(popup.closed){return CommonActions.notificationOpened(popup)}let modal=popup.querySelector(".holler-box-modal");modal.scrollTop=modal.scrollHeight;const form=document.querySelector(`#${popup.id} form.holler-chat-form`);if(popup.state!=="message"){document.querySelector(`#${popup.id} .holler-box-input`)?.focus()}if(["message","more"].includes(popup.state)){document.querySelector(`#${popup.id} .holler-box-input`).addEventListener("keydown",e=>{if(e.key==="Enter"&&!e.shiftKey){form.dispatchEvent(new Event("submit"))}})}if(popup.state==="done"){document.querySelector(`#${popup.id} .close-chat`).addEventListener("click",()=>{popup.close()})}if(!form){return}form.addEventListener("submit",e=>{e.preventDefault();let fd=new FormData(e.target);switch(popup.state){default:case"message":let message=sanitizeTextField(fd.get("message"));popup.responses.message=message;popup.messages.push(__chatResponse(message));popup.messages.push(__chatMessage({content:popup.name_prompt??"<p>What is your name?</p>",avatar:popup.avatar}));popup.state="name";break;case"name":let name=sanitizeTextField(fd.get("name"));popup.responses.name=name;popup.messages.push(__chatResponse(name));popup.messages.push(__chatMessage({content:popup.email_prompt??"<p>What is your best email address?</p>",avatar:popup.avatar}));popup.state="email";break;case"email":popup.responses.email=fd.get("email");popup.messages.push(__chatResponse(fd.get("email")));popup.messages.push(__chatMessage({content:popup.message_prompt??"<p>Thanks for providing that information!</p><p>Can you please describe your needs in more detail?</p>",avatar:popup.avatar}));popup.state="more";break;case"more":let message2="\n\n"+sanitizeTextField(fd.get("message"));popup.responses.message+=message2;popup.messages.push(__chatResponse(message2));popup.state="done";popup.submit({...popup.responses,content:"Chat"}).then(r=>{switch(popup.after_submit){case"message":popup.messages.push(__chatMessage({content:popup.success_message,avatar:popup.avatar}));popup.open();break;case"close":popup.close();break;case"redirect":SubmitActions["redirect"](popup);break}}).catch(e=>maybeLog(e));break}popup.doAnimations=false;popup.open()})},onClosed:popup=>{CommonActions.notificationClosed(popup);popup.doAnimations=true}},popup_custom:{render:({id="",position="center-center",animation="appear",post_content="",overlay_enabled=true})=>{return`
177            <div id="${id}" class="holler-box holler-popup holler-popup-custom">
178                ${overlay_enabled?overlay():""}
179                <div class="positioner ${position}">
180                    <div class="animation ${animation}">
181                        <div class="holler-box-modal">
182                            ${closeButton()}
183                            ${__content(post_content)}
184                        </div>
185                        ${credit()}
186                    </div>
187                </div>
188            </div>`},onOpen:CommonActions.maybeDisableScrolling,onClosed:CommonActions.enableScrolling},popup_standard:{render:({id="",position="center-center",animation="appear",post_content="",submitted=false,success_message="",overlay_enabled=true,...props})=>{return`
189            <div id="${id}"
190                 class="holler-box holler-popup holler-popup-standard ${submitted?"no-animation":""}">
191                ${overlay_enabled?overlay():""}
192                <div class="positioner ${position}">
193                    <div class="animation ${animation}">
194                        <div class="holler-box-modal">
195                            ${closeButton()}
196                            ${__content(submitted?success_message:post_content)}
197                            ${submitted?"":form({direction:"vertical",...props})}
198                        </div>
199                        ${credit()}
200                    </div>
201                </div>
202            </div>`},onOpen:popup=>{CommonActions.formSubmitted(popup);CommonActions.maybeDisableScrolling(popup)},onClose:CommonActions.enableScrolling},popup_image_left:{render:({id="",position="center-center",animation="appear",title="",post_content="",image_src="",submitted=false,success_message="",overlay_enabled=true,...props})=>{return`
203            <div id="${id}"
204                 class="holler-box holler-popup holler-popup-image-left ${submitted?"no-animation":""}">
205                ${overlay_enabled?overlay():""}
206                <div class="positioner ${position}">
207                    <div class="animation ${animation}">
208                        <div class="holler-box-modal">
209                            ${closeButton()}
210                            <div class="display-flex">
211                                <div class="left image-width"
212                                     style="background-image: url('${image_src}')">
213                                </div>
214                                <div class="right">
215                                    ${__content(submitted?success_message:post_content)}
216                                    ${submitted?"":form({direction:"vertical",...props})}
217                                </div>
218                            </div>
219                        </div>
220                        ${credit()}
221                    </div>
222                </div>
223            </div>`},onOpen:popup=>{CommonActions.formSubmitted(popup);CommonActions.maybeDisableScrolling(popup)},onClose:CommonActions.enableScrolling},popup_image_right:{render:({id="",position="center-center",animation="appear",title="",post_content="",image_src="",submitted=false,success_message="",overlay_enabled=true,...props})=>{return`
224            <div id="${id}"
225                 class="holler-box holler-popup holler-popup-image-right ${submitted?"no-animation":""}">
226                ${overlay_enabled?overlay():""}
227                <div class="positioner ${position}">
228                    <div class="animation ${animation}">
229                        <div class="holler-box-modal">
230                            ${closeButton()}
231                            <div class="display-flex">
232                                <div class="left">
233                                    ${__content(submitted?success_message:post_content)}
234                                    ${submitted?"":form({direction:"vertical",...props})}
235                                </div>
236                                <div class="right image-width"
237                                     style="background-image: url('${image_src}')">
238                                </div>
239                            </div>
240                        </div>
241                        ${credit()}
242                    </div>
243                </div>
244            </div>`},onOpen:popup=>{CommonActions.formSubmitted(popup);CommonActions.maybeDisableScrolling(popup)},onClose:CommonActions.enableScrolling},popup_form_below:{render:({id="",position="center-center",animation="appear",post_content="",image_src="",overlay_enabled=true,submitted=false,success_message="",...props})=>{return`
245            <div id="${id}"
246                 class="holler-box holler-popup holler-popup-form-below ${submitted?"no-animation":""}">
247                ${overlay_enabled?overlay():""}
248                <div class="positioner ${position}">
249                    <div class="animation ${animation}">
250                        <div class="holler-box-modal">
251                            ${closeButton()}
252                            <div class="display-flex">
253                                <div class="left">
254                                    ${__content(submitted?success_message:post_content)}
255                                </div>
256                                <div class="right image-width"
257                                     style="background-image: url('${image_src}')">
258                                </div>
259                            </div>
260                            ${submitted?"":form({direction:"horizontal",...props,phone:false})}
261                        </div>
262                        ${credit()}
263                    </div>
264                </div>
265            </div>`},onOpen:popup=>{CommonActions.formSubmitted(popup);CommonActions.maybeDisableScrolling(popup)},onClose:CommonActions.enableScrolling},popup_progress_bar:{render:({id="",position="center-center",animation="appear",post_content="",image_src="",overlay_enabled=true,submitted=false,success_message="",...props})=>{return`
266            <div id="${id}"
267                 class="holler-box holler-popup holler-popup-progress-bar ${submitted?"no-animation":""}">
268                ${overlay_enabled?overlay():""}
269                <div class="positioner ${position}">
270                    <div class="animation ${animation}">
271                        <div class="holler-box-modal">
272                            ${closeButton()}
273                            <div class="holler-box-progress-bar-wrap">
274                                <div class="holler-box-progress-bar">
275                                    <div
276                                            class="holler-box-progress-bar-fill ${submitted?"filled":""}"></div>
277                                </div>
278                            </div>
279                            <div class="display-flex">
280                                <div class="left image-width"
281                                     style="background-image: url('${image_src}')">
282                                </div>
283                                <div class="right">
284                                    ${__content(submitted?success_message:post_content)}
285                                    ${submitted?"":form({direction:"vertical",...props})}
286                                </div>
287                            </div>
288                        </div>
289                        ${credit()}
290                    </div>
291                </div>
292            </div>`},onOpen:popup=>{CommonActions.formSubmitted(popup);CommonActions.maybeDisableScrolling(popup)},onClose:CommonActions.enableScrolling},popup_image_beside_text_top:{render:({id="",position="center-center",animation="appear",title="",post_content="",image_src="",overlay_enabled=true,submitted=false,success_message="",...props})=>{return`
293            <div id="${id}"
294                 class="holler-box holler-popup holler-popup-image-beside-text-top ${submitted?"no-animation":""}">
295                ${overlay_enabled?overlay():""}
296                <div class="positioner ${position}">
297                    <div class="animation ${animation}">
298                        <div class="holler-box-modal">
299                            ${closeButton()}
300                            ${__content(submitted?success_message:post_content)}
301                            <div class="display-flex">
302                                <div class="left image-width"
303                                     style="background-image: url('${image_src}')">
304                                </div>
305                                ${submitted?"":form({direction:"vertical",...props})}
306                            </div>
307                        </div>
308                        ${credit()}
309                    </div>
310                </div>
311            </div>`},onOpen:popup=>{CommonActions.formSubmitted(popup);CommonActions.maybeDisableScrolling(popup)},onClose:CommonActions.enableScrolling},popup_full_image_background:{render:({id="",position="center-center",animation="appear",image_src="",post_content="",overlay_enabled=true,submitted=false,success_message="",...props})=>{return`
312            <div id="${id}"
313                 class="holler-box holler-popup holler-popup-full-image-background ${submitted?"no-animation":""}">
314                ${overlay_enabled?overlay():""}
315                <div class="positioner ${position}">
316                    <div class="animation ${animation}">
317                        <div class="holler-box-modal"
318                             style="background-image: url('${image_src}')">
319                            ${closeButton()}
320                            ${__content(submitted?success_message:post_content)}
321                            ${submitted?"":form({direction:"vertical",...props})}
322                        </div>
323                        ${credit()}
324                    </div>
325                </div>
326            </div>`},onOpen:popup=>{CommonActions.formSubmitted(popup);CommonActions.maybeDisableScrolling(popup)},onClose:CommonActions.enableScrolling}};const notificationTemplates=()=>[...Object.keys(PopupTemplates).filter(s=>s.startsWith("notification_box")),"fake_chat"];function getScrollPercent(){var h=document.documentElement,b=document.body,st="scrollTop",sh="scrollHeight";return(h[st]||b[st])/((h[sh]||b[sh])-h.clientHeight)*100}const PopupStack={stack:[],add(p){this.stack.push(p)},next(){let p=this.stack.pop();if(p){setTimeout(()=>{p.maybeOpen()},HollerBox.settings.stacked_delay*1e3)}}};const TriggerCallbacks={on_page_load:({delay=1},show)=>{setTimeout(show,delay*1e3)},element_click:({selector="",trigger_multiple="once"},show,popup)=>{document.querySelectorAll(selector).forEach(el=>{el.addEventListener("click",e=>{if(trigger_multiple==="multiple"){popup._triggered=false}if(show()){e.preventDefault()}})})},scroll_detection:({depth=50},show)=>{document.addEventListener("scroll",()=>{if(getScrollPercent()>=parseInt(depth)){show()}})},exit_intent:(popup,show)=>
326{if(isMobile()){window.addEventListener("popstate",event=>{if(show()){history.pushState(null,document.title,window.location.href)}});setTimeout(()=>{let startY=0;let startTime=0;let startScroll=0;window.addEventListener("touchstart",function(event){startY=event.touches[0].clientY;startTime=Date.now();startScroll=window.scrollY});window.addEventListener("touchmove",function(event){const deltaY=startY-event.touches[0].clientY;const currentTime=Date.now();const timeDiff=currentTime-startTime;if(deltaY<0&&startScroll>window.scrollY&&Math.abs(deltaY)/timeDiff>.5){show()}});window.addEventListener("touchend",function(event){startY=0;startTime=0;startScroll=0})},1e3)}window.addEventListener("mouseout",e=>{if(!e.toElement&&!e.relatedTarget){show()}})}};const isMobile=()=>{const screenWidth=Math.max(document.documentElement.clientWidth||0,window.innerWidth||0);const screenHeight=Math.max(document.documentElement.clientHeight||0,window.innerHeight||0);const isMobile=/Android|webOS|iPhone|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);return isMobile||screenWidth<768&&screenHeight<1024};const isDesktop=()=>!isMobile();const AdvancedDisplayRules={hide_if_converted:({},popup)=>popup.getConversions()===0,hide_if_closed:({},popup)=>!Cookies.isClosed(popup.ID),show_up_to_x_times:({times=1},popup)=>parseInt(times)>popup.getViews(),show_after_x_page_views:({views})=>parseInt(views)<Cookies.getPageViews(),show_after_x_content_views:({views},popup)=>{views=parseInt(views);return views<Cookies.getContentViews(popup.ID)},show_after_x_potential_views:({views},popup)=>{views=parseInt(views);if(views<Cookies.getPotentialViews(popup.ID)){return true}Cookies.addPotentialView(popup.ID);return false},show_to_new_or_returning:({visitor="all"})=>{switch(visitor){default:case"all":return true;case"new":return Cookies.getSessions()<=1;case"returning":return Cookies.getSessions()>1}},show_on_x_devices:({device})=>{switch(device){default:return true;case"mobile":return isMobile();case"desktop":return isDesktop()}}};const Popup=popup=>({template:"",...popup,id:`popup-${popup.ID}`,_triggered:false,_open:false,_converted:false,_template:{},submitted:false,isOpen(){return this._open},isClosed(){return!this.isOpen()},isSubmitted(){return this.submitted},isConverted(){return this._converted},isViewed(){return this._viewed},wasTriggered(){return this._triggered},isNotification(){return notificationTemplates().includes(this.template)},isPopup(){return this.template.startsWith("popup_")},isBanner(){return this.template.startsWith("banner_")},isSidebar(){return this.template.startsWith("sidebar_")},isCloseable(){if(this.isNotification()){return true}return!this.disable_closing||this.isConverted()},querySelector(selector=""){return document.querySelector(`#${this.id} ${selector}`)},querySelectorAll(selector=""){return document.querySelectorAll(`#${this.id} ${selector}`)},addEventListener(event,callback){return this.querySelector().addEventListener(event,callback)},render(){try{let div=document.createElement("div");div.innerHTML=this._template.render(this);let popup=div.firstElementChild;popup.setAttribute("tabindex",0);return popup}catch(e){maybeLog(e);return""}},addToDom(){let el=document.getElementById(this.id);let rendered=this.render();if(el){el.replaceWith(rendered)}else{document.body.append(rendered)}if(!isBuilderPreview()){rendered.focus()}},removeFromDom(){document.getElementById(this.id)?.remove()},converted(content=""){this._converted=true;if(isBuilderPreview()){return Promise.resolve()}Cookies.addPopupConversion(this.ID);if(content){return apiPost(HollerBox.routes.conversion,{popup_id:this.ID,location:window.location.href,referer:document.referrer,content:content})}},viewed(){if(this.isViewed()){return Promise.resolve()}this._viewed=true;if(isBuilderPreview()){return Promise.resolve()}Cookies.addPopupView(this.ID);return apiPost(HollerBox.routes.impression,{popup_id:this.ID,location:window.location.href,referer:document.referrer})},submit(data){return apiPost(`${HollerBox.routes.submit}/${this.ID}`,{location:window.location.href,referrer:document.referrer,...data}).then(r=>{this.submitted=true;this.converted(false);this.dispatchEvent("holler_submit",{data:data,response:r});return r})},dispatchEvent(event,data={}
326){let customEvent=new CustomEvent(event,{detail:{popup:this,...data}});let el=this.querySelector();if(el){el.dispatchEvent(customEvent)}document.dispatchEvent(customEvent)},getConversions(){return Cookies.getPopupConversions(this.ID)},getViews(){return Cookies.getPopupViews(this.ID)},cleanup(){try{this._template.cleanup(this)}catch(e){maybeLog(e)}},handleShortcodeContent(when){if(isBuilderPreview()){return}switch(when){case"beforeAddToDom":if(this.has_shortcodes.in_content){this.post_content=`<div id="post-content-for-${this.ID}-goes-here"></div>`}if(this.has_shortcodes.in_success_message){this.success_message=`<div id="success-message-for-${this.ID}-goes-here"></div>`}break;case"afterAddToDom":if(this.has_shortcodes.in_content){let target=this.querySelector(`#post-content-for-${this.ID}-goes-here`);let content=document.querySelector(`#holler-${this.ID}-content`);if(target&&content){content.querySelectorAll("p:empty").forEach(el=>el.remove());target.replaceWith(content)}}if(this.has_shortcodes.in_success_message){let target=this.querySelector(`#success-message-for-${this.ID}-goes-here`);let content=document.querySelector(`#holler-${this.ID}-success-message`);if(target&&content){content.querySelectorAll("p:empty").forEach(el=>el.remove());target.replaceWith(content)}}break;case"beforeRemoveFromDom":let container=document.querySelector("#hollerbox-popup-content");if(this.has_shortcodes.in_content){let content=document.querySelector(`#holler-${this.ID}-content`);if(content&&container){container.append(content)}}if(this.has_shortcodes.in_success_message){let content=document.querySelector(`#holler-${this.ID}-success-message`);if(content&&container){container.append(content)}}break}},async open(){this._triggered=true;this._open=true;try{await this._template.beforeOpen(this)}catch(e){maybeLog(e)}this.handleShortcodeContent("beforeAddToDom");this.addToDom();this.handleShortcodeContent("afterAddToDom");if(this.isCloseable()){this.querySelectorAll(".holler-box-modal-close").forEach(el=>{el.addEventListener("click",e=>{this.close()})});setTimeout(()=>{let overlay=this.querySelector(".holler-box-overlay");if(overlay){this.querySelector(".holler-box-overlay").addEventListener("click",e=>{this.close()})}},2e3);this.querySelector().addEventListener("keyup",e=>{if(e.key==="Escape"){this.close()}})}try{this._template.onOpen(this)}catch(e){maybeLog(e)}this.viewed();this.dispatchEvent("holler_open")},async close(){try{await this._template.onClose(this)}catch(e){maybeLog(e)}this.handleShortcodeContent("beforeRemoveFromDom");this.removeFromDom();this._open=false;try{await this._template.onClosed(this)}catch(e){maybeLog(e)}if(isBuilderPreview()){this.submitted=false;this._converted=false;if(!this.isOpen()){setTimeout(()=>this.open(),1e3)}this.dispatchEvent("holler_close");return}Cookies.addClosedPopup(this.ID);if(HollerBox.is_user_logged_in){apiPost(HollerBox.routes.closed,{popup_id:this.ID}).catch(e=>console.log(e))}this.dispatchEvent("holler_close");PopupStack.next()},isBlocking(other){if(other.isNotification()&&this.isNotification()&&other.position===this.position){return true}if(this.overlay_enabled||this.querySelector(".holler-box-overlay")){return true}return this.is_blocking??false},maybeOpen(){if(this.isOpen()||this.wasTriggered()){return false}for(let rule in this.advanced_rules){if(!this.advanced_rules[rule].enabled){continue}if(AdvancedDisplayRules.hasOwnProperty(rule)){if(!AdvancedDisplayRules[rule](this.advanced_rules[rule],this)){return false}}}if(HollerBox.active.some(p=>p.isOpen()&&p.isBlocking(this))){PopupStack.add(this);return false}this.open();return true},setTemplate(){if(!PopupTemplates.hasOwnProperty(this.template)){return false}this._template={render:()=>"",onOpen:()=>{},beforeOpen:()=>{},onClose:()=>{},onClosed:()=>{},cleanup:()=>{},...PopupTemplates[this.template]};return true},init(){if(!this.setTemplate()){return}Cookies.addContentView(this.ID);const show=()=>this.maybeOpen();
326Object.keys(TriggerCallbacks).forEach(_t=>{if(this.triggers[_t]?.enabled){TriggerCallbacks[_t](this.triggers[_t],show,this)}});document.querySelectorAll(`.holler-upgrade.holler-show[data-id="${this.ID}"]`).forEach(el=>{el.addEventListener("click",e=>{e.preventDefault();popup._triggered=false;show()})});this.dispatchEvent("holler_init")}});if(HollerBox.is_frontend){const initHollerBox=()=>{if(HollerBox._initialized){return}HollerBox._initialized=true;HollerBox.active=HollerBox.active.map(p=>Popup(p));HollerBox.active.sort(({menu_order:a=10},{menu_order:b=10})=>a-b);HollerBox.active.forEach(popup=>{popup.init()});Cookies.addPageView();Cookies.maybeAddSession()};window.addEventListener("load",()=>{if(Cookies.hasAccepted()){initHollerBox();return}document.addEventListener("click",()=>{setTimeout(()=>{if(Cookies.hasAccepted()){initHollerBox()}},100)})})}function clickedIn(e,selector){var el=e.tagName?e:e.srcElement||e.target;if(el&&el.matches(selector)){return el}else{while(el=el.parentNode){if(typeof el.matches!=="undefined"&&el.matches(selector)){return el}}}return false}const isBuilderPreview=()=>HollerBox.is_builder_preview;let popup;if(isBuilderPreview()){let home=new URL(HollerBox.home_url);window.addEventListener("message",function(event){if(event.origin===window.location.origin){if(popup){popup.cleanup()}const{cssOnly=false,suppressAnimations=true,overrides={},popup:_popup={}}=event.data;popup=Popup(_popup);popup={...popup,...overrides};popup.setTemplate();if(cssOnly){document.getElementById("hollerbox-builder-styles").innerHTML=popup.css;return}if(suppressAnimations){document.body.classList.add("holler-suppress-animations")}else{document.body.classList.remove("holler-suppress-animations");document.body.style.marginTop="0";document.body.style.marginBottom="0"}document.querySelectorAll(".holler-box").forEach(el=>el.remove());document.getElementById("hollerbox-builder-styles").innerHTML=popup.css;popup.open()}},false);window.addEventListener("load",()=>{document.addEventListener("click",e=>{let el=clickedIn(e,"a");if(!el){return}let url;try{url=new URL(el.href)}catch(e){maybeLog(e);return}if(url.searchParams.has("suppress_hollerbox")){return}e.preventDefault();if(url.hostname!==home.hostname||url.pathname.match(/wp-admin/)||url.pathname.match(/wp-login\.php/)){}else{url.searchParams.append("suppress_hollerbox",1);el.href=url;el.click()}});document.querySelectorAll("a").forEach(el=>{const noClick=()=>{el.classList.add("no-click");el.addEventListener("click",e=>{e.preventDefault()})};let url;try{url=new URL(el.href)}catch(e){noClick();return}if(url.hostname!==home.hostname||url.pathname.match(/wp-admin/)||url.pathname.match(/wp-login\.php/)){noClick()}else{url.searchParams.append("suppress_hollerbox",1);el.href=url}});document.querySelectorAll("form").forEach(el=>{el.addEventListener("submit",e=>{e.preventDefault();e.stopImmediatePropagation()})})})}const currentPopup=()=>{if(isBuilderPreview()){return popup}if(HollerBox.hasOwnProperty("editor")){if(HollerBox.editor.current_preview){return Popup(HollerBox.editor.current_preview)}return Popup(HollerBox.editor.getPopup())}return HollerBox.active.find(p=>p.isOpen())};HollerBox.cookies=Cookies;HollerBox.templates=PopupTemplates;HollerBox._frontend={CommonActions:CommonActions,SubmitActions:SubmitActions,closeButton:closeButton,credit:credit,form:form,nameInput:nameInput,emailInput:emailInput,__content:__content,overlay:overlay,submitButton:submitButton,TriggerCallbacks:TriggerCallbacks,maybeLog:maybeLog,isBuilderPreview:isBuilderPreview,makeURL:makeURL};HollerBox.api={apiPost:apiPost}})();

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.