annotate rhodecode/templates/files/file_diff.html @ 4062:368589dfbe98

side-by-side diffs: use full power of mergerly whitespace and interactive merge modes
author Marcin Kuzminski <marcin@python-works.com>
date Fri, 28 Jun 2013 22:43:32 +0200
parents 31ca78c45705
children ffd45b185016
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
129
42d46deb124d implemented simple diffs for history of files.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
1 <%inherit file="/base/base.html"/>
42d46deb124d implemented simple diffs for history of files.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
2
42d46deb124d implemented simple diffs for history of files.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
3 <%def name="title()">
3582
1f334a68d057 improved title consistency
Marcin Kuzminski <marcin@python-works.com>
parents: 2492
diff changeset
4 ${_('%s File Diff') % c.repo_name} &middot; ${c.rhodecode_name}
129
42d46deb124d implemented simple diffs for history of files.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
5 </%def>
619
a1ec653f5f95 #38 updated RhodeCode titles
Marcin Kuzminski <marcin@python-works.com>
parents: 569
diff changeset
6
362
558eb7c5028f version bump to 0.8
Marcin Kuzminski <marcin@python-works.com>
parents: 189
diff changeset
7 <%def name="breadcrumbs_links()">
636
ffd07396d315 Fixes for raw_id, needed for git
Marcin Kuzminski <marcin@python-works.com>
parents: 619
diff changeset
8 ${_('File diff')} r${c.changeset_1.revision}:${h.short_id(c.changeset_1.raw_id)} &rarr; r${c.changeset_2.revision}:${h.short_id(c.changeset_2.raw_id)}
129
42d46deb124d implemented simple diffs for history of files.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
9 </%def>
362
558eb7c5028f version bump to 0.8
Marcin Kuzminski <marcin@python-works.com>
parents: 189
diff changeset
10
129
42d46deb124d implemented simple diffs for history of files.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
11 <%def name="page_nav()">
3603
eacd33e0c5b3 use valid options for the top menu: repositories, journal, search and admin
Mads Kiilerich <madski@unity3d.com>
parents: 3602
diff changeset
12 ${self.menu('repositories')}
129
42d46deb124d implemented simple diffs for history of files.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
13 </%def>
3601
51da0e019248 repository pages: cleanup of use of repository context menu
Mads Kiilerich <madski@unity3d.com>
parents: 3582
diff changeset
14
129
42d46deb124d implemented simple diffs for history of files.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
15 <%def name="main()">
4059
31ca78c45705 context menu should be changelog when viewing changes
Marcin Kuzminski <marcin@python-works.com>
parents: 3988
diff changeset
16 ${self.repo_context_bar('changelog')}
362
558eb7c5028f version bump to 0.8
Marcin Kuzminski <marcin@python-works.com>
parents: 189
diff changeset
17 <div class="box">
558eb7c5028f version bump to 0.8
Marcin Kuzminski <marcin@python-works.com>
parents: 189
diff changeset
18 <!-- box / title -->
558eb7c5028f version bump to 0.8
Marcin Kuzminski <marcin@python-works.com>
parents: 189
diff changeset
19 <div class="title">
558eb7c5028f version bump to 0.8
Marcin Kuzminski <marcin@python-works.com>
parents: 189
diff changeset
20 ${self.breadcrumbs()}
558eb7c5028f version bump to 0.8
Marcin Kuzminski <marcin@python-works.com>
parents: 189
diff changeset
21 </div>
1789
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
22 <div>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1789
diff changeset
23 ## diff block
1789
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
24 <%namespace name="diff_block" file="/changeset/diff_block.html"/>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1789
diff changeset
25 ${diff_block.diff_block(c.changes)}
362
558eb7c5028f version bump to 0.8
Marcin Kuzminski <marcin@python-works.com>
parents: 189
diff changeset
26 </div>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1789
diff changeset
27 </div>
3601
51da0e019248 repository pages: cleanup of use of repository context menu
Mads Kiilerich <madski@unity3d.com>
parents: 3582
diff changeset
28
1789
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
29 <script>
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
30 YUE.onDOMReady(function(){
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1789
diff changeset
31
1789
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
32 YUE.on(YUQ('.diff-menu-activate'),'click',function(e){
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
33 var act = e.currentTarget.nextElementSibling;
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1789
diff changeset
34
1789
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
35 if(YUD.hasClass(act,'active')){
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
36 YUD.removeClass(act,'active');
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
37 YUD.setStyle(act,'display','none');
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
38 }else{
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
39 YUD.addClass(act,'active');
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
40 YUD.setStyle(act,'display','');
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
41 }
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
42 });
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
43
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
44 })
17caf4efe15c implements #308 rewrote diffs to enable displaying full diff on each file
Marcin Kuzminski <marcin@python-works.com>
parents: 1273
diff changeset
45 </script>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1789
diff changeset
46 </%def>