1
0
Fork 1
mirror of https://example.com synced 2024-11-24 06:56:41 +09:00
This commit is contained in:
syuilo 2020-03-22 19:41:35 +09:00
parent de1ecbaef4
commit 9c3a4eb947

View file

@ -246,7 +246,10 @@ export default Vue.extend({
if (this.isDesktop) this.adjustWidgetsWidth();
const adjustTitlePosition = () => {
this.$refs.title.style.left = (this.$refs.main.getBoundingClientRect().left - this.$refs.nav.offsetWidth) + 'px';
const left = this.$refs.main.getBoundingClientRect().left - this.$refs.nav.offsetWidth;
if (left >= 0) {
this.$refs.title.style.left = left + 'px';
}
};
adjustTitlePosition();