You have commit messages with errors
⧗ input: HUL-48 | Adding new icons for sledging qualities (And migration to TypeScript) (#50)
* feat: add TypeScript support with incremental migration capability
- Install TypeScript and essential type definitions (@types/react, @types/redux, etc.)
- Add tsconfig.json with React/Redux configuration and path mapping
- Update webpack config to handle .ts/.tsx files with ts-loader
- Configure ESLint with TypeScript parser and plugins for .ts/.tsx files
- Update Jest to support TypeScript testing with babel-jest
- Add TypeScript preset to Babel configuration
- Add type-check script to package.json for type validation
- Update README.md with TypeScript migration guidelines
- Maintain backward compatibility with existing .js/.jsx files
* refactor: migrate Redux reducers and tests to TypeScript
- Convert reducers/index.js to TypeScript with proper Redux Reducer types
- Migrate test file from JS to TS with type-safe action definitions
* feat: add centralized test utilities
- Create test/testUtils.tsx with renderWithProviders helper
- Move shared test utilities from inline definitions to dedicated module
- Update Main.test.jsx to use centralized test utilities
- Provide reusable Redux store and React Router setup for component testing
* refactor: convert NotFound component to TypeScript
- Convert NotFound.js to NotFound.tsx with proper TypeScript syntax
- Modernize class component to functional component
* fix: add TypeScript support to webpack configurations
- Add ts-loader with transpileOnly option to cfg/dev.js for development builds
- Add ts-loader with transpileOnly option to cfg/dist.js for production builds
- Enables proper compilation of .ts and .tsx files in all webpack environments
* refactor: convert ObservationItem to TypeScript with comprehensive test suite
- Convert ObservationItem.js to ObservationItem.tsx with full TypeScript typing
- Add comprehensive unit tests
- Add UnitObservation interface in types.ts for proper typing
- Use moment.js with Finnish locale for authentic date formatting
* refactor: convert utils to TypeScript with comprehensive test suite
- Convert utils.js to utils.ts with proper TypeScript typing
- Add comprehensive unit tests
* refactor: migrate UnitStatusSummary from JS to TypeScript
- Convert UnitStatusSummary.js to UnitStatusSummary.tsx with proper TypeScript types
- Add comprehensive test suite for UnitStatusSummary component
- Update UnitMassEdit to use ObservationItem instead of legacy Observation component
* refactor: convert Redux actions to TypeScript with comprehensive testing
- Convert actions/index.js to TypeScript with proper typing
- Create dedicated types.ts files for action-specific interfaces
- Move ActionTypes constants to centralized constants.ts
- Add comprehensive unit tests for all action creators
* refactor: convert UnitDescriptiveStatusForm to TypeScript with comprehensive test suite
- Migrate UnitDescriptiveStatusForm from JS class component to TS functional component
- Add comprehensive unit tests
- Fix unitId parameter type from string to number in enqueueObservation action
- Update action type definitions to use consistent number types
- Improve component logic with optional chaining and cleaner conditionals
* refactor: convert municipal-services-client.js to TypeScript
Rename municipal-services-client.js → municipalServicesClient.ts with full
TypeScript conversion including proper type definitions, interfaces, and
function overloads.
Additional changes:
- Consolidate type system by moving shared types to src/types.ts
- Add comprehensive unit test suite
- Update all import paths throughout codebase
- Fix type inconsistencies in UnitObservation.value handling
- Add API_URL environment variable setup for tests
* refactor: convert UnitDetails component to TypeScript
- Convert UnitDetails.js to UnitDetails.tsx with full type safety
- Add proper TypeScript interfaces for component props
- Export ObservableProperty and ObservablePropertyPanel components with types
- Fix Redux selector performance issue