Q163: the goal progress view is called Progress, not Timeline
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
c78045d523
commit
9826b163a9
4 files changed
+11
-12
No files matched your search
@@ -571,7 +571,7 @@ export const zh: Record<string, string> = {
|
|||||||
"Tests": "测试",
|
"Tests": "测试",
|
||||||
"Theme": "主题",
|
"Theme": "主题",
|
||||||
"Thinking": "思考中",
|
"Thinking": "思考中",
|
||||||
"Timeline": "时间线",
|
"Progress": "进度",
|
||||||
"Title": "标题",
|
"Title": "标题",
|
||||||
"Today": "今天",
|
"Today": "今天",
|
||||||
"Token usage": "Token 用量",
|
"Token usage": "Token 用量",
|
||||||
|
|||||||
@@ -19,13 +19,13 @@ import { ProjectDialog } from "./work/ProjectDialog";
|
|||||||
import { TaskDetailDialog } from "./work/TaskDetailDialog";
|
import { TaskDetailDialog } from "./work/TaskDetailDialog";
|
||||||
import { ProjectOverview } from "./work/ProjectOverview";
|
import { ProjectOverview } from "./work/ProjectOverview";
|
||||||
import { ListView } from "./work/ListView";
|
import { ListView } from "./work/ListView";
|
||||||
import { TimelineView } from "./work/TimelineView";
|
import { ProgressView } from "./work/ProgressView";
|
||||||
import { isBusinessTask, latestTaskRun, nextStatus, prettyRunState, providerFor, runBlocker, runTone } from "./work/task-helpers";
|
import { isBusinessTask, latestTaskRun, nextStatus, prettyRunState, providerFor, runBlocker, runTone } from "./work/task-helpers";
|
||||||
import type { PageProps } from "./types";
|
import type { PageProps } from "./types";
|
||||||
import { activeOrgId, type Focus } from "./types";
|
import { activeOrgId, type Focus } from "./types";
|
||||||
import { t } from "../i18n/i18n";
|
import { t } from "../i18n/i18n";
|
||||||
|
|
||||||
type View = "board" | "list" | "timeline";
|
type View = "board" | "list" | "progress";
|
||||||
|
|
||||||
const COLUMNS: ReadonlyArray<{ id: TaskStatus; label: string; tone: string }> = [
|
const COLUMNS: ReadonlyArray<{ id: TaskStatus; label: string; tone: string }> = [
|
||||||
{ id: TASK_STATUS.BACKLOG, label: t("Backlog"), tone: "var(--text-4)" },
|
{ id: TASK_STATUS.BACKLOG, label: t("Backlog"), tone: "var(--text-4)" },
|
||||||
@@ -37,7 +37,7 @@ const COLUMNS: ReadonlyArray<{ id: TaskStatus; label: string; tone: string }> =
|
|||||||
const VIEW_OPTIONS: ReadonlyArray<{ id: View; label: string }> = [
|
const VIEW_OPTIONS: ReadonlyArray<{ id: View; label: string }> = [
|
||||||
{ id: "board", label: t("Board") },
|
{ id: "board", label: t("Board") },
|
||||||
{ id: "list", label: t("List") },
|
{ id: "list", label: t("List") },
|
||||||
{ id: "timeline", label: t("Timeline") },
|
{ id: "progress", label: t("Progress") },
|
||||||
];
|
];
|
||||||
|
|
||||||
export function WorkPage({ snapshot, actions, navigate, focus }: PageProps) {
|
export function WorkPage({ snapshot, actions, navigate, focus }: PageProps) {
|
||||||
@@ -153,9 +153,9 @@ export function WorkPage({ snapshot, actions, navigate, focus }: PageProps) {
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
{view === "timeline" && (
|
{view === "progress" && (
|
||||||
<div className="work-scroll">
|
<div className="work-scroll">
|
||||||
<TimelineView tasks={tasks} goals={goals} projects={projects} />
|
<ProgressView tasks={tasks} goals={goals} projects={projects} />
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
+2
-6
@@ -8,12 +8,8 @@ const SEGMENTS: ReadonlyArray<{ id: TaskStatus; label: string; tone: string }> =
|
|||||||
{ id: TASK_STATUS.BACKLOG, label: t("Backlog"), tone: "var(--panel-3)" },
|
{ id: TASK_STATUS.BACKLOG, label: t("Backlog"), tone: "var(--panel-3)" },
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
/** How far work is per goal and project, as bars of task status; it shows progress, not dates. */
|
||||||
* Execution timeline by goal: each goal carries a segmented bar of its tasks
|
export function ProgressView({ tasks, goals, projects }: { tasks: TaskRecord[]; goals: GoalRecord[]; projects: ProjectRecord[] }) {
|
||||||
* by status (done → review → in progress → backlog), then one row per
|
|
||||||
* project with the same bar at project scope.
|
|
||||||
*/
|
|
||||||
export function TimelineView({ tasks, goals, projects }: { tasks: TaskRecord[]; goals: GoalRecord[]; projects: ProjectRecord[] }) {
|
|
||||||
const unlinked = tasks.filter((task) => !task.goalId);
|
const unlinked = tasks.filter((task) => !task.goalId);
|
||||||
return (
|
return (
|
||||||
<div style={{ display: "flex", flexDirection: "column", gap: 12 }}>
|
<div style={{ display: "flex", flexDirection: "column", gap: 12 }}>
|
||||||
@@ -81,6 +81,9 @@ test("the pinned CEO conversation is the Messages front door", async () => {
|
|||||||
|
|
||||||
// From a task, its goal, run and back are one click each.
|
// From a task, its goal, run and back are one click each.
|
||||||
await page.getByRole("button", { name: "Work" }).click();
|
await page.getByRole("button", { name: "Work" }).click();
|
||||||
|
// The goal view says what it shows: progress, not a timeline without dates.
|
||||||
|
await expect(page.getByText("Progress", { exact: true })).toBeVisible();
|
||||||
|
await expect(page.getByText("Timeline", { exact: true })).toHaveCount(0);
|
||||||
// The CEO's reply to the founder is a chat vehicle, not work: it stays off the board.
|
// The CEO's reply to the founder is a chat vehicle, not work: it stays off the board.
|
||||||
await expect(page.getByRole("button", { name: /Reply to Yang/ })).toHaveCount(0);
|
await expect(page.getByRole("button", { name: /Reply to Yang/ })).toHaveCount(0);
|
||||||
await page.getByRole("button", { name: /Operationalize goal: Ship the FlowPilot MVP\./ }).first().click();
|
await page.getByRole("button", { name: /Operationalize goal: Ship the FlowPilot MVP\./ }).first().click();
|
||||||
|
|||||||
Reference in new issue
Block a user