configurable_expansion_tile
一個可設定的展開項目,由 Flutter Material 實現修改而來,允許自訂
一個可設定的展開項目,源自 Flutter Material 實現,允許自訂內部組件。
以下為英文專案原文快照,最新內容請造訪 GitHub。
A Configurable Expansion Tile edited from the flutter material implementation that allows for customization of the internal components. Includes providing colours, replacement widgets on expansion, and custom animations.
Tile animations still takes place (which are also configurable), and a widget can be set to precede and/or follow the provided header, which will rotate on expand/collapse of the tile.
Configure any or all parameters or leave default behaviour - header works out of the box.
In the dependencies: section of your pubspec.yaml, add the following line:
configurable_expansion_tile: <latest_version>
import 'package:configurable_expansion_tile/configurable_expansion_tile.dart';
class MyWidget extends StatelessWidget {
Widget build(BuildContext context) {
return ConfigurableExpansionTile(
headerExpanded: Flexible(child: Center(child: Text("A Header Changed"))),
header: Container(child: Center(child: Text("A Header"))),
children: [
Row(
children: <Widget>[Text("CHILD 1")],
),
// + more params, see example !!
],
);
}
}
View the Flutter app in the example directory.
依賴清單 2 項
{"sdk":"flutter"}{"sdk":"flutter"}先依使用情境篩選,再比較專案活躍情況,最後到原始儲存庫確認使用要求。
“A repository is the most basic element of GitHub.”
GitHub Docs — About repositories ↗