Addresses race condition where fetchFlags could cause memory leaks and state updates after component unmount:
- Convert fetchFlags to useCallback with AbortSignal support
- Add useEffect with AbortController for proper request cancellation
- Prevent state updates when requests are aborted
- Handle AbortError gracefully without showing error messages
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Type System Enhancements:
- Introduced PayloadID helper type (string | number) for flexible ID handling
- Created shared types module (src/types/index.ts) for better type consistency
- Exported PayloadID and FeatureFlag types from main index for user access
- Fixed runtime issues with different Payload ID configurations
Configuration Improvements:
- Made API request limits configurable via maxFlags prop (default 100, max 1000)
- Added configurable collection slug support for custom collection names
- Enhanced URL construction to use config.routes.admin for proper path handling
- Improved server-side pagination with query parameter support
Code Quality:
- Centralized type definitions for better maintainability
- Enhanced type safety across client and server components
- Improved prop interfaces with better documentation
- Fixed potential number parsing edge cases with parseFloat
Developer Experience:
- Users can now configure collection slug, API limits, and admin paths
- Better TypeScript support with exported shared types
- Consistent handling of both string and numeric IDs
- More flexible plugin configuration options
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Accessibility Enhancements:
- Added role="alert" to error messages and read-only notices for screen readers
- Improved semantic HTML for better assistive technology support
Performance Optimizations:
- Implemented debounced search (300ms) to reduce re-renders during typing
- Added pagination support for large datasets (configurable limit up to 1000)
- Enhanced server-side data fetching with query parameter support
Input Improvements:
- Changed rollout percentage validation from parseInt to parseFloat for better decimal handling
- Made admin URL construction configurable using config.routes.admin
- Improved input validation with proper rounding for percentage values
Developer Experience:
- Added reusable useDebounce hook for performance optimization
- Better error handling for edge cases in numeric inputs
- Cleaner code organization with separated concerns
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Split feature flags view into server/client components for better performance
- Added comprehensive security checks for authentication and authorization
- Implemented read-only mode for users without update permissions
- Fixed checkbox state synchronization issues with server updates
- Improved UX: rollout percentage editable regardless of flag enabled state
- Added DefaultTemplate integration with proper PayloadCMS admin layout
- Enhanced error handling with specific messages for auth/permissions
- Removed debug logging for production readiness
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>