Skip to content

Commit

Permalink
fix(search): perte du focus dès que la souris survole la carte
Browse files Browse the repository at this point in the history
  • Loading branch information
azarz committed May 22, 2024
1 parent 0be6823 commit c7a4aee
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/components/carte/Map.vue
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,10 @@ onMounted(() => {
* Trigerred on mouse over
*/
const onFocusOnMap = () => {
mapRef.value.focus();
// Si le focus est actuellement sur une balise <input>, on ne change pas de focus
if (document.activeElement.tagName !== "INPUT") {
mapRef.value.focus();
}
}
// rendre disponible 'map' aux composants enfants imbriqués
Expand Down

0 comments on commit c7a4aee

Please sign in to comment.