feat(components): Add markdown editing capability and enhance component styling

- Add editable mode to Markdown component with edit/save/cancel buttons
- Import EditOutlined, SaveOutlined, CloseOutlined icons from ant-design
- Add useState, useRef, useEffect hooks for managing edit state
- Add editable, onContentChange, and onSave props to RbMarkdownProps interface
- Create RbModal component with new index.css stylesheet for modal styling
- Add index.css stylesheet to KnowledgeBase components for consistent styling
- Update i18n translations in en.ts and zh.ts for new UI elements
- Refactor Markdown component handlers to accept and spread additional props
- Update InsertModal and RecallTestResult components for improved UX
- Fix prop spreading in component handlers to maintain compatibility with Ant Design components
This commit is contained in:
yujiangping
2025-12-22 17:03:31 +08:00
parent ad2f47029d
commit 54ff151ed8
8 changed files with 306 additions and 81 deletions

View File

@@ -585,7 +585,6 @@ export const en = {
insertContent: 'Insert Content',
editContent:'Edit Content',
insertContentPlaceholder: 'Please enter the content',
pleaseEnterContent: 'Please enter content',
documentIdRequired: 'Document ID is required',
editContentDesc:'Edit content',
insertContentDesc:'Insert content',
@@ -598,6 +597,10 @@ export const en = {
semantic:'Semantic',
hybrid:'Hybrid',
updateEmbeddingContent:'Are you sure about updating the embedding model? After the update, will the block vector data need to be reconstructed?',
question: 'Question',
answer: 'Answer',
normalMode: 'Normal Mode',
qaMode: 'QA Mode',
createForm:{
name: 'Name',
embedding_id: 'Embedding',