-
Notifications
You must be signed in to change notification settings - Fork 973
Search Settings Panel: Search Suggestions (Part 1) #2726
Conversation
wow this is looking really awesome so far. The functionality is a major improvement over our current search experience. Here's a few things I noticed from testing:
|
@@ -134,7 +134,7 @@ AppStore | |||
'general.downloads.default-save-path': string, // default path for saving files | |||
'general.autohide-menu': boolean, // true if the Windows menu should be autohidden | |||
'general.disable-title-mode': boolean, // true if title mode should always be disabled | |||
'search.default-search-engine': string, // path to the open search XML | |||
'search.default-search-engine': string, // name of search engine, from js/data/searchProviders.js |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will need to be set inside app.sessionStore based on the user's old selected xml engine. And only done once, after that it should jus preserve the setting. Also some users won't have an old xml setting if it is their first time install.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is the same setting name as before so just check for special case values of content/search/google.xml and content/search/duckduckgo.xml when loading the session state and migrate accordingly.
ok made a few minor comments but this is close to being able to be merged, this might still make 0.11.2. |
Pls also add some tests for the shortcut prefix text for this as well. |
thanks! |
Ok, working on it |
There's a couple things off about the urlbar icon image. It seems like not enough padding on the right and also some of the favicons just look bad. cc @bradleyrichter please take a look locally before you work more on that aspect @darkdh |
} | ||
if (data.settings['search.default-search-engine'] === 'contnt/search/duckduckgo.xml') { | ||
data.settings['search.default-search-engine'] = 'DuckDuckGo' | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
great!
ok. I'll run the PR and reply with suggestions if needed. So far from the clip above, it looks great! |
const searchRE = new RegExp('^' + entry.shortcut + ' .*', 'g') | ||
if (searchRE.test(location)) { | ||
const iconSize = 16 | ||
this.searchFaviconStyle = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Style should really only be calculated inside render, here you'd set state which indicated the active engine, something like frame.x.navbar.urlbar.activeSearchEngine
. I think we should also show the favicon as soon as you put searchTerm + ' ' and you don't need an extra char after that. I think it will be fixed by what I'm suggesting here.
You might want to wait for Brad to weigh in first to make sure we still want to have the favicon in the urlbar because I mentioned some of the favicons are looking bad as is, like yahoo and duck duck go seems pixelated.
It's a super great feature, can't wait to get it in. My concerns are with some favicon replacement in the urlbar after the shortcut is entered, in particular I noticed duckduckgo looks small and pixelated and yahoo icon looks huge and ugly. Text doesn't seem to be fully aligned and missing padding as small tweaks that would help. Maybe we need a smaller than 16x16 image here. |
I noticed that not just urlbar but in search engine table got the same issue. Maybe we should replace the icon image source |
It would be nice if svg images can be used here |
@darkdh Can you check if the same favicon path is being used in both cases?
|
@darkdh I restyled the panel a bit but I won't commit until your are done with the other things. Please remove the title under "Search Settings" in your code though... |
Are favicons cached here? |
Thanks for all your valuable feedback. |
cc @diracdeltas for advise. |
feel free to change the |
Thanks @diracdeltas. It works fine now. |
@darkdh Can you please use this fontawesome icon in place of the "X" to indicate the default choice? http://fontawesome.io/icon/check-square/ 16x16px Color it as @braveorange or #FF5000. |
@bradleyrichter Ok, I will replace it with fontawesome in next commit. |
@bradleyrichter , please take a look at screenshot of b9567d6 |
looks great! thanks... |
6fa97b1
to
688fa23
Compare
thanks for all your hard work on this! |
git rebase -i
to squash commits if needed.fix #2694