Updated Drupal to 8.6. This goes with the following updates because it's possible...
[yaffs-website] / web / core / modules / ckeditor / js / ckeditor.drupalimage.admin.js
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
8 (function ($, Drupal, drupalSettings) {
9   Drupal.behaviors.ckeditorDrupalImageSettingsSummary = {
10     attach: function attach() {
11       $('[data-ckeditor-plugin-id="drupalimage"]').drupalSetSummary(function (context) {
12         var root = 'input[name="editor[settings][plugins][drupalimage][image_upload]';
13         var $status = $(root + '[status]"]');
14         var $maxFileSize = $(root + '[max_size]"]');
15         var $maxWidth = $(root + '[max_dimensions][width]"]');
16         var $maxHeight = $(root + '[max_dimensions][height]"]');
17         var $scheme = $(root + '[scheme]"]:checked');
18
19         var maxFileSize = $maxFileSize.val() ? $maxFileSize.val() : $maxFileSize.attr('placeholder');
20         var maxDimensions = $maxWidth.val() && $maxHeight.val() ? '(' + $maxWidth.val() + 'x' + $maxHeight.val() + ')' : '';
21
22         if (!$status.is(':checked')) {
23           return Drupal.t('Uploads disabled');
24         }
25
26         var output = '';
27         output += Drupal.t('Uploads enabled, max size: @size @dimensions', {
28           '@size': maxFileSize,
29           '@dimensions': maxDimensions
30         });
31         if ($scheme.length) {
32           output += '<br />' + $scheme.attr('data-label');
33         }
34         return output;
35       });
36     }
37   };
38 })(jQuery, Drupal, drupalSettings);