Questify: Fixes. (#904)

This commit is contained in:
Etorix 2026-03-11 13:18:21 -07:00 • committed by GitHub
parent b442f4e675
commit 8efccc960e
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 11 additions and 3 deletions

View file

@ -1388,8 +1388,8 @@ export default definePlugin({
},
{
// Prevent SearchableSelect from force-scrolling into view, causing the dropdown to close.
match: /(?<=\.scrollIntoView\()/,
replace: "{block:\"nearest\",inline:\"nearest\"}"
match: /(&&\i.current\?\.scrollIntoView\(\))/,
replace: ""
},
{
// Passes a popoutClassName and optionClassName to the popout handler.
@ -1419,6 +1419,14 @@ export default definePlugin({
}
]
},
{
// Prevent the new version of SearchableSelect from force-scrolling into view.
find: '"data-mana-component":"combobox",',
replacement: {
match: /\i.current\?\.scrollIntoView\({.{0,50}?}\)/,
replace: ""
}
},
{
// Formats the Orbs balance on the Quests page with locale string formatting.
find: '("BalanceCounter")',

View file

@ -77,7 +77,7 @@ export function getQuestProgress(quest: Quest, task: QuestTask) {
export function getQuestTarget(task: QuestTask) {
const isWatch = task.type === QuestTaskType.WATCH_VIDEO || task.type === QuestTaskType.WATCH_VIDEO_ON_MOBILE;
const raw = task.target;
const adjusted = raw - (isWatch ? videoQuestLeeway : 0);
const adjusted = Math.max(0, raw - (isWatch ? videoQuestLeeway : 0));
return { raw, adjusted };
}