mirror of
https://github.com/getgrav/grav-plugin-admin.git
synced 2025-11-18 03:00:56 +01:00
Merge branch 'develop' of https://github.com/getgrav/grav-plugin-admin into develop
This commit is contained in:
@@ -692,3 +692,5 @@ PLUGIN_ADMIN:
|
||||
2FA_SECRET: "2FA Secret"
|
||||
2FA_SECRET_HELP: "Scan this QR code into your [Authenticator App](https://learn.getgrav.org/admin-panel/2fa#apps). Also it's a good idea to backup the secret in a safe location, in case you need to reinstall your app. Check the [Grav docs](https://learn.getgrav.org/admin-panel/2fa) for more information "
|
||||
2FA_REGENERATE: "Regenerate"
|
||||
CASE_INSENSITIVE_URLS: "Case Insensitive URLs"
|
||||
CASE_INSENSITIVE_URLS_HELP: "Enables Grav routing to locate resources regardless of text case."
|
||||
42
themes/grav/js/form-attr.polyfill.js
vendored
42
themes/grav/js/form-attr.polyfill.js
vendored
@@ -51,27 +51,29 @@
|
||||
var form = this,
|
||||
$fields = $('[form=' + this.id + ']');
|
||||
|
||||
$fields.filter('button, input').filter('[type=reset],[type=submit]').click(function() {
|
||||
var type = this.type.toLowerCase();
|
||||
if (type === 'reset') {
|
||||
// reset form
|
||||
form.reset();
|
||||
// for elements outside form
|
||||
$fields.each(function() {
|
||||
this.value = this.defaultValue;
|
||||
this.checked = this.defaultChecked;
|
||||
}).filter('select').each(function() {
|
||||
$(this).find('option').each(function() {
|
||||
this.selected = this.defaultSelected;
|
||||
$fields.filter('button, input')
|
||||
.filter('[type=reset],[type=submit],[type=image],button')
|
||||
.click(function() {
|
||||
var type = this.type.toLowerCase();
|
||||
if (type === 'reset') {
|
||||
// reset form
|
||||
form.reset();
|
||||
// for elements outside form
|
||||
$fields.each(function() {
|
||||
this.value = this.defaultValue;
|
||||
this.checked = this.defaultChecked;
|
||||
}).filter('select').each(function() {
|
||||
$(this).find('option').each(function() {
|
||||
this.selected = this.defaultSelected;
|
||||
});
|
||||
});
|
||||
});
|
||||
} else if (type.match(/^submit|image$/i)) {
|
||||
$(form).appendField({
|
||||
name: this.name,
|
||||
value: this.value
|
||||
}).submit();
|
||||
}
|
||||
});
|
||||
} else {
|
||||
$(form).appendField({
|
||||
name: this.name,
|
||||
value: this.value
|
||||
}).submit();
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user