aggregated search

This commit is contained in:
2024-12-09 17:56:44 +08:00
parent cab66619df
commit cf7be85f29
9 changed files with 320 additions and 22 deletions

View File

@@ -14,14 +14,14 @@ class SearchResultPage extends StatefulWidget {
super.key,
required this.text,
required this.sourceKey,
required this.options,
this.options,
});
final String text;
final String sourceKey;
final List<String> options;
final List<String>? options;
@override
State<SearchResultPage> createState() => _SearchResultPageState();
@@ -99,7 +99,7 @@ class _SearchResultPageState extends State<SearchResultPage> {
onSearch: search,
);
sourceKey = widget.sourceKey;
options = widget.options;
options = widget.options ?? const [];
validateOptions();
text = widget.text;
appdata.addSearchHistory(text);