AK
Size: a a a
AK
C☭
C☭
R
C☭
C☭
C☭
C☭
PA
C☭
C☭
PA
C☭
C☭
class FaFormAutofillFix {
/**
* @constructor
*
* @param {angular.ITimeoutService} $timeout
*
* @ngInject
*/
constructor(
$timeout
) {
this.restrict = 'A';
this._$timeout = $timeout;
}
link(scope, elem, attrs) {
// Fixes Chrome bug: https://groups.google.com/forum/#!topic/angular/6NlucSskQjY
elem.prop('method', 'POST');
// Fix autofill issues where Angular doesn't know about autofilled inputs
if (attrs.ngSubmit) {
this._$timeout(() => {
elem
.unbind('submit')
.bind('submit', (e) => {
e.preventDefault();
elem.find('input, textarea, select').trigger('input').trigger('change').trigger('keydown');
scope.$apply(attrs.ngSubmit);
});
}, 0);
}
}
}R
AK
AK
R