Put tags in li.task HTML to give greater control over CSS
If you put tags in the class attribute of the task node then we can have control to style task labels based on their tags. For example a task tagged with 'important' could have <li class="task important"> so I could style the task red. I could do this with the manual colouring but that's limited and not automatic so I forget. Just popping the tags in the style attr mean I could put li.task.important {color:red} in the custom CSS block in my profile and have it done automatically.
done, please check it out. Due-based tags were added as well
-
Nathanael Boehm commented
AWESOME thank you!
-
Nathanael Boehm commented
I've written a Greasemonkey script to do it for me in the meantime :)
-
Nathanael Boehm commented
Also it means I could it to repurpose due dates as "start from" dates without you having to implement specific functionality for it simply by using CSS to adjust the display of due dates for tasks with a "delay" or "delayedstart" or "startfrom" tag.
-
Nathanael Boehm commented
Would also be helpful if the classes task_invalidated and task_closed were moved up to the li.task class attribute so they could be used to do things like fade or hide tags, due dates, notes etc.
-
Nathanael Boehm commented
It would also mean I could then hide the tags next to the task for cleaner display as the applied tags would be reflected in the styling of the task. I could combine tags so for example an 'important' task could be styled red, an 'urgent' task could be styled as white on red and a task that's both urgent and important (li.task.important.urgent) could be styled white on black with a red border ... or something.