New issue
Advanced search Search tips

Issue 641663 link

Starred by 2 users

Issue metadata

Status: Verified
Owner:
Closed: Nov 2016
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Linux , Windows , Chrome , Mac
Pri: 2
Type: Bug

Blocked on:
issue 660434

Blocking:
issue 657150



Sign in to add a comment

md-settings no longer provides search URLs

Reported by vanantwe...@gmail.com, Aug 27 2016

Issue description

UserAgent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2832.2 Safari/537.36

Steps to reproduce the problem:
1. Activate md-settings
2. Try searching something in the settings
3. Share the result via URL

What is the expected behavior?

What went wrong?
md-settings no longer provides chrome://settings/search#hardware urls

Did this work before? Yes Before md-settings

Chrome version: 54.0.2832.2  Channel: dev
OS Version: 
Flash Version: Shockwave Flash 23.0 r0
 
Components: UI>Settings
Labels: M-55 Proj-MaterialDesign-WebUI
Status: Untriaged (was: Unconfirmed)
Issue seems like a feature request, marking it as untriaged to get more inputs from dev team.

Thnaks,

Comment 2 by dbeam@chromium.org, Sep 6 2016

Cc: tommycli@chromium.org dpa...@chromium.org
Labels: OS-Chrome OS-Mac OS-Windows
Status: Available (was: Untriaged)
I just don't think search URLs are implemented yet
And as far as I remember dpapad@ saying: there was no plan to implement this.

Comment 4 by dpa...@chromium.org, Sep 22 2016

Labels: Hotlist-MD-Settings-SearchBox

Comment 5 by dpa...@chromium.org, Sep 22 2016

Cc: dbeam@chromium.org
@tbuckley,dbeam: The old settings provided search URLs. For example you can navigate to chrome://settings/search#privacy and you will land to a page where the search textbox is pre-populated with "privacy" and the search results are shown.

I believe that with the latest Router implementation this is possible now, and it would be nice to preserve this functionality from the old settings. Is it OK to start working on this?
Blocking: 657150
If implemented, this would be a partial fix for  issue 657150 .

Comment 7 by dpa...@chromium.org, Oct 24 2016

Status: Started (was: Available)
I have an initial implementation of search URLs, which as stated in #6 addresses many of the search+navigation issues. There are still a few glitches to fix, but see screencast for a rough idea.
search_urls_navigation.mp4
1.2 MB View Download
 Issue 657150  has been merged into this issue.

Comment 9 by dpa...@chromium.org, Oct 25 2016

Cc: -dpa...@chromium.org
Owner: dpa...@chromium.org
Attaching new screencast reflecting the latest status of search URLs at https://codereview.chromium.org/2449663002. The glitches mentioned in #7 have been fixed.

Specifically, things that work
 1) Searching via the textbox updates the URL and registers a history entry.
 2) Navigating from top-level->subpage->top-level preserves search highlights
    without triggering any new searching.
 3) Visiting a page from the sidenav clears all search results.
 4) Visiting a URL that already has a "search=" parameter triggers searching,
    and pre-populates the search box with the query string.

The above behavior makes searching and navigation compatible.

There is still an open question about whether navigation history should contain multiple
search URLs or just one. Note that current behavior matches old Options behavior, so
addressing the open question would be an improvement (and should probably be tracked by a
separate bug).

Proposal 1: Only register a new history entry, if the latest search query does not start
with the previous search query. This addresses the slow typing issue. For example
 - user types "cook" then pauses.
 - chrome://md-settings/?search=cook is registered in navigation history.
 - user continues typing "ies" forming the word "cookies".
 - chrome://md-settings/?search=cookies replaces previous history entry, such that clicking
   the "back" arrow takes the user back to chrome://md-settings.

Proposal 2: Only allow a single consecutive search URL in the history. For example
 - user types 'cookies' then pauses.
 - chrome://md-settings/?search=cookies is registered in navigation history.
 - user replaces 'cookies' with 'manage'
 - chrome://md-settings/?search=manage replaces previous history entry. Clicking "back" arrow
   takes user back to chrome://md-settings instead of chrome://md-settings/?search=cookies.
search_urls.mp4
1.5 MB View Download
I'd vote proposal #2. It's simpler - and I would imagine that anyone who clicks the Back button just wants to exit the Search mode.

At least - that would be consistent with how users interact with search boxes on the web in general.
>At least - that would be consistent with how users interact with search boxes on the web in general.

Perhaps within the context of settings you are right, clicking 'back' could be a way to exit search. For google.com though, all searches are registered in history and clicking back takes you through them before landing on google.com without any results showing.
Ahh that's interesting. I was thinking in terms of the Google Instant feature. (When you type "foo" space, it searches for "foo", and then when you add a "bar" word it then searches for "foo bar" with a coalesced history).

Though you are correct that each time the user presses Enter or the search button, a separate history entry is made. Maybe it should make a history entry when the user presses Enter?
Blockedon: 660434
Project Member

Comment 15 by bugdroid1@chromium.org, Nov 3 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/63797594bc2bb93e645129b0c679081dc925ba5f

commit 63797594bc2bb93e645129b0c679081dc925ba5f
Author: dpapad <dpapad@chromium.org>
Date: Thu Nov 03 00:04:50 2016

MD Settings: Implement search URLs.

- Modify settings-ui to sync the URL 'search' parameter and the search
  textfield text to each other, and to trigger searching when the current
  route changes to a "search" URL.
- Provide a way to programmatically change cr-search-field's value without
  triggering a 'search-changed' event (necessary for syncing URL with search
  field).

This makes searching and navigation compatible.

BUG= 641663 
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation

Review-Url: https://codereview.chromium.org/2449663002
Cr-Commit-Position: refs/heads/master@{#429465}

[modify] https://crrev.com/63797594bc2bb93e645129b0c679081dc925ba5f/chrome/browser/resources/settings/settings_main/settings_main.js
[modify] https://crrev.com/63797594bc2bb93e645129b0c679081dc925ba5f/chrome/browser/resources/settings/settings_ui/compiled_resources2.gyp
[modify] https://crrev.com/63797594bc2bb93e645129b0c679081dc925ba5f/chrome/browser/resources/settings/settings_ui/settings_ui.html
[modify] https://crrev.com/63797594bc2bb93e645129b0c679081dc925ba5f/chrome/browser/resources/settings/settings_ui/settings_ui.js
[modify] https://crrev.com/63797594bc2bb93e645129b0c679081dc925ba5f/chrome/test/data/webui/cr_elements/cr_toolbar_search_field_tests.js
[modify] https://crrev.com/63797594bc2bb93e645129b0c679081dc925ba5f/chrome/test/data/webui/settings/cr_settings_browsertest.js
[modify] https://crrev.com/63797594bc2bb93e645129b0c679081dc925ba5f/chrome/test/data/webui/settings/settings_main_test.js
[modify] https://crrev.com/63797594bc2bb93e645129b0c679081dc925ba5f/chrome/test/data/webui/settings/settings_ui_browsertest.js
[modify] https://crrev.com/63797594bc2bb93e645129b0c679081dc925ba5f/ui/webui/resources/cr_elements/cr_search_field/cr_search_field_behavior.js

Status: Fixed (was: Started)
Marking this as fixed. A corner case that still needs to be addressed is tracked by  crbug.com/661835 
Status: Verified (was: Fixed)
Verified on ChromeOS 9000.0.0, 56.0.2923.0
It works! (Version 56.0.2924.10 dev (64-bit), Ubuntu 14.04)

Tnx a lot!!!

Sign in to add a comment