@crossworks/client-types 0.239.62 → 0.239.64
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/package.json +1 -1
- package/src/dto/client.ts +2 -61
- package/src/dto/rows.ts +5 -4
- package/src/index.ts +0 -4
package/package.json
CHANGED
package/src/dto/client.ts
CHANGED
|
@@ -7,7 +7,6 @@
|
|
|
7
7
|
*/
|
|
8
8
|
import type { ClientItemKind, MemberItemKind } from '../member-kinds';
|
|
9
9
|
import type { MemberItemPill, MemberSpaceItemRow } from './member';
|
|
10
|
-
import type { NodeComment } from './rows';
|
|
11
10
|
import type { TreeKind } from '../tree';
|
|
12
11
|
|
|
13
12
|
/** GET /api/client/shell: who is signed in and the brain's brand. */
|
|
@@ -320,8 +319,7 @@ export type ClientItemsPage = {
|
|
|
320
319
|
* waiting for review, and one total for all client spaces of the brain. The
|
|
321
320
|
* 200 MB and the total count page and note text too (C5 audit). A page
|
|
322
321
|
* document over 500 KB serialized (draft or Save version), or a note over
|
|
323
|
-
* 50,000 characters, is a 400 `too-large`.
|
|
324
|
-
* ClientCommentRefusedReason. Any JSON body over the route's ceiling (8 MB)
|
|
322
|
+
* 50,000 characters, is a 400 `too-large`. Any JSON body over the route's ceiling (8 MB)
|
|
325
323
|
* is a 413 `body-too-large`.
|
|
326
324
|
*/
|
|
327
325
|
export type ClientSpaceRefusedReason =
|
|
@@ -360,42 +358,7 @@ export type ClientAcceptedBase = {
|
|
|
360
358
|
updatedAt: string;
|
|
361
359
|
};
|
|
362
360
|
|
|
363
|
-
// ──
|
|
364
|
-
|
|
365
|
-
/**
|
|
366
|
-
* GET /api/client/shared/:id/comments (POST { body } -> 201 { comment },
|
|
367
|
-
* DELETE /comments/:commentId for the client's own): the thread on an item
|
|
368
|
-
* shared with clients. The team, admins and every client login read and
|
|
369
|
-
* write it; each comment shows its author's display name (clients are
|
|
370
|
-
* approved users). Only on an item at client level: any other id is a 404.
|
|
371
|
-
*
|
|
372
|
-
* GET /api/client/space/:id/comments (POST, DELETE own) on the client's own
|
|
373
|
-
* item: the review talk with the reviewers, open while it is submitted. A
|
|
374
|
-
* reviewer's comment shows the brand name, never a staff name.
|
|
375
|
-
*/
|
|
376
|
-
export type ClientCommentThread = {
|
|
377
|
-
comments: NodeComment[];
|
|
378
|
-
/**
|
|
379
|
-
* Older comments exist (client logins C5 audit): a thread answers its
|
|
380
|
-
* NEWEST 100 comments, oldest first; `?before=<createdAt of the oldest
|
|
381
|
-
* shown>` answers the 100 before them. The same paging and `hasMore` on
|
|
382
|
-
* GET /api/member/library/:id/comments, /api/member/space/:id/comments,
|
|
383
|
-
* /api/team-admin/submissions/:id/comments and /api/nodes/:id/comments.
|
|
384
|
-
* Absent on an older brain (the whole thread).
|
|
385
|
-
*/
|
|
386
|
-
hasMore?: boolean;
|
|
387
|
-
};
|
|
388
|
-
|
|
389
|
-
/**
|
|
390
|
-
* Why a comment was refused (the 4xx `reason`, client logins C5 audit): 429
|
|
391
|
-
* `comment-cap` (a client login writes at most 100 comments a day across
|
|
392
|
-
* every thread, the review talk and client threads; deleting one does not
|
|
393
|
-
* give it back), 409 `thread-full` (one thread holds at most 1000
|
|
394
|
-
* comments).
|
|
395
|
-
*/
|
|
396
|
-
export type ClientCommentRefusedReason = 'comment-cap' | 'thread-full';
|
|
397
|
-
|
|
398
|
-
// ── Team admin > Clients: storage and client threads (C5 audit) ────────────
|
|
361
|
+
// ── Team admin > Clients: storage (C5 audit) ──────────────────────────
|
|
399
362
|
|
|
400
363
|
/**
|
|
401
364
|
* GET /api/team-admin/clients/storage (admin only): what the client spaces
|
|
@@ -435,25 +398,3 @@ export type ClientStorageUsage = {
|
|
|
435
398
|
* brain does not send it. */
|
|
436
399
|
clientAppDbBytes?: number;
|
|
437
400
|
};
|
|
438
|
-
|
|
439
|
-
/**
|
|
440
|
-
* GET /api/team-admin/clients/comments?days=7 (admin only, 1 to 90 days):
|
|
441
|
-
* the client-level items whose client thread had a comment by a CLIENT in
|
|
442
|
-
* the window, newest first, at most 100. `clientComments` counts the
|
|
443
|
-
* clients' comments in the window; `lastClientName` is the newest one's
|
|
444
|
-
* author. Open the thread on /api/nodes/:id/comments.
|
|
445
|
-
*/
|
|
446
|
-
export type ClientThreadActivity = {
|
|
447
|
-
rows: {
|
|
448
|
-
nodeId: string;
|
|
449
|
-
title: string;
|
|
450
|
-
type: string;
|
|
451
|
-
lastCommentAt: string;
|
|
452
|
-
clientComments: number;
|
|
453
|
-
lastClientName: string;
|
|
454
|
-
}[];
|
|
455
|
-
};
|
|
456
|
-
|
|
457
|
-
/** DELETE /api/team-admin/clients/:id/comments (admin only): every comment
|
|
458
|
-
* that client login wrote (client threads and review talk) is removed. */
|
|
459
|
-
export type ClientCommentsDeleted = { deleted: number };
|
package/src/dto/rows.ts
CHANGED
|
@@ -58,10 +58,11 @@ export type TaskTodo = {
|
|
|
58
58
|
export type NodeCommentAuthorKind = 'owner' | 'member' | 'agent' | 'client';
|
|
59
59
|
|
|
60
60
|
/**
|
|
61
|
-
* A comment on a node
|
|
62
|
-
*
|
|
63
|
-
*
|
|
64
|
-
*
|
|
61
|
+
* A comment on a node. No route serves comments any more (2026-10-09: the
|
|
62
|
+
* brain has no comment threads; user-to-user talk moves to the forum); the
|
|
63
|
+
* shape stays for older clients that still type one, such as the always
|
|
64
|
+
* empty `comments` of a review item. `authorName` was a display snapshot at
|
|
65
|
+
* post time; `mine` was computed server-side per viewer.
|
|
65
66
|
*/
|
|
66
67
|
export type NodeComment = {
|
|
67
68
|
id: string;
|
package/src/index.ts
CHANGED
|
@@ -175,11 +175,7 @@ export type {
|
|
|
175
175
|
ClientSpaceRefusedReason,
|
|
176
176
|
ClientAcceptedItem,
|
|
177
177
|
ClientAcceptedBase,
|
|
178
|
-
ClientCommentThread,
|
|
179
|
-
ClientCommentRefusedReason,
|
|
180
178
|
ClientStorageUsage,
|
|
181
|
-
ClientThreadActivity,
|
|
182
|
-
ClientCommentsDeleted,
|
|
183
179
|
} from './dto/client';
|
|
184
180
|
|
|
185
181
|
// Types only at the root; the runtime constants (APP_TINTS, limits) are the
|