CoreFiles by mySites.guru
admin-login.js26 lines, 719 bytes, from Joomla_4.0.0-beta6-Beta-Full_Package.zip
Raw History Compare with 4.0.0-beta5
md5
bb9e76cef6d91476fb453e0d2f56b403
sha1
31fe5186bfbc5abc12b1c49cee7bff26eefd3cf2
sha256
08e5116cdfc1920013c1cd6c4e9d8565a27e55b4012025937303022d99f3cdb8
/**
* PLEASE DO NOT MODIFY THIS FILE. WORK ON THE ES6 VERSION.
* OTHERWISE YOUR CHANGES WILL BE REPLACED ON THE NEXT BUILD.
**/

/**
 * @copyright  (C) 2018 Open Source Matters, Inc. <https://www.joomla.org>
 * @license    GNU General Public License version 2 or later; see LICENSE.txt
 */
(function (Joomla, document) {
  'use strict';

  document.addEventListener('DOMContentLoaded', function () {
    var btn = document.getElementById('btn-login-submit');

    if (btn) {
      btn.addEventListener('click', function (event) {
        event.preventDefault();

        if (document.formvalidator.isValid(btn.form)) {
          Joomla.submitbutton('login');
        }
      });
    }
  });
})(window.Joomla, document);

The same content is in 2 releases, Joomla 4.0.0-beta6 to 4.0.0-beta7. See them all, or every version of this file.