diff --git a/app/views/packages/index-list.slim b/app/views/packages/index-list.slim index 1a4e4c8..3619c3a 100644 --- a/app/views/packages/index-list.slim +++ b/app/views/packages/index-list.slim @@ -20,13 +20,13 @@ =pkg.name ' > - if pkg.screenshots.any? - // TODO: smarter search for the beste screenshot instead of taking the first one + // TODO: smarter search for the best screenshot instead of taking the first one - screenshot = pkg.screenshots.first - a.black.fancybox title=screenshot.caption rel=pkg.id href=screenshot.image.url(:large, timestamp: false) + a.black title=screenshot.caption href=package_path(name: pkg.name) = image_tag(screenshot.image.url(:large, timestamp: false), alt: screenshot.caption) - if pkg.screenshots.length > 1 a.black href=package_path(name: pkg.name) - .text-center More screenshots… + .text-center and #{pluralize(pkg.screenshots.length-1, 'screenshot')} more… - else a href=upload_package_by_name_path(name: pkg.name) img.screenshot src="/images/dummy/no-screenshots-upload-one.svg"