flutter_table_plus 1.6.0
flutter_table_plus: ^1.6.0 copied to clipboard
A highly customizable and efficient table widget for Flutter, featuring synchronized scrolling, theming, sorting, selection, and column reordering.
1.6.0 #
-
Enhanced Theming and Styling Capabilities
- Advanced Header Customization:
TablePlusHeaderThemenow includes adecorationproperty, allowing full control over the header's appearance (e.g., borders, gradients, shadows) usingBoxDecoration. - Individual Header Cell Styling: Added
cellDecorationtoTablePlusHeaderThemefor styling individual header cells. - Flexible Row Interaction Effects:
TablePlusSelectionThemehas been updated to provide more granular control over row interaction effects:- Set
hoverColor,splashColor, andhighlightColorindependently for both normal and selected rows (e.g.,rowHoverColor,selectedRowHoverColor). - If these properties are left
null, the default Flutter framework effects will be used, enhancing consistency and predictability. - The
enableRowInteractionEffectsproperty has been removed for a simpler and more direct API.
- Set
- Customizable Header Divider: Added
dividerThicknesstoTablePlusHeaderThemeto control the thickness of the header's bottom divider.
- Advanced Header Customization:
-
Improved Feature Flexibility
- Custom Row ID Key: Added a
rowIdKeyproperty toFlutterTablePlus, allowing developers to specify which key in their data map should be used as a unique row identifier. This removes the previous requirement of having a mandatory'id'key. - Text Overflow and Tooltip:
TablePlusColumnnow supports atextOverflowproperty (ellipsis,clip,fade). Whenellipsisis used, a tooltip automatically appears on hover to show the full text.
- Custom Row ID Key: Added a
-
Internal Code Refinements
- Theme Structure Refactoring: Theme-related classes have been organized into separate files (
header_theme.dart,body_theme.dart, etc.) for better code structure and maintainability.
- Theme Structure Refactoring: Theme-related classes have been organized into separate files (
1.5.0 #
-
Added Single Selection Mode
- Introduced
SelectionMode.singleto allow only one row to be selected at a time. - When a new row is selected in single selection mode, the previous selection is automatically cleared.
- The "Select All" checkbox is now automatically hidden when in single selection mode for a cleaner UI.
- Introduced
-
Refactored Example Page
- The main example page (
table_example_page.dart) has been significantly refactored for better readability and maintainability. - Key UI components like the app bar actions, status indicators, and documentation sections have been extracted into their own reusable widgets:
TableAppBarActionsTableStatusIndicatorsExampleDocumentation
- This improves code organization and makes the example easier to understand and adapt.
- The main example page (
1.4.0 #
-
Enhanced Feature Control Options
- Added ability to completely disable column reordering by setting
onColumnReorder: null. This removes drag handles and disables drag-and-drop functionality entirely. - Added ability to completely disable sorting by setting
onSort: null. This hides all sort icons and disables sorting click handlers for all columns. - Improved conditional feature control for better user experience and permissions-based functionality.
- Added ability to completely disable column reordering by setting
-
Documentation Improvements
- Added comprehensive Column Reordering section to ADVANCED_COLUMNS.md with complete implementation examples.
- Enhanced SORTING.md with detailed comparison between
sortable: falseandonSort: null. - Updated README.md with new "Conditional Feature Control" section and examples.
- Added practical examples for dynamic feature enabling/disabling based on user permissions.
1.3.0 #
- Enabled Simultaneous Selection and Editing
- Removed the restriction that prevented
isSelectableandisEditablefrom being active at the same time. - Now, rows can be selected even when cell editing is enabled, providing greater flexibility.
- Removed the restriction that prevented
1.2.0 #
- Added Configurable Sort Cycle Order
FlutterTablePlusnow includes asortCycleproperty to define the sequence of sorting states (ascending,descending,none).- The default cycle is
ascending->descending->none. - This allows for more flexible sorting behaviors, such as disabling the
nonestate or changing the order.
1.1.2 #
- Added Hint Text and Style for Editable Cells
TablePlusColumnnow includes an optionalhintTextproperty to display placeholder text in editableTextFields.TablePlusEditableThemenow includes an optionalhintStyleproperty to customize the style of the hint text.
- Added Row Double-Tap and Secondary-Tap Callbacks
FlutterTablePlusnow providesonRowDoubleTapandonRowSecondaryTapcallbacks for row-level gesture detection.- These callbacks are active when
isSelectableistrueandisEditableisfalse. CustomInkWellnow correctly handlesonDoubleTapandonSecondaryTapevents without interfering withonTap.- Ensured
CustomInkWell's internal state is preserved duringsetStateby addingkey: ValueKey(rowId).
1.1.1 #
- Update README.md
1.1.0 #
- Added Cell Editing Feature
Features #
- Editable Cells: Introduced
isEditableproperty inFlutterTablePlusto enable or disable cell editing. - Column-Specific Editing: Added
editableproperty toTablePlusColumnto control which columns can be edited. - Cell Change Callback: Implemented
onCellChangedto notify when a cell's value is updated. - Theming for Editing: Added
TablePlusEditableThemeto customize the appearance of cells in editing mode (background color, text style, borders, etc.). - Keyboard Support: Press
Enterto save changes orEscapeto cancel editing. Editing also stops when the cell loses focus.
1.0.0 #
- Initial release of
flutter_table_plus
Features #
- Highly Customizable Table: Provides a flexible and efficient table widget.
- Synchronized Scrolling: Horizontal and vertical scrolling is synchronized between the header and body.
- Theming: Extensive customization of table appearance through
TablePlusTheme, including headers, rows, scrollbars, and selection styles. - Column Sorting: Supports sorting columns in ascending, descending, or unsorted order. The sorting logic is handled by the parent widget.
- Row Selection: Allows for single or multiple row selection with checkboxes.
- Column Reordering: Supports drag-and-drop column reordering.
- Custom Cell Builders: Allows for custom widget rendering in cells for complex data representation.
- Type-Safe Column Builder: Use
TableColumnsBuilderto safely create and manage column order.