[wp-trac] [WordPress Trac] #47519: Introduce a vertically compact view for the Revisions screen

WordPress Trac noreply at wordpress.org
Mon Jun 10 15:42:25 UTC 2019


#47519: Introduce a vertically compact view for the Revisions screen
----------------------------+--------------------------------------
 Reporter:  johnbillion     |      Owner:  (none)
     Type:  enhancement     |     Status:  new
 Priority:  normal          |  Milestone:  Awaiting Review
Component:  Revisions       |    Version:
 Severity:  normal          |   Keywords:  needs-patch needs-design
  Focuses:  administration  |
----------------------------+--------------------------------------
 Given a post containing a lot of content in many paragraphs, it's not easy
 to quickly find the change made during a particular revision when viewing
 the Revisions screen for the post. The change may be a long way down the
 content and is only identifiable by scrolling until you happen to spot the
 change.

 A traditional diff view in software development only shows the lines
 affected by the change and a handful of lines above and below the change
 to add context. This is the case here on Trac, on other services such as
 GitHub and GitLab, and in `.diff` and `.patch` files themselves.

 A similarly compact diff view should be made available on the Revisions
 screen for posts. I think it would be beneficial to make it the default
 view, with a toggle to switch to the full view for a post if the user
 decides they need to see it.

 The `wp_text_diff()` function and the `WP_Text_Diff_Renderer_Table`
 renderer used on this screen supports parameters for controlling the
 number of contextual lines shown: `leading_context_lines` and
 `trailing_context_lines`.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/47519>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list