diff --git a/config-default.toml b/config-default.toml index 0a75fb6..ded0b7e 100644 --- a/config-default.toml +++ b/config-default.toml @@ -8,6 +8,9 @@ api = false # show_version_info = true # stylesheet_url = "/themes/catppuccin-mocha.css" +[image_search] +# enabled = true + [engines] # numbat = false # fend = true diff --git a/src/web/search.rs b/src/web/search.rs index 059e04b..d18377f 100644 --- a/src/web/search.rs +++ b/src/web/search.rs @@ -27,6 +27,9 @@ fn render_beginning_of_html(search: &SearchQuery) -> String { let form_html = html! { form."search-form" action="/search" method="get" { input #"search-input" type="text" name="q" placeholder="Search" value=(search.query) autofocus onfocus="this.select()" autocomplete="off"; + @if search.tab != SearchTab::default() { + input type="hidden" name="tab" value=(search.tab.to_string()); + } input type="submit" value="Search"; } @if search.config.image_search.enabled {