Skip to content

Commit

Permalink
fix(js): fix renameVersionLinks.js
Browse files Browse the repository at this point in the history
  • Loading branch information
peterjunpark committed Nov 25, 2024
1 parent 3b17abd commit 1cd2f45
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/rocm_docs/rocm_docs_theme/static/renameVersionLinks.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
function renameVersionLinks() {
$('div.rst-other-versions dl:first-child a').each( function () {
$('readthedocs-flyout.versions dd>a').each( function () {
const text = $(this).text();
const versionRegEx = /^.*((?:[0-9]+\.){2}[0-9]+).*$/g;
if (versionRegEx.test(text)) {
Expand All @@ -23,5 +23,5 @@ function waitForSelector(selector, callback, backoff=100, max=15) {
}

$(document).ready(() => {
waitForSelector('div.rst-versions', renameVersionLinks);
waitForSelector('readthedocs-flyout.versions', renameVersionLinks);
})

0 comments on commit 1cd2f45

Please sign in to comment.