1
0
mirror of https://github.com/citizenfx/cfx-server-data.git synced 2025-02-09 06:33:29 +08:00

Merge pull request #138 from Zeemahh/fix/chat-scroll

fix: scroll bug when switching chat channel (isChannel)
This commit is contained in:
リーフストーム 2020-12-04 17:26:35 +01:00 committed by GitHub
commit c75152c238
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -397,6 +397,9 @@ export default Vue.extend({
this.modeIdx = (this.modeIdx + 1) % this.modes.length; this.modeIdx = (this.modeIdx + 1) % this.modes.length;
} while (this.modes[this.modeIdx].hidden); } while (this.modes[this.modeIdx].hidden);
} }
const buf = document.getElementsByClassName('chat-messages')[0];
setTimeout(() => buf.scrollTop = buf.scrollHeight, 0);
} }
this.resize(); this.resize();