mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-08-01 07:21:15 +00:00
Changes to habits.stly to support tasks
This commit is contained in:
parent
400ac40212
commit
30cc513f54
2 changed files with 24 additions and 38 deletions
|
|
@ -8,24 +8,7 @@
|
|||
.done { background-color: rgb(217, 217, 217); color: rgb(153, 153, 153); }
|
||||
.reward { background-color: white; }
|
||||
|
||||
.panel {
|
||||
float:left;
|
||||
margin: 10px;
|
||||
min-width: 300px;
|
||||
/*
|
||||
border: 1px solid #EEEEEE;
|
||||
border-radius: 4px 4px 4px 4px;
|
||||
box-shadow: 0 1px 1px #777777;
|
||||
padding: 10px;
|
||||
*/
|
||||
}
|
||||
|
||||
.panel ul {
|
||||
padding:0px;
|
||||
margin-left:0px;
|
||||
}
|
||||
|
||||
.habit, .reward {
|
||||
.task {
|
||||
list-style:none;
|
||||
-moz-border-radius: 3px;
|
||||
-webkit-border-radius: 3px;
|
||||
|
|
@ -36,10 +19,15 @@
|
|||
text-shadow:none;
|
||||
}
|
||||
|
||||
.habit:hover, .reward:hover {
|
||||
.task:hover {
|
||||
cursor: move;
|
||||
}
|
||||
|
||||
.task-controls, .task-text {
|
||||
display:inline;
|
||||
}
|
||||
|
||||
|
||||
.vote-up, .vote-down {
|
||||
text-decoration:none;
|
||||
}
|
||||
|
|
@ -96,13 +84,13 @@
|
|||
|
||||
#money { float:right; }
|
||||
|
||||
.habit-meta { float:right; }
|
||||
.task-meta { float:right; }
|
||||
|
||||
.habit-meta .edit-link {
|
||||
.task-meta .edit-link {
|
||||
display: none;
|
||||
}
|
||||
|
||||
li:hover .habit-meta .edit-link {
|
||||
li:hover .task-meta .edit-link {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -16,8 +16,18 @@
|
|||
</div>
|
||||
|
||||
<task:>
|
||||
<li data-id={{:task.id}} class="{taskClasses(:task.type, :task.completed)}">
|
||||
<label>
|
||||
<li data-id={{:task.id}} class="task {taskClasses(:task.type, :task.completed)}">
|
||||
<div class="task-meta">
|
||||
<!-- TODO make this a popover -->
|
||||
<a x-bind=click:toggleEdit data-selector="{{:task.id}}-edit" class="edit-link">Edit</a>
|
||||
|
||||
<!--<a class="edit-link" href="#/<%= id %>/edit">Edit</a>-->
|
||||
{#if :task.notes}
|
||||
<a href="#" data-content="{:task.notes}" data-original-title="{:task.text}" class='task-notes'><i class="icon-comment"></i></a>
|
||||
{/}
|
||||
</div>
|
||||
|
||||
<div class="task-controls">
|
||||
<!-- Habits -->
|
||||
{#if equal(:task.type, 'habit')}
|
||||
{#if :task.up}<a data-direction=up x-bind=click:vote><img src="img/add.png" /></a>{/}
|
||||
|
|
@ -30,21 +40,9 @@
|
|||
<!--TODO this was part of input below <%= done ? "class='vote-down' checked='checked'" : "class='vote-up'" %>-->
|
||||
<input type="checkbox" checked={:task.completed} />
|
||||
{/}
|
||||
<i></i>
|
||||
</label>
|
||||
<div x-bind=keydown:shortcuts contenteditable>{unescaped :task.text}</div>
|
||||
|
||||
<!-- TODO make this a popover -->
|
||||
<a x-bind=click:toggleEdit data-selector="{{:task.id}}-edit">Edit</a>
|
||||
|
||||
<!--<span class="habit-text"><%= name %></span>-->
|
||||
|
||||
<div class='habit-meta'>
|
||||
<!--<a class="edit-link" href="#/<%= id %>/edit">Edit</a>-->
|
||||
{#if :task.notes}
|
||||
<a href="#" data-content="{:task.notes}" data-original-title="{:task.text}" class='task-notes'><i class="icon-comment"></i></a>
|
||||
{/}
|
||||
</div>
|
||||
<div class="task-text" x-bind=keydown:shortcuts contenteditable>{unescaped :task.text}</div>
|
||||
|
||||
<app:editPopover />
|
||||
</li>
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue