|
All checks were successful
Deploy Frontend / build-and-deploy (push) Successful in 4m17s
When users click on a different class, enum, or slot in the sidebar, the ontology term popup now automatically closes. This prevents the popup from persisting and showing stale information from the previously viewed schema element. |
||
|---|---|---|
| .. | ||
| data/sample-rdf | ||
| public | ||
| scripts | ||
| src | ||
| tests | ||
| .env.production | ||
| .gitignore | ||
| COMMANDS.md | ||
| eslint.config.js | ||
| FILES_CREATED.md | ||
| FOUNDATION_COMPLETE.md | ||
| FRONTEND_PROGRESS.md | ||
| GRAPH_VIZ_FEATURE_CHECKLIST.md | ||
| GRAPH_VIZ_PHASE1_COMPLETE.md | ||
| index.html | ||
| INDEX.md | ||
| INTEGRATION_GUIDE.md | ||
| NDE_HEADER_STYLING_COMPLETE.md | ||
| NDE_HOUSE_STYLE_APPLIED.md | ||
| NEXT_STEPS.md | ||
| OXIGRAPH_STATUS.md | ||
| package-lock.json | ||
| package.json | ||
| PHASE3_HISTORY_COMPLETE.md | ||
| PHASE3_PERSISTENT_UI_STATE_COMPLETE.md | ||
| PHASE3_STATE_MANAGEMENT.md | ||
| PHASE3_TASK6_COMPLETE.md | ||
| PHASE3_TASK6_QUERY_BUILDER.md | ||
| PHASE3_TASK7_PLAN.md | ||
| PHASE3_TASK7_PROGRESS.md | ||
| PROGRESS_DASHBOARD.md | ||
| README.md | ||
| SESSION_SUMMARY.md | ||
| SESSION_SUMMARY_TASK5.md | ||
| STEP1_COMPLETE.md | ||
| TASK6_SUMMARY.md | ||
| TASK7_COMPLETION_SUMMARY.md | ||
| TASK7_FINAL_STATUS.md | ||
| TASK7_HANDOFF.md | ||
| TASK7_QUICK_TEST.md | ||
| TDD_SESSION_FIXES.md | ||
| TESTING_TASK7.md | ||
| TRIPLESTORE_DECISION_SUMMARY.md | ||
| TRIPLESTORE_OXIGRAPH_SETUP.md | ||
| tsconfig.app.json | ||
| tsconfig.json | ||
| tsconfig.node.json | ||
| VISUALIZATION_COMPLETE.md | ||
| vite.config.ts | ||
| yarn.lock | ||
GLAM Heritage Custodian Frontend
Modern React frontend for visualizing and managing RDF transformation results from the GLAM Heritage Custodian Ontology project.
🎯 Project Overview
This frontend application provides interactive visualization of archival RDF data (EAD → RiC-O transformations) with force-directed graphs, bidirectional relationship exploration, and comprehensive metadata display.
Migrated from: example_ld (jQuery + vanilla JS) → React 19 + TypeScript + D3 v7
🚀 Quick Start
# Install dependencies
npm install
# Run development server
npm run dev
# Open http://localhost:5173
# Run tests
npm run test # Watch mode
npm run test:ui # UI with @vitest/ui
npm run test:run # Single run
npm run test:coverage # With coverage
# Build for production
npm run build
# Preview production build
npm run preview
📁 Project Structure
src/
├── components/ # React components
│ ├── layout/ # Layout components
│ ├── visualizations/ # D3 visualizations
│ │ ├── GraphView/ # Force-directed graph
│ │ ├── Timeline/ # Timeline visualization
│ │ ├── Map/ # Geographic map
│ │ └── Hierarchy/ # Hierarchical tree
│ ├── forms/ # Form components
│ └── ui/ # Reusable UI components
├── lib/ # Core libraries
│ ├── rdf/ # RDF parsing and graph utilities
│ ├── storage/ # IndexedDB manager
│ ├── api/ # API client
│ └── utils/ # Utility functions
├── hooks/ # Custom React hooks
├── stores/ # Zustand state stores
├── types/ # TypeScript type definitions
├── pages/ # Page components
└── styles/ # Global styles
tests/
├── unit/ # Unit tests
├── integration/ # Integration tests
└── e2e/ # E2E tests (Playwright)
🧪 Testing
Test coverage: ~85% (target: 80%+)
Test Files
tests/unit/rdf-parser.test.ts- RDF parsing tests (N-Triples, Turtle)tests/unit/graph-utils.test.ts- Graph utility function tests
Running Tests
# All tests in watch mode
npm run test
# Single run (CI/CD)
npm run test:run
# With coverage report
npm run test:coverage
# Interactive UI
npm run test:ui
📦 Key Dependencies
Production
- React 19.2.0 - UI framework
- TypeScript 5.9.3 - Type safety
- D3.js 7.9.0 - Data visualization
- n3 1.26.0 - RDF parsing
- Zustand 5.0.8 - State management
- React Query 5.90.10 - Data fetching
- React Router 7.9.6 - Routing
- Leaflet 1.9.4 - Maps
- Axios - HTTP client
- date-fns - Date utilities
- lodash - Utility functions
Development
- Vite 7.2.4 - Build tool
- Vitest 4.0.13 - Unit testing
- Playwright 1.56.1 - E2E testing
- Testing Library - React testing utilities
- ESLint - Linting
- Prettier - Code formatting
🎨 Features
Implemented ✅
- IndexedDB storage for large RDF files
- N-Triples RDF parser
- Turtle RDF parser
- Graph utility functions
- React hooks for data management
- Type-safe TypeScript interfaces
- Comprehensive test suite
In Progress 🚧
- Force-directed graph visualization (D3.js)
- Bidirectional edge interaction
- Upload form component
- Results display component
Planned 📋
- Timeline visualization
- Geographic map view
- Hierarchical tree view
- Statistics dashboard
- Export functionality
- Search and filtering
🔧 Development
Path Aliases
TypeScript path aliases are configured for clean imports:
import { parseNTriples } from '@/lib/rdf/parser';
import { useDatabase } from '@/hooks/useDatabase';
import type { GraphNode } from '@/types/rdf';
API Proxy
Development server proxies /api/* requests to backend at http://localhost:8000.
Environment Setup
# Node.js version
node --version # v24.5.0+
# npm version
npm --version # 11.5.1+
📚 Documentation
Comprehensive documentation available in /docs/plan/frontend/:
- 00-overview.md - Master implementation plan
- 01-architecture.md - System architecture (4-layer design)
- 02-design-patterns.md - 17 design patterns with examples
- 03-tdd-strategy.md - Test-driven development strategy
- 04-example-ld-mapping.md - Migration mapping from example_ld
- 05-master-checklist.md - 80-day task breakdown
- 06-visual-roadmap.md - Visual timeline and diagrams
- 07-quick-start-guide.md - 15-minute setup guide
🎓 Learning Resources
Example Project
Original implementation: /Users/kempersc/apps/example_ld/
Key files migrated:
static/js/db.js→src/lib/storage/indexed-db.tsstatic/js/graph.js→src/lib/rdf/parser.ts+src/lib/rdf/graph-utils.tsstatic/js/app.js→ (React components, in progress)
Technologies
- React 19 Docs
- TypeScript Handbook
- D3.js v7 Documentation
- Vitest Documentation
- Zustand Documentation
- React Query Docs
🤝 Contributing
Code Style
- TypeScript: Strict mode enabled
- Linting: ESLint + Prettier
- Tests: Required for new features (80%+ coverage)
- Commits: Conventional commits format
Development Workflow
- Create feature branch
- Write tests (TDD approach)
- Implement feature
- Run tests:
npm run test:run - Run linter:
npm run lint - Create pull request
📊 Project Status
Current Phase: Week 1-2 Foundation (60% complete)
| Component | Status | Coverage |
|---|---|---|
| Type Definitions | ✅ Complete | 100% |
| IndexedDB Manager | ✅ Complete | 95% |
| RDF Parser | ✅ Complete | 90% |
| Graph Utilities | ✅ Complete | 85% |
| React Hooks | 🟡 In Progress | 30% |
| Visualizations | ⏳ Not Started | 0% |
| UI Components | ⏳ Not Started | 0% |
Next Milestone: Force-directed graph visualization (Week 3-4)
🐛 Known Issues
None currently - project is in early development phase.
📝 License
Part of the GLAM Heritage Custodian Ontology project.
📞 Support
For questions or issues, refer to:
- Project documentation in
/docs/plan/frontend/ - Session summary:
SESSION_SUMMARY.md - Master checklist:
/docs/plan/frontend/05-master-checklist.md
Version: 0.1.0 (Foundation Phase)
Last Updated: 2024-11-22
Status: 🚧 Active Development