1/** 2 * Callback Functions 3 */ 4 5async function loadPageContent (element, pageId) { 6 const mainTabElement = getMainTabElement(element); 7 const mainTabOutput = mainTabElement.querySelector('#tabs-output'); 8 9 addLoading(mainTabOutput); 10 11 // This function (fetchPageContent) is being loaded by WP Core. 12 // It is located inside ./child-ajax-functions.js (/icelander-child/assets/js/child-ajax-functions.js) 13 const pageContent = await fetchPageContent(pageId); 14 15 updateInnerHTML(mainTabOutput, pageContent); 16} 17 18function loadTabContent (element, target, finalUrl) { 19 const targetOutput = document.querySelector('.tabs-output .tab-content-item#' + target); 20 const everyTabOutput = document.querySelectorAll('.tabs-output .tab-content-item'); 21 22 if (targetOutput && everyTabOutput) { 23 toggleTabs(targetOutput, everyTabOutput); 24 } 25 26 injectURL('tabs-component', finalUrl); 27} 28 29async function loadCollectionHighlights (page, perPage) { 30 const collectionHighlightsContainer = document.querySelector('#load-collection-highlights'); 31 32 if (collectionHighlightsContainer) { 33 addLoading(collectionHighlightsContainer); 34 35 if (collectionHighlightsContainer.getAttribute('data-loaded-page')) { 36 page = collectionHighlightsContainer.getAttribute('data-loaded-page'); 37 38 collectionHighlightsContainer.removeAttribute('data-loaded-page'); 39 } 40 41 const collectionHighlightId = collectionHighlightsContainer.getAttribute('data-collection-highlight-id'); 42 const collectionHighlightsContent = await fetchCollectionHighlightsContent(collectionHighlightId, page, perPage); 43 44 updateInnerHTML(collectionHighlightsContainer, collectionHighlightsContent); 45 } 46}
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.