Skip to content

BRIC-11: Add RAG File Browser section for MinIO folder/file exploration#3

Merged
Kaiohz merged 1 commit into
mainfrom
BRIC-11/rag-file-browser
Apr 12, 2026
Merged

BRIC-11: Add RAG File Browser section for MinIO folder/file exploration#3
Kaiohz merged 1 commit into
mainfrom
BRIC-11/rag-file-browser

Conversation

@Kaiohz
Copy link
Copy Markdown
Contributor

@Kaiohz Kaiohz commented Apr 11, 2026

Jira

BRIC-11

Summary

  • Add "RAG" navigation section to composable-ui header with MinIO folder/file browser
  • Implement breadcrumb navigation + list view for browsing MinIO storage hierarchy
  • Create dedicated ragApiClient axios instance with ragApiBaseUrl from runtime config
  • Follow hexagonal architecture: Domain entities/ports → Infrastructure adapter → Application hooks/components/page

Changes

New Files (13 source + 11 test)

Domain Layer:

  • src/domain/entities/rag/fileEntry.tsFileEntry and FolderEntry classes with computed filename/name getters
  • src/domain/ports/rag/ragFilePort.tsIRagFilePort interface

Infrastructure Layer:

  • src/infrastructure/api/ragAxiosInstance.ts — Dedicated axios client for RAG API
  • src/infrastructure/api/rag/ragApi.ts — IRagFilePort implementation (listFolders, listFiles)

Application Layer:

  • src/application/hooks/rag/useFolders.ts — TanStack Query hook for folder listing
  • src/application/hooks/rag/useFiles.ts — TanStack Query hook for file listing
  • src/application/lib/formatFileSize.ts — Human-readable file size formatter
  • src/application/components/rag/BreadcrumbBar.tsx — Breadcrumb navigation
  • src/application/components/rag/FolderRow.tsx — Clickable folder row
  • src/application/components/rag/FileRow.tsx — File metadata row (name, size, date)
  • src/application/components/rag/FileList.tsx — Composed list with loading/error/empty states
  • src/application/pages/RagPage.tsx — Page orchestrator

Modified Files (5)

  • src/application/App.tsx — Add /rag route
  • src/application/components/layout/TopNav.tsx — Add "RAG" nav link
  • src/domain/entities/config/appConfig.ts — Add ragApiBaseUrl (optional)
  • vite.config.ts — Proxy /api/v1/files to port 8020
  • public/config.json / config.example.json — Add ragApiBaseUrl

Tests

  • 47 new unit tests (domain entities, API adapter, hooks, components, page)
  • 213 total tests passing (0 failures)
  • QA backend tests (18 tests) passing via soludev-compose-apps/bricks/qa/

Quality Gates

  • ESLint: 0 issues
  • Prettier: formatted
  • SonarQube: analysis successful
  • Trivy: 0 new vulnerabilities (2 pre-existing in axios)
  • Build: succeeds (553ms)

DO NOT MERGE

User requested review before merge.

…tion (BRIC-11)

- Add /rag route with BreadcrumbBar + FileList navigation
- Create dedicated ragApiClient with ragApiBaseUrl from config
- Implement hexagonal layers: FileEntry/FolderEntry entities, IRagFilePort, ragApi adapter
- Add useFolders and useFiles TanStack Query hooks
- Add formatFileSize utility, FileRow/FolderRow/BreadcrumbBar components
- Add Vite proxy for /api/v1/files to RAG service (port 8020)
- Add ragApiBaseUrl to AppConfigSchema (optional, backward compatible)
- 47 new unit tests, 213 total passing
@Kaiohz Kaiohz closed this Apr 12, 2026
@Kaiohz Kaiohz reopened this Apr 12, 2026
@Kaiohz Kaiohz marked this pull request as ready for review April 12, 2026 07:05
@Kaiohz Kaiohz merged commit 91a0ca7 into main Apr 12, 2026
1 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant