diff --git a/assets/js/app.js b/assets/js/app.js
index 1b904f1c..3aee4d34 100644
--- a/assets/js/app.js
+++ b/assets/js/app.js
@@ -15,7 +15,7 @@ import "../node_modules/bootstrap-icons/icons/box-arrow-right.svg"; // log out
import "../node_modules/bootstrap-icons/icons/at.svg";
import "../node_modules/bootstrap-icons/icons/key.svg";
import "../node_modules/bootstrap-icons/icons/key-fill.svg";
-import "../node_modules/bootstrap-icons/icons/envelope.svg";
+import "../node_modules/bootstrap-icons/icons/arrow-repeat.svg";
// webpack automatically bundles all modules in your
// entry points. Those entry points can be configured
diff --git a/lib/bones73k_web/templates/user_confirmation/new.html.eex b/lib/bones73k_web/templates/user_confirmation/new.html.eex
index 803080f9..3ce96081 100644
--- a/lib/bones73k_web/templates/user_confirmation/new.html.eex
+++ b/lib/bones73k_web/templates/user_confirmation/new.html.eex
@@ -1,15 +1,40 @@
-
+
-<%= form_for :user, Routes.user_confirmation_path(@conn, :create), fn f -> %>
- <%= label f, :email %>
- <%= email_input f, :email, required: true %>
+
+ <%= icon_div @conn, "bi-arrow-repeat", [class: "icon baseline"] %>
+ Resend confirmation instructions
+
+
We'll send you another email with a link to confirm your email address.
+
+ <%= form_for :user, Routes.user_confirmation_path(@conn, :create), [class: "needs-validation", novalidate: true], fn f -> %>
+
+ <%= label f, :email, class: "form-label" %>
+
+
+ <%= icon_div @conn, "bi-at", [class: "icon fs-5"] %>
+
+ <%= email_input f, :email,
+ value: @current_user && @current_user.email || "",
+ placeholder: "e.g., babka@73k.us",
+ class: "form-control",
+ maxlength: User.max_email,
+ required: true,
+ autofocus: !@current_user
+ %>
+ must be a valid email address
+
+
+
+ <%= submit "Resend confirmation instructions", class: "btn btn-primary" %>
+
+
+ <% end %>
+
+
+ <%= link "Register", to: Routes.user_registration_path(@conn, :new) %> |
+ <%= link "Log in", to: Routes.user_session_path(@conn, :new) %>
+
-
- <%= submit "Resend confirmation instructions" %>
-<% end %>
-
-
- <%= link "Register", to: Routes.user_registration_path(@conn, :new) %> |
- <%= link "Log in", to: Routes.user_session_path(@conn, :new) %>
-
+
diff --git a/lib/bones73k_web/views/user_confirmation_view.ex b/lib/bones73k_web/views/user_confirmation_view.ex
index 7ba1a84c..3001318f 100644
--- a/lib/bones73k_web/views/user_confirmation_view.ex
+++ b/lib/bones73k_web/views/user_confirmation_view.ex
@@ -1,3 +1,4 @@
defmodule Bones73kWeb.UserConfirmationView do
use Bones73kWeb, :view
+ alias Bones73k.Accounts.User
end
diff --git a/test/bones73k_web/controllers/user_confirmation_controller_test.exs b/test/bones73k_web/controllers/user_confirmation_controller_test.exs
index bc0ea4f2..16813066 100644
--- a/test/bones73k_web/controllers/user_confirmation_controller_test.exs
+++ b/test/bones73k_web/controllers/user_confirmation_controller_test.exs
@@ -13,7 +13,7 @@ defmodule Bones73kWeb.UserConfirmationControllerTest do
test "renders the confirmation page", %{conn: conn} do
conn = get(conn, Routes.user_confirmation_path(conn, :new))
response = html_response(conn, 200)
- assert response =~ "
Resend confirmation instructions
"
+ assert response =~ "Resend confirmation instructions\n "
end
end