feat(home): add 'to' parameter to outro
This commit is contained in:
@@ -8,13 +8,13 @@
|
||||
import GameButton from "./GameButton.vue";
|
||||
import PictochatButton from "./PictochatButton.vue";
|
||||
import DownloadPlayButton from "./DownloadPlayButton.vue";
|
||||
import Selector from "./Selector.vue";
|
||||
import Selector from "~/components/Common/ButtonSelector.vue";
|
||||
|
||||
const store = useHomeStore();
|
||||
|
||||
const BUTTONS_CONFIG = {
|
||||
game: [31, 23, 193, 49],
|
||||
pictochat: [31, 71, 97, 49],
|
||||
contact: [31, 71, 97, 49],
|
||||
downloadPlay: [127, 71, 97, 49],
|
||||
} as const satisfies Record<string, ButtonConfig>;
|
||||
|
||||
@@ -23,23 +23,23 @@ type ButtonType = keyof typeof BUTTONS_CONFIG;
|
||||
const { selectedButton, selectorPosition } = useButtonNavigation({
|
||||
buttons: BUTTONS_CONFIG,
|
||||
initialButton: "game",
|
||||
onButtonClick: () => {
|
||||
store.animateOutro();
|
||||
onButtonClick: (button) => {
|
||||
store.animateOutro(`/${button}`);
|
||||
},
|
||||
navigation: {
|
||||
game: {
|
||||
down: "last",
|
||||
left: "pictochat",
|
||||
left: "contact",
|
||||
right: "downloadPlay",
|
||||
horizontalMode: "preview",
|
||||
},
|
||||
pictochat: {
|
||||
contact: {
|
||||
up: "game",
|
||||
right: "downloadPlay",
|
||||
},
|
||||
downloadPlay: {
|
||||
up: "game",
|
||||
left: "pictochat",
|
||||
left: "contact",
|
||||
},
|
||||
},
|
||||
});
|
||||
@@ -69,8 +69,8 @@ const getOpacity = (button?: ButtonType) => {
|
||||
/>
|
||||
<PictochatButton
|
||||
:x="32"
|
||||
:y="72 + getButtonOffset('pictochat')"
|
||||
:opacity="getOpacity('pictochat')"
|
||||
:y="72 + getButtonOffset('contact')"
|
||||
:opacity="getOpacity('contact')"
|
||||
/>
|
||||
|
||||
<Selector
|
||||
|
||||
Reference in New Issue
Block a user