profile menu

This commit is contained in:
metacryst
2025-10-01 22:49:25 -05:00
parent a01fb24a69
commit 989dbd88a0
27 changed files with 244 additions and 845 deletions

View File

@@ -4,23 +4,14 @@
<title>Hyperia</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" href="_/icons/logo.svg">
<link rel="stylesheet" href="index.css">
<link rel="stylesheet" href="_/code/shared.css">
<script src="_/code/util.js"></script>
<script type="module">
import ProfileButton from "./components/ProfileButton.js"
</script>
</head>
<body>
<span id="title" class="link" onclick='window.location.href="/"'>hyperia
</span>
<img class="main-image">
<div class="links" style="z-index: 1; cursor: default; position: fixed; top: 5.5vh; right: 4.5vw">
<a href="#" onclick="logout(); return false;">sign out</a>
<script>
function logout() {
fetch('/signout', { method: 'GET', credentials: 'include' })
.then(() => {
// Force a clean full-page reload of "/"
window.location.replace('/?loggedout');
});
}
</script>
</div>
<span id="title" class="link" onclick='window.location.href="/"'>hyperia</span>
<profile-button style="z-index: 1; cursor: default; position: fixed; top: 5.5vh; right: 4.5vw"></profile-button>
</body>
</html>