ntent}
                    <\/div>
                <\/div>`;
            }
        });
        resultsHTML += '<\/div>';
        resultsDiv.innerHTML = resultsHTML;
        }

        function truncate(str, size) {
        //first, remove HTML
        str = str.replaceAll(/<[^>]*>/g, '');
        if (str.length < size) 
            return str;
        return str.substring(0, size - 3) + '...';
        }

        function offlineSearch(searchQuery) {
        let data = window.docs;

        let isTagSearch =