1/** 2 * @file 3 * This file overrides the way jQuery UI focus trap works. 4 * 5 * When a focus event is fired while a CKEditor 5 instance is focused, do not 6 * trap the focus and let CKEditor 5 manage that focus. 7 */ 8 9(($) => { 10 $.widget('ui.dialog', $.ui.dialog, { 11 // Override core override of jQuery UI's `_allowInteraction()` so that 12 // CKEditor 5 in modals can work as expected. 13 // @see https://api.jqueryui.com/dialog/#method-_allowInteraction 14 _allowInteraction(event) { 15 // Fixes "Uncaught TypeError: event.target.classList is undefined" 16 // in Firefox (only). 17 // @see https://www.drupal.org/project/drupal/issues/3351600 18 if (event.target.classList === undefined) { 19 return this._super(event); 20 } 21 return event.target.classList.contains('ck') || this._super(event); 22 }, 23 }); 24})(jQuery);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.