diff --git a/CHANGELOG.md b/CHANGELOG.md index 4099463..8aed606 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,10 @@ +## [1.7.1-dev.1](https://github.com/revenge-mod/revenge-bundle/compare/v1.7.0...v1.7.1-dev.1) (2025-02-14) + + +### Bug Fixes + +* **settings:** update tab index lookup approach ([93c17e8](https://github.com/revenge-mod/revenge-bundle/commit/93c17e8e0c8597104d147d94da71078d6e368135)) + # [1.7.0](https://github.com/revenge-mod/revenge-bundle/compare/v1.6.0...v1.7.0) (2025-02-02) diff --git a/src/lib/ui/settings/patches/tabs.tsx b/src/lib/ui/settings/patches/tabs.tsx index 46150f4..5811ed2 100644 --- a/src/lib/ui/settings/patches/tabs.tsx +++ b/src/lib/ui/settings/patches/tabs.tsx @@ -1,6 +1,5 @@ import { after } from "@lib/api/patcher"; import { findInReactTree } from "@lib/utils"; -import { i18n } from "@metro/common"; import { TableRow } from "@metro/common/components"; import { findByNameLazy, findByPropsLazy } from "@metro/wrappers"; import { registeredSections } from "@ui/settings"; @@ -77,8 +76,8 @@ export function patchTabsUI(unpatches: (() => void | boolean)[]) { if (useIsFirstRender()) return; // :shrug: const { sections } = findInReactTree(ret, i => i.props?.sections).props; - // TODO: Use new i18n lib - let index = -~sections.findIndex((i: any) => i.label === i18n.Messages.ACCOUNT_SETTINGS) || 1; + // Credit to @palmdevs - https://discord.com/channels/1196075698301968455/1243605828783571024/1307940348378742816 + let index = -~sections.findIndex((i: any) => i.settings.includes("ACCOUNT")) || 1; Object.keys(registeredSections).forEach(sect => { sections.splice(index++, 0, {