# HG changeset patch # User Mads Kiilerich # Date 1470963888 -7200 # Node ID 59a38ec5ad8bfdd5090e6560f684d6e58c790c36 # Parent 8d11063e025d1cdaffabcb036474a8e8d696bb97 diff: tweak mergely side-by-side diff view Expand diff pane to match view port and avoid extra scroll bars. diff -r 8d11063e025d -r 59a38ec5ad8b kallithea/public/css/style.css --- a/kallithea/public/css/style.css Fri Aug 12 03:04:48 2016 +0200 +++ b/kallithea/public/css/style.css Fri Aug 12 03:04:48 2016 +0200 @@ -2953,6 +2953,17 @@ padding: 2px 0px 0px 2px; float: left; } +.diffblock.twoway { + overflow: visible; +} +.diffblock.twoway .diff-actions { + padding-top: 0; +} +.diffblock.twoway .diff-actions label input { + margin: -5px 5px 0 10px; + position: relative; + top: 3px; +} .diffblock .diff-menu ul li { padding: 0px 0px 0px 0px !important; } diff -r 8d11063e025d -r 59a38ec5ad8b kallithea/templates/files/diff_2way.html --- a/kallithea/templates/files/diff_2way.html Fri Aug 12 03:04:48 2016 +0200 +++ b/kallithea/templates/files/diff_2way.html Fri Aug 12 03:04:48 2016 +0200 @@ -31,8 +31,8 @@ ${self.breadcrumbs()} -
-
+
+
@@ -68,7 +68,7 @@ $(document).ready(function () { $('#compare').mergely({ width: 'auto', - height: '600', + height: $(window).height() - $('#compare').offset().top - $('#footer').height() - 35, fgcolor: {a:'#ddffdd',c:'#cccccc',d:'#ffdddd'}, bgcolor: '#fff', viewport: true, @@ -91,6 +91,9 @@ } } }); + // recompute width - avoids overflow and horizontal scrollbar + $('#compare').mergely('resize'); + $('#ignorews').change(function(e){ var val = e.currentTarget.checked; $('#compare').mergely('options', {ignorews: val});