diff options
Diffstat (limited to 'third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates')
6 files changed, 50 insertions, 0 deletions
diff --git a/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/active.hbs b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/active.hbs new file mode 100644 index 0000000000..de244f487d --- /dev/null +++ b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/active.hbs @@ -0,0 +1 @@ +{{todo-list todos=todos}}
\ No newline at end of file diff --git a/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/application.hbs b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/application.hbs new file mode 100644 index 0000000000..70bf1196a9 --- /dev/null +++ b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/application.hbs @@ -0,0 +1,29 @@ +<section id="todoapp" class="todoapp"> + <header id="header" class="header"> + <h1>todos</h1> + <input type="text" id="new-todo" class="new-todo" onkeydown={{action 'createTodo'}} placeholder="What needs to be done?" autofocus> + </header> + {{outlet}} + {{#if (gt model.length 0)}} + <footer id="footer" class="footer"> + <span id="todo-count" class="todo-count"><strong>{{remaining.length}}</strong> {{pluralize 'item' remaining.length}} left</span> + <ul id="filters" class="filters"> + <li>{{#link-to "index" activeClass="selected"}}All{{/link-to}}</li> + <li>{{#link-to "active" activeClass="selected"}}Active{{/link-to}}</li> + <li>{{#link-to "completed" activeClass="selected"}}Completed{{/link-to}}</li> + </ul> + {{#if completed.length}} + <button id="clear-completed" class="clear-completed" onclick={{action 'clearCompleted'}}>Clear completed</button> + {{/if}} + </footer> + {{/if}} +</section> +<footer id="info" class="info"> + <p>Double-click to edit a todo</p> + <p> + Created by + <a href="http://github.com/cibernox">Miguel Camba</a>, + <a href="http://github.com/addyosmani">Addy Osmani</a> + </p> + <p>Part of <a href="http://todomvc.com">TodoMVC</a></p> +</footer>
\ No newline at end of file diff --git a/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/completed.hbs b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/completed.hbs new file mode 100644 index 0000000000..de244f487d --- /dev/null +++ b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/completed.hbs @@ -0,0 +1 @@ +{{todo-list todos=todos}}
\ No newline at end of file diff --git a/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/components/todo-item.hbs b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/components/todo-item.hbs new file mode 100644 index 0000000000..c06975e865 --- /dev/null +++ b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/components/todo-item.hbs @@ -0,0 +1,6 @@ +<div class="view"> + <input type="checkbox" class="toggle" checked={{todo.completed}} onchange={{action 'toggleCompleted'}}> + <label ondblclick={{action 'startEditing'}}>{{todo.title}}</label> + <button onclick={{action 'removeTodo'}} class="destroy"></button> +</div> +<input type="text" class="edit" value={{todo.title}} onblur={{action 'doneEditing' value='target.value'}} onkeydown={{action 'handleKeydown'}} autofocus>
\ No newline at end of file diff --git a/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/components/todo-list.hbs b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/components/todo-list.hbs new file mode 100644 index 0000000000..4e3c2b29f1 --- /dev/null +++ b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/components/todo-list.hbs @@ -0,0 +1,10 @@ +{{#if todos.length}} + {{#if canToggle}} + <input type="checkbox" id="toggle-all" class="toggle-all" checked={{allCompleted}} onchange={{action 'toggleAll'}}> + {{/if}} + <ul id="todo-list" class="todo-list"> + {{#each todos as |todo|}} + {{todo-item todo=todo onStartEdit=(action 'disableToggle') onEndEdit=(action 'enableToggle')}} + {{/each}} + </ul> +{{/if}} diff --git a/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/index.hbs b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/index.hbs new file mode 100644 index 0000000000..7d5565c36a --- /dev/null +++ b/third_party/webkit/PerformanceTests/Speedometer/resources/todomvc/architecture-examples/emberjs/app/templates/index.hbs @@ -0,0 +1,3 @@ +{{#if model.length}} + {{todo-list todos=model}} +{{/if}} |