Lugaru
Lugaru

Reputation: 1460

AngularJS: button focused

I have few input fields and Save button. One of the field with type-ahead functionality(tag-input). When I pressing ENTER on a keyboard when tag-input focused it will trigger Save button.

It seems that Save button still focused even if I doing input in other element.

How I can un-focus this button with Angular?

Upvotes: 0

Views: 49

Answers (1)

Jack A.
Jack A.

Reputation: 4453

The problem is not that the button has focus, it is that the default behavior of the Enter key is to submit the form. So you need something like the answers for this question.

Upvotes: 1

Related Questions