refactor: migrate sensors from TypeScript to JSON data
- Create sensors.json with all sensor data extracted from sensors.ts
- Add sensorLoader.ts to load sensors from JSON and instantiate sensor objects
- Update all imports to use sensorLoader instead of sensors
- Add conversion script (parse-sensors.mjs) to regenerate JSON from TypeScript
- Add documentation (README.md) explaining the new architecture
This change enables sensors to be loaded from remote sources in the future without requiring code changes, while maintaining full type safety.
Files modified:
- src/app/data/catalog-manager.ts
- src/app/sensors/sensorManager.ts
- src/plugins/sensor-list/sensor-list.ts
- src/plugins/sensor/multi-site-look-angles-plugin.ts
- test/environment/apiMocks.ts
Files added:
- src/app/data/catalogs/sensors.json (77 sensors)
- src/app/data/catalogs/sensorLoader.ts
- src/app/data/catalogs/README.md
- scripts/parse-sensors.mjs
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.
Quality Gate failed
Failed conditions
5 Security Hotspots
C Reliability Rating on New Code (required ≥ A)
See analysis details on SonarQube Cloud
Catch issues before they fail your Quality Gate with our IDE extension
SonarQube for IDE