Made search suggestions togglable

This commit is contained in:
2025-07-05 15:19:35 +02:00
parent 66d03513eb
commit c5388fc044
5 changed files with 26 additions and 27 deletions

View File

@@ -7,8 +7,6 @@ namespace HopFrame.Web.Services.Implementation;
public sealed class SearchSuggestionProvider : ISearchSuggestionProvider {
public IEnumerable<string> GenerateSearchSuggestions(TableConfig table, string searchText) {
if (table.ContextConfig is not DbContextConfig) return [];
var searchParts = searchText.Trim().Split(' ');
if (searchParts.Length != 0 && searchParts.Last().EndsWith('=') && !searchText.EndsWith(' ')) {
var part = searchParts.Last()[..^1];