Closed
Bug 155502
Opened 23 years ago
Closed 22 years ago
Bugzilla search / query should focus summary field
Categories
(Bugzilla :: Query/Bug List, enhancement)
Tracking
()
RESOLVED
FIXED
Bugzilla 2.18
People
(Reporter: tpowellmoz, Assigned: kiko)
Details
Attachments
(1 file, 2 obsolete files)
|
1.88 KB,
patch
|
gerv
:
review+
|
Details | Diff | Splinter Review |
When you go to the search form, no field has focus. The summary field should
have focus by default, so you can immediately start typing, just like on the
index page with quicksearch and most search engines.
This is easily accomplished with a line of javascript:
<script language="JavaScript">
<!--
document.forms['queryform'].short_desc.focus()
// -->
</script>
One place to add this is on line 30 of
bugzilla/template/en/default/search/search.html.tmpl
Change:
onload = "selectProduct(document.forms['queryform']);"
to
onload = "selectProduct(document.forms['queryform']);
document.forms['queryform'].short_desc.focus()"
Although this is a minor change, it will save time for all users.
Updated•23 years ago
|
Target Milestone: --- → Bugzilla 2.18
Updated•22 years ago
|
Assignee: endico → nobody
Comment 1•22 years ago
|
||
These bugs appear to be abandoned. Retargeting to 2.20
Target Milestone: Bugzilla 2.18 → Bugzilla 2.20
| Assignee | ||
Comment 2•22 years ago
|
||
Trivial. Patch coming up.
Assignee: nobody → kiko
Target Milestone: Bugzilla 2.20 → Bugzilla 2.18
| Assignee | ||
Comment 3•22 years ago
|
||
Tested and works. Shouldn't be any cross-browser issues -- it's the same DOM
access we use for the form selection JS.
| Assignee | ||
Updated•22 years ago
|
Attachment #144226 -
Flags: review?(myk)
Comment 4•22 years ago
|
||
This is not necessarily a good thing, for the following reason: if a page takes
a couple of seconds to load (as our query page does, being very big), and you've
already clicked somewhere and started typing, the focus gets stolen from you,
which is really irritating. Can we detect whether that has happened before
calling focus()?
(For something like www.google.com, which is tiny, it's fine.)
Gerv
Comment 5•22 years ago
|
||
Comment on attachment 144226 [details] [diff] [review]
kiko_v1: add focus() call to onLoad handler.
Gerv has a point; this is even painful on Google sometimes. Can we do this
right after displaying the summary field rather than after the page has been
loaded?
Attachment #144226 -
Flags: review?(myk)
Comment 6•22 years ago
|
||
With the advent of the new fulltext search, I'm usually using that when I need
to do a "quick" query on something easy. When I go to the Advanced Query page,
I typically want to do something advanced, and most of the time it's somewhere
below the top screen of the page. First thing I generally do when the query
page loads is hit the space bar to page down. That gets broken if the summary
field focuses.
That said, I'd be all for focusing the "enter some words" field on the fulltext
search page, since the entire page (mostly) fits in the browser window, and the
fulltext search will be the default search page when 2.18 ships.
| Assignee | ||
Comment 7•22 years ago
|
||
So what do I do now?
Updated•22 years ago
|
Severity: minor → enhancement
| Assignee | ||
Comment 8•22 years ago
|
||
Another alternative is using inline script to focus the search form, which would
be invoked early (and not late as onLoad is). It could even be placed right
after rendering the search box (which is parsed early) to ensure nothing else
could have been focused (unless in the reload case).
How does that sound?
Comment 9•22 years ago
|
||
Inline script sounds like a good idea.
Gerv
| Assignee | ||
Comment 10•22 years ago
|
||
Glad you liked it.
Attachment #144226 -
Attachment is obsolete: true
| Assignee | ||
Comment 11•22 years ago
|
||
This is less broken, and does it for both pages.
Attachment #146128 -
Attachment is obsolete: true
| Assignee | ||
Comment 12•22 years ago
|
||
Comment on attachment 146132 [details] [diff] [review]
kiko_v3: less braindead version for both specific and "regular" query
Low-risk and a nice usability touch.
Attachment #146132 -
Flags: review?(gerv)
Comment 13•22 years ago
|
||
Comment on attachment 146132 [details] [diff] [review]
kiko_v3: less braindead version for both specific and "regular" query
r=gerv.
Gerv
Attachment #146132 -
Flags: review?(gerv) → review+
Updated•22 years ago
|
Flags: approval?
Comment 14•22 years ago
|
||
I still have my reservations on doing this on the advanced query page, but I
suppose we can back it out later if we get a lot of complaints.
Flags: approval? → approval+
Comment 15•22 years ago
|
||
checked in for kiko, since he's off wandering Europe somewhere. :)
Checking in template/en/default/search/form.html.tmpl;
/cvsroot/mozilla/webtools/bugzilla/template/en/default/search/form.html.tmpl,v
<-- form.html.tmpl
new revision: 1.23; previous revision: 1.22
done
Checking in template/en/default/search/search-specific.html.tmpl;
/cvsroot/mozilla/webtools/bugzilla/template/en/default/search/search-specific.html.tmpl,v
<-- search-specific.html.tmpl
new revision: 1.6; previous revision: 1.5
done
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
Updated•13 years ago
|
QA Contact: matty_is_a_geek → default-qa
You need to log in
before you can comment on or make changes to this bug.
Description
•