MorphReveal class
Content choreography: a block unfolds on its own sub-range of the same spring's progress - fade, slide-in, scale, and a vertical "unsquash" from the anchor. Content does not just appear and "be"; it unpacks out of the morph's direction of growth.
The no-overflow guarantee holds by construction: only render transforms are used here (Transform + Opacity). The block's layout is computed once at its final size; no animated constraints, SizeTransition, or heightFactor - the things that throw "RenderFlex overflowed" on every frame.
Like everything in the system it is a pure symmetric function of the spring value: on close the blocks fold back in reverse order, and interruption stays continuous.
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatelessWidget
- MorphReveal
Constructors
- MorphReveal({Key? key, double from = 0.45, double to = 0.9, Offset slideOffset = const Offset(0, 14), double scaleFrom = 0.96, double squashFrom = 0.85, Alignment alignment = Alignment.topCenter, Curve curve = Curves.easeOut, required Widget child})
-
Creates a reveal over
childon thefrom..toprogress range.const
Properties
- alignment → Alignment
-
The transform anchor - which edge the block unfolds from. Defaults
to the top: content "unpacks" downward, the same direction the
morph container grows.
final
- child → Widget
-
The content being revealed; laid out once at its final size.
final
- curve → Curve
-
Shaping curve applied inside the range; a pure function of
progress, so interruption continuity holds.
final
- from → double
-
The progress range
[from, to]over which the block unfolds. A cascade is built by offsetting the ranges of adjacent blocks.final - hashCode → int
-
The hash code for this object.
no setterinherited
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- scaleFrom → double
-
The block's starting overall scale.
final
- slideOffset → Offset
-
Where the block slides in from (logical pixels).
final
- squashFrom → double
-
The starting "squash": extra vertical compression on top of
scaleFrom. 1.0 disables it - the block only scales.
final
- to → double
-
Progress at which the block is fully revealed.
final
Methods
-
build(
BuildContext context) → Widget -
Describes the part of the user interface represented by this widget.
override
-
createElement(
) → StatelessElement -
Creates a StatelessElement to manage this widget's location in the tree.
inherited
-
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, int wrapWidth = 65}) → 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