Commit c5839759 authored by Jarryd's avatar Jarryd Committed by Commit Bot

AllSites: Show overflow menu for all site entries.

The current All Sites page forces users to go into site
details to clear data for any site with only 1 origin
listed in the siteGroup. This change saves the user from
having to do so, and lets them clear data and reset
permissions directly from the all sites page.

Bug: 997258
Change-Id: I186439d73330f8489149f849e68dfc98db2b26c5
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1884579
Commit-Queue: Jarryd Goodman <jarrydg@chromium.org>
Reviewed-by: default avatarDemetrios Papadopoulos <dpapad@chromium.org>
Cr-Commit-Position: refs/heads/master@{#720744}
parent b581b3e1
......@@ -79,7 +79,7 @@
aria-describedby="displayName"
focus-row-control focus-type="show-detail"></cr-icon-button>
</div>
<div class="row-aligned" hidden$="[[!grouped_(siteGroup)]]">
<div class="row-aligned" hidden$="[[shouldHideOverflow_(siteGroup)]]">
<div class="separator"></div>
<cr-icon-button class="icon-more-vert" id="overflowMenuButton"
title="$i18n{moreActions}" on-click="showOverflowMenu_"
......
......@@ -78,7 +78,7 @@ Polymer({
* The selected sort method.
* @type {!settings.SortMethod|undefined}
*/
sortMethod: {type: String, observer: 'updateOrigins_'}
sortMethod: {type: String, observer: 'updateOrigins_'},
},
/** @private {?settings.LocalDataBrowserProxy} */
......@@ -125,6 +125,17 @@ Polymer({
return false;
},
/**
* Whether or not to display the overflow menu for a site group.
* @param {SiteGroup} siteGroup The eTLD+1 group of origins.
* @return {boolean}
* @private
*/
shouldHideOverflow_: function(siteGroup) {
return !this.grouped_(siteGroup) &&
!loadTimeData.getBoolean('enableStoragePressureUI');
},
/**
* Returns a user-friendly name for the siteGroup.
* If grouped_() is true and eTLD+1 is available, returns the eTLD+1,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment