ContextResponsiveX extension

Responsive context extensions.

context.width            // screen width in dp
context.isPhone          // true when width < 600
context.screenType       // AppScreenType.phone
on

Properties

height → double

Available on BuildContext, provided by the ContextResponsiveX extension

Full screen height in logical pixels.
no setter
isDesktop → bool

Available on BuildContext, provided by the ContextResponsiveX extension

True when the screen width is at or above the tablet breakpoint.
no setter
isLandscape → bool

Available on BuildContext, provided by the ContextResponsiveX extension

True when the screen is wider than it is tall.
no setter
isPhone → bool

Available on BuildContext, provided by the ContextResponsiveX extension

True when the screen width is below the phone breakpoint.
no setter
isPortrait → bool

Available on BuildContext, provided by the ContextResponsiveX extension

True when the screen is taller than it is wide.
no setter
isTablet → bool

Available on BuildContext, provided by the ContextResponsiveX extension

True when the screen width is in the tablet range.
no setter
orientation → Orientation

Available on BuildContext, provided by the ContextResponsiveX extension

Current orientation.
no setter
responsive → AppResponsiveState?

Available on BuildContext, provided by the ContextResponsiveX extension

The active AppResponsiveState if one is present, otherwise null.
no setter
safeBottom → double

Available on BuildContext, provided by the ContextResponsiveX extension

Bottom padding including system navigation / safe area.
no setter
safeTop → double

Available on BuildContext, provided by the ContextResponsiveX extension

Top padding including status bar / safe area.
no setter
screenType → AppScreenType

Available on BuildContext, provided by the ContextResponsiveX extension

Classified screen type (AppScreenType.phone, AppScreenType.tablet or AppScreenType.desktop).
no setter
theme → ThemeData

Available on BuildContext, provided by the ContextResponsiveX extension

The Theme.of(this) instance.
no setter
width → double

Available on BuildContext, provided by the ContextResponsiveX extension

Full screen width in logical pixels.
no setter