primeng icon indicating copy to clipboard operation
primeng copied to clipboard

how to add a value to Primeng auto complete on outside click event

Open PrathyushaRecherla opened this issue 7 years ago • 2 comments

@doeringp I have a list of values that can be added to input filed using Primeng auto complete. I would like to add new values to the input filed and push it to texts array when I click outside of the input box.

In the below example I have keyboard event. It can add values to the texts array on pressing on Enter button. I would like to implement the similar functionality on clicking outside of the input box. https://stackblitz.com/edit/angular-kfvj5p

PrathyushaRecherla avatar Apr 30 '19 16:04 PrathyushaRecherla

This is a question not an issue and should be asked on the primeng forum instead. If you believe this is an issue with the PrimeNG framework please clarify.

JacobSiegle avatar May 01 '19 18:05 JacobSiegle

Used onBlur event to add values on outside click. OutsideClick(event: KeyboardEvent) { let tokenInputValue = event.srcElement as any; console.log("token input on Blur", tokenInputValue.value); }

PrathyushaRecherla avatar May 15 '19 18:05 PrathyushaRecherla