In my Vue code, I have a list of search results that are displayed like this:
<div class="search-result" v-for="result in search_results" v-on:click="submit(result)">
{{ result.name }}
</div>
When a user clicks on a search result, the submit
method is supposed to be triggered.
However, there seems to be an issue with it working consistently across different devices and input methods. Here's what I've observed:
- The functionality works fine when using a Macbook.
- It also works when using a mouse on a Windows laptop.
- Unfortunately, it does NOT work when using the trackpad on the same Windows laptop. Specifically, tapping the trackpad lightly doesn't trigger the method, but pressing down deeply does.
Any insights or solutions to why this behavior is occurring?
For testing purposes, I simplified the submit
method to just log a message (console.log('what is happening')
), and the results remain consistent.