]> git.localhorst.tv Git - alttp.git/commitdiff
fix manual heart pieces
authorDaniel Karbach <daniel.karbach@localhorst.tv>
Tue, 26 Mar 2024 13:04:00 +0000 (14:04 +0100)
committerDaniel Karbach <daniel.karbach@localhorst.tv>
Tue, 26 Mar 2024 13:04:09 +0000 (14:04 +0100)
resources/js/components/tracker/ToggleIcon.js

index da1a18139e8f90bac57e1edb502b0f57e029caff..3966506d2b2b815868b5553bbdce64287af992ff 100644 (file)
@@ -205,10 +205,10 @@ ToggleIcon.modulusController = ctrl => ({
        getActive: (state, icons) => icons[(state[ctrl] || 0) % icons.length],
        getDefault: firstIcon,
        handlePrimary: (state, setState, icons) => {
-               setState(increment(icons[0], icons.length));
+               setState(increment(ctrl, icons.length));
        },
        handleSecondary: (state, setState, icons) => {
-               setState(decrement(icons[0], icons.length));
+               setState(decrement(ctrl, icons.length));
        },
 });