Skip to content

Commit

Permalink
Publish v2.1.0
Browse files Browse the repository at this point in the history
  • Loading branch information
GanZhiXiong committed Jun 3, 2020
1 parent a54d8d7 commit c044794
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 5 deletions.
10 changes: 10 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
## [2.1.0] - [2020-06-03]
### ✨ New Features
* GZXDropDownMenu add dropdownMenuChanging and dropdownMenuChanged callback
* GZXDropDownHeaderItem add style (see https://github.com/GanZhiXiong/gzx_dropdown_menu/issues/27)
### ⚡️ Improvements
* Add removeListener and removeStatusListener when the animation is recreated
* Reduced calls to setstate
### 🐛 Bug Fixes
* Fixed Dropdown menu hide mask no animation

## [2.0.0+2] - [2020-05-11]
* Update Readme

Expand Down
22 changes: 19 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@ A custom is strong dropdown menu for Flutter. Easy to use and powerful for custo
* Custom dropdown menu animation
* Control dropdown menu show or hide

**<u>[点我查看版本更新记录](https://pub.flutter-io.cn/packages/gzx_dropdown_menu#-changelog-tab-)</u>**

## 开源不易🙀🙀🙀,麻烦给个Star⭐️吧!我会根据大家的关注度和个人时间持续更新代码!
**如你想接收更新消息,你可以Watch下,有问题请提到Issues。**

Expand Down Expand Up @@ -47,12 +49,14 @@ A custom is strong dropdown menu for Flutter. Easy to use and powerful for custo
打开pubspec.yaml文件
添加如下代码
``` dart
gzx_dropdown_menu : ^2.0.0
gzx_dropdown_menu : ^2.1.0
```
添加后打开Terminal,执行flutter packages get

### 2、使用
打开本仓库example项目下的gzx_dropdown_menu_test_page.dart文件自己看。
- **强烈建议你先clone下本仓库**
- 然后运行下看下效果
- 打开本仓库example项目下的gzx_dropdown_menu_test_page.dart文件自己看。

没空编辑文字了,而且说这么多还不如你直接运行下看下效果,然后看下代码,就知道如何使用了。

Expand All @@ -67,7 +71,7 @@ A custom is strong dropdown menu for Flutter. Easy to use and powerful for custo
items: [
GZXDropDownHeaderItem(_dropDownHeaderItemStrings[0]),
GZXDropDownHeaderItem(_dropDownHeaderItemStrings[1]),
GZXDropDownHeaderItem(_dropDownHeaderItemStrings[2]),
GZXDropDownHeaderItem(_dropDownHeaderItemStrings[2], style: TextStyle(color: Colors.green)),
GZXDropDownHeaderItem(_dropDownHeaderItemStrings[3], iconData: Icons.filter_frames, iconSize: 18),
],
// GZXDropDownHeader对应第一父级Stack的key
Expand Down Expand Up @@ -118,6 +122,18 @@ A custom is strong dropdown menu for Flutter. Easy to use and powerful for custo
animationMilliseconds: 500,
// 下拉后遮罩颜色
maskColor: Colors.red.withOpacity(0.5),
dropdownMenuChanging: (isShow, index) {
setState(() {
_dropdownMenuChange = '(正在${isShow ? '显示' : '隐藏'}$index)';
print(_dropdownMenuChange);
});
},
dropdownMenuChanged: (isShow, index) {
setState(() {
_dropdownMenuChange = '(已经${isShow ? '显示' : '隐藏'}$index)';
print(_dropdownMenuChange);
});
},
// 下拉菜单,高度自定义,你想显示什么就显示什么,完全由你决定,你只需要在选择后调用_dropdownMenuController.hide();即可
menus: [
GZXDropdownMenuBuilder(
Expand Down
5 changes: 4 additions & 1 deletion example/pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@ dependencies:
# Use with the CupertinoIcons class for iOS style icons.
cupertino_icons: ^0.1.2

# gzx_dropdown_menu : ^2.0.0
# ^1.2.3 等于 '>=1.2.3 <2.0.0'
# ^0.1.2 等于 '>=0.1.2 <0.2.0'
# see detail https://stackoverflow.com/questions/53563079/what-is-the-caret-sign-before-the-dependency-version-number-in-flutters-pub
# gzx_dropdown_menu : ^2.1.0

# gzx_dropdown_menu :
# git:
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: gzx_dropdown_menu
description: A custom is strong dropdown menu for Flutter. Easy to use and powerful for customization, it's up to you what you want to display in the dropdown menu!
version: 2.0.0+2
version: 2.1.0
homepage: https://github.com/GanZhiXiong/gzx_dropdown_menu

environment:
Expand Down

0 comments on commit c044794

Please sign in to comment.