PageSourceSearch

https://daienkai.com/2026/wp-content/plugins/vk-blocks-pro/build/vk-table-of-contents-new.min.js?ver=1.127.0

js daienkai.com collected 2026-10-06 13:18:01 UTC 4,299 bytes, 1 lines download raw bytes

1document.addEventListener("DOMContentLoaded",async()=>{let r=e=>"string"==typeof e&&/^[a-zA-Z0-9_-]+$/.test(e)?e:"",d=(e,t=[])=>{if(!e||"string"!=typeof e)return t;try{var n=JSON.parse(e);return Array.isArray(n)?n:t}catch(e){return t}},c=async()=>{try{var e=window.vkBlocksTocApi?.apiUrl||"/wp-json/vk-blocks/v1/toc_settings",t=await(await fetch(e,{credentials:"include"})).json();return t.success?t.data:null}catch(e){return null}},i=async()=>{let i=await c();i&&document.querySelectorAll(".wp-block-vk-blocks-table-of-contents-new").forEach(e=>{var t=e.querySelector(".vk_tableOfContents_list");if(t){let l;l="true"===e.dataset.useCustomLevels?d(e.dataset.customLevels||"[]",[]).map(e=>parseInt(e.replace("h","")))||[2,3,4,5,6]:i.allowedHeadingLevels||[2,3,4,5,6];let s=d(e.dataset.excludedHeadings||"[]",[]),o=!1!==i.includeBorderBox,n=e.dataset.numberingStyle||"";n=n||i.numberingStyle||"auto";t.querySelectorAll(".vk_tableOfContents_list_item").forEach(e=>{var t,n,a=e.className?e.className.match(/vk_tableOfContents_list_item-h-(\d+)/):null;a&&(a=parseInt(a[1]),n=e.querySelector("a"))&&(n=(n=n.getAttribute("href"))?n.replace("#",""):"",n=r(n),a=l.includes(a),t=s.includes(n),n=n.startsWith("vk-border-box-"),n=!o&&n,a&&!t&&!n||e.remove())});e=t.querySelectorAll(".vk_tableOfContents_list_item");let a=0;e.forEach(e=>{var t=e.className?e.className.match(/vk_tableOfContents_list_item-h-(\d+)/):null;t&&(t=parseInt(t[1]),e=e.querySelector(".vk_tableOfContents_list_item_link_preNumber"),"none"===n?e&&(e.style.display="none"):"h2-only"===n?2===t?(a++,e&&(e.style.display="",e.textContent=a+". ")):e&&(e.style.display="none"):e&&(e.style.display=""))})}})},u=(document.querySelectorAll(".wp-block-vk-blocks-table-of-contents-new").forEach(e=>{let m=e.querySelector(".vk_tableOfContents_openCloseBtn");if(m){let t="BUTTON"===m.tagName,c=t?null:m.previousElementSibling,u=m.closest(".tab").querySelector(".tab_content-open, .tab_content-close");e=u&&u.classList.contains("tab_content-open");let p=null,y=()=>{u&&(u.style.maxHeight="",u.style.paddingTop="",u.style.paddingBottom="")},g=()=>{p&&u&&(u.removeEventListener("transitionend",p),p=null)};e?(m.textContent="CLOSE",u&&(u.style.transition="none"),m.style.transition="none",c?c.checked=!0:t&&m.setAttribute("aria-expanded","true"),u&&(u.getBoundingClientRect(),u.style.transition=""),m.getBoundingClientRect(),m.style.transition=""):(m.textContent="OPEN",c?c.checked=!1:t&&m.setAttribute("aria-expanded","false")),m.addEventListener("click",function(a){let e=!(!c||"checkbox"!==c.type);if(e||t){a.preventDefault();let n=!(e?c.checked:"true"===m.getAttribute("aria-expanded"));a=()=>{e&&(c.checked=n),t&&m.setAttribute("aria-expanded",n?"true":"false"),m.textContent=n?"CLOSE":"OPEN",m.classList.toggle("button_status-open",n),m.classList.toggle("button_status-close",!n),u&&(u.classList.toggle("tab_content-open",n),u.classList.toggle("tab_content-close",!n))};if(!u||"function"==typeof window.matchMedia&&window.matchMedia("(prefers-reduced-motion: reduce)").matches)g(),y(),a();else{g();var l=window.getComputedStyle(u),s=u.getBoundingClientRect().height,o=l.paddingTop,i=l.paddingBottom,r=parseFloat(o)||0,d=parseFloat(i)||0,l="border-box"===l.boxSizing?Math.max(0,s):Math.max(0,s-r-d);let e=u.scrollHeight,t=(u.style.transition="none",u.style.maxHeight=l+"px",u.style.paddingTop=o,u.style.paddingBottom=i,a(),u.getBoundingClientRect(),e=>{e.target===u&&"max-height"===e.propertyName&&(u.removeEventListener("transitionend",t),p=null,y())});p=t,u.addEventListener("transitionend",t),window.requestAnimationFrame(()=>{u.style.transition="",n?(u.style.maxHeight=e+"px",u.style.paddingTop="1em",u.style.paddingBottom="1em"):(u.style.maxHeight="0px",u.style.paddingTop="0px",u.style.paddingBottom="0px")})}}})}}),document.querySelectorAll(".vk_tableOfContents_list li").forEach(e=>{e.innerHTML=e.innerHTML.replace(/\uFFFC/g,"")}),await i(),null),t=0,e=()=>{var e=Date.now();5e3<e-t&&(t=e,(async()=>{var e,t,n,a,l,s,o=await c();o&&u&&(e=JSON.stringify(o.allowedHeadingLevels),t=JSON.stringify(u.allowedHeadingLevels),n=o.includeBorderBox,a=u.includeBorderBox,l=o.numberingStyle,s=u.numberingStyle,e===t&&n===a&&l===s||i()),u=o})())};document.addEventListener("visibilitychange",()=>{document.hidden||e()}),window.addEventListener("focus",e)});

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.