You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
There's no way via the sp-search API to distinguish the clear button being pressed from someone clearing the search input and blurring the input.
This is problematic, since the clear button is a more explicit action, and also clears focus. In our app we'd like to submit the search when it's clicked, but not just from blurring the input.
It'd be nice if clicking the clear button triggered something like a clear event.
Mockups or screenshots
No response
Implementation notes or ideas
No response
The text was updated successfully, but these errors were encountered:
Click "clear" (get one change for blurring the input and committing what you typed)
Form is reset (get one change for moving the value to '')
That would be expected.
There's a reset event on the <form> internal to the element when the "clear" button is pressed. Would redispatching that on the host align with what you're trying to achieve here?
That matches the steps I'm doing and what I'm seeing, yes.
Personally I don't think the change event at step 2 is actually desired. It feels like that one should get suppressed by the clear button press if possible.
Code of conduct
Impacted component(s)
sp-search
Description of the requested feature
There's no way via the sp-search API to distinguish the clear button being pressed from someone clearing the search input and blurring the input.
This is problematic, since the clear button is a more explicit action, and also clears focus. In our app we'd like to submit the search when it's clicked, but not just from blurring the input.
It'd be nice if clicking the clear button triggered something like a clear event.
Mockups or screenshots
No response
Implementation notes or ideas
No response
The text was updated successfully, but these errors were encountered: