MoonPopover class

Inheritance

Constructors

MoonPopover({Key? key, required bool show, BorderRadiusGeometry? borderRadius, Color? backgroundColor, Color borderColor = Colors.transparent, Decoration? decoration, double borderWidth = 0, double? distanceToTarget, double? minHeight, double? minWidth, double? maxHeight, double? maxWidth, double popoverMargin = 8, Duration? transitionDuration, Curve? transitionCurve, EdgeInsetsGeometry? contentPadding, List<BoxShadow>? popoverShadows, MoonPopoverPosition popoverPosition = MoonPopoverPosition.top, RouteObserver<PageRoute>? routeObserver, String? semanticLabel, VoidCallback? onTapOutside, required Widget child, required Widget content})
Creates a Moon Design popover.
const

Properties

backgroundColor Color?
The background color of the popover.
final
borderColor Color
The border color of the popover.
final
borderRadius BorderRadiusGeometry?
The border radius of the popover.
final
borderWidth double
The border width of the popover.
final
child Widget
The widget to display as the child (target) of the popover.
final
content Widget
The widget to display inside the popover as its content.
final
contentPadding EdgeInsetsGeometry?
The padding of the popover content.
final
decoration Decoration?
The custom decoration of the popover.
final
distanceToTarget double?
The distance between the popover and the child (target).
final
hashCode int
The hash code for this object.
no setterinherited
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
maxHeight double?
An optional size constraint for the popover content to define its maximum height.
final
maxWidth double?
An optional size constraint for the popover content to define its maximum width.
final
minHeight double?
An optional size constraint for the popover content to define its minimum height.
final
minWidth double?
An optional size constraint for the popover content to define its minimum width.
final
onTapOutside VoidCallback?
The callback that is called when the user taps outside the popover.
final
popoverMargin double
The margin around the popover. Prevents the popover from touching the edges of the viewport.
final
popoverPosition MoonPopoverPosition
Sets the popover position relative to the child (target). Defaults to MoonPopoverPosition.vertical.
final
popoverShadows List<BoxShadow>?
The list of shadows applied to the popover.
final
routeObserver RouteObserver<PageRoute>?
The observer to keep track of the route changes and automatically hide the popover when the widget's route is not active.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
semanticLabel String?
The semantic label for the popover.
final
show bool
Whether to show the popover.
final
transitionCurve Curve?
The curve of the popover transition animation (fade in or out).
final
transitionDuration Duration?
The duration of the popover transition animation (fade in or out).
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() MoonPopoverState
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