Skip to content

Commit

Permalink
Merge branch 'master' of github.com:snodgrass23/knockoutjs-demo
Browse files Browse the repository at this point in the history
  • Loading branch information
David Becher committed Feb 18, 2011
2 parents 5313d17 + 19c0500 commit 9d59168
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 13 deletions.
5 changes: 3 additions & 2 deletions index.html
@@ -1,4 +1,3 @@

<!DOCTYPE html>
<html>

Expand Down Expand Up @@ -67,7 +66,9 @@ <h3>Task Summary: </h3>
<div class="todo_done">
<div class="display">
<input class="check" type="checkbox" data-bind="checked: isDone" />
<div class="todo-content" data-bind="text: item"></div>
<div class="todo-content" data-bind="text: item">
<input data-bind="value: item, valueUpdate: 'afterkeydown'" class="enteredItem" />
</div>
<div class="todo-hours">
<input data-bind="value: enteredTime, valueUpdate: 'afterkeydown', disable: isDone" class="enteredTime" /> /
<input data-bind="value: hours, valueUpdate: 'afterkeydown', disable: isDone" class="totalTime" />
Expand Down
16 changes: 6 additions & 10 deletions main.css
Expand Up @@ -134,20 +134,15 @@ html {
#todo-list .editing .edit {
display: block;
}
#todo-list .editing input {
width: 444px;
input.enteredItem {
font-size: 24px;
font-family: inherit;
margin: 0;
line-height: 1.6em;
border: 0;
outline: none;
padding: 10px 7px 0px 27px;
border: 1px solid #999999;
-moz-box-shadow: rgba(0, 0, 0, 0.2) 0 1px 2px 0 inset;
-webkit-box-shadow: rgba(0, 0, 0, 0.2) 0 1px 2px 0 inset;
-o-box-shadow: rgba(0, 0, 0, 0.2) 0 1px 2px 0 inset;
box-shadow: rgba(0, 0, 0, 0.2) 0 1px 2px 0 inset;
padding: 0px 0px 0px 10px;
border: 1px solid transparent;
}
#todo-list .check {
position: relative;
Expand Down Expand Up @@ -386,7 +381,6 @@ ul li.danger, ul li.danger input{
.done .todo-hours, .done .todo-hours input{
color: #ccc;
}

#summary {
position: absolute;
right: 0;
Expand All @@ -404,7 +398,9 @@ ul li.danger, ul li.danger input{
font-weight: bold;
margin-bottom: 8px;
}

#summary input.enteredItem {
font-size:70%;
}
#summary li .check, #summary li .todo-hours, #summary li .todo-destroy, #summary li .todo-input{
display: none;
}
Expand Down
2 changes: 1 addition & 1 deletion main.js
Expand Up @@ -55,7 +55,7 @@ taskList.prototype = {
},

addItem: function() {
this.tasks.push(new task({
this.tasks.push(new itemViewModel({
name: this.itemToAdd(),
totalTime: parseInt(this.addTime())
}));
Expand Down

0 comments on commit 9d59168

Please sign in to comment.