feat: enhance document loading and state management in doc-content component
- Introduced a loading state (`loadingChunks`) to manage document chunk loading more effectively. - Updated the scroll handling logic to prevent multiple requests while loading chunks. - Adjusted the pagination logic to ensure correct page increments based on the total document count. This update improves the user experience by ensuring smoother document loading and better state management during scrolling interactions.
This commit is contained in:
@@ -1912,7 +1912,7 @@ func (h *InitializationHandler) testMultimodalWithDocReader(
|
||||
return nil, fmt.Errorf("DocReader service not configured")
|
||||
}
|
||||
|
||||
requestID, _ := ctx.Value(types.RequestIDContextKey).(string)
|
||||
requestID, _ := types.RequestIDFromContext(ctx)
|
||||
|
||||
readResult, err := h.documentReader.Read(ctx, &types.ReadRequest{
|
||||
FileContent: imageContent,
|
||||
|
||||
Reference in New Issue
Block a user