Skip to content
This repository has been archived by the owner on Jan 17, 2023. It is now read-only.

Searches should be performed on change, not on submit #1458

Closed
johngruen opened this issue Sep 6, 2016 · 3 comments
Closed

Searches should be performed on change, not on submit #1458

johngruen opened this issue Sep 6, 2016 · 3 comments
Assignees
Milestone

Comments

@johngruen
Copy link
Contributor

On the shot index page, i start typing a search, i expect results to return immediately not when i hit enter. Also when i delete my query i expect the UI to reset to show all searches.

@johngruen johngruen added this to the First Launch milestone Sep 6, 2016
@fzzzy
Copy link
Contributor

fzzzy commented Sep 6, 2016

We switched it from searching on every keystroke for performance and stability reasons. Also, the way we implement search right now in postgres, only whole words match, not partial words, and so there won't be any results until you type a whole word anyway.

I do think we should do this, but it's not as trivial as just changing the ui.

@johngruen johngruen modified the milestones: First Launch, Stretch Sep 6, 2016
@ianb ianb changed the title Searches should be perforemed on change, not on submit Searches should be performed on change, not on submit Oct 13, 2016
@ianb ianb self-assigned this Oct 13, 2016
@ianb
Copy link
Contributor

ianb commented Oct 17, 2016

I'm going to implement this with a 2 second delay (i.e., you have to not type anything for 2 seconds before a search is sent), and a minimum of 4 characters (i.e., if you type "tes" it won't search, but "test" will search). The normal enter/submit will also still work, with no delay.

@ianb
Copy link
Contributor

ianb commented Oct 18, 2016

I went with 1 second, 2 seconds seemed too long.

I also implemented @TLHuang's idea of dimming the shot cards when the search results below don't match what's in the search box above. So as you first start typing everything dims, and if you pause and search catches up then it becomes fully opaque again.

@fzzzy fzzzy closed this as completed in 12a98ed Oct 18, 2016
fzzzy added a commit that referenced this issue Oct 18, 2016
r?fzzzy Fix #1458, trigger a search when someone changes the search form
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants