ZoomDrawer class
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- ZoomDrawer
Constructors
-
ZoomDrawer({required Widget mainScreen, DrawerStyle style = DrawerStyle.defaultStyle, ZoomDrawerController? controller, double mainScreenScale = 0.3, double slideWidth = 275.0, double slideHeight = 0, double borderRadius = 16.0, double angle = -12.0, double dragOffset = 60.0, double openDragSensitivity = 425, double closeDragSensitivity = 425, Color drawerShadowsBackgroundColor = const Color(0xffffffff), Color? mainScreenOverlayColor, BlendMode overlayBlend = BlendMode.srcATop, double? overlayBlur, Color? shadowLayer1Color, Color? shadowLayer2Color, bool showShadow = false, Curve openCurve = const Interval(0.0, 1.0, curve: Curves.easeOut), Curve closeCurve = const Interval(0.0, 1.0, curve: Curves.easeOut), Duration duration = const Duration(milliseconds: 250), Duration reverseDuration = const Duration(milliseconds: 250), bool androidCloseOnBackTap = false, bool moveMenuScreen = true, bool disableDragGesture = false, bool isRtl = false, bool clipMainScreen = true, bool mainScreenTapClose = false, bool mainScreenAbsorbPointer = true, bool shrinkMainScreen = false, List<
BoxShadow> ? boxShadow, DrawerStyleBuilder? drawerStyleBuilder}) -
const
Properties
- androidCloseOnBackTap → bool
-
Close drawer on android back button
Note: This won't work if you are using WillPopScope in mainScreen,
If that is the case, you have to manually close the drawer from there
By using ZoomDrawer.of(context)?.close()
final
- angle → double
-
Rotation angle of the drawer
final
- borderRadius → double
-
Border radius of the slide content
final
-
boxShadow
→ List<
BoxShadow> ? -
The Shadow of the mainScreenWidget
final
- clipMainScreen → bool
-
Depreciated: Set borderRadius to 0 instead
final
- closeCurve → Curve
-
Drawer slide in curve
final
- closeDragSensitivity → double
-
How fast the closing drawer drag in response to a touch, the lower the more sensitive
final
- controller → ZoomDrawerController?
-
controller to have access to the open/close/toggle function of the drawer
final
- disableDragGesture → bool
-
Disable swipe gesture
final
- dragOffset → double
-
The offset to trigger drawer drag
final
- drawerShadowsBackgroundColor → Color
-
Background color of the drawer shadows
final
- drawerStyleBuilder → DrawerStyleBuilder?
-
Build custom animated style to override DrawerStyle
final
- duration → Duration
-
Drawer forward Duration
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- isRtl → bool
-
display the drawer in RTL
final
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- mainScreen → Widget
-
Screen containing the main content to display
final
- mainScreenAbsorbPointer → bool
-
Prevent touches to mainScreen while drawer is open
final
- mainScreenOverlayColor → Color?
-
Color of the main screen's cover overlay
final
- mainScreenScale → double
-
MainScreen scale factor
final
- mainScreenTapClose → bool
-
Close drawer when tapping mainScreen
final
-
Background color of the menuScreen
final
-
Screen containing the menu/bottom screen
final
-
Color of the menu screen's cover overlay
final
-
Close drawer when tapping menuScreen
final
-
menuScreen Width
Set it to double.infinity to make it take screen width
final
- moveMenuScreen → bool
-
Make menuScreen slide along with mainScreen animation
Has no effects to style1
final
- openCurve → Curve
-
Drawer slide out curve
final
- openDragSensitivity → double
-
How fast the opening drawer drag in response to a touch, the lower the more sensitive
final
- overlayBlend → BlendMode
-
The BlendMode of the mainScreenOverlayColor and menuScreenOverlayColor filter
final
- overlayBlur → double?
-
Apply a Blur amount to the mainScreen
final
- reverseDuration → Duration
-
Drawer reverse Duration
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- shadowLayer1Color → Color?
-
First shadow background color
final
- shadowLayer2Color → Color?
-
Second shadow background color
final
- showShadow → bool
-
Boolean, whether to show the drawer shadows - Applies to defaultStyle only
final
- shrinkMainScreen → bool
-
Shrinks the mainScreen by slideWidth
final
- slideHeight → double
-
Sliding height of the drawer
final
- slideWidth → double
-
Sliding width of the drawer
final
- style → DrawerStyle
-
Layout style
final
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → ZoomDrawerState -
Creates the mutable state for this widget at a given location in the tree.
override
-
debugDescribeChildren(
) → List< DiagnosticsNode> -
Returns a list of DiagnosticsNode objects describing this node's
children.
inherited
-
debugFillProperties(
DiagnosticPropertiesBuilder properties) → void -
Add additional properties associated with the node.
inherited
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toDiagnosticsNode(
{String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode -
Returns a debug representation of the object that is used by debugging
tools and by DiagnosticsNode.toStringDeep.
inherited
-
toString(
{DiagnosticLevel minLevel = DiagnosticLevel.info}) → String -
A string representation of this object.
inherited
-
toStringDeep(
{String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a string representation of this node and its descendants.
inherited
-
toStringShallow(
{String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String -
Returns a one-line detailed description of the object.
inherited
-
toStringShort(
) → String -
A short, textual description of this widget.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
of(
BuildContext context) → ZoomDrawerState? - static function to provide the drawer state