Skip to content

Commit a5a05d8

Browse files
Brijesh619farhan
andauthored
ATLAS-4998: Replaced Swagger Logo with Atlas Logo (#303)
Co-authored-by: farhan <farhan@Gagetzones-MacBook-Pro.local>
1 parent 6c235ce commit a5a05d8

File tree

1 file changed

+13
-1
lines changed
  • build-tools/src/main/resources/ui-dist

1 file changed

+13
-1
lines changed

build-tools/src/main/resources/ui-dist/index.js

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,19 @@
5151
window.ui = ui;
5252

5353
atlasLogo = gatewayUrl + "/img/atlas_logo.svg";
54-
$('#swagger-ui img').attr("src", atlasLogo);
54+
setTimeout(() => {
55+
const logoAnchor = document.querySelector(".swagger-ui .topbar a");
56+
57+
if (logoAnchor) {
58+
const svgLogo = logoAnchor.querySelector("svg");
59+
if (svgLogo) svgLogo.remove();
60+
const img = document.createElement("img");
61+
img.src = atlasLogo;
62+
img.alt = "Atlas Logo";
63+
img.style.height = "40px";
64+
logoAnchor.appendChild(img);
65+
}
66+
}, 500);
5567

5668
fetchCsrfHeader();
5769
}

0 commit comments

Comments
 (0)