VoxResponsiveBuilder class
VoxResponsiveBuilder is a widget that allows us to build a different widget based on the screen size of the device. We generally want to add a padding and center the content if we are on desktop, and fill the entire context iof we are on tablet.
Our general rule of thumb, is that our ui will be approximately 600px wide
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatelessWidget
- VoxResponsiveBuilder
Constructors
- VoxResponsiveBuilder({required Widget child, double? width, double desktopMultiplier = 0.7, ScreenBreakpoints screenBreakpoints = const ScreenBreakpoints(tablet: 600, desktop: 950, watch: 300), Key? key})
-
VoxResponsiveBuilder constructor
const
Properties
- child → Widget
-
child is the child widget that we want to build responsively.
final
- desktopMultiplier → double
-
desktopMultiplier is the multiplier that we use to determine the width
of the widget on desktop
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
- screenBreakpoints → ScreenBreakpoints
-
screenBreakpoints is the breakpoints that we use to determine the
screen size
final
- width → double?
-
our nullable width allows us to pass a value to overright our defualt
of the size * 0.7
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