##// END OF EJS Templates
diffs: added scroll down/scroll up helper. Fixes #5643
marcink -
r4595:82d4afd7 stable
parent child Browse files
Show More
@@ -263,6 +263,10 b' input[type="button"] {'
263 263 border-radius: @border-radius 0 0 @border-radius;
264 264
265 265 }
266 // 2nd, if only 2 elements are there
267 &:nth-of-type(2) {
268 border-left-width: 0;
269 }
266 270 // middle elements
267 271 &:not(:first-of-type):not(:last-of-type) {
268 272 border-radius: 0;
@@ -194,6 +194,7 b''
194 194 .icon-comment-toggle:before { content: '\e830'; } /* '' */
195 195 .icon-rhodecode:before { content: '\e831'; } /* '' */
196 196 .icon-up:before { content: '\e832'; } /* '' */
197 .icon-down:before { content: '\e832'; } /* '' */
197 198 .icon-merge:before { content: '\e833'; } /* '' */
198 199 .icon-spin-alt:before { content: '\e834'; } /* '' */
199 200 .icon-spin:before { content: '\e838'; } /* '' */
@@ -235,6 +236,7 b''
235 236 .icon-rss-sign:before { &:extend(.icon-feed:before); }
236 237 .icon-code-fork:before { &:extend(.icon-fork:before); }
237 238 .icon-arrow_up:before { &:extend(.icon-up:before); }
239 .icon-arrow_down:before { &:extend(.icon-down:before); }
238 240 .icon-file:before { &:extend(.icon-file-code:before); }
239 241 .icon-file-text:before { &:extend(.icon-file-code:before); }
240 242 .icon-directory:before { &:extend(.icon-folder:before); }
@@ -253,6 +255,8 b''
253 255 .icon-merge:before {transform: rotate(180deg);}
254 256 .icon-wide-mode:before {transform: rotate(90deg);}
255 257 .icon-options:before {transform: rotate(90deg);}
258 .icon-down:before {transform: rotate(180deg);}
259
256 260
257 261 // -- END ICON CLASSES -- //
258 262
@@ -714,3 +714,11 b' var getUserSessionAttr = function(key) {'
714 714 }
715 715 return null
716 716 }
717
718 window.scrollDown = function () {
719 $(document).scrollTop($(document).height());
720 }
721
722 window.scrollUp = function scrollUp() {
723 $(window).scrollTop(0);
724 }
@@ -397,6 +397,7 b' window.ReviewersController = function ()'
397 397 'user_group': reviewer_obj.user_group,
398 398 'create': true,
399 399 'rule_show': true,
400 'rhodecode_user': templateContext.rhodecode_user
400 401 })
401 402
402 403 if (role === self.ROLE_REVIEWER) {
@@ -820,7 +821,8 b' window.ReviewersPanel = {'
820 821 'review_status': member.review_status,
821 822 'review_status_label': member.review_status_label,
822 823 'user_group': member.user_group,
823 'create': false
824 'create': false,
825 'rhodecode_user': templateContext.rhodecode_user
824 826 });
825 827
826 828 $(self.controller.$reviewMembers.selector).append(entry)
@@ -915,7 +917,8 b' window.ObserversPanel = {'
915 917 'review_status': member.review_status,
916 918 'review_status_label': member.review_status_label,
917 919 'user_group': member.user_group,
918 'create': false
920 'create': false,
921 'rhodecode_user': templateContext.rhodecode_user
919 922 });
920 923
921 924 $(self.controller.$observerMembers.selector).append(entry)
@@ -916,6 +916,16 b' def get_comments_for(diff_type, comments'
916 916 <div class="sidebar__inner">
917 917 <div class="sidebar__bar">
918 918 <div class="pull-right">
919
920 <div class="btn-group" style="margin-right: 5px;">
921 <a class="tooltip btn" onclick="scrollDown();return false" title="${_('Scroll to page bottom')}">
922 <i class="icon-arrow_down"></i>
923 </a>
924 <a class="tooltip btn" onclick="scrollUp();return false" title="${_('Scroll to page top')}">
925 <i class="icon-arrow_up"></i>
926 </a>
927 </div>
928
919 929 <div class="btn-group">
920 930 <a class="btn tooltip toggle-wide-diff" href="#toggle-wide-diff" onclick="toggleWideDiff(this); return false" title="${h.tooltip(_('Toggle wide diff'))}">
921 931 <i class="icon-wide-mode"></i>
@@ -1004,7 +1014,6 b' def get_comments_for(diff_type, comments'
1004 1014 </strong>
1005 1015 </div>
1006 1016 <div class="pull-right noselect">
1007
1008 1017 %if commit:
1009 1018 <span>
1010 1019 <code>${h.show_id(commit)}</code>
@@ -604,6 +604,7 b''
604 604 <i class="icon-circle review-status-${c.pull_request_review_status}"></i>
605 605 ${_('Reviewers')}
606 606 </span>
607
607 608 %if c.allowed_to_update:
608 609 <span id="open_edit_reviewers" class="block-right action_button last-item">${_('Edit')}</span>
609 610 <span id="close_edit_reviewers" class="block-right action_button last-item" style="display: none;">${_('Close')}</span>
@@ -644,7 +645,7 b''
644 645 </div>
645 646 % endif
646 647 <div class="pull-right" style="margin-bottom: 15px">
647 <button data-role="reviewer" id="update_reviewers" class="btn btn-small no-margin">${_('Save Changes')}</button>
648 <button data-role="reviewer" id="update_reviewers" class="btn btn-sm no-margin">${_('Save Changes')}</button>
648 649 </div>
649 650 %endif
650 651 </div>
@@ -697,7 +698,7 b''
697 698 </div>
698 699 % endif
699 700 <div class="pull-right" style="margin-bottom: 15px">
700 <button data-role="observer" id="update_observers" class="btn btn-small no-margin">${_('Save Changes')}</button>
701 <button data-role="observer" id="update_observers" class="btn btn-sm no-margin">${_('Save Changes')}</button>
701 702 </div>
702 703 %endif
703 704 </div>
General Comments 0
You need to be logged in to leave comments. Login now