Count search results

This commit is contained in:
Tony Garnock-Jones 2014-11-08 19:23:58 -05:00
parent c9dc42adef
commit 8b0b72e493
3 changed files with 10 additions and 4 deletions

View File

@ -15,8 +15,6 @@ you should be able to specify git repos over http/https
you should be able to specify subdirs in git repos
you should check the existence of repos/github repos/urls/etc via XHR
you should say how many packages there are in response to a search
change from "snapshot" to "zip file", depending. ("download" i guess if it's not a zip)
don't let people enter blank version numbers

View File

@ -1126,4 +1126,7 @@
(div ((class "search-results"))
,@(maybe-splice
(or (pair? tags) (not (equal? search-text "")))
(package-summary-table (package-search search-text tags)))))))))
(let ((package-name-list (package-search search-text tags)))
`(div
(p ((class "package-count")) ,(format "~a packages found" (length package-name-list)))
,(package-summary-table package-name-list))))))))))

View File

@ -59,7 +59,12 @@ ul.module-list {
list-style: none; padding: 0;
}
.search-results table { margin-top: 3em; }
.search-results { margin-top: 3em; }
.search-results .package-count {
font-size: 100%;
padding: 0.5em;
background: #eee;
}
input#new_version {
width: 6em;