Date time is now visible on each task

This commit is contained in:
Vyn 2024-04-11 14:08:09 +02:00
parent 839109b77b
commit 317b515e22
4 changed files with 27 additions and 10 deletions

View file

@ -10,11 +10,19 @@ import QtQuick.Layouts
import Mirai
RowLayout {
id: control
property taskItem task
function getFormatedText() {
if (task?.time && task.time != "") {
return `<font color=\"${colorPalette.selected.palette.overlay1}\">${task.time} \></font> ${task.text}`
}
return task.text
}
AppCheckbox {
id: checkbox
text: task.text
text: control.getFormatedText()
checked: task.state === 'DONE'
textComponent.color: task.date < internal.todayDate ? colorPalette.selected.palette.pink
// : task.date === internal.todayDate ? colorPalette.selected.palette.sapphire