-
-
Notifications
You must be signed in to change notification settings - Fork 7
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 "search" or "page" URL parameters, depending on the intent #45
Comments
The last paragraph above was adapted from this comment; it also continues to say:
If I read that correctly, this matches option (1), but I'm hoping @Jan-Ka will clarify if there are nuances escaping me. |
I should have added my thoughts here instead of back in the PR. Let's continue this discussion here :)
(Copy of the linked comment at the time of this comment) |
You know, you can simply delete the comment over there and edit this one as if you wrote it here in the first place :) (If you do, you can delete this one as well, as it'd lose context.) |
As a user I think showing both the search terms in the input field and the actual article found by performing the search would be less surprising. In other words, I'd be able to go back and forth through history and all three pieces (URL, search box and displayed article) would remain identical, regardless of whether I got to that page by typing in the search field, opening an URL someoneone else gave me, or going back and forth in the browser history. I think this helps ground the user as they navigate across multiple pages, and makes the application more predictable. |
Sounds reasonable. Let's do it that way. |
#21 and #34 implemented a way to control the interface of Primerpedia via a URL parameter, which is currently named "search".
Here's a use case where the current behavior may be confusing:
I'm wondering if we shouldn't set the url parameter to
search=
andpage=
, respectively, in order to be able to make the interface behave as expected in both cases, i.e. only fill the search box automatically for pages loaded via search, and show the search terms rather than the actual article title.Of course, if both parameters are present simultaneously, one must take precedence: we could either (1) fill the search terms back into the search input without triggering a search (and perform a search with the exact page title to load it), or (2) ignore the page title and execute a search with the provided terms, hoping that it results in the same page (which most of the time it probably will). For a URL like
...?search=united_states&page=canada
, the first approach would show the Canada article, while the second approach would show the United States article.The text was updated successfully, but these errors were encountered: