1/** 2* DO NOT EDIT THIS FILE. 3* See the following change record for more information, 4* https://www.drupal.org/node/2815083 5* @preserve 6**/ 7(function ($, Drupal, drupalSettings) { 8 var ids = []; 9 Drupal.behaviors.copyFieldValue = { 10 attach: function attach(context) { 11 Object.keys(drupalSettings.copyFieldValue || {}).forEach(function (element) { 12 ids.push(element); 13 }); 14 if (ids.length) { 15 $(once('copy-field-values', 'body')).on('value:copy', this.valueTargetCopyHandler); 16 $(once('copy-field-values', "#".concat(ids.join(', #')))).on('blur', this.valueSourceBlurHandler); 17 } 18 }, 19 detach: function detach(context, settings, trigger) { 20 if (trigger === 'unload' && ids.length) { 21 $(once.remove('copy-field-values', 'body')).off('value:copy'); 22 $(once.remove('copy-field-values', "#".concat(ids.join(', #')))).off('blur'); 23 } 24 }, 25 valueTargetCopyHandler: function valueTargetCopyHandler(e, value) { 26 var target = e.target; 27 if (target.value === '') { 28 target.value = value; 29 } 30 }, 31 valueSourceBlurHandler: function valueSourceBlurHandler(e) { 32 var value = e.target.value; 33 var targetIds = drupalSettings.copyFieldValue[e.target.id]; 34 $("#".concat(targetIds.join(', #'))).trigger('value:copy', value); 35 } 36 }; 37})(jQuery, Drupal, drupalSettings);
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.