From 50ca5e40f461290a2db7452b95f80dd3188dba1d Mon Sep 17 00:00:00 2001 From: erdgeist Date: Fri, 24 Jul 2026 18:04:56 +0200 Subject: Rename layout classes to what they actually do --- app/views/assets/show.html.erb | 44 +++++++++++++++++++++--------------------- 1 file changed, 22 insertions(+), 22 deletions(-) (limited to 'app/views/assets/show.html.erb') diff --git a/app/views/assets/show.html.erb b/app/views/assets/show.html.erb index 122b44e4..4ec77dff 100644 --- a/app/views/assets/show.html.erb +++ b/app/views/assets/show.html.erb @@ -1,16 +1,16 @@ -
+

<%= @asset.name %>

-
Actions
-
-
-
+
Actions
+
+
+
<%= link_to edit_asset_path(@asset), class: 'action_button' do %> <%= icon("edit", library: "tabler", "aria-hidden": true) %> Edit <% end %>
-
+
<%= link_to 'Back', assets_path %>
<%= link_to admin_log_path(:asset_id => @asset.id), :class => "action_button" do %> @@ -20,12 +20,12 @@
<% if @asset.has_variant?(:medium) %> -
Thumbnail
-
<%= image_tag @asset.upload.url(:medium), style: "max-width: 300px; max-height: 300px;" %>
+
Thumbnail
+
<%= image_tag @asset.upload.url(:medium), style: "max-width: 300px; max-height: 300px;" %>
<% end %> -
Attached to
-
+
Attached to
+
<% nodes = @asset.attached_nodes %> <% if nodes.any? %>
    @@ -49,8 +49,8 @@ <% end %>
-
Public Path
-
+
Public Path
+
<% public_path = @asset.upload.url.sub(/\?\d+$/, "") %> <%= link_to public_path, public_path, target: "_blank", rel: "noopener" %>
-
Creator
-
<%= @asset.creator.presence || "—" %>
+
Creator
+
<%= @asset.creator.presence || "—" %>
-
Source
-
+
Source
+
<% if @asset.source_url.present? %> <%= link_to @asset.source_url, @asset.source_url %> <% else %> @@ -72,8 +72,8 @@ <% end %>
-
License
-
+
License
+
<% if (license = AssetLicense.find(@asset.license_key)) %> <%= t("asset_licenses.#{license.key}") %> <% else %> @@ -81,10 +81,10 @@ <% end %>
-
Content Type
-
<%= @asset.upload.content_type %>
+
Content Type
+
<%= @asset.upload.content_type %>
-
Size
-
<%= "#{@asset.upload.size/1024} KB" %>
+
Size
+
<%= "#{@asset.upload.size/1024} KB" %>
-- cgit v1.3