Loading core/modules/image/image.libraries.yml +0 −16 Original line number Diff line number Diff line Loading @@ -3,19 +3,3 @@ admin: css: theme: css/image.admin.css: {} quickedit.inPlaceEditor.image: version: VERSION js: js/editors/image.js: {} js/theme.js: {} css: component: css/editors/image.css: {} theme: css/editors/image.theme.css: {} dependencies: - core/jquery - core/drupal - core/internal.underscore - quickedit/quickedit core/modules/image/image.routing.yml +0 −26 Original line number Diff line number Diff line Loading @@ -71,29 +71,3 @@ image.effect_edit_form: route_callbacks: - '\Drupal\image\Routing\ImageStyleRoutes::routes' image.upload: path: '/quickedit/image/upload/{entity_type}/{entity}/{field_name}/{langcode}/{view_mode_id}' defaults: _controller: '\Drupal\image\Controller\QuickEditImageController::upload' options: parameters: entity: type: entity:{entity_type} requirements: _permission: 'access in-place editing' _access_quickedit_entity_field: 'TRUE' _method: 'POST' image.info: path: '/quickedit/image/info/{entity_type}/{entity}/{field_name}/{langcode}/{view_mode_id}' defaults: _controller: '\Drupal\image\Controller\QuickEditImageController::getInfo' options: parameters: entity: type: entity:{entity_type} requirements: _permission: 'access in-place editing' _access_quickedit_entity_field: 'TRUE' _method: 'GET' core/modules/image/js/theme.es6.jsdeleted 100644 → 0 +0 −92 Original line number Diff line number Diff line /** * @file * Provides theme functions for image Quick Edit's client-side HTML. */ (function (Drupal) { /** * Theme function for validation errors of the Image in-place editor. * * @param {object} settings * Settings object used to construct the markup. * @param {string} settings.errors * Already escaped HTML representing error messages. * * @return {string} * The corresponding HTML. */ Drupal.theme.quickeditImageErrors = function (settings) { return `<div class="quickedit-image-errors">${settings.errors}</div>`; }; /** * Theme function for the dropzone element of the Image module's in-place * editor. * * @param {object} settings * Settings object used to construct the markup. * @param {string} settings.state * State of the upload. * @param {string} settings.text * Text to display inline with the dropzone element. * * @return {string} * The corresponding HTML. */ Drupal.theme.quickeditImageDropzone = function (settings) { return ( `<div class="quickedit-image-dropzone ${settings.state}">` + ' <i class="quickedit-image-icon"></i>' + ` <span class="quickedit-image-text">${settings.text}</span>` + '</div>' ); }; /** * Theme function for the toolbar of the Image module's in-place editor. * * @param {object} settings * Settings object used to construct the markup. * @param {bool} settings.alt_field * Whether or not the "Alt" field is enabled for this field. * @param {bool} settings.alt_field_required * Whether or not the "Alt" field is required for this field. * @param {string} settings.alt * The current value for the "Alt" field. * @param {bool} settings.title_field * Whether or not the "Title" field is enabled for this field. * @param {bool} settings.title_field_required * Whether or not the "Title" field is required for this field. * @param {string} settings.title * The current value for the "Title" field. * * @return {string} * The corresponding HTML. */ Drupal.theme.quickeditImageToolbar = function (settings) { let html = '<form class="quickedit-image-field-info">'; if (settings.alt_field) { html += `<div><label for="alt" class="${ settings.alt_field_required ? 'required' : '' }">${Drupal.t('Alternative text')}</label>` + `<input type="text" placeholder="${settings.alt}" value="${ settings.alt }" name="alt" ${settings.alt_field_required ? 'required' : ''}/>` + ' </div>'; } if (settings.title_field) { html += `<div><label for="title" class="${ settings.title_field_required ? 'form-required' : '' }">${Drupal.t('Title')}</label>` + `<input type="text" placeholder="${settings.title}" value="${ settings.title }" name="title" ${settings.title_field_required ? 'required' : ''}/>` + '</div>'; } html += '</form>'; return html; }; })(Drupal); core/modules/image/js/theme.jsdeleted 100644 → 0 +0 −31 Original line number Diff line number Diff line /** * DO NOT EDIT THIS FILE. * See the following change record for more information, * https://www.drupal.org/node/2815083 * @preserve **/ (function (Drupal) { Drupal.theme.quickeditImageErrors = function (settings) { return `<div class="quickedit-image-errors">${settings.errors}</div>`; }; Drupal.theme.quickeditImageDropzone = function (settings) { return `<div class="quickedit-image-dropzone ${settings.state}">` + ' <i class="quickedit-image-icon"></i>' + ` <span class="quickedit-image-text">${settings.text}</span>` + '</div>'; }; Drupal.theme.quickeditImageToolbar = function (settings) { let html = '<form class="quickedit-image-field-info">'; if (settings.alt_field) { html += `<div><label for="alt" class="${settings.alt_field_required ? 'required' : ''}">${Drupal.t('Alternative text')}</label>` + `<input type="text" placeholder="${settings.alt}" value="${settings.alt}" name="alt" ${settings.alt_field_required ? 'required' : ''}/>` + ' </div>'; } if (settings.title_field) { html += `<div><label for="title" class="${settings.title_field_required ? 'form-required' : ''}">${Drupal.t('Title')}</label>` + `<input type="text" placeholder="${settings.title}" value="${settings.title}" name="title" ${settings.title_field_required ? 'required' : ''}/>` + '</div>'; } html += '</form>'; return html; }; })(Drupal); No newline at end of file core/modules/image/css/editors/image.css→core/modules/quickedit/css/editors/image.css +1 −1 Original line number Diff line number Diff line /** * @file * Functional styles for the Image module's in-place editor. * Functional styles for the Quick Edit image in-place editor. */ /** Loading Loading
core/modules/image/image.libraries.yml +0 −16 Original line number Diff line number Diff line Loading @@ -3,19 +3,3 @@ admin: css: theme: css/image.admin.css: {} quickedit.inPlaceEditor.image: version: VERSION js: js/editors/image.js: {} js/theme.js: {} css: component: css/editors/image.css: {} theme: css/editors/image.theme.css: {} dependencies: - core/jquery - core/drupal - core/internal.underscore - quickedit/quickedit
core/modules/image/image.routing.yml +0 −26 Original line number Diff line number Diff line Loading @@ -71,29 +71,3 @@ image.effect_edit_form: route_callbacks: - '\Drupal\image\Routing\ImageStyleRoutes::routes' image.upload: path: '/quickedit/image/upload/{entity_type}/{entity}/{field_name}/{langcode}/{view_mode_id}' defaults: _controller: '\Drupal\image\Controller\QuickEditImageController::upload' options: parameters: entity: type: entity:{entity_type} requirements: _permission: 'access in-place editing' _access_quickedit_entity_field: 'TRUE' _method: 'POST' image.info: path: '/quickedit/image/info/{entity_type}/{entity}/{field_name}/{langcode}/{view_mode_id}' defaults: _controller: '\Drupal\image\Controller\QuickEditImageController::getInfo' options: parameters: entity: type: entity:{entity_type} requirements: _permission: 'access in-place editing' _access_quickedit_entity_field: 'TRUE' _method: 'GET'
core/modules/image/js/theme.es6.jsdeleted 100644 → 0 +0 −92 Original line number Diff line number Diff line /** * @file * Provides theme functions for image Quick Edit's client-side HTML. */ (function (Drupal) { /** * Theme function for validation errors of the Image in-place editor. * * @param {object} settings * Settings object used to construct the markup. * @param {string} settings.errors * Already escaped HTML representing error messages. * * @return {string} * The corresponding HTML. */ Drupal.theme.quickeditImageErrors = function (settings) { return `<div class="quickedit-image-errors">${settings.errors}</div>`; }; /** * Theme function for the dropzone element of the Image module's in-place * editor. * * @param {object} settings * Settings object used to construct the markup. * @param {string} settings.state * State of the upload. * @param {string} settings.text * Text to display inline with the dropzone element. * * @return {string} * The corresponding HTML. */ Drupal.theme.quickeditImageDropzone = function (settings) { return ( `<div class="quickedit-image-dropzone ${settings.state}">` + ' <i class="quickedit-image-icon"></i>' + ` <span class="quickedit-image-text">${settings.text}</span>` + '</div>' ); }; /** * Theme function for the toolbar of the Image module's in-place editor. * * @param {object} settings * Settings object used to construct the markup. * @param {bool} settings.alt_field * Whether or not the "Alt" field is enabled for this field. * @param {bool} settings.alt_field_required * Whether or not the "Alt" field is required for this field. * @param {string} settings.alt * The current value for the "Alt" field. * @param {bool} settings.title_field * Whether or not the "Title" field is enabled for this field. * @param {bool} settings.title_field_required * Whether or not the "Title" field is required for this field. * @param {string} settings.title * The current value for the "Title" field. * * @return {string} * The corresponding HTML. */ Drupal.theme.quickeditImageToolbar = function (settings) { let html = '<form class="quickedit-image-field-info">'; if (settings.alt_field) { html += `<div><label for="alt" class="${ settings.alt_field_required ? 'required' : '' }">${Drupal.t('Alternative text')}</label>` + `<input type="text" placeholder="${settings.alt}" value="${ settings.alt }" name="alt" ${settings.alt_field_required ? 'required' : ''}/>` + ' </div>'; } if (settings.title_field) { html += `<div><label for="title" class="${ settings.title_field_required ? 'form-required' : '' }">${Drupal.t('Title')}</label>` + `<input type="text" placeholder="${settings.title}" value="${ settings.title }" name="title" ${settings.title_field_required ? 'required' : ''}/>` + '</div>'; } html += '</form>'; return html; }; })(Drupal);
core/modules/image/js/theme.jsdeleted 100644 → 0 +0 −31 Original line number Diff line number Diff line /** * DO NOT EDIT THIS FILE. * See the following change record for more information, * https://www.drupal.org/node/2815083 * @preserve **/ (function (Drupal) { Drupal.theme.quickeditImageErrors = function (settings) { return `<div class="quickedit-image-errors">${settings.errors}</div>`; }; Drupal.theme.quickeditImageDropzone = function (settings) { return `<div class="quickedit-image-dropzone ${settings.state}">` + ' <i class="quickedit-image-icon"></i>' + ` <span class="quickedit-image-text">${settings.text}</span>` + '</div>'; }; Drupal.theme.quickeditImageToolbar = function (settings) { let html = '<form class="quickedit-image-field-info">'; if (settings.alt_field) { html += `<div><label for="alt" class="${settings.alt_field_required ? 'required' : ''}">${Drupal.t('Alternative text')}</label>` + `<input type="text" placeholder="${settings.alt}" value="${settings.alt}" name="alt" ${settings.alt_field_required ? 'required' : ''}/>` + ' </div>'; } if (settings.title_field) { html += `<div><label for="title" class="${settings.title_field_required ? 'form-required' : ''}">${Drupal.t('Title')}</label>` + `<input type="text" placeholder="${settings.title}" value="${settings.title}" name="title" ${settings.title_field_required ? 'required' : ''}/>` + '</div>'; } html += '</form>'; return html; }; })(Drupal); No newline at end of file
core/modules/image/css/editors/image.css→core/modules/quickedit/css/editors/image.css +1 −1 Original line number Diff line number Diff line /** * @file * Functional styles for the Image module's in-place editor. * Functional styles for the Quick Edit image in-place editor. */ /** Loading