rapid_widgets_library 0.2.59 copy "rapid_widgets_library: ^0.2.59" to clipboard
rapid_widgets_library: ^0.2.59 copied to clipboard

flutter_catalogue_widgets,FlutterCatalogueWidgets,Flutter widgets,Flutter custom widgets,Flutter package,Flutter widgets package,Flutter custom widgets package,Custom widgets

example/lib/main.dart

//Use this to call a single widget without getting overflow error
import 'package:flutter/material.dart';


void main() => runApp(MaterialApp(home: BoilerPlate()));

class BoilerPlate extends StatefulWidget {
  @override
  _BoilerPlate createState() => _BoilerPlate();
}

class TableRowdata {
  final sno;
  final requirements;
  Widget proof;
  TableRowdata(
      {@required this.sno, @required this.requirements, @required this.proof});
}

List<TableRowdata> newDataList = [
  TableRowdata(sno: '1', requirements: 'GST Form', proof: Text('Text1')),
  TableRowdata(sno: '2', requirements: 'TIN Details', proof: Text('Text2')),
  TableRowdata(sno: '3', requirements: 'Signature', proof: Text('Text3')),
  TableRowdata(sno: '4', requirements: 'Bank Statement', proof: Text('Text4')),
];

class DTS extends DataTableSource {
  @override
  DataRow getRow(int index) {
    final Userr = newDataList[index];
    print(Userr);
    return DataRow(
        selected: true,
        cells: newDataList.length > 0
            ? [
                DataCell(Text((index + 1).toString())),
                DataCell(Text(Userr.requirements)),
                DataCell(Userr.proof),
              ]
            : [
                DataCell(Text(
                  'No Records Found !',
                  style: TextStyle(color: Colors.black, fontSize: 25),
                )),
                DataCell(Text(''))
              ]);
  }

  @override // TODO: implement isRowCountApproximate
  bool get isRowCountApproximate => false;
  @override // TODO: implement rowCount
  int get rowCount => newDataList.length;
  @override // TODO: implement selectedRowCount
  int get selectedRowCount => 0;
}

// final PaginatedDataTableData data = new PaginatedDataTableData(
//     tableData: DTS(),
//     headerText: null,
//     sortAscending: null,
//     sortColumnIndex: null,
//     rowsPerPage: 2,
//     columnSpacing: 120,
//     columns: <DataColumn>[
//       DataColumn(
//         label: Text('S.No',
//             textAlign: TextAlign.center, style: new TextStyle(fontSize: 18.0)),
//       ),
//       DataColumn(
//         label: Text('Docs',
//             textAlign: TextAlign.center, style: new TextStyle(fontSize: 18.0)),
//       ),
//       DataColumn(
//         label: Text('Status',
//             textAlign: TextAlign.center, style: new TextStyle(fontSize: 18.0)),
//       ),
//     ],
//     theme: ThemeData(
//       dividerColor: Colors.indigo,
//       cardColor: Colors.white,
//       applyElevationOverlayColor: true,
//       iconTheme: IconThemeData(color: Colors.pink, opacity: 10),
//     ));

class _BoilerPlate extends State<BoilerPlate> {
  @override
  Widget build(BuildContext context) {
    // Definition goes here
    return MaterialApp(
        //theme: MediumGreyThemeData(),
        debugShowCheckedModeBanner: false,
        home: Scaffold(
          //widget call for appbar goes here appBar:
          //widget call for drawer goes here drawer:
          //widget call for bottom navigation bar goes here
          body: Container(),
          // Widget Call goes here, Replace 'Container()',
        ));
  }
}

class CustompaginatedDataTable {
}