[wp-trac] [WordPress Trac] #44588: Denote the Copy action is complete by updating the Copy button to state 'Copied'

WordPress Trac noreply at wordpress.org
Mon Jan 6 07:27:39 UTC 2020


#44588: Denote the Copy action is complete by updating the Copy button to state
'Copied'
-------------------------------------------------+-------------------------
 Reporter:  garrett-eclipse                      |       Owner:  garrett-
                                                 |  eclipse
     Type:  enhancement                          |      Status:  assigned
 Priority:  normal                               |   Milestone:  5.4
Component:  Privacy                              |     Version:  4.9.6
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch has-screenshots needs-     |     Focuses:
  testing dev-feedback 2nd-opinion               |  administration
-------------------------------------------------+-------------------------
Changes (by garrett-eclipse):

 * keywords:  has-patch has-screenshots => has-patch has-screenshots needs-
     testing dev-feedback 2nd-opinion


Comment:

 Thanks for the patch @nickylimjj this is a great start here.

 Reviewing I made a few minor tweaks in
 [https://core.trac.wordpress.org/attachment/ticket/44588/44588.3.diff
 44588.3.diff], they are;
 - Cleanup JS variable creation.
 - Updated JS a11y.speak text to use 'Privacy Policy Guide section' instead
 of 'Privacy Content' to be more specific.
 - Reverted the css class for `.privacy-text-copy-button` back to
 `.privacy-text-copy` in case plugins have styled or targetted it. This is
 to avoid back-compat issues.
 - Cleanup PHP for coding standards on indentation.
 - In the PHP removed unneeded variable instantiations when they are stings
 only being used a single time.

 I'm adding `dev-feedback` / `2nd-opinion` to get thoughts on the copy
 formatting change as you noted it now copies HTML instead of formatted
 text. From my testing this works ok in the block editor as it gets
 converted to blocks, but in the classic editor and classic block it's
 pasted as HTML so you'd need to use the Text tab to paste. As well pasting
 to rich text editors like Word, Pages, etc no longer holds the formatting.
 Personally I'm on the fence as I wasn't a huge fan of the original
 formatted copy but now it's less transferrable.
 *Possibly we can place the headings and paragraphs on new lines so it's
 less a jumble and easier to read.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/44588#comment:17>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list