From cc11c352cfdabc784a8ec2c75d48ef09e1ab2008 Mon Sep 17 00:00:00 2001 From: Robin Ward Date: Wed, 1 Jun 2016 13:30:00 -0400 Subject: [PATCH] UX: Timeline was snapping to dock too early --- .../javascripts/discourse/components/mount-widget.js.es6 | 3 --- .../javascripts/discourse/components/topic-timeline.js.es6 | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/app/assets/javascripts/discourse/components/mount-widget.js.es6 b/app/assets/javascripts/discourse/components/mount-widget.js.es6 index f47ce4688cd..c9310fb66aa 100644 --- a/app/assets/javascripts/discourse/components/mount-widget.js.es6 +++ b/app/assets/javascripts/discourse/components/mount-widget.js.es6 @@ -95,7 +95,6 @@ export default Ember.Component.extend({ if (!this._widgetClass) { return; } const t0 = new Date().getTime(); - const args = this.get('args') || this.buildArgs(); const opts = { model: this.get('model') }; const newTree = new this._widgetClass(args, this.container, opts); @@ -119,8 +118,6 @@ export default Ember.Component.extend({ if (this.profileWidget) { console.log(new Date().getTime() - t0); } - } } - }); diff --git a/app/assets/javascripts/discourse/components/topic-timeline.js.es6 b/app/assets/javascripts/discourse/components/topic-timeline.js.es6 index e9d697b7866..7a9cf9d904f 100644 --- a/app/assets/javascripts/discourse/components/topic-timeline.js.es6 +++ b/app/assets/javascripts/discourse/components/topic-timeline.js.es6 @@ -39,7 +39,7 @@ export default MountWidget.extend(Docking, { this.dockBottom = false; if (posTop < topicTop) { this.dockAt = topicTop; - } else if (pos > topicBottom) { + } else if (pos > topicBottom + footerHeight) { this.dockAt = (topicBottom - timelineHeight) + footerHeight; this.dockBottom = true; if (this.dockAt < 0) { this.dockAt = 0; }