New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 652558 link

Starred by 1 user

Issue metadata

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



Sign in to add a comment

MD Settings: site data removal dialog is unlike MD / the rest of chrome / has script errors

Project Member Reported by dbeam@chromium.org, Oct 4 2016

Issue description

what do you expect?
something that looks like Material Design or the rest of chrome

what happens instead?
the current md-settings site data dialog is a unique little snowflake.

any additional info?

* the title of the dialog is "<domain> locally stored data" (which is kinda jargony)

* it should probably be entitled "<domain> cookies" if it's only cookies

* the dropdown with the cookie name is unlabelled (i.e. I just see "__utma" when i go to chrome.google.com, not Cookie name: __utma or something)

* the format for removing 1 cookie is different from when there are multiple cookies (why's this different?)

* removing anything other than Cookies (i.e. Local storage) results in console errors

[6511:6511:1003/195659:ERROR:CONSOLE(179)] "Uncaught TypeError: Cannot read property 'data_' of undefined", source: chrome://md-settings/site_settings/cookie_tree_node.js (179)
[6511:6511:1003/195659:ERROR:CONSOLE(138)] "Uncaught TypeError: Cannot read property 'id' of undefined", source: chrome://md-settings/site_settings/site_data_details_dialog.js (138)

* data about cookies is not formatted well (it's just a bit list of things without any font differentiation or new lines/space)
  * looks different than mocked (but I think we need more space between fields than the mocks provide as well)

* clicking on the trashcan on chrome://md-settings/siteSettings/cookies gives no prompts and silently deletes data (probably ought to put a prompt before deleting user data or allow undoing?)

* clicking "REMOVE ALL" from a domain-specific dialog (i.e. www.google.com locally storage data) seems roughly equivalent to Chrome for Android's "CLEAR & RESET", which has a prompt (desktop UI doesn't have a prompt, it just nukes www.google.com's data, though I just found that the old chrome://settings/cookies does the same thing)

* the UI doesn't update itself if site data is changed from another source (so i could be deleting something that was already deleted or more than I see on this page)
 

Comment 1 by dbeam@chromium.org, Oct 4 2016

it's also odd to me that this site data UI lives in the "Cookies" page.

Comment 2 by dbeam@chromium.org, Oct 4 2016

2016-10-03-195759_550x469_scrot.png
35.8 KB View Download
> * the title of the dialog is "<domain> locally stored data" (which is kinda jargony)
> * it should probably be entitled "<domain> cookies" if it's only cookies

It's a lot more than just cookies. Locally stored data is an accurate term.
 
> * the dropdown with the cookie name is unlabelled (i.e. I just see "__utma" when i go to chrome.google.com, not Cookie name: __utma or something)

Not a bad idea. Although I'd probably go with the shorter version: "Cookie: __utma"

> * the format for removing 1 cookie is different from when there are multiple cookies (why's this different?)

Are you saying you want the dialog to always show the dropdown, Remove button and Remove All button, even if there's only one entry in it?

> * removing anything other than Cookies (i.e. Local storage) results in console errors

> [6511:6511:1003/195659:ERROR:CONSOLE(179)] "Uncaught TypeError: Cannot read property 'data_' of undefined", source: chrome://md-settings/site_settings/cookie_tree_node.js (179)
> [6511:6511:1003/195659:ERROR:CONSOLE(138)] "Uncaught TypeError: Cannot read property 'id' of undefined", source: chrome://md-settings/site_settings/site_data_details_dialog.js (138)

The 'data_' error has already been taken care of. I'll investigate the 'id' error (couldn't repro until now).

> * data about cookies is not formatted well (it's just a bit list of things without any font differentiation or new lines/space)
>  * looks different than mocked (but I think we need more space between fields than the mocks provide as well)

We can probably do better there. Worth keeping in mind, though that this dialog is a little tricky since we don't know what we're going to present in it; it is dynamically generated with the contents of (in the case of the photo above) the cookie. Even the headers above each data element are generated by looking up the key we found in the cookie and consulting a string map. But, like I said, we can polish this a bit, though.

> * clicking on the trashcan on chrome://md-settings/siteSettings/cookies gives no prompts and silently deletes data (probably ought to put a prompt before deleting user data or allow undoing?)
> * clicking "REMOVE ALL" from a domain-specific dialog (i.e. www.google.com locally storage data) seems roughly equivalent to Chrome for Android's "CLEAR & RESET", which has a prompt (desktop UI doesn't have a prompt, it just nukes www.google.com's data, though I just found that the old chrome://settings/cookies does the same thing)

Yeah, I can take a look at this.

> * the UI doesn't update itself if site data is changed from another source (so i could be deleting something that was already deleted or more than I see on this page)

This is issue 626619.

Labels: Proj-MaterialDesign-WebUI
Owner: finnur@chromium.org
Status: Started (was: Available)
Weird that sumit is shown as owner in the overview panel up left, but the owner textbox below was blank. Anyway, I'm looking into this now.
Project Member

Comment 6 by bugdroid1@chromium.org, Oct 10 2016

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

commit 911a4d605e2c485c0cc9547b084a9a3bd3c2e495
Author: finnur <finnur@chromium.org>
Date: Mon Oct 10 10:52:59 2016

Site Settings Desktop: Polish the Site Data section.

- Add a 'Cookie:' prefix for the Details dialog.
- Add a confirmation dialog when deleting all cookies
  for all sites or for a single site (both on the
  Cookie page and Site Details page).
- Remove quota nodes from the Site Data list (the usage
  total specified is not accurate -- bug 642955).
  - This also takes care of the id_ error in the console.
- Make the Site Data Details dialog more like the mocks.

TBR=dbeam, bauerb
BUG= 652558 
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation

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

[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/app/settings_strings.grdp
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/resources/settings/settings_shared_css.html
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/resources/settings/site_settings/cookie_tree_node.js
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/resources/settings/site_settings/site_data.html
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/resources/settings/site_settings/site_data.js
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/resources/settings/site_settings/site_data_details_dialog.html
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/resources/settings/site_settings/site_data_details_dialog.js
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/resources/settings/site_settings/site_details.html
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/resources/settings/site_settings/site_details.js
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/ui/webui/cookies_tree_model_util.cc
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/ui/webui/cookies_tree_model_util.h
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/ui/webui/options/cookies_view_handler.cc
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/ui/webui/settings/md_settings_localized_strings_provider.cc
[modify] https://crrev.com/911a4d605e2c485c0cc9547b084a9a3bd3c2e495/chrome/browser/ui/webui/settings/settings_cookies_view_handler.cc

Comment 7 by finnur@chromium.org, Oct 10 2016

Status: Fixed (was: Started)
Marking this as fixed, since all the actionable items are done, except one that is filed as a separate issue and one unresolved question that we can also treat as a separate issue if we want to make a change.
Status: Verified (was: Fixed)

Sign in to add a comment