Skip to content

Commit

Permalink
dart fix to remove change files
Browse files Browse the repository at this point in the history
  • Loading branch information
stan-at-work committed Jan 11, 2025
1 parent 19af949 commit a6ffe4a
Show file tree
Hide file tree
Showing 18 changed files with 4,384 additions and 4,292 deletions.
48 changes: 32 additions & 16 deletions demo/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -59,44 +59,60 @@ class MyApp extends StatelessWidget {
kReleaseMode ? HomeScreen.routeName : DevelopmentScreen.routeName,
routes: {
HomeScreen.routeName: (context) => const HomeScreen(),
AddAndRemoveColumnRowScreen.routeName: (context) => const AddAndRemoveColumnRowScreen(),
AddRowsAsynchronouslyScreen.routeName: (context) => const AddRowsAsynchronouslyScreen(),
AddAndRemoveColumnRowScreen.routeName: (context) =>
const AddAndRemoveColumnRowScreen(),
AddRowsAsynchronouslyScreen.routeName: (context) =>
const AddRowsAsynchronouslyScreen(),
CellRendererScreen.routeName: (context) => const CellRendererScreen(),
CellSelectionScreen.routeName: (context) => const CellSelectionScreen(),
RTLScreen.routeName: (context) => const RTLScreen(),
ColumnFilteringScreen.routeName: (context) => const ColumnFilteringScreen(),
ColumnFilteringScreen.routeName: (context) =>
const ColumnFilteringScreen(),
ColumnFooterScreen.routeName: (context) => const ColumnFooterScreen(),
ColumnFreezingScreen.routeName: (context) => const ColumnFreezingScreen(),
ColumnFreezingScreen.routeName: (context) =>
const ColumnFreezingScreen(),
ColumnGroupScreen.routeName: (context) => const ColumnGroupScreen(),
ColumnHidingScreen.routeName: (context) => const ColumnHidingScreen(),
ColumnMenuScreen.routeName: (context) => const ColumnMenuScreen(),
ColumnMovingScreen.routeName: (context) => const ColumnMovingScreen(),
ColumnResizingScreen.routeName: (context) => const ColumnResizingScreen(),
ColumnResizingScreen.routeName: (context) =>
const ColumnResizingScreen(),
ColumnSortingScreen.routeName: (context) => const ColumnSortingScreen(),
CopyAndPasteScreen.routeName: (context) => const CopyAndPasteScreen(),
CurrencyTypeColumnScreen.routeName: (context) => const CurrencyTypeColumnScreen(),
CurrencyTypeColumnScreen.routeName: (context) =>
const CurrencyTypeColumnScreen(),
DarkModeScreen.routeName: (context) => const DarkModeScreen(),
DateTypeColumnScreen.routeName: (context) => const DateTypeColumnScreen(),
DateTypeColumnScreen.routeName: (context) =>
const DateTypeColumnScreen(),
DualModeScreen.routeName: (context) => const DualModeScreen(),
EditingStateScreen.routeName: (context) => const EditingStateScreen(),
ExportScreen.routeName: (context) => const ExportScreen(),
GridAsPopupScreen.routeName: (context) => const GridAsPopupScreen(),
ListingModeScreen.routeName: (context) => const ListingModeScreen(),
MovingScreen.routeName: (context) => const MovingScreen(),
NumberTypeColumnScreen.routeName: (context) => const NumberTypeColumnScreen(),
NumberTypeColumnScreen.routeName: (context) =>
const NumberTypeColumnScreen(),
RowColorScreen.routeName: (context) => const RowColorScreen(),
RowGroupScreen.routeName: (context) => const RowGroupScreen(),
RowInfinityScrollScreen.routeName: (context) => const RowInfinityScrollScreen(),
RowLazyPaginationScreen.routeName: (context) => const RowLazyPaginationScreen(),
RowInfinityScrollScreen.routeName: (context) =>
const RowInfinityScrollScreen(),
RowLazyPaginationScreen.routeName: (context) =>
const RowLazyPaginationScreen(),
RowMovingScreen.routeName: (context) => const RowMovingScreen(),
RowPaginationScreen.routeName: (context) => const RowPaginationScreen(),
RowSelectionScreen.routeName: (context) => const RowSelectionScreen(),
RowWithCheckboxScreen.routeName: (context) => const RowWithCheckboxScreen(),
SelectionTypeColumnScreen.routeName: (context) => const SelectionTypeColumnScreen(),
TextTypeColumnScreen.routeName: (context) => const TextTypeColumnScreen(),
TimeTypeColumnScreen.routeName: (context) => const TimeTypeColumnScreen(),
ValueFormatterScreen.routeName: (context) => const ValueFormatterScreen(),
CustomLoadingIndicatorScreen.routeName: (context) => const CustomLoadingIndicatorScreen(),
RowWithCheckboxScreen.routeName: (context) =>
const RowWithCheckboxScreen(),
SelectionTypeColumnScreen.routeName: (context) =>
const SelectionTypeColumnScreen(),
TextTypeColumnScreen.routeName: (context) =>
const TextTypeColumnScreen(),
TimeTypeColumnScreen.routeName: (context) =>
const TimeTypeColumnScreen(),
ValueFormatterScreen.routeName: (context) =>
const ValueFormatterScreen(),
CustomLoadingIndicatorScreen.routeName: (context) =>
const CustomLoadingIndicatorScreen(),
// only development
EmptyScreen.routeName: (context) => const EmptyScreen(),
DevelopmentScreen.routeName: (context) => const DevelopmentScreen(),
Expand Down
48 changes: 32 additions & 16 deletions demo/lib/screen/home_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,8 @@ class HomeScreen extends StatelessWidget {
cursor: SystemMouseCursors.click,
child: GestureDetector(
onTap: () {
launchUrl('https://www.buymeacoffee.com/manki');
launchUrl(
'https://www.buymeacoffee.com/manki');
},
child: Image.asset(
'assets/images/buy_me_a_coffee.png',
Expand Down Expand Up @@ -215,7 +216,8 @@ class PlutoFeatures extends StatelessWidget {
children: [
PlutoListTile(
title: 'Column moving',
description: 'Dragging the column heading left or right moves the column left and right.',
description:
'Dragging the column heading left or right moves the column left and right.',
onTapLiveDemo: () {
Navigator.pushNamed(context, ColumnMovingScreen.routeName);
},
Expand All @@ -236,14 +238,16 @@ class PlutoFeatures extends StatelessWidget {
),
PlutoListTile(
title: 'Column resizing',
description: 'Dragging the icon to the right of the column title left or right changes the width of the column.',
description:
'Dragging the icon to the right of the column title left or right changes the width of the column.',
onTapLiveDemo: () {
Navigator.pushNamed(context, ColumnResizingScreen.routeName);
},
),
PlutoListTile(
title: 'Column sorting',
description: 'Ascending or Descending by clicking on the column heading.',
description:
'Ascending or Descending by clicking on the column heading.',
onTapLiveDemo: () {
Navigator.pushNamed(context, ColumnSortingScreen.routeName);
},
Expand Down Expand Up @@ -271,7 +275,8 @@ class PlutoFeatures extends StatelessWidget {
),
PlutoListTile(
title: 'Column footer',
description: 'Display each column fixed at the bottom. (For outputting data sum, average, etc.)',
description:
'Display each column fixed at the bottom. (For outputting data sum, average, etc.)',
onTapLiveDemo: () {
Navigator.pushNamed(context, ColumnFooterScreen.routeName);
},
Expand Down Expand Up @@ -336,7 +341,8 @@ class PlutoFeatures extends StatelessWidget {
),
PlutoListTile(
title: 'Row selection',
description: 'In Row selection mode, Shift + tap or long tap and then move or Control + tap to select a row.',
description:
'In Row selection mode, Shift + tap or long tap and then move or Control + tap to select a row.',
onTapLiveDemo: () {
Navigator.pushNamed(context, RowSelectionScreen.routeName);
},
Expand All @@ -357,7 +363,8 @@ class PlutoFeatures extends StatelessWidget {
),
PlutoListTile(
title: 'Row lazy pagination',
description: 'Implement pagination in the form of fetching data from the server.',
description:
'Implement pagination in the form of fetching data from the server.',
onTapLiveDemo: () {
Navigator.pushNamed(context, RowLazyPaginationScreen.routeName);
},
Expand Down Expand Up @@ -397,28 +404,32 @@ class PlutoFeatures extends StatelessWidget {
),
PlutoListTile(
title: 'Cell selection',
description: 'In cell selection mode, Shift + tap or long tap and then move to select cells.',
description:
'In cell selection mode, Shift + tap or long tap and then move to select cells.',
onTapLiveDemo: () {
Navigator.pushNamed(context, CellSelectionScreen.routeName);
},
),
PlutoListTile(
title: 'Cell renderer',
description: 'You can change the widget of the cell through the renderer.',
description:
'You can change the widget of the cell through the renderer.',
onTapLiveDemo: () {
Navigator.pushNamed(context, CellRendererScreen.routeName);
},
),
PlutoListTile(
title: 'Copy and Paste',
description: 'Copy and paste are operated depending on the cell and row selection status.',
description:
'Copy and paste are operated depending on the cell and row selection status.',
onTapLiveDemo: () {
Navigator.pushNamed(context, CopyAndPasteScreen.routeName);
},
),
PlutoListTile(
title: 'Moving',
description: 'Change the current cell position with the arrow keys, enter key, and tab key.',
description:
'Change the current cell position with the arrow keys, enter key, and tab key.',
onTapLiveDemo: () {
Navigator.pushNamed(context, MovingScreen.routeName);
},
Expand All @@ -441,19 +452,22 @@ class PlutoFeatures extends StatelessWidget {
title: 'Add and Remove Columns, Rows',
description: 'You can add or delete columns, rows.',
onTapLiveDemo: () {
Navigator.pushNamed(context, AddAndRemoveColumnRowScreen.routeName);
Navigator.pushNamed(
context, AddAndRemoveColumnRowScreen.routeName);
},
),
PlutoListTile(
title: 'Dual mode',
description: 'Place the grid on the left and right and move or edit with the keyboard.',
description:
'Place the grid on the left and right and move or edit with the keyboard.',
onTapLiveDemo: () {
Navigator.pushNamed(context, DualModeScreen.routeName);
},
),
PlutoListTile(
title: 'Grid as Popup',
description: 'You can call the grid by popping up with the TextField.',
description:
'You can call the grid by popping up with the TextField.',
onTapLiveDemo: () {
Navigator.pushNamed(context, GridAsPopupScreen.routeName);
},
Expand Down Expand Up @@ -491,12 +505,14 @@ class PlutoFeatures extends StatelessWidget {
title: 'Custom Loading Indicator',
description: 'Define a custom loading indicator.',
onTapLiveDemo: () {
Navigator.pushNamed(context, CustomLoadingIndicatorScreen.routeName);
Navigator.pushNamed(
context, CustomLoadingIndicatorScreen.routeName);
},
),
PlutoListTile.amber(
title: 'Development',
description: 'This screen is used during development, and various functions can be tested.',
description:
'This screen is used during development, and various functions can be tested.',
onTapLiveDemo: () {
Navigator.pushNamed(context, DevelopmentScreen.routeName);
},
Expand Down
45 changes: 22 additions & 23 deletions example/lib/main.dart
Original file line number Diff line number Diff line change
Expand Up @@ -170,29 +170,28 @@ class _PlutoGridExamplePageState extends State<PlutoGridExamplePage> {
body: Container(
padding: const EdgeInsets.all(15),
child: PlutoGrid(
columns: columns,
rows: rows,
columnGroups: columnGroups,
onLoaded: (PlutoGridOnLoadedEvent event) {
stateManager = event.stateManager;
stateManager.setShowColumnFilter(true);
},
onChanged: (PlutoGridOnChangedEvent event) {
print(event);
},
configuration: const PlutoGridConfiguration(),
selectDateCallback: (PlutoCell cell, PlutoColumn column) async {
return showDatePicker(
context: context,
initialDate: PlutoDateTimeHelper.parseOrNullWithFormat(
cell.value,
column.type.date.format,
) ?? DateTime.now(),
firstDate: column.type.date.startDate ?? DateTime(0),
lastDate: column.type.date.endDate ?? DateTime(9999)
);
}
),
columns: columns,
rows: rows,
columnGroups: columnGroups,
onLoaded: (PlutoGridOnLoadedEvent event) {
stateManager = event.stateManager;
stateManager.setShowColumnFilter(true);
},
onChanged: (PlutoGridOnChangedEvent event) {
print(event);
},
configuration: const PlutoGridConfiguration(),
selectDateCallback: (PlutoCell cell, PlutoColumn column) async {
return showDatePicker(
context: context,
initialDate: PlutoDateTimeHelper.parseOrNullWithFormat(
cell.value,
column.type.date.format,
) ??
DateTime.now(),
firstDate: column.type.date.startDate ?? DateTime(0),
lastDate: column.type.date.endDate ?? DateTime(9999));
}),
),
);
}
Expand Down
Loading

0 comments on commit a6ffe4a

Please sign in to comment.