[appkit plugin] [7/x] Add custom UI elements (+playground) to @databricks/appkit-agent #395
Open
hubertzub-db wants to merge 16 commits intodatabricks:mainfrom
Open
[appkit plugin] [7/x] Add custom UI elements (+playground) to @databricks/appkit-agent #395hubertzub-db wants to merge 16 commits intodatabricks:mainfrom
hubertzub-db wants to merge 16 commits intodatabricks:mainfrom
Conversation
Move agent plugin source code into src/agent-plugin/ subfolder for better organization when hosting multiple plugins.
Signed-off-by: Hubert Zub <hubert.zub@databricks.com>
Signed-off-by: Hubert Zub <hubert.zub@databricks.com>
Signed-off-by: Hubert Zub <hubert.zub@databricks.com>
Add per-package pnpm-lock.yaml and CI/release workflows with explicit pnpm version and cache-dependency-path.
Signed-off-by: Hubert Zub <hubert.zub@databricks.com>
Signed-off-by: Hubert Zub <hubert.zub@databricks.com>
Signed-off-by: Hubert Zub <hubert.zub@databricks.com>
Signed-off-by: Hubert Zub <hubert.zub@databricks.com>
- Import ChatProvider + ChatPanel from @databricks/appkit-agent/chat-ui instead of building from scratch - Add react-router-dom and swr as custom-ui playground dependencies - Add ./chat-ui/styles.css export to package.json for CSS import - Simplify main.tsx entry point
This was referenced Mar 25, 2026
54d6f8e to
aa3223a
Compare
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.
🥞 Stacked PR
Signed-off-by: Hubert Zub hubert.zub@databricks.com
Summary
@databricks/appkit-agent/react— hooks and renderless components that let users build fully custom chat UIs with their own styling.client/) to delegate core logic (chat streaming, history, session, config) to the new library, reducing duplication while preserving full backward compatibility.playground/custom-ui/example app demonstrating the headless library end-to-end: sidebar with chat history, streaming chat, input — all in plain CSS, no component library.Build changes
tsdown.config.tsnow has two entries: server (platform: "node") and React library (platform: "neutral", externalized React/SWR/AI SDK).package.jsonadds"./react"export pointing todist/react/index.{mjs,cjs}, pluspeerDependenciesforreact,react-dom,swr,@ai-sdk/react.Client refactoring
The existing client hooks (
use-chat-stream,use-chat-history,use-session,use-config,useChatData) now wrap the library's hooks, adding only client-specific concerns (toast notifications, router navigation).ChatProviderwrapsChatAgentProviderwhile keeping thewindow.__CHAT_CONFIG__bridge for backward compatibility.Demo of the custom UI
Screen.Recording.2026-03-25.at.15.24.23.mov
Test plan
pnpm run buildinappkit-agent/succeeds — producesdist/react/,dist/chat-client/, server bundlesplayground/custom-ui/starts withpnpm run dev— Vite HMR on port 8000, sidebar lists chats, can send messages, can click existing chats to load historyplayground/default-ui/starts and serves the bundled chat UI athttp://localhost:8000