mirror of
https://github.com/MrUnknownDE/VRCX.git
synced 2026-04-26 10:13:48 +02:00
fix: Inconsistent behavior when cycling through nav menu folders (#1498)
This commit is contained in:
@@ -204,7 +204,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { computed, defineAsyncComponent, onMounted, onUnmounted, ref, watch } from 'vue';
|
import { computed, defineAsyncComponent, onMounted, ref, watch } from 'vue';
|
||||||
import { ElMessageBox, dayjs } from 'element-plus';
|
import { ElMessageBox, dayjs } from 'element-plus';
|
||||||
import { storeToRefs } from 'pinia';
|
import { storeToRefs } from 'pinia';
|
||||||
import { useI18n } from 'vue-i18n';
|
import { useI18n } from 'vue-i18n';
|
||||||
@@ -650,6 +650,10 @@
|
|||||||
if (!entry) {
|
if (!entry) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
const entries = navMenuItems.value.find((item) => item.index === index)?.entries || [];
|
||||||
|
const indexOfEntry = entries.findIndex((e) => e.label === entry.label);
|
||||||
|
folderCyclePointers.set(index, (indexOfEntry + 1) % entries.length);
|
||||||
|
|
||||||
if (entry.routeName) {
|
if (entry.routeName) {
|
||||||
handleRouteChange(entry.routeName, index || entry.routeName);
|
handleRouteChange(entry.routeName, index || entry.routeName);
|
||||||
} else if (entry.path) {
|
} else if (entry.path) {
|
||||||
|
|||||||
Reference in New Issue
Block a user