From 9457b03da1b3251cae04bb638772ac51c9672e04 Mon Sep 17 00:00:00 2001 From: Sam Date: Thu, 20 Oct 2016 10:14:53 +1100 Subject: [PATCH] UX: make it easier to collapse the timeline from fullscreen --- .../javascripts/discourse/components/topic-navigation.js.es6 | 3 ++- app/assets/stylesheets/common/topic-timeline.scss | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/app/assets/javascripts/discourse/components/topic-navigation.js.es6 b/app/assets/javascripts/discourse/components/topic-navigation.js.es6 index 72313abb533..c7b28ca17c0 100644 --- a/app/assets/javascripts/discourse/components/topic-navigation.js.es6 +++ b/app/assets/javascripts/discourse/components/topic-navigation.js.es6 @@ -46,7 +46,8 @@ export default Ember.Component.extend({ _expanded() { if (this.get('info.topicProgressExpanded')) { $(window).on('click.hide-fullscreen', (e) => { - if (!$(e.target).parents().is('.timeline-container, #topic-progress-wrapper')) { + if ( $(e.target).is('.topic-timeline') || + !$(e.target).parents().is('.timeline-container, #topic-progress-wrapper')) { this._collapseFullscreen(); } }); diff --git a/app/assets/stylesheets/common/topic-timeline.scss b/app/assets/stylesheets/common/topic-timeline.scss index 8e606dbb90b..3aa43fd0557 100644 --- a/app/assets/stylesheets/common/topic-timeline.scss +++ b/app/assets/stylesheets/common/topic-timeline.scss @@ -46,6 +46,9 @@ border-top: 1px solid dark-light-choose(scale-color($primary, $lightness: 90%), scale-color($secondary, $lightness: 90%)); padding-top: 15px; z-index: 100000; + .timeline-scrollarea { + max-width: 200px; + } .topic-timeline { width: auto; margin-left: 1.5em;