diff --git a/2-ui/2-events/02-bubbling-and-capturing/article.md b/2-ui/2-events/02-bubbling-and-capturing/article.md index 5d854a59f..113e42ab7 100644 --- a/2-ui/2-events/02-bubbling-and-capturing/article.md +++ b/2-ui/2-events/02-bubbling-and-capturing/article.md @@ -1,8 +1,8 @@ -# Bubbling and capturing +# Bubbling e capturing -Let's start with an example. +Cominciamo con un esempio. -This handler is assigned to `
`:
+Questo gestore è assegnato al ``, ma viene eseguito anche se clicchiamo qualunque tag come ad esempio `` oppure ``:
```html autorun height=60
@@ -10,15 +10,15 @@ This handler is assigned to ``, but also runs if you click any nested tag l
```
-Isn't it a bit strange? Why does the handler on `` run if the actual click was on ``?
+Non è un po' strano? Perché il gestore su `` viene eseguito se il click è su ``?
## Bubbling
-The bubbling principle is simple.
+Il principio alla base del *bubbling* è semplice.
-**When an event happens on an element, it first runs the handlers on it, then on its parent, then all the way up on other ancestors.**
+**Quando viene innescato un evento su un elemento, come prima cosa vengono eseguiti i gestori ad esso assegnati, poi ai nodi genitori, ed infine risale fino agli altri nodi antenati.**
-Let's say we have 3 nested elements `FORM > DIV > P` with a handler on each of them:
+Poniamo il caso di avere 3 elementi annidati `FORM > DIV > P` con un gestore per ognuno di essi:
```html run autorun