diff --git a/kallithea/public/css/style.css b/kallithea/public/css/style.css --- a/kallithea/public/css/style.css +++ b/kallithea/public/css/style.css @@ -2998,9 +2998,8 @@ table.code-browser tbody td { } table.code-browser .browser-file { - background: url("../images/icons/document_16.png") no-repeat scroll 3px; height: 16px; - padding-left: 20px; + padding-left: 5px; text-align: left; } .diffblock .changeset_header { @@ -3041,16 +3040,14 @@ table.code-browser .browser-file { background-color: #EEEEEE; } table.code-browser .browser-dir { - background: url("../images/icons/folder_16.png") no-repeat scroll 3px; height: 16px; - padding-left: 20px; + padding-left: 5px; text-align: left; } table.code-browser .submodule-dir { - background: url("../images/icons/disconnect.png") no-repeat scroll 3px; height: 16px; - padding-left: 20px; + padding-left: 5px; text-align: left; } diff --git a/kallithea/public/images/icons/disconnect.png b/kallithea/public/images/icons/disconnect.png deleted file mode 100644 index b335cb11c4d1a397b307883adcfe1e00c4cf8e6a..0000000000000000000000000000000000000000 GIT binary patch literal 0 Hc$@ %endif +<%def name="file_name(node)"> + <% + c = "icon-folder-open" + if node.is_file(): + c = "icon-doc" + elif node.is_submodule(): + c = "icon-file-submodule" + %> + <%return h.literal('%s' % (c, node.name))%> +
@@ -60,7 +70,7 @@ %if c.file.parent: - ${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")} + ${h.link_to(h.literal('..'),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")} @@ -73,7 +83,7 @@ %for cnt,node in enumerate(c.file): - ${h.link_to(node.name,file_url(node,c),class_=file_class(node)+" ypjax-link")} + ${h.link_to(file_name(node),file_url(node,c),class_=file_class(node)+" ypjax-link")} %if node.is_file(): diff --git a/kallithea/tests/functional/test_files.py b/kallithea/tests/functional/test_files.py --- a/kallithea/tests/functional/test_files.py +++ b/kallithea/tests/functional/test_files.py @@ -33,19 +33,19 @@ class TestFilesController(TestController revision='tip', f_path='/')) # Test response... - response.mustcontain('docs') - response.mustcontain('vcs') - response.mustcontain('.gitignore') - response.mustcontain('.hgignore') - response.mustcontain('.hgtags') - response.mustcontain('.travis.yml') - response.mustcontain('MANIFEST.in') - response.mustcontain('README.rst') - response.mustcontain('run_test_and_report.sh') - response.mustcontain('setup.cfg') - response.mustcontain('setup.py') - response.mustcontain('test_and_report.sh') - response.mustcontain('tox.ini') + response.mustcontain('docs') + response.mustcontain('vcs') + response.mustcontain('.gitignore') + response.mustcontain('.hgignore') + response.mustcontain('.hgtags') + response.mustcontain('.travis.yml') + response.mustcontain('MANIFEST.in') + response.mustcontain('README.rst') + response.mustcontain('run_test_and_report.sh') + response.mustcontain('setup.cfg') + response.mustcontain('setup.py') + response.mustcontain('test_and_report.sh') + response.mustcontain('tox.ini') def test_index_revision(self): self.log_user() @@ -59,9 +59,9 @@ class TestFilesController(TestController #Test response... - response.mustcontain('docs') - response.mustcontain('tests') - response.mustcontain('README.rst') + response.mustcontain('docs') + response.mustcontain('tests') + response.mustcontain('README.rst') response.mustcontain('1.1 KiB') response.mustcontain('text/x-python')