Skip to content
Browse files

minor style fixes on the todo list app

  • Loading branch information...
1 parent 6acc741 commit f7c0da94272a5adb03d316a76b11c753b8ad6501 Techwraith committed Feb 8, 2012
View
19 examples/todo_app/app/views/todos/index.html.ejs
@@ -1,13 +1,12 @@
<div class="hero-unit">
- <% if (todos.length) { %>
- <h3>ToDos:</h3>
- <ul>
- <% for (var i in todos) { %>
- <li><a href="/todos/<%= todos[i].id; %>"><%= todos[i].title; %></a> - <%= todos[i].status; %></li>
- <% } %>
- </ul>
- <% } else { %>
- No ToDos yet
+ <h1>To Do List</h1>
+ <a href="/todos/add" class="btn pull-right">Create a new To Do</a></p>
+</div>
+<% if (todos.length) { %>
+<div class="row todo-item">
+ <% for (var i in todos) { %>
+ <div class="span8"><h3><a href="/todos/<%= todos[i].id; %>"><%= todos[i].title; %></a></h3></div>
+ <div class="span4"><h3><i class="icon-list-alt"></i><%= todos[i].status; %></h3></div>
<% } %>
- <a href="/todos/add">Create a new ToDo</a>
</div>
+<% } %>
View
9 examples/todo_app/app/views/todos/show.html.ejs
@@ -1,13 +1,13 @@
<div class="hero-unit">
- <a href="/todos">&laquo; back to index</a>
<h3><%= todo.title; %></h3>
+ <div class="pull-right">
<% if (todo.status == 'open') { %>
- <form id="finish-todo" action="/todos/update" method="POST">
+ <form id="finish-todo" class="hidden" action="/todos/update" method="POST">
<input type="hidden" name="status" value="done"/>
<input type="hidden" name="id" value="<%= todo.id; %>"/>
<input type="hidden" name="title" value="<%= todo.title; %>">
</form>
- <a href="#" class="btn" id="finish-btn">Finish</a>
+ <span><a href="#" class="btn btn-primary btn-large" id="finish-btn">Finish To Do</a></span>
<script type="text/javascript">
var form = $('#finish-todo');
$('#finish-btn').click(function(e){
@@ -22,6 +22,7 @@
})
</script>
<% } else { %>
- <p>This todo is finished!</p>
+ <p>This to do is finished!</p>
<% } %>
+ </div>
</div>
View
504 examples/todo_app/log/access.log
504 additions, 0 deletions not shown because the diff is too large. Please use a local Git client to view these changes.
View
24 examples/todo_app/log/stdout.log
@@ -1,4 +1,4 @@
-[Wed, 08 Feb 2012 09:53:42 GMT] INFO Server starting with config: {
+[Wed, 08 Feb 2012 10:08:03 GMT] INFO Server starting with config: {
"environment": "development",
"workers": 1,
"port": 4000,
@@ -23,9 +23,19 @@
"detailedErrors": true,
"hostname": null
}
-[Wed, 08 Feb 2012 09:53:42 GMT] INFO Metrics server started on port 4001
-[Wed, 08 Feb 2012 09:53:42 GMT] INFO Creating 1 worker process.
-[Wed, 08 Feb 2012 09:53:42 GMT] NOTICE [object Object]
-[Wed, 08 Feb 2012 09:53:42 GMT] INFO Server worker running in development on port 4000 with a PID of: 23613
-[Wed, 08 Feb 2012 09:53:42 GMT] DEBUG LOGGING STARTED ============================================
-[Wed, 08 Feb 2012 09:53:42 GMT] DEBUG ============================================================
+[Wed, 08 Feb 2012 10:08:03 GMT] INFO Metrics server started on port 4001
+[Wed, 08 Feb 2012 10:08:03 GMT] INFO Creating 1 worker process.
+[Wed, 08 Feb 2012 10:08:03 GMT] NOTICE [object Object]
+[Wed, 08 Feb 2012 10:08:03 GMT] INFO Server worker running in development on port 4000 with a PID of: 24209
+[Wed, 08 Feb 2012 10:08:03 GMT] DEBUG LOGGING STARTED ============================================
+[Wed, 08 Feb 2012 10:08:03 GMT] DEBUG ============================================================
+[Wed, 08 Feb 2012 10:15:46 GMT] DEBUG POST /todos
+[Wed, 08 Feb 2012 10:15:46 GMT] DEBUG received data
+[Wed, 08 Feb 2012 10:22:24 GMT] DEBUG POST /todos
+[Wed, 08 Feb 2012 10:22:24 GMT] DEBUG received data
+[Wed, 08 Feb 2012 10:25:22 GMT] DEBUG POST /todos
+[Wed, 08 Feb 2012 10:25:22 GMT] DEBUG received data
+[Wed, 08 Feb 2012 10:25:26 GMT] DEBUG POST /todos
+[Wed, 08 Feb 2012 10:25:26 GMT] DEBUG received data
+[Wed, 08 Feb 2012 10:25:37 GMT] DEBUG POST /todos
+[Wed, 08 Feb 2012 10:25:37 GMT] DEBUG received data
View
13 examples/todo_app/public/css/style.css
@@ -24,3 +24,16 @@ body {
.geddy-welcome-box .btn-large {
margin-top: 20px;
}
+
+.todo-item div {
+ background: white;
+ border-bottom: 2px solid #ccc;
+}
+
+.todo-item div > * {
+ padding: 20px;
+}
+
+.todo-item div h3 i {
+ margin: 5px;
+}

0 comments on commit f7c0da9

Please sign in to comment.
Something went wrong with that request. Please try again.