From 7f6325fe213ed46ff5479ffd34b0e212426d48f2 Mon Sep 17 00:00:00 2001 From: Ken D'Ambrosio Date: Mon, 8 Jun 2026 21:09:47 +0000 Subject: Add people cluster detail page with face move/merge and hover preview Each cluster in /admin/people now links to a detail page showing all faces in a grid. From there you can rename the cluster, move individual faces to another named person (or spin off a new cluster), or merge the entire cluster into another. Hovering any face crop shows the original full photo for context. Co-Authored-By: Claude Sonnet 4.6 --- views/admin/person_detail.erb | 107 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 107 insertions(+) create mode 100644 views/admin/person_detail.erb (limited to 'views/admin/person_detail.erb') diff --git a/views/admin/person_detail.erb b/views/admin/person_detail.erb new file mode 100644 index 0000000..448aaff --- /dev/null +++ b/views/admin/person_detail.erb @@ -0,0 +1,107 @@ +
+
+ ← All Clusters + <% if @name %> + Public Page ↗ + <% end %> +
+ +

<%= @name ? ERB::Util.html_escape(@name) : 'Unnamed cluster' %>

+

<%= @count %> photo<%= @count == 1 ? '' : 's' %> in this cluster

+ + <%# ── Name ────────────────────────────────────────────────────────────── %> +
+
+ + +
+
+ + <%# ── Merge entire cluster ────────────────────────────────────────────── %> + <% unless @all_others.empty? %> +
+

Merge entire cluster into another person

+

Moves all <%= @count %> photos and removes this cluster.

+
+ + +
+
+ <% end %> + + <%# ── Face grid ────────────────────────────────────────────────────────── %> +

+ Hover a face to see the full photo. + Click to open in the album. + <% unless @named_others.empty? %>Use the drop-down to move a face to another person.<% end %> +

+ +
+ <% @members.each do |m| %> + <% rel = m['rel']; box = m['box'] %> + <% parts = rel.split('/'); fname = parts.last; dir_rel = parts[0..-2].join('/') %> + <% album_url = dir_rel.empty? ? '/browse/' : "/browse/#{ERB::Util.html_escape(dir_rel)}" %> +
+
+ + + +
+ <% unless @named_others.empty? %> +
+ + + +
+ <% end %> +
+ <% end %> +
+
+ +
+ + -- cgit v1.2.3