From d88caf46c876ff8092f6a60c407137d285bd8261 Mon Sep 17 00:00:00 2001
From: alexisben <alexiben7@gmail.com>
Date: Sun, 15 May 2022 18:34:51 +0200
Subject: [PATCH] Bloc embed html

---
 .../communication/blocks/templates/embed/_preview.html.erb  | 3 ++-
 config/locales/communication/en.yml                         | 6 ++++++
 config/locales/communication/fr.yml                         | 6 ++++++
 3 files changed, 14 insertions(+), 1 deletion(-)

diff --git a/app/views/admin/communication/blocks/templates/embed/_preview.html.erb b/app/views/admin/communication/blocks/templates/embed/_preview.html.erb
index 371d5d3ce..560be01fc 100644
--- a/app/views/admin/communication/blocks/templates/embed/_preview.html.erb
+++ b/app/views/admin/communication/blocks/templates/embed/_preview.html.erb
@@ -1 +1,2 @@
-<pre><%= @block.template.code %></pre>
+<%= @block.template.code.html_safe %>
+<p><%= @block.template.transcription %></p>
\ No newline at end of file
diff --git a/config/locales/communication/en.yml b/config/locales/communication/en.yml
index 2cfe8350e..cf74ea0c9 100644
--- a/config/locales/communication/en.yml
+++ b/config/locales/communication/en.yml
@@ -170,6 +170,12 @@ en:
               title_placeholder: Enter title here
               text_label: Text
               text_placeholder: Enter text here
+          embed:
+            edit:
+              code_label: Code du bloc d'intégration HTML
+              code_placeholder: Entrez ici le code
+              transcription_label: Transcription textuelle du contenu
+              transcription_placeholder: Entrez ici la transcription
           gallery:
             edit:
               add_image: Add image
diff --git a/config/locales/communication/fr.yml b/config/locales/communication/fr.yml
index fadcf98a1..f0d22b11a 100644
--- a/config/locales/communication/fr.yml
+++ b/config/locales/communication/fr.yml
@@ -170,6 +170,12 @@ fr:
               title_placeholder: Entrer le titre de la définition
               text_label: Texte
               text_placeholder: Entrer la description de la définition
+          embed:
+            edit:
+              code_label: Code du bloc d'intégration HTML
+              code_placeholder: Entrez ici le code
+              transcription_label: Transcription textuelle du contenu
+              transcription_placeholder: Entrez ici la transcription
           gallery:
             edit:
               add_image: Ajouter une image
-- 
GitLab