2 * DO NOT EDIT THIS FILE.
3 * See the following change record for more information,
4 * https://www.drupal.org/node/2815083
8 (function ($, Drupal) {
9 Drupal.behaviors.mediaFormSummaries = {
10 attach: function attach(context) {
11 var $context = $(context);
13 $context.find('.media-form-author').drupalSetSummary(function (context) {
14 var $authorContext = $(context);
15 var name = $authorContext.find('.field--name-uid input').val();
16 var date = $authorContext.find('.field--name-created input').val();
19 return Drupal.t('By @name on @date', { '@name': name, '@date': date });
21 return Drupal.t('By @name', { '@name': name });
23 return Drupal.t('Authored on @date', { '@date': date });