@nextclaw/ui 0.22.5 → 0.24.0-beta.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +25 -0
- package/dist/assets/{api-aEu9cEI8.js → api-CoqPRKmF.js} +5 -5
- package/dist/assets/{appearance-settings-page-z4DaHc_E.js → appearance-settings-page-CPoFZLw8.js} +1 -1
- package/dist/assets/{book-open-DYRapW_h.js → book-open-jcUt0rr9.js} +1 -1
- package/dist/assets/{channels-list-page-x07sGqsT.js → channels-list-page-anMJAkfK.js} +2 -2
- package/dist/assets/{config-split-page-DJDp86Ne.js → config-split-page-AcuFnbIC.js} +1 -1
- package/dist/assets/{confirm-dialog-BALTnP33.js → confirm-dialog-B-atCfC5.js} +1 -1
- package/dist/assets/{createLucideIcon-CgM0rnsa.js → createLucideIcon-Blz0FzrV.js} +1 -1
- package/dist/assets/{desktop-capabilities-page-4-v3wKLV.js → desktop-capabilities-page-8lKF_Ob-.js} +1 -1
- package/dist/assets/desktop-update-config-DABXDpbj.js +1 -0
- package/dist/assets/{dist-BjYvUhPL.js → dist-D8kcEpTf.js} +1 -1
- package/dist/assets/{dist-N9zc5bkM.js → dist-eH-_j8yU.js} +1 -1
- package/dist/assets/doc-browser-DJEMr7Zk.js +1 -0
- package/dist/assets/{doc-browser-DwRLokCI.js → doc-browser-DzXRehlW.js} +1 -1
- package/dist/assets/{doc-browser-context-BDuypObS.js → doc-browser-context-BlbUcg2J.js} +1 -1
- package/dist/assets/{extensions-DFQXmSwG.js → extensions-mquwAJ2Z.js} +1 -1
- package/dist/assets/{form-actions-CzGmrPAv.js → form-actions-CaZDGEmB.js} +1 -1
- package/dist/assets/index-DyR5iR0O.css +1 -0
- package/dist/assets/{index-zuqzAvNx.js → index-XxXj8WDS.js} +10 -10
- package/dist/assets/loader-circle-0qPOOYQ5.js +1 -0
- package/dist/assets/{mcp-marketplace-page-COUopIOc.js → mcp-marketplace-page-gFtgyueL.js} +1 -1
- package/dist/assets/mcp-marketplace-page-uanamJ6L.js +1 -0
- package/dist/assets/{model-config-page-g9_-hZqZ.js → model-config-page-hFBpeRAO.js} +1 -1
- package/dist/assets/{navigation-link-Ci4Z7Phi.js → navigation-link-Hb5Z0UxZ.js} +1 -1
- package/dist/assets/plus-CYOvNvcV.js +1 -0
- package/dist/assets/privacy-settings-page-C18zo3ox.js +1 -0
- package/dist/assets/projects-C8Gm9RS8.js +1 -0
- package/dist/assets/providers-config-page-YU0-AOXJ.js +1 -0
- package/dist/assets/react-DF-kP7iN.js +8 -0
- package/dist/assets/{refresh-cw-C-3_thgr.js → refresh-cw-ZHKfE3yx.js} +1 -1
- package/dist/assets/remote-B_utkBra.js +1 -0
- package/dist/assets/{rotate-cw-DSFTq_yu.js → rotate-cw-CLhOXGwE.js} +1 -1
- package/dist/assets/runtime-config-page-Dmy1A_0Y.js +1 -0
- package/dist/assets/{save-CpPr78_S.js → save-CWuuZs77.js} +1 -1
- package/dist/assets/{search-msqk2-rd.js → search-DcmsKAn2.js} +1 -1
- package/dist/assets/{search-config-page-BqoDbKpM.js → search-config-page-CxBacx6W.js} +1 -1
- package/dist/assets/{secrets-config-page-GsahsEVw.js → secrets-config-page-B4py8-KR.js} +2 -2
- package/dist/assets/security-config-CTP4IQWw.js +1 -0
- package/dist/assets/{select-DPKCWajZ.js → select-BEr0Iy_f.js} +1 -1
- package/dist/assets/skeleton-B2NHluWf.js +1 -0
- package/dist/assets/{tag-chip-ClBWeQ4p.js → tag-chip-ByqDkn6g.js} +1 -1
- package/dist/assets/x-CENkFyK5.js +1 -0
- package/dist/index.html +21 -21
- package/package.json +6 -6
- package/src/app/configs/__tests__/app-navigation.config.test.ts +20 -0
- package/src/app/configs/app-navigation.config.ts +10 -0
- package/src/app/index.tsx +8 -1
- package/src/features/chat/components/conversation/__tests__/chat-conversation-workspace-section.test.tsx +29 -0
- package/src/features/chat/components/conversation/chat-conversation-workspace-section.tsx +4 -2
- package/src/features/chat/components/layout/__tests__/chat-page-shell.test.tsx +21 -0
- package/src/features/chat/components/layout/chat-page-shell.tsx +19 -4
- package/src/features/chat/features/conversation/hooks/__tests__/use-session-conversation-controller.test.tsx +1 -1
- package/src/features/chat/features/conversation/hooks/use-session-conversation-controller.ts +0 -1
- package/src/features/chat/features/conversation/utils/__tests__/session-message-composer.utils.test.ts +11 -4
- package/src/features/chat/features/conversation/utils/__tests__/session-queued-input.utils.test.ts +0 -1
- package/src/features/chat/features/conversation/utils/session-message-composer.utils.ts +10 -11
- package/src/features/chat/features/input/input-surface-plugins/__tests__/context-reference-plugin.test.ts +1 -0
- package/src/features/chat/features/message/hooks/use-chat-message-actions.tsx +0 -2
- package/src/features/chat/features/runtime/utils/chat-runtime.utils.ts +0 -14
- package/src/features/chat/features/session/components/__tests__/chat-sidebar-project-groups.test.tsx +70 -22
- package/src/features/chat/features/session/components/chat-sidebar-project-groups.tsx +79 -32
- package/src/features/chat/features/session/utils/__tests__/chat-sidebar-session-groups.utils.test.ts +2 -0
- package/src/features/chat/features/session/utils/chat-run-metadata.utils.ts +0 -6
- package/src/features/chat/features/session/utils/chat-sidebar-session-groups.utils.ts +2 -0
- package/src/features/chat/features/welcome/utils/__tests__/chat-welcome-project-options.utils.test.ts +1 -0
- package/src/features/chat/managers/__tests__/chat-session-list.manager.test.ts +27 -0
- package/src/features/chat/pages/__tests__/ncp-chat-page.test.ts +2 -14
- package/src/features/chat/types/chat-run.types.ts +0 -1
- package/src/features/panel-apps/managers/__tests__/panel-app-bridge.manager.test.ts +51 -0
- package/src/features/panel-apps/managers/panel-app-bridge.manager.ts +37 -2
- package/src/features/projects/AGENTS.md +6 -0
- package/src/features/projects/components/project-agreement.tsx +92 -0
- package/src/features/projects/components/project-artifacts.test.tsx +77 -0
- package/src/features/projects/components/project-artifacts.tsx +188 -0
- package/src/features/projects/components/project-overview.tsx +150 -0
- package/src/features/projects/components/project-requests.tsx +57 -0
- package/src/features/projects/components/project-runs.tsx +60 -0
- package/src/features/projects/components/project-section.tsx +60 -0
- package/src/features/projects/components/project-skills.tsx +53 -0
- package/src/features/projects/components/project-work-items.test.tsx +78 -0
- package/src/features/projects/components/project-work-items.tsx +272 -0
- package/src/features/projects/hooks/use-project-observation.test.tsx +93 -0
- package/src/features/projects/hooks/use-project-observation.ts +85 -0
- package/src/features/projects/index.ts +2 -0
- package/src/features/projects/pages/project-home-page.tsx +253 -0
- package/src/features/projects/pages/projects-page.test.tsx +366 -0
- package/src/features/projects/presenters/project-home.presenter.test.ts +74 -0
- package/src/features/projects/presenters/project-home.presenter.ts +55 -0
- package/src/features/projects/utils/project-artifact-view.utils.test.ts +63 -0
- package/src/features/projects/utils/project-artifact-view.utils.ts +62 -0
- package/src/features/projects/utils/project-request-response.utils.test.ts +44 -0
- package/src/features/projects/utils/project-request-response.utils.ts +39 -0
- package/src/shared/lib/i18n/index.ts +6 -2
- package/src/shared/lib/i18n/locales/en-US/projects.json +90 -0
- package/src/shared/lib/i18n/locales/zh-CN/projects.json +90 -0
- package/src/shared/lib/ui-document-title/__tests__/ui-document-title.test.ts +6 -0
- package/src/shared/lib/ui-document-title/index.ts +1 -0
- package/dist/assets/desktop-update-config-Cl-_XHqU.js +0 -1
- package/dist/assets/doc-browser-JlXVLNRe.js +0 -1
- package/dist/assets/index-CwCTiMM9.css +0 -1
- package/dist/assets/loader-circle-D9etMT9f.js +0 -1
- package/dist/assets/mcp-marketplace-page-DxPPmYqh.js +0 -1
- package/dist/assets/plus-DKGD04AO.js +0 -1
- package/dist/assets/privacy-settings-page-pNhQQT4r.js +0 -1
- package/dist/assets/providers-config-page-DftW_6KU.js +0 -1
- package/dist/assets/react-CVFx225w.js +0 -8
- package/dist/assets/remote-DS2TkMPm.js +0 -1
- package/dist/assets/runtime-config-page-Cd9sOYvn.js +0 -1
- package/dist/assets/security-config-BnHQyrtG.js +0 -1
- package/dist/assets/skeleton-BsR5rwB7.js +0 -1
- package/dist/assets/x-Dp5GAFmP.js +0 -1
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { nextclawClient } from "@/shared/lib/api";
|
|
2
|
+
|
|
3
|
+
export type ProjectRequestDecision = "confirmed" | "rejected";
|
|
4
|
+
|
|
5
|
+
export type SendProjectRequestResponseInput = {
|
|
6
|
+
requestId: string;
|
|
7
|
+
sessionId: string;
|
|
8
|
+
decision: ProjectRequestDecision;
|
|
9
|
+
prompt: string;
|
|
10
|
+
};
|
|
11
|
+
|
|
12
|
+
export async function sendProjectRequestResponse(
|
|
13
|
+
input: SendProjectRequestResponseInput,
|
|
14
|
+
) {
|
|
15
|
+
const messageId = `project-response-${input.requestId}-${input.decision}`;
|
|
16
|
+
return await nextclawClient.agentRuns.send({
|
|
17
|
+
sessionId: input.sessionId,
|
|
18
|
+
idempotencyKey: messageId,
|
|
19
|
+
delivery: "prefer-steer",
|
|
20
|
+
message: {
|
|
21
|
+
id: messageId,
|
|
22
|
+
sessionId: input.sessionId,
|
|
23
|
+
role: "user",
|
|
24
|
+
status: "final",
|
|
25
|
+
timestamp: new Date().toISOString(),
|
|
26
|
+
parts: [{
|
|
27
|
+
type: "text",
|
|
28
|
+
text: `${input.decision === "confirmed" ? "确认" : "拒绝"}:${input.prompt}`,
|
|
29
|
+
}],
|
|
30
|
+
metadata: {
|
|
31
|
+
project_observation_response: {
|
|
32
|
+
protocol: "nextclaw.project/v1",
|
|
33
|
+
requestId: input.requestId,
|
|
34
|
+
decision: input.decision,
|
|
35
|
+
},
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
});
|
|
39
|
+
}
|
|
@@ -10,6 +10,7 @@ import zhMarketplace from './locales/zh-CN/marketplace.json';
|
|
|
10
10
|
import zhInbox from './locales/zh-CN/inbox.json';
|
|
11
11
|
import zhPathPicker from './locales/zh-CN/path-picker.json';
|
|
12
12
|
import zhPwa from './locales/zh-CN/pwa.json';
|
|
13
|
+
import zhProjects from './locales/zh-CN/projects.json';
|
|
13
14
|
import zhRemote from './locales/zh-CN/remote.json';
|
|
14
15
|
import zhRuntimeControl from './locales/zh-CN/runtime-control.json';
|
|
15
16
|
import zhSearch from './locales/zh-CN/search.json';
|
|
@@ -25,6 +26,7 @@ import enMarketplace from './locales/en-US/marketplace.json';
|
|
|
25
26
|
import enInbox from './locales/en-US/inbox.json';
|
|
26
27
|
import enPathPicker from './locales/en-US/path-picker.json';
|
|
27
28
|
import enPwa from './locales/en-US/pwa.json';
|
|
29
|
+
import enProjects from './locales/en-US/projects.json';
|
|
28
30
|
import enRemote from './locales/en-US/remote.json';
|
|
29
31
|
import enRuntimeControl from './locales/en-US/runtime-control.json';
|
|
30
32
|
import enSearch from './locales/en-US/search.json';
|
|
@@ -60,7 +62,8 @@ const zhCatalog: MessageCatalog = {
|
|
|
60
62
|
...zhDocBrowser,
|
|
61
63
|
...zhPathPicker,
|
|
62
64
|
...zhPwa,
|
|
63
|
-
...zhChannelAuth
|
|
65
|
+
...zhChannelAuth,
|
|
66
|
+
...zhProjects
|
|
64
67
|
};
|
|
65
68
|
|
|
66
69
|
const enCatalog: MessageCatalog = {
|
|
@@ -78,7 +81,8 @@ const enCatalog: MessageCatalog = {
|
|
|
78
81
|
...enDocBrowser,
|
|
79
82
|
...enPathPicker,
|
|
80
83
|
...enPwa,
|
|
81
|
-
...enChannelAuth
|
|
84
|
+
...enChannelAuth,
|
|
85
|
+
...enProjects
|
|
82
86
|
};
|
|
83
87
|
|
|
84
88
|
const CATALOGS: Record<I18nLanguage, MessageCatalog> = {
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
{
|
|
2
|
+
"projectsTitle": "Projects",
|
|
3
|
+
"projectsOverview": "Overview",
|
|
4
|
+
"projectsWork": "Work items",
|
|
5
|
+
"projectsArtifacts": "Artifacts",
|
|
6
|
+
"projectsSkills": "Skills",
|
|
7
|
+
"projectsSkillsCountSuffix": "skills",
|
|
8
|
+
"projectsAgreement": "Working rules",
|
|
9
|
+
"projectsVisionAndContext": "Vision and context",
|
|
10
|
+
"projectsLoading": "Loading project…",
|
|
11
|
+
"projectsLoadFailed": "Failed to load project",
|
|
12
|
+
"projectsEmpty": "No registered projects",
|
|
13
|
+
"projectsChoose": "Choose a project",
|
|
14
|
+
"projectsAsOf": "Observed at",
|
|
15
|
+
"projectsQuality": "Data quality",
|
|
16
|
+
"projectsQuality_complete": "Complete",
|
|
17
|
+
"projectsQuality_partial": "Partially available",
|
|
18
|
+
"projectsQuality_unavailable": "Unavailable",
|
|
19
|
+
"projectsNoSummary": "This project has no configured summary. Existing sources remain available under Working rules.",
|
|
20
|
+
"projectsObservationSetupTitle": "Set up project observation",
|
|
21
|
+
"projectsObservationSetupDescription": "This project has no observation convention yet. Ask AI to inspect existing materials, recommend a work-item lifecycle and artifact scope, and prepare the project configuration, always-on rule, and project tracking Skill. Nothing is written until you confirm.",
|
|
22
|
+
"projectsObservationSetupAction": "Let AI set up project observation",
|
|
23
|
+
"projectsObservationSetupPrompt": "Follow the built-in project observation setup guidance to establish a durable work-tracking convention for this project. Read the existing materials, then directly propose one editable recommendation containing all three assets: .nextclaw/project.yaml, the minimal always-on section in the root AGENTS.md, and the project-specific .agents/skills/project-work-tracking/SKILL.md. A Workflow describes how one work item progresses; it is not the macro lifecycle of the whole project. Markers must be emitted before a stage starts, never batched at the end. Do not turn this into a long interview; recommend directly when the evidence is sufficient. Write nothing until I confirm, then write and verify all three files together.",
|
|
24
|
+
"projectsNoData": "No observable data",
|
|
25
|
+
"projectsUnavailable": "Currently unavailable",
|
|
26
|
+
"projectsWorkList": "List",
|
|
27
|
+
"projectsWorkBoard": "Board",
|
|
28
|
+
"projectsWorkGantt": "Gantt",
|
|
29
|
+
"projectsWorkViews": "Work item views",
|
|
30
|
+
"projectsWorkDetails": "Work item details",
|
|
31
|
+
"projectsCloseDetails": "Close details",
|
|
32
|
+
"projectsNoWork": "No work items explicitly reported by AI",
|
|
33
|
+
"projectsWorkNeedsSetup": "Set up project observation first so AI can report real progress using this project's workflow.",
|
|
34
|
+
"projectsWorkNoSessions": "No conversation has started in this project yet. Once substantive project work begins, AI-reported progress will appear here.",
|
|
35
|
+
"projectsWorkNoReports": "AI has not explicitly reported any work items from the existing project conversations yet. Real progress will appear here as the work continues.",
|
|
36
|
+
"projectsAiActivity": "AI runs",
|
|
37
|
+
"projectsAiRun": "Project session",
|
|
38
|
+
"projectsRunUnreported": "Work item and stage not reported yet",
|
|
39
|
+
"projectsRunState_running": "Running",
|
|
40
|
+
"projectsRunState_completed": "Finished",
|
|
41
|
+
"projectsRunState_failed": "Failed",
|
|
42
|
+
"projectsRunState_cancelled": "Cancelled",
|
|
43
|
+
"projectsRunState_idle": "Idle",
|
|
44
|
+
"projectsStartProjectWork": "Start project work",
|
|
45
|
+
"projectsStartProjectWorkPrompt": "Start working on this project. First read the project configuration and the materials relevant to this goal; I will add or revise the specific goal before sending.",
|
|
46
|
+
"projectsBoardNeedsWorkflow": "No workflow stages are available. The board does not invent stages.",
|
|
47
|
+
"projectsGanttNeedsSchedule": "No schedule markers are available. The Gantt view does not infer dates from files.",
|
|
48
|
+
"projectsUnstaged": "Stage not reported",
|
|
49
|
+
"projectsStage": "Stage",
|
|
50
|
+
"projectsSchedule": "Schedule",
|
|
51
|
+
"projectsNoArtifacts": "No artifacts matched by configuration or reported by AI",
|
|
52
|
+
"projectsNoSkills": "No project Skills are available",
|
|
53
|
+
"projectsNoContext": "No vision or working-rule sources are configured",
|
|
54
|
+
"projectsRequests": "Waiting for your reply",
|
|
55
|
+
"projectsConfirm": "Confirm",
|
|
56
|
+
"projectsReject": "Reject",
|
|
57
|
+
"projectsResponseSent": "Reply sent; waiting for AI to update",
|
|
58
|
+
"projectsResponseWaiting": "Replied; waiting for AI to update",
|
|
59
|
+
"projectsResponseFailed": "Failed to send reply",
|
|
60
|
+
"projectsActivity": "Recent activity",
|
|
61
|
+
"projectsNoActivity": "No AI-reported activity",
|
|
62
|
+
"projectsOpenSession": "Open source session",
|
|
63
|
+
"projectsAttention": "Needs attention",
|
|
64
|
+
"projectsNoAttention": "No open attention signals",
|
|
65
|
+
"projectsSourceHealth": "Sources and diagnostics",
|
|
66
|
+
"projectsArtifactsCountSuffix": "artifacts",
|
|
67
|
+
"projectsArtifactsSearchPlaceholder": "Search artifacts",
|
|
68
|
+
"projectsArtifactsShowMore": "Show more",
|
|
69
|
+
"projectsArtifactsNoMatches": "No matching artifacts",
|
|
70
|
+
"projectsArtifactsSort": "Sort",
|
|
71
|
+
"projectsArtifactsSortUpdatedDesc": "Recently updated",
|
|
72
|
+
"projectsArtifactsSortUpdatedAsc": "Oldest updated",
|
|
73
|
+
"projectsArtifactsSortCreatedDesc": "Recently created",
|
|
74
|
+
"projectsArtifactsSortName": "File name",
|
|
75
|
+
"projectsTimeJustNow": "Just now",
|
|
76
|
+
"projectsTimeMinutesAgo": "{count} minutes ago",
|
|
77
|
+
"projectsTimeHoursAgo": "{count} hours ago",
|
|
78
|
+
"projectsTimeYesterday": "Yesterday",
|
|
79
|
+
"projectsTimeDaysAgo": "{count} days ago",
|
|
80
|
+
"projectsReadable": "Readable",
|
|
81
|
+
"projectsStatus": "Status",
|
|
82
|
+
"projectsUpdated": "Updated",
|
|
83
|
+
"projectsStatus_active": "Active",
|
|
84
|
+
"projectsStatus_blocked": "Blocked",
|
|
85
|
+
"projectsStatus_completed": "Completed",
|
|
86
|
+
"projectsStatus_cancelled": "Cancelled",
|
|
87
|
+
"projectsSource_available": "Available",
|
|
88
|
+
"projectsSource_empty": "No data",
|
|
89
|
+
"projectsSource_error": "Failed"
|
|
90
|
+
}
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
{
|
|
2
|
+
"projectsTitle": "项目",
|
|
3
|
+
"projectsOverview": "概览",
|
|
4
|
+
"projectsWork": "工作项",
|
|
5
|
+
"projectsArtifacts": "产物",
|
|
6
|
+
"projectsSkills": "Skills",
|
|
7
|
+
"projectsSkillsCountSuffix": "个 Skills",
|
|
8
|
+
"projectsAgreement": "工作约定",
|
|
9
|
+
"projectsVisionAndContext": "愿景与上下文",
|
|
10
|
+
"projectsLoading": "正在读取项目…",
|
|
11
|
+
"projectsLoadFailed": "项目读取失败",
|
|
12
|
+
"projectsEmpty": "还没有注册项目",
|
|
13
|
+
"projectsChoose": "选择项目",
|
|
14
|
+
"projectsAsOf": "观测时间",
|
|
15
|
+
"projectsQuality": "数据质量",
|
|
16
|
+
"projectsQuality_complete": "完整",
|
|
17
|
+
"projectsQuality_partial": "部分可用",
|
|
18
|
+
"projectsQuality_unavailable": "暂不可用",
|
|
19
|
+
"projectsNoSummary": "项目没有配置摘要,可在工作约定中查看已有来源。",
|
|
20
|
+
"projectsObservationSetupTitle": "建立项目观察",
|
|
21
|
+
"projectsObservationSetupDescription": "项目还没有建立观察约定。让 AI 阅读已有材料,推荐工作项流程和产物范围,并同时准备项目配置、常驻规则与项目追踪 Skill;确认后再统一写入。",
|
|
22
|
+
"projectsObservationSetupAction": "让 AI 帮我建立项目观察",
|
|
23
|
+
"projectsObservationSetupPrompt": "请按内置的项目观察 setup 规范,为当前项目建立可持续生效的工作追踪约定。先读取已有材料,根据项目实际情况直接给出一套可修改的推荐,完整包含:.nextclaw/project.yaml、根 AGENTS.md 的最小常驻规则,以及 .agents/skills/project-work-tracking/SKILL.md 的项目日常追踪方法。Workflow 描述单个工作项如何推进,不是整个项目的宏观阶段。Marker 必须在节点开始前报告,不能在结束时批量补写。不要反复提问;信息足够时直接推荐。未经我确认不要写入,确认后一次写入并复核三份文件。",
|
|
24
|
+
"projectsNoData": "暂无可观测数据",
|
|
25
|
+
"projectsUnavailable": "暂不可用",
|
|
26
|
+
"projectsWorkList": "列表",
|
|
27
|
+
"projectsWorkBoard": "看板",
|
|
28
|
+
"projectsWorkGantt": "甘特图",
|
|
29
|
+
"projectsWorkViews": "工作项视图",
|
|
30
|
+
"projectsWorkDetails": "工作项详情",
|
|
31
|
+
"projectsCloseDetails": "关闭详情",
|
|
32
|
+
"projectsNoWork": "暂无 AI 明确报告的工作项",
|
|
33
|
+
"projectsWorkNeedsSetup": "先建立项目观察配置,AI 才能按这个项目的流程报告真实进展。",
|
|
34
|
+
"projectsWorkNoSessions": "还没有在这个项目中开始会话。开始实际项目工作后,AI 报告的进展会显示在这里。",
|
|
35
|
+
"projectsWorkNoReports": "项目会话中还没有 AI 明确报告的工作项。继续实际工作后,真实进展会显示在这里。",
|
|
36
|
+
"projectsAiActivity": "AI 运行",
|
|
37
|
+
"projectsAiRun": "项目会话",
|
|
38
|
+
"projectsRunUnreported": "尚未报告工作项与阶段",
|
|
39
|
+
"projectsRunState_running": "运行中",
|
|
40
|
+
"projectsRunState_completed": "已结束",
|
|
41
|
+
"projectsRunState_failed": "运行失败",
|
|
42
|
+
"projectsRunState_cancelled": "已中止",
|
|
43
|
+
"projectsRunState_idle": "空闲",
|
|
44
|
+
"projectsStartProjectWork": "开始项目工作",
|
|
45
|
+
"projectsStartProjectWorkPrompt": "请开始处理这个项目。先读取项目配置和与本次目标相关的材料;我会在发送前补充或修改具体目标。",
|
|
46
|
+
"projectsBoardNeedsWorkflow": "没有可用的 Workflow 阶段;看板不会自动生成阶段。",
|
|
47
|
+
"projectsGanttNeedsSchedule": "没有 schedule Marker;甘特图不会从文件时间推断日期。",
|
|
48
|
+
"projectsUnstaged": "未声明阶段",
|
|
49
|
+
"projectsStage": "阶段",
|
|
50
|
+
"projectsSchedule": "计划",
|
|
51
|
+
"projectsNoArtifacts": "暂无配置匹配或 AI 标记的产物",
|
|
52
|
+
"projectsNoSkills": "项目目录中暂无可用 Skills",
|
|
53
|
+
"projectsNoContext": "项目没有配置愿景或工作约定来源",
|
|
54
|
+
"projectsRequests": "等待你回复",
|
|
55
|
+
"projectsConfirm": "确认",
|
|
56
|
+
"projectsReject": "拒绝",
|
|
57
|
+
"projectsResponseSent": "回复已发送,等待 AI 更新",
|
|
58
|
+
"projectsResponseWaiting": "已回复,等待 AI 更新",
|
|
59
|
+
"projectsResponseFailed": "回复发送失败",
|
|
60
|
+
"projectsActivity": "最近动态",
|
|
61
|
+
"projectsNoActivity": "暂无 AI 报告的动态",
|
|
62
|
+
"projectsOpenSession": "打开原会话",
|
|
63
|
+
"projectsAttention": "待关注",
|
|
64
|
+
"projectsNoAttention": "暂无待关注信号",
|
|
65
|
+
"projectsSourceHealth": "来源与诊断",
|
|
66
|
+
"projectsArtifactsCountSuffix": "个产物",
|
|
67
|
+
"projectsArtifactsSearchPlaceholder": "搜索产物",
|
|
68
|
+
"projectsArtifactsShowMore": "显示更多",
|
|
69
|
+
"projectsArtifactsNoMatches": "没有匹配的产物",
|
|
70
|
+
"projectsArtifactsSort": "排序",
|
|
71
|
+
"projectsArtifactsSortUpdatedDesc": "最近更新",
|
|
72
|
+
"projectsArtifactsSortUpdatedAsc": "最早更新",
|
|
73
|
+
"projectsArtifactsSortCreatedDesc": "最近创建",
|
|
74
|
+
"projectsArtifactsSortName": "文件名",
|
|
75
|
+
"projectsTimeJustNow": "刚刚",
|
|
76
|
+
"projectsTimeMinutesAgo": "{count} 分钟前",
|
|
77
|
+
"projectsTimeHoursAgo": "{count} 小时前",
|
|
78
|
+
"projectsTimeYesterday": "昨天",
|
|
79
|
+
"projectsTimeDaysAgo": "{count} 天前",
|
|
80
|
+
"projectsReadable": "可读取",
|
|
81
|
+
"projectsStatus": "状态",
|
|
82
|
+
"projectsUpdated": "更新时间",
|
|
83
|
+
"projectsStatus_active": "进行中",
|
|
84
|
+
"projectsStatus_blocked": "受阻",
|
|
85
|
+
"projectsStatus_completed": "已完成",
|
|
86
|
+
"projectsStatus_cancelled": "已取消",
|
|
87
|
+
"projectsSource_available": "可用",
|
|
88
|
+
"projectsSource_empty": "暂无数据",
|
|
89
|
+
"projectsSource_error": "读取失败"
|
|
90
|
+
}
|
|
@@ -37,6 +37,12 @@ describe("resolveUiDocumentTitle", () => {
|
|
|
37
37
|
).toBe("NextClaw 3000 - Model Configuration");
|
|
38
38
|
});
|
|
39
39
|
|
|
40
|
+
it("uses the projects title for project routes", () => {
|
|
41
|
+
setLanguage("en");
|
|
42
|
+
|
|
43
|
+
expect(resolveUiDocumentTitle("/projects")).toBe("NextClaw - Projects");
|
|
44
|
+
});
|
|
45
|
+
|
|
40
46
|
it("uses the full host for non-local instances", () => {
|
|
41
47
|
setLanguage("en");
|
|
42
48
|
const title = resolveUiDocumentTitle(
|
|
@@ -11,6 +11,7 @@ const ROUTE_TITLE_KEYS: Array<{ prefix: string; key: string }> = [
|
|
|
11
11
|
{ prefix: "/skills", key: "marketplaceSkillsPageTitle" },
|
|
12
12
|
{ prefix: "/cron", key: "cronPageTitle" },
|
|
13
13
|
{ prefix: "/agents", key: "agentsPageTitle" },
|
|
14
|
+
{ prefix: "/projects", key: "projectsTitle" },
|
|
14
15
|
{ prefix: "/chat", key: "chat" },
|
|
15
16
|
{ prefix: "/model", key: "modelPageTitle" },
|
|
16
17
|
{ prefix: "/search", key: "searchPageTitle" },
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{B as e,L as t,a as n,r,s as i}from"./react-CVFx225w.js";import{t as a}from"./navigation-link-Ci4Z7Phi.js";import{Gt as o,Jt as s,Kt as c,Wt as l,Yt as u,an as d,fn as f,in as p,on as m,sn as h,yn as g}from"./api-aEu9cEI8.js";import{a as _,i as v,n as y,r as b,t as x}from"./select-DPKCWajZ.js";import{t as S}from"./refresh-cw-C-3_thgr.js";import{t as C}from"./rotate-cw-DSFTq_yu.js";import{$ as w,Q as T,et as E,nt as D,tt as O}from"./index-zuqzAvNx.js";var k=e(),A={checking:`desktopUpdatesStatusChecking`,"update-available":`desktopUpdatesStatusAvailable`,downloading:`desktopUpdatesStatusDownloading`,downloaded:`desktopUpdatesStatusDownloaded`,applying:`desktopUpdatesStatusApplying`,"restart-required":`desktopUpdatesStatusRestartRequired`,"up-to-date":`desktopUpdatesStatusUpToDate`,blocked:`desktopUpdatesStatusBlocked`,failed:`desktopUpdatesStatusFailed`},j={feature:`desktopUpdatesReleaseNotesFeature`,enhancement:`desktopUpdatesReleaseNotesEnhancement`,fix:`desktopUpdatesReleaseNotesFix`,compatibility:`desktopUpdatesReleaseNotesCompatibility`};function M({snapshot:e}){return(0,k.jsx)(`span`,{className:t(`inline-flex rounded-full px-3 py-1 text-xs font-medium ring-1`,V(e.status)),children:B(e)})}function N({label:e,value:t}){return(0,k.jsxs)(`div`,{className:`rounded-lg bg-background/70 p-3`,children:[(0,k.jsx)(`p`,{className:`text-[11px] font-medium uppercase tracking-[0.08em] text-muted-foreground`,children:e}),(0,k.jsx)(`p`,{className:`mt-1 text-sm font-semibold text-foreground`,children:t})]})}function P({snapshot:e}){if(e.status!==`downloading`)return null;let t=e.progress?.percent,r=t==null?n(`desktopUpdatesDownloadProgressUnknown`):n(`desktopUpdatesDownloadProgressPercent`).replace(`{percent}`,String(t)),i=L(e.progress?.downloadedBytes??0,e.progress?.totalBytes??null);return(0,k.jsxs)(`div`,{className:`rounded-2xl border border-amber-200 bg-amber-50/70 p-4`,children:[(0,k.jsxs)(`div`,{className:`flex items-center justify-between gap-4`,children:[(0,k.jsx)(`p`,{className:`text-sm font-semibold text-amber-800`,children:r}),(0,k.jsx)(`p`,{className:`text-xs font-medium text-amber-700`,children:i})]}),(0,k.jsx)(`div`,{className:`mt-3 h-2 overflow-hidden rounded-full bg-amber-100`,children:(0,k.jsx)(`div`,{className:`h-full rounded-full bg-amber-500 transition-[width]`,style:{width:`${t??0}%`}})})]})}function F(e){return e?.trim()||`-`}function I(e){return e?r(e):`-`}function L(e,t){let n=R(e);return t&&t>0?`${n} / ${R(t)}`:n}function R(e){if(!Number.isFinite(e)||e<=0)return`0 B`;let t=[`B`,`KB`,`MB`,`GB`],n=e,r=0;for(;n>=1024&&r<t.length-1;)n/=1024,r+=1;return`${n>=10||r===0?n.toFixed(0):n.toFixed(1)} ${t[r]}`}function z(e){return n(e===`beta`?`desktopUpdatesChannelBeta`:`desktopUpdatesChannelStable`)}function B(e){return e.status===`failed`&&e.failureStage?n(`desktopUpdatesFailureStage.${e.failureStage}`):n(A[e.status]??`desktopUpdatesStatusIdle`)}function V(e){return e===`downloaded`||e===`restart-required`?`bg-emerald-50 text-emerald-700 ring-emerald-100`:e===`update-available`||e===`downloading`||e===`checking`?`bg-amber-50 text-amber-700 ring-amber-100`:e===`failed`||e===`blocked`?`bg-red-50 text-red-700 ring-red-100`:`bg-gray-100 text-gray-700 ring-gray-200`}function H(){return i()===`zh`?`zh-CN`:`en-US`}function U(e,t){return o(e.title,t)??n(j[e.kind]??`desktopUpdatesReleaseNotesEnhancement`)}function W({snapshot:e}){let t=c(e),r=H(),i=g({queryKey:[`runtime-release-notes`,t],queryFn:async()=>await l(t??``),enabled:!!t,retry:!1,staleTime:300*1e3}),s=i.data,u=o(s?.title,r)??n(`desktopUpdatesReleaseNotesPreviewTitle`),d=o(s?.summary,r)??n(`desktopUpdatesReleaseNotesPreviewDescription`);return e.releaseNotesUrl?(0,k.jsxs)(T,{children:[(0,k.jsx)(O,{children:(0,k.jsxs)(`div`,{className:`flex flex-wrap items-start justify-between gap-3`,children:[(0,k.jsxs)(`div`,{className:`space-y-1`,children:[(0,k.jsx)(D,{children:u}),(0,k.jsx)(E,{children:d})]}),(0,k.jsx)(a,{href:e.releaseNotesUrl,external:!0,children:n(`desktopUpdatesReleaseNotes`)})]})}),(0,k.jsxs)(w,{className:`space-y-4`,children:[i.isLoading?(0,k.jsx)(`p`,{className:`text-sm text-gray-500`,children:n(`desktopUpdatesReleaseNotesPreviewLoading`)}):null,!t||i.isError?(0,k.jsx)(`p`,{className:`text-sm text-gray-500`,children:n(`desktopUpdatesReleaseNotesPreviewUnavailable`)}):null,s?(0,k.jsx)(`div`,{className:`grid gap-4 md:grid-cols-2`,children:s.sections.map(e=>(0,k.jsxs)(`div`,{className:`rounded-xl border border-gray-200 bg-gray-50/60 p-4`,children:[(0,k.jsx)(`p`,{className:`text-sm font-semibold text-gray-900`,children:U(e,r)}),(0,k.jsx)(`ul`,{className:`mt-3 space-y-3`,children:e.items.map((t,n)=>{let i=o(t.title,r),a=o(t.body,r);return(0,k.jsxs)(`li`,{className:`space-y-1`,children:[i?(0,k.jsx)(`p`,{className:`text-sm font-medium text-gray-800`,children:i}):null,a?(0,k.jsx)(`p`,{className:`text-sm leading-5 text-gray-600`,children:a}):null]},`${i??e.kind}-${n}`)})})]},e.kind))}):null]})]}):null}function G(){return(0,k.jsx)(h,{title:n(`runtimeUpdatesPageTitle`),description:n(`runtimeUpdatesPageDescription`),children:(0,k.jsx)(m,{title:n(`runtimeUpdatesUnavailableTitle`),description:n(`runtimeUpdatesUnavailableDescription`),children:(0,k.jsx)(d,{children:(0,k.jsx)(`p`,{className:`p-4 text-sm text-muted-foreground`,children:n(`runtimeUpdatesUnavailableHint`)})})})})}function K(){let{supported:e,initialized:r,busyAction:i,snapshot:a}=u();if(!r)return(0,k.jsx)(h,{title:n(`runtimeUpdatesPageTitle`),description:n(`runtimeUpdatesPageDescription`),children:(0,k.jsx)(`div`,{className:`text-sm text-muted-foreground`,children:n(`loading`)})});if(!e||!a)return(0,k.jsx)(G,{});let o=i===`checking`,c=i===`downloading`,l=i===`applying`,g=i===`updating`,w=i===`switching-channel`,T=(a.status===`update-available`||a.status===`downloaded`)&&!c&&!l&&!g,E=[[n(`runtimeUpdatesHostVersion`),F(a.hostVersion)],[n(`desktopUpdatesCurrentBundleVersion`),F(a.currentVersion)],[n(`desktopUpdatesAvailableVersion`),F(a.availableVersion)],[n(`desktopUpdatesLastCheckedAt`),I(a.lastCheckedAt)],[n(`desktopUpdatesCurrentChannel`),z(a.channel)]];return(0,k.jsxs)(h,{title:n(`runtimeUpdatesPageTitle`),description:n(`runtimeUpdatesPageDescription`),actions:(0,k.jsxs)(f,{variant:`outline`,onClick:()=>void s.checkForUpdates(),disabled:o||c||l||g,children:[(0,k.jsx)(S,{className:t(`mr-2 h-4 w-4`,o&&`animate-spin`)}),n(`desktopUpdatesCheckNow`)]}),children:[(0,k.jsx)(m,{title:n(`desktopUpdatesOverviewTitle`),description:n(`desktopUpdatesOverviewDescription`),children:(0,k.jsx)(d,{children:(0,k.jsxs)(`div`,{className:`space-y-4 p-4`,children:[(0,k.jsxs)(`div`,{className:`flex flex-wrap items-center gap-3`,children:[(0,k.jsx)(`span`,{className:`text-sm font-medium text-foreground`,children:n(`desktopUpdatesStatusLabel`)}),(0,k.jsx)(M,{snapshot:a})]}),(0,k.jsx)(`div`,{className:`grid gap-4 md:grid-cols-2 xl:grid-cols-5`,children:E.map(([e,t])=>(0,k.jsx)(N,{label:e,value:t},e))}),a.channel===`beta`?(0,k.jsxs)(`div`,{className:`rounded-2xl border border-amber-200 bg-amber-50/70 p-4`,children:[(0,k.jsx)(`p`,{className:`text-sm font-semibold text-amber-800`,children:n(`desktopUpdatesBetaBadgeTitle`)}),(0,k.jsx)(`p`,{className:`mt-1 text-sm text-amber-700`,children:n(`desktopUpdatesBetaBadgeDescription`)})]}):null,a.downloadedVersion?(0,k.jsxs)(`div`,{className:`rounded-2xl border border-emerald-200 bg-emerald-50/70 p-4`,children:[(0,k.jsx)(`p`,{className:`text-sm font-semibold text-emerald-800`,children:n(`desktopUpdatesDownloadedBannerTitle`)}),(0,k.jsx)(`p`,{className:`mt-1 text-sm text-emerald-700`,children:n(`runtimeUpdatesDownloadedBannerDescription`).replace(`{version}`,a.downloadedVersion)})]}):null,(0,k.jsx)(P,{snapshot:a}),a.status===`blocked`?(0,k.jsxs)(`div`,{className:`rounded-2xl border border-red-200 bg-red-50/70 p-4`,children:[(0,k.jsx)(`p`,{className:`text-sm font-semibold text-red-800`,children:n(`desktopUpdatesBlockedTitle`)}),(0,k.jsx)(`p`,{className:`mt-1 text-sm text-red-700`,children:a.errorMessage??n(`desktopUpdatesBlockedDescription`)}),a.recoveryCommand?(0,k.jsx)(`code`,{className:`mt-3 block rounded-lg bg-white/70 px-3 py-2 text-xs text-red-800`,children:a.recoveryCommand}):null]}):null,a.errorMessage&&a.status!==`blocked`?(0,k.jsx)(`div`,{className:`rounded-2xl border border-red-200 bg-red-50/70 p-4 text-sm text-red-700`,children:a.errorMessage}):null]})})}),(0,k.jsx)(W,{snapshot:a}),(0,k.jsx)(m,{title:n(`desktopUpdatesChannelSettingsTitle`),description:n(`desktopUpdatesChannelSettingsDescription`),children:(0,k.jsx)(d,{children:(0,k.jsx)(p,{title:n(`desktopUpdatesReleaseChannel`),description:n(`desktopUpdatesReleaseChannelHelp`),layout:`stacked`,children:(0,k.jsxs)(`div`,{className:`space-y-2`,children:[(0,k.jsxs)(x,{value:a.channel,disabled:w||o||c||l||g,onValueChange:e=>void s.updateChannel(e),children:[(0,k.jsx)(v,{className:`w-full max-w-sm`,children:(0,k.jsx)(_,{placeholder:n(`desktopUpdatesReleaseChannel`)})}),(0,k.jsxs)(y,{children:[(0,k.jsx)(b,{value:`stable`,children:n(`desktopUpdatesChannelStable`)}),(0,k.jsx)(b,{value:`beta`,children:n(`desktopUpdatesChannelBeta`)})]})]}),(0,k.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:n(`desktopUpdatesReleaseChannelDowngradeHint`)})]})})})}),(0,k.jsx)(m,{title:n(`desktopUpdatesActionsTitle`),description:n(`runtimeUpdatesActionsDescription`),children:(0,k.jsx)(d,{children:(0,k.jsxs)(`div`,{className:`flex flex-wrap items-center gap-3 p-4`,children:[(0,k.jsxs)(f,{variant:`outline`,onClick:()=>void s.checkForUpdates(),disabled:o||c||l||g,children:[(0,k.jsx)(S,{className:t(`mr-2 h-4 w-4`,o&&`animate-spin`)}),n(`desktopUpdatesCheckNow`)]}),(0,k.jsxs)(f,{onClick:()=>void s.updateNow(),disabled:!T,children:[(0,k.jsx)(C,{className:t(`mr-2 h-4 w-4`,g&&`animate-spin`)}),n(`runtimeUpdatesApplyNow`)]})]})})})]})}export{K as DesktopUpdateConfig};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{t as e}from"./doc-browser-DwRLokCI.js";export{e as DocBrowser};
|