Migrate package to git.zontreck.com

This commit is contained in:
zontreck 2025-01-22 12:00:13 -07:00
parent 6985aa366b
commit a8b322b54f
3 changed files with 70 additions and 22 deletions

View file

@ -1,24 +1,26 @@
# flutter_treeview
A hierarchical data widget for your flutter apps.
**NOTE**: This is a fork of the original project in order to maintain functionality across updates for this abandoned package.
A hierarchical data widget for your flutter apps.
It offers a number of options for customizing the appearance and handling user interaction.
It also offers some convenience methods for importing data into the tree.
## Features
* Separately customize child and parent labels
* Add any icon to a node
* Choose from four different expander icons and several modifiers for adjusting shape, outline, and fill.
* Import data from a Map
* Includes ability to handle expandChange, tap, and double tap user interactions
* Includes convenience methods for adding, updating and deleting nodes
- Separately customize child and parent labels
- Add any icon to a node
- Choose from four different expander icons and several modifiers for adjusting shape, outline, and fill.
- Import data from a Map
- Includes ability to handle expandChange, tap, and double tap user interactions
- Includes convenience methods for adding, updating and deleting nodes
## Sample Code
### Creating a TreeView
```dart
List<Node> nodes = [
Node(
@ -79,10 +81,12 @@ TreeView(
theme: treeViewTheme
),
```
_The TreeView requires that the onExpansionChange property updates the expanded
\_The TreeView requires that the onExpansionChange property updates the expanded
node so that the tree is rendered properly.
### Creating a theme
```dart
TreeViewTheme _treeViewTheme = TreeViewTheme(
expanderTheme: ExpanderThemeData(
@ -111,7 +115,9 @@ TreeViewTheme _treeViewTheme = TreeViewTheme(
```
### Using custom data
The Node class supports the use of custom data. You can use the data property on the Node instance to store data that you want to easily retrieve.
```dart
class Person {
final String name;
@ -140,7 +146,7 @@ List<Node> nodes = [
label: 'Otis',
key: 'otis',
data: otis,
),
),
//<T> is optional but recommended. If not specified, code can return Node<dynamic> instead of Node<Animal>
Node(
label: 'Zorro',
@ -160,13 +166,12 @@ TreeView(
),
```
## Getting Started
For help getting started with this widget, view our
For help getting started with this widget, view our
[online documentation](https://bitbucket.org/kevinandre/flutter_treeview/wiki/Home) or view the
full [API reference](https://pub.dev/documentation/flutter_treeview/latest/).
For help getting started with Flutter, view our
[online documentation](https://flutter.dev/docs), which offers tutorials,
For help getting started with Flutter, view our
[online documentation](https://flutter.dev/docs), which offers tutorials,
samples, guidance on mobile development, and a full API reference.