From 290f577e58dc0f4688c9ad1345a67205829e7161 Mon Sep 17 00:00:00 2001 From: Madhurima Rawat <105432776+madhurimarawat@users.noreply.github.com> Date: Mon, 22 Jul 2024 20:59:53 +0530 Subject: [PATCH] Update index.js Updated code to center content --- docs/js/index.js | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/docs/js/index.js b/docs/js/index.js index 9974bc5..d39daa7 100644 --- a/docs/js/index.js +++ b/docs/js/index.js @@ -26,7 +26,16 @@ // Run when DOM content is fully loaded document.addEventListener("DOMContentLoaded", function () { // Center align contentRow element using Flexbox - var contentRow = document.getElementById("contentRow"); + var contentRow = document.getElementById("contentRow_1"); + if (contentRow) { + contentRow.classList.add("d-flex", "justify-content-center"); + } +}); + +// Run when DOM content is fully loaded +document.addEventListener("DOMContentLoaded", function () { + // Center align contentRow element using Flexbox + var contentRow = document.getElementById("contentRow_2"); if (contentRow) { contentRow.classList.add("d-flex", "justify-content-center"); } @@ -92,4 +101,3 @@ $(document).ready(function () { $(".navbar-collapse").collapse('hide'); }); }); -