[Wallpaper Picker] Cleaned UI artefacts in Surprise Me Mode.

In Surprise Me mode, changes are: 
- Top categories don't highlight anymore on Hover
- Online Wallpaper Attributes (author + url + thumbnail) are not displayed
- Selected Item Checkmark is not displayed
- "Add New" button is not highlighted on Hover and don't prompt user anymore.
- White Outline on thumbnails is not displayed.

Screenshot: http://i.imgur.com/UPhSQZS.jpg

Review URL: https://codereview.chromium.org/183853030

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@255379 0039d316-1c4b-4281-b951-d872f2087c98
parent d7debf82
...@@ -66,7 +66,7 @@ body { ...@@ -66,7 +66,7 @@ body {
height: 50px; height: 50px;
} }
#categories-list > li:hover { #categories-list:not([disabled]) > li:hover {
border-top-color: rgba(255, 255, 255, 0.4); border-top-color: rgba(255, 255, 255, 0.4);
cursor: pointer; cursor: pointer;
} }
...@@ -159,7 +159,7 @@ body { ...@@ -159,7 +159,7 @@ body {
width: 108px; width: 108px;
} }
.image-picker [role=listitem]:hover { .image-picker:not([disabled]) [role=listitem]:hover {
outline: 3px solid #f1f1f1; outline: 3px solid #f1f1f1;
z-index: 1; z-index: 1;
} }
...@@ -196,6 +196,11 @@ body { ...@@ -196,6 +196,11 @@ body {
width: 108px; width: 108px;
} }
.image-picker[disabled]~.bottom-bar #online-wallpaper-attribute,
.image-picker[disabled] .check {
visibility: hidden;
}
.image-picker[disabled], .image-picker[disabled],
.image-picker-offline img:not([offline]) { .image-picker-offline img:not([offline]) {
-webkit-filter: grayscale(1); -webkit-filter: grayscale(1);
...@@ -302,7 +307,7 @@ body:not([custom]) [visibleif~='custom'] { ...@@ -302,7 +307,7 @@ body:not([custom]) [visibleif~='custom'] {
content: url('../images/ui/add-wallpaper-thumbnail.png'); content: url('../images/ui/add-wallpaper-thumbnail.png');
} }
#add-new:hover img { .image-picker:not([disabled]) #add-new:hover img {
content: url('../images/ui/add-wallpaper-thumbnail-hover.png'); content: url('../images/ui/add-wallpaper-thumbnail-hover.png');
} }
......
...@@ -45,7 +45,9 @@ cr.define('wallpapers', function() { ...@@ -45,7 +45,9 @@ cr.define('wallpapers', function() {
case Constants.WallpaperSourceEnum.AddNew: case Constants.WallpaperSourceEnum.AddNew:
this.id = 'add-new'; this.id = 'add-new';
this.addEventListener('click', function(e) { this.addEventListener('click', function(e) {
$('wallpaper-selection-container').hidden = false; var checkbox = $('surprise-me').querySelector('#checkbox');
if (!checkbox.classList.contains('checked'))
$('wallpaper-selection-container').hidden = false;
}); });
break; break;
case Constants.WallpaperSourceEnum.Custom: case Constants.WallpaperSourceEnum.Custom:
......
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