mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-12 04:40:26 +00:00
External Libraries: Accessibility: Clean up clipboard.js Copy buttons from focus management workaround.
`clipboard.js` used to suffer from a bug that triggered a focus loss when activating the Copy buttons. The bug was fixed a while ago with the `clipboard.js` 2.0.11 release so that the workaround implemented in WordPress is no longer necessary. Props dhrumilk, paulkevan, afercia. Fixes #60139. git-svn-id: https://develop.svn.wordpress.org/trunk@57231 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -223,8 +223,6 @@
|
||||
|
||||
// Clear the selection and move focus back to the trigger.
|
||||
event.clearSelection();
|
||||
// Handle ClipboardJS focus bug, see https://github.com/zenorocha/clipboard.js/issues/680.
|
||||
triggerElement.trigger( 'focus' );
|
||||
|
||||
// Show success visual feedback.
|
||||
clearTimeout( copyAttachmentURLSuccessTimeout );
|
||||
|
||||
@@ -1303,8 +1303,6 @@ jQuery( function($) {
|
||||
|
||||
// Clear the selection and move focus back to the trigger.
|
||||
event.clearSelection();
|
||||
// Handle ClipboardJS focus bug, see https://github.com/zenorocha/clipboard.js/issues/680
|
||||
triggerElement.trigger( 'focus' );
|
||||
|
||||
// Show success visual feedback.
|
||||
clearTimeout( copyAttachmentURLSuccessTimeout );
|
||||
|
||||
@@ -26,8 +26,6 @@ jQuery( function( $ ) {
|
||||
|
||||
// Clear the selection and move focus back to the trigger.
|
||||
e.clearSelection();
|
||||
// Handle ClipboardJS focus bug, see https://github.com/zenorocha/clipboard.js/issues/680
|
||||
triggerElement.trigger( 'focus' );
|
||||
|
||||
// Show success visual feedback.
|
||||
clearTimeout( successTimeout );
|
||||
|
||||
@@ -380,8 +380,6 @@ function copyAttachmentUploadURLClipboard() {
|
||||
|
||||
// Clear the selection and move focus back to the trigger.
|
||||
event.clearSelection();
|
||||
// Handle ClipboardJS focus bug, see https://github.com/zenorocha/clipboard.js/issues/680
|
||||
triggerElement.trigger( 'focus' );
|
||||
// Show success visual feedback.
|
||||
clearTimeout( successTimeout );
|
||||
successElement.removeClass( 'hidden' );
|
||||
|
||||
@@ -47,8 +47,6 @@ Details = Attachment.extend(/** @lends wp.media.view.Attachment.Details.prototyp
|
||||
|
||||
// Clear the selection and move focus back to the trigger.
|
||||
event.clearSelection();
|
||||
// Handle ClipboardJS focus bug, see https://github.com/zenorocha/clipboard.js/issues/680
|
||||
triggerElement.trigger( 'focus' );
|
||||
|
||||
// Show success visual feedback.
|
||||
clearTimeout( successTimeout );
|
||||
|
||||
Reference in New Issue
Block a user