@skillcdn/console 0.3.1 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (116) hide show
  1. package/README.md +2 -2
  2. package/dist/api.d.ts +3 -3
  3. package/dist/api.d.ts.map +1 -1
  4. package/dist/api.js +3 -3
  5. package/dist/api.js.map +1 -1
  6. package/dist/cli/cli.d.ts +4 -0
  7. package/dist/cli/cli.d.ts.map +1 -1
  8. package/dist/cli/cli.js +105 -18
  9. package/dist/cli/cli.js.map +1 -1
  10. package/dist/cli/format.d.ts.map +1 -1
  11. package/dist/cli/format.js +9 -7
  12. package/dist/cli/format.js.map +1 -1
  13. package/dist/cli/help.d.ts.map +1 -1
  14. package/dist/cli/help.js +13 -11
  15. package/dist/cli/help.js.map +1 -1
  16. package/dist/cli/main.js +1 -0
  17. package/dist/cli/main.js.map +1 -1
  18. package/dist/client.d.ts +13 -8
  19. package/dist/client.d.ts.map +1 -1
  20. package/dist/client.js +10 -2
  21. package/dist/client.js.map +1 -1
  22. package/dist/compat.d.ts +28 -6
  23. package/dist/compat.d.ts.map +1 -1
  24. package/dist/compat.js +55 -14
  25. package/dist/compat.js.map +1 -1
  26. package/dist/components/board.d.ts.map +1 -1
  27. package/dist/components/board.js +6 -4
  28. package/dist/components/board.js.map +1 -1
  29. package/dist/components/calendar.d.ts +13 -7
  30. package/dist/components/calendar.d.ts.map +1 -1
  31. package/dist/components/calendar.js +36 -24
  32. package/dist/components/calendar.js.map +1 -1
  33. package/dist/components/picker.d.ts +39 -0
  34. package/dist/components/picker.d.ts.map +1 -0
  35. package/dist/components/picker.js +155 -0
  36. package/dist/components/picker.js.map +1 -0
  37. package/dist/components/task-form.d.ts +18 -4
  38. package/dist/components/task-form.d.ts.map +1 -1
  39. package/dist/components/task-form.js +56 -13
  40. package/dist/components/task-form.js.map +1 -1
  41. package/dist/components/task-list.js +2 -2
  42. package/dist/components/task-list.js.map +1 -1
  43. package/dist/components/task-view.d.ts +7 -1
  44. package/dist/components/task-view.d.ts.map +1 -1
  45. package/dist/components/task-view.js +6 -5
  46. package/dist/components/task-view.js.map +1 -1
  47. package/dist/components/ui.d.ts +7 -0
  48. package/dist/components/ui.d.ts.map +1 -1
  49. package/dist/components/ui.js +11 -0
  50. package/dist/components/ui.js.map +1 -1
  51. package/dist/components/work.d.ts.map +1 -1
  52. package/dist/components/work.js +5 -3
  53. package/dist/components/work.js.map +1 -1
  54. package/dist/console.css +163 -11
  55. package/dist/console.d.ts.map +1 -1
  56. package/dist/console.js +24 -4
  57. package/dist/console.js.map +1 -1
  58. package/dist/data.d.ts +11 -1
  59. package/dist/data.d.ts.map +1 -1
  60. package/dist/data.js +22 -1
  61. package/dist/data.js.map +1 -1
  62. package/dist/i18n/en.d.ts +11 -3
  63. package/dist/i18n/en.d.ts.map +1 -1
  64. package/dist/i18n/en.js +16 -8
  65. package/dist/i18n/en.js.map +1 -1
  66. package/dist/i18n/ko.d.ts.map +1 -1
  67. package/dist/i18n/ko.js +17 -9
  68. package/dist/i18n/ko.js.map +1 -1
  69. package/dist/index.d.ts +3 -2
  70. package/dist/index.d.ts.map +1 -1
  71. package/dist/index.js +3 -2
  72. package/dist/index.js.map +1 -1
  73. package/dist/limits.d.ts +2 -0
  74. package/dist/limits.d.ts.map +1 -1
  75. package/dist/limits.js +2 -0
  76. package/dist/limits.js.map +1 -1
  77. package/dist/schemas.d.ts +12 -11
  78. package/dist/schemas.d.ts.map +1 -1
  79. package/dist/schemas.js +11 -8
  80. package/dist/schemas.js.map +1 -1
  81. package/dist/vocabulary.d.ts +2 -0
  82. package/dist/vocabulary.d.ts.map +1 -1
  83. package/dist/vocabulary.js +2 -0
  84. package/dist/vocabulary.js.map +1 -1
  85. package/docs/specs/cli.md +9 -9
  86. package/docs/specs/rest.md +14 -14
  87. package/package.json +1 -1
  88. package/skills/building-a-console/SKILL.md +2 -2
  89. package/skills/deploying-a-console/SKILL.md +2 -2
  90. package/skills/deploying-a-console/references/resources.md +1 -1
  91. package/skills/working-the-board/SKILL.md +3 -3
  92. package/skills/working-the-board/references/terms.md +2 -2
  93. package/src/api.ts +5 -0
  94. package/src/cli/cli.ts +131 -18
  95. package/src/cli/format.ts +11 -7
  96. package/src/cli/help.ts +15 -11
  97. package/src/cli/main.ts +1 -0
  98. package/src/client.ts +23 -10
  99. package/src/compat.ts +63 -14
  100. package/src/components/board.tsx +10 -4
  101. package/src/components/calendar.tsx +68 -32
  102. package/src/components/picker.tsx +297 -0
  103. package/src/components/task-form.tsx +149 -63
  104. package/src/components/task-list.tsx +2 -2
  105. package/src/components/task-view.tsx +23 -9
  106. package/src/components/ui.tsx +25 -0
  107. package/src/components/work.tsx +6 -4
  108. package/src/console.tsx +29 -3
  109. package/src/data.ts +44 -1
  110. package/src/i18n/en.ts +16 -8
  111. package/src/i18n/ko.ts +17 -9
  112. package/src/index.ts +16 -1
  113. package/src/limits.ts +2 -0
  114. package/src/schemas.ts +11 -7
  115. package/src/styles/console.css +163 -11
  116. package/src/vocabulary.ts +3 -0
package/README.md CHANGED
@@ -33,7 +33,7 @@ const { items } = await client.tasks({ state: "ready" });
33
33
  - **The bounds** every input is held to (`MAX_TITLE_LENGTH`, `MAX_BODY_LENGTH`, `MAX_OPTIONS`, ...), so that a page can say so before a request is made.
34
34
  - **The routes:** `REST_ROUTES` (the workspace's resources), `AUTH_ROUTES`, and the helpers that build a path (`projectPath(key, collection, id)` for everything under a project, `projectIconPath(key, icon)` for a project's image, `restPath`, `loginPath`, `signInPath`). The API itself is described in [docs/specs/rest.md](https://github.com/skillcdn/console/blob/main/docs/specs/rest.md).
35
35
  - **The schemas,** in the mini build of zod, which runs in a browser: what the server answers (`restProjectSchema`, `restMemberSchema`, `restTaskSchema`, `restDecisionSchema`, `restEventSchema`, `restMeSchema`, ...) and what it is sent (`restProjectInputSchema`, `restTaskInputSchema`, `restTaskPatchSchema`, `restDecisionInputSchema`, `restAnswerInputSchema`, ...). Absent values are `null` on the wire, never missing keys. The server validates with the input schemas and is tested against the others.
36
- - **The client:** `createClient({ baseUrl, fetch })` answers typed values parsed with those schemas, and throws an `ApiError` with the server's stable `code` (or `network`, `invalid_response`) for anything else. It takes a `fetch` and reads nothing else. With `userAgent`, every request names the client: the command sends `skillcdn-console/<version>`, by which the console holds it to the versions it takes ([ADR-0025](https://github.com/skillcdn/console/blob/main/docs/adr/0025-the-command-names-its-version-on-every-request-and-the-console-holds-it-to-the-range-it-takes.md)); `me()` answers the console's version and that range as `console`, and the `compat` module (`parseVersion`, `compareVersions`, `judgeClient`, `clientRange`, `commonRange`, `userAgentOf`, `clientVersionOf`, the headers `VERSION_HEADER` and `CLIENT_RANGE_HEADER`, and `CLIENT_POLICY`, by which the package narrows the common rule and never widens it) is exported for a console or a script that compares itself with it. With `token`, a token a person made on their Agents page, every request carries `Authorization: Bearer` and no cookie: how a script or a console of a person's own acts as that person, configuring included (`createProject`, `updatePerson`, a project's `update`, `setIcon`, `addMember`, `updateMember` and `removeMember`, `createCategory`, `updateCategory` and `removeCategory`), within the person's own roles; only the tokens themselves and the approval of a connection are a session's, except that a token gives itself up with `giveUpToken` ([ADR-0021](https://github.com/skillcdn/console/blob/main/docs/adr/0021-a-token-configures-as-its-person-does.md)). The board is a project's: `client.projects()` lists those the person may see, and `client.project(key)` is the client of one, with its tasks, decisions, goals, runs, files, events, skills (`skills`, the pack by name and by count with its skills and, for a program, what the address serves as `@skillcdn/core` spells it; `skill`, `skillFile`, `skillBrowse` and `skillFind`, each answering what the pack answered as `read`, a `RestSkill`, `RestFile`, `RestBrowse` or `RestFind` of `@skillcdn/core`, with the pack's own refusal beside the status, ADR-0031), documents, settings, members and image (`setIcon`, `removeIcon`). `tasks(filter)` narrows the board (`TaskFilter`: a state, the open ones, a category's key, a goal, an assignee, a day tasks are due by) and pages it (`Page`: `limit` and `offset`; the answer carries `more`), as `decisions(filter)` and `runs(filter)` are paged; a task carries its `category`, `goalId`, its plan (`startsOn`, `dueOn`) and its moments (`startedAt`, `doneAt`). The roadmap is `goals()`, `goal(id)`, `createGoal` and `updateGoal`; the workspace's categories are `client.categories()`, `createCategory`, `updateCategory` and `removeCategory`; `client.work()` is what is on the person's plate across their projects ([ADR-0019](https://github.com/skillcdn/console/blob/main/docs/adr/0019-a-task-is-planned-in-days-the-board-keeps-its-moments-and-goals-and-categories-give-the-work-its-shape.md)). The documents go by path: `documents({ folder })` lists a folder, `documents({ q })` finds pages by their words, `document(path)` reads one with its links both ways and its files, `writeDocument(path, { title, body, baseVersion })` writes a version, `archiveDocument`, `restoreDocument`, `documentVersions`, `documentVersion(path, n)`, `attachFile(path, upload)` and `documentFileUrl(path, id)` do the rest; `updateDecision(id, { outcome })` grows a decision's record. The rules of the board ([ADR-0023](https://github.com/skillcdn/console/blob/main/docs/adr/0023-the-rules-of-a-board-are-pages-the-workspace-and-its-projects-keep-read-first-by-every-agent.md)) are `client.rules()`, `writeRules`, `archiveRules` and `rulesVersions`, for the workspace's, and a project's `rules()`, which answers the workspace's with the project's own; a project's are written as the page `rules`. `REFERENCE_RULES` is what holds where an organization wrote none, and `isReferenceRules` tells it from a text; `fillRules` fills `{language}` (`RULES_LANGUAGE_PLACEHOLDER`) with the name of a person's language, which `languageNameOf` gives from its tag. `agentLabel` is an agent's name before where it runs, what the pages show of "Claude Code on a laptop". `connect`, `connectRequest`, `approveConnection`, `denyConnection` and `claimConnection` are the two sides of an agent connecting with a code a person approves (ADR-0011), and `personTokens` and `revokePersonToken` an administrator's sight of everyone's agents. An `EventSource` cannot carry a header, so a stream read with a token is a `fetch` of `eventStreamUrl(after)`. `handInFile` sends a file as a form, and `fileUrl` says where its bytes are read back. `events(after, { task })` is everything that happened to one task.
36
+ - **The client:** `createClient({ baseUrl, fetch })` answers typed values parsed with those schemas, and throws an `ApiError` with the server's stable `code` (or `network`, `invalid_response`) for anything else. It takes a `fetch` and reads nothing else. With `userAgent`, every request names the client: the command sends `skillcdn-console/<version>`, by which the console holds it to the versions it takes ([ADR-0025](https://github.com/skillcdn/console/blob/main/docs/adr/0025-the-command-names-its-version-on-every-request-and-the-console-holds-it-to-the-range-it-takes.md)); `me()` answers the console's version and that range as `console`, and the `compat` module (`parseVersion`, `compareVersions`, `judgeClient`, `clientRange`, `commonRange`, `judgeConsole`, `consoleRange`, `userAgentOf`, `clientVersionOf`, the headers `VERSION_HEADER` and `CLIENT_RANGE_HEADER`, `CLIENT_POLICY`, the oldest command a console answers, by which the package narrows the common rule and never widens it, and `CONSOLE_AT_LEAST`, the oldest console the command works with; within a line of SkillCDN the two go together whatever the patch, and a release that changes what passes between them raises the floors, ADR-0038) is exported for a console or a script that compares itself with it. With `token`, a token a person made on their Agents page, every request carries `Authorization: Bearer` and no cookie: how a script or a console of a person's own acts as that person, configuring included (`createProject`, `updatePerson`, a project's `update`, `setIcon`, `addMember`, `updateMember` and `removeMember`, `createCategory`, `updateCategory` and `removeCategory`), within the person's own roles; only the tokens themselves and the approval of a connection are a session's, except that a token gives itself up with `giveUpToken` ([ADR-0021](https://github.com/skillcdn/console/blob/main/docs/adr/0021-a-token-configures-as-its-person-does.md)). The board is a project's: `client.projects()` lists those the person may see, and `client.project(key)` is the client of one, with its tasks, decisions, goals, runs, files, events, skills (`skills`, the pack by name and by count with its skills and, for a program, what the address serves as `@skillcdn/core` spells it; `skill`, `skillFile`, `skillBrowse` and `skillFind`, each answering what the pack answered as `read`, a `RestSkill`, `RestFile`, `RestBrowse` or `RestFind` of `@skillcdn/core`, with the pack's own refusal beside the status, ADR-0031), documents, settings, members and image (`setIcon`, `removeIcon`). `tasks(filter)` narrows the board (`TaskFilter`: a state, the open ones, a category's key, a goal, a worker, a day tasks are due by, and `q`, words of the title or a number, how a task is found by searching) and pages it (`Page`: `limit` and `offset`; the answer carries `more`), as `decisions(filter)`, `runs(filter)` and `goals(filter)` are paged; a task carries its `owner` and its `workers` (any number, ADR-0037), its `category`, `goalId`, its plan (`startsOn`, `dueOn`) and its moments (`startedAt`, `doneAt`). The roadmap is `goals(filter)` (`GoalFilter`: a state, the open ones, a category's key, `q` and a page), `goal(id)`, `createGoal` and `updateGoal`; the workspace's categories are `client.categories()`, `createCategory`, `updateCategory` and `removeCategory`; `client.work()` is what is on the person's plate across their projects ([ADR-0019](https://github.com/skillcdn/console/blob/main/docs/adr/0019-a-task-is-planned-in-days-the-board-keeps-its-moments-and-goals-and-categories-give-the-work-its-shape.md)). The documents go by path: `documents({ folder })` lists a folder, `documents({ q })` finds pages by their words, `document(path)` reads one with its links both ways and its files, `writeDocument(path, { title, body, baseVersion })` writes a version, `archiveDocument`, `restoreDocument`, `documentVersions`, `documentVersion(path, n)`, `attachFile(path, upload)` and `documentFileUrl(path, id)` do the rest; `updateDecision(id, { outcome })` grows a decision's record. The rules of the board ([ADR-0023](https://github.com/skillcdn/console/blob/main/docs/adr/0023-the-rules-of-a-board-are-pages-the-workspace-and-its-projects-keep-read-first-by-every-agent.md)) are `client.rules()`, `writeRules`, `archiveRules` and `rulesVersions`, for the workspace's, and a project's `rules()`, which answers the workspace's with the project's own; a project's are written as the page `rules`. `REFERENCE_RULES` is what holds where an organization wrote none, and `isReferenceRules` tells it from a text; `fillRules` fills `{language}` (`RULES_LANGUAGE_PLACEHOLDER`) with the name of a person's language, which `languageNameOf` gives from its tag. `agentLabel` is an agent's name before where it runs, what the pages show of "Claude Code on a laptop". `connect`, `connectRequest`, `approveConnection`, `denyConnection` and `claimConnection` are the two sides of an agent connecting with a code a person approves (ADR-0011), and `personTokens` and `revokePersonToken` an administrator's sight of everyone's agents. An `EventSource` cannot carry a header, so a stream read with a token is a `fetch` of `eventStreamUrl(after)`. `handInFile` sends a file as a form, and `fileUrl` says where its bytes are read back. `events(after, { task })` is everything that happened to one task.
37
37
 
38
38
  ### The command line
39
39
 
@@ -76,7 +76,7 @@ createConsole({
76
76
  }).mount(document.getElementById("root"));
77
77
  ```
78
78
 
79
- - **The components** take their data as props and nothing from the network: `Board` (one column per state, the sooner due first; given `onMove`, a card is dragged to another column with a mouse, or with a finger that rests on it a moment first; given `editHref` and `onArchive`, each card has a menu with the way to the task's form and, once it is done or dropped, the way to put it away), `TaskCard`, `BoardFilters` with `filterTasks` and `byDue` (the board narrowed by category, goal, person and one's own), `TaskList` (tasks as rows, a page at a time), `TaskView` (one task with its plan, its moments, its decisions and its parts), `TaskForm` (with the `categories` and the `goals` to choose from), `Calendar` and `Workload` with `workloadOf` (a month with each task across its planned days, a bar in a lane of its own, or on its one day, a due day or a start, the person who has each before its title, with a legend of the colours of the `categories` given, and who has what; `weekSegments` lays the bars; `TaskTip` is the task under the pointer in full, with the facts its page lists, within its item and above or below it as `placeTip` says, where there is more room, its goal named from the `goals` given; the composition narrows the page with `BoardFilters` as it does the board, the address carrying the filter with the month), `GoalList`, `GoalView` and `GoalForm` (the roadmap, one goal with its tasks by state, and the way to set one, with the `categories` to sort it into and its start and target days, ADR-0026), `GoalTimeline` with `timelineBars` (the roadmap as months: six from the month given, each goal planned in days a bar from its start to its target in the colour of its category, filled as far as its tasks are done, today marked, and the goals without days named below; `Calendar` given `goalHref` marks each goal's target day on the month), `WorkList` (a person's own work across projects), `CategoryList` (the categories, with the ways an administrator keeps them), `DecisionList` and `DecisionCard` (the waiting ones as cards, each with the way to answer, one of the options or a line of one's own; the answered ones as the record, `DecisionLog`, a row each with who asked and when, through which agent, the answer with the word given, marked when it is the person's own, and who answered and when, twenty to a page, each page at an address given `pageHref` and `page`, or turned in place), `DecisionForm`, `EventFeed` (a sentence per event, newest first, a page at a time; `describeEvent` makes the sentence), `Shell` (the header with the workspace, the project, the tabs of the pages and the person's menu), `SignIn` (one button per provider the deployment offers), `TokenList`, `TokenForm` and `NewToken` (the agents a person connected, as the tokens they hold, the way to make one by hand, and the one just made with its secret shown once), `ConnectCodeForm`, `ConnectApproval` and `ConnectWords` (an agent connecting with a code: where the code is typed, what asks under it with the way to approve or refuse it, and what to tell the agent; `ConnectPage` composes the first two for a code), `PeopleList` (everyone in, with what each is and what let them in, the logins let in that nobody signed in with yet, and the deactivated, with the ways for an administrator to change a role, take a person out or back in, and take a listing away) and `ListingForm` (where an administrator lets someone in by login), `ProjectMark` (a project's mark: its own image when it has one, else its symbol on its colour, or the ones chosen from its key and its name; `sm`, `md` or `lg`), `ProjectList`, `ProjectForm` and `MemberList` (the projects a person may see with what they are in each, the way to make or change one, its mark included, with an image chosen for it (`onSubmit` gets the file, or `null` to take the image away), and those listed in a project with the way for an owner to add, change and remove them; `ProjectRoleBadge`, `PROJECT_ROLE_LABELS`, `VISIBILITY_LABELS` and `keyOf` with them), `PackTokenForm`, `PackConnect` and `PackTokenWays` (the SkillCDN token a private pack is read with: pasted, or connected with a code approved at SkillCDN, the console asked again at the interval the deployment named; and the two ways side by side, as a project's Settings page and the workspace's offer them), `WorkspaceSettingsView` and `WorkspaceSettingsForm` (the workspace's settings as rows: who sees whom, the day the week begins on and the time zone, picked by area with `timeZoneGroups`, `deviceTimeZone` and `offsetOf`), `SkillList` (a project's skills as SkillCDN serves them at its address, each with where a person reads it and what an agent loads it by, and how an agent is connected to it), `RulesView` and `RulesForm` (the rules of the board, ADR-0023: what holds and where it comes from, the console's own, a page written or none, with `{language}` filled with the language the pages speak, folded under its facts where asked, and the ways to write them, put them away and go back to the console's own for whoever may; the form starts from what holds and saves nothing that would change nothing), `FolderView`, `DocumentList`, `DocumentSearch`, `DocumentView`, `DocumentForm`, `DocumentFiles` and `DocumentCrumbs` (a project's documents: a folder's folders and pages, the way to find pages by their words, one page with its versions, what it links to, what refers to it and its files, a picture among them shown where the body names it, and the forms to write and attach, a picture pasted into the body attached once the page is written; `DocsPage` composes them for a path), `RunList` and `RunCard` (an agent's run on a task: what it reported, what it handed in, links and files alike, a picture among them small and large as a comment's is and placed in a report by its file name, what it waits for, and when an open one was last heard from; `RunStatusBadge` and `RUN_STATUS_LABELS` with them, and `fileHref` for where a file is read), `TaskThread`, `CommentCard` and `CommentForm` (the discussion on a task, ADR-0024: the comments, the runs and the decisions as one thread in the order they came, which `threadOf` orders, each comment with who said it, through which agent, its text with the pictures it names in place and its other files after it, pictures being what `isPicture` says, and the form at the end, where a picture pasted in goes with the comment; `TaskView` shows the thread given `comments` and `onComment`, and its `fileHref` names any file of the project by its id), and `Markdown`, which renders what people and agents wrote as elements, never as HTML, with links to the web only and pictures over https only, or, given `fileSrc`, from the file of that name, and, given `docHref`, a link to a page's path as a link to the page. `DecisionCard` reads as a record, with the context, the rationale and what followed, which `onUpdate` lets a person write. The small blocks (`Button`, `CopyButton` (a text put on the clipboard), `Badge`, `Avatar` (`xs` to `lg`), `PersonChip` with `personName` (a person by the name the host gives, the login where there is none), `Callout`, `EmptyState`, `Spinner`, `Time`, `Day`, `CategoryBadge`, `DueBadge`, `GoalStateBadge`, `ProgressBar`, `ShowMore` with `usePaged` and `PAGE_SIZE`, a long list growing a page at a time, and `Pager` with `pageOf` and `RECORD_PAGE_SIZE`, a list turned by pages), the words of the vocabulary (`STATE_LABELS`, `PRIORITY_LABELS`, `ROLE_LABELS`, with `RoleBadge`) and the day helpers (`today`, `addDays`, `daysBetween`, `monthGrid`, `formatDay`, `formatMonth` and the rest, days being the strings the API spells them as) are exported too.
79
+ - **The components** take their data as props and nothing from the network: `Board` (one column per state, the sooner due first; given `onMove`, a card is dragged to another column with a mouse, or with a finger that rests on it a moment first; given `editHref` and `onArchive`, each card has a menu with the way to the task's form and, once it is done or dropped, the way to put it away), `TaskCard`, `BoardFilters` with `filterTasks` and `byDue` (the board narrowed by category, goal, person and one's own), `TaskList` (tasks as rows, a page at a time), `TaskView` (one task with its plan, its moments, its workers, its decisions and its parts; given `parent`, the task it is part of when the page has read it, and `findTasks` and `findGoals`, its form searches), `TaskForm` (with the `categories` to choose from, the `people` to put on the task as its workers, and `findTasks` and `findGoals`, searches a page at a time by which the task it is part of and the goal it works towards are found, never offered whole, ADR-0037), `Calendar` and `Workload` with `workloadOf` (a month with each task across its planned days, a bar in a lane of its own, or on its one day, a due day or a start, the person who has each before its title, with a legend of the colours of the `categories` given, and who has what; `weekSegments` lays the bars; `TaskTip` is the task under the pointer in full, with the facts its page lists, within its item and above or below it as `placeTip` says, where there is more room, its goal named from the `goals` given; the composition narrows the page with `BoardFilters` as it does the board, the address carrying the filter with the month), `GoalList`, `GoalView` and `GoalForm` (the roadmap, one goal with its tasks by state, and the way to set one, with the `categories` to sort it into and its start and target days, ADR-0026), `GoalTimeline` with `timelineBars` (the roadmap as months: six from the month given, each goal planned in days a bar from its start to its target in the colour of its category, filled as far as its tasks are done, today marked, and the goals without days named below; `Calendar` given `goalHref` marks each goal's target day on the month), `WorkList` (a person's own work across projects), `CategoryList` (the categories, with the ways an administrator keeps them), `DecisionList` and `DecisionCard` (the waiting ones as cards, each with the way to answer, one of the options or a line of one's own; the answered ones as the record, `DecisionLog`, a row each with who asked and when, through which agent, the answer with the word given, marked when it is the person's own, and who answered and when, twenty to a page, each page at an address given `pageHref` and `page`, or turned in place), `DecisionForm`, `EventFeed` (a sentence per event, newest first, a page at a time; `describeEvent` makes the sentence), `Shell` (the header with the workspace, the project, the tabs of the pages and the person's menu), `SignIn` (one button per provider the deployment offers), `TokenList`, `TokenForm` and `NewToken` (the agents a person connected, as the tokens they hold, the way to make one by hand, and the one just made with its secret shown once), `ConnectCodeForm`, `ConnectApproval` and `ConnectWords` (an agent connecting with a code: where the code is typed, what asks under it with the way to approve or refuse it, and what to tell the agent; `ConnectPage` composes the first two for a code), `PeopleList` (everyone in, with what each is and what let them in, the logins let in that nobody signed in with yet, and the deactivated, with the ways for an administrator to change a role, take a person out or back in, and take a listing away) and `ListingForm` (where an administrator lets someone in by login), `ProjectMark` (a project's mark: its own image when it has one, else its symbol on its colour, or the ones chosen from its key and its name; `sm`, `md` or `lg`), `ProjectList`, `ProjectForm` and `MemberList` (the projects a person may see with what they are in each, the way to make or change one, its mark included, with an image chosen for it (`onSubmit` gets the file, or `null` to take the image away), and those listed in a project with the way for an owner to add, change and remove them; `ProjectRoleBadge`, `PROJECT_ROLE_LABELS`, `VISIBILITY_LABELS` and `keyOf` with them), `PackTokenForm`, `PackConnect` and `PackTokenWays` (the SkillCDN token a private pack is read with: pasted, or connected with a code approved at SkillCDN, the console asked again at the interval the deployment named; and the two ways side by side, as a project's Settings page and the workspace's offer them), `WorkspaceSettingsView` and `WorkspaceSettingsForm` (the workspace's settings as rows: who sees whom, the day the week begins on and the time zone, picked by area with `timeZoneGroups`, `deviceTimeZone` and `offsetOf`), `SkillList` (a project's skills as SkillCDN serves them at its address, each with where a person reads it and what an agent loads it by, and how an agent is connected to it), `RulesView` and `RulesForm` (the rules of the board, ADR-0023: what holds and where it comes from, the console's own, a page written or none, with `{language}` filled with the language the pages speak, folded under its facts where asked, and the ways to write them, put them away and go back to the console's own for whoever may; the form starts from what holds and saves nothing that would change nothing), `FolderView`, `DocumentList`, `DocumentSearch`, `DocumentView`, `DocumentForm`, `DocumentFiles` and `DocumentCrumbs` (a project's documents: a folder's folders and pages, the way to find pages by their words, one page with its versions, what it links to, what refers to it and its files, a picture among them shown where the body names it, and the forms to write and attach, a picture pasted into the body attached once the page is written; `DocsPage` composes them for a path), `RunList` and `RunCard` (an agent's run on a task: what it reported, what it handed in, links and files alike, a picture among them small and large as a comment's is and placed in a report by its file name, what it waits for, and when an open one was last heard from; `RunStatusBadge` and `RUN_STATUS_LABELS` with them, and `fileHref` for where a file is read), `TaskThread`, `CommentCard` and `CommentForm` (the discussion on a task, ADR-0024: the comments, the runs and the decisions as one thread in the order they came, which `threadOf` orders, each comment with who said it, through which agent, its text with the pictures it names in place and its other files after it, pictures being what `isPicture` says, and the form at the end, where a picture pasted in goes with the comment; `TaskView` shows the thread given `comments` and `onComment`, and its `fileHref` names any file of the project by its id), and `Markdown`, which renders what people and agents wrote as elements, never as HTML, with links to the web only and pictures over https only, or, given `fileSrc`, from the file of that name, and, given `docHref`, a link to a page's path as a link to the page. `DecisionCard` reads as a record, with the context, the rationale and what followed, which `onUpdate` lets a person write. The small blocks (`Button`, `CopyButton` (a text put on the clipboard), `Badge`, `Avatar` (`xs` to `lg`), `PersonChip` with `personName` (a person by the name the host gives, the login where there is none), `Callout`, `EmptyState`, `Spinner`, `Time`, `Day`, `CategoryBadge`, `DueBadge`, `GoalStateBadge`, `ProgressBar`, `ShowMore` with `usePaged` and `PAGE_SIZE`, a long list growing a page at a time, `Pager` with `pageOf` and `RECORD_PAGE_SIZE`, a list turned by pages, `Picker` with `PICKER_PAGE_LIMIT`, one thing chosen out of a listing searched a page at a time and standing as a chip once chosen, and `Workers`, the people at work on a task as pictures side by side with a count of the rest), the words of the vocabulary (`STATE_LABELS`, `PRIORITY_LABELS`, `ROLE_LABELS`, with `RoleBadge`) and the day helpers (`today`, `addDays`, `daysBetween`, `monthGrid`, `formatDay`, `formatMonth` and the rest, days being the strings the API spells them as) are exported too.
80
80
  - **The composition:** `createConsole(config)` returns `{ App, mount }`. `App` is the whole console as one component; `mount(container)` renders it and returns the way to take it down. `config.baseUrl` is the origin of the API (the page's own when left out), `config.components` the pieces to replace (`ConsoleComponents` names them with the props each takes), `config.languages` the packs the pages speak, `config.brand` the addresses of a symbol and a wordmark to show beside the name (ADR-0013; the default console passes those of `@skillcdn/brand`, the main repository's package of its marks), `config.client` a client of your own, for tests. The SkillCDN name and marks are trademarks of KDX Labs under the main repository's trademark policy, not under this package's MIT license; a custom console brings its own marks through the same slot. A console that holds a token rather than a session (one of your own, served by `console serve`) is told so by the API (`me.agent`, the token's name) and offers nothing a token cannot do: no agents page and no sign-out, since the tokens themselves are a person's own doing; everything else, configuring included, it does on the token as the person (ADR-0021), and it keeps the choice of language on the person. The pages route in the browser and every form has an address (ADR-0010): the projects at `/`, the person's own work at `/work`, the workspace's settings at `/settings` (its rules, its categories at `/categories`, where its skills come from), a project's pages under `/projects/<key>` (its roadmap, calendar and settings among them), a task by its number, a goal and a decision by their ids, a document by its path, and the query for how a page is shown, the board's filters, the calendar's month, the week of the person's work and the settings' forms among it (`matchRoute(pathname, search)`, `PATHS`, `projectHref`, `boardHref`, `taskHref`, `goalHref`, `calendarHref`, `workHref`, `personWorkHref`, `decisionHref`, `docHref`, `settingsHref`, `projectSettingsHref`, `newTaskHref`, `newGoalHref`, `newDecisionHref`, and `movedFrom` for the addresses of before); every link to one of them is followed in place, with one history entry per step; the workspace is loaded once and the project the page is on whole, kept current by the project's stream (`useConsoleData(client, projectKey)`, for a composition of your own).
81
81
  - **Pages of your own:** `config.pages` adds tabs beside the console's. Each is a `CustomPage`: a `key` (what the address says: `/pages/<key>` on the workspace, `/projects/<project>/pages/<key>` on a project), a `label` (one word, or a word by language tag with `en` standing in), a `level` (`workspace`, or `project` for a tab on every project), `wide` for a page that takes the whole window, and `render(context)`, which gets what the default pages get: the `data` of `useConsoleData` with its actions, the `project` the page is on, the `client`, the `navigation`, the `words` and the `language`. `customPageHref` names the address and `customPageLabel` the tab's word. A page that is not among the pages given shows nothing there.
82
82
  - **The languages:** every word the pages show is in a pack (`Messages`, keyed as `en` is), English and Korean ship (`ENGLISH`, `KOREAN`, `DEFAULT_LANGUAGES`), and a component takes its words from the language above it (`useWords`, `useLanguage`, `LanguageContext`), English where there is none. The person's choice is kept on them (`client.updateMe({ language })`) and the browser's languages decide before one (`chooseLanguage`, `packFor`). `createConsole({ languages })` replaces the packs the default console speaks, so that a custom console adds a language of its own; a pack is complete by type.
package/dist/api.d.ts CHANGED
@@ -1,13 +1,13 @@
1
1
  export { agentLabel } from "./agent-name.js";
2
2
  export { ApiError, type ClientOptions, type CommentInput, type ConsoleClient, createClient, type DocumentFilter, type EventFilter, type FetchLike, type FileRead, type FileUpload, type GoalFilter, type Page, type ProjectClient, type TaskFilter, } from "./client.js";
3
- export { CLIENT_POLICY, CLIENT_PRODUCT, CLIENT_RANGE_HEADER, type ClientJudgement, type ClientPolicy, type ClientVerdict, clientRange, clientVersionOf, commonRange, compareVersions, formatRange, formatVersion, inRange, judgeClient, parseRange, parseVersion, userAgentOf, VERSION_HEADER, type Version, type VersionRange, } from "./compat.js";
3
+ export { CLIENT_POLICY, CLIENT_PRODUCT, CLIENT_RANGE_HEADER, type ClientJudgement, type ClientPolicy, type ClientVerdict, CONSOLE_AT_LEAST, clientRange, clientVersionOf, commonRange, compareVersions, consoleRange, formatRange, formatVersion, inRange, judgeClient, judgeConsole, parseRange, parseVersion, userAgentOf, VERSION_HEADER, type Version, type VersionRange, } from "./compat.js";
4
4
  export { CONNECT_CODE_ALPHABET, CONNECT_CODE_LENGTH, isConnectCode, normalizeConnectCode, } from "./connect.js";
5
5
  export { DOCUMENT_PATH, documentPathsIn, folderOf, foldersAbove, isDocumentPath, isFolderPath, nameOf, } from "./documents.js";
6
- export { DEFAULT_PAGE_LIMIT, DEFAULT_TOKEN_DAYS, EVENTS_PAGE_LIMIT, LIST_LIMIT, MAX_AGENT_LENGTH, MAX_ARTIFACTS_PER_RUN, MAX_BODY_LENGTH, MAX_CATEGORIES, MAX_CATEGORY_KEY_LENGTH, MAX_CATEGORY_NAME_LENGTH, MAX_COMMENTS_PER_TASK, MAX_DOCUMENT_LENGTH, MAX_DOCUMENT_PATH_LENGTH, MAX_DOCUMENT_SEGMENT_LENGTH, MAX_FILE_BYTES, MAX_FILE_NAME_LENGTH, MAX_FILES_PER_COMMENT, MAX_FILES_PER_DOCUMENT, MAX_LANGUAGE_TAG_LENGTH, MAX_LINK_LABEL_LENGTH, MAX_LINKS, MAX_LOGIN_LENGTH, MAX_NOTE_LENGTH, MAX_OPTION_LABEL_LENGTH, MAX_OPTIONS, MAX_PROJECT_DESCRIPTION_LENGTH, MAX_PROJECT_ICON_BYTES, MAX_PROJECT_KEY_LENGTH, MAX_PROJECT_NAME_LENGTH, MAX_PROJECT_SYMBOL_LENGTH, MAX_QUESTION_LENGTH, MAX_REPORTS_PER_RUN, MAX_RULES_LENGTH, MAX_SEARCH_LENGTH, MAX_SECRET_LENGTH, MAX_SKILLS_ADDRESS_LENGTH, MAX_SUMMARY_LENGTH, MAX_TITLE_LENGTH, MAX_TOKEN_DAYS, MAX_TOKEN_NAME_LENGTH, MAX_TOKENS_PER_PERSON, MAX_URL_LENGTH, MAX_VERSIONS_PER_DOCUMENT, MIN_OPTIONS, } from "./limits.js";
6
+ export { DEFAULT_PAGE_LIMIT, DEFAULT_TOKEN_DAYS, EVENTS_PAGE_LIMIT, LIST_LIMIT, MAX_AGENT_LENGTH, MAX_ARTIFACTS_PER_RUN, MAX_BODY_LENGTH, MAX_CATEGORIES, MAX_CATEGORY_KEY_LENGTH, MAX_CATEGORY_NAME_LENGTH, MAX_COMMENTS_PER_TASK, MAX_DOCUMENT_LENGTH, MAX_DOCUMENT_PATH_LENGTH, MAX_DOCUMENT_SEGMENT_LENGTH, MAX_FILE_BYTES, MAX_FILE_NAME_LENGTH, MAX_FILES_PER_COMMENT, MAX_FILES_PER_DOCUMENT, MAX_LANGUAGE_TAG_LENGTH, MAX_LINK_LABEL_LENGTH, MAX_LINKS, MAX_LOGIN_LENGTH, MAX_NOTE_LENGTH, MAX_OPTION_LABEL_LENGTH, MAX_OPTIONS, MAX_PROJECT_DESCRIPTION_LENGTH, MAX_PROJECT_ICON_BYTES, MAX_PROJECT_KEY_LENGTH, MAX_PROJECT_NAME_LENGTH, MAX_PROJECT_SYMBOL_LENGTH, MAX_QUESTION_LENGTH, MAX_REPORTS_PER_RUN, MAX_RULES_LENGTH, MAX_SEARCH_LENGTH, MAX_SECRET_LENGTH, MAX_SKILLS_ADDRESS_LENGTH, MAX_SUMMARY_LENGTH, MAX_TITLE_LENGTH, MAX_TOKEN_DAYS, MAX_TOKEN_NAME_LENGTH, MAX_TOKENS_PER_PERSON, MAX_URL_LENGTH, MAX_VERSIONS_PER_DOCUMENT, MAX_WORKERS, MIN_OPTIONS, } from "./limits.js";
7
7
  export { projectColorOf, projectSymbolOf } from "./marks.js";
8
8
  export { AUTH_ROUTES, CLAIM_PATH, categoryPath, connectPath, isSignInFailure, loginPath, PROJECT_COLLECTIONS, type ProjectCollection, personTokensPath, personWorkPath, projectIconPath, projectPath, REST_ROUTES, RETURN_TO_PARAM, restPath, rulesPath, SIGN_IN_FAILURES, SIGN_IN_PARAM, type SignInFailure, signInPath, } from "./routes.js";
9
9
  export { fillRules, isReferenceRules, languageNameOf, PROJECT_RULES_TEMPLATE, REFERENCE_RULES, RULES_LANGUAGE_PLACEHOLDER, RULES_PATH, RULES_TITLE, } from "./rules.js";
10
10
  export { hostOfLogin, isLoginAt, type RestAnswerInput, type RestArchivedTasks, type RestArchiveTasksInput, type RestArtifact, type RestArtifactInput, type RestBacklink, type RestCategories, type RestCategory, type RestCategoryInput, type RestCategoryPatch, type RestClaim, type RestClaimInput, type RestComment, type RestCommentFile, type RestCommentInput, type RestComments, type RestConnectInput, type RestConnection, type RestConnectRequest, type RestDecision, type RestDecisionInput, type RestDecisionOption, type RestDecisionPatch, type RestDecisions, type RestDocument, type RestDocumentFile, type RestDocumentInput, type RestDocumentLink, type RestDocumentSummary, type RestDocuments, type RestError, type RestEvent, type RestEventData, type RestEvents, type RestFile, type RestFileInput, type RestGoal, type RestGoalInput, type RestGoalPatch, type RestGoals, type RestListing, type RestListingInput, type RestMe, type RestMember, type RestMemberInput, type RestMemberPatch, type RestMembers, type RestMePatch, type RestOrganization, type RestPackConnect, type RestPackConnectStarted, type RestPackRefusal, type RestPackTokenInput, type RestPeople, type RestPerson, type RestPersonPatch, type RestPersonWork, type RestProject, type RestProjectIcon, type RestProjectInput, type RestProjectPatch, type RestProjectRules, type RestProjects, type RestProvider, type RestReport, type RestReportInput, type RestRules, type RestRulesInput, type RestRun, type RestRunEndInput, type RestRunInput, type RestRuns, type RestSkill, type RestSkillBrowse, type RestSkillFile, type RestSkillFind, type RestSkillLoad, type RestSkills, type RestTask, type RestTaskCounts, type RestTaskInput, type RestTaskLink, type RestTaskPatch, type RestTasks, type RestToken, type RestTokenCreated, type RestTokenInput, type RestTokens, type RestVersion, type RestVersionSummary, type RestVersions, type RestWork, type RestWorkspace, type RestWorkspacePackConnect, type RestWorkspacePatch, restAnswerInputSchema, restArchivedTasksSchema, restArchiveTasksInputSchema, restArtifactInputSchema, restArtifactSchema, restBacklinkSchema, restCategoriesSchema, restCategoryInputSchema, restCategoryPatchSchema, restCategorySchema, restClaimInputSchema, restClaimSchema, restCommentFileSchema, restCommentInputSchema, restCommentSchema, restCommentsSchema, restConnectInputSchema, restConnectionSchema, restConnectRequestSchema, restDecisionInputSchema, restDecisionOptionSchema, restDecisionPatchSchema, restDecisionSchema, restDecisionsSchema, restDocumentFileSchema, restDocumentInputSchema, restDocumentLinkSchema, restDocumentSchema, restDocumentSummarySchema, restDocumentsSchema, restErrorSchema, restEventDataSchema, restEventSchema, restEventsSchema, restFileInputSchema, restFileSchema, restGoalInputSchema, restGoalPatchSchema, restGoalSchema, restGoalsSchema, restListingInputSchema, restListingSchema, restMemberInputSchema, restMemberPatchSchema, restMemberSchema, restMembersSchema, restMePatchSchema, restMeSchema, restOrganizationSchema, restPackConnectSchema, restPackConnectStartedSchema, restPackRefusalSchema, restPackTokenInputSchema, restPeopleSchema, restPersonPatchSchema, restPersonSchema, restPersonWorkSchema, restProjectIconSchema, restProjectInputSchema, restProjectPatchSchema, restProjectRulesSchema, restProjectSchema, restProjectsSchema, restProviderSchema, restReportInputSchema, restReportSchema, restRulesInputSchema, restRulesSchema, restRunEndInputSchema, restRunInputSchema, restRunSchema, restRunsSchema, restSkillBrowseSchema, restSkillFileSchema, restSkillFindSchema, restSkillLoadSchema, restSkillSchema, restSkillsSchema, restTaskCountsSchema, restTaskInputSchema, restTaskLinkSchema, restTaskPatchSchema, restTaskSchema, restTasksSchema, restTokenCreatedSchema, restTokenInputSchema, restTokenSchema, restTokensSchema, restVersionSchema, restVersionSummarySchema, restVersionsSchema, restWorkSchema, restWorkspacePackConnectSchema, restWorkspacePatchSchema, restWorkspaceSchema, } from "./schemas.js";
11
11
  export { hasForbiddenCodePoint } from "./text.js";
12
- export { ARTIFACT_KINDS, type ArtifactKind, CATEGORY_COLORS, type CategoryColor, COLOR_NAMES, type ColorName, EVENT_KINDS, type EventKind, GOAL_STATES, type GoalState, isProviderKey, LINK_SOURCES, type LinkSource, MEMBERSHIP_SOURCES, type MembershipSource, OPEN_TASK_STATES, PACK_CONNECT_ENDINGS, type PackConnectEnding, PEOPLE_VISIBILITIES, PERSON_ROLES, PERSON_STATUSES, type PeopleVisibility, type PersonRole, type PersonStatus, PROJECT_ICON_TYPES, PROJECT_ROLES, PROJECT_VISIBILITIES, PROVIDER_KEYS, type ProjectIconType, type ProjectRole, type ProjectVisibility, type ProviderKey, RULES_SOURCES, RUN_ENDINGS, RUN_STATUSES, type RulesSource, type RunEnding, type RunStatus, SKILLS_STATUSES, type SkillsStatus, TASK_PRIORITIES, TASK_STATES, type TaskPriority, type TaskState, WEEK_STARTS, type WeekStart, } from "./vocabulary.js";
12
+ export { ARTIFACT_KINDS, type ArtifactKind, CATEGORY_COLORS, type CategoryColor, COLOR_NAMES, type ColorName, EVENT_KINDS, type EventKind, GOAL_STATES, type GoalState, isProviderKey, LINK_SOURCES, type LinkSource, MEMBERSHIP_SOURCES, type MembershipSource, OPEN_GOAL_STATES, OPEN_TASK_STATES, PACK_CONNECT_ENDINGS, type PackConnectEnding, PEOPLE_VISIBILITIES, PERSON_ROLES, PERSON_STATUSES, type PeopleVisibility, type PersonRole, type PersonStatus, PROJECT_ICON_TYPES, PROJECT_ROLES, PROJECT_VISIBILITIES, PROVIDER_KEYS, type ProjectIconType, type ProjectRole, type ProjectVisibility, type ProviderKey, RULES_SOURCES, RUN_ENDINGS, RUN_STATUSES, type RulesSource, type RunEnding, type RunStatus, SKILLS_STATUSES, type SkillsStatus, TASK_PRIORITIES, TASK_STATES, type TaskPriority, type TaskState, WEEK_STARTS, type WeekStart, } from "./vocabulary.js";
13
13
  //# sourceMappingURL=api.d.ts.map
package/dist/api.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../src/api.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EACL,QAAQ,EACR,KAAK,aAAa,EAClB,KAAK,YAAY,EACjB,KAAK,aAAa,EAClB,Y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cAAc,CAAC;AACtB,OAAO,EAAE,qBAAqB,EAAE,MAAM,WAAW,CAAC;AAClD,OAAO,EACL,cAAc,EACd,KAAK,YAAY,EACjB,eAAe,EACf,KAAK,aAAa,EAClB,WAAW,EACX,KAAK,SAAS,EACd,WAAW,EACX,KAAK,SAAS,EACd,WAAW,EACX,KAAK,SAAS,EACd,aAAa,EACb,YAAY,EACZ,KAAK,UAAU,EACf,kBAAkB,EAClB,KAAK,gBAAgB,EACrB,gBAAgB,EAChB,oBAAoB,EACpB,KAAK,iBAAiB,EACtB,mBAAmB,EACnB,YAAY,EACZ,eAAe,EACf,KAAK,gBAAgB,EACrB,KAAK,UAAU,EACf,KAAK,YAAY,EACjB,kBAAkB,EAClB,aAAa,EACb,oBAAoB,EACpB,aAAa,EACb,KAAK,eAAe,EACpB,KAAK,WAAW,EAChB,KAAK,iBAAiB,EACtB,KAAK,WAAW,EAChB,aAAa,EACb,WAAW,EACX,YAAY,EACZ,KAAK,WAAW,EAChB,KAAK,SAAS,EACd,KAAK,SAAS,EACd,eAAe,EACf,KAAK,YAAY,EACjB,eAAe,EACf,WAAW,EACX,KAAK,YAAY,EACjB,KAAK,SAAS,EACd,WAAW,EACX,KAAK,SAAS,GACf,MAAM,iBAAiB,CAAC"}
1
+ {"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../src/api.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EACL,QAAQ,EACR,KAAK,aAAa,EAClB,KAAK,YAAY,EACjB,KAAK,aAAa,EAClB,YAAY,EACZ,KAAK,cAAc,EACnB,KAAK,WAAW,EAChB,KAAK,SAAS,EACd,KAAK,QAAQ,EACb,KAAK,UAAU,EACf,KAAK,UAAU,EACf,KAAK,IAAI,EACT,KAAK,aAAa,EAClB,KAAK,UAAU,GAChB,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,aAAa,EACb,cAAc,EACd,mBAAmB,EACnB,KAAK,eA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EACX,KAAK,SAAS,EACd,aAAa,EACb,YAAY,EACZ,KAAK,UAAU,EACf,kBAAkB,EAClB,KAAK,gBAAgB,EACrB,gBAAgB,EAChB,gBAAgB,EAChB,oBAAoB,EACpB,KAAK,iBAAiB,EACtB,mBAAmB,EACnB,YAAY,EACZ,eAAe,EACf,KAAK,gBAAgB,EACrB,KAAK,UAAU,EACf,KAAK,YAAY,EACjB,kBAAkB,EAClB,aAAa,EACb,oBAAoB,EACpB,aAAa,EACb,KAAK,eAAe,EACpB,KAAK,WAAW,EAChB,KAAK,iBAAiB,EACtB,KAAK,WAAW,EAChB,aAAa,EACb,WAAW,EACX,YAAY,EACZ,KAAK,WAAW,EAChB,KAAK,SAAS,EACd,KAAK,SAAS,EACd,eAAe,EACf,KAAK,YAAY,EACjB,eAAe,EACf,WAAW,EACX,KAAK,YAAY,EACjB,KAAK,SAAS,EACd,WAAW,EACX,KAAK,SAAS,GACf,MAAM,iBAAiB,CAAC"}
package/dist/api.js CHANGED
@@ -4,14 +4,14 @@
4
4
  // here: the server and the command line import this entry point, and nothing of the pages.
5
5
  export { agentLabel } from "./agent-name.js";
6
6
  export { ApiError, createClient, } from "./client.js";
7
- export { CLIENT_POLICY, CLIENT_PRODUCT, CLIENT_RANGE_HEADER, clientRange, clientVersionOf, commonRange, compareVersions, formatRange, formatVersion, inRange, judgeClient, parseRange, parseVersion, userAgentOf, VERSION_HEADER, } from "./compat.js";
7
+ export { CLIENT_POLICY, CLIENT_PRODUCT, CLIENT_RANGE_HEADER, CONSOLE_AT_LEAST, clientRange, clientVersionOf, commonRange, compareVersions, consoleRange, formatRange, formatVersion, inRange, judgeClient, judgeConsole, parseRange, parseVersion, userAgentOf, VERSION_HEADER, } from "./compat.js";
8
8
  export { CONNECT_CODE_ALPHABET, CONNECT_CODE_LENGTH, isConnectCode, normalizeConnectCode, } from "./connect.js";
9
9
  export { DOCUMENT_PATH, documentPathsIn, folderOf, foldersAbove, isDocumentPath, isFolderPath, nameOf, } from "./documents.js";
10
- export { DEFAULT_PAGE_LIMIT, DEFAULT_TOKEN_DAYS, EVENTS_PAGE_LIMIT, LIST_LIMIT, MAX_AGENT_LENGTH, MAX_ARTIFACTS_PER_RUN, MAX_BODY_LENGTH, MAX_CATEGORIES, MAX_CATEGORY_KEY_LENGTH, MAX_CATEGORY_NAME_LENGTH, MAX_COMMENTS_PER_TASK, MAX_DOCUMENT_LENGTH, MAX_DOCUMENT_PATH_LENGTH, MAX_DOCUMENT_SEGMENT_LENGTH, MAX_FILE_BYTES, MAX_FILE_NAME_LENGTH, MAX_FILES_PER_COMMENT, MAX_FILES_PER_DOCUMENT, MAX_LANGUAGE_TAG_LENGTH, MAX_LINK_LABEL_LENGTH, MAX_LINKS, MAX_LOGIN_LENGTH, MAX_NOTE_LENGTH, MAX_OPTION_LABEL_LENGTH, MAX_OPTIONS, MAX_PROJECT_DESCRIPTION_LENGTH, MAX_PROJECT_ICON_BYTES, MAX_PROJECT_KEY_LENGTH, MAX_PROJECT_NAME_LENGTH, MAX_PROJECT_SYMBOL_LENGTH, MAX_QUESTION_LENGTH, MAX_REPORTS_PER_RUN, MAX_RULES_LENGTH, MAX_SEARCH_LENGTH, MAX_SECRET_LENGTH, MAX_SKILLS_ADDRESS_LENGTH, MAX_SUMMARY_LENGTH, MAX_TITLE_LENGTH, MAX_TOKEN_DAYS, MAX_TOKEN_NAME_LENGTH, MAX_TOKENS_PER_PERSON, MAX_URL_LENGTH, MAX_VERSIONS_PER_DOCUMENT, MIN_OPTIONS, } from "./limits.js";
10
+ export { DEFAULT_PAGE_LIMIT, DEFAULT_TOKEN_DAYS, EVENTS_PAGE_LIMIT, LIST_LIMIT, MAX_AGENT_LENGTH, MAX_ARTIFACTS_PER_RUN, MAX_BODY_LENGTH, MAX_CATEGORIES, MAX_CATEGORY_KEY_LENGTH, MAX_CATEGORY_NAME_LENGTH, MAX_COMMENTS_PER_TASK, MAX_DOCUMENT_LENGTH, MAX_DOCUMENT_PATH_LENGTH, MAX_DOCUMENT_SEGMENT_LENGTH, MAX_FILE_BYTES, MAX_FILE_NAME_LENGTH, MAX_FILES_PER_COMMENT, MAX_FILES_PER_DOCUMENT, MAX_LANGUAGE_TAG_LENGTH, MAX_LINK_LABEL_LENGTH, MAX_LINKS, MAX_LOGIN_LENGTH, MAX_NOTE_LENGTH, MAX_OPTION_LABEL_LENGTH, MAX_OPTIONS, MAX_PROJECT_DESCRIPTION_LENGTH, MAX_PROJECT_ICON_BYTES, MAX_PROJECT_KEY_LENGTH, MAX_PROJECT_NAME_LENGTH, MAX_PROJECT_SYMBOL_LENGTH, MAX_QUESTION_LENGTH, MAX_REPORTS_PER_RUN, MAX_RULES_LENGTH, MAX_SEARCH_LENGTH, MAX_SECRET_LENGTH, MAX_SKILLS_ADDRESS_LENGTH, MAX_SUMMARY_LENGTH, MAX_TITLE_LENGTH, MAX_TOKEN_DAYS, MAX_TOKEN_NAME_LENGTH, MAX_TOKENS_PER_PERSON, MAX_URL_LENGTH, MAX_VERSIONS_PER_DOCUMENT, MAX_WORKERS, MIN_OPTIONS, } from "./limits.js";
11
11
  export { projectColorOf, projectSymbolOf } from "./marks.js";
12
12
  export { AUTH_ROUTES, CLAIM_PATH, categoryPath, connectPath, isSignInFailure, loginPath, PROJECT_COLLECTIONS, personTokensPath, personWorkPath, projectIconPath, projectPath, REST_ROUTES, RETURN_TO_PARAM, restPath, rulesPath, SIGN_IN_FAILURES, SIGN_IN_PARAM, signInPath, } from "./routes.js";
13
13
  export { fillRules, isReferenceRules, languageNameOf, PROJECT_RULES_TEMPLATE, REFERENCE_RULES, RULES_LANGUAGE_PLACEHOLDER, RULES_PATH, RULES_TITLE, } from "./rules.js";
14
14
  export { hostOfLogin, isLoginAt, restAnswerInputSchema, restArchivedTasksSchema, restArchiveTasksInputSchema, restArtifactInputSchema, restArtifactSchema, restBacklinkSchema, restCategoriesSchema, restCategoryInputSchema, restCategoryPatchSchema, restCategorySchema, restClaimInputSchema, restClaimSchema, restCommentFileSchema, restCommentInputSchema, restCommentSchema, restCommentsSchema, restConnectInputSchema, restConnectionSchema, restConnectRequestSchema, restDecisionInputSchema, restDecisionOptionSchema, restDecisionPatchSchema, restDecisionSchema, restDecisionsSchema, restDocumentFileSchema, restDocumentInputSchema, restDocumentLinkSchema, restDocumentSchema, restDocumentSummarySchema, restDocumentsSchema, restErrorSchema, restEventDataSchema, restEventSchema, restEventsSchema, restFileInputSchema, restFileSchema, restGoalInputSchema, restGoalPatchSchema, restGoalSchema, restGoalsSchema, restListingInputSchema, restListingSchema, restMemberInputSchema, restMemberPatchSchema, restMemberSchema, restMembersSchema, restMePatchSchema, restMeSchema, restOrganizationSchema, restPackConnectSchema, restPackConnectStartedSchema, restPackRefusalSchema, restPackTokenInputSchema, restPeopleSchema, restPersonPatchSchema, restPersonSchema, restPersonWorkSchema, restProjectIconSchema, restProjectInputSchema, restProjectPatchSchema, restProjectRulesSchema, restProjectSchema, restProjectsSchema, restProviderSchema, restReportInputSchema, restReportSchema, restRulesInputSchema, restRulesSchema, restRunEndInputSchema, restRunInputSchema, restRunSchema, restRunsSchema, restSkillBrowseSchema, restSkillFileSchema, restSkillFindSchema, restSkillLoadSchema, restSkillSchema, restSkillsSchema, restTaskCountsSchema, restTaskInputSchema, restTaskLinkSchema, restTaskPatchSchema, restTaskSchema, restTasksSchema, restTokenCreatedSchema, restTokenInputSchema, restTokenSchema, restTokensSchema, restVersionSchema, restVersionSummarySchema, restVersionsSchema, restWorkSchema, restWorkspacePackConnectSchema, restWorkspacePatchSchema, restWorkspaceSchema, } from "./schemas.js";
15
15
  export { hasForbiddenCodePoint } from "./text.js";
16
- export { ARTIFACT_KINDS, CATEGORY_COLORS, COLOR_NAMES, EVENT_KINDS, GOAL_STATES, isProviderKey, LINK_SOURCES, MEMBERSHIP_SOURCES, OPEN_TASK_STATES, PACK_CONNECT_ENDINGS, PEOPLE_VISIBILITIES, PERSON_ROLES, PERSON_STATUSES, PROJECT_ICON_TYPES, PROJECT_ROLES, PROJECT_VISIBILITIES, PROVIDER_KEYS, RULES_SOURCES, RUN_ENDINGS, RUN_STATUSES, SKILLS_STATUSES, TASK_PRIORITIES, TASK_STATES, WEEK_STARTS, } from "./vocabulary.js";
16
+ export { ARTIFACT_KINDS, CATEGORY_COLORS, COLOR_NAMES, EVENT_KINDS, GOAL_STATES, isProviderKey, LINK_SOURCES, MEMBERSHIP_SOURCES, OPEN_GOAL_STATES, OPEN_TASK_STATES, PACK_CONNECT_ENDINGS, PEOPLE_VISIBILITIES, PERSON_ROLES, PERSON_STATUSES, PROJECT_ICON_TYPES, PROJECT_ROLES, PROJECT_VISIBILITIES, PROVIDER_KEYS, RULES_SOURCES, RUN_ENDINGS, RUN_STATUSES, SKILLS_STATUSES, TASK_PRIORITIES, TASK_STATES, WEEK_STARTS, } from "./vocabulary.js";
17
17
  //# sourceMappingURL=api.js.map
package/dist/api.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"api.js","sourceRoot":"","sources":["../src/api.ts"],"names":[],"mappings":"AAAA,sFAAsF;AACtF,8FAA8F;AAC9F,+FAA+F;AAC/F,2FAA2F;AAE3F,OAAO,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAC7C,OAAO,EACL,QAAQ,EAIR,YAAY,GAUb,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,aAAa,EACb,cAAc,EACd,mBAAmB,EAInB,WAAW,EACX,eAAe,EACf,WAAW,EACX,eAAe,EACf,WAAW,EACX,aAAa,EACb,OAAO,EACP,WAAW,EACX,UAAU,EACV,YAAY,EACZ,WAAW,EACX,cAAc,GAGf,MAAM,aAAa,CAAC;AACrB,OAAO,EACL,qBAAqB,EACrB,mBAAmB,EACnB,aAAa,EACb,oBAAoB,GACrB,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,aAAa,EACb,eAAe,EACf,QAAQ,EACR,YAAY,EACZ,cAAc,EACd,YAAY,EACZ,MAAM,GACP,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACL,kBAAkB,EAClB,k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B,EAChB,oBAAoB,EAEpB,mBAAmB,EACnB,YAAY,EACZ,eAAe,EAIf,kBAAkB,EAClB,aAAa,EACb,oBAAoB,EACpB,aAAa,EAKb,aAAa,EACb,WAAW,EACX,YAAY,EAIZ,eAAe,EAEf,eAAe,EACf,WAAW,EAGX,WAAW,GAEZ,MAAM,iBAAiB,CAAC"}
package/dist/cli/cli.d.ts CHANGED
@@ -44,6 +44,10 @@ export interface CliIo {
44
44
  readonly install?: Install | undefined;
45
45
  /** What the command last said of the versions; left out, it says it every time. */
46
46
  readonly notices?: NoticeStore | undefined;
47
+ /** The oldest console this command works with (ADR-0038); left out, the package's own floor. */
48
+ readonly consoleAtLeast?: string | undefined;
49
+ /** The language and region of this machine (`ko-KR`), for what follows a language where the person chose none; left out, English. */
50
+ readonly locale?: string | undefined;
47
51
  /** Where the console's own skills are on this machine, shipped with the package; nothing when they are not there. */
48
52
  readonly skillsDir?: string | undefined;
49
53
  /** How `serve` listens on the loopback (ADR-0014); left out, the command cannot serve. */
@@ -1 +1 @@
1
- {"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../src/cli/cli.ts"],"names":[],"mappings":"AAEA,OAAO,EAIL,KAAK,SAAS,EAEf,MAAM,cAAc,CAAC;AAwCtB,OAAO,EACL,KAAK,eAAe,EASrB,MAAM,kBAAkB,CAAC;AAC1B,OAAO,EAA0B,KAAK,cAAc,EAAgB,MAAM,gBAAgB,CAAC;AAgC3F,OAAO,EAAmB,KAAK,OAAO,EAAoB,MAAM,cAAc,CAAC;AAC/E,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAiBhD,OAAO,EAA0C,KAAK,MAAM,EAAE,MAAM,YAAY,CAAC;AAQjF,qFAAqF;AACrF,eAAO,MAAM,IAAI;aACf,EAAE,EAAE,CAAC;IACL,6EAA6E;aAC7E,MAAM,EAAE,CAAC;IACT,sCAAsC;aACtC,KAAK,EAAE,CAAC;IACR,6CAA6C;aAC7C,OAAO,EAAE,CAAC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,GAAG,SAAS,CAAC;IACvC,mFAAmF;IACnF,QAAQ,CAAC,OAAO,CAAC,EAAE,WAAW,GAAG,SAAS,CAAC;IAC3C,gGAAgG;IAChG,QAAQ,CAAC,cAAc,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC7C,qIAAqI;IACrI,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,qHAAqH;IACrH,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACxC,0FAA0F;IAC1F,QAAQ,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACtC;AA+zFD,yFAAyF;AACzF,wBAAsB,MAAM,CAAC,IAAI,EAAE,SAAS,MAAM,EAAE,EAAE,EAAE,EAAE,KAAK,GAAG,OAAO,CAAC,MAAM,CAAC,CAyDhF"}
package/dist/cli/cli.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import { basename, extname } from "node:path";
2
2
  import { parseArgs } from "node:util";
3
3
  import { ApiError, createClient, } from "../client.js";
4
- import { CLIENT_RANGE_HEADER, judgeClient, parseVersion, VERSION_HEADER } from "../compat.js";
5
- import { addDays, dayOf as dayOfDate, isDay } from "../dates.js";
4
+ import { CLIENT_RANGE_HEADER, CONSOLE_AT_LEAST, consoleRange, formatRange, judgeClient, judgeConsole, parseVersion, VERSION_HEADER, formatVersion as versionText, } from "../compat.js";
5
+ import { addDays, dayOf as dayOfDate, firstDayOfWeek, isDay, weekOf } from "../dates.js";
6
6
  import { DEFAULT_PAGE_LIMIT, LIST_LIMIT, MAX_OPTIONS, MIN_OPTIONS } from "../limits.js";
7
7
  import { fillRules, RULES_PATH, RULES_TITLE } from "../rules.js";
8
8
  import { hostOfLogin, } from "../schemas.js";
@@ -606,10 +606,13 @@ const whoami = async (args, io) => {
606
606
  const verdict = command === undefined || server === undefined
607
607
  ? undefined
608
608
  : judgeClient(command, server).verdict;
609
+ // The oldest console this command works with (ADR-0038), as it stands within the command's line.
610
+ const atLeast = io.consoleAtLeast ?? CONSOLE_AT_LEAST;
611
+ const floor = command === undefined ? atLeast : versionText(consoleRange(command, atLeast).atLeast);
609
612
  // A console from before the rule says nothing of itself; the command says so instead.
610
613
  const consoleWords = me.console === undefined
611
614
  ? "the console does not say its version, so it is older than 0.1.18"
612
- : `the console is ${me.console.version} and takes ${me.console.clientRange}`;
615
+ : `the console is ${me.console.version} and takes ${me.console.clientRange}; this command works with a console from ${floor} on`;
613
616
  answer(io, session, {
614
617
  ...me,
615
618
  console: me.console ?? null,
@@ -673,6 +676,15 @@ const use = async (args, io) => {
673
676
  ].join("\n"));
674
677
  return EXIT.ok;
675
678
  };
679
+ /**
680
+ * The last day of this week (ADR-0039): the week begins as the workspace says, or, left to the
681
+ * language, as the person's language has it, else this machine's.
682
+ */
683
+ async function endOfWeek(io, session, today) {
684
+ const me = await session.client.me();
685
+ const language = me.language ?? io.locale ?? "en";
686
+ return weekOf(today, firstDayOfWeek(language, me.workspace.weekStart ?? "auto")).at(-1) ?? today;
687
+ }
676
688
  const tasks = async (args, io) => {
677
689
  const { values } = parse(args, {
678
690
  state: { type: "string" },
@@ -682,12 +694,13 @@ const tasks = async (args, io) => {
682
694
  category: { type: "string" },
683
695
  goal: { type: "string" },
684
696
  due: { type: "string" },
697
+ search: { type: "string" },
685
698
  archived: { type: "boolean" },
686
699
  ...PAGE_OPTIONS,
687
700
  }, false);
688
701
  const state = stateOf(text(values, "state"));
689
702
  if (on(values, "mine") && on(values, "unassigned")) {
690
- throw misuse("Say one: --mine for the tasks assigned to you, or --unassigned for those assigned to nobody");
703
+ throw misuse("Say one: --mine for the tasks you work on, or --unassigned for those nobody works on");
691
704
  }
692
705
  const page = pageOf(values);
693
706
  const session = await open(io, values);
@@ -700,19 +713,22 @@ const tasks = async (args, io) => {
700
713
  : due === "overdue"
701
714
  ? addDays(today, -1)
702
715
  : due === "week"
703
- ? addDays(today, 6)
716
+ ? await endOfWeek(io, session, today)
704
717
  : (dayOf(io, due) ?? undefined);
705
- const assignee = on(values, "mine")
706
- ? ((await personIdOf(session, "me")) ?? undefined)
707
- : undefined;
718
+ const worker = on(values, "mine") ? ((await personIdOf(session, "me")) ?? undefined) : undefined;
719
+ const search = text(values, "search")?.trim();
720
+ if (search === "") {
721
+ throw misuse("Say what to search for: console tasks --search <words>");
722
+ }
708
723
  const found = await project.tasks({
709
724
  ...(state === undefined ? {} : { state }),
710
725
  ...(on(values, "open") || due === "overdue" ? { open: true } : {}),
711
- ...(assignee === undefined ? {} : { assignee }),
726
+ ...(worker === undefined ? {} : { worker }),
712
727
  ...(on(values, "unassigned") ? { unassigned: true } : {}),
713
728
  ...(text(values, "category") === undefined ? {} : { category: text(values, "category") }),
714
729
  ...(text(values, "goal") === undefined ? {} : { goal: text(values, "goal") }),
715
730
  ...(dueBy === undefined ? {} : { dueBy }),
731
+ ...(search === undefined ? {} : { q: search }),
716
732
  ...(on(values, "archived") ? { archived: true } : {}),
717
733
  ...page,
718
734
  });
@@ -980,9 +996,37 @@ const TASK_FIELDS = {
980
996
  goal: { type: "string" },
981
997
  starts: { type: "string" },
982
998
  due: { type: "string" },
983
- assignee: { type: "string" },
999
+ worker: { type: "string", multiple: true },
984
1000
  parent: { type: "string" },
985
1001
  };
1002
+ /**
1003
+ * The people `--worker` names, each a login or `me`, given again or with commas between for
1004
+ * several, in place of those there were; `none` alone for nobody; nothing when the flag was
1005
+ * not given.
1006
+ */
1007
+ async function workerIdsOf(session, given) {
1008
+ if (given.length === 0) {
1009
+ return undefined;
1010
+ }
1011
+ const names = given
1012
+ .flatMap((value) => value.split(","))
1013
+ .map((name) => name.trim())
1014
+ .filter((name) => name.length > 0);
1015
+ if (names.includes("none")) {
1016
+ if (names.length > 1) {
1017
+ throw misuse("Say --worker none alone, for nobody; or the logins of the workers.");
1018
+ }
1019
+ return [];
1020
+ }
1021
+ const ids = [];
1022
+ for (const name of names) {
1023
+ const id = await personIdOf(session, name);
1024
+ if (typeof id === "string" && !ids.includes(id)) {
1025
+ ids.push(id);
1026
+ }
1027
+ }
1028
+ return ids;
1029
+ }
986
1030
  /** What the flags say of a task's fields, as the API takes them; `none` clears a field. */
987
1031
  async function taskFieldsOf(io, session, project, values) {
988
1032
  const state = stateOf(text(values, "state"));
@@ -991,7 +1035,7 @@ async function taskFieldsOf(io, session, project, values) {
991
1035
  const goalId = orNone(text(values, "goal"));
992
1036
  const startsOn = dayOf(io, text(values, "starts"), true);
993
1037
  const dueOn = dayOf(io, text(values, "due"), true);
994
- const assigneeId = await personIdOf(session, text(values, "assignee"));
1038
+ const workerIds = await workerIdsOf(session, texts(values, "worker"));
995
1039
  const parent = text(values, "parent");
996
1040
  const parentId = parent === undefined ? undefined : parent === "none" ? null : (await project.task(parent)).id;
997
1041
  return {
@@ -1001,7 +1045,7 @@ async function taskFieldsOf(io, session, project, values) {
1001
1045
  ...(goalId === undefined ? {} : { goalId }),
1002
1046
  ...(startsOn === undefined ? {} : { startsOn }),
1003
1047
  ...(dueOn === undefined ? {} : { dueOn }),
1004
- ...(assigneeId === undefined ? {} : { assigneeId }),
1048
+ ...(workerIds === undefined ? {} : { workerIds }),
1005
1049
  ...(parentId === undefined ? {} : { parentId }),
1006
1050
  };
1007
1051
  }
@@ -1042,7 +1086,7 @@ const editTask = async (args, io) => {
1042
1086
  ...(await taskFieldsOf(io, session, project, values)),
1043
1087
  };
1044
1088
  if (Object.keys(patch).length === 0) {
1045
- throw misuse("Say what to change: --title, --body, --state, --priority, --category, --goal, --starts, --due, --assignee or --parent; none clears a field.");
1089
+ throw misuse("Say what to change: --title, --body, --state, --priority, --category, --goal, --starts, --due, --worker or --parent; none clears a field.");
1046
1090
  }
1047
1091
  const found = await project.task(ref);
1048
1092
  const changed = await project.updateTask(found.id, patch);
@@ -1487,20 +1531,33 @@ const restore = async (args, io) => {
1487
1531
  return EXIT.ok;
1488
1532
  };
1489
1533
  const goals = async (args, io) => {
1490
- const { values } = parse(args, { category: { type: "string" }, state: { type: "string" } }, false);
1534
+ const { values } = parse(args, {
1535
+ category: { type: "string" },
1536
+ state: { type: "string" },
1537
+ search: { type: "string" },
1538
+ ...PAGE_OPTIONS,
1539
+ }, false);
1491
1540
  const state = goalStateOf(text(values, "state"));
1492
1541
  const category = text(values, "category");
1542
+ const search = text(values, "search")?.trim();
1543
+ if (search === "") {
1544
+ throw misuse("Say what to search for: console goals --search <words>");
1545
+ }
1546
+ const page = pageOf(values);
1493
1547
  const session = await open(io, values);
1494
1548
  const project = await session.project();
1495
1549
  const found = await project.goals({
1496
1550
  ...(state === undefined ? {} : { state }),
1497
1551
  ...(category === undefined ? {} : { category }),
1552
+ ...(search === undefined ? {} : { q: search }),
1553
+ ...page,
1498
1554
  });
1499
1555
  answer(io, session, found, () => found.items.length === 0
1500
- ? state === undefined && category === undefined
1556
+ ? state === undefined && category === undefined && search === undefined
1501
1557
  ? "No goals. An owner sets one: console goal new <title> --due <day>"
1502
1558
  : "No goal matches."
1503
- : found.items.map(formatGoalLine).join("\n"));
1559
+ : found.items.map(formatGoalLine).join("\n") +
1560
+ formatMore(found.more, page.limit, page.offset));
1504
1561
  return EXIT.ok;
1505
1562
  };
1506
1563
  const GOAL_FIELDS = {
@@ -2238,11 +2295,35 @@ async function noticeVersions(io, seen) {
2238
2295
  shownAt: new Date(now).toISOString(),
2239
2296
  });
2240
2297
  }
2298
+ /**
2299
+ * The refusal of a console older than this command works with (ADR-0038), in a console's own
2300
+ * form: a `426` the command reads as it reads the console's, before it acts on anything the
2301
+ * console answered.
2302
+ */
2303
+ function consoleRefusal(io, seen) {
2304
+ const command = parseVersion(io.version);
2305
+ const server = parseVersion(seen.version);
2306
+ if (command === undefined || server === undefined) {
2307
+ return undefined;
2308
+ }
2309
+ const { verdict, range } = judgeConsole(server, command, io.consoleAtLeast ?? CONSOLE_AT_LEAST);
2310
+ if (verdict !== "outdated") {
2311
+ return undefined;
2312
+ }
2313
+ return Response.json({
2314
+ error: {
2315
+ code: "console.outdated",
2316
+ message: `This console, ${seen.version}, is older than this command (${io.version}) works with (${formatRange(range)}).`,
2317
+ },
2318
+ }, { status: 426 });
2319
+ }
2241
2320
  /** What a refusal of the console is followed by, when there is something to do about it. */
2242
2321
  function hintFor(error, io, seen) {
2243
2322
  switch (error.code) {
2244
2323
  case "client.outdated":
2245
2324
  return `Update the command: ${updateWords(io, seen.version)}\n`;
2325
+ case "console.outdated":
2326
+ return `Install the console's version: ${updateWords(io, seen.version)}; or ask the console's operator to update the console.\n`;
2246
2327
  case "client.too_new":
2247
2328
  return `Install the console's version: ${updateWords(io, seen.version)}; or ask the console's operator to update the console.\n`;
2248
2329
  case "auth.required":
@@ -2317,7 +2398,11 @@ export async function runCli(argv, io) {
2317
2398
  const response = await io.fetch(input, init);
2318
2399
  seen.version = response.headers.get(VERSION_HEADER) ?? seen.version;
2319
2400
  seen.range = response.headers.get(CLIENT_RANGE_HEADER) ?? seen.range;
2320
- return response;
2401
+ // A console older than this command works with is refused here (ADR-0038); `serve`
2402
+ // carries the pages' own requests, which are not the command's to judge.
2403
+ // A refusal of the console's own is passed on as it is.
2404
+ return ((name === "serve" || response.status === 426 ? undefined : consoleRefusal(io, seen)) ??
2405
+ response);
2321
2406
  },
2322
2407
  };
2323
2408
  try {
@@ -2348,7 +2433,9 @@ export async function runCli(argv, io) {
2348
2433
  }
2349
2434
  if (error instanceof ApiError) {
2350
2435
  io.stderr(`${error.code}: ${error.message}\n${hintFor(error, io, seen)}`);
2351
- return error.code === "client.outdated" || error.code === "client.too_new"
2436
+ return error.code === "client.outdated" ||
2437
+ error.code === "client.too_new" ||
2438
+ error.code === "console.outdated"
2352
2439
  ? EXIT.incompatible
2353
2440
  : EXIT.failed;
2354
2441
  }