This repository has been archived on 2026-06-27. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
MSE-PI-E2EEDA-Plein-de-eeee…/ui/src/app/app.config.ts
T
khalil-bot a465cba225 feat(ui): dynamic room polling, secure credentials and CO2 levels
- Poll only rooms returned by /api/v1/rooms so calls are never wasted on
  sensor-less rooms; new rooms are picked up automatically after deploy
- Replace timer(0, interval) with concat() for synchronous initial emission
- Remove mock fallback from getLatestReadingForRoom / getHistoryForRoom so
  the UI reflects real API state instead of hiding errors with fake data
- Add Basic-Auth interceptor and dev proxy (proxy.conf.json) for local dev
- Replace hardcoded API credentials with __API_USERNAME__ / __API_PASSWORD__
  placeholders for CI-time injection from GitHub Secrets
- Add "Very Poor" CO2 level (1500-2000 ppm) to the 6-level scale
- Update "No sensor installed" copy to "No data available currently"
- Handle empty history state in room-details-panel

Closes #30
2026-05-27 22:00:11 +02:00

17 lines
658 B
TypeScript

import { ApplicationConfig, provideZoneChangeDetection } from '@angular/core';
import { provideRouter } from '@angular/router';
import { provideHttpClient, withInterceptors } from '@angular/common/http';
import { routes } from './app.routes';
import { provideAnimationsAsync } from '@angular/platform-browser/animations/async';
import { basicAuthInterceptor } from './interceptors/basic-auth.interceptor';
export const appConfig: ApplicationConfig = {
providers: [
provideZoneChangeDetection({ eventCoalescing: true }),
provideRouter(routes),
provideAnimationsAsync(),
provideHttpClient(withInterceptors([basicAuthInterceptor])),
],
};