diff --git a/static/style.css b/static/style.css index 0357041..97854ac 100644 --- a/static/style.css +++ b/static/style.css @@ -76,6 +76,8 @@ body { margin: 0; font-family: sans-serif } .search-result-url { clear:left; } .search-result-url a { color: #5a5; font-size: 8pt; float: left; margin-right: 1em;} .search-result-links { color: #aaf; font-size: 8pt; float: left; margin-right: 1em; visibility: hidden } +.search-result-links a { padding-right: 0.5em; } +.search-result-links a:hover { text-decoration: underline } .search-result:hover > .search-result-links { visibility: visible } .search-result-date { color: #777; font-size: 8pt; float: right; margin-bottom: 7px; } .search-result-size { color: #777; font-size: 8pt; float: right; display: none; } @@ -114,7 +116,7 @@ tr { vertical-align: top } #settings-box { padding: 1em; position: absolute; - top: 10%; + top: 5%; left: 30%; right: 30%; background: #eee; diff --git a/views/result.tpl b/views/result.tpl index f7c65f2..000d831 100644 --- a/views/result.tpl +++ b/views/result.tpl @@ -7,7 +7,15 @@ %url = url.replace(dr, prefix) %end
- {{d['label']}} + %if config.has_key('title_link') and config['title_link'] != 'download': + %if config['title_link'] == 'open': + {{d['label']}} + %elif config['title_link'] == 'preview': + {{d['label']}} + %end + %else: + {{d['label']}} + %end
%if len(d['ipath']) > 0:
[{{d['ipath']}}]
@@ -22,11 +30,13 @@ %end {{urllabel}} -%if hasrclextract: -%end
{{d['time']}}
{{!d['snippet']}}
diff --git a/views/settings.tpl b/views/settings.tpl index 2d3490c..fac85b7 100644 --- a/views/settings.tpl +++ b/views/settings.tpl @@ -16,6 +16,12 @@ Folder depth (number of levels of the folder dropdown) + Default action (action to take when clicking result title) +
Locations
%for d in dirs: diff --git a/webui.py b/webui.py index 15f326a..e86885f 100755 --- a/webui.py +++ b/webui.py @@ -39,6 +39,7 @@ DEFAULTS = { 'maxresults': 0, 'perpage': 25, 'csvfields': 'filename title author size time mtype url', + 'title_link': 'download', } # sort fields/labels