PageSourceSearch

https://storeopinion-can.com/wp-content/themes/neve/assets/js/build/modern/frontend.js?ver=4.2.11

js storeopinion-can.com collected 2026-09-28 08:12:55 UTC 8,185 bytes, 1 lines download raw bytes

1!function(){"use strict";const e=(e,t=document)=>t.querySelector(e),t=(e,t=document)=>t.querySelectorAll(e),n=(e,t)=>document.dispatchEvent(new CustomEvent(e,{detail:t})),o=(e,t,n,o)=>e.addEventListener(t,n,o),i=(e,t)=>e.classList.contains(t),r=e=>e.preventDefault(),s=e=>e.getBoundingClientRect(),a=(e,t,n)=>{(e instanceof NodeList?e:[e]).forEach(e=>e.addEventListener(t,t=>n(t,e)))},c=(e,t)=>{u(e,t,"add")},d=(e,t)=>{u(e,t,"remove")},u=(e,t,n)=>{const o=t.split(" ");(e instanceof NodeList?e:[e]).forEach(e=>e.classList[n].apply(e.classList,o))};let l=null,p=2;const f=()=>{const{masonryStatus:t,masonryColumns:n,blogLayout:o}=NeveProperties;"enabled"!==t||n<2||(l=e(".nv-index-posts .posts-wrapper"),null!==l&&imagesLoaded(l,()=>{const e="article.layout-"+o;window.nvMasonry=new Masonry(l,{itemSelector:e,columnWidth:e,percentPosition:!0})}))},m=()=>{"enabled"===NeveProperties.infScroll&&null!==e(".nv-index-posts .posts-wrapper")&&((e,t,n=.5)=>{if(!e)return;new IntersectionObserver(o=>{if(o[0].intersectionRatio<=n)return;t();const i=setInterval(()=>{const n=e.getBoundingClientRect(),{top:o,left:r,right:s,bottom:a}=n,{innerWidth:c,innerHeight:d}=window;o>=0&&r>=0&&s<=c&&a<=d?t():clearInterval(i)},750)}).observe(e)})(e(".infinite-scroll-trigger"),()=>{if(parent&&parent.wp&&parent.wp.customize)return parent.wp.customize.requestChangesetUpdate().then(()=>{v()}),!1;v()})},v=()=>{const t=window.NeveProperties,n=e(".infinite-scroll-trigger");if(null===n)return;const o=e(".nv-loader");if(o.style.display="block",p>t.maxPages)return n.remove(),void(o.style.display="none");const i=e(".nv-index-posts .posts-wrapper"),r=t.lang,s=t.endpoint+p,a=h(r?s+"/"+r:s);p++;const c=document.createElement("div");i.appendChild(c),((e,t,n)=>{const o=new XMLHttpRequest;o.onload=()=>{200===o.status&&t(o.response)},o.onerror=()=>{},o.open("POST",e,!0),o.setRequestHeader("Content-Type","application/json; charset=UTF-8"),o.send(n)})(a,e=>{if(c.outerHTML=JSON.parse(e),"enabled"!==t.masonryStatus)return!1;window.nvMasonry.reloadItems(),window.nvMasonry.layout()},t.query)},h=e=>"undefined"==typeof wp||void 0===wp.customize?e:(e+="?customize_changeset_uuid="+wp.customize.settings.changeset.uuid+"&customize_autosaved=on","undefined"==typeof _wpCustomizeSettings?e:e+="&customize_preview_nonce="+_wpCustomizeSettings.nonce.preview),g=["dropdown-open","active","nav-clickaway-overlay"],w=()=>window.matchMedia("(max-width: 959px)").matches,y=()=>{b(),o(document,"click",e=>{e.target.hash&&e.target.hash.includes("#")&&window.HFG.toggleMenuSidebar(!1)}),k(),N(),z(),function(){const n=t(".responsive-nav-cart.dropdown");if(0===n.length)return;n.forEach(t=>{const n=e(".cart-icon-wrapper",t);null!==n&&o(n,"click",e=>{w()&&!i(t,"cart-is-empty")&&(r(e),t.classList.toggle("cart-dropdown-open"))})}),o(document,"click",e=>{w()&&n.forEach(t=>{i(t,"cart-dropdown-open")&&!t.contains(e.target)&&d(t,"cart-dropdown-open")})})}(),window.HFG.initSearch=()=>{N(),k()}},b=()=>{const e=t(".sub-menu, .minimal .nv-nav-search");if(!e.length)return;const n=window.innerWidth,o=e=>e.left<0?e.left:e.right>n?e.right-n:0;e.forEach(e=>{const t=e.style;t.right=t.left=t.transform="";let n=o(s(e));if(!n)return;const i=e.matches(".sub-menu .sub-menu")?"100%":"0px";t.right=n<0?"auto":i,t.left=n<0?i:"auto",n=o(s(e)),n&&(t.transform="translateX("+(n<0?20-n:-n-20)+"px)")}),"undefined"!=typeof menuCalcEvent&&window.dispatchEvent(menuCalcEvent)};function k(){const n=document.body;t(".caret-wrap:not([data-nv-bound])").forEach(e=>{e.dataset.nvBound="1",o(e,"click",n=>function(e,n){r(e),e.stopPropagation();const o=!i(n,g[0]);C(n,o),o&&F(t("."+g[0]),g[0])}(n,e))}),n.dataset.nvCaretKeys||(n.dataset.nvCaretKeys="1",o(document,"keydown",t=>{if("Escape"!==t.key)return;const i=e(".menu-item-has-children:hover");i&&(c(n,"nv-hover-off"),o(i,"mouseleave",()=>d(n,"nv-hover-off"),{once:!0}))}),o(document,"keydown",e=>{if("Escape"!==e.key||0===E().length)return;const t=E().find(t=>t.closest("li").contains(e.target));t&&(r(e),e.stopImmediatePropagation(),C(t,!1),t.focus())}),o(document,"focusout",e=>{0!==E().length&&E().forEach(t=>{i(t,"navbar-toggle")||t.closest("li").contains(e.relatedTarget)||C(t,!1)})}))}function E(){return[...t(".caret-wrap."+g[0])]}function C(t,n){if(i(t,g[0])===n)return;const o=e(".sub-menu",t.parentNode.parentNode),r=n?c:d;r(t,g[0]),null!==o&&r(o,g[0]),t.setAttribute("aria-expanded",String(n)),n||0!==E().length||S()}function S(){const t=e("."+g[2]);null!==t&&t.remove()}const x=e=>e===document||"none"!==getComputedStyle(e).display&&x(e.parentNode);let L={};function M(e){const o=(i=L.container,[...t('a[href],button,input,textarea,select,details,[tabindex]:not
1([tabindex="-1"])',i)].filter(e=>!e.hasAttribute("disabled")&&!e.getAttribute("aria-hidden")&&x(e)));var i;const s=9===e.keyCode,a=e.shiftKey,c=27===e.keyCode,d=document.activeElement,u=o[o.length-1],l=o[0];c&&(r(e),L.backFocus.focus(),"function"==typeof L.onClose?L.onClose():window.HFG.toggleMenuSidebar(!1),n("ftrap-end")),!a&&s&&u===d&&(r(e),l.focus()),a&&s&&l===d&&(r(e),u.focus()),s&&l===u&&r(e)}function N(){const o=t(".nv-nav-search"),s=t(".menu-item-nav-search"),c=t(".close-responsive-search");P();const l=()=>{d(s,g[1]),P(),S(),n("ftrap-end")};a(s,"click",(t,o)=>{if(r(t),t.stopPropagation(),u(o,g[1],"toggle"),P(),!i(o,g[1]))return S(),void n("ftrap-end");F(o,g[1]),n("ftrap-run",{container:e(".nv-nav-search",o),close:".close-responsive-search",firstFocus:".search-field",backFocus:e(".nv-search,.nv-nav-search-icon",o)||o,onClose:l})}),a(o,"click",e=>{e.stopPropagation()}),a(c,"click",t=>{r(t);const n=t.target.closest(".menu-item-nav-search");l();const o=n&&e(".nv-search,.nv-nav-search-icon",n);o&&o.focus()})}function P(){t(".menu-item-nav-search").forEach(t=>{const n=e(".nv-search,.nv-nav-search-icon",t);n&&n.setAttribute("aria-expanded",String(i(t,g[1])))})}function z(){const n=t(".header--row .menu-item-nav-cart");if(0===n.length)return;const o=w();n.forEach(t=>{const n=e(".nv-nav-cart:not(.cart-off-canvas)",t);if(null===n)return;const i=n.style;if(i.left="",i.right="",o){const e=Math.min(360,window.innerWidth-32),n=s(t).left;return i.width=e+"px",i.maxWidth="calc(100vw - 32px)",i.left=(window.innerWidth-e)/2-n+"px",void(i.right="auto")}i.width="",i.maxWidth="",i.left=s(t).left<350?0:""})}function F(t,i){let r=e("."+g[2]);null!==r&&r.remove(),r=document.createElement("div"),c(r,g[2]);const s=e("header.header");s.parentNode.insertBefore(r,s),o(r,"click",()=>{E().forEach(e=>C(e,!1)),d(t,i),P(),S(),n("ftrap-end")})}o(document,"ftrap-run",t=>{L=t.detail,setTimeout(t=>{e(t.firstFocus,t.container).focus()},100,L),o(document,"keydown",M)}),o(document,"ftrap-end",()=>{L={},document.removeEventListener("keydown",M)}),o(window,"resize",z);const T=".close-sidebar-panel .navbar-toggle",H=["is-menu-sidebar","hiding-header-menu-sidebar","is-active"],A=function(){this.init()},W=(e,t=!0)=>e.forEach(e=>t?e.setAttribute("aria-hidden","true"):e.removeAttribute("aria-hidden"));function _(){b()}let q;A.prototype.init=function(n=!1){if(!1===n){const e=t(T);a(e,"click",()=>{this.toggleMenuSidebar(!1)})}const o=t(".menu-mobile-toggle");a(o,"click",e=>{this.toggleMenuSidebar(!e.target.parentElement.classList.contains("is-active"),e.target)});const i=e(".header-menu-sidebar-overlay");i&&a(i,"click",()=>this.toggleMenuSidebar(!1))},A.prototype.toggleMenuSidebar=function(o,i=null){const r=document.body,s=t(".menu-mobile-toggle");d(r,H[1]);const a=t("#header-menu-sidebar, .hfg-ov"),u=t(".neve-skip-link, #content, .scroll-to-top, #site-footer, .header--row");if(("undefined"==typeof NeveProperties||!NeveProperties.isCustomize)&&r.classList.contains(H[0])||!1===o){const t=e(".nav-clickaway-overlay");null!==t&&t.remove(),c(r,H[1]),d(r,H[0]),d(s,H[2]),setTimeout((function(){d(r,H[1])}),1e3),W(u,!1),W(a),n("ftrap-end")}else c(r,H[0]),c(s,H[2]),i&&n("ftrap-run",{container:document.getElementById("header-menu-sidebar"),close:T,firstFocus:T+",.menu-item a",backFocus:i}),W(a,!1),W(u)},o(window,"load",(function(){window.HFG=new A,(()=>{if(null===e(".blog.nv-index-posts")||"undefined"==typeof NeveProperties)return!1;f(),m()})(),y()})),o(window,"resize",()=>{clearTimeout(q),q=setTimeout(_,500)})}();

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.