diff --git a/layout/includes/page/shuoshuo.pug b/layout/includes/page/shuoshuo.pug index 745b048..5846792 100644 --- a/layout/includes/page/shuoshuo.pug +++ b/layout/includes/page/shuoshuo.pug @@ -41,9 +41,12 @@ ${item.content} ` @@ -98,6 +101,7 @@ .shuoshuo-content !=markdown(i.content) .shuoshuo-footer - .shuoshuo-tags - each tag in i.tags - span.shuoshuo-tag=tag \ No newline at end of file + if i.tags + .shuoshuo-tags + each tag in i.tags + span.shuoshuo-tag=tag \ No newline at end of file diff --git a/plugins.yml b/plugins.yml index 78bfda9..caf60e9 100644 --- a/plugins.yml +++ b/plugins.yml @@ -8,8 +8,8 @@ activate_power_mode: version: 1.1.4 algolia_search: name: algoliasearch - file: dist/algoliasearch-lite.umd.js - version: 5.7.0 + file: dist/lite/builds/browser.umd.js + version: 5.8.1 aplayer_css: name: aplayer file: dist/APlayer.min.css @@ -111,7 +111,7 @@ instantpage: instantsearch: name: instantsearch.js file: dist/instantsearch.production.min.js - version: 4.74.2 + version: 4.75.0 katex: name: katex file: dist/katex.min.css @@ -137,7 +137,7 @@ medium_zoom: mermaid: name: mermaid file: dist/mermaid.min.js - version: 11.2.1 + version: 11.3.0 meting_js: name: butterfly-extsrc file: metingjs/dist/Meting.min.js diff --git a/source/css/_search/algolia.styl b/source/css/_search/algolia.styl index 87f36c4..1f7f525 100644 --- a/source/css/_search/algolia.styl +++ b/source/css/_search/algolia.styl @@ -59,6 +59,7 @@ height: 24px text-align: center line-height: 24px + addBorderRadius() .ais-Pagination-item--selected a diff --git a/source/js/search/algolia.js b/source/js/search/algolia.js index 814a00c..8624f52 100644 --- a/source/js/search/algolia.js +++ b/source/js/search/algolia.js @@ -85,9 +85,10 @@ window.addEventListener('load', () => { document.querySelector('#algolia-info .algolia-stats') ] + const searchClient = typeof algoliasearch === 'function' ? algoliasearch : window['algoliasearch/lite'].liteClient const search = instantsearch({ indexName, - searchClient: algoliasearch(appId, apiKey), + searchClient: searchClient(appId, apiKey), searchFunction (helper) { disableDiv.forEach(item => { item.style.display = helper.state.query ? '' : 'none'