feat(common): handleConfirm -> handleActivateA, handleCancel -> handleActivateB
This commit is contained in:
@@ -15,12 +15,12 @@ const handleActivateB = () => {
|
||||
bLabel: $t("common.no"),
|
||||
aLabel: $t("common.yes"),
|
||||
onClosed: async (choice) => {
|
||||
if (choice === "confirm") {
|
||||
if (choice === "A") {
|
||||
await animateOutro();
|
||||
store.closeSubMenu();
|
||||
}
|
||||
},
|
||||
keepButtonsDown: (choice) => choice === "confirm",
|
||||
keepButtonsDown: (choice) => choice === "A",
|
||||
});
|
||||
};
|
||||
|
||||
@@ -35,7 +35,7 @@ const handleActivateA = () => {
|
||||
bLabel: $t("common.no"),
|
||||
aLabel: $t("common.yes"),
|
||||
onClosed: (choice) => {
|
||||
if (choice === "confirm") {
|
||||
if (choice === "A") {
|
||||
resetBoard();
|
||||
}
|
||||
},
|
||||
@@ -116,9 +116,9 @@ let animating = false;
|
||||
const showRestartModal = () => {
|
||||
confirmationModal.open({
|
||||
text: $t("settings.options.2048.gameOver"),
|
||||
onConfirm: () => {},
|
||||
onActivateA: () => {},
|
||||
onClosed: (choice) => {
|
||||
if (choice === "confirm") {
|
||||
if (choice === "A") {
|
||||
resetBoard();
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user