diff options
Diffstat (limited to 'profile/public/user.js')
-rw-r--r-- | profile/public/user.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/profile/public/user.js b/profile/public/user.js index 84c4858..12f2fd6 100644 --- a/profile/public/user.js +++ b/profile/public/user.js @@ -8,7 +8,12 @@ if (uid < 1 || uid > 119) window.location.assign("./users.html"); // Well async function addUser(userData) { const resp = await (await fetch("/auth/api/status")).json(); if (!resp.admin) { - userDiv.style.display = "none"; + const { user } = userData; + const h1 = document.createElement("h1"); + h1.textContent = `${user.name} ${user.middlename || ""} ${user.surname}`; + h1.classList.add("hidden-chevron"); + userDiv.append(h1); + document.querySelector("title").textContent = h1.textContent; return; } const divs = []; |