diff options
author | pdp8 <pdp8@pdp8.info> | 2023-06-21 22:09:25 +0200 |
---|---|---|
committer | pdp8 <pdp8@pdp8.info> | 2023-06-21 22:09:25 +0200 |
commit | cec92f7d472c53bdd5d2aa480179ee30c27e8b38 (patch) | |
tree | b5eec23ed5ad27eeb72b649881ebc6d6308acdbe /views | |
parent | 457a0bfdc74ed90b77d09d285281abca8a1396de (diff) |
pdp8 notes included in threads, client helpers moved to client.rb
Diffstat (limited to 'views')
-rw-r--r-- | views/item.erb | 26 |
1 files changed, 14 insertions, 12 deletions
diff --git a/views/item.erb b/views/item.erb index 933fe71..287054e 100644 --- a/views/item.erb +++ b/views/item.erb @@ -1,21 +1,23 @@ <div style='margin-left:<%= @item[:indent] %>em' id='<%= @item[:nr] %>'> <b><a href='<%= @item[:actor_url] %>', target='_blank'><%= @item[:mention] %></a></b> - <form action='<%= File.join @item[:follow], @item[:mention] %>' method='post'> - <button><%= @item[:follow].capitalize %></button> - </form> - - <form action='/delete' method='post'> - <input type='hidden' name='file' value='<%= @item[:file] %>' /> - <input type='hidden' name='redirect' value='/<%= @dir.sub('inbox','') %>#<%= @item[:nr] %>' /> - <button>Delete</button> - </form> - <% if @dir == 'inbox' %> + <% if @item[:mention] != ACCOUNT %> + <form action='<%= File.join @item[:follow], @item[:mention] %>' method='post'> + <button><%= @item[:follow].capitalize %></button> + </form> - <form action='/archive' method='post'> + <form action='/delete' method='post'> <input type='hidden' name='file' value='<%= @item[:file] %>' /> <input type='hidden' name='redirect' value='/<%= @dir.sub('inbox','') %>#<%= @item[:nr] %>' /> - <button>Archive</button> + <button>Delete</button> </form> + <% if @dir == 'inbox' %> + + <form action='/archive' method='post'> + <input type='hidden' name='file' value='<%= @item[:file] %>' /> + <input type='hidden' name='redirect' value='/<%= @dir.sub('inbox','') %>#<%= @item[:nr] %>' /> + <button>Archive</button> + </form> + <% end %> <% end %> <%= @item[:content] %> <% if @item[:attachment] |