add option for users to opt out
All checks were successful
Code quality checks / biome (push) Successful in 7s

This commit is contained in:
creations 2025-05-07 15:21:39 -04:00
parent ba67ba55e3
commit 5ad5d7181f
Signed by: creations
GPG key ID: 8F553AA4320FC711
2 changed files with 14 additions and 0 deletions

View file

@ -382,6 +382,19 @@ async function updatePresence(initialData) {
const kv = data.kv || {};
if (kv.optout === "true") {
const loadingOverlay = document.getElementById("loading-overlay");
if (loadingOverlay) {
loadingOverlay.innerHTML = `
<div class="error-message">
<p>This user has opted out of sharing their presence.</p>
</div>
`;
loadingOverlay.style.opacity = "1";
}
return;
}
const cssLink = kv.css;
if (cssLink) {
try {