@dooc-dev/dooc 0.0.26 → 0.0.28
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/dist/edit.global.js +280 -260
- package/dist/engine/compiler/format-collections.js +9 -3
- package/dist/engine/core/html.js +3 -5
- package/dist/engine/core/icons.js +2 -2
- package/dist/frontend/document-application.js +185 -90
- package/dist/frontend/git-style.d.ts +1 -0
- package/dist/frontend/git-style.js +172 -0
- package/dist/frontend/language-picker.d.ts +5 -1
- package/dist/frontend/language-picker.js +19 -4
- package/dist/frontend/link-preview.d.ts +2 -0
- package/dist/frontend/link-preview.js +385 -0
- package/dist/frontend/locales/eng.json +137 -3
- package/dist/frontend/locales/jpn.json +139 -5
- package/dist/frontend/locales/zho.json +137 -3
- package/dist/frontend/resource-download.js +11 -6
- package/dist/frontend/scrollbars.d.ts +1 -0
- package/dist/frontend/scrollbars.js +9 -0
- package/dist/frontend/video-ui.js +9 -3
- package/dist/manifest.global.js +188 -186
- package/dist/mcp-relay.mjs +20 -1
- package/dist/plugins.global.js +31 -31
- package/dist/server/build.js +11 -8
- package/dist/server/cli.js +6 -1
- package/dist/server/git-origin.js +1 -1
- package/dist/server/git.js +49 -26
- package/dist/server/operation-log.js +9 -1
- package/dist/server/serve.d.ts +1 -0
- package/dist/server/serve.js +18 -7
- package/dist/server/static-client.js +4 -14
- package/dist/server/workspace-server.js +2 -1
- package/dist/subformats.global.js +57 -57
- package/dist/ui.global.js +71 -69
- package/dist/workspace/git-review.d.ts +5 -0
- package/dist/workspace/git-review.js +56 -0
- package/dist/workspace/git-types.d.ts +29 -2
- package/dist/workspace/git-types.js +5 -1
- package/dist/workspace/github.d.ts +1 -1
- package/dist/workspace/github.js +73 -9
- package/dist/workspace/mcp-tools.js +20 -1
- package/dist/workspace-worker.global.js +337 -87
- package/package.json +1 -1
- package/dist/workspace-mcp-worker.global.js +0 -3263
- package/dist/workspace-reader-mcp-worker.global.js +0 -3263
- package/dist/workspace-reader-worker.global.js +0 -3263
|
@@ -0,0 +1,385 @@
|
|
|
1
|
+
import { SCROLLBAR_CSS } from "./scrollbars.js";
|
|
2
|
+
/** Self-contained so workspace readers and standalone documents share previews. */
|
|
3
|
+
export function mountLinkPreviews(request = fetch, network = true, scrollbars = SCROLLBAR_CSS) {
|
|
4
|
+
const t = (key) => window.__docsTranslate?.(key) ??
|
|
5
|
+
key;
|
|
6
|
+
let active;
|
|
7
|
+
let popup;
|
|
8
|
+
let controller;
|
|
9
|
+
let timer;
|
|
10
|
+
let closeTimer;
|
|
11
|
+
let title = null;
|
|
12
|
+
let description = null;
|
|
13
|
+
let press;
|
|
14
|
+
let hoverPoint;
|
|
15
|
+
let suppressClick = false;
|
|
16
|
+
let restoringFocus = false;
|
|
17
|
+
document.body.dataset.linkPreviews = "";
|
|
18
|
+
const close = () => {
|
|
19
|
+
clearTimeout(timer);
|
|
20
|
+
clearTimeout(closeTimer);
|
|
21
|
+
controller?.abort();
|
|
22
|
+
const origin = active;
|
|
23
|
+
const host = popup;
|
|
24
|
+
const modal = host instanceof HTMLDialogElement;
|
|
25
|
+
if (active && title !== null)
|
|
26
|
+
active.setAttribute("title", title);
|
|
27
|
+
if (active && popup) {
|
|
28
|
+
if (description === null)
|
|
29
|
+
active.removeAttribute("aria-describedby");
|
|
30
|
+
else
|
|
31
|
+
active.setAttribute("aria-describedby", description);
|
|
32
|
+
}
|
|
33
|
+
active?.removeAttribute("data-link-preview-press");
|
|
34
|
+
active = popup = undefined;
|
|
35
|
+
press = hoverPoint = undefined;
|
|
36
|
+
title = null;
|
|
37
|
+
restoringFocus = true;
|
|
38
|
+
if (modal)
|
|
39
|
+
host.close();
|
|
40
|
+
host?.remove();
|
|
41
|
+
if (modal && origin?.isConnected)
|
|
42
|
+
origin.focus({ preventScroll: true });
|
|
43
|
+
restoringFocus = false;
|
|
44
|
+
};
|
|
45
|
+
const position = () => {
|
|
46
|
+
if (!active || !popup || popup instanceof HTMLDialogElement)
|
|
47
|
+
return;
|
|
48
|
+
const rect = active.getBoundingClientRect();
|
|
49
|
+
const below = innerHeight - rect.bottom;
|
|
50
|
+
popup.style.left = `${Math.max(12, Math.min(rect.left, innerWidth - popup.offsetWidth - 12))}px`;
|
|
51
|
+
popup.style.top = `${Math.max(12, Math.min(innerHeight - popup.offsetHeight - 12, below >= popup.offsetHeight + 12 ? rect.bottom + 8 : rect.top - popup.offsetHeight - 8))}px`;
|
|
52
|
+
};
|
|
53
|
+
const show = async (target, overlay = false) => {
|
|
54
|
+
if (active !== target ||
|
|
55
|
+
!target.isConnected ||
|
|
56
|
+
window.getSelection()?.isCollapsed === false)
|
|
57
|
+
return;
|
|
58
|
+
const control = new AbortController();
|
|
59
|
+
controller = control;
|
|
60
|
+
const signal = control.signal;
|
|
61
|
+
const templates = [
|
|
62
|
+
...document.querySelectorAll("template[data-route]"),
|
|
63
|
+
];
|
|
64
|
+
const file = target.dataset.resourceSource ??
|
|
65
|
+
target.closest("[data-record-file]")?.dataset.recordFile;
|
|
66
|
+
const href = target.dataset.jumpUrl ??
|
|
67
|
+
target.getAttribute("href") ??
|
|
68
|
+
(file ? `${templates.length ? "#" : ""}/_files/file/${encodeURIComponent(file)}` : "");
|
|
69
|
+
if (!href)
|
|
70
|
+
return;
|
|
71
|
+
let url;
|
|
72
|
+
try {
|
|
73
|
+
url = new URL(href, location.href);
|
|
74
|
+
}
|
|
75
|
+
catch {
|
|
76
|
+
return;
|
|
77
|
+
}
|
|
78
|
+
if (!["http:", "https:", "file:"].includes(url.protocol) || url.username || url.password)
|
|
79
|
+
return;
|
|
80
|
+
const host = document.createElement(overlay ? "dialog" : "div");
|
|
81
|
+
popup = host;
|
|
82
|
+
host.className = "link-preview";
|
|
83
|
+
host.id = "dooc-link-preview";
|
|
84
|
+
description = target.getAttribute("aria-describedby");
|
|
85
|
+
if (!overlay) {
|
|
86
|
+
host.popover = "manual";
|
|
87
|
+
host.setAttribute("role", "tooltip");
|
|
88
|
+
target.setAttribute("aria-describedby", [description, host.id].filter(Boolean).join(" "));
|
|
89
|
+
}
|
|
90
|
+
const heading = document.createElement("strong");
|
|
91
|
+
heading.id = `${host.id}-title`;
|
|
92
|
+
heading.textContent =
|
|
93
|
+
target.getAttribute("aria-label") ||
|
|
94
|
+
title ||
|
|
95
|
+
target.firstChild?.textContent?.trim() ||
|
|
96
|
+
file ||
|
|
97
|
+
url.hostname;
|
|
98
|
+
const source = document.createElement("div");
|
|
99
|
+
source.className = "link-preview-source";
|
|
100
|
+
source.textContent = file || href;
|
|
101
|
+
const status = document.createElement("p");
|
|
102
|
+
status.textContent = t("Loading…");
|
|
103
|
+
status.setAttribute("role", "status");
|
|
104
|
+
host.append(heading, source, status);
|
|
105
|
+
if (host instanceof HTMLDialogElement) {
|
|
106
|
+
host.setAttribute("aria-labelledby", heading.id);
|
|
107
|
+
const actions = document.createElement("div");
|
|
108
|
+
actions.className = "link-preview-actions";
|
|
109
|
+
const dismiss = document.createElement("button");
|
|
110
|
+
dismiss.type = "button";
|
|
111
|
+
dismiss.textContent = t("Close");
|
|
112
|
+
dismiss.autofocus = true;
|
|
113
|
+
dismiss.addEventListener("click", close);
|
|
114
|
+
const open = document.createElement("button");
|
|
115
|
+
open.type = "button";
|
|
116
|
+
open.textContent = t("Open link");
|
|
117
|
+
open.addEventListener("click", () => {
|
|
118
|
+
close();
|
|
119
|
+
target.click();
|
|
120
|
+
});
|
|
121
|
+
actions.append(dismiss, open);
|
|
122
|
+
host.append(actions);
|
|
123
|
+
host.addEventListener("cancel", (event) => {
|
|
124
|
+
event.preventDefault();
|
|
125
|
+
close();
|
|
126
|
+
});
|
|
127
|
+
host.addEventListener("click", (event) => {
|
|
128
|
+
const rect = host.getBoundingClientRect();
|
|
129
|
+
if (event.target === host &&
|
|
130
|
+
(event.clientX < rect.left ||
|
|
131
|
+
event.clientX > rect.right ||
|
|
132
|
+
event.clientY < rect.top ||
|
|
133
|
+
event.clientY > rect.bottom))
|
|
134
|
+
close();
|
|
135
|
+
});
|
|
136
|
+
}
|
|
137
|
+
(target.closest("[data-theme], main") ?? document.body).append(host);
|
|
138
|
+
if (host instanceof HTMLDialogElement) {
|
|
139
|
+
suppressClick = true;
|
|
140
|
+
host.showModal();
|
|
141
|
+
}
|
|
142
|
+
else
|
|
143
|
+
host.showPopover();
|
|
144
|
+
position();
|
|
145
|
+
const frame = document.createElement("iframe");
|
|
146
|
+
frame.title = heading.textContent || t("Preview");
|
|
147
|
+
frame.sandbox.value = "";
|
|
148
|
+
frame.referrerPolicy = "no-referrer";
|
|
149
|
+
// Keep keyboard focus on the dialog controls instead of entering a sandboxed frame.
|
|
150
|
+
frame.tabIndex = -1;
|
|
151
|
+
const present = (html) => {
|
|
152
|
+
if (signal.aborted || popup !== host)
|
|
153
|
+
return;
|
|
154
|
+
const theme = getComputedStyle(target);
|
|
155
|
+
const palette = [
|
|
156
|
+
"--doc-fg",
|
|
157
|
+
"--doc-fg-2",
|
|
158
|
+
"--doc-bg",
|
|
159
|
+
"--doc-border",
|
|
160
|
+
"--doc-accent",
|
|
161
|
+
"--doc-accent-2",
|
|
162
|
+
"--font-sans",
|
|
163
|
+
"--doc-mono",
|
|
164
|
+
]
|
|
165
|
+
.map((name) => `${name}:${theme.getPropertyValue(name)};`)
|
|
166
|
+
.join("");
|
|
167
|
+
frame.srcdoc = `<!doctype html><meta charset="utf-8"><style>:root{${palette}color-scheme:${theme.colorScheme}}*{box-sizing:border-box}${scrollbars}html{overscroll-behavior:contain}body{margin:0;padding:12px;font:${overlay ? "15px" : "13px"}/1.6 var(--font-sans,system-ui);color:var(--doc-fg,CanvasText);background:var(--doc-bg,Canvas);overflow-wrap:anywhere}::selection{background:color-mix(in srgb,var(--doc-accent) 24%,transparent)}a{color:var(--doc-accent-2);text-underline-offset:2px}img,video,object,iframe{display:block;max-width:100%;max-height:240px;object-fit:contain}iframe{width:100%!important;border:0}pre{white-space:pre-wrap;font:12px/1.5 var(--doc-mono,monospace)}h1,h2,h3{margin:0 0 8px;font-size:16px}figure{margin:0}button,a[download],[data-resource-download],.pbtn,.doc-title,.resource-download-tools,.page-actions,.pane-actions,.subformat-card-tools,.codeblk-head,.res-crumbs{display:none}table{border-collapse:collapse}td,th{padding:4px 8px;overflow-wrap:break-word;border-bottom:1px solid var(--doc-border)}</style>${html}`;
|
|
168
|
+
status.replaceWith(frame);
|
|
169
|
+
position();
|
|
170
|
+
};
|
|
171
|
+
const nearby = target.querySelector(".figpop, .dictpop") ??
|
|
172
|
+
(target.matches(".subformat-card-open")
|
|
173
|
+
? target.closest(".subformat-card")?.querySelector(".format-preview")
|
|
174
|
+
: null);
|
|
175
|
+
if (nearby) {
|
|
176
|
+
present(nearby.innerHTML);
|
|
177
|
+
return;
|
|
178
|
+
}
|
|
179
|
+
const internal = url.origin === location.origin &&
|
|
180
|
+
(url.protocol !== "file:" || url.pathname === location.pathname);
|
|
181
|
+
try {
|
|
182
|
+
if (internal) {
|
|
183
|
+
const routeHash = href.startsWith("#/");
|
|
184
|
+
const route = routeHash ? new URL(href.slice(1), url) : url;
|
|
185
|
+
const base = window.__doocClientBase?.replace(/\/$/, "") ?? "";
|
|
186
|
+
const path = !routeHash && base && route.pathname.startsWith(`${base}/`)
|
|
187
|
+
? route.pathname.slice(base.length)
|
|
188
|
+
: route.pathname;
|
|
189
|
+
const template = templates.find((item) => item.dataset.route === path.replace(/^\/+|\/$/g, "").split("?")[0]);
|
|
190
|
+
if (template && !template.dataset.src) {
|
|
191
|
+
present(template.innerHTML);
|
|
192
|
+
return;
|
|
193
|
+
}
|
|
194
|
+
if (href.startsWith("#") && !routeHash) {
|
|
195
|
+
const anchor = document.getElementById(decodeURIComponent(href.slice(1)));
|
|
196
|
+
if (anchor) {
|
|
197
|
+
present((anchor.closest("section") ?? anchor).outerHTML);
|
|
198
|
+
return;
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
if (!network && !template?.dataset.src)
|
|
202
|
+
throw new Error("Offline preview unavailable");
|
|
203
|
+
const workspace = target.closest("[data-workspace]")?.dataset.workspace;
|
|
204
|
+
const query = new URLSearchParams(route.search);
|
|
205
|
+
query.set("route", path);
|
|
206
|
+
const endpoint = template?.dataset.src ??
|
|
207
|
+
(document.body.classList.contains("edit")
|
|
208
|
+
? `/api/page?${query}`
|
|
209
|
+
: `${path}${route.search}`);
|
|
210
|
+
const response = await request(endpoint, { signal }, workspace);
|
|
211
|
+
if (!response.ok)
|
|
212
|
+
throw new Error(`Preview unavailable: ${response.status}`);
|
|
213
|
+
if (response.headers.get("content-type")?.includes("application/json")) {
|
|
214
|
+
const data = await response.json();
|
|
215
|
+
if (typeof data.html !== "string")
|
|
216
|
+
throw new Error("Preview unavailable");
|
|
217
|
+
present(data.html);
|
|
218
|
+
}
|
|
219
|
+
else {
|
|
220
|
+
const parsed = new DOMParser().parseFromString(await response.text(), "text/html");
|
|
221
|
+
present((parsed.querySelector(".preview-content, main") ?? parsed.body).innerHTML);
|
|
222
|
+
}
|
|
223
|
+
}
|
|
224
|
+
else if (network && /^https?:$/.test(url.protocol)) {
|
|
225
|
+
// shortcut: Some sites hide frame denials; retain the source label as a fallback.
|
|
226
|
+
frame.sandbox.add("allow-scripts");
|
|
227
|
+
frame.src = url.href;
|
|
228
|
+
frame.onerror = () => {
|
|
229
|
+
if (!signal.aborted) {
|
|
230
|
+
frame.replaceWith(status);
|
|
231
|
+
status.textContent = t("Preview unavailable");
|
|
232
|
+
}
|
|
233
|
+
};
|
|
234
|
+
status.replaceWith(frame);
|
|
235
|
+
position();
|
|
236
|
+
}
|
|
237
|
+
else
|
|
238
|
+
throw new Error("Offline preview unavailable");
|
|
239
|
+
}
|
|
240
|
+
catch {
|
|
241
|
+
if (!signal.aborted && popup === host) {
|
|
242
|
+
status.textContent = t("Preview unavailable");
|
|
243
|
+
position();
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
};
|
|
247
|
+
const previewTarget = (event) => {
|
|
248
|
+
const target = event.target instanceof Element
|
|
249
|
+
? event.target.closest("a[href], .subformat-card-open, [data-subformat-record], [data-resource-source]")
|
|
250
|
+
: null;
|
|
251
|
+
if (!target?.closest("main") ||
|
|
252
|
+
target.closest(".link-preview, dialog, .pane-actions, .page-actions, .resource-toolbar, .res-crumbs, .codeblk-head, .cm-editor, #file-editor, [contenteditable]:not([contenteditable=false])") ||
|
|
253
|
+
target.matches("[download], [data-resource-download]"))
|
|
254
|
+
return;
|
|
255
|
+
return target;
|
|
256
|
+
};
|
|
257
|
+
const begin = (target) => {
|
|
258
|
+
close();
|
|
259
|
+
active = target;
|
|
260
|
+
title = target.getAttribute("title");
|
|
261
|
+
target.removeAttribute("title");
|
|
262
|
+
};
|
|
263
|
+
const enter = (event) => {
|
|
264
|
+
if (restoringFocus ||
|
|
265
|
+
press ||
|
|
266
|
+
popup instanceof HTMLDialogElement ||
|
|
267
|
+
window.getSelection()?.isCollapsed === false)
|
|
268
|
+
return;
|
|
269
|
+
if (event instanceof PointerEvent &&
|
|
270
|
+
(event.pointerType !== "mouse" ||
|
|
271
|
+
event.buttons ||
|
|
272
|
+
!matchMedia("(hover: hover)").matches))
|
|
273
|
+
return;
|
|
274
|
+
const target = previewTarget(event);
|
|
275
|
+
if (!target)
|
|
276
|
+
return;
|
|
277
|
+
if (event.type === "focusin" && !target.matches(":focus-visible"))
|
|
278
|
+
return;
|
|
279
|
+
if (target === active) {
|
|
280
|
+
clearTimeout(closeTimer);
|
|
281
|
+
return;
|
|
282
|
+
}
|
|
283
|
+
begin(target);
|
|
284
|
+
if (event instanceof PointerEvent)
|
|
285
|
+
hoverPoint = { x: event.clientX, y: event.clientY };
|
|
286
|
+
timer = setTimeout(() => void show(target), 650);
|
|
287
|
+
};
|
|
288
|
+
document.addEventListener("pointerover", enter);
|
|
289
|
+
document.addEventListener("focusin", enter);
|
|
290
|
+
document.addEventListener("pointerdown", (event) => {
|
|
291
|
+
suppressClick = false;
|
|
292
|
+
if (popup instanceof HTMLDialogElement)
|
|
293
|
+
return;
|
|
294
|
+
close();
|
|
295
|
+
if (!event.isPrimary ||
|
|
296
|
+
event.button !== 0 ||
|
|
297
|
+
!["touch", "pen"].includes(event.pointerType))
|
|
298
|
+
return;
|
|
299
|
+
const target = previewTarget(event);
|
|
300
|
+
if (!target || window.getSelection()?.isCollapsed === false)
|
|
301
|
+
return;
|
|
302
|
+
begin(target);
|
|
303
|
+
target.dataset.linkPreviewPress = "";
|
|
304
|
+
press = { id: event.pointerId, x: event.clientX, y: event.clientY };
|
|
305
|
+
timer = setTimeout(() => void show(target, true), 500);
|
|
306
|
+
}, true);
|
|
307
|
+
document.addEventListener("pointermove", (event) => {
|
|
308
|
+
if (!active || popup)
|
|
309
|
+
return;
|
|
310
|
+
if (press) {
|
|
311
|
+
if (event.pointerId === press.id &&
|
|
312
|
+
Math.hypot(event.clientX - press.x, event.clientY - press.y) > 10)
|
|
313
|
+
close();
|
|
314
|
+
}
|
|
315
|
+
else if (hoverPoint && event.pointerType === "mouse") {
|
|
316
|
+
if (event.buttons) {
|
|
317
|
+
close();
|
|
318
|
+
return;
|
|
319
|
+
}
|
|
320
|
+
if (Math.hypot(event.clientX - hoverPoint.x, event.clientY - hoverPoint.y) < 4)
|
|
321
|
+
return;
|
|
322
|
+
hoverPoint = { x: event.clientX, y: event.clientY };
|
|
323
|
+
clearTimeout(timer);
|
|
324
|
+
const target = active;
|
|
325
|
+
timer = setTimeout(() => void show(target), 650);
|
|
326
|
+
}
|
|
327
|
+
});
|
|
328
|
+
for (const type of ["pointerup", "pointercancel"])
|
|
329
|
+
document.addEventListener(type, (event) => {
|
|
330
|
+
if (event.pointerId !== press?.id)
|
|
331
|
+
return;
|
|
332
|
+
if (!(popup instanceof HTMLDialogElement))
|
|
333
|
+
close();
|
|
334
|
+
press = undefined;
|
|
335
|
+
});
|
|
336
|
+
document.addEventListener("contextmenu", (event) => {
|
|
337
|
+
if ((press || suppressClick) &&
|
|
338
|
+
event.target instanceof Node &&
|
|
339
|
+
active?.contains(event.target))
|
|
340
|
+
event.preventDefault();
|
|
341
|
+
});
|
|
342
|
+
document.addEventListener("pointerout", (event) => {
|
|
343
|
+
if (!active || press || popup instanceof HTMLDialogElement || event.pointerType !== "mouse")
|
|
344
|
+
return;
|
|
345
|
+
const next = event.relatedTarget;
|
|
346
|
+
if (next instanceof Node && (active.contains(next) || popup?.contains(next))) {
|
|
347
|
+
clearTimeout(closeTimer);
|
|
348
|
+
return;
|
|
349
|
+
}
|
|
350
|
+
clearTimeout(timer);
|
|
351
|
+
clearTimeout(closeTimer);
|
|
352
|
+
if (popup)
|
|
353
|
+
closeTimer = setTimeout(close, 150);
|
|
354
|
+
else
|
|
355
|
+
close();
|
|
356
|
+
});
|
|
357
|
+
document.addEventListener("focusout", (event) => {
|
|
358
|
+
if (event.target === active && !(popup instanceof HTMLDialogElement))
|
|
359
|
+
close();
|
|
360
|
+
});
|
|
361
|
+
document.addEventListener("keydown", (event) => {
|
|
362
|
+
if (event.key === "Escape")
|
|
363
|
+
close();
|
|
364
|
+
});
|
|
365
|
+
window.addEventListener("click", (event) => {
|
|
366
|
+
if (suppressClick && event.detail !== 0) {
|
|
367
|
+
suppressClick = false;
|
|
368
|
+
event.preventDefault();
|
|
369
|
+
event.stopImmediatePropagation();
|
|
370
|
+
}
|
|
371
|
+
else if (!(event.target instanceof Node && popup?.contains(event.target)))
|
|
372
|
+
close();
|
|
373
|
+
}, true);
|
|
374
|
+
document.addEventListener("scroll", () => {
|
|
375
|
+
if (!(popup instanceof HTMLDialogElement))
|
|
376
|
+
close();
|
|
377
|
+
}, true);
|
|
378
|
+
document.addEventListener("selectionchange", () => {
|
|
379
|
+
if (window.getSelection()?.isCollapsed === false && !(popup instanceof HTMLDialogElement))
|
|
380
|
+
close();
|
|
381
|
+
});
|
|
382
|
+
document.addEventListener("dragstart", close);
|
|
383
|
+
window.addEventListener("resize", close);
|
|
384
|
+
document.addEventListener("docs:page-shown", close);
|
|
385
|
+
}
|
|
@@ -234,6 +234,10 @@
|
|
|
234
234
|
"Format collections": "Format collections",
|
|
235
235
|
"Collection": "Collection",
|
|
236
236
|
"Grid": "Grid",
|
|
237
|
+
"Grid layout": "Grid layout",
|
|
238
|
+
"Drag or use arrow keys to resize the grid": "Drag or use arrow keys to resize the grid",
|
|
239
|
+
"Display": "Display",
|
|
240
|
+
"Pagination": "Pagination",
|
|
237
241
|
"Columns": "Columns",
|
|
238
242
|
"Rows": "Rows",
|
|
239
243
|
"Folder": "Folder",
|
|
@@ -268,6 +272,105 @@
|
|
|
268
272
|
"Fullscreen is unavailable": "Fullscreen is unavailable",
|
|
269
273
|
"Some registered fonts could not be loaded": "Some registered fonts could not be loaded",
|
|
270
274
|
"Done": "Done",
|
|
275
|
+
"Git views": "Git views",
|
|
276
|
+
"Detached HEAD": "Detached HEAD",
|
|
277
|
+
"Branch name": "Branch name",
|
|
278
|
+
"No commits yet": "No commits yet",
|
|
279
|
+
"Changed files": "Changed files",
|
|
280
|
+
"Filter by path": "Filter by path",
|
|
281
|
+
"Conflicts": "Conflicts",
|
|
282
|
+
"Unstaged": "Unstaged",
|
|
283
|
+
"Staged": "Staged",
|
|
284
|
+
"Conflict": "Conflict",
|
|
285
|
+
"Untracked": "Untracked",
|
|
286
|
+
"Deleted": "Deleted",
|
|
287
|
+
"Renamed": "Renamed",
|
|
288
|
+
"Type changed": "Type changed",
|
|
289
|
+
"Changed": "Changed",
|
|
290
|
+
"View diff for {path}": "View diff for {path}",
|
|
291
|
+
"File diff": "File diff",
|
|
292
|
+
"No text changes": "No text changes",
|
|
293
|
+
"Binary file": "Binary file",
|
|
294
|
+
"File too large to preview": "File too large to preview",
|
|
295
|
+
"Showing the beginning of this diff.": "Showing the beginning of this diff.",
|
|
296
|
+
"Mark resolved": "Mark resolved",
|
|
297
|
+
"Loading diff…": "Loading diff…",
|
|
298
|
+
"Show more files": "Show more files",
|
|
299
|
+
"No matching files": "No matching files",
|
|
300
|
+
"Clear filter": "Clear filter",
|
|
301
|
+
"Check the updated changes and try again.": "Check the updated changes and try again.",
|
|
302
|
+
"Another Git operation is in progress. Try again shortly.": "Another Git operation is in progress. Try again shortly.",
|
|
303
|
+
"Loading repository…": "Loading repository…",
|
|
304
|
+
"Staged {path}": "Staged {path}",
|
|
305
|
+
"Unstaged {path}": "Unstaged {path}",
|
|
306
|
+
"Commit created": "Commit created",
|
|
307
|
+
"Committed locally. Check the current branch before pushing.": "Committed locally. Check the current branch before pushing.",
|
|
308
|
+
"Changes stashed": "Changes stashed",
|
|
309
|
+
"Stash restored": "Stash restored",
|
|
310
|
+
"Pull complete": "Pull complete",
|
|
311
|
+
"Push complete": "Push complete",
|
|
312
|
+
"Pull request created": "Pull request created",
|
|
313
|
+
"Pull request updated": "Pull request updated",
|
|
314
|
+
"Pull request merged": "Pull request merged",
|
|
315
|
+
"Commit and push": "Commit and push",
|
|
316
|
+
"Commit only": "Commit only",
|
|
317
|
+
"Commit options": "Commit options",
|
|
318
|
+
"Committed locally. Push failed: {error}": "Committed locally. Push failed: {error}",
|
|
319
|
+
"Fetch failed: {error}": "Fetch failed: {error}",
|
|
320
|
+
"Commit": "Commit",
|
|
321
|
+
"{count} staged": "{count} staged",
|
|
322
|
+
"Resolve and stage conflicted files before committing.": "Resolve and stage conflicted files before committing.",
|
|
323
|
+
"Synchronization": "Synchronization",
|
|
324
|
+
"Up to date": "Up to date",
|
|
325
|
+
"{count} ahead": "{count} ahead",
|
|
326
|
+
"{count} behind": "{count} behind",
|
|
327
|
+
"No upstream branch": "No upstream branch",
|
|
328
|
+
"Pull": "Pull",
|
|
329
|
+
"A clean working tree is required to pull.": "A clean working tree is required to pull.",
|
|
330
|
+
"Stash": "Stash",
|
|
331
|
+
"Commit your changes before restoring the stash.": "Commit your changes before restoring the stash.",
|
|
332
|
+
"No pull requests": "No pull requests",
|
|
333
|
+
"This workspace has no pull request provider.": "This workspace has no pull request provider.",
|
|
334
|
+
"Pull requests could not be loaded.": "Pull requests could not be loaded.",
|
|
335
|
+
"Loading pull requests…": "Loading pull requests…",
|
|
336
|
+
"This workspace returns staged and unstaged changes together.": "This workspace returns staged and unstaged changes together.",
|
|
337
|
+
"Open in {provider}": "Open in {provider}",
|
|
338
|
+
"Review status unavailable": "Review status unavailable",
|
|
339
|
+
"PR head": "PR head",
|
|
340
|
+
"Open #{number} in {provider}": "Open #{number} in {provider}",
|
|
341
|
+
"Review required": "Review required",
|
|
342
|
+
"Approved": "Approved",
|
|
343
|
+
"Changes requested": "Changes requested",
|
|
344
|
+
"Open": "Open",
|
|
345
|
+
"Merged": "Merged",
|
|
346
|
+
"Closed": "Closed",
|
|
347
|
+
"Pull request state": "Pull request state",
|
|
348
|
+
"All states": "All states",
|
|
349
|
+
"No pull requests match this state.": "No pull requests match this state.",
|
|
350
|
+
"Source branch: {branch}": "Source branch: {branch}",
|
|
351
|
+
"Push the source branch and choose a different base branch.": "Push the source branch and choose a different base branch.",
|
|
352
|
+
"This pull request changed. Reset edits to load the latest version.": "This pull request changed. Reset edits to load the latest version.",
|
|
353
|
+
"New pull request": "New pull request",
|
|
354
|
+
"Create a commit on a branch before opening a pull request.": "Create a commit on a branch before opening a pull request.",
|
|
355
|
+
"No description": "No description",
|
|
356
|
+
"Edit details": "Edit details",
|
|
357
|
+
"Mark this draft ready in the review before merging.": "Mark this draft ready in the review before merging.",
|
|
358
|
+
"Review submitted": "Review submitted",
|
|
359
|
+
"Files changed": "Files changed",
|
|
360
|
+
"Open the provider review to inspect this file.": "Open the provider review to inspect this file.",
|
|
361
|
+
"Open the provider review for the remaining files.": "Open the provider review for the remaining files.",
|
|
362
|
+
"No changed files": "No changed files",
|
|
363
|
+
"Page {number}": "Page {number}",
|
|
364
|
+
"Review decision": "Review decision",
|
|
365
|
+
"Comment": "Comment",
|
|
366
|
+
"Approve": "Approve",
|
|
367
|
+
"Request changes": "Request changes",
|
|
368
|
+
"Review comment": "Review comment",
|
|
369
|
+
"Submit review": "Submit review",
|
|
370
|
+
"Write a review": "Write a review",
|
|
371
|
+
"The pull request changed while you were writing this review.": "The pull request changed while you were writing this review.",
|
|
372
|
+
"Review latest revision": "Review latest revision",
|
|
373
|
+
"Merge #{number} ({commit}) into {base} using {method}?": "Merge #{number} ({commit}) into {base} using {method}?",
|
|
271
374
|
"Git operation failed": "Git operation failed",
|
|
272
375
|
"Create pull request": "Create pull request",
|
|
273
376
|
"Base branch": "Base branch",
|
|
@@ -286,12 +389,10 @@
|
|
|
286
389
|
"This branch does not contain {manifest} at the same path.": "This branch does not contain {manifest} at the same path.",
|
|
287
390
|
"New branches start from the latest commit. Unsaved changes stay in the current workspace.": "New branches start from the latest commit. Unsaved changes stay in the current workspace.",
|
|
288
391
|
"Changes": "Changes",
|
|
289
|
-
"Git uses saved files.": "Git uses saved files.",
|
|
290
392
|
"Stage": "Stage",
|
|
291
393
|
"Unstage": "Unstage",
|
|
292
394
|
"Working tree clean": "Working tree clean",
|
|
293
395
|
"Commit message": "Commit message",
|
|
294
|
-
"Commit staged changes": "Commit staged changes",
|
|
295
396
|
"Fetch": "Fetch",
|
|
296
397
|
"Pull (fast-forward)": "Pull (fast-forward)",
|
|
297
398
|
"Push": "Push",
|
|
@@ -537,5 +638,38 @@
|
|
|
537
638
|
"Conversation is too large. Start a new chat.": "Conversation is too large. Start a new chat.",
|
|
538
639
|
"Attach at most 16 context items per message.": "Attach at most 16 context items per message.",
|
|
539
640
|
"Workspace changed. Start a new chat.": "Workspace changed. Start a new chat.",
|
|
540
|
-
"No matching files or skills.": "No matching files or skills."
|
|
641
|
+
"No matching files or skills.": "No matching files or skills.",
|
|
642
|
+
"LLM chat": "LLM chat",
|
|
643
|
+
"Chat": "Chat",
|
|
644
|
+
"Open chat": "Open chat",
|
|
645
|
+
"Providers": "Providers",
|
|
646
|
+
"Add an API key": "Add an API key",
|
|
647
|
+
"Remove API key": "Remove API key",
|
|
648
|
+
"Saved in this browser": "Saved in this browser",
|
|
649
|
+
"Saved in this browser. Sent only to the provider.": "Saved in this browser. Sent only to the provider.",
|
|
650
|
+
"Saved providers could not be loaded. Check browser storage.": "Saved providers could not be loaded. Check browser storage.",
|
|
651
|
+
"Could not save. Check browser storage and try again.": "Could not save. Check browser storage and try again.",
|
|
652
|
+
"Enter a valid API key and model.": "Enter a valid API key and model.",
|
|
653
|
+
"Add an API key in Providers to start.": "Add an API key in Providers to start.",
|
|
654
|
+
"Open section agent": "Open section agent",
|
|
655
|
+
"Agent": "Agent",
|
|
656
|
+
"Move conversation": "Move conversation",
|
|
657
|
+
"Move to sidebar": "Move to sidebar",
|
|
658
|
+
"Message the agent": "Message the agent",
|
|
659
|
+
"Read and write": "Read and write",
|
|
660
|
+
"Read only": "Read only",
|
|
661
|
+
"Section updated": "Section updated",
|
|
662
|
+
"Section read": "Section read",
|
|
663
|
+
"The source changed. Select the section again before editing.": "The source changed. Select the section again before editing.",
|
|
664
|
+
"This section is read-only.": "This section is read-only.",
|
|
665
|
+
"Read the section before editing it.": "Read the section before editing it.",
|
|
666
|
+
"Invalid section action.": "Invalid section action.",
|
|
667
|
+
"The section could not be updated.": "The section could not be updated.",
|
|
668
|
+
"Agent step limit reached. Review the changes and send a follow-up.": "Agent step limit reached. Review the changes and send a follow-up.",
|
|
669
|
+
"No section is selected for agent actions.": "No section is selected for agent actions.",
|
|
670
|
+
"The provider returned invalid tool calls.": "The provider returned invalid tool calls.",
|
|
671
|
+
"Model": "Model",
|
|
672
|
+
"API key missing": "API key missing",
|
|
673
|
+
"Model list unavailable. Using local choices.": "Model list unavailable. Using local choices.",
|
|
674
|
+
"Enter to select; Ctrl+Enter to configure": "Enter to select; Ctrl+Enter to configure"
|
|
541
675
|
}
|