Skip to content

Commit

Permalink
Don't show banner on stable
Browse files Browse the repository at this point in the history
  • Loading branch information
jackgerrits committed Jan 9, 2025
1 parent 6abc700 commit 30f17d2
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 2 deletions.
11 changes: 11 additions & 0 deletions python/packages/autogen-core/docs/src/_static/banner-override.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
var version = DOCUMENTATION_OPTIONS.VERSION;
if (version === "stable") {
var styles = `
s#bd-header-version-warning {
display: none;
}
`
var styleSheet = document.createElement("style")
styleSheet.textContent = styles
document.head.appendChild(styleSheet)
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
<script src="_static/banner-override.js"></script>
4 changes: 2 additions & 2 deletions python/packages/autogen-core/docs/src/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@

"footer_start": ["copyright"],
"footer_center": ["footer-middle-links"],
"footer_end": ["theme-version"],
"footer_end": ["theme-version", "version-banner-override"],
"pygments_light_style": "xcode",
"pygments_dark_style": "monokai",
"navbar_start": ["navbar-logo", "version-switcher"],
Expand All @@ -135,7 +135,7 @@
]
}

html_js_files = ["custom-icon.js"]
html_js_files = ["custom-icon.js", "banner-override.js"]
html_sidebars = {
"packages/index": [],
"user-guide/core-user-guide/**": ["sidebar-nav-bs-core"],
Expand Down

0 comments on commit 30f17d2

Please sign in to comment.