mirror of
https://github.com/CopilotKit/CopilotKit.git
synced 2026-09-14 16:26:20 +08:00
18c7a6001d
Attachment queue & previews: - Image lightbox with View Transition API morph animation - Video lightbox with native controls and play button overlay - Document lightbox (PDF via blob URL, text inline, info card fallback) - Drop zone overlay with upload icon - Filename preservation via InputContent metadata - Proper video thumbnail sizing and play/pause indicator - Fix attachment queue positioning (max-w-3xl constraint) - Padding between X button and content for audio/document cards - Document filenames wrap instead of truncating Attachments config: - onUploadFailed callback for validation/upload errors (file-too-large, invalid-type, upload-failed) - onUpload accepts sync or async returns - AttachmentUploadResult discriminated union with explicit interfaces - Metadata field on Attachment and onUpload return type AG-UI version bump: - Bump @ag-ui/client, @ag-ui/core, @ag-ui/encoder, @ag-ui/proto to 0.0.51 - Remove process.env Vite workaround (fixed upstream in 0.0.51) Deprecation lifecycle: - @deprecated JSDoc on all legacy image upload APIs - ImageRenderer, ImageRendererProps, ImageUpload type, imageUploadsEnabled prop, inputFileAccept prop, ImageRenderer prop, AIMessage.image, ImageData - Codemod at codemods/migrate-attachments.ts (15 tests) - Migration guide updated with codemod instructions and new type shapes Docs: - New guide: docs/(root)/multimodal-attachments.mdx - Updated migration guide with onUpload return type, metadata, codemod section - Cross-links from prebuilt-components and migration guide - Label change: "Add photos or files" → "Add attachments" Tests: - CopilotChat.attachments.test.tsx — 5 tests for onUploadFailed - migrate-attachments codemod — 15 tests
46 lines
1.1 KiB
JSON
46 lines
1.1 KiB
JSON
{
|
|
"name": "react-router-example",
|
|
"version": "0.1.0",
|
|
"private": true,
|
|
"type": "module",
|
|
"scripts": {
|
|
"dev": "react-router dev",
|
|
"build": "react-router build",
|
|
"start": "react-router-serve ./build/server/index.js"
|
|
},
|
|
"dependencies": {
|
|
"@ag-ui/client": "0.0.51",
|
|
"@copilotkit/react-core": "workspace:*",
|
|
"@copilotkit/runtime": "workspace:*",
|
|
"@copilotkit/shared": "workspace:*",
|
|
"@react-router/node": "^7.11.0",
|
|
"@tanstack/ai": "latest",
|
|
"@tanstack/ai-openai": "latest",
|
|
"hono": "^4.11.4",
|
|
"isbot": "^5.1.27",
|
|
"react": "^19.1.0",
|
|
"react-dom": "^19.1.0",
|
|
"react-router": "^7.11.0",
|
|
"react-router-hono-server": "^2.22.0",
|
|
"rxjs": "^7.8.1"
|
|
},
|
|
"devDependencies": {
|
|
"@react-router/dev": "^7.11.0",
|
|
"@react-router/fs-routes": "^7.11.0",
|
|
"@tailwindcss/vite": "^4.0.0",
|
|
"@types/react": "^19",
|
|
"@types/react-dom": "^19",
|
|
"tailwindcss": "^4.0.0",
|
|
"typescript": "~5.7.0",
|
|
"vite": "^6.0.0",
|
|
"vite-tsconfig-paths": "^4.3.0"
|
|
},
|
|
"nx": {
|
|
"targets": {
|
|
"build": {
|
|
"cache": false
|
|
}
|
|
}
|
|
}
|
|
}
|