Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 /* Copyright (c) 2012 The Chromium Authors. All rights reserved. | |
|
Dan Beam
2012/02/09 01:43:06
Why did you duplicate this style?
GeorgeY
2012/02/10 00:00:36
Modified copy of the Most Visited - see above.
| |
| 2 * Use of this source code is governed by a BSD-style license that can be | |
| 3 * found in the LICENSE file. | |
|
Dan Beam
2012/02/09 01:43:06
nit:
* found in the LICENSE file. */
GeorgeY
2012/02/10 00:00:36
Done.
| |
| 4 */ | |
| 5 | |
| 6 .suggested { | |
| 7 position: absolute; | |
| 8 z-index: 0; | |
| 9 } | |
| 10 | |
| 11 .suggested { | |
| 12 display: -webkit-box; | |
| 13 position: absolute; | |
| 14 text-decoration: none; | |
| 15 -webkit-box-orient: vertical; | |
|
Dan Beam
2012/02/09 01:43:06
-webkit rules should go at the top, alpha sorted,
GeorgeY
2012/02/10 00:00:36
Done.
| |
| 16 } | |
| 17 | |
| 18 .suggested:focus { | |
| 19 outline: none; | |
| 20 } | |
| 21 | |
| 22 .fills-parent { | |
| 23 bottom: 0; | |
| 24 display: -webkit-box; | |
| 25 left: 0; | |
| 26 position: absolute; | |
| 27 right: 0; | |
| 28 top: 0; | |
| 29 } | |
| 30 | |
| 31 /* filler mode: hide everything except the thumbnail --- leave a grey rectangle | |
| 32 * in its place. */ | |
| 33 .filler * { | |
| 34 visibility: hidden; | |
| 35 } | |
| 36 | |
| 37 .filler { | |
| 38 pointer-events: none; | |
| 39 } | |
| 40 | |
| 41 .suggested .close-button { | |
| 42 opacity: 0; | |
| 43 position: absolute; | |
| 44 right: 0; | |
| 45 top: 0; | |
| 46 z-index: 5; | |
| 47 -webkit-transition: opacity 150ms; | |
| 48 } | |
| 49 | |
| 50 html[dir=rtl] .suggested .close-button { | |
| 51 left: 0; | |
| 52 right: auto; | |
| 53 } | |
| 54 | |
| 55 .suggested:hover .close-button { | |
| 56 opacity: 1; | |
| 57 -webkit-transition-delay: 500ms; | |
| 58 } | |
| 59 | |
| 60 .suggested .close-button:hover { | |
| 61 -webkit-transition: none; | |
| 62 } | |
| 63 | |
| 64 .suggested .favicon { | |
| 65 -webkit-margin-start: 5px; | |
| 66 background: no-repeat left 50%; | |
| 67 bottom: 7px; | |
| 68 box-sizing: border-box; | |
| 69 display: block; | |
| 70 height: 16px; | |
| 71 position: absolute; | |
| 72 width: 16px; | |
| 73 } | |
| 74 | |
| 75 html[dir='rtl'] .suggested .favicon { | |
| 76 background-position-x: right; | |
| 77 } | |
| 78 | |
| 79 .suggested .color-stripe { | |
| 80 border-bottom-left-radius: 3px 3px; | |
| 81 border-bottom-right-radius: 3px 3px; | |
| 82 /* Matches height of title. */ | |
| 83 bottom: 23px; | |
| 84 height: 3px; | |
| 85 /* Matches padding-top of the title. */ | |
| 86 margin-bottom: 8px; | |
| 87 position: absolute; | |
| 88 width: 100%; | |
| 89 z-index: 10; | |
| 90 } | |
| 91 | |
| 92 .suggested .title { | |
| 93 display: block; | |
| 94 height: 23px; | |
| 95 overflow: hidden; | |
| 96 padding-top: 8px; | |
| 97 text-align: center; | |
| 98 text-overflow: ellipsis; | |
| 99 white-space: nowrap; | |
| 100 } | |
| 101 | |
| 102 .thumbnail { | |
| 103 background: no-repeat; | |
| 104 /* This shows for missing thumbnails. */ | |
| 105 background-color: #eee; | |
| 106 background-size: 100%; | |
| 107 border-radius: 3px; | |
| 108 /* These max dimensions are not necessary, as the sizing logic in the .js | |
| 109 * should be sufficient, but they're here for extra insurance. We never want | |
| 110 * to scale a thumbnail larger than this size. */ | |
| 111 max-height: 132px; | |
| 112 max-width: 212px; | |
| 113 -webkit-transition: opacity 150ms; | |
| 114 } | |
| 115 | |
| 116 .filler .thumbnail { | |
| 117 /* TODO(estade): there seems to be a webkit bug where this border is not | |
| 118 * always removed when it should be. Investigate. */ | |
| 119 border: 1px solid; | |
| 120 visibility: visible; | |
| 121 } | |
| 122 | |
| 123 .thumbnail-shield { | |
| 124 border-radius: 3px; | |
| 125 background: -webkit-linear-gradient(rgba(255, 255, 255, 0), | |
| 126 rgba(255, 255, 255, 0) 50%, | |
| 127 rgba(255, 255, 255, 0.9)); | |
| 128 } | |
| 129 | |
| 130 /* TODO(dbeam): Remove this when printing of -webkit-linear-gradient() works. */ | |
| 131 @media print { | |
| 132 .thumbnail-shield { | |
| 133 background: none; | |
| 134 } | |
| 135 } | |
| 136 | |
| 137 .suggested:focus .thumbnail, | |
| 138 .suggested:hover .thumbnail { | |
| 139 opacity: 0.95; | |
| 140 } | |
| 141 | |
| 142 .suggested:focus .thumbnail-shield, | |
| 143 .suggested:hover .thumbnail-shield, | |
| 144 .suggested:active .thumbnail-shield { | |
| 145 background: -webkit-linear-gradient(rgba(255, 255, 255, 0), | |
| 146 rgba(255, 255, 255, 0) 80%, | |
| 147 rgba(255, 255, 255, 0.9)); | |
| 148 } | |
| 149 | |
| 150 /* The thumbnail gets lighter when clicked, but not when the click is on the | |
| 151 * close button. */ | |
| 152 .suggested:active .close-button:not(:active) + .thumbnail { | |
| 153 opacity: 0.9; | |
| 154 } | |
| 155 | |
| 156 /* The thumbnail gets a shadow when clicked, but not when the click is on the | |
| 157 * close button. */ | |
| 158 .suggested:active .close-button:not(:active) + .thumbnail .thumbnail-shield { | |
| 159 -webkit-box-shadow: inset 0 1px 10px rgba(0, 0, 0, 0.2); | |
| 160 } | |
| 161 | |
| 162 .thumbnail-wrapper { | |
| 163 border: 1px solid transparent; | |
| 164 border-radius: 3px; | |
| 165 display: block; | |
| 166 position: relative; | |
| 167 z-index: 5; | |
| 168 -webkit-box-flex: 1; | |
| 169 -webkit-transition: background-color 150ms; | |
| 170 } | |
| 171 | |
| 172 .filler .thumbnail-wrapper { | |
| 173 visibility: visible; | |
| 174 } | |
| 175 | |
| 176 /* 'finishing-drag' is the state we are in after dropping on the trash can. | |
| 177 * Override opacity of the tile to 1, so that the new tile animation | |
| 178 * occurs simultaneously with the trash animation. */ | |
| 179 .tile.dragging.finishing-drag { | |
| 180 opacity: 1; | |
| 181 } | |
| 182 | |
| 183 /* Don't display the new tile until there's something to show. */ | |
| 184 .blacklisted { | |
| 185 opacity: 0; | |
| 186 } | |
| OLD | NEW |