##// END OF EJS Templates
diffs: added wide-mode button to expand large diffs.
marcink -
r1193:26ee369d default
parent child Browse files
Show More
@@ -109,6 +109,10 b' ul.simple-list{'
109 padding-bottom: @pagepadding;
109 padding-bottom: @pagepadding;
110 }
110 }
111
111
112 .wide-mode-wrapper {
113 max-width:2400px !important;
114 }
115
112 .wrapper {
116 .wrapper {
113 position: relative;
117 position: relative;
114 max-width: @wrapper-maxwidth;
118 max-width: @wrapper-maxwidth;
@@ -476,6 +476,19 b' var CommentsController = function() { /*'
476 ajaxPOST(url, postData, success, failure);
476 ajaxPOST(url, postData, success, failure);
477 };
477 };
478
478
479 this.toggleWideMode = function (node) {
480 if ($('#content').hasClass('wrapper')) {
481 $('#content').removeClass("wrapper");
482 $('#content').addClass("wide-mode-wrapper");
483 $(node).addClass('btn-success');
484 } else {
485 $('#content').removeClass("wide-mode-wrapper");
486 $('#content').addClass("wrapper");
487 $(node).removeClass('btn-success');
488 }
489 return false;
490 };
491
479 this.toggleComments = function(node, show) {
492 this.toggleComments = function(node, show) {
480 var $filediff = $(node).closest('.filediff');
493 var $filediff = $(node).closest('.filediff');
481 if (show === true) {
494 if (show === true) {
@@ -540,6 +540,7 b' from rhodecode.lib.diffs import NEW_FILE'
540 </%def>
540 </%def>
541
541
542 <%def name="render_diffset_menu()">
542 <%def name="render_diffset_menu()">
543
543 <div class="diffset-menu clearinner">
544 <div class="diffset-menu clearinner">
544 <div class="pull-right">
545 <div class="pull-right">
545 <div class="btn-group">
546 <div class="btn-group">
@@ -566,6 +567,10 b' from rhodecode.lib.diffs import NEW_FILE'
566 class="btn"
567 class="btn"
567 href="#"
568 href="#"
568 onclick="$('input[class=filediff-collapse-state]').prop('checked', true); return false">${_('Collapse All')}</a>
569 onclick="$('input[class=filediff-collapse-state]').prop('checked', true); return false">${_('Collapse All')}</a>
570 <a
571 class="btn"
572 href="#"
573 onclick="return Rhodecode.comments.toggleWideMode(this)">${_('Wide Mode')}</a>
569 </div>
574 </div>
570 </div>
575 </div>
571 </div>
576 </div>
General Comments 0
You need to be logged in to leave comments. Login now