@celljs/ta-web 4.15.1 → 4.15.2

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.
Files changed (57) hide show
  1. package/esm/browser/components/access-view.d.ts +6 -0
  2. package/esm/browser/components/access-view.js +4 -4
  3. package/esm/browser/components/app-view.js +4 -0
  4. package/esm/browser/components/environment-view.js +9 -2
  5. package/esm/browser/components/host-view.d.ts +1 -1
  6. package/esm/browser/components/settings-parts.js +4 -1
  7. package/esm/browser/extension/web-extension-protocol.d.ts +6 -0
  8. package/esm/browser/extension/web-extensions.d.ts +3 -0
  9. package/esm/browser/extension/web-extensions.js +7 -0
  10. package/esm/browser/gateway/console-extension.d.ts +20 -0
  11. package/esm/browser/gateway/console-extension.js +75 -0
  12. package/esm/browser/gateway/console-parts.d.ts +62 -0
  13. package/esm/browser/gateway/console-parts.js +271 -0
  14. package/esm/browser/gateway/console-tenant.d.ts +22 -0
  15. package/esm/browser/gateway/console-tenant.js +286 -0
  16. package/esm/browser/gateway/console-util.d.ts +59 -0
  17. package/esm/browser/gateway/console-util.js +187 -0
  18. package/esm/browser/gateway/console-view.d.ts +2 -0
  19. package/esm/browser/gateway/console-view.js +218 -0
  20. package/esm/browser/i18n/locales.d.ts +174 -3
  21. package/esm/browser/i18n/messages-ja.js +171 -0
  22. package/esm/browser/i18n/messages-zh-tw.js +171 -0
  23. package/esm/browser/i18n/messages.d.ts +171 -0
  24. package/esm/browser/i18n/messages.js +342 -0
  25. package/esm/browser/index.d.ts +3 -0
  26. package/esm/browser/index.js +3 -0
  27. package/esm/browser/style/pages.d.ts +1 -1
  28. package/esm/browser/style/pages.js +140 -0
  29. package/lib/browser/components/access-view.d.ts +6 -0
  30. package/lib/browser/components/access-view.js +5 -4
  31. package/lib/browser/components/app-view.js +4 -0
  32. package/lib/browser/components/environment-view.js +9 -2
  33. package/lib/browser/components/host-view.d.ts +1 -1
  34. package/lib/browser/components/settings-parts.js +4 -1
  35. package/lib/browser/extension/web-extension-protocol.d.ts +6 -0
  36. package/lib/browser/extension/web-extensions.d.ts +3 -0
  37. package/lib/browser/extension/web-extensions.js +7 -0
  38. package/lib/browser/gateway/console-extension.d.ts +21 -0
  39. package/lib/browser/gateway/console-extension.js +111 -0
  40. package/lib/browser/gateway/console-parts.d.ts +63 -0
  41. package/lib/browser/gateway/console-parts.js +315 -0
  42. package/lib/browser/gateway/console-tenant.d.ts +23 -0
  43. package/lib/browser/gateway/console-tenant.js +327 -0
  44. package/lib/browser/gateway/console-util.d.ts +60 -0
  45. package/lib/browser/gateway/console-util.js +190 -0
  46. package/lib/browser/gateway/console-view.d.ts +3 -0
  47. package/lib/browser/gateway/console-view.js +254 -0
  48. package/lib/browser/i18n/locales.d.ts +174 -3
  49. package/lib/browser/i18n/messages-ja.js +171 -0
  50. package/lib/browser/i18n/messages-zh-tw.js +171 -0
  51. package/lib/browser/i18n/messages.d.ts +171 -0
  52. package/lib/browser/i18n/messages.js +342 -0
  53. package/lib/browser/index.d.ts +3 -0
  54. package/lib/browser/index.js +3 -0
  55. package/lib/browser/style/pages.d.ts +1 -1
  56. package/lib/browser/style/pages.js +140 -0
  57. package/package.json +7 -7
@@ -273,5 +273,145 @@ export const PAGES_STYLE = `
273
273
  .ta-custom-form .ta-input, .ta-custom-model-input { font-size: max(16px, calc(14px * var(--ta-font-scale))); }
274
274
  .ta-custom-actions .ta-button { flex: 1; }
275
275
  }
276
+ /* The console of a gateway (gateway/console-view.tsx). */
277
+ .ta-console-stats { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
278
+ .ta-console-stats.ta-console-stats-small { grid-template-columns: repeat(4, minmax(0, 1fr)); }
279
+ .ta-console-stats-small .ta-console-stat-value { font-size: calc(18px * var(--ta-font-scale)); }
280
+ .ta-console-agent { position: relative; display: flex; align-items: center; gap: 12px; min-height: 54px; padding: 8px 14px; }
281
+ .ta-console-agent + .ta-console-agent::before { content: ''; position: absolute; top: 0; right: 0; left: 33px; height: 1px; background: var(--ta-border-muted); }
282
+ .ta-console-dot.ta-console-agent-working { background: var(--ta-green); animation: ta-console-pulse 1.2s ease-in-out infinite; }
283
+ .ta-console-dot.ta-console-agent-waiting, .ta-console-dot.ta-console-agent-asking { background: var(--ta-blue); }
284
+ .ta-console-stat { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--ta-border-muted); background: var(--ta-list-cell); font: inherit; color: inherit; text-align: left; }
285
+ button.ta-console-stat:not(:disabled):hover { background: var(--ta-hover); }
286
+ button.ta-console-stat:disabled { cursor: default; }
287
+ .ta-console-stat-value { font-size: calc(22px * var(--ta-font-scale)); font-weight: 600; font-variant-numeric: tabular-nums; line-height: 1.2; }
288
+ .ta-console-stat-value.ta-good { color: var(--ta-green); }
289
+ .ta-console-stat-value.ta-warn { color: var(--ta-yellow); }
290
+ .ta-console-stat-label { font-size: calc(12px * var(--ta-font-scale)); color: var(--ta-muted); }
291
+ .ta-console-section { display: flex; align-items: center; justify-content: space-between; min-height: 28px; margin: 4px 4px -8px; }
292
+ .ta-console-section-title { font-size: calc(12.5px * var(--ta-font-scale)); font-weight: 600; color: var(--ta-secondary); }
293
+ .ta-console-tenant, .ta-console-provider { position: relative; display: flex; align-items: center; gap: 12px; width: 100%; min-height: 58px; padding: 8px 14px; border: 0; background: none; font: inherit; color: var(--ta-text); text-align: left; }
294
+ .ta-console-tenant { transition: background 120ms; }
295
+ .ta-console-tenant:hover { background: var(--ta-hover); }
296
+ .ta-console-tenant:focus-visible { outline: 1px solid var(--ta-border-focus); outline-offset: -1px; }
297
+ .ta-console-tenant + .ta-console-tenant::before, .ta-console-provider + .ta-console-provider::before { content: ''; position: absolute; top: 0; right: 0; left: 58px; height: 1px; background: var(--ta-border-muted); }
298
+ .ta-console-avatar { width: 32px; height: 32px; flex: none; border-radius: 50%; object-fit: cover; }
299
+ .ta-console-avatar.ta-chat-avatar { font-size: 14px; }
300
+ .ta-console-avatar-large { width: 56px; height: 56px; }
301
+ .ta-console-avatar-large.ta-chat-avatar { font-size: 22px; }
302
+ .ta-console-tenant-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
303
+ .ta-console-tenant-name { font-size: calc(14.5px * var(--ta-font-scale)); font-weight: 500; }
304
+ .ta-console-account { font-size: calc(12.5px * var(--ta-font-scale)); font-weight: 400; color: var(--ta-muted); }
305
+ .ta-console-tenant-state { display: inline-flex; align-items: center; gap: 6px; font-size: calc(12.5px * var(--ta-font-scale)); color: var(--ta-muted); min-width: 0; }
306
+ .ta-console-dot { width: 7px; height: 7px; flex: none; border-radius: 50%; background: var(--ta-border-field); }
307
+ .ta-console-dot.ta-console-running { background: var(--ta-green); }
308
+ .ta-console-dot.ta-console-starting { background: var(--ta-blue); animation: ta-console-pulse 1.2s ease-in-out infinite; }
309
+ .ta-console-dot.ta-console-failed { background: var(--ta-red); }
310
+ @keyframes ta-console-pulse { 50% { opacity: 0.35; } }
311
+ .ta-console-tenant-usage { flex: none; display: flex; flex-direction: column; align-items: flex-end; gap: 3px; font-size: calc(12px * var(--ta-font-scale)); font-variant-numeric: tabular-nums; color: var(--ta-secondary); }
312
+ .ta-console-bar { display: block; height: 6px; border-radius: 3px; background: var(--ta-chip); overflow: hidden; }
313
+ .ta-console-bar > span { display: block; height: 100%; border-radius: inherit; background: var(--ta-green); transition: width 300ms var(--ta-ease); }
314
+ .ta-console-bar > span.ta-warm { background: var(--ta-yellow); }
315
+ .ta-console-bar > span.ta-high { background: var(--ta-red); }
316
+ .ta-console-bar-small { width: 56px; height: 4px; }
317
+ .ta-console-chip { display: inline-block; margin-left: 8px; padding: 1px 7px; border-radius: 999px; background: var(--ta-chip); font-size: calc(11px * var(--ta-font-scale)); font-weight: 500; color: var(--ta-secondary); vertical-align: 1px; }
318
+ .ta-console-invite { display: flex; flex-direction: column; gap: 8px; padding: 14px; border-radius: 12px; border: 1px solid var(--ta-border-muted); background: var(--ta-list-cell); }
319
+ .ta-console-invite .ta-list-hint { margin: 0; }
320
+ .ta-console-mono { font-family: var(--ta-mono); font-size: calc(12.5px * var(--ta-font-scale)); word-break: break-all; }
321
+ .ta-console-actions { display: flex; flex-wrap: wrap; gap: 8px; }
322
+ .ta-console-person { display: flex; align-items: center; gap: 14px; padding: 4px 2px; }
323
+ .ta-console-person-text { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
324
+ .ta-console-person-name { font-size: calc(17px * var(--ta-font-scale)); font-weight: 600; }
325
+ .ta-console-usage { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 10px; }
326
+ .ta-console-meter { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--ta-border-muted); background: var(--ta-list-cell); }
327
+ .ta-console-meter-text { display: flex; justify-content: space-between; gap: 8px; font-size: calc(12.5px * var(--ta-font-scale)); color: var(--ta-muted); }
328
+ .ta-console-meter-value { font-variant-numeric: tabular-nums; color: var(--ta-text); }
329
+ .ta-console-facts { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px 16px; margin: 0; padding: 14px; border-radius: 12px; border: 1px solid var(--ta-border-muted); background: var(--ta-list-cell); font-size: calc(13.5px * var(--ta-font-scale)); }
330
+ .ta-console-facts dt { color: var(--ta-muted); }
331
+ .ta-console-facts dd { margin: 0; min-width: 0; text-align: right; }
332
+ .ta-console-logs { margin: 0; max-height: 420px; overflow: auto; padding: 12px 14px; border-radius: 12px; border: 1px solid var(--ta-border-muted); background: var(--ta-code); font-family: var(--ta-mono); font-size: calc(12px * var(--ta-font-scale)); line-height: 1.5; white-space: pre-wrap; word-break: break-all; color: var(--ta-secondary); }
333
+ .ta-console-loading { align-self: center; margin: 40px 0; }
334
+ .ta-console .ta-phone-stack-top { background: var(--ta-list-bg); }
335
+ @media ${DeviceMedia.COMPACT} {
336
+ .ta-console-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
337
+ .ta-console-stats.ta-console-stats-small { grid-template-columns: repeat(2, minmax(0, 1fr)); }
338
+ }
339
+ .ta-console-content { gap: 14px; }
340
+ .ta-console-content > .ta-segmented { align-self: stretch; }
341
+ .ta-console-stat-value.ta-bad { color: var(--ta-red); }
342
+ .ta-console-chip-warn { background: color-mix(in srgb, var(--ta-yellow) 18%, transparent); color: var(--ta-yellow); }
343
+ .ta-console-role-owner { background: color-mix(in srgb, var(--ta-blue) 16%, transparent); color: var(--ta-blue); }
344
+ .ta-console-role-admin { background: color-mix(in srgb, var(--ta-green) 16%, transparent); color: var(--ta-green); }
345
+ .ta-console-meter-hint { font-size: calc(11.5px * var(--ta-font-scale)); color: var(--ta-muted); }
346
+ .ta-console-card { display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: 12px; border: 1px solid var(--ta-border-muted); background: var(--ta-list-cell); }
347
+ .ta-console-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
348
+ .ta-console-card-controls { display: flex; gap: 8px; flex-wrap: wrap; }
349
+ .ta-console-card-controls .ta-segmented button { padding: 0 10px; white-space: nowrap; }
350
+ .ta-console-total { display: flex; flex-direction: column; gap: 2px; }
351
+ .ta-console-total strong { font-size: calc(22px * var(--ta-font-scale)); font-weight: 600; font-variant-numeric: tabular-nums; line-height: 1.2; }
352
+ .ta-console-total span, .ta-console-card-label { font-size: calc(12px * var(--ta-font-scale)); color: var(--ta-muted); }
353
+ .ta-console-card-label { margin-top: 4px; }
354
+ .ta-console-chart { display: flex; flex-direction: column; gap: 4px; }
355
+ .ta-console-chart svg { width: 100%; height: 120px; display: block; overflow: visible; }
356
+ .ta-console-chart-loading { height: 160px; border-radius: 8px; background: var(--ta-chip); opacity: 0.5; }
357
+ .ta-console-chart-hover { display: flex; align-items: baseline; gap: 8px; min-height: 20px; font-size: calc(12px * var(--ta-font-scale)); color: var(--ta-muted); font-variant-numeric: tabular-nums; }
358
+ .ta-console-chart-hover strong { color: var(--ta-text); font-weight: 600; }
359
+ .ta-console-chart-hit { fill: transparent; }
360
+ .ta-console-chart-bar { fill: color-mix(in srgb, var(--ta-green) 55%, transparent); transition: fill 120ms; }
361
+ .ta-console-chart-bar.ta-on { fill: var(--ta-green); }
362
+ .ta-console-chart-axis { stroke: var(--ta-border-muted); stroke-width: 1; }
363
+ .ta-console-chart-ticks { display: flex; justify-content: space-between; font-size: calc(11px * var(--ta-font-scale)); color: var(--ta-muted); }
364
+ .ta-console-shares { display: flex; flex-direction: column; gap: 6px; }
365
+ .ta-console-share { display: grid; grid-template-columns: minmax(0, 1fr) 96px 64px; align-items: center; gap: 10px; font-size: calc(12.5px * var(--ta-font-scale)); }
366
+ .ta-console-share .ta-console-bar-small { width: 100%; }
367
+ .ta-console-bar > span.ta-part { background: var(--ta-blue); }
368
+ .ta-console-share-button { padding: 2px 4px; margin: 0 -4px; border: 0; border-radius: 6px; background: none; font: inherit; color: inherit; text-align: left; }
369
+ .ta-console-share-button:hover { background: var(--ta-hover); }
370
+ .ta-console-share-value { text-align: right; font-variant-numeric: tabular-nums; color: var(--ta-secondary); }
371
+ .ta-console-limits { gap: 0; padding: 4px 14px; }
372
+ .ta-console-limit { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; }
373
+ .ta-console-limit + .ta-console-limit, .ta-console-chips + .ta-console-limit { border-top: 1px solid var(--ta-border-muted); }
374
+ .ta-console-limit-text { min-width: 0; display: flex; flex-direction: column; gap: 2px; font-size: calc(13.5px * var(--ta-font-scale)); }
375
+ .ta-console-limit-hint { font-size: calc(12px * var(--ta-font-scale)); color: var(--ta-muted); }
376
+ .ta-console-limit-control { flex: none; display: flex; align-items: center; gap: 6px; }
377
+ .ta-console-select { width: auto; min-width: 104px; height: 32px; padding: 0 8px; font-size: calc(13px * var(--ta-font-scale)); }
378
+ .ta-console-number { width: 84px; height: 32px; font-variant-numeric: tabular-nums; }
379
+ .ta-console-number.ta-invalid { border-color: var(--ta-red); }
380
+ .ta-console-chips { display: flex; flex-wrap: wrap; gap: 6px; }
381
+ .ta-console-limits .ta-console-chips { padding: 0 0 10px; }
382
+ .ta-console-chip-toggle { display: inline-flex; align-items: center; gap: 5px; height: 28px; padding: 0 11px; border-radius: 999px; border: 1px solid var(--ta-border-muted); background: var(--ta-list-cell); font: inherit; font-size: calc(12.5px * var(--ta-font-scale)); color: var(--ta-secondary); transition: background 120ms, color 120ms, border-color 120ms; }
383
+ .ta-console-chip-toggle:hover:not(:disabled) { color: var(--ta-text); }
384
+ .ta-console-chip-toggle.ta-on { border-color: transparent; background: var(--ta-segment); color: var(--ta-text); font-weight: 500; }
385
+ .ta-console-chip-count { font-variant-numeric: tabular-nums; color: var(--ta-muted); }
386
+ .ta-console-form-actions { justify-content: flex-end; padding: 10px 0; border-top: 1px solid var(--ta-border-muted); }
387
+ .ta-console-role-row { display: flex; align-items: center; gap: 8px; padding: 10px 14px; border-radius: 12px; border: 1px solid var(--ta-border-muted); background: var(--ta-list-cell); font-size: calc(13.5px * var(--ta-font-scale)); color: var(--ta-secondary); }
388
+ .ta-console-role-row > span { flex: 1; }
389
+ .ta-console-toolbar { display: flex; gap: 8px; }
390
+ .ta-console-search { flex: 1; }
391
+ .ta-console-agent-block { position: relative; }
392
+ .ta-console-agent-block + .ta-console-agent-block::before { content: ''; position: absolute; top: 0; right: 0; left: 33px; height: 1px; background: var(--ta-border-muted); }
393
+ button.ta-console-agent { width: 100%; border: 0; background: none; font: inherit; color: inherit; text-align: left; transition: background 120ms; }
394
+ button.ta-console-agent:hover { background: var(--ta-hover); }
395
+ .ta-console-activity { display: flex; flex-direction: column; gap: 2px; padding: 0 14px 12px 33px; }
396
+ .ta-console-activity-summary { font-size: calc(12px * var(--ta-font-scale)); color: var(--ta-muted); padding-bottom: 4px; }
397
+ .ta-console-activity-empty { margin: 0; padding: 0 14px 12px 33px; }
398
+ .ta-console-activity-row { display: flex; align-items: center; gap: 8px; min-height: 24px; font-size: calc(12.5px * var(--ta-font-scale)); }
399
+ .ta-console-activity-name { flex: none; font-family: var(--ta-mono); font-size: calc(12px * var(--ta-font-scale)); }
400
+ .ta-console-activity-error { flex: 1; min-width: 0; color: var(--ta-red); }
401
+ .ta-console-activity-time { flex: none; margin-left: auto; font-size: calc(11.5px * var(--ta-font-scale)); color: var(--ta-muted); font-variant-numeric: tabular-nums; }
402
+ .ta-console-audit { display: flex; align-items: center; gap: 10px; min-height: 40px; padding: 6px 14px; font-size: calc(13px * var(--ta-font-scale)); }
403
+ .ta-console-audit + .ta-console-audit { border-top: 1px solid var(--ta-border-muted); }
404
+ .ta-console-audit-text { flex: 1; min-width: 0; display: inline-flex; align-items: center; gap: 4px; }
405
+ .ta-console-audit-text strong { font-weight: 500; }
406
+ .ta-console-audit-detail { color: var(--ta-muted); }
407
+ .ta-console-foot { text-align: center; }
408
+ @media ${DeviceMedia.COMPACT} {
409
+ .ta-console-share { grid-template-columns: minmax(0, 1fr) 64px 56px; }
410
+ .ta-console-limit { flex-direction: column; align-items: stretch; }
411
+ .ta-console-limit-control { justify-content: flex-end; }
412
+ .ta-console-select, .ta-console-number { font-size: max(16px, calc(13px * var(--ta-font-scale))); }
413
+ .ta-console-card-controls { width: 100%; }
414
+ .ta-console-card-controls .ta-segmented { flex: 1; }
415
+ }
276
416
  `;
277
417
  //# sourceMappingURL=pages.js.map
@@ -5,6 +5,12 @@ export declare function useAccess(): {
5
5
  info: TaAccessInfo | undefined;
6
6
  read: () => Promise<void>;
7
7
  };
8
+ /** The account's letter or picture, as a conversation of the list; `className` sizes it. */
9
+ export declare function AccountAvatar({ id, avatar, className }: {
10
+ id: string;
11
+ avatar?: string;
12
+ className?: string;
13
+ }): React.JSX.Element;
8
14
  /**
9
15
  * Settings, Access: the accounts that may sign in (those of TA_ALLOWED_USERS, and those added here), the
10
16
  * ones that signed in and wait, and the browsers signed in. The owner, in with the token on the page of
@@ -34,6 +34,7 @@ var __importStar = (this && this.__importStar) || (function () {
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
36
  exports.useAccess = useAccess;
37
+ exports.AccountAvatar = AccountAvatar;
37
38
  exports.AccessSettings = AccessSettings;
38
39
  const lucide_react_1 = require("lucide-react");
39
40
  const React = __importStar(require("react"));
@@ -58,13 +59,13 @@ function useAccess() {
58
59
  }, [workbench.status, read]);
59
60
  return { info, read };
60
61
  }
61
- /** The account's letter or picture, as a conversation of the list. */
62
- function AccountAvatar({ id, avatar }) {
62
+ /** The account's letter or picture, as a conversation of the list; `className` sizes it. */
63
+ function AccountAvatar({ id, avatar, className = 'ta-access-avatar' }) {
63
64
  if (avatar) {
64
- return React.createElement("img", { className: "ta-access-avatar", src: avatar, alt: "", referrerPolicy: "no-referrer" });
65
+ return React.createElement("img", { className: className, src: avatar, alt: "", referrerPolicy: "no-referrer" });
65
66
  }
66
67
  const name = id.split(':').slice(1).join(':') || id;
67
- return (React.createElement("span", { className: `ta-access-avatar ta-chat-avatar ta-tone-${chat_list_1.ChatListUtil.tone(id)}`, "aria-hidden": "true" }, name.charAt(0).toUpperCase()));
68
+ return (React.createElement("span", { className: `${className} ta-chat-avatar ta-tone-${chat_list_1.ChatListUtil.tone(id)}`, "aria-hidden": "true" }, name.charAt(0).toUpperCase()));
68
69
  }
69
70
  function AccountLabel({ id, name, avatar }) {
70
71
  return (React.createElement("span", { className: "ta-access-account" },
@@ -199,6 +199,10 @@ function AppShell() {
199
199
  setSurface(undefined);
200
200
  }
201
201
  }, [focus, revealRight, revealEditor]);
202
+ React.useEffect(() => {
203
+ host.setSettingsOpener(openSettings);
204
+ return () => host.setSettingsOpener(undefined);
205
+ }, [host, openSettings]);
202
206
  // A web extension shows another conversation: the conversation, not a page, a drawer or the workbench over it, is then in front.
203
207
  React.useEffect(() => {
204
208
  host.setSessionSwitcher(async (session, opening) => {
@@ -39,6 +39,7 @@ exports.EnvironmentSettings = EnvironmentSettings;
39
39
  exports.EnvironmentPage = EnvironmentPage;
40
40
  const lucide_react_1 = require("lucide-react");
41
41
  const React = __importStar(require("react"));
42
+ const console_parts_1 = require("../gateway/console-parts");
42
43
  const hooks_1 = require("../hooks");
43
44
  const use_t_1 = require("../i18n/use-t");
44
45
  const callout_1 = require("./callout");
@@ -215,6 +216,8 @@ function EnvironmentSettings({ info, onChange }) {
215
216
  busy ? React.createElement("span", { className: "ta-spinner" }) : React.createElement(icon_1.Icon, { icon: lucide_react_1.RotateCw, size: 14 }),
216
217
  " ",
217
218
  t('ta.environment.restart'))),
219
+ React.createElement(settings_controls_1.Row, { label: t('ta.console.quota'), description: t('ta.environment.quotaHint'), stacked: true },
220
+ React.createElement(console_parts_1.QuotaMeters, { quota: info.quota })),
218
221
  React.createElement(settings_controls_1.Row, { label: t('ta.environment.where'), description: t('ta.environment.whereHint'), stacked: true },
219
222
  React.createElement(EnvironmentChooser, { info: info, onChanged: reload })),
220
223
  info.admin && React.createElement(Tenants, null)));
@@ -230,8 +233,12 @@ function EnvironmentPage() {
230
233
  return (React.createElement("div", { className: "ta-signin" },
231
234
  React.createElement("div", { className: "ta-card ta-environment-card" },
232
235
  React.createElement(ta_avatar_1.TaAvatar, { size: 72 }),
233
- React.createElement("h1", null, t('ta.environment.failedTitle')),
234
- React.createElement(callout_1.Callout, { level: "error" }, (_a = info === null || info === void 0 ? void 0 : info.environment.error) !== null && _a !== void 0 ? _a : workbench.environmentError),
236
+ React.createElement("h1", null, t((info === null || info === void 0 ? void 0 : info.quota.blocked) ? 'ta.environment.blockedTitle' : 'ta.environment.failedTitle')),
237
+ (info === null || info === void 0 ? void 0 : info.quota.blocked) ? (React.createElement(React.Fragment, null,
238
+ React.createElement(callout_1.Callout, { level: "warning" }, t(info.quota.blocked === 'suspended' ? 'ta.environment.blockedSuspended' : 'ta.environment.blockedMinutes', {
239
+ date: new Date(info.quota.resetsAt).toLocaleDateString(undefined, { month: 'long', day: 'numeric' }),
240
+ })),
241
+ React.createElement(console_parts_1.QuotaMeters, { quota: info.quota }))) : (React.createElement(callout_1.Callout, { level: "error" }, (_a = info === null || info === void 0 ? void 0 : info.environment.error) !== null && _a !== void 0 ? _a : workbench.environmentError)),
235
242
  React.createElement("button", { type: "button", className: "ta-button ta-primary ta-wide", disabled: busy, onClick: async () => {
236
243
  setBusy(true);
237
244
  try {
@@ -4,7 +4,7 @@ import type { SavedHost } from '../workbench-protocol';
4
4
  /** Adding a computer by its code or link: what the sign-in and the sheet of the computers share. */
5
5
  export declare function useAddHost(): {
6
6
  busy: boolean;
7
- error: "ta.access.add" | "ta.access.addHint" | "ta.access.added" | "ta.access.allow" | "ta.access.bind" | "ta.access.bindHint" | "ta.access.browser" | "ta.access.dismiss" | "ta.access.fromEnv" | "ta.access.lastUsed" | "ta.access.none" | "ta.access.noneHint" | "ta.access.remove" | "ta.access.removeAccount" | "ta.access.removeConfirm" | "ta.access.removeDetail" | "ta.access.requested" | "ta.access.signOut" | "ta.access.thisBrowser" | "ta.access.title" | "ta.account" | "ta.account.menu" | "ta.account.service" | "ta.ask.no" | "ta.ask.start" | "ta.ask.title" | "ta.ask.waiting" | "ta.assistant.attention" | "ta.assistant.busy" | "ta.assistant.confirmOn" | "ta.assistant.confirmShort" | "ta.assistant.copied" | "ta.assistant.copyCwd" | "ta.assistant.cwdTitle" | "ta.assistant.endedTasks" | "ta.assistant.export" | "ta.assistant.forbidden" | "ta.assistant.hello" | "ta.assistant.look" | "ta.assistant.me" | "ta.assistant.noTasks" | "ta.assistant.noTasksHint" | "ta.assistant.nothingToExport" | "ta.assistant.offline" | "ta.assistant.placeholder" | "ta.assistant.poke" | "ta.assistant.prompt" | "ta.assistant.promptTitle" | "ta.assistant.rename" | "ta.assistant.restart" | "ta.assistant.restartHint" | "ta.assistant.restartTitle" | "ta.assistant.runningTasks" | "ta.assistant.showTasks" | "ta.assistant.speakOn" | "ta.assistant.speakStop" | "ta.assistant.speakStopShort" | "ta.assistant.speakTalkShort" | "ta.assistant.step.run" | "ta.assistant.step.say" | "ta.assistant.step.tell" | "ta.assistant.stop" | "ta.assistant.taskEnded" | "ta.assistant.tasks" | "ta.assistant.tasksTool" | "ta.assistant.waking" | "ta.assistant.working" | "ta.assistant.you" | "ta.auth.account" | "ta.auth.accounts" | "ta.auth.accountsExample" | "ta.auth.accountsTitle" | "ta.auth.apiKey" | "ta.auth.back" | "ta.auth.continue" | "ta.auth.copyAndOpen" | "ta.auth.copyCode" | "ta.auth.copyLink" | "ta.auth.custom.add" | "ta.auth.custom.addHeader" | "ta.auth.custom.addHint" | "ta.auth.custom.advanced" | "ta.auth.custom.advancedHint" | "ta.auth.custom.api" | "ta.auth.custom.apiAnthropic" | "ta.auth.custom.apiGoogle" | "ta.auth.custom.apiKey" | "ta.auth.custom.apiOpenai" | "ta.auth.custom.apiResponses" | "ta.auth.custom.badNumber" | "ta.auth.custom.baseUrl" | "ta.auth.custom.contextWindow" | "ta.auth.custom.fetch" | "ta.auth.custom.fetchFailed" | "ta.auth.custom.fetched" | "ta.auth.custom.fetchedNone" | "ta.auth.custom.filter" | "ta.auth.custom.headerName" | "ta.auth.custom.headerValue" | "ta.auth.custom.headers" | "ta.auth.custom.images" | "ta.auth.custom.keyKept" | "ta.auth.custom.keyOptional" | "ta.auth.custom.kind" | "ta.auth.custom.maxTokens" | "ta.auth.custom.mixed" | "ta.auth.custom.modelPlaceholder" | "ta.auth.custom.models" | "ta.auth.custom.name" | "ta.auth.custom.needModel" | "ta.auth.custom.note" | "ta.auth.custom.optional" | "ta.auth.custom.reasoning" | "ta.auth.custom.remove" | "ta.auth.custom.removeConfirm" | "ta.auth.custom.removeHeader" | "ta.auth.custom.removeModel" | "ta.auth.custom.save" | "ta.auth.custom.saved" | "ta.auth.custom.title" | "ta.auth.deviceHint" | "ta.auth.done" | "ta.auth.enterKey" | "ta.auth.failed" | "ta.auth.hint" | "ta.auth.hintRemote" | "ta.auth.keys" | "ta.auth.keysExample" | "ta.auth.later" | "ta.auth.manualCode" | "ta.auth.manualCodeRemote" | "ta.auth.none" | "ta.auth.openHint" | "ta.auth.openPage" | "ta.auth.search" | "ta.auth.signOut" | "ta.auth.signOutConfirm" | "ta.auth.signedIn" | "ta.auth.subscription" | "ta.auth.title" | "ta.auth.waiting" | "ta.back" | "ta.board" | "ta.board.add" | "ta.board.done" | "ta.board.edit" | "ta.board.empty" | "ta.board.emptyHint" | "ta.board.moreTasks" | "ta.board.move" | "ta.board.noTasks" | "ta.board.none" | "ta.board.noneHint" | "ta.board.put" | "ta.board.remove" | "ta.board.tasks" | "ta.builtin.assistant" | "ta.builtin.assistantHint" | "ta.cancel" | "ta.chat" | "ta.chat.archived" | "ta.chat.archivedCount" | "ta.chat.archivedHint" | "ta.chat.asking" | "ta.chat.asks" | "ta.chat.asksCount" | "ta.chat.byDirectory" | "ta.chat.cwdTitle" | "ta.chat.doubleTag" | "ta.chat.doubleTagTitle" | "ta.chat.handToDouble" | "ta.chat.hint" | "ta.chat.letGo" | "ta.chat.new" | "ta.chat.newIn" | "ta.chat.noMatch" | "ta.chat.none" | "ta.chat.noneHint" | "ta.chat.olderCount" | "ta.chat.open" | "ta.chat.opening" | "ta.chat.openingOffline" | "ta.chat.pin" | "ta.chat.pinned" | "ta.chat.remove" | "ta.chat.removeShort" | "ta.chat.removed" | "ta.chat.replyingFor" | "ta.chat.restore" | "ta.chat.restoreShort" | "ta.chat.search" | "ta.chat.suggest.1" | "ta.chat.suggest.1.label" | "ta.chat.suggest.2" | "ta.chat.suggest.2.label" | "ta.chat.suggest.3" | "ta.chat.suggest.3.label" | "ta.chat.title" | "ta.chat.toAsk" | "ta.chat.unpin" | "ta.chat.unseen" | "ta.close" | "ta.command.bug" | "ta.command.mcp" | "ta.composer.addImage" | "ta.composer.album" | "ta.composer.camera" | "ta.composer.commands" | "ta.composer.filesUnavailable" | "ta.composer.filter" | "ta.composer.image.count" | "ta.composer.image.size" | "ta.composer.image.type" | "ta.composer.imageLoading" | "ta.composer.keyboard" | "ta.composer.label" | "ta.composer.listening" | "ta.composer.mentionFile" | "ta.composer.more" | "ta.composer.noFiles" | "ta.composer.noMatch" | "ta.composer.page" | "ta.composer.placeholder" | "ta.composer.placeholderTouch" | "ta.composer.queue.count" | "ta.composer.queue.editTitle" | "ta.composer.queue.followUp" | "ta.composer.queue.remove" | "ta.composer.queue.steering" | "ta.composer.queue.takeBackAll" | "ta.composer.queue.takeBackTitle" | "ta.composer.recentShot" | "ta.composer.recentShotAdd" | "ta.composer.removeImage" | "ta.composer.steerPlaceholder" | "ta.composer.steerPlaceholderTouch" | "ta.composer.steerTitle" | "ta.composer.stopTitle" | "ta.composer.stopping" | "ta.composer.voice" | "ta.composer.voiceDenied" | "ta.composer.voiceFailed" | "ta.composer.voiceStop" | "ta.connection.away" | "ta.connection.awayBrief" | "ta.connection.back" | "ta.connection.lost" | "ta.connection.notDone" | "ta.connection.outdated" | "ta.connection.reload" | "ta.connection.retry" | "ta.connection.retryIn" | "ta.connection.retryNow" | "ta.connection.retrying" | "ta.connection.unreachableBrief" | "ta.copied" | "ta.copy" | "ta.discover" | "ta.discover.empty" | "ta.discover.emptyHint" | "ta.discover.hint" | "ta.dismiss" | "ta.editor" | "ta.editor.close" | "ta.editor.discardClose" | "ta.editor.failed" | "ta.editor.loading" | "ta.editor.unsavedManyTitle" | "ta.editor.unsavedMessage" | "ta.editor.unsavedTitle" | "ta.environment.connect" | "ta.environment.connections" | "ta.environment.failed" | "ta.environment.failedTitle" | "ta.environment.none" | "ta.environment.own" | "ta.environment.ownDetail" | "ta.environment.ownHint" | "ta.environment.restart" | "ta.environment.restartConfirm" | "ta.environment.restartDetail" | "ta.environment.retry" | "ta.environment.running" | "ta.environment.sandbox" | "ta.environment.starting" | "ta.environment.stop" | "ta.environment.stopConfirm" | "ta.environment.stopDetail" | "ta.environment.stopped" | "ta.environment.switch" | "ta.environment.switchConfirm" | "ta.environment.switchDetail" | "ta.environment.title" | "ta.environment.token" | "ta.environment.url" | "ta.environment.where" | "ta.environment.whereHint" | "ta.error.alreadyCompacted" | "ta.error.forbidden" | "ta.error.forbiddenAsk" | "ta.error.forbiddenHint" | "ta.error.forbiddenNever" | "ta.error.limit" | "ta.error.messageConflict" | "ta.error.modelNotFound" | "ta.error.nothingToCompact" | "ta.error.sessionBusy" | "ta.error.sessionLocked" | "ta.error.sessionNotFound" | "ta.error.tooManySessions" | "ta.folder.empty" | "ta.folder.failed" | "ta.folder.open" | "ta.folder.path" | "ta.folder.title" | "ta.folder.up" | "ta.gait.bounce" | "ta.gait.sneak" | "ta.gait.strut" | "ta.gait.waddle" | "ta.gait.walk" | "ta.game.failed" | "ta.game.label" | "ta.game.loading" | "ta.home" | "ta.host.title" | "ta.hosts.cameraDenied" | "ta.hosts.connecting" | "ta.hosts.notPairing" | "ta.hosts.paste" | "ta.hosts.refused" | "ta.hosts.remove" | "ta.hosts.removeConfirm" | "ta.hosts.rename" | "ta.hosts.saved" | "ta.hosts.scan" | "ta.hosts.scanFailed" | "ta.hosts.scanHint" | "ta.hosts.scanInstructions" | "ta.hosts.scanShort" | "ta.hosts.switching" | "ta.hosts.thisServer" | "ta.hosts.title" | "ta.hosts.unreachable" | "ta.launch.failed" | "ta.launch.open" | "ta.launch.ready" | "ta.launcher" | "ta.launcher.back" | "ta.launcher.clear" | "ta.launcher.noResults" | "ta.launcher.place.discover" | "ta.launcher.place.launcher" | "ta.launcher.place.list" | "ta.launcher.place.navigation" | "ta.launcher.search" | "ta.launcher.searchHint" | "ta.launcher.searchPlaceholder" | "ta.layout.editor" | "ta.layout.panel" | "ta.layout.resize" | "ta.layout.sidebar" | "ta.link.ask" | "ta.link.copied" | "ta.link.external" | "ta.link.externalMac" | "ta.link.noOpener" | "ta.link.notFound" | "ta.link.open" | "ta.link.openFile" | "ta.link.openFolder" | "ta.link.trust" | "ta.link.trustHint" | "ta.look.gait" | "ta.look.premium" | "ta.look.species" | "ta.look.title" | "ta.manage.about" | "ta.manage.accounts" | "ta.manage.packages" | "ta.manage.relay" | "ta.manage.shortcuts" | "ta.manage.workingDirectory" | "ta.markdown.diagram" | "ta.markdown.download" | "ta.markdown.enlarge" | "ta.markdown.exitFullscreen" | "ta.markdown.fullscreen" | "ta.markdown.missing" | "ta.markdown.source" | "ta.me" | "ta.menu" | "ta.message.branch" | "ta.message.compacted" | "ta.message.compactedFrom" | "ta.message.debug" | "ta.message.debugCopied" | "ta.message.discard" | "ta.message.failedUnknown" | "ta.message.forkAt" | "ta.message.forkBefore" | "ta.message.forked" | "ta.message.images" | "ta.message.interrupted" | "ta.message.modelSwitched" | "ta.message.notSaved" | "ta.message.queued" | "ta.message.queuedTitle" | "ta.message.quote" | "ta.message.resend" | "ta.message.resume" | "ta.message.resumeText" | "ta.message.resumed" | "ta.message.rewind" | "ta.message.rewindConfirm" | "ta.message.rewindDetail" | "ta.message.selectText" | "ta.message.sendFailed" | "ta.message.showLess" | "ta.message.showMore" | "ta.message.silent" | "ta.message.skill" | "ta.message.steered" | "ta.message.steeredTitle" | "ta.message.stopped" | "ta.message.thinking" | "ta.message.usageTitle" | "ta.message.used" | "ta.model.default" | "ta.model.defaultNone" | "ta.model.search" | "ta.mood.attention" | "ta.mood.done" | "ta.mood.idle" | "ta.mood.listening" | "ta.mood.sleeping" | "ta.mood.speaking" | "ta.mood.thinking" | "ta.mood.working" | "ta.more" | "ta.nav.fold" | "ta.nav.open" | "ta.nav.pin" | "ta.nav.settings" | "ta.no" | "ta.notice.openLink" | "ta.notice.picture" | "ta.notices" | "ta.off" | "ta.ok" | "ta.on" | "ta.online" | "ta.open.failed" | "ta.open.notALink" | "ta.open.open" | "ta.open.published" | "ta.open.relayed" | "ta.open.title" | "ta.packages" | "ta.packages.builtin" | "ta.packages.builtinTitle" | "ta.packages.failed" | "ta.packages.hint" | "ta.packages.installed" | "ta.packages.none" | "ta.packages.noneHint" | "ta.packages.reload" | "ta.packages.reloaded" | "ta.packages.remove" | "ta.packages.removeConfirm" | "ta.packages.removeDetail" | "ta.packages.removed" | "ta.packages.scope.project" | "ta.packages.scope.user" | "ta.panel.hide" | "ta.panel.show" | "ta.presence.asked" | "ta.presence.more" | "ta.presence.owner" | "ta.presence.separator" | "ta.presence.typing" | "ta.presence.viewing" | "ta.process.done" | "ta.process.earlier" | "ta.process.failed" | "ta.process.requestFailed" | "ta.process.running" | "ta.process.showAll" | "ta.process.thinking" | "ta.process.thought" | "ta.progress.calling" | "ta.progress.compacting" | "ta.progress.input" | "ta.progress.output" | "ta.progress.retry.error" | "ta.progress.retry.network" | "ta.progress.retry.overloaded" | "ta.progress.retry.rateLimit" | "ta.progress.retrying" | "ta.progress.retryingNow" | "ta.progress.waiting" | "ta.pwa.install" | "ta.reconnecting" | "ta.relay.devices" | "ta.relay.done" | "ta.relay.hint" | "ta.relay.keepAwake" | "ta.relay.keepAwakeHint" | "ta.relay.offline" | "ta.relay.online" | "ta.relay.pair" | "ta.relay.phone" | "ta.relay.scan" | "ta.relay.title" | "ta.relay.unpair" | "ta.relay.unpairConfirm" | "ta.relays.add" | "ta.relays.addButton" | "ta.relays.addHint" | "ta.relays.addPlaceholder" | "ta.relays.broken" | "ta.relays.drive" | "ta.relays.driveHint" | "ta.relays.driveUse" | "ta.relays.feature.devices" | "ta.relays.feature.devicesHint" | "ta.relays.feature.rooms" | "ta.relays.feature.roomsHint" | "ta.relays.feature.share" | "ta.relays.feature.shareHint" | "ta.relays.feature.sync" | "ta.relays.feature.syncHint" | "ta.relays.file" | "ta.relays.folderOnly" | "ta.relays.limits" | "ta.relays.memory" | "ta.relays.official" | "ta.relays.offline" | "ta.relays.online" | "ta.relays.onlineNoTime" | "ta.relays.optional" | "ta.relays.remove" | "ta.relays.storeAdd" | "ta.relays.storeName" | "ta.relays.storeNote" | "ta.relays.storeOnly" | "ta.relays.storeOpen" | "ta.relays.storeType" | "ta.relays.title" | "ta.relays.unavailable" | "ta.remote.add" | "ta.remote.addHint" | "ta.remote.added" | "ta.remote.closePort" | "ta.remote.connect" | "ta.remote.connected" | "ta.remote.connectedTo" | "ta.remote.connecting" | "ta.remote.description" | "ta.remote.disconnect" | "ta.remote.disconnected" | "ta.remote.failed" | "ta.remote.forwarded" | "ta.remote.fromConfig" | "ta.remote.invalid" | "ta.remote.local" | "ta.remote.lost" | "ta.remote.none" | "ta.remote.noneHint" | "ta.remote.options" | "ta.remote.port" | "ta.remote.prompt.continue" | "ta.remote.prompt.title" | "ta.remote.prompt.trust" | "ta.remote.remove" | "ta.remote.step.checking" | "ta.remote.step.connecting" | "ta.remote.step.copying-server" | "ta.remote.step.installing-node" | "ta.remote.step.starting" | "ta.remote.title" | "ta.restart" | "ta.restart.button" | "ta.restart.confirm" | "ta.restart.description" | "ta.restart.detail" | "ta.restart.done" | "ta.restart.restarting" | "ta.scan" | "ta.scan.album" | "ta.scan.ask" | "ta.scan.askHint" | "ta.scan.askPlaceholder" | "ta.scan.askTitle" | "ta.scan.cameraFailed" | "ta.scan.copyFailed" | "ta.scan.error" | "ta.scan.errorPrompt" | "ta.scan.failed" | "ta.scan.flip" | "ta.scan.identify" | "ta.scan.identifyPrompt" | "ta.scan.instructions" | "ta.scan.myCode" | "ta.scan.noCode" | "ta.scan.note" | "ta.scan.notePrompt" | "ta.scan.pairMessage" | "ta.scan.pairTitle" | "ta.scan.result" | "ta.scan.retake" | "ta.scan.sameHost" | "ta.scan.translate" | "ta.scan.translatePrompt" | "ta.search.all" | "ta.search.failed" | "ta.search.loading" | "ta.search.more" | "ta.search.pages" | "ta.select.all" | "ta.select.count" | "ta.select.done" | "ta.send" | "ta.session.compact" | "ta.session.compactTitle" | "ta.session.earlier" | "ta.session.empty" | "ta.session.model" | "ta.session.noModel" | "ta.session.phase.thinking" | "ta.session.phase.working" | "ta.session.phase.writing" | "ta.session.thinking" | "ta.session.title" | "ta.session.toBottom" | "ta.session.waitingClientTool" | "ta.session.working" | "ta.setting.codemode.mode" | "ta.setting.codemode.mode.hint" | "ta.setting.codemode.mode.on" | "ta.setting.codemode.mode.only" | "ta.setting.compaction.enabled" | "ta.setting.compaction.enabled.hint" | "ta.setting.compaction.keepRecentTokens" | "ta.setting.compaction.keepRecentTokens.hint" | "ta.setting.compaction.reserveTokens" | "ta.setting.compaction.reserveTokens.hint" | "ta.setting.defaultThinkingLevel" | "ta.setting.defaultThinkingLevel.high" | "ta.setting.defaultThinkingLevel.hint" | "ta.setting.defaultThinkingLevel.low" | "ta.setting.defaultThinkingLevel.max" | "ta.setting.defaultThinkingLevel.medium" | "ta.setting.defaultThinkingLevel.minimal" | "ta.setting.defaultThinkingLevel.off" | "ta.setting.defaultThinkingLevel.xhigh" | "ta.setting.enableSkillCommands" | "ta.setting.enableSkillCommands.hint" | "ta.setting.followUpMode" | "ta.setting.followUpMode.all" | "ta.setting.followUpMode.hint" | "ta.setting.followUpMode.one-at-a-time" | "ta.setting.images.autoResize" | "ta.setting.images.autoResize.hint" | "ta.setting.images.blockImages" | "ta.setting.images.blockImages.hint" | "ta.setting.model" | "ta.setting.model.hint" | "ta.setting.retry.enabled" | "ta.setting.retry.enabled.hint" | "ta.setting.retry.maxRetries" | "ta.setting.shellCommandPrefix" | "ta.setting.shellCommandPrefix.hint" | "ta.setting.shellPath" | "ta.setting.shellPath.hint" | "ta.setting.steeringMode" | "ta.setting.steeringMode.all" | "ta.setting.steeringMode.hint" | "ta.setting.steeringMode.one-at-a-time" | "ta.setting.transport" | "ta.setting.transport.auto" | "ta.setting.transport.hint" | "ta.settings" | "ta.settings.about" | "ta.settings.accounts" | "ta.settings.accountsDescription" | "ta.settings.agent" | "ta.settings.appearance" | "ta.settings.assistant" | "ta.settings.assistantModel" | "ta.settings.assistantModelHint" | "ta.settings.chatArchive" | "ta.settings.chatArchiveHint" | "ta.settings.chatFold" | "ta.settings.chatFoldHint" | "ta.settings.chatFontSize" | "ta.settings.chatFontSizeHint" | "ta.settings.chats" | "ta.settings.confirmTasks" | "ta.settings.confirmTasksHint" | "ta.settings.cwd" | "ta.settings.cwdChange" | "ta.settings.cwdDescription" | "ta.settings.days" | "ta.settings.decides" | "ta.settings.default" | "ta.settings.displayLanguage" | "ta.settings.failed" | "ta.settings.fontSize" | "ta.settings.fontSize.large" | "ta.settings.fontSize.small" | "ta.settings.fontSize.standard" | "ta.settings.fontSize.xlarge" | "ta.settings.fontSizeHint" | "ta.settings.fromUser" | "ta.settings.group.context" | "ta.settings.group.conversation" | "ta.settings.group.model" | "ta.settings.group.tools" | "ta.settings.keepAlive" | "ta.settings.keepAliveDescription" | "ta.settings.language" | "ta.settings.language.system" | "ta.settings.links" | "ta.settings.loading" | "ta.settings.manageAccounts" | "ta.settings.maxTasks" | "ta.settings.maxTasksAny" | "ta.settings.maxTasksHint" | "ta.settings.minutes" | "ta.settings.modified" | "ta.settings.more" | "ta.settings.motion" | "ta.settings.motionHint" | "ta.settings.navigation" | "ta.settings.navigation.folded" | "ta.settings.navigation.inNav" | "ta.settings.navigation.none" | "ta.settings.navigation.overflow" | "ta.settings.navigation.pinned" | "ta.settings.navigation.reset" | "ta.settings.navigation.resetButton" | "ta.settings.navigation.resetHint" | "ta.settings.navigation.show" | "ta.settings.navigation.slots" | "ta.settings.navigation.slotsHint" | "ta.settings.never" | "ta.settings.noMatch" | "ta.settings.off" | "ta.settings.offline" | "ta.settings.on" | "ta.settings.oneYear" | "ta.settings.recentShots" | "ta.settings.recentShotsHint" | "ta.settings.relay" | "ta.settings.relayDescription" | "ta.settings.reset" | "ta.settings.retention" | "ta.settings.retentionDescription" | "ta.settings.scope.project" | "ta.settings.scope.user" | "ta.settings.scopeHint.project" | "ta.settings.scopeHint.user" | "ta.settings.search" | "ta.settings.server" | "ta.settings.shortcuts" | "ta.settings.signOut" | "ta.settings.speak" | "ta.settings.speakHint" | "ta.settings.speakTalk" | "ta.settings.speakTalkHint" | "ta.settings.taskModel" | "ta.settings.taskModelHint" | "ta.settings.theme" | "ta.settings.theme.dark" | "ta.settings.theme.light" | "ta.settings.theme.system" | "ta.settings.trustedDomains" | "ta.settings.trustedDomainsAdd" | "ta.settings.trustedDomainsEmpty" | "ta.settings.trustedDomainsEmptyHint" | "ta.settings.trustedDomainsHint" | "ta.settings.trustedDomainsRemove" | "ta.settings.untrusted" | "ta.settings.version" | "ta.settings.voice" | "ta.settings.voiceAuto" | "ta.settings.voiceAutoNone" | "ta.settings.voiceName" | "ta.settings.voiceNameHint" | "ta.settings.voicePreview" | "ta.settings.voiceSample" | "ta.settings.web" | "ta.settings.webHint" | "ta.share.cannot" | "ta.share.copied" | "ta.share.copy" | "ta.share.making" | "ta.share.published" | "ta.share.qr" | "ta.share.relayed" | "ta.share.send" | "ta.share.stop" | "ta.share.stopHint" | "ta.share.stopTitle" | "ta.share.title" | "ta.shortcut.commands" | "ta.shortcut.files" | "ta.shortcut.followUp" | "ta.shortcut.newline" | "ta.shortcut.save" | "ta.shortcut.send" | "ta.shortcut.settings" | "ta.shortcut.sidebar" | "ta.shortcut.stop" | "ta.sidebar" | "ta.sidebar.closeTitle" | "ta.signInSetup.add" | "ta.signInSetup.callback" | "ta.signInSetup.copied" | "ta.signInSetup.copy" | "ta.signInSetup.device" | "ta.signInSetup.edit" | "ta.signInSetup.field.appId" | "ta.signInSetup.field.appSecret" | "ta.signInSetup.field.clientId" | "ta.signInSetup.field.clientSecret" | "ta.signInSetup.field.issuer" | "ta.signInSetup.field.name" | "ta.signInSetup.field.url" | "ta.signInSetup.fromEnv" | "ta.signInSetup.hint" | "ta.signInSetup.incomplete" | "ta.signInSetup.off" | "ta.signInSetup.oidc" | "ta.signInSetup.on" | "ta.signInSetup.optional" | "ta.signInSetup.remove" | "ta.signInSetup.removeConfirm" | "ta.signInSetup.removeDetail" | "ta.signInSetup.removed" | "ta.signInSetup.save" | "ta.signInSetup.saved" | "ta.signInSetup.secretKept" | "ta.signInSetup.title" | "ta.signin.accountsHint" | "ta.signin.connect" | "ta.signin.denied" | "ta.signin.failed" | "ta.signin.hint" | "ta.signin.hintRemote" | "ta.signin.orToken" | "ta.signin.pairHint" | "ta.signin.pairRefused" | "ta.signin.pairing" | "ta.signin.refused" | "ta.signin.title" | "ta.signin.token" | "ta.signin.wechat" | "ta.signin.with" | "ta.species.ankylosaurus" | "ta.species.brachiosaurus" | "ta.species.dragon" | "ta.species.parasaurolophus" | "ta.species.pteranodon" | "ta.species.stegosaurus" | "ta.species.trex" | "ta.species.triceratops" | "ta.species.velociraptor" | "ta.stop" | "ta.suggest.1" | "ta.suggest.1.label" | "ta.suggest.2" | "ta.suggest.2.label" | "ta.suggest.3" | "ta.suggest.3.label" | "ta.tab.close" | "ta.tab.closeAll" | "ta.tab.closeLeft" | "ta.tab.closeOthers" | "ta.tab.closeRight" | "ta.tab.closeSaved" | "ta.tab.keepOpen" | "ta.talk.edit" | "ta.talk.hold" | "ta.talk.listening" | "ta.talk.releaseCancel" | "ta.talk.releaseEdit" | "ta.talk.releaseSend" | "ta.talk.tooShort" | "ta.task.allTasks" | "ta.task.done" | "ta.task.ended" | "ta.task.failed" | "ta.task.remove" | "ta.task.removeHint" | "ta.task.removeTitle" | "ta.task.running" | "ta.task.stopped" | "ta.task.takeOver" | "ta.task.takeOverHint" | "ta.task.takenOver" | "ta.task.waiting" | "ta.tasks.all" | "ta.tasks.ended" | "ta.tasks.fewer" | "ta.tasks.removeTitle" | "ta.tasks.running" | "ta.tasks.runningCount" | "ta.tasks.select" | "ta.tasks.waiting" | "ta.tasks.waitingCount" | "ta.terminal.openLink" | "ta.terminal.openLinkMac" | "ta.terminal.openUrl" | "ta.terminal.openUrlMac" | "ta.time.dayBefore" | "ta.time.earlier" | "ta.time.today" | "ta.time.week" | "ta.time.yesterday" | "ta.tool.earlier" | "ta.tool.exitCode" | "ta.tool.failedCalls" | "ta.tool.hideScript" | "ta.tool.moreEntries" | "ta.tool.noOutput" | "ta.tool.printed" | "ta.tool.showScript" | "ta.tool.verb.bash" | "ta.tool.verb.codemode" | "ta.tool.verb.deleteScheduled" | "ta.tool.verb.deleteTeam" | "ta.tool.verb.edit" | "ta.tool.verb.editImage" | "ta.tool.verb.fetch" | "ta.tool.verb.find" | "ta.tool.verb.getTask" | "ta.tool.verb.grep" | "ta.tool.verb.listScheduled" | "ta.tool.verb.listTasks" | "ta.tool.verb.ls" | "ta.tool.verb.messageTask" | "ta.tool.verb.publish" | "ta.tool.verb.read" | "ta.tool.verb.scheduleTask" | "ta.tool.verb.sendMessage" | "ta.tool.verb.skill" | "ta.tool.verb.startTask" | "ta.tool.verb.stopTask" | "ta.tool.verb.todo" | "ta.tool.verb.viewImage" | "ta.tool.verb.webSearch" | "ta.tool.verb.write" | "ta.unreachable" | "ta.update.later" | "ta.update.ready" | "ta.update.readyDetail" | "ta.update.restartTo" | "ta.widget.failed" | "ta.workbench" | "ta.workbench.cards" | "ta.workbench.cwd" | "ta.workbench.empty" | "ta.workbench.emptyHint" | "ta.workbench.maximize" | "ta.workbench.noCards" | "ta.workbench.noCardsHint" | "ta.workbench.open" | "ta.workbench.restore" | "ta.workbench.tabs" | "ta.workingDirectory.changed" | "ta.yes" | "ta.zoom.actual" | "ta.zoom.failed" | "ta.zoom.fit" | "ta.zoom.in" | "ta.zoom.loading" | "ta.zoom.next" | "ta.zoom.out" | "ta.zoom.previous" | undefined;
7
+ error: "ta.access.add" | "ta.access.addHint" | "ta.access.added" | "ta.access.allow" | "ta.access.bind" | "ta.access.bindHint" | "ta.access.browser" | "ta.access.dismiss" | "ta.access.fromEnv" | "ta.access.lastUsed" | "ta.access.none" | "ta.access.noneHint" | "ta.access.remove" | "ta.access.removeAccount" | "ta.access.removeConfirm" | "ta.access.removeDetail" | "ta.access.requested" | "ta.access.signOut" | "ta.access.thisBrowser" | "ta.access.title" | "ta.account" | "ta.account.menu" | "ta.account.service" | "ta.ask.no" | "ta.ask.start" | "ta.ask.title" | "ta.ask.waiting" | "ta.assistant.attention" | "ta.assistant.busy" | "ta.assistant.confirmOn" | "ta.assistant.confirmShort" | "ta.assistant.copied" | "ta.assistant.copyCwd" | "ta.assistant.cwdTitle" | "ta.assistant.endedTasks" | "ta.assistant.export" | "ta.assistant.forbidden" | "ta.assistant.hello" | "ta.assistant.look" | "ta.assistant.me" | "ta.assistant.noTasks" | "ta.assistant.noTasksHint" | "ta.assistant.nothingToExport" | "ta.assistant.offline" | "ta.assistant.placeholder" | "ta.assistant.poke" | "ta.assistant.prompt" | "ta.assistant.promptTitle" | "ta.assistant.rename" | "ta.assistant.restart" | "ta.assistant.restartHint" | "ta.assistant.restartTitle" | "ta.assistant.runningTasks" | "ta.assistant.showTasks" | "ta.assistant.speakOn" | "ta.assistant.speakStop" | "ta.assistant.speakStopShort" | "ta.assistant.speakTalkShort" | "ta.assistant.step.run" | "ta.assistant.step.say" | "ta.assistant.step.tell" | "ta.assistant.stop" | "ta.assistant.taskEnded" | "ta.assistant.tasks" | "ta.assistant.tasksTool" | "ta.assistant.waking" | "ta.assistant.working" | "ta.assistant.you" | "ta.auth.account" | "ta.auth.accounts" | "ta.auth.accountsExample" | "ta.auth.accountsTitle" | "ta.auth.apiKey" | "ta.auth.back" | "ta.auth.continue" | "ta.auth.copyAndOpen" | "ta.auth.copyCode" | "ta.auth.copyLink" | "ta.auth.custom.add" | "ta.auth.custom.addHeader" | "ta.auth.custom.addHint" | "ta.auth.custom.advanced" | "ta.auth.custom.advancedHint" | "ta.auth.custom.api" | "ta.auth.custom.apiAnthropic" | "ta.auth.custom.apiGoogle" | "ta.auth.custom.apiKey" | "ta.auth.custom.apiOpenai" | "ta.auth.custom.apiResponses" | "ta.auth.custom.badNumber" | "ta.auth.custom.baseUrl" | "ta.auth.custom.contextWindow" | "ta.auth.custom.fetch" | "ta.auth.custom.fetchFailed" | "ta.auth.custom.fetched" | "ta.auth.custom.fetchedNone" | "ta.auth.custom.filter" | "ta.auth.custom.headerName" | "ta.auth.custom.headerValue" | "ta.auth.custom.headers" | "ta.auth.custom.images" | "ta.auth.custom.keyKept" | "ta.auth.custom.keyOptional" | "ta.auth.custom.kind" | "ta.auth.custom.maxTokens" | "ta.auth.custom.mixed" | "ta.auth.custom.modelPlaceholder" | "ta.auth.custom.models" | "ta.auth.custom.name" | "ta.auth.custom.needModel" | "ta.auth.custom.note" | "ta.auth.custom.optional" | "ta.auth.custom.reasoning" | "ta.auth.custom.remove" | "ta.auth.custom.removeConfirm" | "ta.auth.custom.removeHeader" | "ta.auth.custom.removeModel" | "ta.auth.custom.save" | "ta.auth.custom.saved" | "ta.auth.custom.title" | "ta.auth.deviceHint" | "ta.auth.done" | "ta.auth.enterKey" | "ta.auth.failed" | "ta.auth.hint" | "ta.auth.hintRemote" | "ta.auth.keys" | "ta.auth.keysExample" | "ta.auth.later" | "ta.auth.manualCode" | "ta.auth.manualCodeRemote" | "ta.auth.none" | "ta.auth.openHint" | "ta.auth.openPage" | "ta.auth.search" | "ta.auth.signOut" | "ta.auth.signOutConfirm" | "ta.auth.signedIn" | "ta.auth.subscription" | "ta.auth.title" | "ta.auth.waiting" | "ta.back" | "ta.board" | "ta.board.add" | "ta.board.done" | "ta.board.edit" | "ta.board.empty" | "ta.board.emptyHint" | "ta.board.moreTasks" | "ta.board.move" | "ta.board.noTasks" | "ta.board.none" | "ta.board.noneHint" | "ta.board.put" | "ta.board.remove" | "ta.board.tasks" | "ta.builtin.assistant" | "ta.builtin.assistantHint" | "ta.cancel" | "ta.chat" | "ta.chat.archived" | "ta.chat.archivedCount" | "ta.chat.archivedHint" | "ta.chat.asking" | "ta.chat.asks" | "ta.chat.asksCount" | "ta.chat.byDirectory" | "ta.chat.cwdTitle" | "ta.chat.doubleTag" | "ta.chat.doubleTagTitle" | "ta.chat.handToDouble" | "ta.chat.hint" | "ta.chat.letGo" | "ta.chat.new" | "ta.chat.newIn" | "ta.chat.noMatch" | "ta.chat.none" | "ta.chat.noneHint" | "ta.chat.olderCount" | "ta.chat.open" | "ta.chat.opening" | "ta.chat.openingOffline" | "ta.chat.pin" | "ta.chat.pinned" | "ta.chat.remove" | "ta.chat.removeShort" | "ta.chat.removed" | "ta.chat.replyingFor" | "ta.chat.restore" | "ta.chat.restoreShort" | "ta.chat.search" | "ta.chat.suggest.1" | "ta.chat.suggest.1.label" | "ta.chat.suggest.2" | "ta.chat.suggest.2.label" | "ta.chat.suggest.3" | "ta.chat.suggest.3.label" | "ta.chat.title" | "ta.chat.toAsk" | "ta.chat.unpin" | "ta.chat.unseen" | "ta.close" | "ta.command.bug" | "ta.command.mcp" | "ta.composer.addImage" | "ta.composer.album" | "ta.composer.camera" | "ta.composer.commands" | "ta.composer.filesUnavailable" | "ta.composer.filter" | "ta.composer.image.count" | "ta.composer.image.size" | "ta.composer.image.type" | "ta.composer.imageLoading" | "ta.composer.keyboard" | "ta.composer.label" | "ta.composer.listening" | "ta.composer.mentionFile" | "ta.composer.more" | "ta.composer.noFiles" | "ta.composer.noMatch" | "ta.composer.page" | "ta.composer.placeholder" | "ta.composer.placeholderTouch" | "ta.composer.queue.count" | "ta.composer.queue.editTitle" | "ta.composer.queue.followUp" | "ta.composer.queue.remove" | "ta.composer.queue.steering" | "ta.composer.queue.takeBackAll" | "ta.composer.queue.takeBackTitle" | "ta.composer.recentShot" | "ta.composer.recentShotAdd" | "ta.composer.removeImage" | "ta.composer.steerPlaceholder" | "ta.composer.steerPlaceholderTouch" | "ta.composer.steerTitle" | "ta.composer.stopTitle" | "ta.composer.stopping" | "ta.composer.voice" | "ta.composer.voiceDenied" | "ta.composer.voiceFailed" | "ta.composer.voiceStop" | "ta.connection.away" | "ta.connection.awayBrief" | "ta.connection.back" | "ta.connection.lost" | "ta.connection.notDone" | "ta.connection.outdated" | "ta.connection.reload" | "ta.connection.retry" | "ta.connection.retryIn" | "ta.connection.retryNow" | "ta.connection.retrying" | "ta.connection.unreachableBrief" | "ta.console.about" | "ta.console.accounts" | "ta.console.active" | "ta.console.activityNone" | "ta.console.activityRunning" | "ta.console.activitySummary" | "ta.console.agentAsking" | "ta.console.agentIdle" | "ta.console.agentWaiting" | "ta.console.agentWorking" | "ta.console.agents" | "ta.console.agentsNone" | "ta.console.agentsOwn" | "ta.console.agentsPrivacy" | "ta.console.agentsStopped" | "ta.console.agentsWorking" | "ta.console.allProviders" | "ta.console.audit" | "ta.console.auditActivity" | "ta.console.auditAllow" | "ta.console.auditDefaults" | "ta.console.auditDisallow" | "ta.console.auditDismiss" | "ta.console.auditGrant" | "ta.console.auditInvite" | "ta.console.auditLimits" | "ta.console.auditLogs" | "ta.console.auditNone" | "ta.console.auditRestart" | "ta.console.auditRole" | "ta.console.auditStart" | "ta.console.auditStop" | "ta.console.auditSuspend" | "ta.console.blockedMinutes" | "ta.console.blockedSuspended" | "ta.console.bonus" | "ta.console.byAccount" | "ta.console.byModel" | "ta.console.cannotManage" | "ta.console.connectionsLabel" | "ta.console.connectionsLimit" | "ta.console.connectionsMax" | "ta.console.connectionsMaxHint" | "ta.console.context" | "ta.console.copied" | "ta.console.copy" | "ta.console.cost" | "ta.console.cpu" | "ta.console.created" | "ta.console.default" | "ta.console.defaults" | "ta.console.defaultsHint" | "ta.console.defaultsReadOnly" | "ta.console.demote" | "ta.console.demoteConfirm" | "ta.console.demoteDetail" | "ta.console.empty" | "ta.console.emptyHint" | "ta.console.environment" | "ta.console.failed" | "ta.console.filterAdmins" | "ta.console.filterAll" | "ta.console.filterLimited" | "ta.console.filterRunning" | "ta.console.filterWorking" | "ta.console.freeMinutes" | "ta.console.freeMinutesHint" | "ta.console.grant" | "ta.console.grantTitle" | "ta.console.granted" | "ta.console.hint" | "ta.console.idle" | "ta.console.idleNever" | "ta.console.invite" | "ta.console.inviteHint" | "ta.console.inviteLink" | "ta.console.invitePlaceholder" | "ta.console.inviteTitle" | "ta.console.isAdmin" | "ta.console.isMember" | "ta.console.limitDefault" | "ta.console.limitSet" | "ta.console.limitedCount" | "ta.console.limitsDone" | "ta.console.limitsEdit" | "ta.console.logs" | "ta.console.logsAudited" | "ta.console.logsEmpty" | "ta.console.logsNone" | "ta.console.logsShow" | "ta.console.managers" | "ta.console.managersHint" | "ta.console.memory" | "ta.console.messages" | "ta.console.metric" | "ta.console.modelFailed" | "ta.console.monthTokens" | "ta.console.never" | "ta.console.no" | "ta.console.noMatch" | "ta.console.outOfMinutes" | "ta.console.ownAllowed" | "ta.console.ownNot" | "ta.console.ownService" | "ta.console.ownServiceHint" | "ta.console.peak" | "ta.console.promote" | "ta.console.promoteConfirm" | "ta.console.promoteDetail" | "ta.console.promptsLimit" | "ta.console.promptsPerMinute" | "ta.console.promptsPerMinuteHint" | "ta.console.providerTenants" | "ta.console.providersAllowed" | "ta.console.providersAllowedHint" | "ta.console.quota" | "ta.console.range" | "ta.console.range1" | "ta.console.range30" | "ta.console.range7" | "ta.console.refresh" | "ta.console.requests" | "ta.console.reset" | "ta.console.resets" | "ta.console.restartConfirm" | "ta.console.restartDetail" | "ta.console.resume" | "ta.console.resumed" | "ta.console.roleAdmin" | "ta.console.roleMember" | "ta.console.roleOwner" | "ta.console.rowWaiting" | "ta.console.rowWorking" | "ta.console.running" | "ta.console.sandboxNow" | "ta.console.sandboxes" | "ta.console.save" | "ta.console.saved" | "ta.console.search" | "ta.console.sessions" | "ta.console.since" | "ta.console.someProviders" | "ta.console.sort" | "ta.console.sortActive" | "ta.console.sortMinutes" | "ta.console.sortName" | "ta.console.stale" | "ta.console.start" | "ta.console.suspend" | "ta.console.suspendConfirm" | "ta.console.suspendDetail" | "ta.console.suspended" | "ta.console.tabAccounts" | "ta.console.tabOverview" | "ta.console.tabPolicy" | "ta.console.tenantId" | "ta.console.title" | "ta.console.tokens" | "ta.console.toolCalls" | "ta.console.toolCallsLabel" | "ta.console.trend" | "ta.console.trendEmpty" | "ta.console.turns" | "ta.console.unlimited" | "ta.console.updated" | "ta.console.view" | "ta.console.yes" | "ta.copied" | "ta.copy" | "ta.discover" | "ta.discover.empty" | "ta.discover.emptyHint" | "ta.discover.hint" | "ta.dismiss" | "ta.editor" | "ta.editor.close" | "ta.editor.discardClose" | "ta.editor.failed" | "ta.editor.loading" | "ta.editor.unsavedManyTitle" | "ta.editor.unsavedMessage" | "ta.editor.unsavedTitle" | "ta.environment.blockedMinutes" | "ta.environment.blockedSuspended" | "ta.environment.blockedTitle" | "ta.environment.connect" | "ta.environment.connections" | "ta.environment.failed" | "ta.environment.failedTitle" | "ta.environment.none" | "ta.environment.own" | "ta.environment.ownDetail" | "ta.environment.ownHint" | "ta.environment.quotaHint" | "ta.environment.restart" | "ta.environment.restartConfirm" | "ta.environment.restartDetail" | "ta.environment.retry" | "ta.environment.running" | "ta.environment.sandbox" | "ta.environment.starting" | "ta.environment.stop" | "ta.environment.stopConfirm" | "ta.environment.stopDetail" | "ta.environment.stopped" | "ta.environment.switch" | "ta.environment.switchConfirm" | "ta.environment.switchDetail" | "ta.environment.title" | "ta.environment.token" | "ta.environment.url" | "ta.environment.where" | "ta.environment.whereHint" | "ta.error.alreadyCompacted" | "ta.error.forbidden" | "ta.error.forbiddenAsk" | "ta.error.forbiddenHint" | "ta.error.forbiddenNever" | "ta.error.limit" | "ta.error.messageConflict" | "ta.error.modelNotFound" | "ta.error.nothingToCompact" | "ta.error.sessionBusy" | "ta.error.sessionLocked" | "ta.error.sessionNotFound" | "ta.error.tooManySessions" | "ta.folder.empty" | "ta.folder.failed" | "ta.folder.open" | "ta.folder.path" | "ta.folder.title" | "ta.folder.up" | "ta.gait.bounce" | "ta.gait.sneak" | "ta.gait.strut" | "ta.gait.waddle" | "ta.gait.walk" | "ta.game.failed" | "ta.game.label" | "ta.game.loading" | "ta.home" | "ta.host.title" | "ta.hosts.cameraDenied" | "ta.hosts.connecting" | "ta.hosts.notPairing" | "ta.hosts.paste" | "ta.hosts.refused" | "ta.hosts.remove" | "ta.hosts.removeConfirm" | "ta.hosts.rename" | "ta.hosts.saved" | "ta.hosts.scan" | "ta.hosts.scanFailed" | "ta.hosts.scanHint" | "ta.hosts.scanInstructions" | "ta.hosts.scanShort" | "ta.hosts.switching" | "ta.hosts.thisServer" | "ta.hosts.title" | "ta.hosts.unreachable" | "ta.launch.failed" | "ta.launch.open" | "ta.launch.ready" | "ta.launcher" | "ta.launcher.back" | "ta.launcher.clear" | "ta.launcher.noResults" | "ta.launcher.place.discover" | "ta.launcher.place.launcher" | "ta.launcher.place.list" | "ta.launcher.place.navigation" | "ta.launcher.search" | "ta.launcher.searchHint" | "ta.launcher.searchPlaceholder" | "ta.layout.editor" | "ta.layout.panel" | "ta.layout.resize" | "ta.layout.sidebar" | "ta.link.ask" | "ta.link.copied" | "ta.link.external" | "ta.link.externalMac" | "ta.link.noOpener" | "ta.link.notFound" | "ta.link.open" | "ta.link.openFile" | "ta.link.openFolder" | "ta.link.trust" | "ta.link.trustHint" | "ta.look.gait" | "ta.look.premium" | "ta.look.species" | "ta.look.title" | "ta.manage.about" | "ta.manage.accounts" | "ta.manage.packages" | "ta.manage.relay" | "ta.manage.shortcuts" | "ta.manage.workingDirectory" | "ta.markdown.diagram" | "ta.markdown.download" | "ta.markdown.enlarge" | "ta.markdown.exitFullscreen" | "ta.markdown.fullscreen" | "ta.markdown.missing" | "ta.markdown.source" | "ta.me" | "ta.menu" | "ta.message.branch" | "ta.message.compacted" | "ta.message.compactedFrom" | "ta.message.debug" | "ta.message.debugCopied" | "ta.message.discard" | "ta.message.failedUnknown" | "ta.message.forkAt" | "ta.message.forkBefore" | "ta.message.forked" | "ta.message.images" | "ta.message.interrupted" | "ta.message.modelSwitched" | "ta.message.notSaved" | "ta.message.queued" | "ta.message.queuedTitle" | "ta.message.quote" | "ta.message.resend" | "ta.message.resume" | "ta.message.resumeText" | "ta.message.resumed" | "ta.message.rewind" | "ta.message.rewindConfirm" | "ta.message.rewindDetail" | "ta.message.selectText" | "ta.message.sendFailed" | "ta.message.showLess" | "ta.message.showMore" | "ta.message.silent" | "ta.message.skill" | "ta.message.steered" | "ta.message.steeredTitle" | "ta.message.stopped" | "ta.message.thinking" | "ta.message.usageTitle" | "ta.message.used" | "ta.model.default" | "ta.model.defaultNone" | "ta.model.search" | "ta.mood.attention" | "ta.mood.done" | "ta.mood.idle" | "ta.mood.listening" | "ta.mood.sleeping" | "ta.mood.speaking" | "ta.mood.thinking" | "ta.mood.working" | "ta.more" | "ta.nav.fold" | "ta.nav.open" | "ta.nav.pin" | "ta.nav.settings" | "ta.no" | "ta.notice.openLink" | "ta.notice.picture" | "ta.notices" | "ta.off" | "ta.ok" | "ta.on" | "ta.online" | "ta.open.failed" | "ta.open.notALink" | "ta.open.open" | "ta.open.published" | "ta.open.relayed" | "ta.open.title" | "ta.packages" | "ta.packages.builtin" | "ta.packages.builtinTitle" | "ta.packages.failed" | "ta.packages.hint" | "ta.packages.installed" | "ta.packages.none" | "ta.packages.noneHint" | "ta.packages.reload" | "ta.packages.reloaded" | "ta.packages.remove" | "ta.packages.removeConfirm" | "ta.packages.removeDetail" | "ta.packages.removed" | "ta.packages.scope.project" | "ta.packages.scope.user" | "ta.panel.hide" | "ta.panel.show" | "ta.presence.asked" | "ta.presence.more" | "ta.presence.owner" | "ta.presence.separator" | "ta.presence.typing" | "ta.presence.viewing" | "ta.process.done" | "ta.process.earlier" | "ta.process.failed" | "ta.process.requestFailed" | "ta.process.running" | "ta.process.showAll" | "ta.process.thinking" | "ta.process.thought" | "ta.progress.calling" | "ta.progress.compacting" | "ta.progress.input" | "ta.progress.output" | "ta.progress.retry.error" | "ta.progress.retry.network" | "ta.progress.retry.overloaded" | "ta.progress.retry.rateLimit" | "ta.progress.retrying" | "ta.progress.retryingNow" | "ta.progress.waiting" | "ta.pwa.install" | "ta.reconnecting" | "ta.relay.devices" | "ta.relay.done" | "ta.relay.hint" | "ta.relay.keepAwake" | "ta.relay.keepAwakeHint" | "ta.relay.offline" | "ta.relay.online" | "ta.relay.pair" | "ta.relay.phone" | "ta.relay.scan" | "ta.relay.title" | "ta.relay.unpair" | "ta.relay.unpairConfirm" | "ta.relays.add" | "ta.relays.addButton" | "ta.relays.addHint" | "ta.relays.addPlaceholder" | "ta.relays.broken" | "ta.relays.drive" | "ta.relays.driveHint" | "ta.relays.driveUse" | "ta.relays.feature.devices" | "ta.relays.feature.devicesHint" | "ta.relays.feature.rooms" | "ta.relays.feature.roomsHint" | "ta.relays.feature.share" | "ta.relays.feature.shareHint" | "ta.relays.feature.sync" | "ta.relays.feature.syncHint" | "ta.relays.file" | "ta.relays.folderOnly" | "ta.relays.limits" | "ta.relays.memory" | "ta.relays.official" | "ta.relays.offline" | "ta.relays.online" | "ta.relays.onlineNoTime" | "ta.relays.optional" | "ta.relays.remove" | "ta.relays.storeAdd" | "ta.relays.storeName" | "ta.relays.storeNote" | "ta.relays.storeOnly" | "ta.relays.storeOpen" | "ta.relays.storeType" | "ta.relays.title" | "ta.relays.unavailable" | "ta.remote.add" | "ta.remote.addHint" | "ta.remote.added" | "ta.remote.closePort" | "ta.remote.connect" | "ta.remote.connected" | "ta.remote.connectedTo" | "ta.remote.connecting" | "ta.remote.description" | "ta.remote.disconnect" | "ta.remote.disconnected" | "ta.remote.failed" | "ta.remote.forwarded" | "ta.remote.fromConfig" | "ta.remote.invalid" | "ta.remote.local" | "ta.remote.lost" | "ta.remote.none" | "ta.remote.noneHint" | "ta.remote.options" | "ta.remote.port" | "ta.remote.prompt.continue" | "ta.remote.prompt.title" | "ta.remote.prompt.trust" | "ta.remote.remove" | "ta.remote.step.checking" | "ta.remote.step.connecting" | "ta.remote.step.copying-server" | "ta.remote.step.installing-node" | "ta.remote.step.starting" | "ta.remote.title" | "ta.restart" | "ta.restart.button" | "ta.restart.confirm" | "ta.restart.description" | "ta.restart.detail" | "ta.restart.done" | "ta.restart.restarting" | "ta.scan" | "ta.scan.album" | "ta.scan.ask" | "ta.scan.askHint" | "ta.scan.askPlaceholder" | "ta.scan.askTitle" | "ta.scan.cameraFailed" | "ta.scan.copyFailed" | "ta.scan.error" | "ta.scan.errorPrompt" | "ta.scan.failed" | "ta.scan.flip" | "ta.scan.identify" | "ta.scan.identifyPrompt" | "ta.scan.instructions" | "ta.scan.myCode" | "ta.scan.noCode" | "ta.scan.note" | "ta.scan.notePrompt" | "ta.scan.pairMessage" | "ta.scan.pairTitle" | "ta.scan.result" | "ta.scan.retake" | "ta.scan.sameHost" | "ta.scan.translate" | "ta.scan.translatePrompt" | "ta.search.all" | "ta.search.failed" | "ta.search.loading" | "ta.search.more" | "ta.search.pages" | "ta.select.all" | "ta.select.count" | "ta.select.done" | "ta.send" | "ta.session.compact" | "ta.session.compactTitle" | "ta.session.earlier" | "ta.session.empty" | "ta.session.model" | "ta.session.noModel" | "ta.session.phase.thinking" | "ta.session.phase.working" | "ta.session.phase.writing" | "ta.session.thinking" | "ta.session.title" | "ta.session.toBottom" | "ta.session.waitingClientTool" | "ta.session.working" | "ta.setting.codemode.mode" | "ta.setting.codemode.mode.hint" | "ta.setting.codemode.mode.on" | "ta.setting.codemode.mode.only" | "ta.setting.compaction.enabled" | "ta.setting.compaction.enabled.hint" | "ta.setting.compaction.keepRecentTokens" | "ta.setting.compaction.keepRecentTokens.hint" | "ta.setting.compaction.reserveTokens" | "ta.setting.compaction.reserveTokens.hint" | "ta.setting.defaultThinkingLevel" | "ta.setting.defaultThinkingLevel.high" | "ta.setting.defaultThinkingLevel.hint" | "ta.setting.defaultThinkingLevel.low" | "ta.setting.defaultThinkingLevel.max" | "ta.setting.defaultThinkingLevel.medium" | "ta.setting.defaultThinkingLevel.minimal" | "ta.setting.defaultThinkingLevel.off" | "ta.setting.defaultThinkingLevel.xhigh" | "ta.setting.enableSkillCommands" | "ta.setting.enableSkillCommands.hint" | "ta.setting.followUpMode" | "ta.setting.followUpMode.all" | "ta.setting.followUpMode.hint" | "ta.setting.followUpMode.one-at-a-time" | "ta.setting.images.autoResize" | "ta.setting.images.autoResize.hint" | "ta.setting.images.blockImages" | "ta.setting.images.blockImages.hint" | "ta.setting.model" | "ta.setting.model.hint" | "ta.setting.retry.enabled" | "ta.setting.retry.enabled.hint" | "ta.setting.retry.maxRetries" | "ta.setting.shellCommandPrefix" | "ta.setting.shellCommandPrefix.hint" | "ta.setting.shellPath" | "ta.setting.shellPath.hint" | "ta.setting.steeringMode" | "ta.setting.steeringMode.all" | "ta.setting.steeringMode.hint" | "ta.setting.steeringMode.one-at-a-time" | "ta.setting.transport" | "ta.setting.transport.auto" | "ta.setting.transport.hint" | "ta.settings" | "ta.settings.about" | "ta.settings.accounts" | "ta.settings.accountsDescription" | "ta.settings.agent" | "ta.settings.appearance" | "ta.settings.assistant" | "ta.settings.assistantModel" | "ta.settings.assistantModelHint" | "ta.settings.chatArchive" | "ta.settings.chatArchiveHint" | "ta.settings.chatFold" | "ta.settings.chatFoldHint" | "ta.settings.chatFontSize" | "ta.settings.chatFontSizeHint" | "ta.settings.chats" | "ta.settings.confirmTasks" | "ta.settings.confirmTasksHint" | "ta.settings.cwd" | "ta.settings.cwdChange" | "ta.settings.cwdDescription" | "ta.settings.days" | "ta.settings.decides" | "ta.settings.default" | "ta.settings.displayLanguage" | "ta.settings.failed" | "ta.settings.fontSize" | "ta.settings.fontSize.large" | "ta.settings.fontSize.small" | "ta.settings.fontSize.standard" | "ta.settings.fontSize.xlarge" | "ta.settings.fontSizeHint" | "ta.settings.fromUser" | "ta.settings.group.context" | "ta.settings.group.conversation" | "ta.settings.group.model" | "ta.settings.group.tools" | "ta.settings.keepAlive" | "ta.settings.keepAliveDescription" | "ta.settings.language" | "ta.settings.language.system" | "ta.settings.links" | "ta.settings.loading" | "ta.settings.manageAccounts" | "ta.settings.maxTasks" | "ta.settings.maxTasksAny" | "ta.settings.maxTasksHint" | "ta.settings.minutes" | "ta.settings.modified" | "ta.settings.more" | "ta.settings.motion" | "ta.settings.motionHint" | "ta.settings.navigation" | "ta.settings.navigation.folded" | "ta.settings.navigation.inNav" | "ta.settings.navigation.none" | "ta.settings.navigation.overflow" | "ta.settings.navigation.pinned" | "ta.settings.navigation.reset" | "ta.settings.navigation.resetButton" | "ta.settings.navigation.resetHint" | "ta.settings.navigation.show" | "ta.settings.navigation.slots" | "ta.settings.navigation.slotsHint" | "ta.settings.never" | "ta.settings.noMatch" | "ta.settings.off" | "ta.settings.offline" | "ta.settings.on" | "ta.settings.oneYear" | "ta.settings.recentShots" | "ta.settings.recentShotsHint" | "ta.settings.relay" | "ta.settings.relayDescription" | "ta.settings.reset" | "ta.settings.retention" | "ta.settings.retentionDescription" | "ta.settings.scope.project" | "ta.settings.scope.user" | "ta.settings.scopeHint.project" | "ta.settings.scopeHint.user" | "ta.settings.search" | "ta.settings.server" | "ta.settings.shortcuts" | "ta.settings.signOut" | "ta.settings.speak" | "ta.settings.speakHint" | "ta.settings.speakTalk" | "ta.settings.speakTalkHint" | "ta.settings.taskModel" | "ta.settings.taskModelHint" | "ta.settings.theme" | "ta.settings.theme.dark" | "ta.settings.theme.light" | "ta.settings.theme.system" | "ta.settings.trustedDomains" | "ta.settings.trustedDomainsAdd" | "ta.settings.trustedDomainsEmpty" | "ta.settings.trustedDomainsEmptyHint" | "ta.settings.trustedDomainsHint" | "ta.settings.trustedDomainsRemove" | "ta.settings.untrusted" | "ta.settings.version" | "ta.settings.voice" | "ta.settings.voiceAuto" | "ta.settings.voiceAutoNone" | "ta.settings.voiceName" | "ta.settings.voiceNameHint" | "ta.settings.voicePreview" | "ta.settings.voiceSample" | "ta.settings.web" | "ta.settings.webHint" | "ta.share.cannot" | "ta.share.copied" | "ta.share.copy" | "ta.share.making" | "ta.share.published" | "ta.share.qr" | "ta.share.relayed" | "ta.share.send" | "ta.share.stop" | "ta.share.stopHint" | "ta.share.stopTitle" | "ta.share.title" | "ta.shortcut.commands" | "ta.shortcut.files" | "ta.shortcut.followUp" | "ta.shortcut.newline" | "ta.shortcut.save" | "ta.shortcut.send" | "ta.shortcut.settings" | "ta.shortcut.sidebar" | "ta.shortcut.stop" | "ta.sidebar" | "ta.sidebar.closeTitle" | "ta.signInSetup.add" | "ta.signInSetup.callback" | "ta.signInSetup.copied" | "ta.signInSetup.copy" | "ta.signInSetup.device" | "ta.signInSetup.edit" | "ta.signInSetup.field.appId" | "ta.signInSetup.field.appSecret" | "ta.signInSetup.field.clientId" | "ta.signInSetup.field.clientSecret" | "ta.signInSetup.field.issuer" | "ta.signInSetup.field.name" | "ta.signInSetup.field.url" | "ta.signInSetup.fromEnv" | "ta.signInSetup.hint" | "ta.signInSetup.incomplete" | "ta.signInSetup.off" | "ta.signInSetup.oidc" | "ta.signInSetup.on" | "ta.signInSetup.optional" | "ta.signInSetup.remove" | "ta.signInSetup.removeConfirm" | "ta.signInSetup.removeDetail" | "ta.signInSetup.removed" | "ta.signInSetup.save" | "ta.signInSetup.saved" | "ta.signInSetup.secretKept" | "ta.signInSetup.title" | "ta.signin.accountsHint" | "ta.signin.connect" | "ta.signin.denied" | "ta.signin.failed" | "ta.signin.hint" | "ta.signin.hintRemote" | "ta.signin.orToken" | "ta.signin.pairHint" | "ta.signin.pairRefused" | "ta.signin.pairing" | "ta.signin.refused" | "ta.signin.title" | "ta.signin.token" | "ta.signin.wechat" | "ta.signin.with" | "ta.species.ankylosaurus" | "ta.species.brachiosaurus" | "ta.species.dragon" | "ta.species.parasaurolophus" | "ta.species.pteranodon" | "ta.species.stegosaurus" | "ta.species.trex" | "ta.species.triceratops" | "ta.species.velociraptor" | "ta.stop" | "ta.suggest.1" | "ta.suggest.1.label" | "ta.suggest.2" | "ta.suggest.2.label" | "ta.suggest.3" | "ta.suggest.3.label" | "ta.tab.close" | "ta.tab.closeAll" | "ta.tab.closeLeft" | "ta.tab.closeOthers" | "ta.tab.closeRight" | "ta.tab.closeSaved" | "ta.tab.keepOpen" | "ta.talk.edit" | "ta.talk.hold" | "ta.talk.listening" | "ta.talk.releaseCancel" | "ta.talk.releaseEdit" | "ta.talk.releaseSend" | "ta.talk.tooShort" | "ta.task.allTasks" | "ta.task.done" | "ta.task.ended" | "ta.task.failed" | "ta.task.remove" | "ta.task.removeHint" | "ta.task.removeTitle" | "ta.task.running" | "ta.task.stopped" | "ta.task.takeOver" | "ta.task.takeOverHint" | "ta.task.takenOver" | "ta.task.waiting" | "ta.tasks.all" | "ta.tasks.ended" | "ta.tasks.fewer" | "ta.tasks.removeTitle" | "ta.tasks.running" | "ta.tasks.runningCount" | "ta.tasks.select" | "ta.tasks.waiting" | "ta.tasks.waitingCount" | "ta.terminal.openLink" | "ta.terminal.openLinkMac" | "ta.terminal.openUrl" | "ta.terminal.openUrlMac" | "ta.time.dayBefore" | "ta.time.earlier" | "ta.time.today" | "ta.time.week" | "ta.time.yesterday" | "ta.tool.earlier" | "ta.tool.exitCode" | "ta.tool.failedCalls" | "ta.tool.hideScript" | "ta.tool.moreEntries" | "ta.tool.noOutput" | "ta.tool.printed" | "ta.tool.showScript" | "ta.tool.verb.bash" | "ta.tool.verb.codemode" | "ta.tool.verb.deleteScheduled" | "ta.tool.verb.deleteTeam" | "ta.tool.verb.edit" | "ta.tool.verb.editImage" | "ta.tool.verb.fetch" | "ta.tool.verb.find" | "ta.tool.verb.getTask" | "ta.tool.verb.grep" | "ta.tool.verb.listScheduled" | "ta.tool.verb.listTasks" | "ta.tool.verb.ls" | "ta.tool.verb.messageTask" | "ta.tool.verb.publish" | "ta.tool.verb.read" | "ta.tool.verb.scheduleTask" | "ta.tool.verb.sendMessage" | "ta.tool.verb.skill" | "ta.tool.verb.startTask" | "ta.tool.verb.stopTask" | "ta.tool.verb.todo" | "ta.tool.verb.viewImage" | "ta.tool.verb.webSearch" | "ta.tool.verb.write" | "ta.unreachable" | "ta.update.later" | "ta.update.ready" | "ta.update.readyDetail" | "ta.update.restartTo" | "ta.widget.failed" | "ta.workbench" | "ta.workbench.cards" | "ta.workbench.cwd" | "ta.workbench.empty" | "ta.workbench.emptyHint" | "ta.workbench.maximize" | "ta.workbench.noCards" | "ta.workbench.noCardsHint" | "ta.workbench.open" | "ta.workbench.restore" | "ta.workbench.tabs" | "ta.workingDirectory.changed" | "ta.yes" | "ta.zoom.actual" | "ta.zoom.failed" | "ta.zoom.fit" | "ta.zoom.in" | "ta.zoom.loading" | "ta.zoom.next" | "ta.zoom.out" | "ta.zoom.previous" | undefined;
8
8
  add: (text: string, scanned?: boolean) => Promise<void>;
9
9
  scan: () => Promise<void>;
10
10
  canScan: boolean;
@@ -276,7 +276,10 @@ function useParts(scope, onScope, onClose, onDialog) {
276
276
  title: t('ta.packages.builtinTitle'),
277
277
  icon: lucide_react_1.Blocks,
278
278
  rows: [
279
- ...host.builtins.map(builtin => { var _a; return (0, settings_controls_1.row)(`web:${builtin.name}`, [t(builtin.title), t(builtin.description), t('ta.packages.builtinTitle')], React.createElement(settings_controls_1.Row, { icon: (_a = builtin.icon) !== null && _a !== void 0 ? _a : lucide_react_1.Puzzle, label: t(builtin.title), description: t(builtin.description) },
279
+ // The console only for administrators of a gateway, where it shows.
280
+ ...host.builtins
281
+ .filter(builtin => { var _a; return !builtin.gatewayAdmin || ((_a = gateway.info) === null || _a === void 0 ? void 0 : _a.admin); })
282
+ .map(builtin => { var _a; return (0, settings_controls_1.row)(`web:${builtin.name}`, [t(builtin.title), t(builtin.description), t('ta.packages.builtinTitle')], React.createElement(settings_controls_1.Row, { icon: (_a = builtin.icon) !== null && _a !== void 0 ? _a : lucide_react_1.Puzzle, label: t(builtin.title), description: t(builtin.description) },
280
283
  React.createElement(settings_controls_1.Switch, { label: t(builtin.title), checked: !settings.builtinsOff.includes(builtin.name), onChange: on => toggleBuiltin(builtin.name, on) }))); }),
281
284
  ...builtinPackages.map(info => {
282
285
  const { title, summary, icon } = (0, settings_choices_1.packageLabel)(info, language);
@@ -15,6 +15,8 @@ export interface BuiltinWebExtension {
15
15
  readonly description: MessageId;
16
16
  /** Shown before its title in the settings. */
17
17
  readonly icon?: WebIcon;
18
+ /** Only for administrators of a gateway (`ta gateway`): listed in the settings there alone. */
19
+ readonly gatewayAdmin?: boolean;
18
20
  readonly activate: WebExtensionFactory;
19
21
  }
20
22
  export interface LoadedWebExtension {
@@ -271,5 +273,9 @@ export interface TaWebExtensions {
271
273
  setSessionSwitcher(switcher: WebSessionSwitcher | undefined): void;
272
274
  /** How the page shows a session as the conversation, once it said (setSessionSwitcher). */
273
275
  sessionSwitcher(): WebSessionSwitcher | undefined;
276
+ /** What `openSettings` does: the shell opens the settings at a section; `undefined` until it can. */
277
+ setSettingsOpener(opener: ((section?: string) => void) | undefined): void;
278
+ /** The settings, at a section (`access`) of them, from a page of the page's own (the console). */
279
+ openSettings(section?: string): void;
274
280
  }
275
281
  //# sourceMappingURL=web-extension-protocol.d.ts.map
@@ -39,6 +39,7 @@ export declare class TaWebExtensionsImpl implements TaWebExtensions {
39
39
  protected readonly listeners: Set<(state: WebExtensionsState) => void>;
40
40
  protected conversation?: WebExtensionConversation;
41
41
  protected switcher?: WebSessionSwitcher;
42
+ protected settingsOpener?: (section?: string) => void;
42
43
  protected refreshing: Promise<boolean>;
43
44
  /** The extensions of the list of the last time have started (startKept), once. */
44
45
  protected keptStarted: boolean;
@@ -92,6 +93,8 @@ export declare class TaWebExtensionsImpl implements TaWebExtensions {
92
93
  connect(conversation: WebExtensionConversation | undefined): void;
93
94
  setConversationShown(shown: boolean): void;
94
95
  setSessionSwitcher(switcher: WebSessionSwitcher | undefined): void;
96
+ setSettingsOpener(opener: ((section?: string) => void) | undefined): void;
97
+ openSettings(section?: string): void;
95
98
  sessionSwitcher(): WebSessionSwitcher | undefined;
96
99
  emit(event: TaEvent): void;
97
100
  protected reconcile(): Promise<boolean>;
@@ -287,6 +287,13 @@ let TaWebExtensionsImpl = class TaWebExtensionsImpl {
287
287
  setSessionSwitcher(switcher) {
288
288
  this.switcher = switcher;
289
289
  }
290
+ setSettingsOpener(opener) {
291
+ this.settingsOpener = opener;
292
+ }
293
+ openSettings(section) {
294
+ var _a;
295
+ (_a = this.settingsOpener) === null || _a === void 0 ? void 0 : _a.call(this, section);
296
+ }
290
297
  sessionSwitcher() {
291
298
  return this.switcher;
292
299
  }
@@ -0,0 +1,21 @@
1
+ import type { WebExtensionAPI } from '../extension/web-extension-api';
2
+ import { BuiltinWebExtension } from '../extension/web-extension-protocol';
3
+ import { TaWorkbench } from '../workbench-protocol';
4
+ export declare const CONSOLE_EXTENSION = "gateway";
5
+ export declare const CONSOLE_VIEW = "console";
6
+ /** The page of the console, as `openView` takes it. */
7
+ export declare const CONSOLE_VIEW_ID = "gateway/console";
8
+ /**
9
+ * The console of a gateway (`ta gateway`), as a built-in web extension: a page for its administrators alone,
10
+ * of everyone's Ta on it. Behind no gateway, or for anyone else, it adds nothing.
11
+ */
12
+ export declare class ConsoleWebExtension implements BuiltinWebExtension {
13
+ readonly name = "gateway";
14
+ readonly title = "ta.console.title";
15
+ readonly description = "ta.console.hint";
16
+ readonly icon: import("lucide-react").LucideIcon;
17
+ readonly gatewayAdmin = true;
18
+ protected readonly workbench: TaWorkbench;
19
+ readonly activate: (pi: WebExtensionAPI) => () => void;
20
+ }
21
+ //# sourceMappingURL=console-extension.d.ts.map
@@ -0,0 +1,111 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
14
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
15
+ }) : function(o, v) {
16
+ o["default"] = v;
17
+ });
18
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
19
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
20
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
21
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
22
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
23
+ };
24
+ var __importStar = (this && this.__importStar) || (function () {
25
+ var ownKeys = function(o) {
26
+ ownKeys = Object.getOwnPropertyNames || function (o) {
27
+ var ar = [];
28
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
29
+ return ar;
30
+ };
31
+ return ownKeys(o);
32
+ };
33
+ return function (mod) {
34
+ if (mod && mod.__esModule) return mod;
35
+ var result = {};
36
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
37
+ __setModuleDefault(result, mod);
38
+ return result;
39
+ };
40
+ })();
41
+ var __metadata = (this && this.__metadata) || function (k, v) {
42
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
43
+ };
44
+ Object.defineProperty(exports, "__esModule", { value: true });
45
+ exports.ConsoleWebExtension = exports.CONSOLE_VIEW_ID = exports.CONSOLE_VIEW = exports.CONSOLE_EXTENSION = void 0;
46
+ const core_1 = require("@celljs/core");
47
+ const lucide_react_1 = require("lucide-react");
48
+ const React = __importStar(require("react"));
49
+ const web_extension_protocol_1 = require("../extension/web-extension-protocol");
50
+ const messages_1 = require("../i18n/messages");
51
+ const workbench_protocol_1 = require("../workbench-protocol");
52
+ const console_view_1 = require("./console-view");
53
+ exports.CONSOLE_EXTENSION = 'gateway';
54
+ exports.CONSOLE_VIEW = 'console';
55
+ /** The page of the console, as `openView` takes it. */
56
+ exports.CONSOLE_VIEW_ID = `${exports.CONSOLE_EXTENSION}/${exports.CONSOLE_VIEW}`;
57
+ /**
58
+ * The console of a gateway (`ta gateway`), as a built-in web extension: a page for its administrators alone,
59
+ * of everyone's Ta on it. Behind no gateway, or for anyone else, it adds nothing.
60
+ */
61
+ let ConsoleWebExtension = class ConsoleWebExtension {
62
+ constructor() {
63
+ this.name = exports.CONSOLE_EXTENSION;
64
+ this.title = 'ta.console.title';
65
+ this.description = 'ta.console.hint';
66
+ this.icon = lucide_react_1.Gauge;
67
+ this.gatewayAdmin = true;
68
+ this.activate = (pi) => {
69
+ let registered = false;
70
+ let asking = false;
71
+ let online = false;
72
+ const check = () => {
73
+ const now = this.workbench.state.status === 'online';
74
+ // Asked again on each connection: the gateway, or the account, may be another since.
75
+ if (now && !online && !registered && !asking) {
76
+ asking = true;
77
+ this.workbench.gateway.getGateway().then(info => {
78
+ asking = false;
79
+ if (info.admin && !registered) {
80
+ registered = true;
81
+ pi.registerView(exports.CONSOLE_VIEW, {
82
+ title: () => (0, messages_1.message)(pi.ui.language, 'ta.console.title'),
83
+ icon: lucide_react_1.Gauge,
84
+ render: () => React.createElement(console_view_1.ConsolePage),
85
+ order: 90,
86
+ discover: true,
87
+ });
88
+ }
89
+ },
90
+ // A Ta service without a gateway has no TaGatewayServer.
91
+ () => {
92
+ asking = false;
93
+ });
94
+ }
95
+ online = now;
96
+ };
97
+ const stop = this.workbench.subscribe(check);
98
+ check();
99
+ return stop;
100
+ };
101
+ }
102
+ };
103
+ exports.ConsoleWebExtension = ConsoleWebExtension;
104
+ __decorate([
105
+ (0, core_1.Autowired)(workbench_protocol_1.TaWorkbench),
106
+ __metadata("design:type", Object)
107
+ ], ConsoleWebExtension.prototype, "workbench", void 0);
108
+ exports.ConsoleWebExtension = ConsoleWebExtension = __decorate([
109
+ (0, core_1.Component)(web_extension_protocol_1.BuiltinWebExtension)
110
+ ], ConsoleWebExtension);
111
+ //# sourceMappingURL=console-extension.js.map