[openstreetmap/openstreetmap-website] Show tag changes in object history view (PR #6448)

Minh Nguyễn notifications at github.com
Fri Oct 24 19:31:34 UTC 2025


@1ec5 commented on this pull request.



> +    when :unmodified
+      "diff-indicator-cell diff-unmodified"
+    else
+      "diff-indicator-cell"
+    end
+  end
+
+  def format_tag_row_with_change(key, change_info)
+    case change_info[:type]
+    when :modified
+      # Generate two rows for modified tags
+      value_cells = format_tag_value_with_change(key, change_info)
+      [
+        tag.tr(:class => tag_change_class(change_info[:type])) do
+          safe_join([
+                      tag.th(format_key(key), :class => "diff-key-modified", :rowspan => 2),

How does the rowspan interact with the Wikidata preview, which normally adds a row below the existing row?

> +.diff-indicator-cell.diff-removed {
+  background-color: var(--bs-danger);
+}
+
+.diff-indicator-cell.diff-unmodified {
+  background-color: var(--bs-border-color);
+  color: var(--bs-body-color);
+}
+
+.diff-cell {
+  padding: 0.25rem 0.5rem !important;
+}
+
+/* Modified tag key cell styling */
+.diff-key-modified {
+  color: var(--bs-body-color) !important;

What if the rightmost column still has a red or green background like you originally had, while the key column remains yellow? It would make the relationship between the ± column and this column a little clearer. (I realize this is going back and forth to an older design, so feel free to ignore this suggestion if it isn’t a good tradeoff.)

-- 
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/6448#pullrequestreview-3378505734
You are receiving this because you are subscribed to this thread.

Message ID: <openstreetmap/openstreetmap-website/pull/6448/review/3378505734 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20251024/e7005d2c/attachment.htm>


More information about the rails-dev mailing list