diff --git a/src/lib/template/templatizer.html b/src/lib/template/templatizer.html index ee8ea789d9..b76fcc463a 100644 --- a/src/lib/template/templatizer.html +++ b/src/lib/template/templatizer.html @@ -124,6 +124,8 @@ archetype._scopeElementClass = this._scopeElementClassImpl; archetype.listen = this._listenImpl; archetype._showHideChildren = this._showHideChildrenImpl; + archetype.__setPropertyOrig = this.__setProperty; + archetype.__setProperty = this.__setPropertyImpl; // boilerplate code var _constructor = this._constructorImpl; var ctor = function TemplateInstance(model, host) { @@ -168,6 +170,13 @@ } }, + __setPropertyImpl: function(property, value, fromAbove, node) { + if (node && node.__hideTemplateChildren__ && property == 'textContent') { + property = '__polymerTextContent__'; + } + this.__setPropertyOrig(property, value, fromAbove, node); + }, + _debounceTemplate: function(fn) { Polymer.dom.addDebouncer(this.debounce('_debounceTemplate', fn)); }, @@ -242,7 +251,7 @@ }, { kind: 'notify', fn: Polymer.Bind._notifyEffect, - effect: {event: + effect: {event: Polymer.CaseMap.camelToDashCase(parentProp) + '-changed'} }]; Polymer.Bind._createAccessors(proto, parentProp, effects); @@ -259,7 +268,7 @@ } this._extendTemplate(template, proto); template._pathEffector = function(path, value, fromAbove) { - return self._pathEffectorImpl(path, value, fromAbove); + return self._pathEffectorImpl(path, value, fromAbove); } } }, diff --git a/test/unit/dom-if-elements.html b/test/unit/dom-if-elements.html index f569bebfa3..2c421a262c 100644 --- a/test/unit/dom-if-elements.html +++ b/test/unit/dom-if-elements.html @@ -165,13 +165,18 @@