Permalink
Browse files

Display a delete link next to uploads in the file list

  • Loading branch information...
1 parent 9082dc1 commit 631e56acf7a32d1fb0ad6f673fe0e7be3458cb4c @rekado rekado committed Jan 8, 2014
Showing with 5 additions and 2 deletions.
  1. +4 −2 Network/Gitit/Handlers.hs
  2. +1 −0 data/static/css/screen.css
@@ -674,8 +674,10 @@ fileListToHtml base' prefix files =
li ! [theclass "page" ] <<
anchor ! [href $ base' ++ urlForPage (prefix ++ dropExtension f)] <<
dropExtension f
- fileLink (FSFile f) =
- li ! [theclass "upload"] << anchor ! [href $ base' ++ urlForPage (prefix ++ f)] << f
+ fileLink (FSFile f) = li ! [theclass "upload"] << concatHtml
+ [ anchor ! [href $ base' ++ urlForPage (prefix ++ f)] << f
+ , anchor ! [href $ base' ++ "_delete" ++ urlForPage (prefix ++ f)] << "(delete)"
+ ]
fileLink (FSDirectory f) =
li ! [theclass "folder"] <<
anchor ! [href $ base' ++ urlForPage (prefix ++ f) ++ "/"] << f
@@ -130,6 +130,7 @@ ul.tabs li a { text-decoration: none; font-size: 93%; font-weight: bold; margin:
.index li.page { background-image: url(../img/icons/page.png); }
.index li.folder { background-image: url(../img/icons/folder.png); }
.index a { color: #000000; cursor: pointer; text-decoration: none; }
+.index a + a { margin-left: 0.5em; }
.index a:hover { text-decoration: underline; }
a.updir { font-weight: bold; }

0 comments on commit 631e56a

Please sign in to comment.