From 44a7b0788ea65f8348c7003285d2e4d9de323f01 Mon Sep 17 00:00:00 2001 From: Marcin Kulik Date: Wed, 14 Aug 2013 19:38:01 +0200 Subject: [PATCH] Convert asciicasts#_preview to slim --- app/views/asciicasts/_preview.html.erb | 18 ------------------ app/views/asciicasts/_preview.html.slim | 12 ++++++++++++ 2 files changed, 12 insertions(+), 18 deletions(-) delete mode 100644 app/views/asciicasts/_preview.html.erb create mode 100644 app/views/asciicasts/_preview.html.slim diff --git a/app/views/asciicasts/_preview.html.erb b/app/views/asciicasts/_preview.html.erb deleted file mode 100644 index 1434f1c..0000000 --- a/app/views/asciicasts/_preview.html.erb +++ /dev/null @@ -1,18 +0,0 @@ -<% cache ['thumbnail', asciicast] do %> -
- <%= link_to asciicast, :class => 'preview-link' do %> -
-
<%= asciicast.thumbnail(30, 10) %>
- <% end -%> - -
-

- <%= link_to asciicast.title, asciicast %> -

- -

- <%= time_ago_tag asciicast.created_at %> by <%= asciicast.author_link %> -

-
-
-<% end -%> diff --git a/app/views/asciicasts/_preview.html.slim b/app/views/asciicasts/_preview.html.slim new file mode 100644 index 0000000..7f11360 --- /dev/null +++ b/app/views/asciicasts/_preview.html.slim @@ -0,0 +1,12 @@ +- cache ['thumbnail', asciicast] do + .presentation + = link_to asciicast, :class => 'preview-link' do + .play-button + .arrow + | ► + .thumbnail = asciicast.thumbnail(30, 10) + + .info + h3 = link_to asciicast.title, asciicast + p.date + | #{time_ago_tag asciicast.created_at} by #{asciicast.author_link}