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