feat(contact): notifications system + action
This commit is contained in:
@@ -14,6 +14,9 @@ export const useContactStore = defineStore("contact", {
|
||||
},
|
||||
|
||||
isIntro: true,
|
||||
|
||||
notifications: [] as string[],
|
||||
notificationsYOffset: 0,
|
||||
}),
|
||||
|
||||
actions: {
|
||||
@@ -70,5 +73,15 @@ export const useContactStore = defineStore("contact", {
|
||||
},
|
||||
);
|
||||
},
|
||||
|
||||
pushNotification(content: string) {
|
||||
this.notifications.push(content);
|
||||
|
||||
gsap.fromTo(
|
||||
this,
|
||||
{ notificationsYOffset: 20 },
|
||||
{ notificationsYOffset: 0, duration: 0.075 },
|
||||
);
|
||||
},
|
||||
},
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user