A comprehensive React + TypeScript admin dashboard for monitoring bank client onboarding processes with Azure AD authentication, interactive charts, and real-time data management.
- Azure AD Integration: Full MSAL authentication with development bypass mode
- Protected Routes: All dashboard routes require authentication
- Token Management: Automatic token refresh and secure API calls
- KPI Tiles: Real-time metrics for total processes, success rate, pending reviews, and average completion time
- Interactive Charts:
- Daily metrics line chart showing process trends over time
- Outcome distribution donut chart with success/failure rates
- Responsive Design: Bootstrap-based responsive layout
- Paginated Table: Efficient display of onboarding processes with sorting and filtering
- Advanced Filtering: Filter by status, outcome, date range, and search by phone/email
- Process Details: Detailed view for individual onboarding processes
- Copy-to-Clipboard: Easy copying of process IDs and sensitive data
- WCAG 2.1 Compliance: Full keyboard navigation and screen reader support
- ARIA Labels: Comprehensive labeling for all interactive elements
- Focus Management: Clear focus indicators and skip links
- Reduced Motion: Respects user preferences for reduced motion
- High Contrast: Support for high contrast mode
- Loading States: Skeleton loaders and spinners for all async operations
- Error Boundaries: Graceful error handling with retry mechanisms
- Toast Notifications: User feedback for actions like copying data
- Offline Support: Graceful degradation when API is unavailable
- Frontend: React 18 + TypeScript
- Routing: React Router v6
- UI Framework: React Bootstrap
- Charts: Chart.js with react-chartjs-2
- Authentication: Microsoft MSAL (Azure AD)
- Build Tool: Vite
- Styling: Bootstrap 5 + Custom CSS
- Date Handling: date-fns
- API Integration: Custom TypeScript client based on OpenAPI spec
src/
βββ auth/ # Authentication configuration
β βββ authConfig.ts # MSAL configuration
β βββ AuthContext.tsx # React context for auth state
β βββ useApiClient.ts # Authenticated API client hook
βββ components/ # Reusable UI components
β βββ DailyChart.tsx # Daily metrics line chart
β βββ OutcomeChart.tsx # Outcome distribution donut chart
β βββ ProcessTable.tsx # Main data table with filtering
β βββ Header.tsx # Navigation header
β βββ LoadingSpinner.tsx # Loading state component
β βββ ErrorAlert.tsx # Error display component
β βββ AccessibleTable.tsx # Accessible table wrapper
β βββ ProtectedRoute.tsx # Route protection wrapper
βββ pages/ # Main application pages
β βββ Dashboard.tsx # Main dashboard page
β βββ ProcessDetails.tsx # Individual process details
βββ types/ # TypeScript type definitions
β βββ api.ts # API types from OpenAPI spec
βββ utils/ # Utility functions
β βββ mockData.ts # Development mock data
βββ styles/ # Custom styling
β βββ accessibility.css # Accessibility enhancements
βββ App.tsx # Main application component
- Node.js 16+ and npm
- Azure AD application registration (for production)
-
Clone the repository
git clone <repository-url> cd Dashboard-test2
-
Install dependencies
npm install
-
Environment Configuration
cp .env.example .env
Update
.env
with your Azure AD configuration:VITE_AZURE_CLIENT_ID=your-client-id VITE_AZURE_TENANT_ID=your-tenant-id VITE_API_BASE_URL=https://your-api-endpoint.com VITE_DEV_MODE=true # Set to false for production
-
Start Development Server
npm run dev
-
Access the Application
- Development: http://localhost:12000
- The app will automatically open in your browser
- Register a new application in Azure AD
- Configure redirect URIs for your domain
- Enable implicit flow for tokens
- Update
src/auth/authConfig.ts
with your tenant and client IDs
- The application uses a TypeScript client generated from the OpenAPI specification
- Update
VITE_API_BASE_URL
in your environment variables - API client automatically handles authentication headers
- Set
VITE_DEV_MODE=true
to bypass Azure AD authentication - Uses comprehensive mock data for development and testing
- All features work without backend connectivity
The application includes 150+ mock onboarding processes with:
- Realistic customer data (masked for privacy)
- Various process statuses and outcomes
- Date ranges spanning several months
- Different completion times and review states
- Bootstrap 5 variables can be customized in
src/styles/
- Custom CSS for accessibility and branding
- Responsive breakpoints configured for mobile-first design
- Chart.js configuration in component files
- Customizable colors, animations, and interactions
- Responsive design with proper ARIA labeling
- Configurable filter options in
ProcessTable.tsx
- Extensible search functionality
- Custom date range pickers
- Authentication flow (login/logout)
- Dashboard KPIs display correctly
- Charts render and are interactive
- Table sorting and filtering work
- Process details page loads
- Copy-to-clipboard functionality
- Keyboard navigation works
- Screen reader compatibility
- Mobile responsiveness
- Error states display properly
- Use browser dev tools accessibility audits
- Test with keyboard-only navigation
- Verify screen reader compatibility
- Check color contrast ratios
- Test with reduced motion preferences
npm run build
VITE_AZURE_CLIENT_ID=production-client-id
VITE_AZURE_TENANT_ID=production-tenant-id
VITE_API_BASE_URL=https://production-api.com
VITE_DEV_MODE=false
- Azure Static Web Apps: Native Azure AD integration
- Netlify/Vercel: Easy deployment with environment variables
- AWS S3 + CloudFront: Scalable static hosting
- All API calls include authentication headers
- Sensitive data is masked in the UI
- HTTPS required for production Azure AD
- Environment variables for configuration
- No sensitive data in client-side code
- Chrome 90+
- Firefox 88+
- Safari 14+
- Edge 90+
- Mobile browsers (iOS Safari, Chrome Mobile)
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly (including accessibility)
- Submit a pull request
This project is licensed under the MIT License - see the LICENSE file for details.
For issues and questions:
- Check the browser console for errors
- Verify environment configuration
- Test with development mode enabled
- Review Azure AD application settings
- v1.0.0: Initial release with full dashboard functionality
- Azure AD authentication
- Interactive charts and KPIs
- Comprehensive data table
- Full accessibility support
- Mobile-responsive design