Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

handle text overflow

ashilknb58f1c44f5fb
diff --git a/lib/ui/viewer/search/result/no_result_widget.dart b/lib/ui/viewer/search/result/no_result_widget.dart
index eea81a5282..6aef909124 100644
--- a/lib/ui/viewer/search/result/no_result_widget.dart
+++ b/lib/ui/viewer/search/result/no_result_widget.dart
@@ -26,12 +26,11 @@ class _NoResultWidgetState extends State<NoResultWidget> {
for (int j = 0; j < 2 && j < value[i].length; j++) {
querySuggestions.add(value[i][j].name());
}
- setState(() {
- //todo: remove keys with empty list
- searchTypeToQuerySuggestion
- .addAll({searchTypes[i].sectionTitle(context): querySuggestions});
- });
+ //todo: remove keys with empty list
+ searchTypeToQuerySuggestion
+ .addAll({searchTypes[i].sectionTitle(context): querySuggestions});
}
+ setState(() {});
});
}
@@ -49,9 +48,13 @@ class _NoResultWidgetState extends State<NoResultWidget> {
style: textTheme.bodyMuted,
),
const SizedBox(width: 6),
- Text(
- formatList(value),
- style: textTheme.miniMuted,
+ Flexible(
+ child: Text(
+ formatList(value),
+ style: textTheme.miniMuted,
+ maxLines: 1,
+ overflow: TextOverflow.ellipsis,
+ ),
),
],
),