From d8d1003e781cc328ea6541bace1ac97df6fe7000 Mon Sep 17 00:00:00 2001 From: mARTin Date: Mon, 6 Apr 2026 16:03:16 +0200 Subject: [PATCH] feat: show priority & delegation icons in all views MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit A small icon appears before each task title whenever priority has been set in the Priority View. Works in simple, calendar, list, someday, and kanban. Icon + color mapping ⚡ Zap red #ef4444 Sofort erledigen (urgent + important / ABCDE A) 🕐 CalendarClock blue #3b82f6 Planen (important, not urgent / B) ↗ CornerUpRight orange #f97316 Delegieren (urgent, not important / D) 📦 Archive gray #9ca3af Eliminieren (neither / E) 🕐 Clock yellow #eab308 ABCDE C only Delegation badge 🤖 Bot purple task.delegatedTo === "AI" 👤 User purple task.delegatedTo = person name Hover tooltip shows the full label (e.g. "Sofort erledigen", "Planen"). Icons are 11–12 px so they sit inline without disrupting the task row. v1.88.2 --- package.json | 2 +- src/components/WeeklyView.tsx | 64 +++++++++++++++++++++++++++++++++++ 2 files changed, 65 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 64d7de6..786c452 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "my-weekly-todo-list", - "version": "1.88.1", + "version": "1.88.2", "description": "A web-based weekly task management application that organizes to-dos and calendar events in a single, intuitive weekly view", "main": "index.js", "scripts": { diff --git a/src/components/WeeklyView.tsx b/src/components/WeeklyView.tsx index 40cf9a0..9cc5970 100644 --- a/src/components/WeeklyView.tsx +++ b/src/components/WeeklyView.tsx @@ -84,6 +84,10 @@ import { Pencil, FileText, ArrowLeftRight, + CalendarClock, + CornerUpRight, + Archive, + Bot, } from "lucide-react"; const stripHtml = (html: string) => html.replace(/<[^>]*>/g, '').trim(); @@ -6240,6 +6244,24 @@ export default function WeeklyView() { className="kanban-card-checkbox" /> )} + {(() => { + const pm = getPriorityMeta(task); + return pm ? ( + + + + ) : null; + })()} + {task.delegatedTo && ( + + {task.delegatedTo === "AI" + ? + : } + + )} = { + A: { Icon: Zap, color: "#ef4444" }, + B: { Icon: CalendarClock, color: "#3b82f6" }, + C: { Icon: Clock, color: "#eab308" }, + D: { Icon: CornerUpRight, color: "#f97316" }, + E: { Icon: Archive, color: "#9ca3af" }, + }; + const m = map[task.priority]; + return m ? { ...m, label: task.priority } : null; + } + return null; +} + function TaskItem({ task, isEditing, @@ -9683,6 +9729,24 @@ function TaskItem({ flex: 1, }} > + {(() => { + const pm = getPriorityMeta(task); + return pm ? ( + + + + ) : null; + })()} + {task.delegatedTo && ( + + {task.delegatedTo === "AI" + ? + : } + + )} {showProjectIcons && task.project && (