core/modules/ckeditor/js/ckeditor.drupalimage.admin.js | 7 ++++++- core/modules/editor/editor.admin.inc | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/core/modules/ckeditor/js/ckeditor.drupalimage.admin.js b/core/modules/ckeditor/js/ckeditor.drupalimage.admin.js index da0d7e8..ec093ab 100644 --- a/core/modules/ckeditor/js/ckeditor.drupalimage.admin.js +++ b/core/modules/ckeditor/js/ckeditor.drupalimage.admin.js @@ -39,6 +39,7 @@ Drupal.behaviors.ckeditorDrupalImageSettingsSummary = { attach: function () { $('#edit-editor-settings-plugins-drupalimage').drupalSetSummary(function (context) { var root = 'input[name="editor[settings][plugins][drupalimage][image_upload]'; + var $status = $(root + '[status]"]'); var $maxFileSize = $(root + '[max_size]"]'); var $maxWidth = $(root + '[max_dimensions][width]"]'); var $maxHeight = $(root + '[max_dimensions][height]"]'); @@ -47,8 +48,12 @@ Drupal.behaviors.ckeditorDrupalImageSettingsSummary = { var maxFileSize = $maxFileSize.val() ? $maxFileSize.val() : $maxFileSize.attr('placeholder'); var maxDimensions = ($maxWidth.val() && $maxHeight.val()) ? '(' + $maxWidth.val() + 'x' + $maxHeight.val() + ')' : ''; + if (!$status.is(':checked')) { + return Drupal.t('Uploads disabled'); + } + var output = ''; - output += Drupal.t('Max image size: @size @dimensions', { '@size': maxFileSize, '@dimensions': maxDimensions }); + output += Drupal.t('Uploads enabled, max size: @size @dimensions', { '@size': maxFileSize, '@dimensions': maxDimensions }); if ($scheme.length) { output += '
' + $scheme.attr('data-label'); } diff --git a/core/modules/editor/editor.admin.inc b/core/modules/editor/editor.admin.inc index 5af5ac0..9089ac3 100644 --- a/core/modules/editor/editor.admin.inc +++ b/core/modules/editor/editor.admin.inc @@ -37,7 +37,7 @@ function editor_image_upload_settings_form(Editor $editor) { $form['status'] = array( '#type' => 'checkbox', - '#title' => t('Allow image uploads'), + '#title' => t('Enable image uploads'), '#default_value' => $editor->image_upload['status'], '#attributes' => array( 'data-editor-image-upload' => 'status',