feat(home): navigation and outro animation to settings
This commit is contained in:
@@ -9,8 +9,9 @@ export const useHomeStore = defineStore("home", {
|
||||
|
||||
outro: {
|
||||
buttonOffsetY: 0,
|
||||
stage1Opacity: 0,
|
||||
stage2Opacity: 0,
|
||||
stage1Opacity: 1,
|
||||
stage2Opacity: 1,
|
||||
animateTop: false,
|
||||
},
|
||||
|
||||
isIntro: true,
|
||||
@@ -54,8 +55,9 @@ export const useHomeStore = defineStore("home", {
|
||||
);
|
||||
},
|
||||
|
||||
animateOutro(to?: string) {
|
||||
animateOutro(to: "contact" | "projects" | "settings") {
|
||||
this.isOutro = true;
|
||||
this.outro.animateTop = to !== "settings";
|
||||
|
||||
const duration = 0.4;
|
||||
const delay = 0.08;
|
||||
@@ -74,7 +76,7 @@ export const useHomeStore = defineStore("home", {
|
||||
ease: "none",
|
||||
onComplete: () => {
|
||||
this.isOutro = true;
|
||||
if (to) navigateTo(to);
|
||||
navigateTo(`/${to}`);
|
||||
},
|
||||
},
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user