sci_mobile_components 1.0.3 copy "sci_mobile_components: ^1.0.3" to clipboard
sci_mobile_components: ^1.0.3 copied to clipboard

outdated

Mobile UI component for SCI mobile project.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:sci_mobile_components/sci_mobile_components.dart';

void main() => runApp(MyApp());

class MyApp extends StatelessWidget {
  // This widget is the root of your application.

  @override
  Widget build(BuildContext context) {
    return SCIAppTheme(
      theme: SCIThemeModel(
        primaryColor: Color.fromRGBO(57, 151, 203, 1),
        secondaryColor: Color.fromRGBO(229, 144, 66, 1),
        lightColor: Color.fromRGBO(255, 255, 255, 1),
        darkColor: Color.fromRGBO(64, 64, 64, 1),
      ),
      child: MaterialApp(
        home: Scaffold(
          appBar: SCIAppBar(
            logo: Image.network('https://via.placeholder.com/140x40'),
            onSettingPressed: () {},
            onNotificationPressed: () {},
          ),
          body: Test(),
        ),
      ),
    );
  }
}

class Test extends StatelessWidget {
  final List<VitalSignData> data = [
    VitalSignData(createdDate: DateTime.now(), value: '36'),
    VitalSignData(
        createdDate: DateTime.now().add(Duration(days: 1)), value: '38'),
    VitalSignData(
        createdDate: DateTime.now().add(Duration(days: 2)), value: '32'),
  ];

  final List<VitalSignData> data1 = [
    VitalSignData(createdDate: DateTime.now(), value: '25'),
    VitalSignData(
        createdDate: DateTime.now().add(Duration(days: 1)), value: '23'),
    VitalSignData(
        createdDate: DateTime.now().add(Duration(days: 2)), value: '30'),
  ];

  @override
  Widget build(BuildContext context) {
    return Column(
      children: <Widget>[
        Container(
          padding: EdgeInsets.all(20.0),
          width: double.infinity,
          child: SCIBPChart(
            systolic: data,
            diastolic: data1,
            ageInDay: 30,
          ),
        ),
        Expanded(
          child: ListView(
            children: [
              ListTile(
                title: Text('Systolic'),
                subtitle: Text('10-12-2019'),
                trailing: CircleAvatar(
                  child: Text('85'),
                  backgroundColor: Colors.redAccent,
                ),
              ),
              ListTile(
                title: Text('Systolic'),
                subtitle: Text('10-12-2019'),
                trailing: CircleAvatar(
                  child: Text('85'),
                  backgroundColor: Colors.redAccent,
                ),
              ),
            ],
          ),
        )
      ],
    );
  }
}
0
likes
0
pub points
13%
popularity

Publisher

unverified uploader

Mobile UI component for SCI mobile project.

Homepage

License

unknown (LICENSE)

Dependencies

fl_chart, flutter, flutter_vector_icons

More

Packages that depend on sci_mobile_components