From 8957808536e53bb9329cb6ae12835fde7835210b Mon Sep 17 00:00:00 2001 From: erdgeist Date: Sat, 27 Jun 2026 21:43:55 +0200 Subject: Stage 7 click-testing fixes (2) - nodes_controller: permit staged_slug and staged_parent_id in node params; these were silently dropped since strong parameters migration, breaking the two-phase slug/parent change workflow - file_attachment: add SVG support; vector files are copied to all style directories without rasterisation, preserving scalability in the browser - assets index/show: constrain image display with max-width/max-height via admin.css td img rule; fixes oversized SVG thumbnails while leaving raster variants unaffected --- app/views/assets/index.html.erb | 2 +- app/views/assets/show.html.erb | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'app/views') diff --git a/app/views/assets/index.html.erb b/app/views/assets/index.html.erb index 83d55c2..51fc486 100644 --- a/app/views/assets/index.html.erb +++ b/app/views/assets/index.html.erb @@ -10,7 +10,7 @@ <% @assets.each do |asset| %> - <%= image_tag asset.upload.url(:thumb) %> + <%= image_tag asset.upload.url(:thumb), style: "max-width: 100px; max-height: 100px;" %> <%= link_to asset.name, asset.upload.url %> <%= asset.upload.content_type %> <%= link_to 'Show', asset %> diff --git a/app/views/assets/show.html.erb b/app/views/assets/show.html.erb index a64987c..694be5a 100644 --- a/app/views/assets/show.html.erb +++ b/app/views/assets/show.html.erb @@ -6,7 +6,7 @@ - + @@ -20,4 +20,4 @@ -
Thumbnail<%= image_tag @asset.upload.url(:medium) %><%= image_tag @asset.upload.url(:medium), style: "max-width: 300px; max-height: 300px;" %>
Public PathSize <%= "#{@asset.upload.size/1024} KB" %>
\ No newline at end of file + -- cgit v1.3