Task UX: forward-only advance button, auto edit mode, reload on save
TaskViewerView: - Add '→ In Progress' / '→ Done' advance button in toolbar (forward-only, hidden when status is already done) - Styled with primary indigo gradient to distinguish from secondary actions TaskEditorView: - showPreview now defaults false; set to true after load only when body has content — empty tasks open directly in Write mode - Save on an existing task now calls window.location.reload() so the preview/edit mode re-evaluates from the freshly persisted body Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -98,7 +98,7 @@ async function toggleSubTask(sub: SubTask) {
|
||||
toast.show("Failed to update sub-task", "error");
|
||||
}
|
||||
}
|
||||
const showPreview = ref(true);
|
||||
const showPreview = ref(false);
|
||||
const sidebarOpen = ref(true);
|
||||
const editorRef = ref<InstanceType<typeof TiptapEditor> | null>(null);
|
||||
const titleRef = ref<HTMLInputElement | null>(null);
|
||||
@@ -266,6 +266,8 @@ onMounted(async () => {
|
||||
savedProjectId = projectId.value;
|
||||
savedMilestoneId = milestoneId.value;
|
||||
savedParentId = parentId.value;
|
||||
// Start in preview mode only if the task already has body content
|
||||
showPreview.value = body.value.trim().length > 0;
|
||||
}
|
||||
loadSubTasks();
|
||||
} else {
|
||||
@@ -304,6 +306,7 @@ async function save() {
|
||||
savedParentId = parentId.value;
|
||||
dirty.value = false;
|
||||
toast.show("Task saved");
|
||||
window.location.reload();
|
||||
} else {
|
||||
const task = await store.createTask(data);
|
||||
dirty.value = false;
|
||||
|
||||
Reference in New Issue
Block a user