summaryrefslogtreecommitdiffstats
path: root/client/components/cards/cardDate.js
diff options
context:
space:
mode:
authorMatthias Marschall <mm@agileweboperations.com>2018-01-04 18:34:39 +0100
committerMatthias Marschall <mm@agileweboperations.com>2018-01-04 18:34:39 +0100
commitcd4062c9f1a34ae32d548905fb1e9652db621b3a (patch)
tree85d4715f50ef4e858b59c34cab58d1250ab04575 /client/components/cards/cardDate.js
parent22158b4941104ceb25f6467b68c36b12ebd3a4c7 (diff)
downloadwekan-cd4062c9f1a34ae32d548905fb1e9652db621b3a.tar.gz
wekan-cd4062c9f1a34ae32d548905fb1e9652db621b3a.tar.bz2
wekan-cd4062c9f1a34ae32d548905fb1e9652db621b3a.zip
different icons for start and due date
Diffstat (limited to 'client/components/cards/cardDate.js')
-rw-r--r--client/components/cards/cardDate.js14
1 files changed, 8 insertions, 6 deletions
diff --git a/client/components/cards/cardDate.js b/client/components/cards/cardDate.js
index 3f69f384..abf6a42b 100644
--- a/client/components/cards/cardDate.js
+++ b/client/components/cards/cardDate.js
@@ -171,11 +171,12 @@ class CardStartDate extends CardDate {
}
classes() {
+ let classes = 'start-date' + ' ';
if (this.date.get().isBefore(this.now.get(), 'minute') &&
this.now.get().isBefore(this.data().dueAt)) {
- return 'current';
+ classes += 'current';
}
- return '';
+ return classes;
}
showTitle() {
@@ -200,13 +201,14 @@ class CardDueDate extends CardDate {
}
classes() {
+ let classes = 'due-date' + ' ';
if (this.now.get().diff(this.date.get(), 'days') >= 2)
- return 'long-overdue';
+ classes += 'long-overdue';
else if (this.now.get().diff(this.date.get(), 'minute') >= 0)
- return 'due';
+ classes += 'due';
else if (this.now.get().diff(this.date.get(), 'days') >= -1)
- return 'almost-due';
- return '';
+ classes += 'almost-due';
+ return classes;
}
showTitle() {