Skip to content

Conversation

@kylerm42
Copy link

@kylerm42 kylerm42 commented May 28, 2025

Summary

• Enhanced search widget with configurable shortcuts for quick site navigation and fuzzy matching
• Added search suggestions integration with popular search engines (Google, DuckDuckGo, Bing, Startpage)
• Navigate directly to URLs, bypassing search engine

Features Added

Shortcuts System:

  • Fuzzy matching against shortcut titles and optional alias text
  • Dropdown interface with keyboard navigation (arrow keys, tab, enter)
  • Exact match prioritization for immediate navigation (e.g. type gm, then Enter to go directly to Gmail)
  shortcuts:
    - title: Gmail
      url: https://mail.google.com
      alias: gm
    - title: GitHub
      url: https://github.com

Search Suggestions:

  • Suggestions from configured search engines with debouncing
  • Automatic fallback to main search engine if not specified
  • Support for custom suggestion endpoints
  • New /api/search/suggestions endpoint to handle requests
  suggestions: true
  suggestion-engine: duckduckgo  # or google, bing, startpage

Direct URL Navigation:

  • Detects when the query is a URL and takes the user there instead of searching for it
  • Supports standard URLs (google.com, www.google.com), HTTP(S) prefixes (https://google.com), localhost (localhost:3000) and IP addresses (192.168.1.1), all with optional ports

Keyboard Navigation:

  • ↓/Tab and ↑/Shift+Tab for dropdown navigation
  • Enter to select highlighted item or perform search
  • Click support for all dropdown items
  • Maintains existing bang functionality and keyboard shortcuts
image

This is similar to #702, but with some extra features. Also relates to issue #700

@kylerm42 kylerm42 marked this pull request as ready for review May 28, 2025 14:07
@rhijjawi
Copy link
Contributor

Good work @kylerm42, that's what I was trying to go for! Nice to see that we had the same idea :))
I would've been happy with a PR on the feature set too, so that you didn't have to start from 0 on the features.

@kylerm42
Copy link
Author

kylerm42 commented May 28, 2025

Thanks @rhijjawi! I was actually going to work off yours but I'm new to Go, so at this point writing is easier than reading and understanding. Definitely open to bringing in anything from that PR over here though, or vice versa!

@russssl
Copy link

russssl commented Jun 11, 2025

Amazing feature

@hydr0nium
Copy link

Great feature

@beatrizq
Copy link

beatrizq commented Sep 4, 2025

has this been implemented?

@hydr0nium
Copy link

has this been implemented?

@beatrizq The pull request is still open and not merged so I don't think so

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants