This is an automated email from the ASF dual-hosted git repository. wave pushed a commit to branch fixup-styles-post in repository https://gitbox.apache.org/repos/asf/tooling-docs.git
commit 1ab98bf97674662c44492c99371328640054b4a9 Author: Dave Fisher <[email protected]> AuthorDate: Sat Nov 29 20:48:12 2025 -0800 html validation fixup --- content/theme/templates/footer.html | 1 - content/theme/templates/page.html | 28 +----------------------- content/theme/templates/{page.html => post.html} | 22 +------------------ content/theme/templates/styles.html | 6 ++--- 4 files changed, 5 insertions(+), 52 deletions(-) diff --git a/content/theme/templates/footer.html b/content/theme/templates/footer.html index f09d384..aba8504 100644 --- a/content/theme/templates/footer.html +++ b/content/theme/templates/footer.html @@ -7,4 +7,3 @@ </p> </div> </div> - <script type="application/ecmascript" src="/js/bootstrap.bundle.min.js" integrity="sha384-TYMA+uAx4f43rilxPIhmlqA+Vi+xbyMe+YVR3BcL15NyHLqd+7WYNtyBPdayiOPx"></script> diff --git a/content/theme/templates/page.html b/content/theme/templates/page.html index 3eff0ee..d6f1fd3 100644 --- a/content/theme/templates/page.html +++ b/content/theme/templates/page.html @@ -16,33 +16,7 @@ {% include "footer.html" %} </div> </main> - <script> - document.addEventListener("DOMContentLoaded", () => { - function decodeHtmlEntities(str) { - const txt = document.createElement("textarea"); - txt.innerHTML = str; - return txt.value; - } - document.querySelectorAll("pre > code.language-mermaid").forEach((code, i) => { - let decoded = decodeHtmlEntities(code.innerHTML); - // Normalize whitespace - decoded = decoded.replace(/\t/g, " "); - decoded = decoded.replace(/^\s*\n/, "").replace(/\n\s*$/, ""); - const div = document.createElement("div"); - div.className = "mermaid"; - div.textContent = decoded; - code.parentElement.replaceWith(div); - console.log(`=== Mermaid block ${i} ===`); - console.log(decoded); - }); - // Mermaid v10+ runs asynchronously - mermaid.run({ querySelector: ".mermaid" }) - .catch(err => { - console.error("Mermaid rendering failed:", err); - }); - }); - </script> - <script>hljs.highlightAll();</script> + {% include "post.html" $} </body> </html> {% endblock %} diff --git a/content/theme/templates/page.html b/content/theme/templates/post.html similarity index 63% copy from content/theme/templates/page.html copy to content/theme/templates/post.html index 3eff0ee..dc1351d 100644 --- a/content/theme/templates/page.html +++ b/content/theme/templates/post.html @@ -1,21 +1,4 @@ -{% block head %} -<!doctype html> -<html class="no-js" lang="en" dir="ltr"> - <head> - <meta charset="utf-8"> - <meta http-equiv="x-ua-compatible" content="ie=edge"> - <meta name="viewport" content="width=device-width, initial-scale=1.0"> - <title>{{ page.title }} - {{SITENAME}}</title> - {% include "styles.html" %} - </head> - <body class="d-flex flex-column h-100"> - <main class="flex-shrink-0"> - <div> - {% include "menu.html" %} - {% include "generic.html" %} - {% include "footer.html" %} - </div> - </main> + <script src="/js/bootstrap.bundle.min.js" integrity="sha384-TYMA+uAx4f43rilxPIhmlqA+Vi+xbyMe+YVR3BcL15NyHLqd+7WYNtyBPdayiOPx"></script> <script> document.addEventListener("DOMContentLoaded", () => { function decodeHtmlEntities(str) { @@ -43,6 +26,3 @@ }); </script> <script>hljs.highlightAll();</script> - </body> -</html> -{% endblock %} diff --git a/content/theme/templates/styles.html b/content/theme/templates/styles.html index bb23919..8a694a6 100644 --- a/content/theme/templates/styles.html +++ b/content/theme/templates/styles.html @@ -7,7 +7,7 @@ <script src="/js/mermaid.min.js"></script> <!-- pagefind search --> <link href="/_pagefind/pagefind-ui.css" rel="stylesheet"> -<script src="/_pagefind/pagefind-ui.js" type="text/javascript"></script> +<script src="/_pagefind/pagefind-ui.js"></script> <script> window.addEventListener('DOMContentLoaded', (event) => { new PagefindUI({ element: "#pagefind-search" }); @@ -26,7 +26,7 @@ }); </script> <!-- pagefind search box styling --> -<style type="text/css"> +<style> .search-form { right: 0; left: initial !important; @@ -41,6 +41,6 @@ padding: 1em; background: #fff; border: 1px solid #d0d7de; - broder-radius: 6px; + border-radius: 6px; } </style> --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
