Index: src/js/_enqueues/admin/privacy-tools.js =================================================================== --- src/js/_enqueues/admin/privacy-tools.js (revision 47383) +++ src/js/_enqueues/admin/privacy-tools.js (working copy) @@ -250,8 +250,12 @@ // Privacy policy page, copy button. $( document ).on( 'click', function( event ) { - var $target = $( event.target ); - var $parent, $container, range; + var $parent, + $container, + range, + __ = wp.i18n.__, + $target = $( event.target ), + copiedNotice = $target.siblings( '.success' ); if ( $target.is( 'button.privacy-text-copy' ) ) { $parent = $target.parent().parent(); @@ -271,8 +275,13 @@ window.getSelection().addRange( range ); document.execCommand( 'copy' ); + copiedNotice.addClass( 'visible' ); + wp.a11y.speak( __( 'The section has been copied to your clipboard.' ) ); + $container.removeClass( 'hide-privacy-policy-tutorial' ); window.getSelection().removeAllRanges(); + + setTimeout( function(){ copiedNotice.removeClass( 'visible' ); }, 3000 ); } catch ( er ) {} } } Index: src/wp-admin/css/edit.css =================================================================== --- src/wp-admin/css/edit.css (revision 47383) +++ src/wp-admin/css/edit.css (working copy) @@ -728,6 +728,18 @@ padding-bottom: 6px; } +.privacy-text-actions .success { + display: none; + color: #40860a; + float: right; + padding-right: 1em; +} + +.privacy-text-actions .success.visible { + display: inline-block; + height: 32px; +} + .wp-privacy-policy-guide .policy-text h2 { margin: 1.2em 0 1em; padding: 0; Index: src/wp-admin/includes/class-wp-privacy-policy-content.php =================================================================== --- src/wp-admin/includes/class-wp-privacy-policy-content.php (revision 47383) +++ src/wp-admin/includes/class-wp-privacy-policy-content.php (working copy) @@ -372,12 +372,9 @@ public static function privacy_policy_guide() { $content_array = self::get_suggested_policy_text(); - $content = ''; $toc = array( '
' . sprintf( $removed, $date ) . '