mirror of
https://github.com/DanielnetoDotCom/YouPHPTube
synced 2025-10-03 01:39:24 +02:00
31 lines
967 B
JavaScript
31 lines
967 B
JavaScript
/*
|
|
Input Mask plugin binding
|
|
http://github.com/RobinHerbots/jquery.inputmask
|
|
Copyright (c) Robin Herbots
|
|
Licensed under the MIT license
|
|
*/
|
|
(function (factory) {
|
|
factory(jQuery, window.Inputmask, window);
|
|
})(function ($, Inputmask, window) {
|
|
$(window.document)
|
|
.ajaxComplete(function (event, xmlHttpRequest, ajaxOptions) {
|
|
if ($.inArray("html", ajaxOptions.dataTypes) !== -1) {
|
|
$(
|
|
".inputmask, [data-inputmask], [data-inputmask-mask], [data-inputmask-alias], [data-inputmask-regex]"
|
|
).each(function (ndx, lmnt) {
|
|
if (lmnt.inputmask === undefined) {
|
|
Inputmask().mask(lmnt);
|
|
}
|
|
});
|
|
}
|
|
})
|
|
.ready(function () {
|
|
$(
|
|
".inputmask, [data-inputmask], [data-inputmask-mask], [data-inputmask-alias],[data-inputmask-regex]"
|
|
).each(function (ndx, lmnt) {
|
|
if (lmnt.inputmask === undefined) {
|
|
Inputmask().mask(lmnt);
|
|
}
|
|
});
|
|
});
|
|
});
|