Skip to content

Commit

Permalink
images position fixed
Browse files Browse the repository at this point in the history
position of images inside category is changed
  • Loading branch information
siddhant-2002 committed Jun 15, 2024
1 parent ec7ca27 commit 44a8345
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion js/categoryjs.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,15 @@ document.addEventListener("DOMContentLoaded", function () {

const icon = document.createElement("img");
icon.src = "img/" + categoryData.icon;
icon.style.display = "block";
icon.style.margin = "auto";

const nameLink = document.createElement("a");
nameLink.href = categoryData.name + "-/"; //find index.html
nameLink.textContent = categoryData.name;

const name = document.createElement("span");
name.appendChild(document.createElement("br"));
// name.appendChild(document.createElement("br"));
name.appendChild(nameLink);

categoryItem.appendChild(icon);
Expand Down

0 comments on commit 44a8345

Please sign in to comment.