Import
import 'package:flutter/widgets.dart';
import 'package:fluttyui/fluttyui.dart' as ui;API Reference
The declarations below match the current FluttyUI source. Types are shown without the optional ui. import prefix.
LineChart
const LineChart({
super.key,
required super.data,
required super.xKey,
required super.yKeys,
super.series,
super.width,
super.height,
super.aspectRatio,
super.xAxis,
super.yAxis,
super.domain,
super.xDomain,
super.padding,
super.animation,
super.resetKey,
super.interaction,
super.controller,
super.onSelectionChanged,
super.onChartBoundsChange,
super.emptyBuilder,
super.domainPadding,
super.drawOn,
super.semanticsLabel = 'Line chart',
});| Parameter | Type | Required | Default |
|---|---|---|---|
key | Key? | No | null |
data | List<ChartDatum> | Yes | — |
xKey | String | Yes | — |
yKeys | List<String> | Yes | — |
series | List<ChartSeries>? | No | null |
width | double? | No | null |
height | double? | No | null |
aspectRatio | double | No | 1.6 |
xAxis | ChartAxis | No | const ChartAxis() |
yAxis | ChartAxis | No | const ChartAxis(showGrid: true) |
domain | ChartDomain | No | const ChartDomain() |
xDomain | ChartDomain | No | const ChartDomain() |
padding | EdgeInsets | No | const EdgeInsets.all(12) |
animation | ChartAnimation | No | const ChartAnimation() |
resetKey | Object? | No | null |
interaction | ChartInteraction | No | const ChartInteraction() |
controller | ChartController? | No | null |
onSelectionChanged | ValueChanged<ChartSelection?>? | No | null |
onChartBoundsChange | ValueChanged<Rect>? | No | null |
emptyBuilder | WidgetBuilder? | No | null |
domainPadding | EdgeInsets | No | const EdgeInsets.all(8) |
drawOn | bool | No | true |
semanticsLabel | String | No | 'Line chart' |
Application Setup
Place components under FluttyApp to provide theme, navigation, localization, and overlay defaults. Use theme tokens for shared appearance settings.
Source
lib/src/widgets/charts/line_chart/line_chart.dart
This reference is generated from the LineChart declaration in the FluttyUI core checkout. The component catalog lists the other available building blocks.

