7124ab5f by Michael Richards

Ensure <= 80 character lines.

1 parent 3ce0f6a2
...@@ -174,8 +174,8 @@ class Rivets.ComponentBinding extends Rivets.Binding ...@@ -174,8 +174,8 @@ class Rivets.ComponentBinding extends Rivets.Binding
174 else 174 else
175 @inflections[attribute.name] = attribute.value 175 @inflections[attribute.name] = attribute.value
176 176
177 # Intercepts `Rivets.Binding::sync` since component bindings are not bound to a 177 # Intercepts `Rivets.Binding::sync` since component bindings are not bound to
178 # particular model to update it's value. 178 # a particular model to update it's value.
179 sync: -> 179 sync: ->
180 180
181 # Returns an object map using the component's scope inflections. 181 # Returns an object map using the component's scope inflections.
...@@ -297,13 +297,17 @@ class Rivets.View ...@@ -297,13 +297,17 @@ class Rivets.View
297 [startToken, restTokens...] = tokens 297 [startToken, restTokens...] = tokens
298 node.data = startToken.value 298 node.data = startToken.value
299 299
300 switch startToken.type 300 if startToken.type is 0
301 when 0 then node.data = startToken.value 301 node.data = startToken.value
302 when 1 then buildBinding 'TextBinding', node, null, startToken.value 302 else
303 buildBinding 'TextBinding', node, null, startToken.value
303 304
304 for token in restTokens 305 for token in restTokens
305 node.parentNode.appendChild (text = document.createTextNode token.value) 306 text = document.createTextNode token.value
306 buildBinding 'TextBinding', text, null, token.value if token.type is 1 307 node.parentNode.appendChild text
308
309 if token.type is 1
310 buildBinding 'TextBinding', text, null, token.value
307 else if componentRegExp.test node.tagName 311 else if componentRegExp.test node.tagName
308 type = node.tagName.replace(componentRegExp, '').toLowerCase() 312 type = node.tagName.replace(componentRegExp, '').toLowerCase()
309 @bindings.push new Rivets.ComponentBinding @, node, type 313 @bindings.push new Rivets.ComponentBinding @, node, type
......