feat(document-preview): add document preview page and improve chunk list UI
- Implement new document preview page with support for various file types - Move file preview functionality from parsed-result to dedicated preview page - Enhance chunk list UI with better visual hierarchy and styling - Add document preview button in parsed-result page - Improve error handling and loading states for both pages
This commit is contained in:
@@ -9,6 +9,7 @@ import { KnowledgeBaseList, KnowledgeBaseCreate, KnowledgeBaseDetail, KnowledgeB
|
||||
import MCP from '../pages/MCP';
|
||||
import FormFieldTest from '../pages/FormFieldTest';
|
||||
import ChunkParsedResult from '@/pages/chunk/parsed-result';
|
||||
import DocumentPreview from '@/pages/chunk/document-preview';
|
||||
|
||||
const AppRoutes = () => {
|
||||
return (
|
||||
@@ -38,6 +39,8 @@ const AppRoutes = () => {
|
||||
{/* 处理chunk相关路由 需要传入 kb_id doc_id */}
|
||||
<Route path="chunk">
|
||||
<Route path="parsed-result" element={<ChunkParsedResult />} />
|
||||
{/* 文档预览页面路由 */}
|
||||
<Route path="/document-preview/:kb_id/:doc_id" element={<DocumentPreview />} />
|
||||
</Route>
|
||||
|
||||
{/* 处理未匹配的路由 */}
|
||||
|
||||
Reference in New Issue
Block a user