~reykjalin/inner_circle

b9d3d31acaabbada5e5f8c1efbcd07408180c115 — Kristófer R 7 months ago 55b0fba main
Expand new post body while typing
1 files changed, 6 insertions(+), 1 deletions(-)

M lib/inner_circle_web/live/create_post_live/index.html.heex
M lib/inner_circle_web/live/create_post_live/index.html.heex => lib/inner_circle_web/live/create_post_live/index.html.heex +6 -1
@@ 11,7 11,12 @@
    >

    <%= label f, :body, class: "font-bold" %>
    <%= textarea f, :body, autofocus: true, class: "border px-4 py-3 mb-5" %>
    <%= textarea f,
      :body,
      autofocus: true,
      class: "border px-4 py-3 mb-5",
      rows: max(String.split(Map.get(@changeset.changes, :body, ""), "\n") |> length(), 5) |> Integer.to_string()
    %>
    <%= error_tag f, :body %>

    <p class="my-5">