feature/share-libs
erb 81 lines 3.3 KB
Raw
1 <% content_for :meta_head do %>
2 <title><%= @meta_title %></title>
3 <meta name="description" content="<%= @meta_description %>">
4 <meta property="og:title" content="<%= @meta_title %>" />
5 <meta property="og:description" content="<%= @meta_description %>" />
6 <meta property="og:url" content="<%= guitar_chord_detail_url(@song.slug) %>" />
7 <% end %>
8 <% content_for :breadcrumb do %>
9 <script type="application/ld+json">
10 {
11 "@context": "http://schema.org",
12 "@type": "BreadcrumbList",
13 "itemListElement": [{
14 "@type": "ListItem",
15 "position": 1,
16 "item": {
17 "@id": "<%= root_url %>",
18 "name": "Musik 88"
19 }
20 },{
21 "@type": "ListItem",
22 "position": 2,
23 "item": {
24 "@id": "<%= artist_url %>",
25 "name": "<%= t("nav_artists") %>"
26 }
27 },{
28 "@type": "ListItem",
29 "position": 3,
30 "item": {
31 "@id": "<%= artist_detail_url(@song.album.artists[0].name.downcase.parameterize + "-" + @song.album.artists[0].id.to_s) %>",
32 "name": "<%= @song.album.artists[0].name %>"
33 }
34 },{
35 "@type": "ListItem",
36 "position": 4,
37 "item": {
38 "@id": "<%= album_detail_url(@song.album.name.downcase.parameterize + '-' + @song.album.artists[0].name.downcase.parameterize + "-" + @song.album.id.to_s) %>",
39 "name": "<%= @song.album.name %>"
40 }
41 },{
42 "@type": "ListItem",
43 "position": 5,
44 "item": {
45 "@id": "<%= guitar_chord_detail_url(@song.slug) %>",
46 "name": "<%= t("guitar_chord") + @song.name + " " + @song.album.artists[0].name + " " + @song.album.name %>"
47 }
48 }]
49 }
50 </script>
51 <% end %>
52 <%= render("partial_menus_aside", active_menu: 'karaoke' ) %>
53 <div class="row">
54 <div class="col-md-8">
55 <div class="blog-post-single content-row chord-content">
56 <h1 class="post-heading"><%= @page_title %></h1>
57 <%= render("partial_meta_top") %>
58 <% @song.audio_files.each_with_index do |audio_file, index| %>
59 <% next if audio_file.karaoke_file.nil? %>
60 <div class="buttons-wrap" style="width: 110px;background-color: inherit;">
61 <audio controls>
62 <source src="<%= audio_file.karaoke_file.source_file.blob %>" type="audio/wav">
63 Your browser does not support the audio tag.
64 </audio>
65 <%= link_to("<i class='icon-download'></i> Download".html_safe, rails_blob_path(audio_file.karaoke_file.source_file, disposition: "attachment"))%>
66 </div>
67 <% end %>
68 <% if @song.audio_files.count == 0 %>
69 <div>
70 <%= @shown_text.html_safe %>
71 </div>
72 <% end %>
73 </div>
74 </div>
75 </div>
76 <%= render "shared/partial_breadcrumbs" do %>
77 <li class="breadcrumb-item"><%= link_to t("nav_artists"), artist_url %></li>
78 <li class="breadcrumb-item"><%= link_to @song.album.artists[0].name, artist_detail_url(@song.album.artists[0].name.downcase.parameterize + "-" + @song.album.artists[0].id.to_s) %></li>
79 <li class="breadcrumb-item"><%= link_to @song.album.name, album_detail_url(@song.album.name.downcase.parameterize + '-' + @song.album.artists[0].name.downcase.parameterize + "-" + @song.album.id.to_s) %></li>
80 <li class="breadcrumb-item"><%= link_to @song.name, guitar_chord_detail_url(@song.slug) %></li>
81 <% end %>