##// END OF EJS Templates
pullrequests: added peppercorn sequence start/end markers to...
dan -
r955:e88e739c default
parent child Browse files
Show More
@@ -1,102 +1,104 b''
1 1 ## Changesets table !
2 2 <%namespace name="base" file="/base/base.html"/>
3 3 <div class="container">
4 4 %if not c.commit_ranges:
5 5 <p class="empty_data">${_('No Commits')}</p>
6 6 %else:
7 7
8 8 %if c.ancestor:
9 9 <p class="ancestor">${_('Common Ancestor Commit')}:
10 10 <a href="${h.url('changeset_home',
11 11 repo_name=c.repo_name,
12 12 revision=c.ancestor)}">
13 13 ${h.short_id(c.ancestor)}
14 14 </a>
15 15 </p>
16 16 %endif
17 17
18 <input type="hidden" name="__start__" value="revisions:sequence">
18 19 <table class="rctable compare_view_commits">
19 20 <tr>
20 21 <th>${_('Time')}</th>
21 22 <th>${_('Author')}</th>
22 23 <th>${_('Commit')}</th>
23 24 <th></th>
24 25 <th>${_('Description')}</th>
25 26 </tr>
26 27 %for commit in c.commit_ranges:
27 28 <tr id="row-${commit.raw_id}"
28 29 commit_id="${commit.raw_id}"
29 30 class="compare_select"
30 31 >
31 32 <td class="td-time">
32 33 ${h.age_component(commit.date)}
33 34 </td>
34 35 <td class="td-user">
35 36 ${base.gravatar_with_user(commit.author, 16)}
36 37 </td>
37 38 <td class="td-hash">
38 39 <code>
39 40 <a href="${h.url('changeset_home',
40 41 repo_name=c.target_repo.repo_name,
41 42 revision=commit.raw_id)}">
42 43 r${commit.revision}:${h.short_id(commit.raw_id)}
43 44 </a>
44 45 ${h.hidden('revisions',commit.raw_id)}
45 46 </code>
46 47 </td>
47 48 <td class="expand_commit"
48 49 data-commit-id="${commit.raw_id}"
49 50 title="${_( 'Expand commit message')}"
50 51 >
51 52 <div class="show_more_col">
52 53 <i class="show_more"></i>
53 54 </div>
54 55 </td>
55 56 <td class="mid td-description">
56 57 <div class="log-container truncate-wrap">
57 58 <div
58 59 id="c-${commit.raw_id}"
59 60 class="message truncate"
60 61 data-message-raw="${commit.message}"
61 62 >
62 63 ${h.urlify_commit_message(commit.message, c.repo_name)}
63 64 </div>
64 65 </div>
65 66 </td>
66 67 </tr>
67 68 %endfor
68 69 </table>
70 <input type="hidden" name="__end__" value="revisions:sequence">
69 71 %endif
70 72 </div>
71 73
72 74 <script>
73 75 $('.expand_commit').on('click',function(e){
74 76 var target_expand = $(this);
75 77 var cid = target_expand.data('commitId');
76 78
77 79 ## TODO: dan: extract styles into css, and just toggleClass('open') here
78 80 if (target_expand.hasClass('open')){
79 81 $('#c-'+cid).css({
80 82 'height': '1.5em',
81 83 'white-space': 'nowrap',
82 84 'text-overflow': 'ellipsis',
83 85 'overflow':'hidden'
84 86 });
85 87 target_expand.removeClass('open');
86 88 }
87 89 else {
88 90 $('#c-'+cid).css({
89 91 'height': 'auto',
90 92 'white-space': 'pre-line',
91 93 'text-overflow': 'initial',
92 94 'overflow':'visible'
93 95 });
94 96 target_expand.addClass('open');
95 97 }
96 98 });
97 99
98 100 $('.compare_select').on('click',function(e){
99 101 var cid = $(this).attr('commit_id');
100 102 $('#row-'+cid).toggleClass('hl', !$('#row-'+cid).hasClass('hl'));
101 103 });
102 104 </script>
General Comments 0
You need to be logged in to leave comments. Login now