Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use defaultWidthBreakPoint constant #12

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/src/wolt_screen_width_adaptive_widget.dart
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class WoltScreenWidthAdaptiveWidget extends StatelessWidget {
super.key,
required this.smallScreenWidthChild,
required this.largeScreenWidthChild,
this.widthBreakPoint = 768,
this.widthBreakPoint = defaultWidthBreakPoint,
});

/// The child widget to be displayed when the screen width is below the `widthBreakPoint`.
Expand All @@ -36,7 +36,7 @@ class WoltScreenWidthAdaptiveWidget extends StatelessWidget {
final Widget largeScreenWidthChild;

/// By default, the `widthBreakPoint` is set to 768, which corresponds to the common breakpoint between small and large screens.
static const defaultWidthBreakPoint = 768;
static const defaultWidthBreakPoint = 768.0;

/// The screen width breakpoint to determine the adaptive behavior.
/// If the screen width is below this breakpoint, the `smallScreenWidthChild` will be displayed;
Expand Down