Deployed c2c736e with MkDocs version: 1.6.0

This commit is contained in:
Mouse
2024-07-17 21:58:59 +08:00
parent 306a444cc6
commit 7148576e77
75 changed files with 5703 additions and 6715 deletions

View File

@@ -21,8 +21,15 @@ function joinUrl (base, path) {
return base + "/" + path;
}
function escapeHtml (value) {
return value.replace(/&/g, '&')
.replace(/"/g, '"')
.replace(/</g, '&lt;')
.replace(/>/g, '&gt;');
}
function formatResult (location, title, summary) {
return '<article><h3><a href="' + joinUrl(base_url, location) + '">'+ title + '</a></h3><p>' + summary +'</p></article>';
return '<article><h3><a href="' + joinUrl(base_url, location) + '">'+ escapeHtml(title) + '</a></h3><p>' + escapeHtml(summary) +'</p></article>';
}
function displayResults (results) {