mirror of
https://github.com/foss42/apidash.git
synced 2025-12-01 18:28:25 +08:00
feat: update default height and adjust height clamping in DashbotWindowNotifier
This commit is contained in:
@@ -9,7 +9,7 @@ class DashbotWindowModel {
|
||||
|
||||
const DashbotWindowModel({
|
||||
this.width = 400,
|
||||
this.height = 475,
|
||||
this.height = 500,
|
||||
this.right = 50,
|
||||
this.bottom = 100,
|
||||
this.isActive = false,
|
||||
|
||||
@@ -16,7 +16,7 @@ class DashbotWindowNotifier extends StateNotifier<DashbotWindowModel> {
|
||||
final newWidth =
|
||||
(state.width - dx).clamp(400, screenSize.width - state.right);
|
||||
final newHeight =
|
||||
(state.height - dy).clamp(460, screenSize.height - state.bottom);
|
||||
(state.height - dy).clamp(515, screenSize.height - state.bottom);
|
||||
|
||||
state = state.copyWith(
|
||||
width: newWidth.toDouble(),
|
||||
|
||||
@@ -40,6 +40,7 @@ class _DashbotHomePageState extends ConsumerState<DashbotHomePage> {
|
||||
return Container(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
kVSpacer16,
|
||||
DashbotIcons.getDashbotIcon1(width: 60),
|
||||
@@ -165,6 +166,7 @@ class _DashbotHomePageState extends ConsumerState<DashbotHomePage> {
|
||||
),
|
||||
],
|
||||
),
|
||||
kVSpacer20,
|
||||
],
|
||||
),
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user