Repository navigation
feat(ui): render the chat dock vertically with its own close button - #113
Merged
Merged
Conversation
The dock is a tall, narrow column, but the chat rendered datum-ui's horizontal layout: a left rail plus a history panel that squeezed the chat to a sliver. The portal's dock also overlaid its close button on the chat header's controls. ChatDock now renders the workspace with `orientation="vertical"` (top bar, history drawer) and passes the dock's `onClose` through, so the X sits in the chat's own header. The manifest declares `handlesClose`, so the portal drops its overlay button. Moves @datum-cloud/datum-ui from ^2.10.0 to ^3.4.0, the release that adds both props. The plugin only imports datum-ui/assistant, and its existing deps already satisfy 3.x's peers (motion 13, react-table 9).
2 of 4 tasks
yahyafakhroji
approved these changes
Oct 1, 2026
mattdjenkinson
added a commit
to datum-cloud/cloud-portal
that referenced
this pull request
Oct 1, 2026
**Problem** The dock panel puts its close button on top of the widget's top-right corner. Patch's chat now has a header with its own controls in that corner (datum-ui 3.4's vertical `AssistantWorkspace`), so the two buttons sit on top of each other. **Solution** Every `portal.dock/project` component is now mounted with an `onClose` prop. A widget that sets `handlesClose: true` in its manifest renders its own close control, and the panel then drops its overlay button. Widgets without the flag keep the overlay, so existing plugins are unaffected. - `DockProjectProperties.handlesClose` and `DockWidgetProps` are defined in `types.ts` and validated in the manifest schema. - `LazyPluginComponent` forwards optional `componentProps` to the plugin component. - The dock's loading skeleton now matches the chat's vertical layout (top bar and empty state) rather than the old left rail. `DockWidgetProps` lives here for now. It belongs in `@datum-cloud/portal-plugin-sdk` eventually, so plugins can import the type instead of copying it. **Rollout** Merge and deploy this before releasing the assistant plugin change that sets `handlesClose` (milo-os/assistant#113). An older portal ignores the flag and keeps its overlay button, which would then sit on top of the chat's new-chat button. Related: datum-cloud/datum-ui#228 **Test plan** - [x] `bun run typecheck`, eslint, prettier - [x] `bun test app/modules/plugins`: 221 pass, including 2 new manifest schema tests (`handlesClose` accepted, non-boolean rejected) - [ ] With the updated assistant plugin: the dock shows a single close button (in the chat header), and it closes the panel - [ ] A dock widget without `handlesClose` still gets the overlay close button
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Patch AI dock is a tall, narrow column, but
ChatDockrendered datum-ui's horizontal workspace. Its left rail and history panel squeezed the chat to a sliver, and the portal's dock close button sat on top of the chat header's sidebar toggle.ChatDockrendersAssistantWorkspacewithorientation="vertical": a top bar (history toggle, title, new chat), history as a drawer over the chat, and a tighter empty state.onClosethrough, so the close button sits in the chat's own header.plugin-manifest.jsonsetshandlesClose: true, which tells the portal to drop its overlay button.@datum-cloud/datum-uimoves from^2.10.0to^3.4.0, the release with both props (fix(nav): steady rail motion; feat(assistant): vertical orientation and onClose datum-cloud/datum-ui#228). The plugin only importsdatum-ui/assistant, has no type-scale classes to migrate, and its deps already meet 3.x's peers (motion 13, react-table 9, react 19.2.8).Release order
onClose, honourshandlesClose) must be deployed first. An older portal ignores the flag and keeps its overlay button, which would then cover the chat's new-chat button.Test plan
bun install,tsc --noEmit,vite buildagainst the published datum-ui 3.4.0