Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use of OpenSearch Standard in LaunchMenu #158

Open
sancarn opened this issue Jul 22, 2021 · 0 comments
Open

Use of OpenSearch Standard in LaunchMenu #158

sancarn opened this issue Jul 22, 2021 · 0 comments
Labels
applet related to an applet enhancement New feature or request

Comments

@sancarn
Copy link
Contributor

sancarn commented Jul 22, 2021

Is your feature applicable to LaunchMenu as a whole, or specific to an applet? Please describe
Applet

Is your feature request related to a problem? Please describe.
No

Describe the solution you'd like

There is a standard for defining search engines. It started in 1997 as a sherlock plugin but has gone by many names: mycroft plugins, search engines, search plugins, and more recently "opensearch". All browsers can read this format and let the user choose it to search the web.

It'd be nice if LaunchMenu could use this format too, actively while browsing the web. The idea would be for LM to track the chrome/firefox/edge/safari location URL, and whenever a new domain is visited an additional web request is sent out to the domain by LM (or the page is scraped). We're looking for a link as follows:

<link rel="search" type="application/opensearchdescription+xml" title="Stack Overflow" href="/opensearch.xml">

This link defines a href, in this case to http://stackoverflow.com/opensearch.xml. From this url we can query the following document:

<?xml version="1.0" encoding="UTF-8" ?>
<OpenSearchDescription xmlns="http://a9.com/-/spec/opensearch/1.1/" xmlns:moz="http://www.mozilla.org/2006/browser/search/">
  <ShortName>Stack Overflow</ShortName>
  <Description>Search Stack Overflow: Q&A for professional and enthusiast programmers</Description>
  <InputEncoding>UTF-8</InputEncoding>
  <Image width="16" height="16" type="image/x-icon">//sstatic.net/stackoverflow/img/favicon.ico</Image>
  <Url type="text/html" method="get" template="http://stackoverflow.com/search?q={searchTerms}"></Url>
</OpenSearchDescription>

Which identifies a searchable web address (template). When LM is opened it could then be used to search the active site. It might be worth while changing the tray icon to indicate that the website is searchable. Additionally it'd be worth cacheing this url in the web search applet, as this url may come in use in the future.

@sancarn sancarn added enhancement New feature or request applet related to an applet labels Jul 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
applet related to an applet enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant