@markmo/europacore-session-ui 0.0.0-stage → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +78 -2
- package/dist/BoardPage-BAQrGP7G.js +682 -0
- package/dist/CardDetail-CCgP8R61.js +255 -0
- package/dist/ComparePage-FcLLhKzC.js +247 -0
- package/dist/OverviewPage-CbfbyGNT.js +363 -0
- package/dist/RegisterPage-3-hJNQEV.js +383 -0
- package/dist/SessionPage-CA9hAakW.js +865 -0
- package/dist/api/agentClient.d.ts +142 -0
- package/dist/api/agentErrors.d.ts +14 -0
- package/dist/api/chatStream.d.ts +34 -0
- package/dist/api/sse.d.ts +18 -0
- package/dist/api/types.d.ts +223 -0
- package/dist/api/wire.d.ts +779 -0
- package/dist/features/agents/agentsStore.d.ts +26 -0
- package/dist/features/board/BoardCard.d.ts +20 -0
- package/dist/features/board/BoardColumn.d.ts +11 -0
- package/dist/features/board/BoardPage.d.ts +17 -0
- package/dist/features/board/CardDetail.d.ts +16 -0
- package/dist/features/board/StageChips.d.ts +9 -0
- package/dist/features/board/actions.d.ts +3 -0
- package/dist/features/board/board.d.ts +48 -0
- package/dist/features/board/flipPlan.d.ts +72 -0
- package/dist/features/board/stageStyle.d.ts +10 -0
- package/dist/features/board/useBoardFlip.d.ts +19 -0
- package/dist/features/bootstrap.d.ts +2 -0
- package/dist/features/chat/ChatIntro.d.ts +3 -0
- package/dist/features/chat/MessageParts.d.ts +21 -0
- package/dist/features/chat/decisions/PauseDock.d.ts +26 -0
- package/dist/features/chat/decisions/cards.d.ts +88 -0
- package/dist/features/chat/extensions.d.ts +52 -0
- package/dist/features/chat/images.d.ts +6 -0
- package/dist/features/chat/markdown/CodeBlock.d.ts +4 -0
- package/dist/features/chat/markdown/CopyButton.d.ts +6 -0
- package/dist/features/chat/markdown/MarkdownContent.d.ts +7 -0
- package/dist/features/chat/markdown/MermaidBlock.d.ts +4 -0
- package/dist/features/chat/model/chrome.d.ts +12 -0
- package/dist/features/chat/model/collisions.d.ts +44 -0
- package/dist/features/chat/model/describeCall.d.ts +26 -0
- package/dist/features/chat/model/entries.d.ts +121 -0
- package/dist/features/chat/model/export.d.ts +3 -0
- package/dist/features/chat/model/fleet.d.ts +51 -0
- package/dist/features/chat/model/flow.d.ts +21 -0
- package/dist/features/chat/model/format.d.ts +11 -0
- package/dist/features/chat/model/mcp.d.ts +14 -0
- package/dist/features/chat/model/memory.d.ts +115 -0
- package/dist/features/chat/model/pullRequests.d.ts +22 -0
- package/dist/features/chat/model/questions.d.ts +13 -0
- package/dist/features/chat/model/reducer.d.ts +5 -0
- package/dist/features/chat/model/register.d.ts +15 -0
- package/dist/features/chat/model/rowFilters.d.ts +10 -0
- package/dist/features/chat/model/sanitize.d.ts +12 -0
- package/dist/features/chat/model/sessions.d.ts +158 -0
- package/dist/features/chat/model/spec.d.ts +20 -0
- package/dist/features/chat/model/stages.d.ts +37 -0
- package/dist/features/chat/model/store.d.ts +94 -0
- package/dist/features/chat/model/subagents.d.ts +17 -0
- package/dist/features/chat/model/tasks.d.ts +21 -0
- package/dist/features/chat/model/variants.d.ts +39 -0
- package/dist/features/chat/notify.d.ts +1 -0
- package/dist/features/chat/panels/CorePanels.d.ts +16 -0
- package/dist/features/chat/panels/Inspector.d.ts +14 -0
- package/dist/features/chat/panels/registry.d.ts +23 -0
- package/dist/features/chat/session/ComposerHistory.d.ts +19 -0
- package/dist/features/chat/session/SessionBar.d.ts +11 -0
- package/dist/features/chat/session/SessionComposer.d.ts +24 -0
- package/dist/features/chat/session/SessionController.d.ts +255 -0
- package/dist/features/chat/session/SessionPage.d.ts +5 -0
- package/dist/features/chat/session/StatusLine.d.ts +5 -0
- package/dist/features/chat/session/describeError.d.ts +2 -0
- package/dist/features/chat/session/promptHistory.d.ts +35 -0
- package/dist/features/chat/session/sessionPageHooks.d.ts +8 -0
- package/dist/features/chat/session/useFileMentions.d.ts +7 -0
- package/dist/features/chat/session/useSession.d.ts +10 -0
- package/dist/features/chat/slashMatching.d.ts +11 -0
- package/dist/features/chat/transcript/Rows.d.ts +55 -0
- package/dist/features/chat/transcript/TranscriptView.d.ts +14 -0
- package/dist/features/chat/transcript/blocks.d.ts +46 -0
- package/dist/features/commands/AppDialogs.d.ts +1 -0
- package/dist/features/commands/CommandPalette.d.ts +11 -0
- package/dist/features/commands/core.d.ts +4 -0
- package/dist/features/commands/dialogs.d.ts +13 -0
- package/dist/features/commands/hotkeys.d.ts +13 -0
- package/dist/features/commands/registry.d.ts +59 -0
- package/dist/features/fleet/ComparePage.d.ts +16 -0
- package/dist/features/fleet/FleetPanel.d.ts +10 -0
- package/dist/features/fleet/fleetCommands.d.ts +61 -0
- package/dist/features/fleet/fleetEnv.d.ts +2 -0
- package/dist/features/memory/ExtractConfirmDialog.d.ts +10 -0
- package/dist/features/memory/MemoryDialog.d.ts +13 -0
- package/dist/features/memory/MemoryParts.d.ts +52 -0
- package/dist/features/memory/RegisterPage.d.ts +9 -0
- package/dist/features/memory/memoryCommands.d.ts +1 -0
- package/dist/features/memory/memoryService.d.ts +215 -0
- package/dist/features/memory/memoryStore.d.ts +95 -0
- package/dist/features/memory/useMemoryCapture.d.ts +33 -0
- package/dist/features/sessions/ContextGauge.d.ts +15 -0
- package/dist/features/sessions/DispatchLine.d.ts +15 -0
- package/dist/features/sessions/NewSessionDialog.d.ts +18 -0
- package/dist/features/sessions/OverviewPage.d.ts +6 -0
- package/dist/features/sessions/PeekPanel.d.ts +16 -0
- package/dist/features/sessions/RenameInput.d.ts +7 -0
- package/dist/features/sessions/SessionRow.d.ts +22 -0
- package/dist/features/sessions/SessionsPanel.d.ts +20 -0
- package/dist/features/sessions/hub.d.ts +128 -0
- package/dist/features/sessions/useAttention.d.ts +11 -0
- package/dist/features/workspace/AcceptDiscardBar.d.ts +9 -0
- package/dist/features/workspace/AddedDirsDialog.d.ts +6 -0
- package/dist/features/workspace/DiffDialog.d.ts +30 -0
- package/dist/features/workspace/DiffViewer.d.ts +39 -0
- package/dist/features/workspace/GitPanel.d.ts +7 -0
- package/dist/features/workspace/Highlight.d.ts +23 -0
- package/dist/features/workspace/PullRequestCard.d.ts +29 -0
- package/dist/features/workspace/SnapshotsDialog.d.ts +6 -0
- package/dist/features/workspace/UndoDialog.d.ts +6 -0
- package/dist/features/workspace/WorkspaceDialogs.d.ts +18 -0
- package/dist/features/workspace/WorkspaceLocation.d.ts +17 -0
- package/dist/features/workspace/collisionsWatcher.d.ts +78 -0
- package/dist/features/workspace/hooks.d.ts +10 -0
- package/dist/features/workspace/intraline.d.ts +41 -0
- package/dist/features/workspace/parsePatch.d.ts +60 -0
- package/dist/features/workspace/register.d.ts +1 -0
- package/dist/features/workspace/testController.d.ts +15 -0
- package/dist/features/workspace/undoCommands.d.ts +64 -0
- package/dist/features/workspace/useSessionPageHooks.d.ts +6 -0
- package/dist/features/workspace/workspaceActions.d.ts +44 -0
- package/dist/features/workspace/workspaceCommands.d.ts +83 -0
- package/dist/features/workspace/workspaceFormat.d.ts +31 -0
- package/dist/host.d.ts +66 -0
- package/dist/index-NjGO7Jg1.js +9963 -0
- package/dist/index.d.ts +32 -0
- package/dist/index.js +91 -0
- package/dist/lib/cx.d.ts +2 -0
- package/dist/lib/paths.d.ts +12 -0
- package/dist/lib/posixPath.d.ts +7 -0
- package/dist/lib/theme.d.ts +15 -0
- package/dist/lib/time.d.ts +10 -0
- package/dist/lib/uuid.d.ts +1 -0
- package/dist/promptHistory-DjSCHmEk.js +231 -0
- package/dist/ui/Avatar.d.ts +7 -0
- package/dist/ui/Badge.d.ts +7 -0
- package/dist/ui/Button.d.ts +19 -0
- package/dist/ui/Callout.d.ts +10 -0
- package/dist/ui/Dialog.d.ts +19 -0
- package/dist/ui/Disclosure.d.ts +8 -0
- package/dist/ui/EmptyState.d.ts +7 -0
- package/dist/ui/Field.d.ts +30 -0
- package/dist/ui/Menu.d.ts +20 -0
- package/dist/ui/PageHeader.d.ts +8 -0
- package/dist/ui/Spinner.d.ts +5 -0
- package/dist/ui/Toast.d.ts +16 -0
- package/dist/ui/index.d.ts +12 -0
- package/package.json +52 -4
- package/src/styles/session-ui.css +90 -0
- package/src/styles/tokens.css +80 -0
package/README.md
CHANGED
|
@@ -1,3 +1,79 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @markmo/europacore-session-ui
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
europacore's session UI for any React 18 or 19 app that reaches a europacore server (`europacore/docs/server-api.md`):
|
|
4
|
+
|
|
5
|
+
- sessions, with the live transcript, tool calls, approvals, steering and Stop;
|
|
6
|
+
- workspaces (git, diffs, accept and discard, snapshots, pull requests) and fleets;
|
|
7
|
+
- the overview, the live board and the decision register.
|
|
8
|
+
|
|
9
|
+
It is europacoreui's own frontend, kept in that repository as an npm workspace. devassistant (Codaflow) installs it.
|
|
10
|
+
|
|
11
|
+
## Use it
|
|
12
|
+
|
|
13
|
+
```ts
|
|
14
|
+
import { configureSessionUi, ThemeProvider, ToastProvider, SessionPage, OverviewPage, DialogHost } from '@markmo/europacore-session-ui';
|
|
15
|
+
|
|
16
|
+
configureSessionUi({
|
|
17
|
+
// where the server's /v1 is, and how calls to it are signed
|
|
18
|
+
transport: {
|
|
19
|
+
baseUrl: '/europacore/v1',
|
|
20
|
+
headers: async () => ({ Authorization: `Bearer ${await idToken()}`, 'X-Devassistant-Workspace': workspaceId() }),
|
|
21
|
+
onUnauthorized: () => signIn(),
|
|
22
|
+
},
|
|
23
|
+
basePath: '/coding', // pages at /coding/sessions/:id, /coding/board, ...
|
|
24
|
+
userName: () => currentUser()?.name ?? null,
|
|
25
|
+
// features: what the app allows (the coder, fleets, credentials); all off by default
|
|
26
|
+
// workspaces: the app's directories a coder can work in, when it has them
|
|
27
|
+
// disabledPermissionModes: modes users may not switch to here, e.g. ['bypassPermissions']
|
|
28
|
+
// approvalArmMs: how long an approval card ignores clicks after it appears (300 by default)
|
|
29
|
+
});
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
Call it once before the first render, then:
|
|
33
|
+
|
|
34
|
+
- **Routes.** Mount the pages at the paths `lib/paths.ts` names, under `basePath`:
|
|
35
|
+
- `SessionPage` at `sessions/:sessionId` (`new` starts one);
|
|
36
|
+
- `OverviewPage` at `sessions`;
|
|
37
|
+
- `ComparePage` at `sessions/:sessionId/compare/:group`;
|
|
38
|
+
- `BoardPage` at `board`;
|
|
39
|
+
- `DecisionsPage` at `decisions`.
|
|
40
|
+
- **Shell.** Render `DialogHost` once, inside the router. Call `bootstrapFeatures()` once, and `loadAgents()` once signed in. `SessionsPanel`, `CommandPalette` and the hooks (`useAttention`, `useMemoryCapture`, `useSessionPageHooks`, `useHotkeys`) are optional.
|
|
41
|
+
- **Router.** The package uses React Router 7 (`react-router`), a peer dependency.
|
|
42
|
+
- **Theme.** `ThemeProvider` owns light and dark. Without it, the package follows the document's `dark` class.
|
|
43
|
+
|
|
44
|
+
### Styles
|
|
45
|
+
|
|
46
|
+
The components use Tailwind utilities named after semantic tokens:
|
|
47
|
+
|
|
48
|
+
- `bg-surface`, `bg-surface-alt`, `bg-surface-sunken`, `bg-surface-hover`, `bg-bg`;
|
|
49
|
+
- `text-ink`, `text-muted`, `text-faint`;
|
|
50
|
+
- `border-line`, `border-line-soft`;
|
|
51
|
+
- `accent`, `accent-hover`, `accent-soft` and `on-accent`;
|
|
52
|
+
- the families `danger`, `warn` and `ok` (each with `-soft` and `-line`; `danger` also has `-ink`);
|
|
53
|
+
- `disabled`.
|
|
54
|
+
|
|
55
|
+
The app's Tailwind (v4) generates the utilities. Point it at the package, and give it the tokens:
|
|
56
|
+
|
|
57
|
+
```css
|
|
58
|
+
@import 'tailwindcss';
|
|
59
|
+
@source '../node_modules/@markmo/europacore-session-ui/dist';
|
|
60
|
+
@import '@markmo/europacore-session-ui/tokens.css'; /* europacoreui's palette; or define the names yourself */
|
|
61
|
+
@import '@markmo/europacore-session-ui/styles.css'; /* markdown and the streaming caret */
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
## Develop
|
|
65
|
+
|
|
66
|
+
From `frontend/`:
|
|
67
|
+
|
|
68
|
+
- `npm test` runs the app's tests, then the package's.
|
|
69
|
+
- `npm run typecheck` checks both.
|
|
70
|
+
- `npm run build -w @markmo/europacore-session-ui` builds `dist/`: ES modules, one chunk per page, and `.d.ts` files.
|
|
71
|
+
- `npm pack -w @markmo/europacore-session-ui` makes a tarball, for trying a change in an app before it is published.
|
|
72
|
+
|
|
73
|
+
## Publish
|
|
74
|
+
|
|
75
|
+
It is published to public npm, so an app installs it with no token: `npm install @markmo/europacore-session-ui`.
|
|
76
|
+
|
|
77
|
+
1. Bump `version` and add to `CHANGELOG.md`.
|
|
78
|
+
2. Once that is on `main`, push the tag `session-ui-v<version>`.
|
|
79
|
+
3. `.github/workflows/publish-session-ui.yml` then checks, tests and publishes the package.
|