annotate rhodecode/templates/files/files_browser.html @ 4116:ffd45b185016 rhodecode-2.2.5-gpl

Imported some of the GPLv3'd changes from RhodeCode v2.2.5. This imports changes between changesets 21af6c4eab3d and 6177597791c2 in RhodeCode's original repository, including only changes to Python files and HTML. RhodeCode clearly licensed its changes to these files under GPLv3 in their /LICENSE file, which states the following: The Python code and integrated HTML are licensed under the GPLv3 license. (See: https://code.rhodecode.com/rhodecode/files/v2.2.5/LICENSE or http://web.archive.org/web/20140512193334/https://code.rhodecode.com/rhodecode/files/f3b123159901f15426d18e3dc395e8369f70ebe0/LICENSE for an online copy of that LICENSE file) Conservancy reviewed these changes and confirmed that they can be licensed as a whole to the Kallithea project under GPLv3-only. While some of the contents committed herein are clearly licensed GPLv3-or-later, on the whole we must assume the are GPLv3-only, since the statement above from RhodeCode indicates that they intend GPLv3-only as their license, per GPLv3ยง14 and other relevant sections of GPLv3.
author Bradley M. Kuhn <bkuhn@sfconservancy.org>
date Wed, 02 Jul 2014 19:03:13 -0400
parents 3563bb7b4b82
children 1cb909e6fc6d
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
128
9deb6f1d5b90 Implemented file history.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
1 <%def name="file_class(node)">
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
2 %if node.is_file():
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
3 <%return "browser-file" %>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
4 %else:
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
5 <%return "browser-dir"%>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
6 %endif
128
9deb6f1d5b90 Implemented file history.
Marcin Kuzminski <marcin@python-works.com>
parents:
diff changeset
7 </%def>
144
ea89ac73bef8 Update css +file browsing and diffs
Marcin Kuzminski <marcin@python-works.com>
parents: 128
diff changeset
8 <div id="body" class="browserblock">
949
3bc10f10f2f6 fixed file browsing ui and css
Marcin Kuzminski <marcin@python-works.com>
parents: 904
diff changeset
9 <div class="browser-header">
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
10 <div class="browser-nav">
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
11 ${h.form(h.url.current())}
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
12 <div class="info_box">
4116
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
13 <div class="info_box_elem rev">${_('revision')}</div>
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
14 <div class="info_box_elem"><a class="btn btn-mini ypjax-link" href="${c.url_prev}" title="${_('Previous revision')}"><i class="icon-chevron-left"></i></a></div>
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
15 <div class="info_box_elem">${h.text('at_rev',value=c.changeset.revision,size=5)}</div>
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
16 <div class="info_box_elem"><a class="btn btn-mini ypjax-link" href="${c.url_next}" title="${_('Next revision')}"><i class="icon-chevron-right"></i></a></div>
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
17 </div>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
18 ${h.end_form()}
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
19 </div>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
20 <div class="browser-branch">
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
21 ${h.checkbox('stay_at_branch',c.changeset.branch,c.changeset.branch==c.branch)}
3654
ec6354949623 Fix a lot of casings - use standard casing in most places
Mads Kiilerich <madski@unity3d.com>
parents: 3496
diff changeset
22 <label>${_('Follow current branch')}</label>
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
23 </div>
4116
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
24 <div id="search_activate_id" class="search_activate">
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
25 <a class="btn btn-mini" id="filter_activate" href="#">${_('Search File List')}</a>
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
26 </div>
1452
8585fbf3ed06 Implemented #111 copy github node finder solution
Marcin Kuzminski <marcin@python-works.com>
parents: 1304
diff changeset
27 <div class="browser-search">
4116
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
28 <div>
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
29 <div id="node_filter_box_loading" style="display:none">${_('Loading file list...')}</div>
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
30 <div id="node_filter_box" style="display:none">
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
31 ${h.files_breadcrumbs(c.repo_name,c.changeset.raw_id,c.file.path)}/<input class="init" type="text" value="type to search..." name="filter" size="25" id="node_filter" autocomplete="off">
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
32 </div>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1810
diff changeset
33 </div>
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1810
diff changeset
34 </div>
884
322b53be49cc Fixed url bug when using numeric revision in file browser,
Marcin Kuzminski <marcin@python-works.com>
parents: 740
diff changeset
35 </div>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1810
diff changeset
36
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
37 <div class="browser-body">
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
38 <table class="code-browser">
3198
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
39 <thead>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
40 <tr>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
41 <th>${_('Name')}</th>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
42 <th>${_('Size')}</th>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
43 <th>${_('Mimetype')}</th>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
44 <th>${_('Last Revision')}</th>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
45 <th>${_('Last modified')}</th>
3492
0065f7fe60f6 fix spelling of committer
Mads Kiilerich <madski@unity3d.com>
parents: 3198
diff changeset
46 <th>${_('Last committer')}</th>
3198
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
47 </tr>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
48 </thead>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1810
diff changeset
49
3198
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
50 <tbody id="tbody">
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
51 %if c.file.parent:
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
52 <tr class="parity0">
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
53 <td>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
54 ${h.link_to('..',h.url('files_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=c.file.parent.path),class_="browser-dir ypjax-link")}
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
55 </td>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
56 <td></td>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
57 <td></td>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
58 <td></td>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
59 <td></td>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
60 <td></td>
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
61 </tr>
3198
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
62 %endif
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1810
diff changeset
63
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
64 %for cnt,node in enumerate(c.file):
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
65 <tr class="parity${cnt%2}">
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
66 <td>
2232
49dc09e9f076 Implements subrepos view inside filebrowser
Marcin Kuzminski <marcin@python-works.com>
parents: 2084
diff changeset
67 %if node.is_submodule():
49dc09e9f076 Implements subrepos view inside filebrowser
Marcin Kuzminski <marcin@python-works.com>
parents: 2084
diff changeset
68 ${h.link_to(node.name,node.url or '#',class_="submodule-dir ypjax-link")}
49dc09e9f076 Implements subrepos view inside filebrowser
Marcin Kuzminski <marcin@python-works.com>
parents: 2084
diff changeset
69 %else:
49dc09e9f076 Implements subrepos view inside filebrowser
Marcin Kuzminski <marcin@python-works.com>
parents: 2084
diff changeset
70 ${h.link_to(node.name, h.url('files_home',repo_name=c.repo_name,revision=c.changeset.raw_id,f_path=h.safe_unicode(node.path)),class_=file_class(node)+" ypjax-link")}
49dc09e9f076 Implements subrepos view inside filebrowser
Marcin Kuzminski <marcin@python-works.com>
parents: 2084
diff changeset
71 %endif:
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
72 </td>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
73 <td>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
74 %if node.is_file():
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
75 ${h.format_byte_size(node.size,binary=True)}
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
76 %endif
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
77 </td>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
78 <td>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
79 %if node.is_file():
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
80 ${node.mimetype}
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
81 %endif
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
82 </td>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
83 <td>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
84 %if node.is_file():
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
85 <div class="tooltip" title="${h.tooltip(node.last_changeset.message)}">
3496
58905069da21 Speed up of last_changeset extraction in VCS, in edge cases for git we can get 10x speed improvement by limiting the history extraction if we only need last changeset
Marcin Kuzminski <marcin@python-works.com>
parents: 3492
diff changeset
86 <pre>${'r%s:%s' % (node.last_changeset.revision,node.last_changeset.short_id)}</pre>
58905069da21 Speed up of last_changeset extraction in VCS, in edge cases for git we can get 10x speed improvement by limiting the history extraction if we only need last changeset
Marcin Kuzminski <marcin@python-works.com>
parents: 3492
diff changeset
87 </div>
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
88 %endif
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
89 </td>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
90 <td>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
91 %if node.is_file():
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
92 <span class="tooltip" title="${h.tooltip(h.fmt_date(node.last_changeset.date))}">
887
3c0cae9b58cf shorten last modified column in files listing
Marcin Kuzminski <marcin@python-works.com>
parents: 884
diff changeset
93 ${h.age(node.last_changeset.date)}</span>
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
94 %endif
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
95 </td>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
96 <td>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
97 %if node.is_file():
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
98 <span title="${node.last_changeset.author}">
1764
39b49c999efb fixes issue #320.
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
99 ${h.person(node.last_changeset.author)}
39b49c999efb fixes issue #320.
Marcin Kuzminski <marcin@python-works.com>
parents: 1756
diff changeset
100 </span>
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
101 %endif
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
102 </td>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
103 </tr>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
104 %endfor
3198
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
105 </tbody>
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
106 <tbody id="tbody_filtered" style="display:none">
c20adbaf16af html: random indentation fixes
Mads Kiilerich <madski@unity3d.com>
parents: 3197
diff changeset
107 </tbody>
3197
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
108 </table>
b4f401524060 html: don't use tabs
Mads Kiilerich <madski@unity3d.com>
parents: 2686
diff changeset
109 </div>
1888
f91d3f9b7230 White-space cleanup
Marcin Kuzminski <marcin@python-works.com>
parents: 1810
diff changeset
110 </div>
4116
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
111
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
112 <script>
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
113 $(document).ready(function(){
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
114 // init node filter if we pass GET param ?search=1
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
115 var search_GET = "${request.GET.get('search','')}";
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
116 if(search_GET == "1"){
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
117 _NODEFILTER.initFilter();
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
118 }
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
119 })
ffd45b185016 Imported some of the GPLv3'd changes from RhodeCode v2.2.5.
Bradley M. Kuhn <bkuhn@sfconservancy.org>
parents: 3700
diff changeset
120 </script>