diff --git a/app/index.html b/app/index.html index 1bb283d4..f9794ca3 100644 --- a/app/index.html +++ b/app/index.html @@ -39,7 +39,7 @@ - + diff --git a/app/js/directives.js b/app/js/directives.js index 9b778576..0845ce9d 100644 --- a/app/js/directives.js +++ b/app/js/directives.js @@ -97,6 +97,7 @@ angular.module('myApp.directives', ['myApp.filters']) function link (scope, element, attrs) { var historyWrap = $('.im_history_wrap')[0], + historyEl = $('.im_history')[0], scrollableWrap = $('.im_history_scrollable_wrap')[0], scrollable = $('.im_history_scrollable')[0], panelWrap = $('.im_history_panel_wrap', element)[0], @@ -182,6 +183,9 @@ angular.module('myApp.directives', ['myApp.filters']) $(historyWrap).css({ height: $($window).height() - panelWrap.offsetHeight - sendFormWrap.offsetHeight - 90 }); + $(historyEl).css({ + minHeight: $($window).height() - panelWrap.offsetHeight - sendFormWrap.offsetHeight - 90 - 44 + }); if (heightOnly) return; if (atBottom) { @@ -329,10 +333,9 @@ angular.module('myApp.directives', ['myApp.filters']) }; function link (scope, element, attrs) { - scope.$watch('thumb.location', function (newVal) { if (!scope.thumb || !scope.thumb.location) { - element.attr('src', scope.thumb.placeholder || ''); + element.attr('src', scope.thumb && scope.thumb.placeholder || ''); return; }