mirror of
https://github.com/mdbootstrap/mdb-ui-kit.git
synced 2025-02-27 00:50:39 +03:00
Update material.js
This commit is contained in:
parent
08a2702506
commit
a458c088cc
37
dist/js/material.js
vendored
37
dist/js/material.js
vendored
|
@ -216,11 +216,28 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
.on("focus", ".form-control, .form-group.is-fileinput", function () {
|
.on("select2-focus", function (e) {
|
||||||
_addFormGroupFocus(this);
|
if (!$(e.target).is('.select2-focusser')) {
|
||||||
|
_addFormGroupFocus($(e.target));
|
||||||
|
}
|
||||||
})
|
})
|
||||||
.on("blur", ".form-control, .form-group.is-fileinput", function () {
|
.on("select2-opening", function (e) {
|
||||||
_removeFormGroupFocus(this);
|
if (!$(e.target).is('.select2-focusser')) {
|
||||||
|
_addFormGroupFocus($(e.target));
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.on("select2-blur", function (e) {
|
||||||
|
_removeFormGroupFocus($(e.target));
|
||||||
|
})
|
||||||
|
.on("focus", ".form-control", function (e) {
|
||||||
|
if (!$(e.target).is('.select2-focusser')) {
|
||||||
|
_addFormGroupFocus(this);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.on("blur", ".form-control, .form-group.is-fileinput", function (e) {
|
||||||
|
if (!$(e.target).is('.select2-focusser')) {
|
||||||
|
_removeFormGroupFocus(this);
|
||||||
|
}
|
||||||
})
|
})
|
||||||
// make sure empty is added back when there is a programmatic value change.
|
// make sure empty is added back when there is a programmatic value change.
|
||||||
// NOTE: programmatic changing of value using $.val() must trigger the change event i.e. $.val('x').trigger('change')
|
// NOTE: programmatic changing of value using $.val() must trigger the change event i.e. $.val('x').trigger('change')
|
||||||
|
@ -256,7 +273,17 @@
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
"ripples": function (selector) {
|
"ripples": function (selector) {
|
||||||
$((selector) ? selector : this.options.withRipples).ripples();
|
if (this.options.ripplesDelegate) {
|
||||||
|
// Delegate mode, lazy creation
|
||||||
|
$(document).on('mousedown touchstart', selector || this.options.withRipples, function(event) {
|
||||||
|
if(!$.data($(this), "plugin_ripples")) {
|
||||||
|
$(this).ripples({}, event);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
// Immediate and static creation
|
||||||
|
$((selector) ? selector : this.options.withRipples).ripples();
|
||||||
|
};
|
||||||
},
|
},
|
||||||
"autofill": function () {
|
"autofill": function () {
|
||||||
// This part of code will detect autofill when the page is loading (username and password inputs for example)
|
// This part of code will detect autofill when the page is loading (username and password inputs for example)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user