diff --git a/package.json b/package.json index 0f561ed..f44305f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "my-weekly-todo-list", - "version": "1.27.0", + "version": "1.27.1", "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/app/globals.css b/src/app/globals.css index 55d076e..5ec2702 100644 --- a/src/app/globals.css +++ b/src/app/globals.css @@ -1560,6 +1560,12 @@ h3 { color: #fff; } +.someday-tab-btn-h.drag-over { + outline: 2px dashed var(--weekly-accent, #6366f1); + outline-offset: -1px; + background: rgba(99, 102, 241, 0.12); +} + .someday-tab-count { display: inline-flex; align-items: center; diff --git a/src/components/WeeklyView.tsx b/src/components/WeeklyView.tsx index 59b5c95..e1547da 100644 --- a/src/components/WeeklyView.tsx +++ b/src/components/WeeklyView.tsx @@ -1470,6 +1470,7 @@ export default function WeeklyView() { const [newTabNameValue, setNewTabNameValue] = useState(""); const [creatingNewTab, setCreatingNewTab] = useState(false); const [creatingNewTabName, setCreatingNewTabName] = useState(""); + const [dragOverTab, setDragOverTab] = useState(null); useEffect(() => { if (typeof window !== "undefined") { @@ -6448,8 +6449,27 @@ export default function WeeklyView() { )}
{somedayTabs.map(tab => ( editingTabName === tab ? ( @@ -6478,9 +6498,31 @@ export default function WeeklyView() { }} /> ) : ( -
+
{ + if (e.dataTransfer.types.includes("text/list-id")) { + e.preventDefault(); + e.dataTransfer.dropEffect = "move"; + setDragOverTab(tab); + } + }} + onDragLeave={() => setDragOverTab(null)} + onDrop={(e) => { + const listId = e.dataTransfer.getData("text/list-id"); + if (listId) { + e.preventDefault(); + e.stopPropagation(); + assignListToTab(listId, tab); + setDraggingListId(null); + setDropTargetListIndex(null); + } + setDragOverTab(null); + }} + >