mirror of
https://github.com/SyncrowIOT/web.git
synced 2025-07-10 07:07:19 +00:00
32 lines
721 B
Dart
32 lines
721 B
Dart
import 'package:flutter/material.dart';
|
|
import 'package:syncrow_web/utils/color_manager.dart';
|
|
|
|
class AirQualityDataModel {
|
|
const AirQualityDataModel({
|
|
required this.date,
|
|
this.aqi,
|
|
this.pm25,
|
|
this.pm10,
|
|
this.hcho,
|
|
this.tvoc,
|
|
this.co2,
|
|
});
|
|
|
|
final DateTime date;
|
|
final double? aqi;
|
|
final double? pm25;
|
|
final double? pm10;
|
|
final double? hcho;
|
|
final double? tvoc;
|
|
final double? co2;
|
|
|
|
static const Map<String, Color> metricColors = {
|
|
'aqi': ColorsManager.goodGreen,
|
|
'pm25': ColorsManager.moderateYellow,
|
|
'pm10': ColorsManager.poorOrange,
|
|
'hcho': ColorsManager.unhealthyRed,
|
|
'tvoc': ColorsManager.severePink,
|
|
'co2': ColorsManager.hazardousPurple,
|
|
};
|
|
}
|