summaryrefslogtreecommitdiff
path: root/app/views/page_translations/edit.html.erb
diff options
context:
space:
mode:
authorerdgeist <erdgeist@erdgeist.org>2026-07-14 17:25:37 +0200
committererdgeist <erdgeist@erdgeist.org>2026-07-14 18:30:40 +0200
commit6ddc9d73f1299cdeb90bc88ed0bb53821c4825aa (patch)
tree7672dd034ec0bacdaa1534813981a5f5de5a7650 /app/views/page_translations/edit.html.erb
parent8847db139bef9dd8f9465c31438f16af13593267 (diff)
Supply related-asset URLs/name and public inline-image CSS
RelatedAssetsController#create's JSON includes large_url, original_url, and name alongside thumb_url/url; the related-asset list items in both editors carry them as data-large-url, data-original-url, and data-name. ccc.css gets the public-facing .inline-image--full/--half/--left/ --right rules -- admin.css and TinyMCE's content_style cover the cockpit and in-editor renderings respectively.
Diffstat (limited to 'app/views/page_translations/edit.html.erb')
-rw-r--r--app/views/page_translations/edit.html.erb9
1 files changed, 9 insertions, 0 deletions
diff --git a/app/views/page_translations/edit.html.erb b/app/views/page_translations/edit.html.erb
index 0f64d400..00bf221e 100644
--- a/app/views/page_translations/edit.html.erb
+++ b/app/views/page_translations/edit.html.erb
@@ -20,6 +20,15 @@
20</div> 20</div>
21 21
22<div id="page_editor"> 22<div id="page_editor">
23 <ul id="related_asset_list" style="display:none">
24 <% @page.related_assets.includes(:asset).each do |related| %>
25 <li data-large-url="<%= related.asset.upload.url(:large) %>"
26 data-original-url="<%= related.asset.upload.url %>"
27 data-name="<%= related.asset.name %>">
28 <%= image_tag related.asset.upload.url(:thumb) %>
29 </li>
30 <% end %>
31 </ul>
23 <%= form_with url: node_translation_path(@node, @locale), method: :patch, local: true, id: "translation_edit_form", 32 <%= form_with url: node_translation_path(@node, @locale), method: :patch, local: true, id: "translation_edit_form",
24 data: { autosave_url: autosave_node_translation_path(@node, @locale), show_url: node_path(@node) } do |f| %> 33 data: { autosave_url: autosave_node_translation_path(@node, @locale), show_url: node_path(@node) } do |f| %>
25 <div id="content"> 34 <div id="content">