From a904b2e97c703bbf86446d4f0a8dd691fa38ed9f Mon Sep 17 00:00:00 2001 From: Yashas H Majmudar Date: Tue, 19 Mar 2024 00:17:09 +0530 Subject: [PATCH 1/7] feat: Search Requests UI --- lib/screens/home_page/collection_pane.dart | 101 +++++++++++++++++++-- lib/screens/home_page/home_page.dart | 2 +- lib/screens/mobile/dashboard.dart | 2 +- 3 files changed, 96 insertions(+), 9 deletions(-) diff --git a/lib/screens/home_page/collection_pane.dart b/lib/screens/home_page/collection_pane.dart index c70db3ad..f81f0304 100644 --- a/lib/screens/home_page/collection_pane.dart +++ b/lib/screens/home_page/collection_pane.dart @@ -1,30 +1,105 @@ -import 'package:flutter/material.dart'; -import 'package:flutter_riverpod/flutter_riverpod.dart'; +import 'package:apidash/consts.dart'; +import 'package:apidash/models/models.dart'; import 'package:apidash/providers/providers.dart'; import 'package:apidash/widgets/widgets.dart'; -import 'package:apidash/models/models.dart'; -import 'package:apidash/consts.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_riverpod/flutter_riverpod.dart'; class CollectionPane extends ConsumerWidget { - const CollectionPane({ + CollectionPane({ super.key, }); + final textEditController = TextEditingController(); + @override Widget build(BuildContext context, WidgetRef ref) { var sm = ScaffoldMessenger.of(context); final collection = ref.watch(collectionStateNotifierProvider); final savingData = ref.watch(saveDataStateProvider); + if (collection == null) { return const Center( child: CircularProgressIndicator(), ); } + return Padding( padding: kIsMacOS ? kP24CollectionPane : kP8CollectionPane, child: Column( crossAxisAlignment: CrossAxisAlignment.stretch, children: [ + Container( + height: 35, + margin: const EdgeInsets.symmetric(horizontal: 8), + padding: const EdgeInsets.symmetric(horizontal: 5), + decoration: BoxDecoration( + borderRadius: kBorderRadius8, + border: Border.all( + color: Theme.of(context).colorScheme.surfaceVariant, + width: 1, + ), + ), + alignment: Alignment.center, + child: Row( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.center, + mainAxisSize: MainAxisSize.max, + children: [ + const Icon( + Icons.search_rounded, + size: 18, + ), + kHSpacer5, + Expanded( + child: SizedBox( + height: 35, + child: TextField( + onChanged: (value) => ref + .read(collectionStateNotifierProvider.notifier) + .filter(value.trim()), + controller: textEditController, + decoration: const InputDecoration( + constraints: BoxConstraints( + maxHeight: 35, + minHeight: 35, + ), + border: InputBorder.none, + contentPadding: EdgeInsets.only( + bottom: 16, + right: 5, + left: 5, + ), + counterText: '', + ), + // cursorHeight: 12, + maxLines: 1, + maxLength: 150, + style: const TextStyle( + fontSize: 12, + // height: 0.1, + ), + ), + ), + ), + kHSpacer5, + if (textEditController.text != '') + GestureDetector( + onTap: () { + textEditController.text = ''; + ref + .read(collectionStateNotifierProvider.notifier) + .filter(''); + }, + child: const Icon( + Icons.close, + size: 18, + ), + ), + ], + ), + ), + kVSpacer8, Padding( padding: kPr8CollectionPane, child: Wrap( @@ -64,8 +139,20 @@ class CollectionPane extends ConsumerWidget { ), ), kVSpacer8, - const Expanded( - child: RequestList(), + Consumer( + builder: (_, ref, __) { + final searching = ref.watch(searchRequestsProvider); + + return searching + ? const Expanded( + child: Center( + child: CircularProgressIndicator(), + ), + ) + : const Expanded( + child: RequestList(), + ); + }, ), ], ), diff --git a/lib/screens/home_page/home_page.dart b/lib/screens/home_page/home_page.dart index a7338a08..76b07230 100644 --- a/lib/screens/home_page/home_page.dart +++ b/lib/screens/home_page/home_page.dart @@ -8,7 +8,7 @@ class HomePage extends StatelessWidget { @override Widget build(BuildContext context) { - return const Column( + return Column( children: [ Expanded( child: DashboardSplitView( diff --git a/lib/screens/mobile/dashboard.dart b/lib/screens/mobile/dashboard.dart index b6f25041..dab0654b 100644 --- a/lib/screens/mobile/dashboard.dart +++ b/lib/screens/mobile/dashboard.dart @@ -49,7 +49,7 @@ class _MobileDashboardState extends ConsumerState { onTap: () { Navigator.of(context).pushAndRemoveUntil( MaterialPageRoute( - builder: (context) => const MobileDashboard( + builder: (context) => MobileDashboard( title: 'Requests', scaffoldBody: CollectionPane(), ), From 549d69c05185b0b42b14c509a27581597e6688b4 Mon Sep 17 00:00:00 2001 From: Yashas H Majmudar Date: Tue, 19 Mar 2024 00:19:13 +0530 Subject: [PATCH 2/7] Revert "feat: Search Requests UI" This reverts commit a904b2e97c703bbf86446d4f0a8dd691fa38ed9f. --- lib/screens/home_page/collection_pane.dart | 101 ++------------------- lib/screens/home_page/home_page.dart | 2 +- lib/screens/mobile/dashboard.dart | 2 +- 3 files changed, 9 insertions(+), 96 deletions(-) diff --git a/lib/screens/home_page/collection_pane.dart b/lib/screens/home_page/collection_pane.dart index f81f0304..c70db3ad 100644 --- a/lib/screens/home_page/collection_pane.dart +++ b/lib/screens/home_page/collection_pane.dart @@ -1,105 +1,30 @@ -import 'package:apidash/consts.dart'; -import 'package:apidash/models/models.dart'; -import 'package:apidash/providers/providers.dart'; -import 'package:apidash/widgets/widgets.dart'; import 'package:flutter/material.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; +import 'package:apidash/providers/providers.dart'; +import 'package:apidash/widgets/widgets.dart'; +import 'package:apidash/models/models.dart'; +import 'package:apidash/consts.dart'; class CollectionPane extends ConsumerWidget { - CollectionPane({ + const CollectionPane({ super.key, }); - final textEditController = TextEditingController(); - @override Widget build(BuildContext context, WidgetRef ref) { var sm = ScaffoldMessenger.of(context); final collection = ref.watch(collectionStateNotifierProvider); final savingData = ref.watch(saveDataStateProvider); - if (collection == null) { return const Center( child: CircularProgressIndicator(), ); } - return Padding( padding: kIsMacOS ? kP24CollectionPane : kP8CollectionPane, child: Column( crossAxisAlignment: CrossAxisAlignment.stretch, children: [ - Container( - height: 35, - margin: const EdgeInsets.symmetric(horizontal: 8), - padding: const EdgeInsets.symmetric(horizontal: 5), - decoration: BoxDecoration( - borderRadius: kBorderRadius8, - border: Border.all( - color: Theme.of(context).colorScheme.surfaceVariant, - width: 1, - ), - ), - alignment: Alignment.center, - child: Row( - mainAxisAlignment: MainAxisAlignment.start, - crossAxisAlignment: CrossAxisAlignment.center, - mainAxisSize: MainAxisSize.max, - children: [ - const Icon( - Icons.search_rounded, - size: 18, - ), - kHSpacer5, - Expanded( - child: SizedBox( - height: 35, - child: TextField( - onChanged: (value) => ref - .read(collectionStateNotifierProvider.notifier) - .filter(value.trim()), - controller: textEditController, - decoration: const InputDecoration( - constraints: BoxConstraints( - maxHeight: 35, - minHeight: 35, - ), - border: InputBorder.none, - contentPadding: EdgeInsets.only( - bottom: 16, - right: 5, - left: 5, - ), - counterText: '', - ), - // cursorHeight: 12, - maxLines: 1, - maxLength: 150, - style: const TextStyle( - fontSize: 12, - // height: 0.1, - ), - ), - ), - ), - kHSpacer5, - if (textEditController.text != '') - GestureDetector( - onTap: () { - textEditController.text = ''; - ref - .read(collectionStateNotifierProvider.notifier) - .filter(''); - }, - child: const Icon( - Icons.close, - size: 18, - ), - ), - ], - ), - ), - kVSpacer8, Padding( padding: kPr8CollectionPane, child: Wrap( @@ -139,20 +64,8 @@ class CollectionPane extends ConsumerWidget { ), ), kVSpacer8, - Consumer( - builder: (_, ref, __) { - final searching = ref.watch(searchRequestsProvider); - - return searching - ? const Expanded( - child: Center( - child: CircularProgressIndicator(), - ), - ) - : const Expanded( - child: RequestList(), - ); - }, + const Expanded( + child: RequestList(), ), ], ), diff --git a/lib/screens/home_page/home_page.dart b/lib/screens/home_page/home_page.dart index 76b07230..a7338a08 100644 --- a/lib/screens/home_page/home_page.dart +++ b/lib/screens/home_page/home_page.dart @@ -8,7 +8,7 @@ class HomePage extends StatelessWidget { @override Widget build(BuildContext context) { - return Column( + return const Column( children: [ Expanded( child: DashboardSplitView( diff --git a/lib/screens/mobile/dashboard.dart b/lib/screens/mobile/dashboard.dart index dab0654b..b6f25041 100644 --- a/lib/screens/mobile/dashboard.dart +++ b/lib/screens/mobile/dashboard.dart @@ -49,7 +49,7 @@ class _MobileDashboardState extends ConsumerState { onTap: () { Navigator.of(context).pushAndRemoveUntil( MaterialPageRoute( - builder: (context) => MobileDashboard( + builder: (context) => const MobileDashboard( title: 'Requests', scaffoldBody: CollectionPane(), ), From b4bf2a191114f55b1d033b0e9f22b826ca016d77 Mon Sep 17 00:00:00 2001 From: Yashas H Majmudar Date: Tue, 19 Mar 2024 00:26:45 +0530 Subject: [PATCH 3/7] feat: search from requests --- lib/app.dart | 2 +- lib/providers/collection_providers.dart | 32 +++++++- lib/providers/ui_providers.dart | 2 + lib/screens/home_page/collection_pane.dart | 85 ++++++++++++++++++++-- 4 files changed, 111 insertions(+), 10 deletions(-) diff --git a/lib/app.dart b/lib/app.dart index f60198af..41b4c769 100644 --- a/lib/app.dart +++ b/lib/app.dart @@ -124,7 +124,7 @@ class DashApp extends ConsumerWidget { ), themeMode: isDarkMode ? ThemeMode.dark : ThemeMode.light, home: kIsMobile - ? const MobileDashboard( + ? MobileDashboard( title: 'Requests', scaffoldBody: CollectionPane(), ) diff --git a/lib/providers/collection_providers.dart b/lib/providers/collection_providers.dart index db6b7cf3..3dccc709 100644 --- a/lib/providers/collection_providers.dart +++ b/lib/providers/collection_providers.dart @@ -1,11 +1,14 @@ +import 'dart:async'; + import 'package:flutter_riverpod/flutter_riverpod.dart'; -import 'settings_providers.dart'; -import 'ui_providers.dart'; +import 'package:http/http.dart' as http; + +import '../consts.dart'; import '../models/models.dart'; import '../services/services.dart' show hiveHandler, HiveHandler, request; import '../utils/utils.dart' show getNewUuid, collectionToHAR; -import '../consts.dart'; -import 'package:http/http.dart' as http; +import 'settings_providers.dart'; +import 'ui_providers.dart'; final selectedIdStateProvider = StateProvider((ref) => null); @@ -53,6 +56,27 @@ class CollectionStateNotifier return state?[id]; } + void filter(String query) { + ref.read(searchRequestsProvider.notifier).update((state) => true); + + if (query == '') { + loadData(); + ref.read(requestSequenceProvider.notifier).state = [ + ...state!.keys, + ]; + } else { + final map = {...state!}; + map.removeWhere((key, value) => + !(value.name.toLowerCase().contains(query.toLowerCase()) || + value.url.toLowerCase().contains(query.toLowerCase()))); + ref + .read(requestSequenceProvider.notifier).state = [...map.keys]; + state = map; + } + + ref.read(searchRequestsProvider.notifier).update((state) => false); + } + void add() { final id = getNewUuid(); final newRequestModel = RequestModel( diff --git a/lib/providers/ui_providers.dart b/lib/providers/ui_providers.dart index 2fddb2ad..b0ccbd4c 100644 --- a/lib/providers/ui_providers.dart +++ b/lib/providers/ui_providers.dart @@ -6,6 +6,8 @@ final selectedIdEditStateProvider = StateProvider((ref) => null); final codePaneVisibleStateProvider = StateProvider((ref) => false); final saveDataStateProvider = StateProvider((ref) => false); final clearDataStateProvider = StateProvider((ref) => false); +final searchRequestsProvider = StateProvider((ref) => false); + // final nameTextFieldControllerProvider = // StateProvider.autoDispose((ref) { // TextEditingController controller = TextEditingController(text: ""); diff --git a/lib/screens/home_page/collection_pane.dart b/lib/screens/home_page/collection_pane.dart index c70db3ad..78c22419 100644 --- a/lib/screens/home_page/collection_pane.dart +++ b/lib/screens/home_page/collection_pane.dart @@ -1,30 +1,105 @@ -import 'package:flutter/material.dart'; -import 'package:flutter_riverpod/flutter_riverpod.dart'; +import 'package:apidash/consts.dart'; +import 'package:apidash/models/models.dart'; import 'package:apidash/providers/providers.dart'; import 'package:apidash/widgets/widgets.dart'; -import 'package:apidash/models/models.dart'; -import 'package:apidash/consts.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_riverpod/flutter_riverpod.dart'; class CollectionPane extends ConsumerWidget { - const CollectionPane({ + CollectionPane({ super.key, }); + final textEditController = TextEditingController(); + @override Widget build(BuildContext context, WidgetRef ref) { var sm = ScaffoldMessenger.of(context); final collection = ref.watch(collectionStateNotifierProvider); final savingData = ref.watch(saveDataStateProvider); + if (collection == null) { return const Center( child: CircularProgressIndicator(), ); } + return Padding( padding: kIsMacOS ? kP24CollectionPane : kP8CollectionPane, child: Column( crossAxisAlignment: CrossAxisAlignment.stretch, children: [ + Container( + height: 35, + margin: const EdgeInsets.symmetric(horizontal: 8), + padding: const EdgeInsets.symmetric(horizontal: 5), + decoration: BoxDecoration( + borderRadius: kBorderRadius8, + border: Border.all( + color: Theme.of(context).colorScheme.surfaceVariant, + width: 1, + ), + ), + alignment: Alignment.center, + child: Row( + mainAxisAlignment: MainAxisAlignment.start, + crossAxisAlignment: CrossAxisAlignment.center, + mainAxisSize: MainAxisSize.max, + children: [ + const Icon( + Icons.search_rounded, + size: 18, + ), + kHSpacer5, + Expanded( + child: SizedBox( + height: 35, + child: TextField( + onChanged: (value) => ref + .read(collectionStateNotifierProvider.notifier) + .filter(value.trim()), + controller: textEditController, + decoration: const InputDecoration( + constraints: BoxConstraints( + maxHeight: 35, + minHeight: 35, + ), + border: InputBorder.none, + contentPadding: EdgeInsets.only( + bottom: 16, + right: 5, + left: 5, + ), + counterText: '', + ), + // cursorHeight: 12, + maxLines: 1, + maxLength: 150, + style: const TextStyle( + fontSize: 12, + // height: 0.1, + ), + ), + ), + ), + kHSpacer5, + if (textEditController.text != '') + GestureDetector( + onTap: () { + textEditController.text = ''; + ref + .read(collectionStateNotifierProvider.notifier) + .filter(''); + }, + child: const Icon( + Icons.close, + size: 18, + ), + ), + ], + ), + ), + kVSpacer8, Padding( padding: kPr8CollectionPane, child: Wrap( From 6d13c8de49572c801ba18aa4137b5d80a98497ee Mon Sep 17 00:00:00 2001 From: Yashas H Majmudar Date: Tue, 19 Mar 2024 07:44:27 +0530 Subject: [PATCH 4/7] fix: minor bug fix --- lib/screens/home_page/home_page.dart | 4 ++-- lib/screens/mobile/dashboard.dart | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/screens/home_page/home_page.dart b/lib/screens/home_page/home_page.dart index a7338a08..84efbf7d 100644 --- a/lib/screens/home_page/home_page.dart +++ b/lib/screens/home_page/home_page.dart @@ -8,12 +8,12 @@ class HomePage extends StatelessWidget { @override Widget build(BuildContext context) { - return const Column( + return Column( children: [ Expanded( child: DashboardSplitView( sidebarWidget: CollectionPane(), - mainWidget: RequestEditorPane(), + mainWidget: const RequestEditorPane(), ), ), ], diff --git a/lib/screens/mobile/dashboard.dart b/lib/screens/mobile/dashboard.dart index b6f25041..ef4320f3 100644 --- a/lib/screens/mobile/dashboard.dart +++ b/lib/screens/mobile/dashboard.dart @@ -49,7 +49,7 @@ class _MobileDashboardState extends ConsumerState { onTap: () { Navigator.of(context).pushAndRemoveUntil( MaterialPageRoute( - builder: (context) => const MobileDashboard( + builder: (context) => MobileDashboard( title: 'Requests', scaffoldBody: CollectionPane(), ), From 2bd2a40ddce3ac28635ff508acb29267dea5f644 Mon Sep 17 00:00:00 2001 From: Yashas H Majmudar Date: Wed, 20 Mar 2024 00:33:35 +0530 Subject: [PATCH 5/7] fix: fixed issue with request filtering and showed a request not fount when nothing matches query --- lib/app.dart | 2 +- lib/providers/collection_providers.dart | 2 -- lib/screens/home_page/collection_pane.dart | 28 ++++++++-------------- lib/screens/home_page/home_page.dart | 4 ++-- lib/screens/mobile/dashboard.dart | 2 +- 5 files changed, 14 insertions(+), 24 deletions(-) diff --git a/lib/app.dart b/lib/app.dart index 41b4c769..f60198af 100644 --- a/lib/app.dart +++ b/lib/app.dart @@ -124,7 +124,7 @@ class DashApp extends ConsumerWidget { ), themeMode: isDarkMode ? ThemeMode.dark : ThemeMode.light, home: kIsMobile - ? MobileDashboard( + ? const MobileDashboard( title: 'Requests', scaffoldBody: CollectionPane(), ) diff --git a/lib/providers/collection_providers.dart b/lib/providers/collection_providers.dart index 3dccc709..ed03e733 100644 --- a/lib/providers/collection_providers.dart +++ b/lib/providers/collection_providers.dart @@ -60,7 +60,6 @@ class CollectionStateNotifier ref.read(searchRequestsProvider.notifier).update((state) => true); if (query == '') { - loadData(); ref.read(requestSequenceProvider.notifier).state = [ ...state!.keys, ]; @@ -71,7 +70,6 @@ class CollectionStateNotifier value.url.toLowerCase().contains(query.toLowerCase()))); ref .read(requestSequenceProvider.notifier).state = [...map.keys]; - state = map; } ref.read(searchRequestsProvider.notifier).update((state) => false); diff --git a/lib/screens/home_page/collection_pane.dart b/lib/screens/home_page/collection_pane.dart index 78c22419..96e87e1f 100644 --- a/lib/screens/home_page/collection_pane.dart +++ b/lib/screens/home_page/collection_pane.dart @@ -6,12 +6,10 @@ import 'package:flutter/material.dart'; import 'package:flutter_riverpod/flutter_riverpod.dart'; class CollectionPane extends ConsumerWidget { - CollectionPane({ + const CollectionPane({ super.key, }); - final textEditController = TextEditingController(); - @override Widget build(BuildContext context, WidgetRef ref) { var sm = ScaffoldMessenger.of(context); @@ -58,7 +56,6 @@ class CollectionPane extends ConsumerWidget { onChanged: (value) => ref .read(collectionStateNotifierProvider.notifier) .filter(value.trim()), - controller: textEditController, decoration: const InputDecoration( constraints: BoxConstraints( maxHeight: 35, @@ -82,20 +79,6 @@ class CollectionPane extends ConsumerWidget { ), ), ), - kHSpacer5, - if (textEditController.text != '') - GestureDetector( - onTap: () { - textEditController.text = ''; - ref - .read(collectionStateNotifierProvider.notifier) - .filter(''); - }, - child: const Icon( - Icons.close, - size: 18, - ), - ), ], ), ), @@ -179,6 +162,15 @@ class _RequestListState extends ConsumerState { final alwaysShowCollectionPaneScrollbar = ref.watch(settingsProvider .select((value) => value.alwaysShowCollectionPaneScrollbar)); + if (requestItems.isNotEmpty && requestSequence.isEmpty) { + return Center( + child: Text( + 'Request not found!', + style: Theme.of(context).textTheme.titleMedium, + ), + ); + } + return Scrollbar( controller: controller, thumbVisibility: alwaysShowCollectionPaneScrollbar ? true : null, diff --git a/lib/screens/home_page/home_page.dart b/lib/screens/home_page/home_page.dart index 84efbf7d..a7338a08 100644 --- a/lib/screens/home_page/home_page.dart +++ b/lib/screens/home_page/home_page.dart @@ -8,12 +8,12 @@ class HomePage extends StatelessWidget { @override Widget build(BuildContext context) { - return Column( + return const Column( children: [ Expanded( child: DashboardSplitView( sidebarWidget: CollectionPane(), - mainWidget: const RequestEditorPane(), + mainWidget: RequestEditorPane(), ), ), ], diff --git a/lib/screens/mobile/dashboard.dart b/lib/screens/mobile/dashboard.dart index ef4320f3..b6f25041 100644 --- a/lib/screens/mobile/dashboard.dart +++ b/lib/screens/mobile/dashboard.dart @@ -49,7 +49,7 @@ class _MobileDashboardState extends ConsumerState { onTap: () { Navigator.of(context).pushAndRemoveUntil( MaterialPageRoute( - builder: (context) => MobileDashboard( + builder: (context) => const MobileDashboard( title: 'Requests', scaffoldBody: CollectionPane(), ), From c0072e617dcfc47ebae3a74f447624d8a9a30d61 Mon Sep 17 00:00:00 2001 From: Yashas H Majmudar Date: Wed, 20 Mar 2024 00:47:53 +0530 Subject: [PATCH 6/7] fix: codegen language dropdown renderflex bugfix --- lib/widgets/dropdowns.dart | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/widgets/dropdowns.dart b/lib/widgets/dropdowns.dart index 69008a6b..e881b9c8 100644 --- a/lib/widgets/dropdowns.dart +++ b/lib/widgets/dropdowns.dart @@ -158,6 +158,7 @@ class DropdownButtonCodegenLanguage extends StatelessWidget { final surfaceColor = Theme.of(context).colorScheme.surface; return DropdownButton( focusColor: surfaceColor, + isExpanded: true, value: codegenLanguage, icon: const Icon( Icons.unfold_more_rounded, From b0c2373095476262daba1d4d0815c8ed64f9b586 Mon Sep 17 00:00:00 2001 From: Yashas H Majmudar Date: Wed, 20 Mar 2024 09:15:20 +0530 Subject: [PATCH 7/7] fix: unsaved request order changing when clearing search, fixed with a temp sequence variable --- lib/providers/collection_providers.dart | 13 +++++++------ lib/providers/ui_providers.dart | 1 - 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/providers/collection_providers.dart b/lib/providers/collection_providers.dart index ed03e733..a9ce95e1 100644 --- a/lib/providers/collection_providers.dart +++ b/lib/providers/collection_providers.dart @@ -56,13 +56,16 @@ class CollectionStateNotifier return state?[id]; } + List tempSequence = []; + void filter(String query) { - ref.read(searchRequestsProvider.notifier).update((state) => true); + if(tempSequence.isEmpty){ + tempSequence = ref.read(requestSequenceProvider); + } if (query == '') { - ref.read(requestSequenceProvider.notifier).state = [ - ...state!.keys, - ]; + ref.read(requestSequenceProvider.notifier).state = [...tempSequence]; + tempSequence.clear(); } else { final map = {...state!}; map.removeWhere((key, value) => @@ -71,8 +74,6 @@ class CollectionStateNotifier ref .read(requestSequenceProvider.notifier).state = [...map.keys]; } - - ref.read(searchRequestsProvider.notifier).update((state) => false); } void add() { diff --git a/lib/providers/ui_providers.dart b/lib/providers/ui_providers.dart index b0ccbd4c..8401435b 100644 --- a/lib/providers/ui_providers.dart +++ b/lib/providers/ui_providers.dart @@ -6,7 +6,6 @@ final selectedIdEditStateProvider = StateProvider((ref) => null); final codePaneVisibleStateProvider = StateProvider((ref) => false); final saveDataStateProvider = StateProvider((ref) => false); final clearDataStateProvider = StateProvider((ref) => false); -final searchRequestsProvider = StateProvider((ref) => false); // final nameTextFieldControllerProvider = // StateProvider.autoDispose((ref) {