feat: hide dashbot fab when dashbot is open

This commit is contained in:
Udhay-Adithya
2025-09-24 22:27:21 +05:30
parent 35fad1338a
commit 5149179d66
4 changed files with 5 additions and 23 deletions

View File

@@ -21,6 +21,8 @@ class Dashboard extends ConsumerWidget {
ref.watch(settingsProvider.select((value) => value.isDashBotEnabled));
final isDashBotActive = ref
.watch(dashbotWindowNotifierProvider.select((value) => value.isActive));
final isDashBotPopped = ref
.watch(dashbotWindowNotifierProvider.select((value) => value.isPopped));
return Scaffold(
body: SafeArea(
child: Row(
@@ -129,7 +131,9 @@ class Dashboard extends ConsumerWidget {
],
),
),
floatingActionButton: isDashBotEnabled && !isDashBotActive
floatingActionButton: isDashBotEnabled &&
!isDashBotActive &&
isDashBotPopped
? FloatingActionButton(
backgroundColor: Theme.of(context).colorScheme.primaryContainer,
onPressed: () => showDashbotWindow(context, ref),