@skillcdn/console 0.4.1 → 0.4.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.
- package/README.md +19 -2
- package/SKILLCDN.md +7 -5
- package/dist/api.d.ts +4 -3
- package/dist/api.d.ts.map +1 -1
- package/dist/api.js +4 -3
- package/dist/api.js.map +1 -1
- package/dist/cli/cli.d.ts.map +1 -1
- package/dist/cli/cli.js +543 -34
- package/dist/cli/cli.js.map +1 -1
- package/dist/cli/format.d.ts +34 -3
- package/dist/cli/format.d.ts.map +1 -1
- package/dist/cli/format.js +277 -6
- package/dist/cli/format.js.map +1 -1
- package/dist/cli/help.d.ts.map +1 -1
- package/dist/cli/help.js +35 -2
- package/dist/cli/help.js.map +1 -1
- package/dist/cli/plugin-check.d.ts +21 -0
- package/dist/cli/plugin-check.d.ts.map +1 -0
- package/dist/cli/plugin-check.js +374 -0
- package/dist/cli/plugin-check.js.map +1 -0
- package/dist/cli/plugin-cli.d.ts +20 -0
- package/dist/cli/plugin-cli.d.ts.map +1 -0
- package/dist/cli/plugin-cli.js +123 -0
- package/dist/cli/plugin-cli.js.map +1 -0
- package/dist/cli/plugin-init.d.ts +20 -0
- package/dist/cli/plugin-init.d.ts.map +1 -0
- package/dist/cli/plugin-init.js +74 -0
- package/dist/cli/plugin-init.js.map +1 -0
- package/dist/cli/plugin-main.d.ts +3 -0
- package/dist/cli/plugin-main.d.ts.map +1 -0
- package/dist/cli/plugin-main.js +28 -0
- package/dist/cli/plugin-main.js.map +1 -0
- package/dist/client.d.ts +97 -1
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +63 -2
- package/dist/client.js.map +1 -1
- package/dist/compat.d.ts +1 -1
- package/dist/compat.js +2 -2
- package/dist/components/board.d.ts +8 -0
- package/dist/components/board.d.ts.map +1 -1
- package/dist/components/board.js +59 -15
- package/dist/components/board.js.map +1 -1
- package/dist/components/event-feed.d.ts +1 -1
- package/dist/components/event-feed.d.ts.map +1 -1
- package/dist/components/event-feed.js +33 -1
- package/dist/components/event-feed.js.map +1 -1
- package/dist/components/plugin-frame.d.ts +52 -0
- package/dist/components/plugin-frame.d.ts.map +1 -0
- package/dist/components/plugin-frame.js +314 -0
- package/dist/components/plugin-frame.js.map +1 -0
- package/dist/components/plugin-settings.d.ts +38 -0
- package/dist/components/plugin-settings.d.ts.map +1 -0
- package/dist/components/plugin-settings.js +348 -0
- package/dist/components/plugin-settings.js.map +1 -0
- package/dist/components/shell.d.ts +2 -0
- package/dist/components/shell.d.ts.map +1 -1
- package/dist/components/shell.js +26 -1
- package/dist/components/shell.js.map +1 -1
- package/dist/components/workspace.d.ts +7 -1
- package/dist/components/workspace.d.ts.map +1 -1
- package/dist/components/workspace.js +1 -1
- package/dist/components/workspace.js.map +1 -1
- package/dist/console.css +327 -0
- package/dist/console.d.ts.map +1 -1
- package/dist/console.js +136 -26
- package/dist/console.js.map +1 -1
- package/dist/data.d.ts +7 -1
- package/dist/data.d.ts.map +1 -1
- package/dist/data.js +19 -2
- package/dist/data.js.map +1 -1
- package/dist/i18n/en.d.ts +149 -0
- package/dist/i18n/en.d.ts.map +1 -1
- package/dist/i18n/en.js +160 -0
- package/dist/i18n/en.js.map +1 -1
- package/dist/i18n/ko.d.ts.map +1 -1
- package/dist/i18n/ko.js +144 -0
- package/dist/i18n/ko.js.map +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -1
- package/dist/index.js.map +1 -1
- package/dist/plugin/args.d.ts +148 -0
- package/dist/plugin/args.d.ts.map +1 -0
- package/dist/plugin/args.js +369 -0
- package/dist/plugin/args.js.map +1 -0
- package/dist/plugin/bridge.d.ts +146 -0
- package/dist/plugin/bridge.d.ts.map +1 -0
- package/dist/plugin/bridge.js +125 -0
- package/dist/plugin/bridge.js.map +1 -0
- package/dist/plugin/capabilities.d.ts +20 -0
- package/dist/plugin/capabilities.d.ts.map +1 -0
- package/dist/plugin/capabilities.js +133 -0
- package/dist/plugin/capabilities.js.map +1 -0
- package/dist/plugin/context.d.ts +374 -0
- package/dist/plugin/context.d.ts.map +1 -0
- package/dist/plugin/context.js +2 -0
- package/dist/plugin/context.js.map +1 -0
- package/dist/plugin/define.d.ts +208 -0
- package/dist/plugin/define.d.ts.map +1 -0
- package/dist/plugin/define.js +482 -0
- package/dist/plugin/define.js.map +1 -0
- package/dist/plugin/definition-error.d.ts +11 -0
- package/dist/plugin/definition-error.d.ts.map +1 -0
- package/dist/plugin/definition-error.js +17 -0
- package/dist/plugin/definition-error.js.map +1 -0
- package/dist/plugin/limits.d.ts +67 -0
- package/dist/plugin/limits.d.ts.map +1 -0
- package/dist/plugin/limits.js +70 -0
- package/dist/plugin/limits.js.map +1 -0
- package/dist/plugin/load-worker.d.ts +7 -0
- package/dist/plugin/load-worker.d.ts.map +1 -0
- package/dist/plugin/load-worker.js +41 -0
- package/dist/plugin/load-worker.js.map +1 -0
- package/dist/plugin/load.d.ts +18 -0
- package/dist/plugin/load.d.ts.map +1 -0
- package/dist/plugin/load.js +62 -0
- package/dist/plugin/load.js.map +1 -0
- package/dist/plugin/manifest.d.ts +237 -0
- package/dist/plugin/manifest.d.ts.map +1 -0
- package/dist/plugin/manifest.js +411 -0
- package/dist/plugin/manifest.js.map +1 -0
- package/dist/plugin/refusals.d.ts +49 -0
- package/dist/plugin/refusals.d.ts.map +1 -0
- package/dist/plugin/refusals.js +79 -0
- package/dist/plugin/refusals.js.map +1 -0
- package/dist/plugin/rest-schemas.d.ts +556 -0
- package/dist/plugin/rest-schemas.d.ts.map +1 -0
- package/dist/plugin/rest-schemas.js +262 -0
- package/dist/plugin/rest-schemas.js.map +1 -0
- package/dist/plugin/sandbox.d.ts +23 -0
- package/dist/plugin/sandbox.d.ts.map +1 -0
- package/dist/plugin/sandbox.js +99 -0
- package/dist/plugin/sandbox.js.map +1 -0
- package/dist/plugin/testing.d.ts +45 -0
- package/dist/plugin/testing.d.ts.map +1 -0
- package/dist/plugin/testing.js +420 -0
- package/dist/plugin/testing.js.map +1 -0
- package/dist/plugin/web-react.d.ts +11 -0
- package/dist/plugin/web-react.d.ts.map +1 -0
- package/dist/plugin/web-react.js +34 -0
- package/dist/plugin/web-react.js.map +1 -0
- package/dist/plugin/web.d.ts +95 -0
- package/dist/plugin/web.d.ts.map +1 -0
- package/dist/plugin/web.js +245 -0
- package/dist/plugin/web.js.map +1 -0
- package/dist/plugin-nav.d.ts +29 -0
- package/dist/plugin-nav.d.ts.map +1 -0
- package/dist/plugin-nav.js +92 -0
- package/dist/plugin-nav.js.map +1 -0
- package/dist/plugin-testing.d.ts +2 -0
- package/dist/plugin-testing.d.ts.map +1 -0
- package/dist/plugin-testing.js +4 -0
- package/dist/plugin-testing.js.map +1 -0
- package/dist/plugin-web-react.d.ts +3 -0
- package/dist/plugin-web-react.d.ts.map +1 -0
- package/dist/plugin-web-react.js +3 -0
- package/dist/plugin-web-react.js.map +1 -0
- package/dist/plugin-web.d.ts +4 -0
- package/dist/plugin-web.d.ts.map +1 -0
- package/dist/plugin-web.js +5 -0
- package/dist/plugin-web.js.map +1 -0
- package/dist/plugin.d.ts +11 -0
- package/dist/plugin.d.ts.map +1 -0
- package/dist/plugin.js +15 -0
- package/dist/plugin.js.map +1 -0
- package/dist/router.d.ts +28 -0
- package/dist/router.d.ts.map +1 -1
- package/dist/router.js +47 -0
- package/dist/router.js.map +1 -1
- package/dist/routes.d.ts +4 -0
- package/dist/routes.d.ts.map +1 -1
- package/dist/routes.js +6 -0
- package/dist/routes.js.map +1 -1
- package/dist/schemas.d.ts +117 -0
- package/dist/schemas.d.ts.map +1 -1
- package/dist/schemas.js +40 -1
- package/dist/schemas.js.map +1 -1
- package/dist/tokens.d.ts +2 -0
- package/dist/tokens.d.ts.map +1 -0
- package/dist/tokens.js +101 -0
- package/dist/tokens.js.map +1 -0
- package/dist/vocabulary.d.ts +11 -1
- package/dist/vocabulary.d.ts.map +1 -1
- package/dist/vocabulary.js +24 -0
- package/dist/vocabulary.js.map +1 -1
- package/dist/web.d.ts.map +1 -1
- package/dist/web.js +2 -0
- package/dist/web.js.map +1 -1
- package/docs/specs/cli.md +11 -4
- package/docs/specs/plugins.md +487 -0
- package/docs/specs/rest.md +3 -2
- package/package.json +20 -2
- package/skills/building-a-console/SKILL.md +25 -26
- package/skills/building-a-console/references/configuring.md +40 -0
- package/skills/building-a-console/references/the-default-console.md +1 -1
- package/skills/building-a-console/references/the-look-from-a-website.md +5 -5
- package/skills/building-a-plugin/SKILL.md +137 -0
- package/skills/deploying-a-console/SKILL.md +24 -26
- package/skills/deploying-a-console/references/access.md +13 -9
- package/skills/deploying-a-console/references/resources.md +25 -10
- package/skills/deploying-a-console/references/running-it-again.md +15 -0
- package/skills/deploying-a-console/references/sizing.md +2 -0
- package/skills/planning-the-board/SKILL.md +96 -0
- package/skills/planning-the-board/references/a-task.md +36 -0
- package/skills/planning-the-board/references/setting-up.md +44 -0
- package/skills/working-the-board/SKILL.md +43 -34
- package/skills/working-the-board/references/the-pack.md +19 -0
- package/src/api.ts +8 -0
- package/src/cli/cli.ts +697 -33
- package/src/cli/format.ts +356 -9
- package/src/cli/help.ts +41 -2
- package/src/cli/plugin-check.ts +470 -0
- package/src/cli/plugin-cli.ts +148 -0
- package/src/cli/plugin-init.ts +90 -0
- package/src/cli/plugin-main.ts +30 -0
- package/src/client.ts +294 -0
- package/src/compat.ts +2 -2
- package/src/components/board.tsx +62 -14
- package/src/components/event-feed.tsx +42 -1
- package/src/components/plugin-frame.tsx +437 -0
- package/src/components/plugin-settings.tsx +1111 -0
- package/src/components/shell.tsx +82 -14
- package/src/components/workspace.tsx +18 -0
- package/src/console.tsx +286 -19
- package/src/data.ts +27 -2
- package/src/i18n/en.ts +168 -0
- package/src/i18n/ko.ts +148 -0
- package/src/index.ts +12 -0
- package/src/plugin/args.ts +526 -0
- package/src/plugin/bridge.ts +314 -0
- package/src/plugin/capabilities.ts +150 -0
- package/src/plugin/context.ts +416 -0
- package/src/plugin/define.ts +792 -0
- package/src/plugin/definition-error.ts +19 -0
- package/src/plugin/limits.ts +70 -0
- package/src/plugin/load-worker.ts +50 -0
- package/src/plugin/load.ts +82 -0
- package/src/plugin/manifest.ts +561 -0
- package/src/plugin/refusals.ts +94 -0
- package/src/plugin/rest-schemas.ts +354 -0
- package/src/plugin/sandbox.ts +123 -0
- package/src/plugin/testing.ts +612 -0
- package/src/plugin/web-react.ts +45 -0
- package/src/plugin/web.ts +403 -0
- package/src/plugin-nav.ts +132 -0
- package/src/plugin-testing.ts +10 -0
- package/src/plugin-web-react.ts +4 -0
- package/src/plugin-web.ts +35 -0
- package/src/plugin.ts +126 -0
- package/src/router.ts +73 -0
- package/src/routes.ts +7 -0
- package/src/schemas.ts +43 -0
- package/src/styles/console.css +327 -0
- package/src/tokens.ts +101 -0
- package/src/vocabulary.ts +30 -0
- package/src/web.ts +2 -0
- package/template/plugin/.gitignore +2 -0
- package/template/plugin/README.md +26 -0
- package/template/plugin/SKILLCDN.md +13 -0
- package/template/plugin/build.mjs +40 -0
- package/template/plugin/console-plugin.json +50 -0
- package/template/plugin/package.json +27 -0
- package/template/plugin/skills/__key__/SKILL.md +23 -0
- package/template/plugin/src/check.test.ts +34 -0
- package/template/plugin/src/server/index.test.ts +41 -0
- package/template/plugin/src/server/index.ts +72 -0
- package/template/plugin/src/web/index.css +51 -0
- package/template/plugin/src/web/index.ts +115 -0
- package/template/plugin/tsconfig.json +17 -0
- package/skills/working-the-board/references/setting-up.md +0 -3
- /package/skills/{working-the-board → planning-the-board}/references/project-rules.md +0 -0
package/src/data.ts
CHANGED
|
@@ -39,12 +39,14 @@ import {
|
|
|
39
39
|
type RestPerson,
|
|
40
40
|
type RestPersonPatch,
|
|
41
41
|
type RestPersonWork,
|
|
42
|
+
type RestPlugin,
|
|
42
43
|
type RestProject,
|
|
43
44
|
type RestProjectInput,
|
|
44
45
|
type RestProjectPatch,
|
|
45
46
|
type RestProjectRules,
|
|
46
47
|
type RestRules,
|
|
47
48
|
type RestRulesInput,
|
|
49
|
+
type RestRulesPlugin,
|
|
48
50
|
type RestRun,
|
|
49
51
|
type RestSkills,
|
|
50
52
|
type RestTask,
|
|
@@ -198,6 +200,8 @@ export interface ConsoleActions {
|
|
|
198
200
|
connectRequest(code: string, signal?: AbortSignal): Promise<RestConnectRequest>;
|
|
199
201
|
approveConnection(code: string, input: RestTokenInput): Promise<RestConnectRequest>;
|
|
200
202
|
denyConnection(code: string): Promise<void>;
|
|
203
|
+
/** Reads the plugins again: after one was enabled, configured or disabled on the settings. */
|
|
204
|
+
refreshPlugins(): Promise<void>;
|
|
201
205
|
/** Another person's plate: for an administrator, or an owner of a project they are in. */
|
|
202
206
|
personWork(personId: string, signal?: AbortSignal): Promise<RestPersonWork>;
|
|
203
207
|
/** The tokens of another person, and the way to take one away: for an administrator. */
|
|
@@ -223,6 +227,8 @@ export interface ConsoleData {
|
|
|
223
227
|
readonly organization: RestOrganization | null;
|
|
224
228
|
/** The categories tasks are sorted into, by name. */
|
|
225
229
|
readonly categories: readonly RestCategory[];
|
|
230
|
+
/** The plugins the person may know of (docs/specs/plugins.md), by key: the enabled ones, every one for an administrator. */
|
|
231
|
+
readonly plugins: readonly RestPlugin[];
|
|
226
232
|
/** The tokens of whoever is signed in, newest first. */
|
|
227
233
|
readonly tokens: readonly RestToken[];
|
|
228
234
|
/** The project the page is on, once loaded; `undefined` while loading, or when the page is on none. */
|
|
@@ -245,6 +251,8 @@ export interface ConsoleData {
|
|
|
245
251
|
readonly members: readonly RestMember[];
|
|
246
252
|
/** The project's skills, as the console answered; `undefined` until it has. */
|
|
247
253
|
readonly skills: RestSkills | undefined;
|
|
254
|
+
/** The plugins bound to the project that the person holds a role in, as the rules name them. */
|
|
255
|
+
readonly projectPlugins: readonly RestRulesPlugin[];
|
|
248
256
|
readonly actions: ConsoleActions;
|
|
249
257
|
/** Asks everything again, from who is signed in on. */
|
|
250
258
|
reload(): void;
|
|
@@ -354,6 +362,7 @@ export function useConsoleData(client: ConsoleClient, projectKey: string | undef
|
|
|
354
362
|
const [listed, setListed] = useState<readonly RestListing[]>([]);
|
|
355
363
|
const [organization, setOrganization] = useState<RestOrganization | null>(null);
|
|
356
364
|
const [categories, setCategories] = useState<readonly RestCategory[]>([]);
|
|
365
|
+
const [plugins, setPlugins] = useState<readonly RestPlugin[]>([]);
|
|
357
366
|
const [tokens, setTokens] = useState<readonly RestToken[]>([]);
|
|
358
367
|
const [project, setProject] = useState<RestProject | undefined>(undefined);
|
|
359
368
|
const [projectLoaded, setProjectLoaded] = useState(false);
|
|
@@ -366,6 +375,7 @@ export function useConsoleData(client: ConsoleClient, projectKey: string | undef
|
|
|
366
375
|
const [events, setEvents] = useState<readonly RestEvent[]>([]);
|
|
367
376
|
const [members, setMembers] = useState<readonly RestMember[]>([]);
|
|
368
377
|
const [skills, setSkills] = useState<RestSkills | undefined>(undefined);
|
|
378
|
+
const [projectPlugins, setProjectPlugins] = useState<readonly RestRulesPlugin[]>([]);
|
|
369
379
|
const [generation, setGeneration] = useState(0);
|
|
370
380
|
const lastEvent = useRef(0);
|
|
371
381
|
const signedIn = me?.person !== null && me !== undefined;
|
|
@@ -375,10 +385,12 @@ export function useConsoleData(client: ConsoleClient, projectKey: string | undef
|
|
|
375
385
|
/** Loads the workspace's lists again. What fails stays as it was. */
|
|
376
386
|
const refreshWorkspace = useCallback(
|
|
377
387
|
async (signal?: AbortSignal) => {
|
|
378
|
-
const [nextProjects, nextPeople, nextCategories] = await Promise.all([
|
|
388
|
+
const [nextProjects, nextPeople, nextCategories, nextPlugins] = await Promise.all([
|
|
379
389
|
client.projects(signal),
|
|
380
390
|
client.people(signal),
|
|
381
391
|
client.categories(signal),
|
|
392
|
+
// A console without plugins answers none; one older than them answers nothing, which is none too.
|
|
393
|
+
client.plugins(signal).catch(() => ({ items: [], sql: false })),
|
|
382
394
|
]);
|
|
383
395
|
if (signal?.aborted === true) {
|
|
384
396
|
return;
|
|
@@ -388,6 +400,7 @@ export function useConsoleData(client: ConsoleClient, projectKey: string | undef
|
|
|
388
400
|
setListed(nextPeople.listed);
|
|
389
401
|
setOrganization(nextPeople.organization);
|
|
390
402
|
setCategories(nextCategories.items);
|
|
403
|
+
setPlugins(nextPlugins.items);
|
|
391
404
|
},
|
|
392
405
|
[client],
|
|
393
406
|
);
|
|
@@ -399,7 +412,7 @@ export function useConsoleData(client: ConsoleClient, projectKey: string | undef
|
|
|
399
412
|
return;
|
|
400
413
|
}
|
|
401
414
|
const scope = client.project(projectKey);
|
|
402
|
-
const [nextProject, nextTasks, nextDecisions, nextGoals, nextRuns, nextMembers] =
|
|
415
|
+
const [nextProject, nextTasks, nextDecisions, nextGoals, nextRuns, nextMembers, nextPlugins] =
|
|
403
416
|
await Promise.all([
|
|
404
417
|
scope.get(signal),
|
|
405
418
|
readTasks(scope, signal),
|
|
@@ -407,6 +420,11 @@ export function useConsoleData(client: ConsoleClient, projectKey: string | undef
|
|
|
407
420
|
readGoals(scope, signal),
|
|
408
421
|
scope.runs(undefined, signal),
|
|
409
422
|
scope.members(signal),
|
|
423
|
+
// The plugins bound to the project come with its rules; a console older than them names none.
|
|
424
|
+
scope
|
|
425
|
+
.rules(signal)
|
|
426
|
+
.then((rules) => rules.plugins ?? [])
|
|
427
|
+
.catch((): readonly RestRulesPlugin[] => []),
|
|
410
428
|
]);
|
|
411
429
|
if (signal?.aborted === true) {
|
|
412
430
|
return;
|
|
@@ -417,6 +435,7 @@ export function useConsoleData(client: ConsoleClient, projectKey: string | undef
|
|
|
417
435
|
setGoals(nextGoals.items);
|
|
418
436
|
setRuns(nextRuns.items);
|
|
419
437
|
setMembers(nextMembers.items);
|
|
438
|
+
setProjectPlugins(nextPlugins);
|
|
420
439
|
},
|
|
421
440
|
[client, projectKey],
|
|
422
441
|
);
|
|
@@ -480,6 +499,7 @@ export function useConsoleData(client: ConsoleClient, projectKey: string | undef
|
|
|
480
499
|
setEvents([]);
|
|
481
500
|
setMembers([]);
|
|
482
501
|
setSkills(undefined);
|
|
502
|
+
setProjectPlugins([]);
|
|
483
503
|
setLive(false);
|
|
484
504
|
if (projectKey === undefined || !signedIn) {
|
|
485
505
|
return;
|
|
@@ -766,6 +786,9 @@ export function useConsoleData(client: ConsoleClient, projectKey: string | undef
|
|
|
766
786
|
},
|
|
767
787
|
cancelWorkspacePackTokenConnection: () => client.cancelWorkspacePackTokenConnection(),
|
|
768
788
|
findPerson: (login, signal) => client.findPerson(login, signal),
|
|
789
|
+
async refreshPlugins() {
|
|
790
|
+
setPlugins((await client.plugins()).items);
|
|
791
|
+
},
|
|
769
792
|
async abandonRun(id) {
|
|
770
793
|
const run = await scope().endRun(id, { status: "abandoned" });
|
|
771
794
|
await refreshProject();
|
|
@@ -822,6 +845,7 @@ export function useConsoleData(client: ConsoleClient, projectKey: string | undef
|
|
|
822
845
|
listed,
|
|
823
846
|
organization,
|
|
824
847
|
categories,
|
|
848
|
+
plugins,
|
|
825
849
|
tokens,
|
|
826
850
|
project,
|
|
827
851
|
projectLoaded,
|
|
@@ -834,6 +858,7 @@ export function useConsoleData(client: ConsoleClient, projectKey: string | undef
|
|
|
834
858
|
events,
|
|
835
859
|
members,
|
|
836
860
|
skills,
|
|
861
|
+
projectPlugins,
|
|
837
862
|
actions,
|
|
838
863
|
reload,
|
|
839
864
|
};
|
package/src/i18n/en.ts
CHANGED
|
@@ -29,6 +29,15 @@ export const en = {
|
|
|
29
29
|
label: "English",
|
|
30
30
|
|
|
31
31
|
vocabulary: {
|
|
32
|
+
/** The states of a plugin (docs/specs/plugins.md, "Lifecycle"). */
|
|
33
|
+
pluginState: {
|
|
34
|
+
installed: "Installed",
|
|
35
|
+
enabled: "Enabled",
|
|
36
|
+
needs_consent: "Needs consent",
|
|
37
|
+
disabled: "Disabled",
|
|
38
|
+
failed: "Failed",
|
|
39
|
+
orphaned: "Orphaned",
|
|
40
|
+
} as Record<string, string>,
|
|
32
41
|
state: {
|
|
33
42
|
idea: "Idea",
|
|
34
43
|
ready: "Ready",
|
|
@@ -143,6 +152,138 @@ export const en = {
|
|
|
143
152
|
skills: "Skills",
|
|
144
153
|
members: "Members",
|
|
145
154
|
settings: "Settings",
|
|
155
|
+
plugins: "Plugins",
|
|
156
|
+
/** The groups of tabs the console knows (docs/specs/plugins.md, "Tabs, sub-tabs and addresses"). */
|
|
157
|
+
pluginGroups: {
|
|
158
|
+
people: "People",
|
|
159
|
+
customers: "Customers",
|
|
160
|
+
money: "Money",
|
|
161
|
+
operations: "Operations",
|
|
162
|
+
marketing: "Marketing",
|
|
163
|
+
engineering: "Engineering",
|
|
164
|
+
reports: "Reports",
|
|
165
|
+
} as Record<string, string>,
|
|
166
|
+
},
|
|
167
|
+
|
|
168
|
+
plugins: {
|
|
169
|
+
frame: (name: string) => `${name}, a plugin's page`,
|
|
170
|
+
noPage: {
|
|
171
|
+
title: "Nothing here",
|
|
172
|
+
body: "This plugin has no page you may see, or it is not on this project.",
|
|
173
|
+
},
|
|
174
|
+
settings: {
|
|
175
|
+
title: "Plugins",
|
|
176
|
+
empty: { title: "No plugins", body: "None is installed in this console's image." },
|
|
177
|
+
none: "The console has no plugins directory: none can be installed.",
|
|
178
|
+
about: "About",
|
|
179
|
+
problems: "Why it cannot run",
|
|
180
|
+
nothing: "None",
|
|
181
|
+
capabilities: "Capabilities",
|
|
182
|
+
board: "Board project",
|
|
183
|
+
boardHint: "Where its decisions, tasks and pages go.",
|
|
184
|
+
boardNone: "None",
|
|
185
|
+
boardCreate: "A new project",
|
|
186
|
+
boardChoose: "An existing project",
|
|
187
|
+
boardKey: "Key",
|
|
188
|
+
boardName: "Name",
|
|
189
|
+
boardDescription: "Description",
|
|
190
|
+
projects: "Projects",
|
|
191
|
+
projectsAll: "Every project",
|
|
192
|
+
projectsSome: "Some projects",
|
|
193
|
+
settingsForm: "Settings",
|
|
194
|
+
secretSet: (when: string) => `Set ${when}`,
|
|
195
|
+
secretUnset: "Not set",
|
|
196
|
+
secretNew: "New value",
|
|
197
|
+
enable: "Enable",
|
|
198
|
+
disable: "Disable",
|
|
199
|
+
roles: "Roles",
|
|
200
|
+
rolesNone: "No roles: every member may use it.",
|
|
201
|
+
roleDefault: "Default",
|
|
202
|
+
everyMember: "Every member",
|
|
203
|
+
grantEveryone: "Everyone",
|
|
204
|
+
grantMembersOf: (project: string) => `Members of ${project}`,
|
|
205
|
+
grantPeople: "People",
|
|
206
|
+
grantProjects: "Members of a project",
|
|
207
|
+
grantWhom: "Grant to…",
|
|
208
|
+
grant: "Grant",
|
|
209
|
+
revoke: "Revoke",
|
|
210
|
+
events: "What happened",
|
|
211
|
+
noEvents: "Nothing yet.",
|
|
212
|
+
data: "Data",
|
|
213
|
+
export: "Export",
|
|
214
|
+
exportHint: "Its records and their versions, as JSON Lines.",
|
|
215
|
+
exportLink: "Download",
|
|
216
|
+
purge: "Purge",
|
|
217
|
+
purgeHint:
|
|
218
|
+
"Removes its records, files, grants and secrets from the console. What it put on the board stays.",
|
|
219
|
+
purgeDisabledFirst: "Disable it first.",
|
|
220
|
+
purgeConfirm: (key: string) => `Type ${key}`,
|
|
221
|
+
purged: "Purged.",
|
|
222
|
+
agentNote: "For agents",
|
|
223
|
+
operations: "Commands and queries",
|
|
224
|
+
},
|
|
225
|
+
/** The capabilities (docs/specs/plugins.md, "Capabilities"), each by a name and the sentence of what it opens, as an administrator reads them before consenting. */
|
|
226
|
+
capability: {
|
|
227
|
+
files: {
|
|
228
|
+
name: "Files",
|
|
229
|
+
opens: "Keeps files on its records, within the bytes the deployment allows.",
|
|
230
|
+
},
|
|
231
|
+
"people:read": { name: "People", opens: "Reads the people the person may see." },
|
|
232
|
+
"people:read:all": {
|
|
233
|
+
name: "Everyone",
|
|
234
|
+
opens: "Reads everyone in the workspace, from its jobs and hooks too.",
|
|
235
|
+
},
|
|
236
|
+
"projects:read": {
|
|
237
|
+
name: "Projects",
|
|
238
|
+
opens: "Reads the projects and members the person may see.",
|
|
239
|
+
},
|
|
240
|
+
"projects:read:all": {
|
|
241
|
+
name: "Every project",
|
|
242
|
+
opens: "Reads every project and its members.",
|
|
243
|
+
},
|
|
244
|
+
"board:read": {
|
|
245
|
+
name: "Board",
|
|
246
|
+
opens:
|
|
247
|
+
"Reads the tasks, decisions, runs, pages and events of its board projects, and of the project a call is on.",
|
|
248
|
+
},
|
|
249
|
+
"board:tasks": {
|
|
250
|
+
name: "Tasks",
|
|
251
|
+
opens: "Creates tasks in its projects; changes, closes and comments on its own.",
|
|
252
|
+
},
|
|
253
|
+
"board:decisions": {
|
|
254
|
+
name: "Decisions",
|
|
255
|
+
opens: "Raises decisions in its projects and reads the answers to its own.",
|
|
256
|
+
},
|
|
257
|
+
"board:documents": {
|
|
258
|
+
name: "Pages",
|
|
259
|
+
opens: "Writes pages in a folder of its own in its projects.",
|
|
260
|
+
},
|
|
261
|
+
"events:console": {
|
|
262
|
+
name: "Console events",
|
|
263
|
+
opens: "Runs hooks on what happens in its board projects.",
|
|
264
|
+
},
|
|
265
|
+
"events:plugins": {
|
|
266
|
+
name: "Other plugins' events",
|
|
267
|
+
opens: "Runs hooks on the events other plugins emit.",
|
|
268
|
+
},
|
|
269
|
+
jobs: { name: "Schedule", opens: "Runs at the times it names." },
|
|
270
|
+
endpoints: {
|
|
271
|
+
name: "Inbound requests",
|
|
272
|
+
opens: "Takes requests under its own path, a person's or a webhook's.",
|
|
273
|
+
},
|
|
274
|
+
"storage:sql": {
|
|
275
|
+
name: "Own database schema",
|
|
276
|
+
opens: "Gets a schema and a login role of its own in the console's database.",
|
|
277
|
+
},
|
|
278
|
+
outbound: (host: string) => ({
|
|
279
|
+
name: `Requests to ${host}`,
|
|
280
|
+
opens: `Sends https requests to ${host}.`,
|
|
281
|
+
}),
|
|
282
|
+
plugins: (key: string) => ({
|
|
283
|
+
name: `Plugin ${key}`,
|
|
284
|
+
opens: `Calls the API of the plugin ${key}, as the person.`,
|
|
285
|
+
}),
|
|
286
|
+
},
|
|
146
287
|
},
|
|
147
288
|
|
|
148
289
|
shell: {
|
|
@@ -595,6 +736,8 @@ export const en = {
|
|
|
595
736
|
workspace: {
|
|
596
737
|
title: "Workspace",
|
|
597
738
|
aria: "Workspace settings",
|
|
739
|
+
consoleVersion: "Console version",
|
|
740
|
+
consoleTakes: (range: string) => `Takes the console command ${range}`,
|
|
598
741
|
peopleVisibility: "Member visibility",
|
|
599
742
|
peopleVisibilityHint:
|
|
600
743
|
"Whom a member sees on the People page and in the pickers: everyone of the workspace, or only the people they share a project with. An administrator always sees everyone, and a project open to the workspace has everyone in it.",
|
|
@@ -640,6 +783,17 @@ export const en = {
|
|
|
640
783
|
as: (agent: string) => `as ${agent}`,
|
|
641
784
|
asTitle: "The agent the person acted through",
|
|
642
785
|
aTask: "a task",
|
|
786
|
+
aPlugin: "a plugin",
|
|
787
|
+
/** After the sentence of a board's event a plugin caused (ADR-0052). */
|
|
788
|
+
throughPlugin: (plugin: string) => `through the plugin ${plugin}`,
|
|
789
|
+
everyone: "everyone",
|
|
790
|
+
membersOf: (project: string) => `the members of ${project}`,
|
|
791
|
+
outcome: {
|
|
792
|
+
ok: "done",
|
|
793
|
+
refused: "refused",
|
|
794
|
+
waiting: "waiting for a decision",
|
|
795
|
+
failed: "failed",
|
|
796
|
+
} as Readonly<Record<string, string>>,
|
|
643
797
|
aProject: "a project",
|
|
644
798
|
someone: "someone",
|
|
645
799
|
something: "something",
|
|
@@ -725,6 +879,20 @@ export const en = {
|
|
|
725
879
|
documentArchived: (page: string) => `archived ${page}`,
|
|
726
880
|
documentRestored: (page: string) => `restored ${page}`,
|
|
727
881
|
fileAttached: (label: string, page: string) => `attached ${label} to ${page}`,
|
|
882
|
+
pluginEnabled: (plugin: string) => `enabled the plugin ${plugin}`,
|
|
883
|
+
pluginDisabled: (plugin: string) => `disabled the plugin ${plugin}`,
|
|
884
|
+
pluginConfigured: (fields: string, plugin: string) =>
|
|
885
|
+
`changed ${fields} of the plugin ${plugin}`,
|
|
886
|
+
pluginGranted: (role: string, who: string, plugin: string) =>
|
|
887
|
+
`gave ${who} the role ${role} in the plugin ${plugin}`,
|
|
888
|
+
pluginRevoked: (role: string, who: string, plugin: string) =>
|
|
889
|
+
`took the role ${role} from ${who} in the plugin ${plugin}`,
|
|
890
|
+
pluginUpgraded: (plugin: string, version: string) =>
|
|
891
|
+
`brought the plugin ${plugin} to ${version}`,
|
|
892
|
+
pluginCommand: (command: string, plugin: string, outcome: string) =>
|
|
893
|
+
`ran ${command} of the plugin ${plugin}: ${outcome}`,
|
|
894
|
+
pluginPurged: (plugin: string) => `purged the plugin ${plugin}: everything it kept is gone`,
|
|
895
|
+
pluginFailed: (plugin: string, problem: string) => `the plugin ${plugin} failed: ${problem}`,
|
|
728
896
|
},
|
|
729
897
|
},
|
|
730
898
|
|
package/src/i18n/ko.ts
CHANGED
|
@@ -8,6 +8,14 @@ export const ko: Messages = {
|
|
|
8
8
|
label: "한국어",
|
|
9
9
|
|
|
10
10
|
vocabulary: {
|
|
11
|
+
pluginState: {
|
|
12
|
+
installed: "설치됨",
|
|
13
|
+
enabled: "활성",
|
|
14
|
+
needs_consent: "동의 필요",
|
|
15
|
+
disabled: "비활성",
|
|
16
|
+
failed: "실패",
|
|
17
|
+
orphaned: "패키지 없음",
|
|
18
|
+
},
|
|
11
19
|
state: {
|
|
12
20
|
idea: "아이디어",
|
|
13
21
|
ready: "준비됨",
|
|
@@ -105,6 +113,122 @@ export const ko: Messages = {
|
|
|
105
113
|
skills: "스킬",
|
|
106
114
|
members: "멤버",
|
|
107
115
|
settings: "설정",
|
|
116
|
+
plugins: "플러그인",
|
|
117
|
+
pluginGroups: {
|
|
118
|
+
people: "사람",
|
|
119
|
+
customers: "고객",
|
|
120
|
+
money: "돈",
|
|
121
|
+
operations: "운영",
|
|
122
|
+
marketing: "마케팅",
|
|
123
|
+
engineering: "엔지니어링",
|
|
124
|
+
reports: "보고",
|
|
125
|
+
},
|
|
126
|
+
},
|
|
127
|
+
|
|
128
|
+
plugins: {
|
|
129
|
+
frame: (name) => `${name}, 플러그인 페이지`,
|
|
130
|
+
noPage: {
|
|
131
|
+
title: "여기엔 없습니다",
|
|
132
|
+
body: "이 플러그인에는 볼 수 있는 페이지가 없거나, 이 프로젝트에 올라가 있지 않습니다.",
|
|
133
|
+
},
|
|
134
|
+
settings: {
|
|
135
|
+
title: "플러그인",
|
|
136
|
+
empty: { title: "플러그인 없음", body: "이 콘솔의 이미지에 설치된 플러그인이 없습니다." },
|
|
137
|
+
none: "콘솔에 플러그인 디렉터리가 없어 설치할 수 없습니다.",
|
|
138
|
+
about: "개요",
|
|
139
|
+
problems: "실행할 수 없는 이유",
|
|
140
|
+
nothing: "없음",
|
|
141
|
+
capabilities: "권한",
|
|
142
|
+
board: "보드 프로젝트",
|
|
143
|
+
boardHint: "플러그인의 결정, 태스크, 문서가 가는 곳입니다.",
|
|
144
|
+
boardNone: "없음",
|
|
145
|
+
boardCreate: "새 프로젝트",
|
|
146
|
+
boardChoose: "기존 프로젝트",
|
|
147
|
+
boardKey: "키",
|
|
148
|
+
boardName: "이름",
|
|
149
|
+
boardDescription: "설명",
|
|
150
|
+
projects: "프로젝트",
|
|
151
|
+
projectsAll: "모든 프로젝트",
|
|
152
|
+
projectsSome: "일부 프로젝트",
|
|
153
|
+
settingsForm: "설정",
|
|
154
|
+
secretSet: (when) => `${when} 설정됨`,
|
|
155
|
+
secretUnset: "설정 안 됨",
|
|
156
|
+
secretNew: "새 값",
|
|
157
|
+
enable: "활성화",
|
|
158
|
+
disable: "비활성화",
|
|
159
|
+
roles: "역할",
|
|
160
|
+
rolesNone: "역할이 없어 모든 멤버가 쓸 수 있습니다.",
|
|
161
|
+
roleDefault: "기본",
|
|
162
|
+
everyMember: "모든 멤버",
|
|
163
|
+
grantEveryone: "모두",
|
|
164
|
+
grantMembersOf: (project) => `${project}의 멤버`,
|
|
165
|
+
grantPeople: "사람",
|
|
166
|
+
grantProjects: "프로젝트의 멤버",
|
|
167
|
+
grantWhom: "부여할 대상…",
|
|
168
|
+
grant: "부여",
|
|
169
|
+
revoke: "회수",
|
|
170
|
+
events: "일어난 일",
|
|
171
|
+
noEvents: "아직 없습니다.",
|
|
172
|
+
data: "데이터",
|
|
173
|
+
export: "내보내기",
|
|
174
|
+
exportHint: "레코드와 그 버전을 JSON Lines로 받습니다.",
|
|
175
|
+
exportLink: "내려받기",
|
|
176
|
+
purge: "삭제",
|
|
177
|
+
purgeHint: "콘솔에 있는 레코드, 파일, 역할, 비밀을 지웁니다. 보드에 남긴 것은 남습니다.",
|
|
178
|
+
purgeDisabledFirst: "삭제하려면 먼저 비활성화하세요.",
|
|
179
|
+
purgeConfirm: (key) => `${key} 입력`,
|
|
180
|
+
purged: "삭제했습니다.",
|
|
181
|
+
agentNote: "에이전트에게",
|
|
182
|
+
operations: "명령과 조회",
|
|
183
|
+
},
|
|
184
|
+
capability: {
|
|
185
|
+
files: { name: "파일", opens: "레코드에 파일을 붙입니다. 배포가 허용한 용량까지." },
|
|
186
|
+
"people:read": { name: "사람 읽기", opens: "보는 사람이 볼 수 있는 사람들을 읽습니다." },
|
|
187
|
+
"people:read:all": {
|
|
188
|
+
name: "모든 사람 읽기",
|
|
189
|
+
opens: "워크스페이스의 모든 사람을 읽습니다. 예약 실행과 훅에서도.",
|
|
190
|
+
},
|
|
191
|
+
"projects:read": {
|
|
192
|
+
name: "프로젝트 읽기",
|
|
193
|
+
opens: "보는 사람이 볼 수 있는 프로젝트와 멤버를 읽습니다.",
|
|
194
|
+
},
|
|
195
|
+
"projects:read:all": {
|
|
196
|
+
name: "모든 프로젝트 읽기",
|
|
197
|
+
opens: "모든 프로젝트와 멤버를 읽습니다.",
|
|
198
|
+
},
|
|
199
|
+
"board:read": {
|
|
200
|
+
name: "보드 읽기",
|
|
201
|
+
opens: "보드 프로젝트와 호출된 프로젝트의 태스크, 결정, 실행, 문서, 이벤트를 읽습니다.",
|
|
202
|
+
},
|
|
203
|
+
"board:tasks": {
|
|
204
|
+
name: "태스크",
|
|
205
|
+
opens: "자기 프로젝트에 태스크를 만들고, 만든 것을 바꾸고 닫고 댓글을 답니다.",
|
|
206
|
+
},
|
|
207
|
+
"board:decisions": { name: "결정", opens: "자기 프로젝트에 결정을 올리고 그 답을 읽습니다." },
|
|
208
|
+
"board:documents": { name: "문서", opens: "자기 프로젝트의 문서에 자기 폴더를 두고 씁니다." },
|
|
209
|
+
"events:console": {
|
|
210
|
+
name: "콘솔 이벤트",
|
|
211
|
+
opens: "보드 프로젝트에서 일어나는 일에 훅을 겁니다.",
|
|
212
|
+
},
|
|
213
|
+
"events:plugins": {
|
|
214
|
+
name: "다른 플러그인의 이벤트",
|
|
215
|
+
opens: "다른 플러그인이 내는 이벤트에 훅을 겁니다.",
|
|
216
|
+
},
|
|
217
|
+
jobs: { name: "예약 실행", opens: "정해진 시간에 실행됩니다." },
|
|
218
|
+
endpoints: {
|
|
219
|
+
name: "요청 받기",
|
|
220
|
+
opens: "자기 경로로 오는 요청을 받습니다. 사람의 요청이나 웹훅.",
|
|
221
|
+
},
|
|
222
|
+
"storage:sql": {
|
|
223
|
+
name: "전용 데이터베이스 스키마",
|
|
224
|
+
opens: "콘솔 데이터베이스에 전용 스키마와 로그인 역할을 갖습니다.",
|
|
225
|
+
},
|
|
226
|
+
outbound: (host) => ({ name: `${host}로 요청`, opens: `${host}에 https 요청을 보냅니다.` }),
|
|
227
|
+
plugins: (key) => ({
|
|
228
|
+
name: `플러그인 ${key} 호출`,
|
|
229
|
+
opens: `플러그인 ${key}의 API를 호출한 사람의 권한으로 호출합니다.`,
|
|
230
|
+
}),
|
|
231
|
+
},
|
|
108
232
|
},
|
|
109
233
|
|
|
110
234
|
shell: {
|
|
@@ -551,6 +675,8 @@ export const ko: Messages = {
|
|
|
551
675
|
workspace: {
|
|
552
676
|
title: "워크스페이스",
|
|
553
677
|
aria: "워크스페이스 설정",
|
|
678
|
+
consoleVersion: "콘솔 버전",
|
|
679
|
+
consoleTakes: (range) => `받는 console 명령: ${range}`,
|
|
554
680
|
peopleVisibility: "멤버 공개 범위",
|
|
555
681
|
peopleVisibilityHint:
|
|
556
682
|
"멤버가 사람들 페이지와 선택 목록에서 보는 범위: 워크스페이스의 모두, 또는 같은 프로젝트에 속한 사람만. 관리자는 언제나 모두를 보고, 워크스페이스에 공개된 프로젝트에는 모두가 속합니다.",
|
|
@@ -596,6 +722,16 @@ export const ko: Messages = {
|
|
|
596
722
|
as: (agent) => `${agent}(으)로`,
|
|
597
723
|
asTitle: "그 사람이 사용한 에이전트",
|
|
598
724
|
aTask: "작업",
|
|
725
|
+
aPlugin: "플러그인",
|
|
726
|
+
throughPlugin: (plugin) => `플러그인 ${plugin}을(를) 통해`,
|
|
727
|
+
everyone: "모든 구성원",
|
|
728
|
+
membersOf: (project) => `${project}의 구성원`,
|
|
729
|
+
outcome: {
|
|
730
|
+
ok: "완료",
|
|
731
|
+
refused: "거절됨",
|
|
732
|
+
waiting: "결정 대기",
|
|
733
|
+
failed: "실패",
|
|
734
|
+
},
|
|
599
735
|
aProject: "프로젝트",
|
|
600
736
|
someone: "누군가",
|
|
601
737
|
something: "무언가",
|
|
@@ -678,6 +814,18 @@ export const ko: Messages = {
|
|
|
678
814
|
documentArchived: (page) => `${page}을(를) 보관했습니다`,
|
|
679
815
|
documentRestored: (page) => `${page}을(를) 복원했습니다`,
|
|
680
816
|
fileAttached: (label, page) => `${page}에 ${label}을(를) 첨부했습니다`,
|
|
817
|
+
pluginEnabled: (plugin) => `플러그인 ${plugin}을(를) 활성화했습니다`,
|
|
818
|
+
pluginDisabled: (plugin) => `플러그인 ${plugin}을(를) 비활성화했습니다`,
|
|
819
|
+
pluginConfigured: (fields, plugin) => `플러그인 ${plugin}의 ${fields}을(를) 바꿨습니다`,
|
|
820
|
+
pluginGranted: (role, who, plugin) =>
|
|
821
|
+
`${who}에게 플러그인 ${plugin}의 ${role} 역할을 주었습니다`,
|
|
822
|
+
pluginRevoked: (role, who, plugin) =>
|
|
823
|
+
`${who}에게서 플러그인 ${plugin}의 ${role} 역할을 거두었습니다`,
|
|
824
|
+
pluginUpgraded: (plugin, version) => `플러그인 ${plugin}을(를) ${version}으로 올렸습니다`,
|
|
825
|
+
pluginCommand: (command, plugin, outcome) =>
|
|
826
|
+
`플러그인 ${plugin}의 ${command}을(를) 실행했습니다: ${outcome}`,
|
|
827
|
+
pluginPurged: (plugin) => `플러그인 ${plugin}을(를) 완전히 지웠습니다`,
|
|
828
|
+
pluginFailed: (plugin, problem) => `플러그인 ${plugin}이(가) 실패했습니다: ${problem}`,
|
|
681
829
|
},
|
|
682
830
|
},
|
|
683
831
|
|
package/src/index.ts
CHANGED
|
@@ -131,6 +131,15 @@ export {
|
|
|
131
131
|
ZOOM_STEP,
|
|
132
132
|
zoomAround,
|
|
133
133
|
} from "./components/pictures.js";
|
|
134
|
+
export {
|
|
135
|
+
BridgeRefusal,
|
|
136
|
+
PluginFrame,
|
|
137
|
+
type PluginFrameProps,
|
|
138
|
+
PluginWidgets,
|
|
139
|
+
type PluginWidgetsProps,
|
|
140
|
+
performBridgeCall,
|
|
141
|
+
readTheme,
|
|
142
|
+
} from "./components/plugin-frame.js";
|
|
134
143
|
export {
|
|
135
144
|
keyOf,
|
|
136
145
|
MemberList,
|
|
@@ -303,6 +312,8 @@ export {
|
|
|
303
312
|
type ProjectPage,
|
|
304
313
|
personAgentsHref,
|
|
305
314
|
personWorkHref,
|
|
315
|
+
pluginHref,
|
|
316
|
+
pluginSettingsHref,
|
|
306
317
|
projectHref,
|
|
307
318
|
projectSettingsHref,
|
|
308
319
|
type Route,
|
|
@@ -314,4 +325,5 @@ export {
|
|
|
314
325
|
withoutSignInParam,
|
|
315
326
|
workHref,
|
|
316
327
|
} from "./router.js";
|
|
328
|
+
export { CONSOLE_TOKENS } from "./tokens.js";
|
|
317
329
|
export { errorWords, useAction } from "./use-action.js";
|