OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <!-- | 2 <!-- |
3 Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 3 Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
4 for details. All rights reserved. Use of this source code is governed by a | 4 for details. All rights reserved. Use of this source code is governed by a |
5 BSD-style license that can be found in the LICENSE file. | 5 BSD-style license that can be found in the LICENSE file. |
6 --> | 6 --> |
7 <html lang="en"> | 7 <html lang="en"> |
8 <head> | 8 <head> |
9 <meta charset="utf-8"> | 9 <meta charset="utf-8"> |
10 <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> | 10 <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> |
11 <link rel="components" href="footer.html"> | 11 <link rel="components" href="footer.html"> |
12 <link rel="components" href="newform.html"> | 12 <link rel="components" href="newform.html"> |
13 <link rel="components" href="toggleall.html"> | 13 <link rel="components" href="toggleall.html"> |
14 <link rel="components" href="item.html"> | 14 <link rel="components" href="item.html"> |
15 <link rel="stylesheet" href="base.css"> | 15 <link rel="stylesheet" href="base.css"> |
16 <title>dart - TodoMVC</title> | 16 <title>dart - TodoMVC</title> |
17 </head> | 17 </head> |
18 <body> | 18 <body> |
19 <section id="todoapp"> | 19 <section id="todoapp"> |
20 <header id="header"> | 20 <header id="header"> |
21 <h1 class='title'>todos</h1> | 21 <h1 class='title'>todos</h1> |
22 <x-todo-form></x-todo-form> | 22 <x-todo-form></x-todo-form> |
23 </header> | 23 </header> |
24 <section id="main"> | 24 <section id="main"> |
25 <x-toggle-all></x-toggle-all> | 25 <x-toggle-all></x-toggle-all> |
26 <ul id="todo-list"> | 26 <ul id="todo-list"> |
27 <template iterate="x in app.todos"> | 27 <template iterate="x in app.todos"> |
28 <template if="viewModel.isVisible(x)"> | 28 <template if="viewModel.isVisible(x)"> |
29 <x-todo-row data-value="todo:x"></x-todo-row> | 29 <x-todo-row todo="{{x}}"></x-todo-row> |
30 </template> | 30 </template> |
31 </template> | 31 </template> |
32 </ul> | 32 </ul> |
33 </section> | 33 </section> |
34 <template if="viewModel.hasElements"> | 34 <template if="viewModel.hasElements"> |
35 <x-todo-footer id="footer"></x-todo-footer> | 35 <x-todo-footer id="footer"></x-todo-footer> |
36 </template> | 36 </template> |
37 </section> | 37 </section> |
38 <footer id="info"> | 38 <footer id="info"> |
39 <p>Double-click to edit a todo.</p> | 39 <p>Double-click to edit a todo.</p> |
(...skipping 20 matching lines...) Expand all Loading... |
60 viewModel.showIncomplete = window.location.hash != '#/completed'; | 60 viewModel.showIncomplete = window.location.hash != '#/completed'; |
61 viewModel.showDone = window.location.hash != '#/active'; | 61 viewModel.showDone = window.location.hash != '#/active'; |
62 dispatch(); | 62 dispatch(); |
63 } | 63 } |
64 window.on.hashChange.add(updateFilters); | 64 window.on.hashChange.add(updateFilters); |
65 window.on.popState.add(updateFilters); | 65 window.on.popState.add(updateFilters); |
66 } | 66 } |
67 </script> | 67 </script> |
68 </body> | 68 </body> |
69 </html> | 69 </html> |
OLD | NEW |