You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
ansu_ui/example/lib/widgets/example_chart.dart

49 lines
1.3 KiB

3 years ago
import 'package:ansu_ui/ansu_ui.dart';
import 'package:ansu_ui/chart/circle_chart_widget.dart';
3 years ago
import 'package:example/codeviewer/code_segments.dart';
import 'package:example/common/code_view.dart';
3 years ago
import 'package:flutter/material.dart';
3 years ago
import 'package:get/get.dart';
3 years ago
class ExampleChart extends StatefulWidget {
const ExampleChart({Key? key}) : super(key: key);
3 years ago
@override
_ExampleChartState createState() => _ExampleChartState();
}
class _ExampleChartState extends State<ExampleChart> {
@override
Widget build(BuildContext context) {
return ASScaffold(
title: 'chart',
3 years ago
actions: [
IconButton(
icon: Icon(Icons.code, color: Colors.black54),
onPressed: () => Get.to(CodeView(
text: (context) => CodeSegments.button(context),
)),
),
],
3 years ago
body: ListView(
children: [
20.hb,
ListTile(
title: Text('circle chart'),
trailing: Container(
width: 50.w,
height: 50.w,
child: CircleChart(
size: 40.w,
color: Colors.red,
aboveStrokeWidth: 10.w,
core: '65%'.text.size(20.sp).color(kTextColor).make(),
aspectRato: 0.65,
),
)),
],
),
);
}
}