Making WordPress.org

Opened 8 years ago

Closed 6 years ago

Last modified 6 years ago

#1504 closed enhancement (fixed)

Improve functionality surrounding comment examples in the developer reference

Reported by: netweb's profile netweb Owned by:
Milestone: Priority: normal
Component: Developer Hub Keywords: has-screenshots has-patch
Cc:

Description

I just hit upon an "example" on the developer reference that is not correct:
https://developer.wordpress.org/reference/functions/register_post_type/#comment-925

In the example linked the comment mentions that with_front default is false, in fact the default is true

At the moment all I can do is downvote the example comment, there is no way to provide context or feedback to the original user the reason for down voting their example.

The original author is also unable to edit or update their example.

Some ideas for improving this functionality:

  • Maybe allow replies to examples so feedback can be added (i.e. You could reply and explain your down vote)
  • Allow authors to edit and update their examples.

Attachments (7)

notes.png (59.0 KB) - added by keesiemeijer 8 years ago.
Notes with links to add or display feedback
notes-expanded.png (88.0 KB) - added by keesiemeijer 8 years ago.
Notes expanded
note-with-feedback-and-editor.png (112.6 KB) - added by keesiemeijer 8 years ago.
Note expanded with feedback and feedback editor
1504.patch (40.3 KB) - added by keesiemeijer 8 years ago.
First pass of adding feedback to user contributed notes
1504.notes.png (218.5 KB) - added by keesiemeijer 8 years ago.
1504.patch feedback notes
1504.1.patch (41.4 KB) - added by keesiemeijer 8 years ago.
Clean up of patch
1504.2.patch (41.5 KB) - added by keesiemeijer 8 years ago.
Updates for Internet Explorer

Download all attachments as: .zip

Change History (21)

#1 @SergeyBiryukov
8 years ago

Also, the author name for that comment is empty for some reason.

#2 @netweb
8 years ago

Related but not quite the same:

  • #607 Add information about error reporting in the code reference
  • #981 Create feedback form for devhub

This ticket was mentioned in Slack in #meta-devhub by drew. View the logs.


8 years ago

#4 @keesiemeijer
8 years ago

This ticket was discussed in Slack.
https://wordpress.slack.com/archives/meta-devhub/p1470161139000258

Users should be able to edit and add feedback on notes in the front end by creating new endpoints like reference/contributer-note/33434 and reference/contributer-note/33434/edit.
Edits to a note should be sent into moderation. For now, users should be given the ability to edit their own notes while it's in moderation. At a later time, when we start auto-approving comments based on X-number of approved comments, we should grant these users the ability to edit-after-publish for a set time duration.

#5 @keesiemeijer
8 years ago

I've been playing around with adding feedback (replying) to notes in the single post page itself. I was wondering if the notes would get too cluttered or unintuitive if we did it this way instead of adding new endpoints.

This is what I've done so far:

  • Note feedback is added to the note itself but is hidden if Javascript is enabled.
  • Use a separate editor for adding feedback with only the strong, em, and inline code buttons (and no preview).

A drawback is that you can't link directly (with a #) to feedback notes that are hidden. The following screenshots will give you an idea.

Feedback for this approach is appreciated :)

Last edited 8 years ago by keesiemeijer (previous) (diff)

@keesiemeijer
8 years ago

Notes with links to add or display feedback

@keesiemeijer
8 years ago

Notes expanded

@keesiemeijer
8 years ago

Note expanded with feedback and feedback editor

#6 @keesiemeijer
8 years ago

  • Keywords has-screenshots added

This ticket was mentioned in Slack in #meta-devhub by coffee2code. View the logs.


8 years ago

@keesiemeijer
8 years ago

First pass of adding feedback to user contributed notes

#8 @keesiemeijer
8 years ago

  • Keywords has-patch added

The 1504.patch Is a first pass at adding feedback to user contributed notes. It ditches the wp_list_comments() function (again) to have more control over the display of feedback (child) comments. Feedback comments are nested one level deep. The use of HTML in feedback comments is restricted to <strong>, <em>, <code> and <a>. Newlines are removed. You can also add feedback with this patch if Javascript is disabled.

@keesiemeijer
8 years ago

1504.patch feedback notes

@keesiemeijer
8 years ago

Clean up of patch

@keesiemeijer
8 years ago

Updates for Internet Explorer

#9 @keesiemeijer
8 years ago

Patch 1504.2.patch is tested in all modern browsers. It looks good in ie9 and up, with minor differences. In ie8 there is an error and the JS doesn't apply (jQuery: “Unexpected call to method or property access”). You can still see and add feedback in ie8.

#10 @netweb
8 years ago

Related: #2082 - Enable revisions on the front end for DevHub/HelpHub/Handbook pages

  • Adding revisions to users edited contributor notes on devhub is another potential example of helpful revisions

#11 @coffee2code
6 years ago

In 6910:

developer.wordpress.org: Add support for user feedback on submitted user notes.

Props keesiemeijer.
See #1504.

This ticket was mentioned in Slack in #meta by tellyworth. View the logs.


6 years ago

#13 @netweb
6 years ago

  • Resolution set to fixed
  • Status changed from new to closed

Closing this as fixed, if there is anything else outstanding please create new ticket or tickets please

This ticket was mentioned in Slack in #meta-devhub by drew. View the logs.


6 years ago

Note: See TracTickets for help on using tickets.