- 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
17 lines
658 B
TypeScript
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])),
|
|
],
|
|
};
|