This repository has been archived on 2025-01-19. You can view files and clone it, but cannot push or open issues or pull requests.
drupalcampbristol/web/modules/contrib/webform/js/webform.imce.js
2018-11-23 12:29:20 +00:00

24 lines
495 B
JavaScript

/**
* @file
* JavaScript behaviors for IMCE.
*/
(function ($, Drupal) {
'use strict';
/**
* Override processUrlInput to place the 'Open File Browser' links after the target element.
*
* @param {int} i
* Element's index.
* @param {element} el
* A element.
*/
window.imceInput.processUrlInput = function (i, el) {
var button = imceInput.createUrlButton(el.id, el.getAttribute('data-imce-type'));
$(button).insertAfter($(el));
};
})(jQuery, Drupal);