smooth_line_chart 0.0.6
smooth_line_chart: ^0.0.6 copied to clipboard
The simplest way to add stunning line charts to your Flutter app. Smooth bezier curves, tap/hover tooltips, dark mode, gradient fill, async data loading — all with zero dependencies.
0.0.5 #
padding— inner padding around the chart area (defaultEdgeInsets.zero).- Fix value labels overlapping Y-axis at leftmost point (clamp X position).
- Fix value labels hidden when data point is near top of chart (flip below point).
- Removed stale
lib/main.dartfrom package root.
0.0.4 #
Functional
-
onPointTap— callback when user taps a data point (index, x, y, qty, range). -
yMin— set a minimum Y value so charts with high baseline data aren't flat. -
emptyWidget— custom widget shown whenyValuesis empty; defaults to "No data". -
onRangeChangedonSmoothLineChartAsync— called whenever the user switches range. -
height— fixed chart height in pixels as alternative toaspectRatio.
Visual
ChartTheme.showDots+dotRadius— show dots at every data point.ChartTheme.showValueLabels+valueLabelStyle— show Y value text above each point.ChartTheme.fillGradient— gradient fill below the line (overridesfillColor).backgroundColor+borderRadiusonChartCard/SmoothLineChart— card styling.
0.0.3 #
- Fix tooltip dismiss — tapping the active point now correctly hides the tooltip (was re-shown by
onPanUpdatefiring afteronTapDown). - Y labels overlay — new
yLabelOverlay: true(default) draws Y labels inside the chart, making it flush with any title above it. No extra left space consumed. - Tooltip arrow — new
tooltipArrow: trueshows a downward triangle pointer on the tooltip pointing toward the active data point.
0.0.2 #
- Flexible JSON parsing —
ChartData.fromMap()andChartData.fromList()factories for any JSON shape.fromPayloadnow also accepts flat lists and common key aliases (label,x,y,quantity,dateRange). - Tooltip dismiss — tap the active point again (or anywhere outside the chart) to close the tooltip on mobile/touch devices.
- Grid toggle —
ChartTheme.showGrid(defaulttrue); set tofalseto hide all grid lines. - Custom Y-axis labels —
ChartCard.yAxisLabels/SmoothLineChart.yAxisLabelslets you supply arbitrary text for each Y tick (e.g.['0', '500 Rb', '1 Jt']).
0.0.1 #
- Initial release.
ChartCard— interactive line + area chart with hover/tap tooltips.SmoothLineChart— simple one-widget entry point with optional title.SmoothLineChartAsync— built-in range selector + async data loading.RangeSelector— customizable pill-button time range picker.ChartData— data model with optionalfromPayloadfactory.ChartTheme— full color/style configuration including a dark preset.- Zero external dependencies — pure Flutter +
dart:math.
