diff options
author | Raimund Schlüßler <raimund.schluessler@mailbox.org> | 2020-02-13 00:06:19 +0300 |
---|---|---|
committer | Raimund Schlüßler <raimund.schluessler@mailbox.org> | 2020-02-13 00:06:19 +0300 |
commit | 7a291bdebb2b0ffe3f340c0b26795ec93eb67115 (patch) | |
tree | 6f9a56f9a0d7f6b1f1cf5ea7d83aa089b8824a2f /src/components | |
parent | 0e39d9a19734bb22fcbb433f5ea839bb6ade8665 (diff) |
Use new start and due date icons in details view
Signed-off-by: Raimund Schlüßler <raimund.schluessler@mailbox.org>
Diffstat (limited to 'src/components')
-rw-r--r-- | src/components/TheDetails.vue | 22 |
1 files changed, 13 insertions, 9 deletions
diff --git a/src/components/TheDetails.vue b/src/components/TheDetails.vue index 67625776..1416d07d 100644 --- a/src/components/TheDetails.vue +++ b/src/components/TheDetails.vue @@ -72,7 +72,7 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. class="section-content" @click="editProperty('start', $event)"> <span class="section-icon"> - <span :class="[dateIcon(task.startMoment)]" + <span :class="[startDateIcon(task.startMoment)]" class="icon" /> </span> <span class="section-title"> @@ -116,7 +116,7 @@ License along with this library. If not, see <http://www.gnu.org/licenses/>. class="section-content" @click="editProperty('due', $event)"> <span class="section-icon"> - <span :class="[dateIcon(task.dueMoment)]" + <span :class="[dueDateIcon(task.dueMoment)]" class="icon" /> </span> <span class="section-title"> @@ -739,15 +739,19 @@ export default { } }, - dateIcon: function(date) { + startDateIcon: function(date) { if (date.isValid()) { - let c = 'icon-color icon-calendar-due' - if (overdue(date)) { - c += ' icon-calendar-overdue' - } - return c + return `icon-color icon-startdate-${overdue(date) ? 'overdue' : 'due'}` + } else { + return 'icon-bw icon-startdate' + } + }, + + dueDateIcon: function(date) { + if (date.isValid()) { + return `icon-color icon-duedate-${overdue(date) ? 'overdue' : 'due'}` } else { - return 'icon-bw icon-calendar' + return 'icon-bw icon-duedate' } }, |