@design.estate/dees-catalog 4.12.0 → 5.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.
- package/dist_bundle/bundle.js +2322 -1251
- package/dist_ts_web/00_commitinfo_data.js +2 -2
- package/dist_ts_web/elements/00group-harness/dees-harness-chat/dees-harness-chat.d.ts +17 -3
- package/dist_ts_web/elements/00group-harness/dees-harness-chat/dees-harness-chat.demo.js +291 -78
- package/dist_ts_web/elements/00group-harness/dees-harness-chat/dees-harness-chat.js +328 -35
- package/dist_ts_web/elements/00group-harness/dees-harness-message/dees-harness-message.js +44 -3
- package/dist_ts_web/elements/00group-harness/dees-harness-reasoning/dees-harness-reasoning.js +5 -7
- package/dist_ts_web/elements/00group-harness/dees-harness-session-list/dees-harness-session-list.js +5 -2
- package/dist_ts_web/elements/00group-harness/dees-harness-session-sidebar/dees-harness-session-sidebar.d.ts +49 -0
- package/dist_ts_web/elements/00group-harness/dees-harness-session-sidebar/dees-harness-session-sidebar.demo.d.ts +1 -0
- package/dist_ts_web/elements/00group-harness/dees-harness-session-sidebar/dees-harness-session-sidebar.demo.js +56 -0
- package/dist_ts_web/elements/00group-harness/dees-harness-session-sidebar/dees-harness-session-sidebar.js +649 -0
- package/dist_ts_web/elements/00group-harness/dees-harness-session-sidebar/index.d.ts +1 -0
- package/dist_ts_web/elements/00group-harness/dees-harness-session-sidebar/index.js +2 -0
- package/dist_ts_web/elements/00group-harness/harness.markdown.js +3 -1
- package/dist_ts_web/elements/00group-harness/harness.styles.js +29 -1
- package/dist_ts_web/elements/00group-harness/index.d.ts +1 -0
- package/dist_ts_web/elements/00group-harness/index.js +2 -1
- package/dist_ts_web/elements/00group-harness/interfaces.d.ts +41 -0
- package/package.json +1 -1
- package/readme.md +11 -5
- package/ts_web/00_commitinfo_data.ts +1 -1
- package/ts_web/elements/00group-harness/dees-harness-chat/dees-harness-chat.demo.ts +278 -79
- package/ts_web/elements/00group-harness/dees-harness-chat/dees-harness-chat.ts +283 -28
- package/ts_web/elements/00group-harness/dees-harness-message/dees-harness-message.ts +43 -2
- package/ts_web/elements/00group-harness/dees-harness-reasoning/dees-harness-reasoning.ts +4 -6
- package/ts_web/elements/00group-harness/dees-harness-session-list/dees-harness-session-list.ts +4 -1
- package/ts_web/elements/00group-harness/dees-harness-session-sidebar/dees-harness-session-sidebar.demo.ts +67 -0
- package/ts_web/elements/00group-harness/dees-harness-session-sidebar/dees-harness-session-sidebar.ts +557 -0
- package/ts_web/elements/00group-harness/dees-harness-session-sidebar/index.ts +1 -0
- package/ts_web/elements/00group-harness/harness.markdown.ts +2 -0
- package/ts_web/elements/00group-harness/harness.styles.ts +28 -0
- package/ts_web/elements/00group-harness/index.ts +1 -0
- package/ts_web/elements/00group-harness/interfaces.ts +48 -0
|
@@ -6,6 +6,7 @@ import {
|
|
|
6
6
|
customElement,
|
|
7
7
|
type TemplateResult,
|
|
8
8
|
property,
|
|
9
|
+
state,
|
|
9
10
|
cssManager,
|
|
10
11
|
} from '@design.estate/dees-element';
|
|
11
12
|
import { themeDefaultStyles } from '../../00theme.js';
|
|
@@ -14,6 +15,9 @@ import type {
|
|
|
14
15
|
IHarnessMessage,
|
|
15
16
|
IHarnessPermissionRequest,
|
|
16
17
|
IHarnessQuestionRequest,
|
|
18
|
+
IHarnessIntelligenceExchange,
|
|
19
|
+
IHarnessScratchpad,
|
|
20
|
+
IHarnessSessionMetrics,
|
|
17
21
|
IHarnessStatus,
|
|
18
22
|
IHarnessTodoItem,
|
|
19
23
|
IHarnessUsage,
|
|
@@ -24,6 +28,7 @@ import { DeesHarnessToolRegistry } from '../toolregistry.js';
|
|
|
24
28
|
import { DeesHarnessMessageList } from '../dees-harness-message-list/dees-harness-message-list.js';
|
|
25
29
|
import { DeesHarnessComposer } from '../dees-harness-composer/dees-harness-composer.js';
|
|
26
30
|
import '../dees-harness-todos/dees-harness-todos.js';
|
|
31
|
+
import '../dees-harness-session-sidebar/dees-harness-session-sidebar.js';
|
|
27
32
|
import '../dees-harness-usage/dees-harness-usage.js';
|
|
28
33
|
import '../../00group-button/dees-button/dees-button.js';
|
|
29
34
|
import '../../00group-utility/dees-icon/dees-icon.js';
|
|
@@ -40,8 +45,7 @@ declare global {
|
|
|
40
45
|
* pinned permission queue, status line, and composer. Owns no business
|
|
41
46
|
* logic — consumers feed `.messages`/`.permissions`/`.status` (and stream
|
|
42
47
|
* through `applyDelta()`), and listen for the bubbling harness-* events
|
|
43
|
-
* from the children plus `harness-
|
|
44
|
-
* from the toolbar.
|
|
48
|
+
* from the children plus `harness-toggle-sidebar` from the toolbar.
|
|
45
49
|
*/
|
|
46
50
|
@customElement('dees-harness-chat')
|
|
47
51
|
export class DeesHarnessChat extends DeesElement {
|
|
@@ -75,6 +79,36 @@ export class DeesHarnessChat extends DeesElement {
|
|
|
75
79
|
@property({ type: Boolean })
|
|
76
80
|
accessor showTodosPanel: boolean = true;
|
|
77
81
|
|
|
82
|
+
@property({ type: Boolean })
|
|
83
|
+
accessor showSessionSidebar: boolean = true;
|
|
84
|
+
|
|
85
|
+
@property({ attribute: false })
|
|
86
|
+
accessor sessionMetrics: IHarnessSessionMetrics = {};
|
|
87
|
+
|
|
88
|
+
@property({ attribute: false })
|
|
89
|
+
accessor scratchpad: IHarnessScratchpad | undefined = undefined;
|
|
90
|
+
|
|
91
|
+
@property({ type: Boolean })
|
|
92
|
+
accessor scratchpadBusy: boolean = false;
|
|
93
|
+
|
|
94
|
+
@property()
|
|
95
|
+
accessor scratchpadError: string = '';
|
|
96
|
+
|
|
97
|
+
@property({ type: Boolean })
|
|
98
|
+
accessor sessionIntelligenceEnabled: boolean = false;
|
|
99
|
+
|
|
100
|
+
@property({ attribute: false })
|
|
101
|
+
accessor intelligenceExchanges: IHarnessIntelligenceExchange[] = [];
|
|
102
|
+
|
|
103
|
+
@property({ type: Boolean })
|
|
104
|
+
accessor intelligenceBusy: boolean = false;
|
|
105
|
+
|
|
106
|
+
@property()
|
|
107
|
+
accessor intelligenceError: string = '';
|
|
108
|
+
|
|
109
|
+
@state()
|
|
110
|
+
private accessor sessionSidebarOpen: boolean = false;
|
|
111
|
+
|
|
78
112
|
@property()
|
|
79
113
|
accessor heading: string = '';
|
|
80
114
|
|
|
@@ -144,6 +178,7 @@ export class DeesHarnessChat extends DeesElement {
|
|
|
144
178
|
}
|
|
145
179
|
|
|
146
180
|
.chatBody {
|
|
181
|
+
position: relative;
|
|
147
182
|
flex: 1;
|
|
148
183
|
min-height: 0;
|
|
149
184
|
min-width: 0;
|
|
@@ -156,7 +191,14 @@ export class DeesHarnessChat extends DeesElement {
|
|
|
156
191
|
min-width: 0;
|
|
157
192
|
}
|
|
158
193
|
|
|
159
|
-
.
|
|
194
|
+
.transcriptColumn {
|
|
195
|
+
flex: 1;
|
|
196
|
+
min-height: 0;
|
|
197
|
+
display: flex;
|
|
198
|
+
flex-direction: column;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
.sessionPanel {
|
|
160
202
|
flex: 0 0 232px;
|
|
161
203
|
min-width: 0;
|
|
162
204
|
overflow-y: auto;
|
|
@@ -167,11 +209,95 @@ export class DeesHarnessChat extends DeesElement {
|
|
|
167
209
|
background: var(--dees-color-bg-secondary);
|
|
168
210
|
}
|
|
169
211
|
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
212
|
+
.sessionPanelClose,
|
|
213
|
+
.sessionPanelToggle,
|
|
214
|
+
.sessionPanelBackdrop {
|
|
215
|
+
display: none;
|
|
216
|
+
}
|
|
217
|
+
|
|
218
|
+
.sessionPanelToggle {
|
|
219
|
+
box-sizing: border-box;
|
|
220
|
+
width: var(--dees-control-height-lg);
|
|
221
|
+
height: var(--dees-control-height-lg);
|
|
222
|
+
padding: 0;
|
|
223
|
+
align-items: center;
|
|
224
|
+
justify-content: center;
|
|
225
|
+
border: 1px solid transparent;
|
|
226
|
+
border-radius: var(--dees-radius-lg);
|
|
227
|
+
corner-shape: var(--dees-corner-shape);
|
|
228
|
+
background: transparent;
|
|
229
|
+
color: var(--dees-color-text-primary);
|
|
230
|
+
cursor: pointer;
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
.sessionPanelToggle:hover {
|
|
234
|
+
background: var(--dees-color-badge-default-bg);
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
.sessionPanelToggle:focus-visible {
|
|
238
|
+
outline: 2px solid var(--dees-color-accent-primary);
|
|
239
|
+
outline-offset: 2px;
|
|
240
|
+
}
|
|
241
|
+
|
|
242
|
+
/* Narrow hosts keep every session section reachable in an overlay.
|
|
243
|
+
Todo tool cards remain a second transcript-level representation. */
|
|
244
|
+
@container (max-width: 680px) {
|
|
245
|
+
.sessionPanel {
|
|
246
|
+
position: absolute;
|
|
247
|
+
inset: 0 0 0 auto;
|
|
248
|
+
width: min(320px, calc(100% - 36px));
|
|
249
|
+
max-width: none;
|
|
250
|
+
padding-top: 42px;
|
|
251
|
+
border-left-color: var(--dees-color-border-default);
|
|
252
|
+
box-shadow: var(--dees-shadow-lg);
|
|
253
|
+
visibility: hidden;
|
|
254
|
+
transform: translateX(100%);
|
|
255
|
+
transition:
|
|
256
|
+
transform var(--dees-transition-default) var(--dees-ease-out),
|
|
257
|
+
visibility 0s linear var(--dees-transition-default);
|
|
258
|
+
}
|
|
259
|
+
|
|
260
|
+
.sessionPanel.open {
|
|
261
|
+
visibility: visible;
|
|
262
|
+
transform: translateX(0);
|
|
263
|
+
transition-delay: 0s;
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
.sessionPanelClose {
|
|
267
|
+
position: absolute;
|
|
268
|
+
top: 6px;
|
|
269
|
+
right: 8px;
|
|
270
|
+
display: block;
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
.sessionPanelToggle {
|
|
274
|
+
position: absolute;
|
|
275
|
+
top: 8px;
|
|
276
|
+
right: 8px;
|
|
277
|
+
display: flex;
|
|
278
|
+
}
|
|
279
|
+
|
|
280
|
+
.sessionPanelBackdrop {
|
|
281
|
+
position: absolute;
|
|
282
|
+
inset: 0;
|
|
283
|
+
display: block;
|
|
284
|
+
border: 0;
|
|
285
|
+
background: color-mix(in srgb, var(--dees-color-bg-primary) 58%, transparent);
|
|
286
|
+
opacity: 0;
|
|
287
|
+
pointer-events: none;
|
|
288
|
+
transition: opacity var(--dees-transition-default) var(--dees-ease-standard);
|
|
289
|
+
}
|
|
290
|
+
|
|
291
|
+
.sessionPanelBackdrop.open {
|
|
292
|
+
opacity: 1;
|
|
293
|
+
pointer-events: auto;
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
@media (prefers-reduced-motion: reduce) {
|
|
297
|
+
.sessionPanel,
|
|
298
|
+
.sessionPanelBackdrop {
|
|
299
|
+
transition: none;
|
|
300
|
+
}
|
|
175
301
|
}
|
|
176
302
|
}
|
|
177
303
|
|
|
@@ -219,7 +345,7 @@ export class DeesHarnessChat extends DeesElement {
|
|
|
219
345
|
flex: 0 0 auto;
|
|
220
346
|
}
|
|
221
347
|
|
|
222
|
-
.
|
|
348
|
+
.transcriptColumn dees-harness-message-list {
|
|
223
349
|
flex: 1;
|
|
224
350
|
min-height: 0;
|
|
225
351
|
}
|
|
@@ -232,6 +358,36 @@ export class DeesHarnessChat extends DeesElement {
|
|
|
232
358
|
position: relative;
|
|
233
359
|
z-index: 1;
|
|
234
360
|
}
|
|
361
|
+
|
|
362
|
+
.composerContextBar {
|
|
363
|
+
min-width: 0;
|
|
364
|
+
display: flex;
|
|
365
|
+
align-items: center;
|
|
366
|
+
gap: var(--dees-spacing-xs);
|
|
367
|
+
padding: 5px var(--dees-spacing-md);
|
|
368
|
+
background: var(--dees-color-bg-secondary);
|
|
369
|
+
color: var(--dees-color-text-muted);
|
|
370
|
+
font-size: var(--dees-font-caption2-size, 10px);
|
|
371
|
+
line-height: 1.3;
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
.composerContextBar dees-icon {
|
|
375
|
+
flex: 0 0 auto;
|
|
376
|
+
color: var(--dees-color-text-secondary);
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
.composerContextLabel {
|
|
380
|
+
flex: 0 0 auto;
|
|
381
|
+
}
|
|
382
|
+
|
|
383
|
+
.composerContextTitle {
|
|
384
|
+
min-width: 0;
|
|
385
|
+
overflow: hidden;
|
|
386
|
+
color: var(--dees-color-text-secondary);
|
|
387
|
+
font-weight: 600;
|
|
388
|
+
text-overflow: ellipsis;
|
|
389
|
+
white-space: nowrap;
|
|
390
|
+
}
|
|
235
391
|
`,
|
|
236
392
|
];
|
|
237
393
|
|
|
@@ -269,6 +425,16 @@ export class DeesHarnessChat extends DeesElement {
|
|
|
269
425
|
return [];
|
|
270
426
|
}
|
|
271
427
|
|
|
428
|
+
public get hasSessionSidebar(): boolean {
|
|
429
|
+
if (!this.showSessionSidebar) return false;
|
|
430
|
+
return (
|
|
431
|
+
(this.showTodosPanel && this.effectiveTodos.length > 0)
|
|
432
|
+
|| Object.values(this.sessionMetrics).some((value) => value !== undefined)
|
|
433
|
+
|| this.scratchpad !== undefined
|
|
434
|
+
|| this.sessionIntelligenceEnabled
|
|
435
|
+
);
|
|
436
|
+
}
|
|
437
|
+
|
|
272
438
|
private get listElement(): DeesHarnessMessageList | undefined {
|
|
273
439
|
const element = this.shadowRoot?.querySelector('dees-harness-message-list');
|
|
274
440
|
return element instanceof DeesHarnessMessageList ? element : undefined;
|
|
@@ -279,26 +445,113 @@ export class DeesHarnessChat extends DeesElement {
|
|
|
279
445
|
return element instanceof DeesHarnessComposer ? element : undefined;
|
|
280
446
|
}
|
|
281
447
|
|
|
448
|
+
private readonly toggleSessionSidebar = (): void => {
|
|
449
|
+
if (this.sessionSidebarOpen) {
|
|
450
|
+
void this.closeSessionSidebar();
|
|
451
|
+
return;
|
|
452
|
+
}
|
|
453
|
+
void this.openSessionSidebar();
|
|
454
|
+
};
|
|
455
|
+
|
|
456
|
+
private async openSessionSidebar(): Promise<void> {
|
|
457
|
+
this.sessionSidebarOpen = true;
|
|
458
|
+
await this.updateComplete;
|
|
459
|
+
const panel = this.shadowRoot?.querySelector<HTMLElement>('.sessionPanel');
|
|
460
|
+
await new Promise<void>((resolve) => requestAnimationFrame(() => resolve()));
|
|
461
|
+
panel?.focus();
|
|
462
|
+
}
|
|
463
|
+
|
|
464
|
+
private async closeSessionSidebar(): Promise<void> {
|
|
465
|
+
this.sessionSidebarOpen = false;
|
|
466
|
+
await this.updateComplete;
|
|
467
|
+
const toggleButton = this.shadowRoot?.querySelector<HTMLButtonElement>('.sessionPanelToggle');
|
|
468
|
+
toggleButton?.focus();
|
|
469
|
+
}
|
|
470
|
+
|
|
282
471
|
// ----------------------------------------------------------------- render
|
|
283
472
|
|
|
284
473
|
public render(): TemplateResult {
|
|
285
474
|
return html`
|
|
286
475
|
${this.showToolbar ? this.renderToolbar() : ''}
|
|
287
476
|
<div class="chatBody">
|
|
288
|
-
<
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
477
|
+
<div class="transcriptColumn">
|
|
478
|
+
<dees-harness-message-list
|
|
479
|
+
.messages=${this.messages}
|
|
480
|
+
.permissions=${this.permissions}
|
|
481
|
+
.permissionsBusy=${this.disabled}
|
|
482
|
+
.questions=${this.questions}
|
|
483
|
+
.status=${this.status}
|
|
484
|
+
.showRoles=${this.showRoles}
|
|
485
|
+
.showTimestamps=${this.showTimestamps}
|
|
486
|
+
.toolRegistry=${this.toolRegistry}
|
|
487
|
+
></dees-harness-message-list>
|
|
488
|
+
${this.heading
|
|
489
|
+
? html`
|
|
490
|
+
<div class="composerContextBar" title=${`Replying to ${this.heading}`}>
|
|
491
|
+
<dees-icon icon="lucide:MessageSquare" iconSize="11"></dees-icon>
|
|
492
|
+
<span class="composerContextLabel">Replying to</span>
|
|
493
|
+
<span class="composerContextTitle">${this.heading}</span>
|
|
494
|
+
</div>
|
|
495
|
+
`
|
|
496
|
+
: ''}
|
|
497
|
+
${this.hasSessionSidebar ? html`
|
|
498
|
+
<button
|
|
499
|
+
class="sessionPanelToggle"
|
|
500
|
+
type="button"
|
|
501
|
+
aria-label="Session details"
|
|
502
|
+
title="Session details"
|
|
503
|
+
aria-expanded=${String(this.sessionSidebarOpen)}
|
|
504
|
+
aria-controls="harness-session-panel"
|
|
505
|
+
@click=${this.toggleSessionSidebar}
|
|
506
|
+
>
|
|
507
|
+
<dees-icon icon="lucide:PanelRight" iconSize="16"></dees-icon>
|
|
508
|
+
</button>
|
|
509
|
+
` : ''}
|
|
510
|
+
</div>
|
|
511
|
+
${this.hasSessionSidebar
|
|
299
512
|
? html`
|
|
300
|
-
<
|
|
301
|
-
|
|
513
|
+
<button
|
|
514
|
+
class=${`sessionPanelBackdrop ${this.sessionSidebarOpen ? 'open' : ''}`}
|
|
515
|
+
aria-label="Close session details"
|
|
516
|
+
aria-hidden=${String(!this.sessionSidebarOpen)}
|
|
517
|
+
?inert=${!this.sessionSidebarOpen}
|
|
518
|
+
tabindex=${this.sessionSidebarOpen ? '0' : '-1'}
|
|
519
|
+
@click=${() => void this.closeSessionSidebar()}
|
|
520
|
+
></button>
|
|
521
|
+
<aside
|
|
522
|
+
id="harness-session-panel"
|
|
523
|
+
class=${`todosPanel sessionPanel ${this.sessionSidebarOpen ? 'open' : ''}`}
|
|
524
|
+
aria-label="Session details"
|
|
525
|
+
tabindex="-1"
|
|
526
|
+
@keydown=${(event: KeyboardEvent) => {
|
|
527
|
+
if (event.key !== 'Escape') return;
|
|
528
|
+
event.preventDefault();
|
|
529
|
+
event.stopPropagation();
|
|
530
|
+
void this.closeSessionSidebar();
|
|
531
|
+
}}
|
|
532
|
+
>
|
|
533
|
+
<dees-button
|
|
534
|
+
class="sessionPanelClose"
|
|
535
|
+
size="icon"
|
|
536
|
+
type="ghost"
|
|
537
|
+
icon="lucide:X"
|
|
538
|
+
text="Close session details"
|
|
539
|
+
title="Close session details"
|
|
540
|
+
@clicked=${() => void this.closeSessionSidebar()}
|
|
541
|
+
></dees-button>
|
|
542
|
+
<dees-harness-session-sidebar
|
|
543
|
+
.todos=${this.effectiveTodos}
|
|
544
|
+
.showTasks=${this.showTodosPanel}
|
|
545
|
+
.metrics=${this.sessionMetrics}
|
|
546
|
+
.scratchpad=${this.scratchpad}
|
|
547
|
+
.scratchpadBusy=${this.scratchpadBusy}
|
|
548
|
+
.scratchpadError=${this.scratchpadError}
|
|
549
|
+
.intelligenceEnabled=${this.sessionIntelligenceEnabled}
|
|
550
|
+
.intelligenceExchanges=${this.intelligenceExchanges}
|
|
551
|
+
.intelligenceBusy=${this.intelligenceBusy}
|
|
552
|
+
.intelligenceError=${this.intelligenceError}
|
|
553
|
+
.disabled=${this.disabled}
|
|
554
|
+
></dees-harness-session-sidebar>
|
|
302
555
|
</aside>
|
|
303
556
|
`
|
|
304
557
|
: ''}
|
|
@@ -344,12 +597,14 @@ export class DeesHarnessChat extends DeesElement {
|
|
|
344
597
|
</div>
|
|
345
598
|
<div class="toolbarActions">
|
|
346
599
|
<dees-harness-usage compact .usage=${this.usage}></dees-harness-usage>
|
|
347
|
-
<dees-button
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
600
|
+
<dees-button
|
|
601
|
+
size="icon"
|
|
602
|
+
type="ghost"
|
|
603
|
+
icon="lucide:PanelLeft"
|
|
604
|
+
text="Toggle chat sidebar"
|
|
605
|
+
title="Toggle chat sidebar"
|
|
606
|
+
@clicked=${() => this.emit('harness-toggle-sidebar')}
|
|
607
|
+
></dees-button>
|
|
353
608
|
</div>
|
|
354
609
|
</div>
|
|
355
610
|
`;
|
|
@@ -136,6 +136,46 @@ export class DeesHarnessMessage extends DeesElement {
|
|
|
136
136
|
background: var(--dees-color-bg-secondary);
|
|
137
137
|
}
|
|
138
138
|
|
|
139
|
+
.message.role-assistant {
|
|
140
|
+
position: relative;
|
|
141
|
+
padding: var(--dees-spacing-xs) var(--dees-spacing-md);
|
|
142
|
+
border: 0;
|
|
143
|
+
border-radius: 0;
|
|
144
|
+
background: transparent;
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
.message.role-assistant::before {
|
|
148
|
+
content: '';
|
|
149
|
+
position: absolute;
|
|
150
|
+
inset: 0 auto 0 0;
|
|
151
|
+
width: 1px;
|
|
152
|
+
background: transparent;
|
|
153
|
+
pointer-events: none;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.message.role-assistant.streaming::before {
|
|
157
|
+
background:
|
|
158
|
+
linear-gradient(
|
|
159
|
+
to bottom,
|
|
160
|
+
transparent 40%,
|
|
161
|
+
color-mix(in srgb, var(--dees-color-accent-primary) 85%, transparent) 50%,
|
|
162
|
+
transparent 60%
|
|
163
|
+
) 0 100% / 100% 250% no-repeat;
|
|
164
|
+
animation: assistantActivityScan 2s linear infinite;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
@keyframes assistantActivityScan {
|
|
168
|
+
from { background-position: 0 100%; }
|
|
169
|
+
to { background-position: 0 0; }
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
@media (prefers-reduced-motion: reduce) {
|
|
173
|
+
.message.role-assistant.streaming::before {
|
|
174
|
+
animation: none;
|
|
175
|
+
background: color-mix(in srgb, var(--dees-color-accent-primary) 65%, transparent);
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
|
|
139
179
|
.message.role-user {
|
|
140
180
|
/* chat-like: user turns bind right and size to their content */
|
|
141
181
|
border-left-color: var(--dees-color-accent-primary);
|
|
@@ -210,7 +250,8 @@ export class DeesHarnessMessage extends DeesElement {
|
|
|
210
250
|
vertical-align: text-bottom;
|
|
211
251
|
border-radius: 1px;
|
|
212
252
|
background: var(--dees-color-accent-primary);
|
|
213
|
-
|
|
253
|
+
will-change: opacity;
|
|
254
|
+
animation: harness-cursor-blink 1.2s ease-in-out infinite;
|
|
214
255
|
}
|
|
215
256
|
|
|
216
257
|
@keyframes harness-cursor-blink {
|
|
@@ -385,7 +426,7 @@ export class DeesHarnessMessage extends DeesElement {
|
|
|
385
426
|
}
|
|
386
427
|
const roleClass = `role-${message.role}`;
|
|
387
428
|
return html`
|
|
388
|
-
<div class="message ${roleClass} ${message.error ? 'has-error' : ''}">
|
|
429
|
+
<div class="message ${roleClass} ${message.streaming ? 'streaming' : ''} ${message.error ? 'has-error' : ''}">
|
|
389
430
|
${this.showRole || this.showTimestamp || message.model
|
|
390
431
|
? html`
|
|
391
432
|
<div class="roleRow">
|
|
@@ -50,10 +50,8 @@ export class DeesHarnessReasoning extends DeesElement {
|
|
|
50
50
|
}
|
|
51
51
|
|
|
52
52
|
.reasoning {
|
|
53
|
-
border:
|
|
54
|
-
|
|
55
|
-
corner-shape: var(--dees-corner-shape);
|
|
56
|
-
background: var(--dees-color-bg-tertiary);
|
|
53
|
+
border: 0;
|
|
54
|
+
background: transparent;
|
|
57
55
|
overflow: hidden;
|
|
58
56
|
animation: harness-reasoning-enter var(--dees-transition-default) var(--dees-ease-out);
|
|
59
57
|
}
|
|
@@ -101,7 +99,7 @@ export class DeesHarnessReasoning extends DeesElement {
|
|
|
101
99
|
display: flex;
|
|
102
100
|
align-items: center;
|
|
103
101
|
gap: var(--dees-spacing-sm);
|
|
104
|
-
padding: var(--dees-spacing-xs)
|
|
102
|
+
padding: var(--dees-spacing-xs) 0;
|
|
105
103
|
border: 0;
|
|
106
104
|
background: transparent;
|
|
107
105
|
color: var(--dees-color-text-secondary);
|
|
@@ -165,7 +163,7 @@ export class DeesHarnessReasoning extends DeesElement {
|
|
|
165
163
|
|
|
166
164
|
.body {
|
|
167
165
|
margin: 0;
|
|
168
|
-
padding: 0 var(--dees-spacing-
|
|
166
|
+
padding: 0 0 var(--dees-spacing-sm) calc(12px + var(--dees-spacing-sm));
|
|
169
167
|
color: var(--dees-color-text-secondary);
|
|
170
168
|
white-space: pre-wrap;
|
|
171
169
|
overflow-wrap: anywhere;
|
package/ts_web/elements/00group-harness/dees-harness-session-list/dees-harness-session-list.ts
CHANGED
|
@@ -507,7 +507,10 @@ export class DeesHarnessSessionList extends DeesElement {
|
|
|
507
507
|
.expandToggle {
|
|
508
508
|
display: grid;
|
|
509
509
|
place-items: center;
|
|
510
|
-
|
|
510
|
+
min-width: 27px;
|
|
511
|
+
min-height: 32px;
|
|
512
|
+
margin: 7px 3px 7px 0;
|
|
513
|
+
padding: 0;
|
|
511
514
|
border-radius: 9px;
|
|
512
515
|
color: var(--dees-color-text-muted);
|
|
513
516
|
cursor: pointer;
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { html } from '@design.estate/dees-element';
|
|
2
|
+
|
|
3
|
+
import type {
|
|
4
|
+
IHarnessIntelligenceExchange,
|
|
5
|
+
IHarnessScratchpad,
|
|
6
|
+
IHarnessSessionMetrics,
|
|
7
|
+
IHarnessTodoItem,
|
|
8
|
+
} from '../interfaces.js';
|
|
9
|
+
|
|
10
|
+
const todos: IHarnessTodoItem[] = [
|
|
11
|
+
{ content: 'Inspect current context usage', status: 'completed' },
|
|
12
|
+
{ content: 'Verify the cache-key patch', status: 'in_progress' },
|
|
13
|
+
{ content: 'Prepare the release', status: 'pending' },
|
|
14
|
+
];
|
|
15
|
+
|
|
16
|
+
const metrics: IHarnessSessionMetrics = {
|
|
17
|
+
lifetimeUsedTokens: 184_320,
|
|
18
|
+
compactionCount: 2,
|
|
19
|
+
tokensBeforeLatestCompaction: 112_840,
|
|
20
|
+
currentContextTokens: 47_200,
|
|
21
|
+
maxContextTokens: 128_000,
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
const scratchpad: IHarnessScratchpad = {
|
|
25
|
+
id: 'demo-session',
|
|
26
|
+
text: '- Cache keys use the route manifest hash.\n- Release after staging verification.',
|
|
27
|
+
revision: 4,
|
|
28
|
+
updatedAt: Date.now() - 45_000,
|
|
29
|
+
updatedBy: 'intelligence',
|
|
30
|
+
};
|
|
31
|
+
|
|
32
|
+
const exchanges: IHarnessIntelligenceExchange[] = [{
|
|
33
|
+
id: 'intelligence-1',
|
|
34
|
+
question: 'What remains before release?',
|
|
35
|
+
answer: 'Staging verification is the only remaining task.',
|
|
36
|
+
status: 'completed',
|
|
37
|
+
model: 'gpt-5.6-luna',
|
|
38
|
+
createdAt: Date.now() - 30_000,
|
|
39
|
+
completedAt: Date.now() - 28_000,
|
|
40
|
+
}];
|
|
41
|
+
|
|
42
|
+
export const demoFunc = () => html`
|
|
43
|
+
<style>
|
|
44
|
+
.harnessSessionSidebarDemo {
|
|
45
|
+
width: 280px;
|
|
46
|
+
height: 720px;
|
|
47
|
+
margin: 40px auto;
|
|
48
|
+
border: 1px solid var(--dees-color-border-subtle);
|
|
49
|
+
background: var(--dees-color-bg-secondary);
|
|
50
|
+
}
|
|
51
|
+
</style>
|
|
52
|
+
<div class="harnessSessionSidebarDemo">
|
|
53
|
+
<dees-harness-session-sidebar
|
|
54
|
+
.todos=${todos}
|
|
55
|
+
.metrics=${metrics}
|
|
56
|
+
.scratchpad=${scratchpad}
|
|
57
|
+
.intelligenceEnabled=${true}
|
|
58
|
+
.intelligenceExchanges=${exchanges}
|
|
59
|
+
@harness-scratchpad-save=${(event: CustomEvent) => {
|
|
60
|
+
console.log('harness-scratchpad-save', event.detail);
|
|
61
|
+
}}
|
|
62
|
+
@harness-session-intelligence-ask=${(event: CustomEvent) => {
|
|
63
|
+
console.log('harness-session-intelligence-ask', event.detail);
|
|
64
|
+
}}
|
|
65
|
+
></dees-harness-session-sidebar>
|
|
66
|
+
</div>
|
|
67
|
+
`;
|