update things

This commit is contained in:
zack 2024-10-26 22:38:41 -04:00
parent 984a193c5d
commit b2f2f57029
No known key found for this signature in database
GPG key ID: 5F873416BCF59F35
6 changed files with 27 additions and 9 deletions

View file

@ -2,9 +2,11 @@
<%= @gist.title || "Gist: #{@gist.id}" %>
<:subtitle>This is a gist record from your database.</:subtitle>
<:actions>
<.link patch={~p"/gists/#{@gist}/show/edit"} phx-click={JS.push_focus()}>
<.button>Edit gist</.button>
</.link>
<%= if(@current_user && @gist.author.email == @current_user.email) do %>
<.link patch={~p"/gists/#{@gist}/show/edit"} phx-click={JS.push_focus()}>
<.button>Edit gist</.button>
</.link>
<% end %>
</:actions>
</.header>