Skip to content

Conversation

@cooperka
Copy link
Member

@cooperka cooperka commented Mar 15, 2019

Integrates the existing search box into the new Filters component.

@cooperka cooperka requested a review from smoyte March 15, 2019 16:36
@smoyte smoyte force-pushed the 9402_searchbox_filter branch from 668da23 to 711b60a Compare March 20, 2019 14:50
Copy link
Contributor

@smoyte smoyte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI: I rebased this against develop with the other PR merged.

It took me awhile to figure out why the box always says query 😅. Now it makes perfect sense of course but in future with these PRs can you remind me what is stubbed vs. what real functionality you're adding so I can remember what to be testing for/scrutinizing. It would help me get back into the context. Thanks.

Overall it looks great. A couple small comments inline, plus can we get some space between these buttons please:

image

Thanks a lot!

onChange={[MockFunction]}
placeholder="Advanced search"
type="text"
value="query"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't this be foo? I'm not seeing foo anywhere in this snapshot even though that's the query param...

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OH RIGHT. I guess this snapshot will change once we integrate with the backend.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actually this value is coming from the test mock in spec/.../search/utils.js which defines advancedSearchProps. The AdvancedSearchFilter component itself gets props directly, it doesn't care what the actual url querystring is.

@smoyte
Copy link
Contributor

smoyte commented Mar 20, 2019

@cooperka Hmm, it seems there are a lot of CI failures. We will need to figure those out...

@cooperka cooperka force-pushed the 9402_searchbox_filter branch from 495b7c7 to e37f663 Compare March 20, 2019 20:40
@cooperka cooperka force-pushed the 9402_searchbox_filter branch from 8546281 to eeee4de Compare March 20, 2019 23:39
@cooperka
Copy link
Member Author

@smoyth tests should finally be passing. There were a lot of weird inconsistencies with the way Ruby talks to React, and also with the way Capybara manipulates the DOM.

I squashed the hell out of the commits, hopefully the solution is fairly readable now. Ready for review.

@smoyte smoyte merged commit a9c2bf6 into develop Mar 21, 2019
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.

4 participants