feat(achievements): implement unlocking, saving and notification

This commit is contained in:
2026-01-18 22:50:35 +01:00
parent ca9d0a2b55
commit 41eea74cc0
13 changed files with 269 additions and 2 deletions

View File

@@ -6,6 +6,7 @@ import Buttons from "./Buttons.vue";
import ButtonSelector from "~/components/Common/ButtonSelector.vue";
const store = useContactStore();
const achievements = useAchievementsStore();
const confirmationModal = useConfirmationModal();
const ACTIONS = {
@@ -65,6 +66,12 @@ const actionateButton = async (button: (typeof selected)["value"]) => {
store.pushNotification(`${verb} opened`);
await sleep(100);
await navigateTo(content, { open: { target: "_blank " } });
await sleep(500);
if (button === "github") {
achievements.unlock("contact_git_visit");
}
},
});
}