Fixes #549 - Migrate from "data" to "input"

This commit is contained in:
Patrick Steele-Idem 2017-01-26 17:18:12 -07:00
parent 96a360e515
commit 489321cf54
178 changed files with 277 additions and 268 deletions

View File

@ -38,7 +38,9 @@ class TemplateRoot extends Node {
var builder = codegen.builder; var builder = codegen.builder;
let renderStatements = []; let renderStatements = [
builder.var('data', builder.identifier('input'))
];
var vars = createVarsArray(context.getVars()); var vars = createVarsArray(context.getVars());
if (vars.length) { if (vars.length) {
renderStatements.push(builder.vars(vars)); renderStatements.push(builder.vars(vars));
@ -56,7 +58,7 @@ class TemplateRoot extends Node {
builder.functionDeclaration( builder.functionDeclaration(
null, null,
[ [
builder.identifier('data'), builder.identifier('input'),
builder.identifierOut() builder.identifierOut()
], ],
renderStatements) renderStatements)
@ -89,7 +91,7 @@ class TemplateRoot extends Node {
body = body.concat(staticNodes); body = body.concat(staticNodes);
} }
var renderParams = [builder.identifier('data'), builder.identifierOut()]; var renderParams = [builder.identifier('input'), builder.identifierOut()];
if (this.extraRenderParams) { if (this.extraRenderParams) {
renderParams = renderParams.concat(this.extraRenderParams); renderParams = renderParams.concat(this.extraRenderParams);
} }

View File

@ -0,0 +1 @@
Hello Frank! data===input ? true

View File

@ -0,0 +1 @@
-- Hello ${data.name}! data===input ? ${data === input}

View File

@ -0,0 +1,3 @@
exports.templateData = {
name: 'Frank'
};

View File

@ -1,5 +1,5 @@
<select multiple> <select multiple>
<option value="red">Red</option> <option value="red">Red</option>
<option value="green" selected=(data.isGreenSelected)>Green</option> <option value="green" selected=(input.isGreenSelected)>Green</option>
<option value="blue" selected=(data.isBlueSelected)>Blue</option> <option value="blue" selected=(input.isBlueSelected)>Blue</option>
</select> </select>

View File

@ -1,11 +1,11 @@
<input type="checkbox" checked=data.checked> <input type="checkbox" checked=input.checked>
<button disabled>Button</button> <button disabled>Button</button>
<select> <select>
<option value="${option.value}" <option value="${option.value}"
selected=option.selected selected=option.selected
for(option in data.options)> for(option in input.options)>
${option.value} ${option.value}

View File

@ -1 +1 @@
<img alt=(data.myAlt || true)> <img alt=(input.myAlt || true)>

View File

@ -1 +1 @@
<div value=data.myObject/> <div value=input.myObject/>

View File

@ -1,3 +1,3 @@
<div foo='Hello ${data.foo || ''}'> <div foo='Hello ${input.foo || ''}'>
Hello World! Hello World!
</div> </div>

View File

@ -1,3 +1,3 @@
<div foo='Hello $!{data.foo || ''}'> <div foo='Hello $!{input.foo || ''}'>
Hello World! Hello World!
</div> </div>

View File

@ -1 +1 @@
<div data-_onclick=data.parent/> <div data-_onclick=input.parent/>

View File

@ -1 +1 @@
<div data-_onclick=data.specialData/> <div data-_onclick=input.specialData/>

View File

@ -1,3 +1,3 @@
<div ${data.myAttrs} data-encoding='"hello"'> <div ${input.myAttrs} data-encoding='"hello"'>
Hello World! Hello World!
</div> </div>

View File

@ -1,6 +1,6 @@
<div class="hello"> <div class="hello">
<h1>test-hello</h1> <h1>test-hello</h1>
<div class="body"> <div class="body">
<invoke data.renderBody(out) /> <invoke input.renderBody(out) />
</div> </div>
</div> </div>

View File

@ -1,6 +1,6 @@
<a href=data.url body-only-if(!data.url)> <a href=input.url body-only-if(!input.url)>
Some Link Some Link
</a> </a>
<a href=data.invalidUrl body-only-if(!data.invalidUrl)> <a href=input.invalidUrl body-only-if(!input.invalidUrl)>
Another Link Another Link
</a> </a>

View File

@ -1,5 +1,5 @@
<ul> <ul>
<li for(item in data.items)> <li for(item in input.items)>
<b>${item.label}</b> <b>${item.label}</b>
<navigation-item items=item.children if(item.children)/> <navigation-item items=item.children if(item.children)/>
</li> </li>

View File

@ -1 +1 @@
<navigation-item items=data.items/> <navigation-item items=input.items/>

View File

@ -1,6 +1,6 @@
div -- Hello ${data.name} div -- Hello ${input.name}
<span if(data.name)> <span if(input.name)>
${data.name} ${input.name}
</span> </span>
<p else> <p else>
No name! No name!

View File

@ -1,4 +1,4 @@
div -- Hello ${data.name} div -- Hello ${input.name}
span if(data.name) span if(input.name)
-- ${data.name} -- ${input.name}
p else -- No name! p else -- No name!

View File

@ -1,3 +1,3 @@
<div class=( false ? 'some-class' : undefined )></div> <div class=( false ? 'some-class' : undefined )></div>
<div class=( true ? 'some-class' : false )></div> <div class=( true ? 'some-class' : false )></div>
<div class=data.name></div> <div class=input.name></div>

View File

@ -1,3 +1,3 @@
--- ---
Hello ${data.name}! Hello ${input.name}!
--- ---

View File

@ -1,3 +1,3 @@
--- ---
Hello ${data.name}! Hello ${input.name}!
--- ---

View File

@ -1 +1 @@
<div ${data.attrs}>Hello World</div> <div ${input.attrs}>Hello World</div>

View File

@ -1,5 +1,5 @@
hello-${data.myTagName} class="my-class" foo="bar" hello-${input.myTagName} class="my-class" foo="bar"
-- My nested content -- My nested content
${data.foo ? 'foo' : 'bar'} class="my-class" foo="bar" ${input.foo ? 'foo' : 'bar'} class="my-class" foo="bar"
-- My nested content -- My nested content

View File

@ -1,7 +1,7 @@
<hello-${data.myTagName} class="my-class" foo="bar"> <hello-${input.myTagName} class="my-class" foo="bar">
My nested content My nested content
</> </>
<${data.foo ? 'foo' : 'bar'} class="my-class" foo="bar"> <${input.foo ? 'foo' : 'bar'} class="my-class" foo="bar">
My nested content My nested content
</> </>

View File

@ -1,6 +1,6 @@
p p
<span> <span>
<a> <a>
Hello ${data.name}! Hello ${input.name}!
</> </>
</> </>

View File

@ -1,4 +1,4 @@
<div if(data.foo === dasda 0)> <div if(input.foo === dasda 0)>
A A
</div> </div>
<div else> <div else>

View File

@ -5,5 +5,5 @@ exports.templateData = {};
exports.checkError = function(e) { exports.checkError = function(e) {
var message = e.toString(); var message = e.toString();
// expect(message).to.contain('Error: Unable to compile template at path'); // expect(message).to.contain('Error: Unable to compile template at path');
expect(message).to.contain('Unexpected number: (data.foo === dasda 0)'); expect(message).to.contain('Unexpected number: (input.foo === dasda 0)');
}; };

View File

@ -1,4 +1,4 @@
<div if(data.foo === 0)> <div if(input.foo === 0)>
A A
</div> </div>
<div else-if(true sds)> <div else-if(true sds)>

View File

@ -1,7 +1,7 @@
<div if(data.foo === 0)> <div if(input.foo === 0)>
A A
</div> </div>
<div else-if(data.foo ==== 1)> <div else-if(input.foo ==== 1)>
B B
</div> </div>
<div else foo asasa sasa> <div else foo asasa sasa>

View File

@ -4,5 +4,5 @@ exports.templateData = {};
exports.checkError = function(e) { exports.checkError = function(e) {
var message = e.toString(); var message = e.toString();
expect(message).to.contain('Unexpected token =: (data.foo ==== 1)'); expect(message).to.contain('Unexpected token =: (input.foo ==== 1)');
}; };

View File

@ -1,4 +1,4 @@
<script> <script>
var foo = ${JSON.stringify(data.foo)}; var foo = ${JSON.stringify(input.foo)};
</script> </script>
<pre>${JSON.stringify(data.foo)}</pre> <pre>${JSON.stringify(input.foo)}</pre>

View File

@ -1,3 +1,3 @@
<for(item in data.myIterator)> <for(item in input.myIterator)>
${item} ${item}
</for> </for>

View File

@ -1,3 +1,3 @@
<div for(item in ['a', 'b', 'c'] | iterator=data.reverseIterator)> <div for(item in ['a', 'b', 'c'] | iterator=input.reverseIterator)>
${item} ${item}
</div> </div>

View File

@ -1,3 +1,3 @@
<div for(item in ['a', 'b', 'c'] | iterator=data.reverseIterator status-var=status )> <div for(item in ['a', 'b', 'c'] | iterator=input.reverseIterator status-var=status )>
${status.index}-${item} ${status.index}-${item}
</div> </div>

View File

@ -1,3 +1,3 @@
<for (item in ['a', 'b', 'c'] | iterator=data.reverseIterator status-var=status )> <for (item in ['a', 'b', 'c'] | iterator=input.reverseIterator status-var=status )>
${status.index}-${item} ${status.index}-${item}
</for> </for>

View File

@ -1,3 +1,3 @@
<for(item in ['a', 'b', 'c'] | iterator=data.reverseIterator)> <for(item in ['a', 'b', 'c'] | iterator=input.reverseIterator)>
${item} ${item}
</for> </for>

View File

@ -1,3 +1,3 @@
<for(name,value in data.myMap)> <for(name,value in input.myMap)>
[${name}=${value}] [${name}=${value}]
</for> </for>

View File

@ -1,4 +1,4 @@
<for(color in data.colors | array)> <for(color in input.colors | array)>
<div> <div>
${color} ${color}
</div> </div>

View File

@ -1,5 +1,5 @@
function getName() { function getName() {
return data.firstName + ' ' + data.lastName; return input.firstName + ' ' + input.lastName;
} }
-- Hello ${getName()} -- Hello ${getName()}

View File

@ -1 +1 @@
-- Hello ${data.name}! Hello $!{data.name}! Hello $!{data.missing}! -- Hello ${input.name}! Hello $!{input.name}! Hello $!{input.missing}!

View File

@ -1,4 +1,4 @@
<div if(data.foo === 0)> <div if(input.foo === 0)>
A A
</div> </div>
<div else> <div else>

View File

@ -1,4 +1,4 @@
<div if(data.foo === 0)> <div if(input.foo === 0)>
A A
</div> </div>
<div else-if(true)> <div else-if(true)>

View File

@ -1,7 +1,7 @@
<div if(data.foo === 0)> <div if(input.foo === 0)>
A A
</div> </div>
<div else-if(data.foo === 1)> <div else-if(input.foo === 1)>
B B
</div> </div>
<div else> <div else>

View File

@ -1 +1 @@
-- Hello ${data.name}! You have ${data.count} new messages. -- Hello ${input.name}! You have ${input.count} new messages.

View File

@ -1,9 +1,9 @@
<div> <div>
<h1> <h1>
Hello ${data.name}! You have ${data.count} new messages. Hello ${input.name}! You have ${input.count} new messages.
</h1> </h1>
<p if(data.renderBody)> <p if(input.renderBody)>
<invoke data.renderBody(out)/> <invoke input.renderBody(out)/>
</p> </p>
<p else> <p else>
No body! No body!

View File

@ -1,8 +1,8 @@
<div> <div>
<h1> <h1>
Hello ${data.name}! You have ${data.count} new messages. Hello ${input.name}! You have ${input.count} new messages.
</h1> </h1>
<p> <p>
<invoke data.renderBody(out)/> <invoke input.renderBody(out)/>
</p> </p>
</div> </div>

View File

@ -1 +1 @@
<include(data.component, {name: 'Frank'})/> <include(input.component, {name: 'Frank'})/>

View File

@ -1,8 +1,8 @@
<div> <div>
<h1> <h1>
Hello ${data.name}! You have ${data.count} new messages. Hello ${input.name}! You have ${input.count} new messages.
</h1> </h1>
<p> <p>
<invoke data.renderBody(out)/> <invoke input.renderBody(out)/>
</p> </p>
</div> </div>

View File

@ -1 +1 @@
-- Hello ${data.name}! You have ${data.count} new messages. -- Hello ${input.name}! You have ${input.count} new messages.

View File

@ -1 +1 @@
-- Hello ${data.name}! You have ${data.count} new messages. -- Hello ${input.name}! You have ${input.count} new messages.

View File

@ -1 +1 @@
<include(data.includeTarget) name='Frank' count=20/> <include(input.includeTarget) name='Frank' count=20/>

View File

@ -1 +1 @@
-- Hello ${data.firstName} ${data.lastName}! -- Hello ${input.firstName} ${input.lastName}!

View File

@ -1 +1 @@
-- Hello ${data.firstName}! You have ${data.count} new messages. -- Hello ${input.firstName}! You have ${input.count} new messages.

View File

@ -1,17 +1,17 @@
<h1 if(data.showHeader !== false)> <h1 if(input.showHeader !== false)>
<if(data.header)> <if(input.header)>
<include(data.header)/> <include(input.header)/>
</if> </if>
<else> <else>
DEFAULT TITLE DEFAULT TITLE
</else> </else>
</h1> </h1>
<div> <div>
<include(data.body)/> <include(input.body)/>
</div> </div>
<h1 if(data.showFooter !== false)> <h1 if(input.showFooter !== false)>
<if(data.footer)> <if(input.footer)>
<include(data.footer)/> <include(input.footer)/>
</if> </if>
<else> <else>
DEFAULT FOOTER DEFAULT FOOTER

View File

@ -1,13 +1,13 @@
<h1 if(data.showHeader !== false)> <h1 if(input.showHeader !== false)>
<if(data.header)> <if(input.header)>
<include(data.header)/> <include(input.header)/>
</if> </if>
<else> <else>
DEFAULT TITLE DEFAULT TITLE
</else> </else>
</h1> </h1>
<div> <div>
<include(data.body)/> <include(input.body)/>
</div> </div>
<include(data.footer)/> <include(input.footer)/>
<include(data.empty)/> <include(input.empty)/>

View File

@ -1,13 +1,13 @@
<h1 if(data.showHeader !== false)> <h1 if(input.showHeader !== false)>
<if(data.header)> <if(input.header)>
<include(data.header)/> <include(input.header)/>
</if> </if>
<else> <else>
DEFAULT TITLE DEFAULT TITLE
</else> </else>
</h1> </h1>
<div> <div>
<include(data.body)/> <include(input.body)/>
</div> </div>
<include(data.footer)/> <include(input.footer)/>
<include(data.empty)/> <include(input.empty)/>

View File

@ -12,7 +12,7 @@
<@body>BODY CONTENT</@body> <@body>BODY CONTENT</@body>
<@footer>FOOTER CONTENT</@footer> <@footer>FOOTER CONTENT</@footer>
</include> </include>
<include(data.layoutDynamic) show-header=true> <include(input.layoutDynamic) show-header=true>
<@body>BODY CONTENT</@body> <@body>BODY CONTENT</@body>
<@footer>FOOTER CONTENT</@footer> <@footer>FOOTER CONTENT</@footer>
</include> </include>

View File

@ -1 +1 @@
<include(data.renderBody, {name: 'Frank'}) age=10/> <include(input.renderBody, {name: 'Frank'}) age=10/>

View File

@ -1 +1 @@
<include(data.renderBody)/> <include(input.renderBody)/>

View File

@ -1 +1 @@
<include(data.renderBody, 'Frank')/> <include(input.renderBody, 'Frank')/>

View File

@ -1 +1 @@
<include(data.renderBody, {name: 'Frank'})/> <include(input.renderBody, {name: 'Frank'})/>

View File

@ -1,8 +1,8 @@
<div> <div>
<h1> <h1>
Hello ${data.name}! You have ${data.count} new messages. Hello ${input.name}! You have ${input.count} new messages.
</h1> </h1>
<p> <p>
<invoke data.renderBody(out)/> <invoke input.renderBody(out)/>
</p> </p>
</div> </div>

View File

@ -1 +1 @@
-- Hello ${data.name}! You have ${data.count} new messages. -- Hello ${input.name}! You have ${input.count} new messages.

View File

@ -1,4 +1,4 @@
<var name="name" value="data.name"/> <var name="name" value="input.name"/>
<html> <html>
<head> <head>
@ -10,7 +10,7 @@
<script type="text/javascript"> <script type="text/javascript">
<div if(foo)></div> <div if(foo)></div>
$(function() { $(function() {
alert('${data.name}'); alert('${input.name}');
}) })
</script> </script>
</body> </body>

View File

@ -1,5 +1,5 @@
<div marko-body="parsed-text"> <div marko-body="parsed-text">
<span if(foo)> <span if(foo)>
Hello ${data.name}! Hello ${input.name}!
</span> </span>
</div> </div>

View File

@ -1,11 +1,11 @@
<div class="message"> <div class="message">
<h1> <h1>
<include(data.title)/> <include(input.title)/>
</h1> </h1>
<div> <div>
<include(data.body)/> <include(input.body)/>
</div> </div>
<div> <div>
<include(data.renderBody)/> <include(input.renderBody)/>
</div> </div>
</div> </div>

View File

@ -1,5 +1,5 @@
<ul> <ul>
<li for(item in data.items)> <li for(item in input.items)>
<h1>${item.title}</h1> <h1>${item.title}</h1>
<include(item.renderBody)/> <include(item.renderBody)/>
</li> </li>

View File

@ -1,8 +1,8 @@
<div class="message"> <div class="message">
<h1> <h1>
<include(data.title)/> <include(input.title)/>
</h1> </h1>
<div> <div>
<include(data.body)/> <include(input.body)/>
</div> </div>
</div> </div>

View File

@ -1,8 +1,8 @@
<div class="message"> <div class="message">
<h1> <h1>
<include(data.title)/> <include(input.title)/>
</h1> </h1>
<div> <div>
<include(data.body)/> <include(input.body)/>
</div> </div>
</div> </div>

View File

@ -1,8 +1,8 @@
<div class="message"> <div class="message">
<h1> <h1>
<b>${data.header.label}:</b> <include(data.header)/> <b>${input.header.label}:</b> <include(input.header)/>
</h1> </h1>
<div> <div>
<b>${data.body.label}:</b> <include(data.body)/> <b>${input.body.label}:</b> <include(input.body)/>
</div> </div>
</div> </div>

View File

@ -1,8 +1,8 @@
<div class="message"> <div class="message">
<h1> <h1>
<b>${data.header.label}:</b> <include(data.header)/> <b>${input.header.label}:</b> <include(input.header)/>
</h1> </h1>
<div> <div>
<b>${data.body.label}:</b> <include(data.body)/> <b>${input.body.label}:</b> <include(input.body)/>
</div> </div>
</div> </div>

View File

@ -1,5 +1,5 @@
<ul> <ul>
<li for(item in data.items)> <li for(item in input.items)>
<h1>${item.title}</h1> <h1>${item.title}</h1>
<include(item.renderBody)/> <include(item.renderBody)/>
</li> </li>

View File

@ -1,5 +1,5 @@
<ul> <ul>
<li for(item in data.items)> <li for(item in input.items)>
<h1>${item.title}</h1> <h1>${item.title}</h1>
<include(item.renderBody)/> <include(item.renderBody)/>
</li> </li>

View File

@ -1,8 +1,8 @@
<div class="message"> <div class="message">
<h1> <h1>
${data.title.label}: <include(data.title)/> ${input.title.label}: <include(input.title)/>
</h1> </h1>
<div> <div>
${data.body.label}: <include(data.body)/> ${input.body.label}: <include(input.body)/>
</div> </div>
</div> </div>

View File

@ -1,4 +1,4 @@
<var tabs=data.tabs/> <var tabs=input.tabs/>
<div class="tabs"> <div class="tabs">
<ul> <ul>

View File

@ -1,4 +1,4 @@
<div for(item in data.items)> <div for(item in input.items)>
Foo: ${item.foo} Foo: ${item.foo}
Body: <invoke item.body.renderBody(out) if(item.body)/> Body: <invoke item.body.renderBody(out) if(item.body)/>
</div> </div>

View File

@ -1,4 +1,4 @@
<var tabs=data.tabs/> <var tabs=input.tabs/>
<div class="tabs"> <div class="tabs">
<ul> <ul>

View File

@ -1,13 +1,13 @@
<div class="overlay"> <div class="overlay">
<div class="overlay-header ${data.header.className || ''}" if(data.header)> <div class="overlay-header ${input.header.className || ''}" if(input.header)>
<invoke data.header.renderBody(out)/> <invoke input.header.renderBody(out)/>
</div> </div>
<div class="overlay-body ${data.body.className}" if(data.body)> <div class="overlay-body ${input.body.className}" if(input.body)>
<invoke data.body.renderBody(out)/> <invoke input.body.renderBody(out)/>
</div> </div>
<div class="overlay-footer ${data.footer.className}" if(data.footer)> <div class="overlay-footer ${input.footer.className}" if(input.footer)>
<invoke data.footer.renderBody(out)/> <invoke input.footer.renderBody(out)/>
</div> </div>
</div> </div>

View File

@ -1,4 +1,4 @@
<test-nested-tags-overlay header=data.header> <test-nested-tags-overlay header=input.header>
<test-nested-tags-overlay:body class="my-body"> <test-nested-tags-overlay:body class="my-body">
Body content Body content

View File

@ -1,4 +1,4 @@
<var tabs=data.tabs/> <var tabs=input.tabs/>
<div class="tabs"> <div class="tabs">
<ul> <ul>

View File

@ -1,4 +1,4 @@
<var tabs=data.tabs/> <var tabs=input.tabs/>
<div class="tabs"> <div class="tabs">
<ul> <ul>

View File

@ -1,13 +1,13 @@
<div class="overlay"> <div class="overlay">
<div class="overlay-header" if(data.header)> <div class="overlay-header" if(input.header)>
<invoke data.header.renderBody(out)/> <invoke input.header.renderBody(out)/>
</div> </div>
<div class="overlay-body ${data.body.className}" if(data.body)> <div class="overlay-body ${input.body.className}" if(input.body)>
<invoke data.body.renderBody(out)/> <invoke input.body.renderBody(out)/>
</div> </div>
<div class="overlay-footer ${data.footer.className}" if(data.footer)> <div class="overlay-footer ${input.footer.className}" if(input.footer)>
<invoke data.footer.renderBody(out)/> <invoke input.footer.renderBody(out)/>
</div> </div>
</div> </div>

View File

@ -1,4 +1,4 @@
<test-nested-tags-overlay header=data.header> <test-nested-tags-overlay header=input.header>
<test-nested-tags-overlay:body class="my-body"> <test-nested-tags-overlay:body class="my-body">
Body content Body content

View File

@ -1,3 +1,3 @@
<my-custom-tag short="World"/> <my-custom-tag short="World"/>
-- Hello ${data.short} -- Hello ${input.short}

View File

@ -1,3 +1,3 @@
--- ---
scanned-b: Hello ${data.name} scanned-b: Hello ${input.name}
--- ---

View File

@ -9,5 +9,5 @@ TAG = {
} }
--> -->
--- ---
scanned-d: Hello ${data.NAME} scanned-d: Hello ${input.NAME}
--- ---

View File

@ -1,3 +1,3 @@
<script foo="bar" ${data.myAttrs} csp-nonce> <script foo="bar" ${input.myAttrs} csp-nonce>
console.log('foo') console.log('foo')
</script> </script>

View File

@ -1 +1 @@
<script>document.write('<div>Hello ${data.name}</div>');</script> <script>document.write('<div>Hello ${input.name}</div>');</script>

View File

@ -1 +1 @@
div.foo.${data.missing} class="baz" div.foo.${input.missing} class="baz"

View File

@ -1,3 +1,3 @@
.foo.bar.baz.bat .foo.bar.baz.bat
.foo.bar.${data.cls}.baz .foo.bar.${input.cls}.baz
.foo.bar.baz class="test" .foo.bar.baz class="test"

View File

@ -1,2 +1,2 @@
div#foo-${data.name} style="color: red;" div#foo-${input.name} style="color: red;"
-- Hello ${data.name}! -- Hello ${input.name}!

View File

@ -1,2 +1,2 @@
div#foo style="color: red;" div#foo style="color: red;"
-- Hello ${data.name}! -- Hello ${input.name}!

View File

@ -1,2 +1,2 @@
div.foo style="color: red;" div.foo style="color: red;"
-- Hello ${data.name}! -- Hello ${input.name}!

View File

@ -1,3 +1,3 @@
<#foo.bar.baz> <#foo.bar.baz>
Hello ${data.name}! Hello ${input.name}!
</> </>

View File

@ -1,4 +1,4 @@
<var name=data.name count=data.count/> <var name=input.name count=input.count/>
<div class=( count>50 ? 'over-50' : null)></div> <div class=( count>50 ? 'over-50' : null)></div>
<div class=( count<50 ? 'under-50' : null)></div> <div class=( count<50 ? 'under-50' : null)></div>

View File

@ -1,6 +1,6 @@
<var rootClass=data.rootClass <var rootClass=input.rootClass
colors=data.colors colors=input.colors
message=data.message /> message=input.message />
<div class="hello-world ${rootClass}"> <div class="hello-world ${rootClass}">
${message} ${message}

View File

@ -1,2 +1,2 @@
<var name=data.name count=data.count/> <var name=input.name count=input.count/>
-- ${name != null ? "Hello ${name.toUpperCase()}! You have ${count} new messages." : null} -- ${name != null ? "Hello ${name.toUpperCase()}! You have ${count} new messages." : null}

View File

@ -1 +1 @@
div style=data.style div style=input.style

View File

@ -1,4 +1,4 @@
<var tabs=data.tabs/> <var tabs=input.tabs/>
<div class="tabs"> <div class="tabs">
<ul> <ul>

Some files were not shown because too many files have changed in this diff Show More