@agentdeck/shared 0.2.0 → 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (113) hide show
  1. package/dist/adapter.d.ts +3 -1
  2. package/dist/adapter.d.ts.map +1 -1
  3. package/dist/adapter.js +24 -0
  4. package/dist/adapter.js.map +1 -1
  5. package/dist/command-builders.d.ts +8 -2
  6. package/dist/command-builders.d.ts.map +1 -1
  7. package/dist/command-builders.js +20 -2
  8. package/dist/command-builders.js.map +1 -1
  9. package/dist/connection-status.d.ts +42 -0
  10. package/dist/connection-status.d.ts.map +1 -0
  11. package/dist/connection-status.js +52 -0
  12. package/dist/connection-status.js.map +1 -0
  13. package/dist/creature-layout.d.ts +18 -0
  14. package/dist/creature-layout.d.ts.map +1 -0
  15. package/dist/creature-layout.js +131 -0
  16. package/dist/creature-layout.js.map +1 -0
  17. package/dist/d200h-layout.d.ts +146 -0
  18. package/dist/d200h-layout.d.ts.map +1 -0
  19. package/dist/d200h-layout.js +808 -0
  20. package/dist/d200h-layout.js.map +1 -0
  21. package/dist/design-tokens.d.ts +261 -0
  22. package/dist/design-tokens.d.ts.map +1 -0
  23. package/dist/design-tokens.js +157 -0
  24. package/dist/design-tokens.js.map +1 -0
  25. package/dist/eval-schema.d.ts +32 -2
  26. package/dist/eval-schema.d.ts.map +1 -1
  27. package/dist/eval-schema.js.map +1 -1
  28. package/dist/format-utils.d.ts +38 -0
  29. package/dist/format-utils.d.ts.map +1 -1
  30. package/dist/format-utils.js +70 -0
  31. package/dist/format-utils.js.map +1 -1
  32. package/dist/gateway-protocol.d.ts +1 -1
  33. package/dist/gateway-protocol.js +1 -1
  34. package/dist/index.d.ts +11 -0
  35. package/dist/index.d.ts.map +1 -1
  36. package/dist/index.js +11 -0
  37. package/dist/index.js.map +1 -1
  38. package/dist/llm-settings.d.ts +3 -3
  39. package/dist/llm-settings.d.ts.map +1 -1
  40. package/dist/llm-settings.js +3 -3
  41. package/dist/llm-settings.js.map +1 -1
  42. package/dist/net-utils.d.ts +2 -1
  43. package/dist/net-utils.d.ts.map +1 -1
  44. package/dist/net-utils.js +100 -3
  45. package/dist/net-utils.js.map +1 -1
  46. package/dist/pricing.d.ts +45 -0
  47. package/dist/pricing.d.ts.map +1 -0
  48. package/dist/pricing.js +93 -0
  49. package/dist/pricing.js.map +1 -0
  50. package/dist/protocol.d.ts +220 -5
  51. package/dist/protocol.d.ts.map +1 -1
  52. package/dist/protocol.js +11 -1
  53. package/dist/protocol.js.map +1 -1
  54. package/dist/sample.d.ts +152 -0
  55. package/dist/sample.d.ts.map +1 -0
  56. package/dist/sample.js +22 -0
  57. package/dist/sample.js.map +1 -0
  58. package/dist/session-utils.d.ts +82 -2
  59. package/dist/session-utils.d.ts.map +1 -1
  60. package/dist/session-utils.js +205 -10
  61. package/dist/session-utils.js.map +1 -1
  62. package/dist/state-colors.d.ts.map +1 -1
  63. package/dist/state-colors.js +2 -0
  64. package/dist/state-colors.js.map +1 -1
  65. package/dist/states.d.ts +1 -0
  66. package/dist/states.d.ts.map +1 -1
  67. package/dist/states.js +6 -1
  68. package/dist/states.js.map +1 -1
  69. package/dist/svg-renderers/agent-logos.d.ts +20 -12
  70. package/dist/svg-renderers/agent-logos.d.ts.map +1 -1
  71. package/dist/svg-renderers/agent-logos.js +154 -46
  72. package/dist/svg-renderers/agent-logos.js.map +1 -1
  73. package/dist/svg-renderers/session-slot-renderer.d.ts +71 -6
  74. package/dist/svg-renderers/session-slot-renderer.d.ts.map +1 -1
  75. package/dist/svg-renderers/session-slot-renderer.js +429 -209
  76. package/dist/svg-renderers/session-slot-renderer.js.map +1 -1
  77. package/dist/svg-renderers/text-utils.d.ts +14 -0
  78. package/dist/svg-renderers/text-utils.d.ts.map +1 -1
  79. package/dist/svg-renderers/text-utils.js +34 -0
  80. package/dist/svg-renderers/text-utils.js.map +1 -1
  81. package/dist/telemetry-envelope.d.ts +1 -1
  82. package/dist/telemetry-envelope.d.ts.map +1 -1
  83. package/dist/terrarium-rules.d.ts +46 -0
  84. package/dist/terrarium-rules.d.ts.map +1 -0
  85. package/dist/terrarium-rules.js +63 -0
  86. package/dist/terrarium-rules.js.map +1 -0
  87. package/dist/timeline-icons.d.ts +80 -0
  88. package/dist/timeline-icons.d.ts.map +1 -0
  89. package/dist/timeline-icons.js +174 -0
  90. package/dist/timeline-icons.js.map +1 -0
  91. package/dist/timeline-label.d.ts +38 -0
  92. package/dist/timeline-label.d.ts.map +1 -0
  93. package/dist/timeline-label.js +95 -0
  94. package/dist/timeline-label.js.map +1 -0
  95. package/dist/timeline-markdown.d.ts +80 -0
  96. package/dist/timeline-markdown.d.ts.map +1 -0
  97. package/dist/timeline-markdown.js +221 -0
  98. package/dist/timeline-markdown.js.map +1 -0
  99. package/dist/timeline-summarizer.d.ts +24 -0
  100. package/dist/timeline-summarizer.d.ts.map +1 -1
  101. package/dist/timeline-summarizer.js +55 -13
  102. package/dist/timeline-summarizer.js.map +1 -1
  103. package/dist/timeline-task-display.d.ts +66 -0
  104. package/dist/timeline-task-display.d.ts.map +1 -0
  105. package/dist/timeline-task-display.js +94 -0
  106. package/dist/timeline-task-display.js.map +1 -0
  107. package/dist/timeline.d.ts +101 -2
  108. package/dist/timeline.d.ts.map +1 -1
  109. package/dist/timeline.js +249 -11
  110. package/dist/timeline.js.map +1 -1
  111. package/dist/trmnl-layout.d.ts.map +1 -0
  112. package/dist/trmnl-layout.js.map +1 -0
  113. package/package.json +2 -1
@@ -1,21 +1,25 @@
1
1
  /**
2
- * Agent logo SVG paths for icon and watermark rendering on session buttons.
2
+ * Agent creature SVG fragments for session buttons.
3
3
  *
4
- * Each logo is a centered path designed for a 144x144 button canvas.
5
- * Two rendering modes:
6
- * agentLogoIcon() — prominent icon at top of button (primary identification)
7
- * agentLogoWatermark() — low-opacity background mark
4
+ * The exported names are kept for plugin compatibility, but the rendered
5
+ * marks are the same AgentDeck creature language used by the terrarium:
6
+ * Claude = robot, Codex = cloud prompt, OpenClaw = crayfish, OpenCode =
7
+ * nested-square floater, Antigravity = peak/arc mark.
8
8
  */
9
9
  import { dimColor, agentBrandColor } from '../state-colors.js';
10
- /** Claude Code creature asset: assets/logos/claude.svg. viewBox 0 0 24 24. */
11
- export const CLAUDE_LOGO_PATH = 'M4.709 15.955l4.72-2.647.08-.23-.08-.128H9.2l-.79-.048-2.698-.073-2.339-.097-2.266-.122-.571-.121L0 11.784l.055-.352.48-.321.686.06 1.52.103 2.278.158 1.652.097 2.449.255h.389l.055-.157-.134-.098-.103-.097-2.358-1.596-2.552-1.688-1.336-.972-.724-.491-.364-.462-.158-1.008.656-.722.881.06.225.061.893.686 1.908 1.476 2.491 1.833.365.304.145-.103.019-.073-.164-.274-1.355-2.446-1.446-2.49-.644-1.032-.17-.619a2.97 2.97 0 01-.104-.729L6.283.134 6.696 0l.996.134.42.364.62 1.414 1.002 2.229 1.555 3.03.456.898.243.832.091.255h.158V9.01l.128-1.706.237-2.095.23-2.695.08-.76.376-.91.747-.492.584.28.48.685-.067.444-.286 1.851-.559 2.903-.364 1.942h.212l.243-.242.985-1.306 1.652-2.064.73-.82.85-.904.547-.431h1.033l.76 1.129-.34 1.166-1.064 1.347-.881 1.142-1.264 1.7-.79 1.36.073.11.188-.02 2.856-.606 1.543-.28 1.841-.315.833.388.091.395-.328.807-1.969.486-2.309.462-3.439.813-.042.03.049.061 1.549.146.662.036h1.622l3.02.225.79.522.474.638-.079.485-1.215.62-1.64-.389-3.829-.91-1.312-.329h-.182v.11l1.093 1.068 2.006 1.81 2.509 2.33.127.578-.322.455-.34-.049-2.205-1.657-.851-.747-1.926-1.62h-.128v.17l.444.649 2.345 3.521.122 1.08-.17.353-.608.213-.668-.122-1.374-1.925-1.415-2.167-1.143-1.943-.14.08-.674 7.254-.316.37-.729.28-.607-.461-.322-.747.322-1.476.389-1.924.315-1.53.286-1.9.17-.632-.012-.042-.14.018-1.434 1.967-2.18 2.945-1.726 1.845-.414.164-.717-.37.067-.662.401-.589 2.388-3.036 1.44-1.882.93-1.086-.006-.158h-.055L4.132 18.56l-1.13.146-.487-.456.061-.746.231-.243 1.908-1.312-.006.006z';
12
- /** Legacy OpenClaw paths kept for the Gateway preset mini-browser icon. */
13
- export const OC_BODY = 'M60 10 C30 10 15 35 15 55 C15 75 30 95 45 100 L45 110 L55 110 L55 100 C55 100 60 102 65 100 L65 110 L75 110 L75 100 C90 95 105 75 105 55 C105 35 90 10 60 10Z';
14
- export const OC_CLAW_L = 'M20 45 C5 40 0 50 5 60 C10 70 20 65 25 55 C28 48 25 45 20 45Z';
15
- export const OC_CLAW_R = 'M100 45 C115 40 120 50 115 60 C110 70 100 65 95 55 C92 48 95 45 100 45Z';
10
+ // Claude Code creature = the rusty robot (design/brand/claudecode.svg): blocky
11
+ // head with two eye holes. Exported so 1-bit surfaces (TRMNL e-ink) render the
12
+ // canonical mark rather than a drifted approximation.
13
+ export const ROBOT_CREATURE_PATH = 'M20.998 10.949H24v3.102h-3v3.028h-1.487V20H18v-2.921h-1.487V20H15v-2.921H9V20H7.488v-2.921H6V20H4.487v-2.921H3V14.05H0V10.95h3V5h17.998v5.949zM6 10.949h1.488V8.102H6v2.847zm10.51 0H18V8.102h-1.49v2.847z';
14
+ /** OpenCode mark (design/brand/opencode.svg): hollow nested-square ring. */
15
+ export const OPENCODE_RING_PATH = 'M16 6H8v12h8V6zm4 16H4V2h16v20z';
16
+ /** Antigravity mark (design/brand/antigravity.svg): peak/arc. */
17
+ export const ANTIGRAVITY_PATH = 'M21.751 22.607c1.34 1.005 3.35.335 1.508-1.508C17.73 15.74 18.904 1 12.037 1 5.17 1 6.342 15.74.815 21.1c-2.01 2.009.167 2.511 1.507 1.506 5.192-3.517 4.857-9.714 9.715-9.714 4.857 0 4.522 6.197 9.714 9.715z';
18
+ /** Claude Code mark (design/brand/claudecode.svg). Compatibility alias. */
19
+ export const CLAUDE_LOGO_PATH = ROBOT_CREATURE_PATH;
16
20
  /** Codex CLI knot/clover — official SVG from codex brand assets. viewBox 0 0 24 24. */
17
21
  export const CODEX_LOGO_PATH = 'M8.086.457a6.105 6.105 0 013.046-.415c1.333.153 2.521.72 3.564 1.7a.117.117 0 00.107.029c1.408-.346 2.762-.224 4.061.366l.063.03.154.076c1.357.703 2.33 1.77 2.918 3.198.278.679.418 1.388.421 2.126a5.655 5.655 0 01-.18 1.631.167.167 0 00.04.155 5.982 5.982 0 011.578 2.891c.385 1.901-.01 3.615-1.183 5.14l-.182.22a6.063 6.063 0 01-2.934 1.851.162.162 0 00-.108.102c-.255.736-.511 1.364-.987 1.992-1.199 1.582-2.962 2.462-4.948 2.451-1.583-.008-2.986-.587-4.21-1.736a.145.145 0 00-.14-.032c-.518.167-1.04.191-1.604.185a5.924 5.924 0 01-2.595-.622 6.058 6.058 0 01-2.146-1.781c-.203-.269-.404-.522-.551-.821a7.74 7.74 0 01-.495-1.283 6.11 6.11 0 01-.017-3.064.166.166 0 00.008-.074.115.115 0 00-.037-.064 5.958 5.958 0 01-1.38-2.202 5.196 5.196 0 01-.333-1.589 6.915 6.915 0 01.188-2.132c.45-1.484 1.309-2.648 2.577-3.493.282-.188.55-.334.802-.438.286-.12.573-.22.861-.304a.129.129 0 00.087-.087A6.016 6.016 0 015.635 2.31C6.315 1.464 7.132.846 8.086.457zm-.804 7.85a.848.848 0 00-1.473.842l1.694 2.965-1.688 2.848a.849.849 0 001.46.864l1.94-3.272a.849.849 0 00.007-.854l-1.94-3.393zm5.446 6.24a.849.849 0 000 1.695h4.848a.849.849 0 000-1.696h-4.848z';
18
- /** OpenClaw creature asset: assets/logos/openclaw.svg. viewBox 0 0 24 24. */
22
+ /** OpenClaw mark (design/brand/openclaw.svg). viewBox 0 0 24 24. */
19
23
  export const OPENCLAW_LOGO_PATHS = [
20
24
  'M9.046 7.104a.527.527 0 110 1.055.527.527 0 010-1.055z',
21
25
  'M15.376 7.104a.528.528 0 110 1.056.528.528 0 010-1.056z',
@@ -23,18 +27,137 @@ export const OPENCLAW_LOGO_PATHS = [
23
27
  'M.395 13.118c-.966-1.932-.163-3.863 2.41-3.365v-.001l.05.01c.084.018.17.038.26.06.033.009.067.017.1.027.084.022.168.048.255.076l.09.027c.528 0 .95.158 1.16.501.212.343.212.87-.105 1.61-.085.17-.178.333-.276.489l-.01.017a4.967 4.967 0 01-.62.791l-.019.02c-1.092 1.117-2.496 1.336-3.295-.262z',
24
28
  'M21.193 9.753c2.574-.5 3.378 1.433 2.411 3.365-.58 1.159-1.476 1.361-2.342.96l-.011-.005a2.419 2.419 0 01-.114-.056l-.019-.01a2.751 2.751 0 01-.115-.067l-.023-.014c-.035-.022-.071-.044-.106-.068l-.05-.035c-.55-.388-1.062-1.007-1.44-1.76-.276-.647-.311-1.132-.174-1.472.176-.439.636-.639 1.23-.639.032-.011.066-.02.099-.03.08-.026.16-.05.238-.072l.117-.03a5.502 5.502 0 01.3-.067z',
25
29
  ];
30
+ const OPENCLAW_BODY_PATHS = OPENCLAW_LOGO_PATHS.slice(2);
26
31
  function officialPathIcon(path, fill, size, opacity, cx, cy) {
27
32
  const s = size / 24;
28
33
  return `<g transform="translate(${cx},${cy}) scale(${s.toFixed(3)}) translate(-12,-12)" opacity="${opacity}"><path d="${path}" fill="${fill}" fill-rule="evenodd" clip-rule="evenodd"/></g>`;
29
34
  }
30
- function officialMultiPathIcon(paths, fill, size, opacity, cx, cy) {
35
+ function gradientPathIcon(path, size, opacity, cx, cy) {
31
36
  const s = size / 24;
37
+ const idSuffix = `${Math.round(size)}-${Math.round(cx * 10)}-${Math.round(cy * 10)}`.replace(/-/g, '_');
38
+ const gradId = `antigravity_rainbow_${idSuffix}`;
39
+ const warmId = `antigravity_warm_${idSuffix}`;
40
+ const greenId = `antigravity_green_${idSuffix}`;
41
+ const purpleId = `antigravity_purple_${idSuffix}`;
32
42
  return [
33
- `<g transform="translate(${cx},${cy}) scale(${s.toFixed(3)}) translate(-12,-12)" opacity="${opacity}" fill="${fill}" fill-rule="evenodd" clip-rule="evenodd">`,
34
- ...paths.map((p) => `<path d="${p}"/>`),
43
+ `<g transform="translate(${cx},${cy}) scale(${s.toFixed(3)}) translate(-12,-12)" opacity="${opacity}">`,
44
+ `<defs>`,
45
+ `<linearGradient id="${gradId}" x1="12" y1="1" x2="12" y2="23" gradientUnits="userSpaceOnUse">`,
46
+ `<stop offset="0%" stop-color="#FF8A18"/>`,
47
+ `<stop offset="24%" stop-color="#FF4F47"/>`,
48
+ `<stop offset="52%" stop-color="#28BDF3"/>`,
49
+ `<stop offset="100%" stop-color="#247CFF"/>`,
50
+ `</linearGradient>`,
51
+ `<radialGradient id="${warmId}" cx="9" cy="2" r="9" gradientUnits="userSpaceOnUse">`,
52
+ `<stop offset="0%" stop-color="#F3D233"/>`,
53
+ `<stop offset="58%" stop-color="#FF8A18" stop-opacity="0.74"/>`,
54
+ `<stop offset="100%" stop-color="#FF8A18" stop-opacity="0"/>`,
55
+ `</radialGradient>`,
56
+ `<radialGradient id="${greenId}" cx="4" cy="10" r="8" gradientUnits="userSpaceOnUse">`,
57
+ `<stop offset="0%" stop-color="#2FD66D"/>`,
58
+ `<stop offset="72%" stop-color="#2FD66D" stop-opacity="0.58"/>`,
59
+ `<stop offset="100%" stop-color="#2FD66D" stop-opacity="0"/>`,
60
+ `</radialGradient>`,
61
+ `<radialGradient id="${purpleId}" cx="20" cy="9" r="9" gradientUnits="userSpaceOnUse">`,
62
+ `<stop offset="0%" stop-color="#A85CC8"/>`,
63
+ `<stop offset="70%" stop-color="#A85CC8" stop-opacity="0.58"/>`,
64
+ `<stop offset="100%" stop-color="#A85CC8" stop-opacity="0"/>`,
65
+ `</radialGradient>`,
66
+ `</defs>`,
67
+ `<path d="${path}" fill="url(#${gradId})" fill-rule="evenodd" clip-rule="evenodd"/>`,
68
+ `<path d="${path}" fill="url(#${warmId})" fill-rule="evenodd" clip-rule="evenodd"/>`,
69
+ `<path d="${path}" fill="url(#${greenId})" fill-rule="evenodd" clip-rule="evenodd"/>`,
70
+ `<path d="${path}" fill="url(#${purpleId})" fill-rule="evenodd" clip-rule="evenodd"/>`,
35
71
  `</g>`,
36
72
  ].join('');
37
73
  }
74
+ function robotCreatureIcon(fill, size, opacity, cx, cy) {
75
+ return officialPathIcon(ROBOT_CREATURE_PATH, fill, size, opacity, cx, cy);
76
+ }
77
+ function codexCloudCreatureIcon(size, opacity, cx, cy) {
78
+ const idSuffix = `${Math.round(size)}-${Math.round(cx * 10)}-${Math.round(cy * 10)}`.replace(/-/g, '_');
79
+ const gradId = `codex_cloud_${idSuffix}`;
80
+ const s = (size * 0.82) / 24;
81
+ return [
82
+ `<defs>`,
83
+ `<linearGradient id="${gradId}" x1="0" y1="0" x2="24" y2="24" gradientUnits="userSpaceOnUse">`,
84
+ `<stop offset="0%" stop-color="#D9D3FF"/>`,
85
+ `<stop offset="48%" stop-color="#8BA4FF"/>`,
86
+ `<stop offset="100%" stop-color="#3941FF"/>`,
87
+ `</linearGradient>`,
88
+ `</defs>`,
89
+ `<g transform="translate(${cx},${cy}) scale(${s.toFixed(3)}) translate(-12,-12)" opacity="${opacity}">`,
90
+ `<path d="${CODEX_LOGO_PATH}" fill="url(#${gradId})" fill-rule="evenodd" clip-rule="evenodd"/>`,
91
+ `</g>`,
92
+ ].join('');
93
+ }
94
+ function openClawCreatureIcon(size, opacity, cx, cy) {
95
+ const bodySize = size * 0.92;
96
+ const s = bodySize / 24;
97
+ const idSuffix = `${Math.round(size)}-${Math.round(cx * 10)}-${Math.round(cy * 10)}`.replace(/-/g, '_');
98
+ const gradId = `openclaw_shell_${idSuffix}`;
99
+ return [
100
+ `<g transform="translate(${cx},${cy}) scale(${s.toFixed(3)}) translate(-12,-12)" opacity="${opacity}">`,
101
+ `<defs>`,
102
+ `<linearGradient id="${gradId}" x1="0" y1="0" x2="24" y2="24" gradientUnits="userSpaceOnUse">`,
103
+ `<stop offset="0%" stop-color="#FF6B6B"/>`,
104
+ `<stop offset="100%" stop-color="#991B1B"/>`,
105
+ `</linearGradient>`,
106
+ `</defs>`,
107
+ `<g fill="url(#${gradId})" fill-rule="evenodd" clip-rule="evenodd">`,
108
+ ...OPENCLAW_BODY_PATHS.map((p) => `<path d="${p}"/>`),
109
+ `</g>`,
110
+ `<circle cx="8.835" cy="7.843" r="1.266" fill="#050810"/>`,
111
+ `<circle cx="15.165" cy="7.843" r="1.266" fill="#050810"/>`,
112
+ `<circle cx="9.046" cy="7.632" r="0.527" fill="#00E5CC" opacity="0.9"/>`,
113
+ `<circle cx="15.376" cy="7.632" r="0.527" fill="#00E5CC" opacity="0.9"/>`,
114
+ `</g>`,
115
+ ].join('');
116
+ }
117
+ function openCodeCreatureIcon(size, opacity, cx, cy) {
118
+ // Canonical opencode mark (opencode.svg, viewBox 24, evenodd): a single-color vertical
119
+ // rectangular RING with a HOLLOW center — not filled nested squares. Map so the mark
120
+ // (16×20) sits centered on (cx,cy) at ~0.6×size tall.
121
+ const s = (size * 0.72) / 24;
122
+ const tx = cx - 12 * s;
123
+ const ty = cy - 12 * s;
124
+ return [
125
+ `<g opacity="${opacity}" transform="translate(${tx.toFixed(2)} ${ty.toFixed(2)}) scale(${s.toFixed(4)})">`,
126
+ `<path d="M16 6H8v12h8V6zm4 16H4V2h16v20z" fill-rule="evenodd" fill="#F1ECEC"/>`,
127
+ `</g>`,
128
+ ].join('');
129
+ }
130
+ function antigravityCreatureIcon(size, opacity, cx, cy) {
131
+ return gradientPathIcon(ANTIGRAVITY_PATH, size * 0.76, opacity, cx, cy);
132
+ }
133
+ const AGENT_MONO_GLYPH = {
134
+ 'claude-code': { paths: [ROBOT_CREATURE_PATH] },
135
+ 'codex-cli': { paths: [CODEX_LOGO_PATH] },
136
+ 'codex-app': { paths: [CODEX_LOGO_PATH] },
137
+ codex: { paths: [CODEX_LOGO_PATH] },
138
+ opencode: { paths: [OPENCODE_RING_PATH] },
139
+ antigravity: { paths: [ANTIGRAVITY_PATH] },
140
+ openclaw: { paths: OPENCLAW_BODY_PATHS, eyes: [[8.835, 7.843, 1.05], [15.165, 7.843, 1.05]] },
141
+ };
142
+ /**
143
+ * Render the agent's canonical brand mark as a 1-bit glyph: the path(s) filled
144
+ * with `ink` (evenodd so in-path holes — robot eyes, opencode ring, codex prompt —
145
+ * read as paper), plus any separate `paper` eye cutouts. 24-unit viewBox scaled to
146
+ * `size`, centered on (cx,cy). Used by the TRMNL e-ink layout; mirrored in Swift.
147
+ */
148
+ export function agentGlyphMono(agent, cx, cy, size, ink, paper) {
149
+ const g = AGENT_MONO_GLYPH[(agent || '').toLowerCase()] ?? AGENT_MONO_GLYPH.openclaw;
150
+ const s = size / 24;
151
+ const agentClass = (agent || '').toLowerCase();
152
+ const out = [`<g class="agent-mono-glyph-${agentClass}" transform="translate(${cx.toFixed(2)},${cy.toFixed(2)}) scale(${s.toFixed(4)}) translate(-12,-12)">`];
153
+ for (const p of g.paths)
154
+ out.push(`<path d="${p}" fill="${ink}" fill-rule="evenodd"/>`);
155
+ if (g.eyes)
156
+ for (const [ex, ey, er] of g.eyes)
157
+ out.push(`<circle cx="${ex}" cy="${ey}" r="${er}" fill="${paper}"/>`);
158
+ out.push('</g>');
159
+ return out.join('');
160
+ }
38
161
  // ===== Prominent agent icon (top of button, primary identification) =====
39
162
  /**
40
163
  * Render agent logo as a visible icon at top-center of button.
@@ -46,26 +169,18 @@ function officialMultiPathIcon(paths, fill, size, opacity, cx, cy) {
46
169
  export function agentLogoIcon(agent, size = 48, opacity = 0.7, cx = 72, cy = size / 2 + 12) {
47
170
  const brandColor = agentBrandColor(agent);
48
171
  if (agent === 'claude-code') {
49
- return officialPathIcon(CLAUDE_LOGO_PATH, brandColor, size, opacity, cx, cy);
172
+ return robotCreatureIcon(brandColor, size, opacity, cx, cy);
50
173
  }
51
- if (agent === 'codex-cli') {
52
- return officialPathIcon(CODEX_LOGO_PATH, brandColor, size, opacity, cx, cy);
174
+ if (agent === 'codex-cli' || agent === 'codex-app') {
175
+ return codexCloudCreatureIcon(size, opacity, cx, cy);
53
176
  }
54
177
  if (agent === 'opencode') {
55
- // Smaller icon for OpenCode (geometric squares are visually heavier)
56
- const ocSize = Math.round(size * 0.75);
57
- const half = ocSize / 2;
58
- const ring = ocSize * 0.18;
59
- const inner = ocSize * 0.5;
60
- return [
61
- `<g opacity="${opacity}">`,
62
- `<rect x="${cx - half}" y="${cy - half}" width="${ocSize}" height="${ocSize}" rx="4" fill="${dimColor(brandColor, 0.3)}"/>`,
63
- `<rect x="${cx - half + ring}" y="${cy - half + ring}" width="${ocSize - ring * 2}" height="${ocSize - ring * 2}" rx="2" fill="${dimColor('#4B4646', 0.2)}"/>`,
64
- `<rect x="${cx - inner / 2}" y="${cy - inner / 2}" width="${inner}" height="${inner}" rx="2" fill="${dimColor('#4B4646', 0.2)}"/>`,
65
- `</g>`,
66
- ].join('');
178
+ return openCodeCreatureIcon(size, opacity, cx, cy);
67
179
  }
68
- return officialMultiPathIcon(OPENCLAW_LOGO_PATHS, brandColor, size, opacity, cx, cy);
180
+ if (agent === 'antigravity') {
181
+ return antigravityCreatureIcon(size, opacity, cx, cy);
182
+ }
183
+ return openClawCreatureIcon(size, opacity, cx, cy);
69
184
  }
70
185
  // ===== Low-opacity watermark (background mark) =====
71
186
  /**
@@ -77,24 +192,17 @@ export function agentLogoWatermark(agent, _color, opacity = 0.12) {
77
192
  const markOpacity = Math.min(opacity * 4, 0.9);
78
193
  const fill = dimColor(brandColor, 0.5);
79
194
  if (agent === 'claude-code') {
80
- return officialPathIcon(CLAUDE_LOGO_PATH, fill, 72, markOpacity, 72, 72);
195
+ return robotCreatureIcon(fill, 72, markOpacity, 72, 72);
81
196
  }
82
- if (agent === 'codex-cli') {
83
- return officialPathIcon(CODEX_LOGO_PATH, fill, 72, markOpacity, 72, 72);
197
+ if (agent === 'codex-cli' || agent === 'codex-app') {
198
+ return codexCloudCreatureIcon(72, markOpacity, 72, 72);
84
199
  }
85
200
  if (agent === 'opencode') {
86
- const s = 72;
87
- const half = s / 2;
88
- const ring = s * 0.18;
89
- const inner = s * 0.5;
90
- return [
91
- `<g opacity="${markOpacity}">`,
92
- `<rect x="${72 - half}" y="${72 - half}" width="${s}" height="${s}" fill="${dimColor('#F1ECEC', 0.6)}"/>`,
93
- `<rect x="${72 - half + ring}" y="${72 - half + ring}" width="${s - ring * 2}" height="${s - ring * 2}" fill="${dimColor('#4B4646', 0.5)}"/>`,
94
- `<rect x="${72 - inner / 2}" y="${72 - inner / 2}" width="${inner}" height="${inner}" fill="${dimColor('#4B4646', 0.5)}"/>`,
95
- `</g>`,
96
- ].join('');
201
+ return openCodeCreatureIcon(72, markOpacity, 72, 72);
202
+ }
203
+ if (agent === 'antigravity') {
204
+ return antigravityCreatureIcon(72, markOpacity, 72, 72);
97
205
  }
98
- return officialMultiPathIcon(OPENCLAW_LOGO_PATHS, fill, 72, markOpacity, 72, 72);
206
+ return openClawCreatureIcon(72, markOpacity, 72, 72);
99
207
  }
100
208
  //# sourceMappingURL=agent-logos.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"agent-logos.js","sourceRoot":"","sources":["../../src/svg-renderers/agent-logos.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAGH,OAAO,EAAE,QAAQ,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AAE/D,8EAA8E;AAC9E,MAAM,CAAC,MAAM,gBAAgB,GAC3B,69CAA69C,CAAC;AAEh+C,2EAA2E;AAC3E,MAAM,CAAC,MAAM,OAAO,GAClB,+JAA+J,CAAC;AAClK,MAAM,CAAC,MAAM,SAAS,GACpB,+DAA+D,CAAC;AAClE,MAAM,CAAC,MAAM,SAAS,GACpB,yEAAyE,CAAC;AAE5E,uFAAuF;AACvF,MAAM,CAAC,MAAM,eAAe,GAC1B,6nCAA6nC,CAAC;AAEhoC,6EAA6E;AAC7E,MAAM,CAAC,MAAM,mBAAmB,GAAG;IACjC,wDAAwD;IACxD,yDAAyD;IACzD,87BAA87B;IAC97B,oSAAoS;IACpS,6XAA6X;CAC9X,CAAC;AAEF,SAAS,gBAAgB,CAAC,IAAY,EAAE,IAAY,EAAE,IAAY,EAAE,OAAe,EAAE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ACxD,CAAC;IACD,OAAO,oBAAoB,CAAC,IAAI,EAAE,OAAO,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;AACrD,CAAC;AAED,sDAAsD;AAEtD;;;GAGG;AACH,MAAM,UAAU,kBAAkB,CAChC,KAAgB,EAChB,MAAe,EACf,OAAO,GAAG,IAAI;IAEd,MAAM,UAAU,GAAG,eAAe,CAAC,KAAK,CAAC,CAAC;IAC1C,MAAM,WAAW,GAAG,IAAI,CAAC,GAAG,CAAC,OAAO,GAAG,CAAC,EAAE,GAAG,CAAC,CAAC;IAC/C,MAAM,IAAI,GAAG,QAAQ,CAAC,UAAU,EAAE,GAAG,CAAC,CAAC;IAEvC,IAAI,KAAK,KAAK,aAAa,EAAE,CAAC;QAC5B,OAAO,iBAAiB,CAAC,IAAI,EAAE,EAAE,EAAE,WAAW,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;IAC1D,CAAC;IACD,IAAI,KAAK,KAAK,WAAW,IAAI,KAAK,KAAK,WAAW,EAAE,CAAC;QACnD,OAAO,sBAAsB,CAAC,EAAE,EAAE,WAAW,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;IACzD,CAAC;IACD,IAAI,KAAK,KAAK,UAAU,EAAE,CAAC;QACzB,OAAO,oBAAoB,CAAC,EAAE,EAAE,WAAW,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;IACvD,CAAC;IACD,IAAI,KAAK,KAAK,aAAa,EAAE,CAAC;QAC5B,OAAO,uBAAuB,CAAC,EAAE,EAAE,WAAW,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;IAC1D,CAAC;IACD,OAAO,oBAAoB,CAAC,EAAE,EAAE,WAAW,EAAE,EAAE,EAAE,EAAE,CAAC,CAAC;AACvD,CAAC"}
@@ -1,18 +1,81 @@
1
1
  import type { SessionInfo } from '../protocol.js';
2
2
  import type { PromptOption } from '../states.js';
3
3
  import { State } from '../states.js';
4
+ export type DisconnectedSlotKind = 'open-app' | 'empty';
5
+ export type ClusterQuadrant = 'tl' | 'tr' | 'bl' | 'br';
6
+ export interface DisconnectedSlotConfig {
7
+ kind: DisconnectedSlotKind;
8
+ label?: string;
9
+ subtitle?: string;
10
+ detail?: string;
11
+ /**
12
+ * When set, render the matching 144×144 quadrant of a 288×288 cluster
13
+ * hero — used by even×even decks (SD+, SD XL) so the OFFLINE card sits
14
+ * on the geometric center 2×2 of the keypad instead of one off-center key.
15
+ */
16
+ quadrant?: ClusterQuadrant;
17
+ col?: number;
18
+ row?: number;
19
+ cols?: number;
20
+ rows?: number;
21
+ }
22
+ export type StatusIconKind = 'hub' | 'no-session' | 'agentdeck' | 'tool' | 'model' | 'mode' | 'ready' | 'activity' | 'open-app' | 'retry' | 'offline' | 'back' | 'more' | 'esc' | 'stop' | 'play' | 'review' | 'commit' | 'clear' | 'gateway' | 'status' | 'allow' | 'deny' | 'diff' | 'option';
23
+ export type StatusCardTone = 'ready' | 'idle' | 'info' | 'warning' | 'danger' | 'muted' | 'agent' | 'action' | 'brand' | 'purple';
24
+ export interface StatusCardConfig {
25
+ icon: StatusIconKind;
26
+ label: string;
27
+ subtitle?: string;
28
+ detail?: string;
29
+ tone?: StatusCardTone;
30
+ }
4
31
  /**
5
- * Format "Model · effort" suffix for session tile / detail view.
6
- * Skips neutral efforts ("medium" legacy, "default" is Claude Code 2.1+
7
- * per-model default) so they don't clutter the tile. Truncates the model
8
- * name preferentially so the effort label survives in tight pixel budgets.
32
+ * Compact, readable model strings for narrow surfaces (StreamDeck 144\u00d7144 keys).
33
+ * - claude-sonnet-4-6 \u2192 "sonnet 4.6"
34
+ * - claude-opus-4-7 \u2192 "opus 4.7"
35
+ * - claude-haiku-4-5-20251001 \u2192 "haiku 4.5" (date suffix dropped)
36
+ * - gpt-5-codex / gpt-5 / others \u2192 unchanged (caller still truncates if needed)
9
37
  */
38
+ export declare function aliasModelName(name: string): string;
10
39
  export declare function formatModelEffort(modelName?: string, effortLevel?: string, maxLen?: number): string;
40
+ /**
41
+ * AgentDeck product mark — the aquarium dome over a hardware deck (glass dome +
42
+ * waterline + highlight + rounded deck base + three keys + two bubbles). Ported
43
+ * unit-for-unit (0..24 space) from the SwiftUI `AgentDeckLogo` / Compose
44
+ * `AgentDeckMark` so the Stream Deck / D200H offline hero shows the SAME brand
45
+ * mark that the macOS/iOS/Android connection overlays and the ESP32 splash draw.
46
+ * Centered on (x,y); `size` is the mark's width in px. `color` draws the dome/deck
47
+ * strokes + keys; `accent` tints the waterline + bubbles.
48
+ */
49
+ export declare function renderAgentDeckMark(x: number, y: number, size: number, color: string, accent?: string): string;
50
+ /**
51
+ * Small-size reduction of {@link renderAgentDeckMark}.
52
+ *
53
+ * The full mark carries a waterline, a dome highlight and interior bubbles at
54
+ * 0.34–0.62 opacity. Those read at 72px+ but collapse into a grey blob by 20px,
55
+ * which is the size Stream Deck draws action-list icons at. This keeps the
56
+ * mark's three identifying features — dome arc, deck body, three keys — at full
57
+ * opacity and drops everything that cannot survive the downsample.
58
+ *
59
+ * Keep the two in sync: if the mark's silhouette changes, change this too.
60
+ */
61
+ export declare function renderAgentDeckMarkCompact(x: number, y: number, size: number, color: string): string;
11
62
  export declare function renderSessionSlot(session: SessionInfo, isActive: boolean, animFrame: number, displayName?: string, options?: {
12
63
  animated?: boolean;
64
+ processingStartFrame?: number;
65
+ isStale?: boolean;
13
66
  }): string;
14
67
  export declare function renderEmptySlot(): string;
15
- export declare function renderNoDaemonSlot(slot: number): string;
68
+ export declare function renderQuietSlot(): string;
69
+ export declare function renderStatusCard(config: StatusCardConfig): string;
70
+ export declare function renderDisconnectedSlot(config: DisconnectedSlotConfig): string;
71
+ /**
72
+ * Renders a single 144×144 viewport into a 288×288 cluster hero. Each of the
73
+ * four center keys (tl/tr/bl/br) emits the same logical content offset by its
74
+ * quadrant; viewBox clipping keeps only the relevant 144×144 visible. The
75
+ * cluster reads as one card visually, with the inner panel + glyph + text
76
+ * spanning all four keys while each key keeps its own outer rounded bezel.
77
+ */
78
+ export declare function renderOpenAppQuadrant(quadrant: ClusterQuadrant, label?: string, subtitle?: string): string;
16
79
  export declare function renderBackButton(): string;
17
80
  export declare function renderNextPageButton(pageLabel: string): string;
18
81
  export declare function renderEscButton(active?: boolean): string;
@@ -20,6 +83,8 @@ export declare function renderStopButton(active?: boolean): string;
20
83
  export declare function renderDetailInfo(session: SessionInfo | undefined, state: State, tool?: string, modelName?: string, mode?: string, displayName?: string, effortLevel?: string): string;
21
84
  export declare function renderOptionButton(option: PromptOption, index: number): string;
22
85
  export declare function renderPresetButton(label: string, iconSvg: string, color: string, textColor: string, subtitle?: string, loading?: boolean): string;
23
- export declare function renderInfoSlot(label: string, subtitle?: string): string;
86
+ export declare function renderInfoSlot(label: string, subtitle?: string, icon?: StatusIconKind, tone?: StatusCardTone, detail?: string): string;
24
87
  export declare function svgFrame(bgColor: string, innerElements: string): string;
88
+ export declare function renderOpenAppGrid(col: number, row: number, cols: number, rows: number, label?: string, subtitle?: string): string;
89
+ export declare function renderOfflineTouchStrip(index: number): string;
25
90
  //# sourceMappingURL=session-slot-renderer.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"session-slot-renderer.d.ts","sourceRoot":"","sources":["../../src/svg-renderers/session-slot-renderer.ts"],"names":[],"mappings":"AAUA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,KAAK,EAAE,MAAM,cAAc,CAAC;AAwCrC;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAAC,SAAS,CAAC,EAAE,MAAM,EAAE,WAAW,CAAC,EAAE,MAAM,EAAE,MAAM,SAAK,GAAG,MAAM,CAS/F;AAID,wBAAgB,iBAAiB,CAC/B,OAAO,EAAE,WAAW,EACpB,QAAQ,EAAE,OAAO,EACjB,SAAS,EAAE,MAAM,EACjB,WAAW,CAAC,EAAE,MAAM,EACpB,OAAO,CAAC,EAAE;IAAE,QAAQ,CAAC,EAAE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