diff --git a/public/docs/ts/latest/guide/template-syntax.jade b/public/docs/ts/latest/guide/template-syntax.jade index e6822a848e..c900d0c505 100644 --- a/public/docs/ts/latest/guide/template-syntax.jade +++ b/public/docs/ts/latest/guide/template-syntax.jade @@ -1389,29 +1389,29 @@ block style-property-name-dart-diff 这都是好事。 // -:marked -### Event bubbling and propagation [TODO: reinstate this section when it becomes true] -Angular invokes the event-handling statement if the event is raised by the current element or one of its child elements. -+makeExample('template-syntax/ts/app/app.component.html', 'event-binding-bubbling')(format=".") -:marked -Many DOM events, both [native](https://developer.mozilla.org/en-US/docs/Web/Guide/Events/Overview_of_Events_and_Handlers ) and [custom](https://developer.mozilla.org/en-US/docs/Web/Guide/Events/Creating_and_triggering_events ), bubble up their ancestor tree of DOM elements until an event handler along the way prevents further propagation. + :marked + ### Event bubbling and propagation [TODO: reinstate this section when it becomes true] + Angular invokes the event-handling statement if the event is raised by the current element or one of its child elements. + +makeExample('template-syntax/ts/app/app.component.html', 'event-binding-bubbling')(format=".") + :marked + Many DOM events, both [native](https://developer.mozilla.org/en-US/docs/Web/Guide/Events/Overview_of_Events_and_Handlers ) and [custom](https://developer.mozilla.org/en-US/docs/Web/Guide/Events/Creating_and_triggering_events ), bubble up their ancestor tree of DOM elements until an event handler along the way prevents further propagation. .l-sub-section -:marked - `EventEmitter` events don’t bubble. + :marked + `EventEmitter` events don’t bubble. :marked - The result of an event binding statement determines whether - [event propagation](https://developer.mozilla.org/en-US/docs/Web/API/Document_Object_Model/Examples#Example_5:_Event_Propagation) - continues or stops with the current element. + The result of an event binding statement determines whether + [event propagation](https://developer.mozilla.org/en-US/docs/Web/API/Document_Object_Model/Examples#Example_5:_Event_Propagation) + continues or stops with the current element. - Event propagation stops if the binding statement returns a falsey value (as does a method with no return value). - Clicking the button in the next example triggers a save; - the click doesn't make it to the outer `
` so the div's save handler is not called. + Event propagation stops if the binding statement returns a falsey value (as does a method with no return value). + Clicking the button in the next example triggers a save; + the click doesn't make it to the outer `
` so the div's save handler is not called. +makeExample('template-syntax/ts/app/app.component.html', 'event-binding-no-propagation')(format=".") :marked - Propagation continues if the statement returns a truthy value. In the next example, the click is heard by both the button - and the outer `
`, causing a double save. + Propagation continues if the statement returns a truthy value. In the next example, the click is heard by both the button + and the outer `
`, causing a double save. +makeExample('template-syntax/ts/app/app.component.html', 'event-binding-propagation')(format=".") #two-way