@design.estate/dees-catalog 22.1.0 → 22.3.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 +2372 -1369
- package/dist_bundle/bundle.js.map +1 -1
- package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/{chunk-VIN4YGID.js → chunk-IGD4DLG4.js} +3 -3
- package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/{chunk-6I3PIV5F.js → chunk-MK42UYWT.js} +10 -6
- package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/{chunk-6I3PIV5F.js.map → chunk-MK42UYWT.js.map} +1 -1
- package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/{chunk-3SSZ4CDV.js → chunk-RITCTBBY.js} +2 -2
- package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/{de-STYNV6A3.js → de-TN6FRTSU.js} +10 -6
- package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/de-TN6FRTSU.js.map +1 -0
- package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/{dees-modal-PULP7K3X.js → dees-modal-PLLCPO5V.js} +3 -3
- package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/{dees-workspace-terminal-KEQHBOYE.js → dees-workspace-terminal-7N6EXGH6.js} +4 -4
- package/dist_ts_web/00_commitinfo_data.js +1 -1
- package/dist_ts_web/elements/00group-harness/dees-harness-resource-list/dees-harness-resource-list.d.ts +16 -2
- package/dist_ts_web/elements/00group-harness/dees-harness-resource-list/dees-harness-resource-list.demo.js +458 -57
- package/dist_ts_web/elements/00group-harness/dees-harness-resource-list/dees-harness-resource-list.js +67 -34
- package/dist_ts_web/elements/00group-harness/dees-harness-session-list/dees-harness-session-list.d.ts +22 -2
- package/dist_ts_web/elements/00group-harness/dees-harness-session-list/dees-harness-session-list.demo.js +61 -7
- package/dist_ts_web/elements/00group-harness/dees-harness-session-list/dees-harness-session-list.js +273 -27
- package/dist_ts_web/elements/00group-kanban/dees-kanban/dees-kanban.d.ts +12 -0
- package/dist_ts_web/elements/00group-kanban/dees-kanban/dees-kanban.demo.js +24 -2
- package/dist_ts_web/elements/00group-kanban/dees-kanban/dees-kanban.js +54 -7
- package/dist_ts_web/elements/00group-kanban/dees-kanban-activity/dees-kanban-activity.d.ts +13 -1
- package/dist_ts_web/elements/00group-kanban/dees-kanban-activity/dees-kanban-activity.js +80 -12
- package/dist_ts_web/elements/00group-kanban/dees-kanban-card/dees-kanban-card.d.ts +10 -0
- package/dist_ts_web/elements/00group-kanban/dees-kanban-card/dees-kanban-card.js +72 -4
- package/dist_ts_web/elements/00group-kanban/dees-kanban-column/dees-kanban-column.d.ts +12 -0
- package/dist_ts_web/elements/00group-kanban/dees-kanban-column/dees-kanban-column.js +73 -3
- package/dist_ts_web/elements/00group-kanban/kanban.firstload.d.ts +23 -0
- package/dist_ts_web/elements/00group-kanban/kanban.firstload.js +51 -0
- package/dist_ts_web/elements/00group-kanban/kanban.styles.d.ts +8 -0
- package/dist_ts_web/elements/00group-kanban/kanban.styles.js +47 -1
- package/dist_ts_web/i18n/de.d.ts +24 -8
- package/dist_ts_web/i18n/de.js +9 -5
- package/dist_ts_web/i18n/messages.d.ts +24 -8
- package/dist_ts_web/i18n/messages.js +9 -5
- package/package.json +1 -1
- package/readme.md +38 -5
- package/ts_web/00_commitinfo_data.ts +1 -1
- package/ts_web/elements/00group-harness/dees-harness-resource-list/dees-harness-resource-list.demo.ts +504 -98
- package/ts_web/elements/00group-harness/dees-harness-resource-list/dees-harness-resource-list.ts +68 -33
- package/ts_web/elements/00group-harness/dees-harness-session-list/dees-harness-session-list.demo.ts +41 -2
- package/ts_web/elements/00group-harness/dees-harness-session-list/dees-harness-session-list.ts +271 -25
- package/ts_web/elements/00group-kanban/dees-kanban/dees-kanban.demo.ts +23 -1
- package/ts_web/elements/00group-kanban/dees-kanban/dees-kanban.ts +60 -6
- package/ts_web/elements/00group-kanban/dees-kanban-activity/dees-kanban-activity.ts +88 -11
- package/ts_web/elements/00group-kanban/dees-kanban-card/dees-kanban-card.ts +60 -2
- package/ts_web/elements/00group-kanban/dees-kanban-column/dees-kanban-column.ts +61 -1
- package/ts_web/elements/00group-kanban/kanban.firstload.ts +54 -0
- package/ts_web/elements/00group-kanban/kanban.styles.ts +47 -0
- package/ts_web/i18n/de.ts +8 -4
- package/ts_web/i18n/messages.ts +8 -4
- package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/de-STYNV6A3.js.map +0 -1
- /package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/{chunk-VIN4YGID.js.map → chunk-IGD4DLG4.js.map} +0 -0
- /package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/{chunk-3SSZ4CDV.js.map → chunk-RITCTBBY.js.map} +0 -0
- /package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/{dees-modal-PULP7K3X.js.map → dees-modal-PLLCPO5V.js.map} +0 -0
- /package/dist_bundle/chunks/U6Ua8p1giFoD1s7vrUZUdpbg/{dees-workspace-terminal-KEQHBOYE.js.map → dees-workspace-terminal-7N6EXGH6.js.map} +0 -0
|
@@ -17,7 +17,9 @@ import type {
|
|
|
17
17
|
TKanbanLink,
|
|
18
18
|
TKanbanPriority,
|
|
19
19
|
} from '../interfaces.js';
|
|
20
|
-
import { kanbanFeedStyles, kanbanStyles } from '../kanban.styles.js';
|
|
20
|
+
import { kanbanFeedStyles, kanbanSkeletonStyles, kanbanStyles } from '../kanban.styles.js';
|
|
21
|
+
import { KanbanFirstLoadController } from '../kanban.firstload.js';
|
|
22
|
+
import { visuallyHidden } from '../../00visuallyhidden.js';
|
|
21
23
|
import {
|
|
22
24
|
kanbanEvent,
|
|
23
25
|
kanbanLinkText,
|
|
@@ -33,6 +35,8 @@ declare global {
|
|
|
33
35
|
}
|
|
34
36
|
}
|
|
35
37
|
|
|
38
|
+
/** The placeholder entries a first load draws. */
|
|
39
|
+
const placeholderEntries = 3;
|
|
36
40
|
/** A changed field's value that is not there. */
|
|
37
41
|
const noValue = '—';
|
|
38
42
|
/** The characters of a changed text the history shows before it cuts the text short. */
|
|
@@ -55,11 +59,24 @@ interface IChangeLine {
|
|
|
55
59
|
value: string;
|
|
56
60
|
}
|
|
57
61
|
|
|
58
|
-
/**
|
|
62
|
+
/**
|
|
63
|
+
* A ticket's history: who changed what, oldest first, with the fields each change touched. Its first
|
|
64
|
+
* load, `loading` without entries, draws placeholder entries once it has taken 200 ms and says it is
|
|
65
|
+
* still loading after `stillLoadingAfter`; entries that are already there stay while more load.
|
|
66
|
+
*/
|
|
59
67
|
@customElement('dees-kanban-activity')
|
|
60
68
|
export class DeesKanbanActivity extends DeesElement {
|
|
69
|
+
/** How long a first load runs, in milliseconds, before the history says it is still loading. */
|
|
70
|
+
public static stillLoadingAfter = 10_000;
|
|
71
|
+
|
|
61
72
|
private readonly t = dcLocalize(this);
|
|
62
73
|
|
|
74
|
+
private readonly firstLoad = new KanbanFirstLoadController(
|
|
75
|
+
this,
|
|
76
|
+
() => this.isFirstLoad(),
|
|
77
|
+
() => DeesKanbanActivity.stillLoadingAfter,
|
|
78
|
+
);
|
|
79
|
+
|
|
63
80
|
@property({ type: String, reflect: true })
|
|
64
81
|
accessor ticketId = '';
|
|
65
82
|
|
|
@@ -92,6 +109,7 @@ export class DeesKanbanActivity extends DeesElement {
|
|
|
92
109
|
public static styles = [
|
|
93
110
|
...kanbanStyles,
|
|
94
111
|
kanbanFeedStyles,
|
|
112
|
+
kanbanSkeletonStyles,
|
|
95
113
|
css`
|
|
96
114
|
li {
|
|
97
115
|
grid-template-columns: 24px minmax(0, 1fr);
|
|
@@ -150,18 +168,45 @@ export class DeesKanbanActivity extends DeesElement {
|
|
|
150
168
|
min-width: 0;
|
|
151
169
|
overflow-wrap: anywhere;
|
|
152
170
|
}
|
|
171
|
+
|
|
172
|
+
.loadingStatus {
|
|
173
|
+
${visuallyHidden}
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
/* A placeholder entry's lines, of differing lengths from entry to entry. */
|
|
177
|
+
.placeholderAuthor {
|
|
178
|
+
width: 10ch;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
.placeholderWhat {
|
|
182
|
+
width: 18ch;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
li:nth-child(3n + 2) .placeholderWhat {
|
|
186
|
+
width: 12ch;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
li:nth-child(3n) .placeholderWhat {
|
|
190
|
+
width: 22ch;
|
|
191
|
+
}
|
|
192
|
+
|
|
193
|
+
.placeholderTime {
|
|
194
|
+
width: 12ch;
|
|
195
|
+
}
|
|
153
196
|
`,
|
|
154
197
|
];
|
|
155
198
|
|
|
156
199
|
public render(): TemplateResult {
|
|
157
|
-
const entries = this.
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
200
|
+
const entries = this.entries();
|
|
201
|
+
const firstLoad = this.isFirstLoad();
|
|
202
|
+
const stillLoading = this.firstLoad.stillLoading;
|
|
203
|
+
const skeleton = `skeleton ${stillLoading ? 'stalled' : ''}`;
|
|
161
204
|
return html`${this.showHeader
|
|
162
205
|
? html`<header>
|
|
163
206
|
<h3>${this.t('kanban.history')}</h3>
|
|
164
|
-
|
|
207
|
+
${firstLoad
|
|
208
|
+
? html`<span class=${skeleton} aria-hidden="true"><span class="count skeletonFill"></span></span>`
|
|
209
|
+
: html`<span class="count">${entries.length}</span>`}
|
|
165
210
|
<span class="spacer"></span>
|
|
166
211
|
<dees-button
|
|
167
212
|
class="refresh"
|
|
@@ -175,16 +220,48 @@ export class DeesKanbanActivity extends DeesElement {
|
|
|
175
220
|
></dees-button>
|
|
176
221
|
</header>`
|
|
177
222
|
: ''}
|
|
178
|
-
|
|
179
|
-
?
|
|
180
|
-
: ''}
|
|
223
|
+
<p class="loadingStatus" role="status">${firstLoad
|
|
224
|
+
? this.t(stillLoading ? 'kanban.stillLoadingHistory' : 'kanban.loadingHistory')
|
|
225
|
+
: ''}</p>
|
|
226
|
+
${firstLoad && stillLoading
|
|
227
|
+
? html`<p class="caption" aria-hidden="true">${this.t('kanban.stillLoadingHistory')}</p>`
|
|
228
|
+
: !firstLoad && this.loading
|
|
229
|
+
? html`<p class="caption" role="status">${this.t('kanban.loadingHistory')}</p>`
|
|
230
|
+
: ''}
|
|
181
231
|
${this.error ? html`<p class="error" role="alert">${this.error}</p>` : ''}
|
|
182
|
-
<ol aria-label=${this.t('kanban.history')}
|
|
232
|
+
<ol aria-label=${this.t('kanban.history')} aria-busy=${this.loading ? 'true' : 'false'}>${firstLoad
|
|
233
|
+
? Array.from({ length: placeholderEntries }, () => this.renderPlaceholderEntry(skeleton))
|
|
234
|
+
: entries.map(entry => this.renderEntry(entry))}</ol>
|
|
183
235
|
${!entries.length && !this.loading && !this.error
|
|
184
236
|
? html`<p class="empty">${this.t('kanban.noHistory')}</p>`
|
|
185
237
|
: ''}`;
|
|
186
238
|
}
|
|
187
239
|
|
|
240
|
+
/** The history's first load runs: loading, with no entries of the ticket yet and nothing failed. */
|
|
241
|
+
private isFirstLoad(): boolean {
|
|
242
|
+
return this.loading && !this.error && this.entries().length === 0;
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
private entries(): IKanbanActivity[] {
|
|
246
|
+
return this.activity
|
|
247
|
+
.filter(entry => entry.ticketId === this.ticketId)
|
|
248
|
+
.slice()
|
|
249
|
+
.sort((a, b) => Date.parse(a.createdAt) - Date.parse(b.createdAt));
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
/** A placeholder entry, on an entry's own glyph and meta row. */
|
|
253
|
+
private renderPlaceholderEntry(skeleton: string): TemplateResult {
|
|
254
|
+
return html`<li class=${skeleton} aria-hidden="true">
|
|
255
|
+
<span class="glyph skeletonFill"></span><div>
|
|
256
|
+
<div class="row meta">
|
|
257
|
+
<span><span class="author skeletonFill skeletonBar placeholderAuthor"></span> <span
|
|
258
|
+
class="what skeletonFill skeletonBar placeholderWhat"
|
|
259
|
+
></span></span>
|
|
260
|
+
<time class="skeletonFill skeletonBar placeholderTime"></time>
|
|
261
|
+
</div>
|
|
262
|
+
</div></li>`;
|
|
263
|
+
}
|
|
264
|
+
|
|
188
265
|
private renderEntry(entry: IKanbanActivity): TemplateResult {
|
|
189
266
|
const lines = this.changeLines(entry);
|
|
190
267
|
return html`<li>
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { DeesElement, customElement, property, html, css } from '@design.estate/dees-element';
|
|
2
2
|
import { dcLocalize } from '../../../i18n/localize.js';
|
|
3
3
|
import type { IKanbanAutoLabel, IKanbanTicket, IKanbanColumn } from '../interfaces.js';
|
|
4
|
-
import { kanbanStyles } from '../kanban.styles.js';
|
|
4
|
+
import { kanbanSkeletonStyles, kanbanStyles } from '../kanban.styles.js';
|
|
5
5
|
import { kanbanEvent, kanbanInitials, kanbanPriorityIcon, renderKanbanAutoLabels } from '../kanban.helpers.js';
|
|
6
6
|
import '../../00group-button/dees-button/dees-button.js';
|
|
7
7
|
import '../../00group-utility/dees-icon/dees-icon.js';
|
|
@@ -50,8 +50,21 @@ export class DeesKanbanCard extends DeesElement {
|
|
|
50
50
|
@property({ attribute: false })
|
|
51
51
|
accessor pointerManaged = false;
|
|
52
52
|
|
|
53
|
+
/**
|
|
54
|
+
* A placeholder for a card still loading, in the card's own shape: a key, a line of title and a
|
|
55
|
+
* footer with a label and an assignee, hidden from assistive technology. The board draws them on
|
|
56
|
+
* its first load; `ticket` is not read.
|
|
57
|
+
*/
|
|
58
|
+
@property({ type: Boolean, reflect: true })
|
|
59
|
+
accessor placeholder = false;
|
|
60
|
+
|
|
61
|
+
/** The placeholder's load runs long: it holds still. */
|
|
62
|
+
@property({ type: Boolean, reflect: true })
|
|
63
|
+
accessor stalled = false;
|
|
64
|
+
|
|
53
65
|
public static styles = [
|
|
54
66
|
...kanbanStyles,
|
|
67
|
+
kanbanSkeletonStyles,
|
|
55
68
|
css`
|
|
56
69
|
article {
|
|
57
70
|
padding: 12px;
|
|
@@ -62,7 +75,7 @@ export class DeesKanbanCard extends DeesElement {
|
|
|
62
75
|
box-shadow: var(--dees-shadow-xs);
|
|
63
76
|
}
|
|
64
77
|
|
|
65
|
-
article:hover {
|
|
78
|
+
article:not(.skeleton):hover {
|
|
66
79
|
border-color: var(--dees-color-border-strong);
|
|
67
80
|
}
|
|
68
81
|
|
|
@@ -256,6 +269,35 @@ export class DeesKanbanCard extends DeesElement {
|
|
|
256
269
|
color: var(--dees-color-link);
|
|
257
270
|
}
|
|
258
271
|
|
|
272
|
+
/* A placeholder's lines, of differing lengths from card to card, as real titles are. */
|
|
273
|
+
.skeleton .title {
|
|
274
|
+
cursor: default;
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
.placeholderKey {
|
|
278
|
+
width: 7ch;
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
.placeholderTitle {
|
|
282
|
+
width: 82%;
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
:host(:nth-child(3n + 2)) .placeholderTitle {
|
|
286
|
+
width: 58%;
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
:host(:nth-child(3n)) .placeholderTitle {
|
|
290
|
+
width: 70%;
|
|
291
|
+
}
|
|
292
|
+
|
|
293
|
+
.placeholderLabel {
|
|
294
|
+
width: 9ch;
|
|
295
|
+
}
|
|
296
|
+
|
|
297
|
+
.placeholderName {
|
|
298
|
+
width: 8ch;
|
|
299
|
+
}
|
|
300
|
+
|
|
259
301
|
@media (pointer: coarse) {
|
|
260
302
|
.move::part(button) {
|
|
261
303
|
width: 32px;
|
|
@@ -276,6 +318,7 @@ export class DeesKanbanCard extends DeesElement {
|
|
|
276
318
|
private readonly t = dcLocalize(this);
|
|
277
319
|
|
|
278
320
|
public render() {
|
|
321
|
+
if (this.placeholder) return this.renderPlaceholder();
|
|
279
322
|
const ticket = this.ticket;
|
|
280
323
|
if (!ticket) return html``;
|
|
281
324
|
const completed = this.subtasks.filter(task =>
|
|
@@ -382,4 +425,19 @@ export class DeesKanbanCard extends DeesElement {
|
|
|
382
425
|
: ''}
|
|
383
426
|
</article>`;
|
|
384
427
|
}
|
|
428
|
+
|
|
429
|
+
/** The placeholder card: each line on the card's own boxes, so the card that replaces it takes its place. */
|
|
430
|
+
private renderPlaceholder() {
|
|
431
|
+
return html`<article class="skeleton ${this.stalled ? 'stalled' : ''}" aria-hidden="true">
|
|
432
|
+
<div class="meta"><span class="skeletonFill skeletonBar placeholderKey"></span></div>
|
|
433
|
+
<div class="title"><span class="skeletonFill skeletonBar placeholderTitle"></span></div>
|
|
434
|
+
<div class="row footer">
|
|
435
|
+
<span class="badge skeletonFill placeholderLabel">\u200b</span>
|
|
436
|
+
<span class="assignee">
|
|
437
|
+
<span class="avatar skeletonFill"></span>
|
|
438
|
+
<span class="skeletonFill skeletonBar placeholderName"></span>
|
|
439
|
+
</span>
|
|
440
|
+
</div>
|
|
441
|
+
</article>`;
|
|
442
|
+
}
|
|
385
443
|
}
|
|
@@ -12,7 +12,7 @@ import { ScrollEdgeShadowController, scrollEdgeFadeStyles } from '../../00scroll
|
|
|
12
12
|
import { OverlayScrollbarController, overlayScrollbarStyles } from '../../00scrollbars.js';
|
|
13
13
|
import type { IKanbanAutoLabel, IKanbanColumn, IKanbanProject, IKanbanTicket } from '../interfaces.js';
|
|
14
14
|
import type { IKanbanMotion } from '../kanban.dragcontroller.js';
|
|
15
|
-
import { kanbanStyles } from '../kanban.styles.js';
|
|
15
|
+
import { kanbanSkeletonStyles, kanbanStyles } from '../kanban.styles.js';
|
|
16
16
|
import { kanbanEvent, kanbanProjectName, sortKanbanTickets } from '../kanban.helpers.js';
|
|
17
17
|
import '../dees-kanban-card/dees-kanban-card.js';
|
|
18
18
|
|
|
@@ -75,6 +75,17 @@ export class DeesKanbanColumn extends DeesElement {
|
|
|
75
75
|
@property({ attribute: false })
|
|
76
76
|
accessor pointerManaged = false;
|
|
77
77
|
|
|
78
|
+
/**
|
|
79
|
+
* Placeholder cards the board draws while its first load runs, in place of the column's cards and
|
|
80
|
+
* its count. Without a `column`, the header is a placeholder too: a column still to be named.
|
|
81
|
+
*/
|
|
82
|
+
@property({ type: Number, reflect: true })
|
|
83
|
+
accessor placeholderCards = 0;
|
|
84
|
+
|
|
85
|
+
/** The placeholders' load runs long: they hold still. */
|
|
86
|
+
@property({ type: Boolean, reflect: true })
|
|
87
|
+
accessor placeholderStalled = false;
|
|
88
|
+
|
|
78
89
|
@state()
|
|
79
90
|
private accessor nativeDropBefore: string | undefined;
|
|
80
91
|
|
|
@@ -104,6 +115,7 @@ export class DeesKanbanColumn extends DeesElement {
|
|
|
104
115
|
|
|
105
116
|
public static styles = [
|
|
106
117
|
...kanbanStyles,
|
|
118
|
+
kanbanSkeletonStyles,
|
|
107
119
|
scrollEdgeFadeStyles,
|
|
108
120
|
overlayScrollbarStyles,
|
|
109
121
|
css`
|
|
@@ -234,6 +246,23 @@ export class DeesKanbanColumn extends DeesElement {
|
|
|
234
246
|
margin-top: 8px;
|
|
235
247
|
}
|
|
236
248
|
|
|
249
|
+
/* A placeholder column's name, of differing lengths from column to column. */
|
|
250
|
+
.placeholderTitle {
|
|
251
|
+
width: 12ch;
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
:host(:nth-child(4n + 2)) .placeholderTitle {
|
|
255
|
+
width: 9ch;
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
:host(:nth-child(4n + 3)) .placeholderTitle {
|
|
259
|
+
width: 14ch;
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
:host(:nth-child(4n)) .placeholderTitle {
|
|
263
|
+
width: 7ch;
|
|
264
|
+
}
|
|
265
|
+
|
|
237
266
|
@media (prefers-reduced-motion: reduce) {
|
|
238
267
|
section {
|
|
239
268
|
transition: none;
|
|
@@ -259,6 +288,7 @@ export class DeesKanbanColumn extends DeesElement {
|
|
|
259
288
|
}
|
|
260
289
|
|
|
261
290
|
public render() {
|
|
291
|
+
if (this.placeholderCards > 0) return this.renderPlaceholder();
|
|
262
292
|
if (!this.column) return html``;
|
|
263
293
|
const motion = this.motion;
|
|
264
294
|
const ordered = sortKanbanTickets(this.tickets).filter(
|
|
@@ -416,6 +446,36 @@ export class DeesKanbanColumn extends DeesElement {
|
|
|
416
446
|
</section>`;
|
|
417
447
|
}
|
|
418
448
|
|
|
449
|
+
/**
|
|
450
|
+
* The column while the board's first load runs: its own header, or a placeholder one, over
|
|
451
|
+
* placeholder cards in the stack the cards will fill. Nothing in it takes a drop.
|
|
452
|
+
*/
|
|
453
|
+
private renderPlaceholder() {
|
|
454
|
+
const skeleton = `skeleton ${this.placeholderStalled ? 'stalled' : ''}`;
|
|
455
|
+
const cards = Array.from({ length: this.placeholderCards }, () => html`<dees-kanban-card
|
|
456
|
+
placeholder
|
|
457
|
+
.stalled=${this.placeholderStalled}
|
|
458
|
+
></dees-kanban-card>`);
|
|
459
|
+
const content = html`<header>
|
|
460
|
+
${this.column
|
|
461
|
+
? html`<span class="status ${this.column.done ? 'done' : ''}" aria-hidden="true"></span>
|
|
462
|
+
<h3>${this.column.title}</h3>`
|
|
463
|
+
: html`<span class="status ${skeleton}" aria-hidden="true"></span>
|
|
464
|
+
<h3 class=${skeleton} aria-hidden="true"><span
|
|
465
|
+
class="skeletonFill skeletonBar placeholderTitle"
|
|
466
|
+
></span></h3>`}
|
|
467
|
+
<span class=${skeleton} aria-hidden="true"><span class="count skeletonFill"></span></span>
|
|
468
|
+
</header>
|
|
469
|
+
<div class="bodyFrame">
|
|
470
|
+
<div class="body">
|
|
471
|
+
<div class="stack" aria-hidden="true">${cards}</div>
|
|
472
|
+
</div>
|
|
473
|
+
</div>`;
|
|
474
|
+
return this.column
|
|
475
|
+
? html`<section aria-label=${this.column.title}>${content}</section>`
|
|
476
|
+
: html`<section aria-hidden="true">${content}</section>`;
|
|
477
|
+
}
|
|
478
|
+
|
|
419
479
|
private toggle(): void {
|
|
420
480
|
kanbanEvent(this, 'kanban-column-toggle', { columnId: this.column!.id });
|
|
421
481
|
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import type { DeesElement } from '@design.estate/dees-element';
|
|
2
|
+
import type { TReactiveController } from '../00controller.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Counts a first load towards its "still loading", as the catalog's session list does: while
|
|
6
|
+
* `isFirstLoad()` holds — loading, with nothing to show yet — the host draws placeholders, and once
|
|
7
|
+
* it has held for `stillLoadingAfter()` milliseconds, `stillLoading` turns true and the host
|
|
8
|
+
* renders again to say so. Ending the load, or content arriving, forgets the count; a first load
|
|
9
|
+
* under way when the host left the page counts again from its return.
|
|
10
|
+
*/
|
|
11
|
+
export class KanbanFirstLoadController implements TReactiveController {
|
|
12
|
+
private timer: ReturnType<typeof setTimeout> | undefined;
|
|
13
|
+
private stalled = false;
|
|
14
|
+
|
|
15
|
+
constructor(
|
|
16
|
+
private readonly host: DeesElement,
|
|
17
|
+
private readonly isFirstLoad: () => boolean,
|
|
18
|
+
private readonly stillLoadingAfter: () => number,
|
|
19
|
+
) {
|
|
20
|
+
host.addController(this);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
/** The first load has run past `stillLoadingAfter()`. */
|
|
24
|
+
public get stillLoading(): boolean {
|
|
25
|
+
return this.stalled;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
public hostConnected(): void {
|
|
29
|
+
if (this.isFirstLoad()) this.host.requestUpdate();
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
public hostUpdate(): void {
|
|
33
|
+
if (!this.host.isConnected || !this.isFirstLoad()) {
|
|
34
|
+
this.clear();
|
|
35
|
+
return;
|
|
36
|
+
}
|
|
37
|
+
if (this.stalled || this.timer) return;
|
|
38
|
+
this.timer = setTimeout(() => {
|
|
39
|
+
this.timer = undefined;
|
|
40
|
+
this.stalled = true;
|
|
41
|
+
this.host.requestUpdate();
|
|
42
|
+
}, this.stillLoadingAfter());
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
public hostDisconnected(): void {
|
|
46
|
+
this.clear();
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
private clear(): void {
|
|
50
|
+
if (this.timer) clearTimeout(this.timer);
|
|
51
|
+
this.timer = undefined;
|
|
52
|
+
this.stalled = false;
|
|
53
|
+
}
|
|
54
|
+
}
|
|
@@ -237,3 +237,50 @@ export const kanbanFeedStyles = css`
|
|
|
237
237
|
color: var(--dees-color-text-secondary);
|
|
238
238
|
}
|
|
239
239
|
`;
|
|
240
|
+
|
|
241
|
+
/**
|
|
242
|
+
* A first load's placeholders, as the catalog's session list and table draw theirs. A `.skeleton`
|
|
243
|
+
* stays invisible for its first 200 ms, so a quick load never flashes it. A `.skeletonFill` takes
|
|
244
|
+
* the theme's placeholder fill and breathes with its loading pulse, and holds still inside a
|
|
245
|
+
* `.stalled` skeleton, a load that runs long, and under reduced motion. A `.skeletonBar` is a line
|
|
246
|
+
* of text: as tall as the capitals of the font it stands in for; shapes keep their own class.
|
|
247
|
+
*/
|
|
248
|
+
export const kanbanSkeletonStyles = css`
|
|
249
|
+
.skeleton {
|
|
250
|
+
animation: dees-kanban-skeleton-reveal 1ms linear 200ms both;
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
@keyframes dees-kanban-skeleton-reveal {
|
|
254
|
+
from { visibility: hidden; }
|
|
255
|
+
to { visibility: visible; }
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
.skeletonFill {
|
|
259
|
+
background: var(--dees-color-fill-secondary);
|
|
260
|
+
animation: dees-kanban-skeleton var(--dees-loading-pulse-duration) var(--dees-ease-standard) infinite;
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
.skeletonBar {
|
|
264
|
+
display: inline-block;
|
|
265
|
+
vertical-align: middle;
|
|
266
|
+
max-width: 100%;
|
|
267
|
+
height: 1cap;
|
|
268
|
+
border-radius: var(--dees-radius-full);
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
.skeleton.stalled .skeletonFill,
|
|
272
|
+
.skeleton.stalled.skeletonFill {
|
|
273
|
+
animation: none;
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
@keyframes dees-kanban-skeleton {
|
|
277
|
+
0%, 100% { opacity: 1; }
|
|
278
|
+
50% { opacity: var(--dees-loading-pulse-opacity); }
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
@media (prefers-reduced-motion: reduce) {
|
|
282
|
+
.skeletonFill {
|
|
283
|
+
animation: none;
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
`;
|
package/ts_web/i18n/de.ts
CHANGED
|
@@ -863,6 +863,7 @@ export default dcMessages.translation('de', {
|
|
|
863
863
|
'kanban.openEpic': 'Epic öffnen',
|
|
864
864
|
'kanban.newTicket': '{kind, select, epic {Neues Epic} task {Neue Aufgabe} subtask {Neue Teilaufgabe} other {Neues Ticket}}',
|
|
865
865
|
'kanban.loading': 'Board wird geladen …',
|
|
866
|
+
'kanban.stillLoading': 'Board wird noch geladen …',
|
|
866
867
|
'kanban.opening': 'Ticket wird geöffnet …',
|
|
867
868
|
'kanban.noColumns': 'Keine Spalten eingerichtet.',
|
|
868
869
|
'kanban.ticketUnavailable': 'Dieses Ticket ist nicht verfügbar, oder Sie haben keinen Zugriff darauf.',
|
|
@@ -947,6 +948,7 @@ export default dcMessages.translation('de', {
|
|
|
947
948
|
'kanban.history': 'Verlauf',
|
|
948
949
|
'kanban.feed': 'Kommentare oder Verlauf',
|
|
949
950
|
'kanban.loadingHistory': 'Verlauf wird geladen …',
|
|
951
|
+
'kanban.stillLoadingHistory': 'Verlauf wird noch geladen …',
|
|
950
952
|
'kanban.noHistory': 'Noch kein Verlauf.',
|
|
951
953
|
'kanban.activity': '{action, select, created {hat das Ticket erstellt} updated {hat das Ticket geändert} moved {hat das Ticket verschoben} reordered {hat die Position des Tickets geändert} commented {hat kommentiert} asked {hat eine Frage gestellt} answered {hat eine Frage beantwortet} linked {hat einen Link hinzugefügt} other {hat das Ticket geändert}}',
|
|
952
954
|
'kanban.activityMoved': 'hat das Ticket von {from} nach {to} verschoben',
|
|
@@ -1367,14 +1369,15 @@ export default dcMessages.translation('de', {
|
|
|
1367
1369
|
'usage.compact': '<total>{count}</total> Tokens',
|
|
1368
1370
|
'usage.in': '{count} ein',
|
|
1369
1371
|
'usage.out': '{count} aus',
|
|
1370
|
-
'resourcelist.empty': 'Noch keine Unterhaltungen.',
|
|
1372
|
+
'resourcelist.empty': '{kind, select, terminal {Noch keine Terminals.} browser {Noch keine Browser.} workspace {Noch keine Arbeitsbereiche.} resource {Noch keine Ressourcen.} none {Noch keine Unterhaltungen.} other {Noch keine Unterhaltungen.}}',
|
|
1371
1373
|
'resourcelist.dropHere': 'Hier ablegen',
|
|
1372
1374
|
'resourcelist.searchAll': 'Unterhaltungen und Ressourcen durchsuchen',
|
|
1373
|
-
'resourcelist.searchResources': 'Ressourcen durchsuchen',
|
|
1375
|
+
'resourcelist.searchResources': '{kind, select, terminal {Terminals durchsuchen} browser {Browser durchsuchen} workspace {Arbeitsbereiche durchsuchen} resource {Ressourcen durchsuchen} other {Ressourcen durchsuchen}}',
|
|
1376
|
+
'resourcelist.search': 'Suchen …',
|
|
1374
1377
|
'resourcelist.newGroup': 'Neue Gruppe',
|
|
1375
|
-
'resourcelist.loading': 'Unterhaltungen werden geladen …',
|
|
1378
|
+
'resourcelist.loading': '{kind, select, conversation {Unterhaltungen werden geladen …} terminal {Terminals werden geladen …} browser {Browser werden geladen …} workspace {Arbeitsbereiche werden geladen …} resource {Ressourcen werden geladen …} none {Wird geladen …} other {Wird geladen …}}',
|
|
1376
1379
|
'resourcelist.noMatchAll': 'Keine Unterhaltungen oder Ressourcen passen zu dieser Suche.',
|
|
1377
|
-
'resourcelist.noMatchResources': 'Keine Ressourcen passen zu dieser Suche.',
|
|
1380
|
+
'resourcelist.noMatchResources': '{kind, select, terminal {Keine Terminals passen zu dieser Suche.} browser {Keine Browser passen zu dieser Suche.} workspace {Keine Arbeitsbereiche passen zu dieser Suche.} resource {Keine Ressourcen passen zu dieser Suche.} other {Keine Ressourcen passen zu dieser Suche.}}',
|
|
1378
1381
|
'resourcelist.noMatch': 'Keine Unterhaltungen passen zu dieser Suche.',
|
|
1379
1382
|
'resourcelist.ungrouped': 'Ohne Gruppe',
|
|
1380
1383
|
'resourcelist.attention': '{count, number} erfordern Aufmerksamkeit',
|
|
@@ -1409,6 +1412,7 @@ export default dcMessages.translation('de', {
|
|
|
1409
1412
|
'sessionlist.label': 'Sitzungen',
|
|
1410
1413
|
'sessionlist.empty': 'Noch keine Sitzungen.',
|
|
1411
1414
|
'sessionlist.loading': 'Sitzungen werden geladen …',
|
|
1415
|
+
'sessionlist.stillLoading': 'Sitzungen werden noch geladen …',
|
|
1412
1416
|
'sessionlist.group': '{state, select, needs_input {Wartet auf Eingabe} working {In Arbeit} failed {Fehlgeschlagen} completed {Abgeschlossen} other {Sitzungen}}',
|
|
1413
1417
|
'sessionlist.harness': '{harness, select, claude {Claude Code} codex {Codex} flex {FlexHarness} opencode {OpenCode} other {Agent}}',
|
|
1414
1418
|
'sessionlist.indicator': '{harness} · {state, select, needs_input {wartet auf Eingabe} working {in Arbeit} failed {fehlgeschlagen} completed {abgeschlossen} other {aktiv}}',
|
package/ts_web/i18n/messages.ts
CHANGED
|
@@ -897,6 +897,7 @@ export const dcMessages = plugins.smarti18n.defineCatalog({
|
|
|
897
897
|
'kanban.openEpic': { message: 'Open epic', description: 'The button that opens the epic the board is filtered by.' },
|
|
898
898
|
'kanban.newTicket': { message: '{kind, select, epic {New epic} task {New task} subtask {New subtask} other {New ticket}}', description: 'The buttons that create a ticket, and the heading of the dialog that names it; {kind} is the kind of ticket.' },
|
|
899
899
|
'kanban.loading': { message: 'Loading board…', description: 'Said while the board loads.' },
|
|
900
|
+
'kanban.stillLoading': { message: 'Still loading board…', description: 'Said when the first load of the board takes long.' },
|
|
900
901
|
'kanban.opening': { message: 'Opening ticket…', description: 'Said while a ticket opens.' },
|
|
901
902
|
'kanban.noColumns': { message: 'No columns configured.', description: 'Said by a board without columns.' },
|
|
902
903
|
'kanban.ticketUnavailable': { message: 'This ticket is unavailable or you do not have access.', description: 'Said when a ticket could not be opened.' },
|
|
@@ -981,6 +982,7 @@ export const dcMessages = plugins.smarti18n.defineCatalog({
|
|
|
981
982
|
'kanban.history': { message: 'History', description: 'The heading over a ticket\'s history, and the switch that shows it.' },
|
|
982
983
|
'kanban.feed': { message: 'Comments or history', description: 'The switch between a ticket\'s comments and its history (its name).' },
|
|
983
984
|
'kanban.loadingHistory': { message: 'Loading history…', description: 'Said while a ticket\'s history loads.' },
|
|
985
|
+
'kanban.stillLoadingHistory': { message: 'Still loading history…', description: 'Said when the first load of a ticket\'s history takes long.' },
|
|
984
986
|
'kanban.noHistory': { message: 'No history yet.', description: 'Said by a ticket without history.' },
|
|
985
987
|
'kanban.activity': { message: '{action, select, created {created the ticket} updated {changed the ticket} moved {moved the ticket} reordered {changed the ticket’s position} commented {commented} asked {asked a question} answered {answered a question} linked {added a link} other {changed the ticket}}', description: 'What a person did to a ticket, after their name in its history; {action} is the kind of change.' },
|
|
986
988
|
'kanban.activityMoved': { message: 'moved the ticket from {from} to {to}', description: 'A move in a ticket\'s history, after the person\'s name; {from} and {to} are columns.' },
|
|
@@ -1441,14 +1443,15 @@ export const dcMessages = plugins.smarti18n.defineCatalog({
|
|
|
1441
1443
|
'usage.out': { message: '{count} out', description: 'The usage chip: tokens written; {count} is formatted.' },
|
|
1442
1444
|
|
|
1443
1445
|
// dees-harness-resource-list
|
|
1444
|
-
'resourcelist.empty': { message: 'No conversations yet.', description: 'Said by an empty list, while the host names nothing.' },
|
|
1446
|
+
'resourcelist.empty': { message: '{kind, select, terminal {No terminals yet.} browser {No browsers yet.} workspace {No workspaces yet.} resource {No resources yet.} none {No conversations yet.} other {No conversations yet.}}', description: 'Said by an empty list, while the host names nothing; {kind} is what the list shows.' },
|
|
1445
1447
|
'resourcelist.dropHere': { message: 'Drop here', description: 'The gap where a dragged row will land.' },
|
|
1446
1448
|
'resourcelist.searchAll': { message: 'Search conversations and resources', description: 'The search field while the list shows resources too.' },
|
|
1447
|
-
'resourcelist.searchResources': { message: 'Search resources', description: 'The search field while the list shows resources only.' },
|
|
1449
|
+
'resourcelist.searchResources': { message: '{kind, select, terminal {Search terminals} browser {Search browsers} workspace {Search workspaces} resource {Search resources} other {Search resources}}', description: 'The search field while the list shows resources only; {kind} is their kind.' },
|
|
1450
|
+
'resourcelist.search': { message: 'Search…', description: 'The search field while the list cannot tell what it shows.' },
|
|
1448
1451
|
'resourcelist.newGroup': { message: 'New group', description: 'The button that creates a group.' },
|
|
1449
|
-
'resourcelist.loading': { message: 'Loading conversations…', description: 'Said while the list loads.' },
|
|
1452
|
+
'resourcelist.loading': { message: '{kind, select, conversation {Loading conversations…} terminal {Loading terminals…} browser {Loading browsers…} workspace {Loading workspaces…} resource {Loading resources…} none {Loading…} other {Loading…}}', description: 'Said while the list loads; {kind} is what the list shows, when it can tell.' },
|
|
1450
1453
|
'resourcelist.noMatchAll': { message: 'No conversations or resources match this search.', description: 'Said when nothing matches the search.' },
|
|
1451
|
-
'resourcelist.noMatchResources': { message: 'No resources match this search.', description: 'Said when no resource matches the search and there are no conversations.' },
|
|
1454
|
+
'resourcelist.noMatchResources': { message: '{kind, select, terminal {No terminals match this search.} browser {No browsers match this search.} workspace {No workspaces match this search.} resource {No resources match this search.} other {No resources match this search.}}', description: 'Said when no resource matches the search and there are no conversations; {kind} is their kind.' },
|
|
1452
1455
|
'resourcelist.noMatch': { message: 'No conversations match this search.', description: 'Said when no conversation matches the search.' },
|
|
1453
1456
|
'resourcelist.ungrouped': { message: 'Ungrouped', description: 'The section of rows in no group.' },
|
|
1454
1457
|
'resourcelist.attention': { message: '{count, number} need attention', description: 'A group\'s badge (its name): rows that need attention.' },
|
|
@@ -1484,6 +1487,7 @@ export const dcMessages = plugins.smarti18n.defineCatalog({
|
|
|
1484
1487
|
'sessionlist.label': { message: 'Sessions', description: 'The list of every session (its name).' },
|
|
1485
1488
|
'sessionlist.empty': { message: 'No sessions yet.', description: 'Said by an empty list, while the host names nothing.' },
|
|
1486
1489
|
'sessionlist.loading': { message: 'Loading sessions…', description: 'Said while the list loads.' },
|
|
1490
|
+
'sessionlist.stillLoading': { message: 'Still loading sessions…', description: 'Said when the first load of the list takes long.' },
|
|
1487
1491
|
'sessionlist.group': { message: '{state, select, needs_input {Needs input} working {Working} failed {Failed} completed {Completed} other {Sessions}}', description: 'A group heading: the state its sessions share.' },
|
|
1488
1492
|
'sessionlist.harness': { message: '{harness, select, claude {Claude Code} codex {Codex} flex {FlexHarness} opencode {OpenCode} other {Agent}}', description: 'The product a session runs in; product names stay as they are.' },
|
|
1489
1493
|
'sessionlist.indicator': { message: '{harness} · {state, select, needs_input {needs input} working {working} failed {failed} completed {completed} other {active}}', description: 'A row\'s status mark (its name): the harness, then the session\'s state.' },
|