diff --git a/lib/outlook_web/live/article_live/show.ex b/lib/outlook_web/live/article_live/show.ex index 75f15b4..256d396 100644 --- a/lib/outlook_web/live/article_live/show.ex +++ b/lib/outlook_web/live/article_live/show.ex @@ -11,10 +11,12 @@ defmodule OutlookWeb.ArticleLive.Show do @impl true def handle_params(%{"id" => id}, _, socket) do + article = Articles.get_article_with_translations!(id) {:noreply, socket |> assign(:page_title, page_title(socket.assigns.live_action)) - |> assign(:article, Articles.get_article_with_translations!(id))} + |> assign(:article_content, InternalTree.garnish(article.content, %{tunits: %{class: "tunit"}})) + |> assign(:article, article)} end defp page_title(:show), do: "Show Article" diff --git a/lib/outlook_web/live/article_live/show.html.heex b/lib/outlook_web/live/article_live/show.html.heex index 6d9616c..0b83069 100644 --- a/lib/outlook_web/live/article_live/show.html.heex +++ b/lib/outlook_web/live/article_live/show.html.heex @@ -38,7 +38,7 @@