Drawer-Behavior-Flutter
Drawer-Behavior-Flutter copied to clipboard
Add property to change Leading Icon in DrawerScaffold()
I want to change the Icon to my desired icon.
When I add my desired icon in the leading
property in the AppBar
, I am not able to figure out what should be in the onPressed to open the side drawer.
If you allow the option to change the icon or tell me what should I put in the onPressed, it would be very helpful.
you can set AppBar by using appBar
prop
final DrawerScaffoldController controller = DrawerScaffoldController();
DrawerScaffold(
controller: controller,
appBar: AppBar(
leading: InkWell(
onTap: ()=> controller.toggle(),
child: Icon(Icons.menu),
),
),
)
more, https://github.com/shiburagi/Drawer-Behavior-Flutter#customize
related issue https://github.com/shiburagi/Drawer-Behavior-Flutter/issues/53