l5
import 'package:d_chart/d_chart.dart';
import 'package:flutter/material.dart';
List<TimeData> series = [
TimeData(domain: DateTime(2024, 1), measure: 30),
TimeData(domain: DateTime(2024, 2), measure: 20),
TimeData(domain: DateTime(2024, 3), measure: 45),
TimeData(domain: DateTime(2024, 4), measure: 40),
TimeData(domain: DateTime(2024, 5), measure: 22),
TimeData(domain: DateTime(2024, 6), measure: 30),
TimeData(domain: DateTime(2024, 7), measure: 70),
TimeData(domain: DateTime(2024, 8), measure: 40),
TimeData(domain: DateTime(2024, 9), measure: 30),
];
AspectRatio(
aspectRatio: 16 / 9,
child: DChartLineT(
configRenderLine: ConfigRenderLine(
includeArea: true,
areaOpacity: 0.1,
roundEndCaps: true,
includeLine: false,
),
layoutMargin: LayoutMargin(30, 10, 30, 10),
domainAxis: const DomainAxis(
noRenderSpec: true,
showLine: false,
),
measureAxis: const MeasureAxis(
noRenderSpec: true,
),
groupList: [
TimeGroup(
id: '1',
data: series,
color: Colors.blue.shade900,
),
],
),
),