Commit 171bb6b4 by Rizal Hermawan

refactor : add clearFilter Function

parent c93c03d5
......@@ -77,6 +77,7 @@ class FloatingSearchBarAction extends StatelessWidget {
factory FloatingSearchBarAction.searchToClear({
double size = 24,
Color? color,
Function()? clearFilter,
bool showIfClosed = true,
Duration duration = const Duration(milliseconds: 900),
String searchButtonSemanticLabel = 'Search',
......@@ -105,6 +106,7 @@ class FloatingSearchBarAction extends StatelessWidget {
bar.isOpen =
!bar.isOpen || (!bar.hasFocus && bar.isAlwaysOpened);
}
clearFilter!();
},
searchButtonSemanticLabel: searchButtonSemanticLabel,
clearButtonSemanticLabel: clearButtonSemanticLabel,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment