mirror of
https://github.com/moparisthebest/mail
synced 2024-12-23 15:58:49 -05:00
refactored addressInput directive in write view to not use stopPropagation
This commit is contained in:
parent
746c4f3b2d
commit
5a1b9c1af9
@ -483,7 +483,11 @@ define(function(require) {
|
||||
return {
|
||||
//scope: true, // optionally create a child scope
|
||||
link: function(scope, element, attrs) {
|
||||
element.on('click', function() {
|
||||
element.on('click', function(e) {
|
||||
if(e.target.nodeName === 'INPUT') {
|
||||
return;
|
||||
}
|
||||
|
||||
var fieldName = attrs.field;
|
||||
var field = scope[fieldName];
|
||||
|
||||
@ -509,11 +513,6 @@ define(function(require) {
|
||||
var field = scope[fieldName];
|
||||
var index = parseInt(attrs.id.replace(fieldName, ''), 10);
|
||||
|
||||
element.on('click', function(e) {
|
||||
// focus on this one and dont bubble to field click handler
|
||||
e.stopPropagation();
|
||||
});
|
||||
|
||||
element.on('blur', function() {
|
||||
if (!checkForEmptyInput(field)) {
|
||||
// create new field input
|
||||
|
Loading…
Reference in New Issue
Block a user