Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(244)

Side by Side Diff: chrome/browser/resources/ntp/apps.css

Issue 6297013: [NTP] Allow reordering of apps via drag and drop. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 9 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /* Apps */ 1 /* Apps */
2 2
3 #apps-content { 3 #apps-content {
4 position: relative; 4 position: relative;
5 width: intrinsic;
6 max-width: 780px; /* (124 + margin * 2) * 6 */ 5 max-width: 780px; /* (124 + margin * 2) * 6 */
7 } 6 }
8 7
9 html.apps-promo-visible #apps-content { 8 html.apps-promo-visible #apps-content {
10 max-width: 650px; /* (124 + margin * 2) * 5 */ 9 max-width: 650px; /* (124 + margin * 2) * 5 */
11 } 10 }
12 11
13 /* small */ 12 /* small */
14 @media (max-width: 940px) { 13 @media (max-width: 940px) {
15 /* 14 /*
16 We don't need to do anything for html.apps-promo-visible because there is 15 We don't need to do anything for html.apps-promo-visible because there is
17 enough extra space in the small grid layout. 16 enough extra space in the small grid layout.
18 */ 17 */
19 #apps-content, 18 #apps-content,
20 html.apps-promo-visible #apps-content { 19 html.apps-promo-visible #apps-content {
21 max-width: 520px; /* (124 + margin * 2) * 4 */ 20 max-width: 520px; /* (124 + margin * 2) * 4 */
22 } 21 }
23 } 22 }
24 23
25 .app, 24 .app,
26 .app[new=installed] { 25 .app[new=installed] {
27 box-sizing: border-box; 26 box-sizing: border-box;
28 -webkit-perspective: 400; 27 -webkit-perspective: 400;
29 border-radius: 10px; 28 border-radius: 10px;
30 color: black; 29 color: black;
31 display: inline-block;
32 margin: 5px 3px; 30 margin: 5px 3px;
33 position: relative; 31 position: absolute;
34 height: 136px; 32 height: 136px;
35 width: 124px; /* 920 / 7 - margin * 2 */ 33 width: 124px; /* 920 / 7 - margin * 2 */
36 } 34 }
37 35
38 .app a { 36 .app a {
39 border-radius: 10px; 37 border-radius: 10px;
40 bottom: 0; 38 bottom: 0;
41 left: 0; 39 left: 0;
42 position: absolute; 40 position: absolute;
43 right: 0; 41 right: 0;
(...skipping 27 matching lines...) Expand all
71 width: 14px; 69 width: 14px;
72 } 70 }
73 71
74 .app > .app-settings { 72 .app > .app-settings {
75 -webkit-transition: opacity .3s; 73 -webkit-transition: opacity .3s;
76 -webkit-transition-delay: 0; 74 -webkit-transition-delay: 0;
77 background-image: url(chrome://theme/IDR_BALLOON_WRENCH); 75 background-image: url(chrome://theme/IDR_BALLOON_WRENCH);
78 opacity: 0; 76 opacity: 0;
79 } 77 }
80 78
81 .app > .app-settings:hover { 79 .app:not(.dragging) > .app-settings:hover {
Aaron Boodman 2011/01/22 23:42:57 If possible, it would be better to have the .dragg
jstritar 2011/01/24 01:00:42 Done. Definitely makes it simpler.
82 -webkit-transition: none; 80 -webkit-transition: none;
83 background-image: url(chrome://theme/IDR_BALLOON_WRENCH_H); 81 background-image: url(chrome://theme/IDR_BALLOON_WRENCH_H);
84 } 82 }
85 83
86 .app:hover > .app-settings, 84 .app:hover:not(.dragging) > .app-settings,
87 .app > .app-settings:focus { 85 .app > .app-settings:focus {
88 -webkit-transition-delay: .5s; 86 -webkit-transition-delay: .5s;
89 opacity: .9; 87 opacity: .9;
90 } 88 }
91 89
90 .app.dragging {
91 opacity: .7;
92 }
93
94 #apps-content[launcher-animations=true] .app {
95 -webkit-transition: top .20s, left .20s, right .20s;
Aaron Boodman 2011/01/22 23:42:57 It seems that the convention in the rest of the cs
jstritar 2011/01/24 01:00:42 Done.
96 }
97
92 @-webkit-keyframes bounce { 98 @-webkit-keyframes bounce {
93 0% { 99 0% {
94 -webkit-transform: scale(0, 0); 100 -webkit-transform: scale(0, 0);
95 } 101 }
96 102
97 60% { 103 60% {
98 -webkit-transform: scale(1.2, 1.2); 104 -webkit-transform: scale(1.2, 1.2);
99 } 105 }
100 106
101 100% { 107 100% {
102 -webkit-transform: scale(1, 1); 108 -webkit-transform: scale(1, 1);
103 } 109 }
104 } 110 }
105 111
106 html[install-animation-enabled=true] .app[new=new] { 112 html[install-animation-enabled=true] .app[new=new] {
107 opacity: 0; 113 opacity: 0;
108 } 114 }
109 115
110 html[install-animation-enabled=true] .app[new=installed] { 116 html[install-animation-enabled=true] .app[new=installed] {
111 -webkit-animation: bounce .5s ease-in-out; 117 -webkit-animation: bounce .5s ease-in-out;
112 -webkit-transition: opacity .5s; 118 -webkit-transition: opacity .5s;
113 } 119 }
114 120
115 .app[app-id=web-store-entry] > a { 121 .app.web-store-entry > a {
Aaron Boodman 2011/01/22 23:42:57 Why this change?
jstritar 2011/01/24 01:00:42 For the other apps, the app-id attribute is on the
116 background-image: url("chrome://theme/IDR_WEBSTORE_ICON"); 122 background-image: url("chrome://theme/IDR_WEBSTORE_ICON");
117 } 123 }
118 124
119 menu > button.default { 125 menu > button.default {
120 font-weight: bold; 126 font-weight: bold;
121 } 127 }
122 128
123 #apps-promo { 129 #apps-promo {
124 display: none; 130 display: none;
125 } 131 }
(...skipping 21 matching lines...) Expand all
147 cursor: pointer; 153 cursor: pointer;
148 font-family: inherit; 154 font-family: inherit;
149 font-size: 90%; 155 font-size: 90%;
150 text-decoration: underline; 156 text-decoration: underline;
151 } 157 }
152 158
153 html[dir=rtl] #apps-promo-hide { 159 html[dir=rtl] #apps-promo-hide {
154 float: left; 160 float: left;
155 } 161 }
156 162
157 html.apps-promo-visible .app[app-id=web-store-entry] { 163 html.apps-promo-visible .app.web-store-entry {
158 position: absolute; 164 position: absolute;
159 left: 100%; 165 left: 100%;
160 top: 0; 166 top: 0;
161 -webkit-margin-start: 22px; 167 -webkit-margin-start: 22px;
162 } 168 }
163 169
164 html.apps-promo-visible[dir=rtl] .app[app-id=web-store-entry] { 170 html.apps-promo-visible[dir=rtl] .app.web-store-entry {
165 right: 100%; 171 right: 100%;
166 } 172 }
167 173
168 html.apps-promo-visible .app[app-id=web-store-entry] a { 174 html.apps-promo-visible .app.web-store-entry a {
169 font-weight: bold; 175 font-weight: bold;
170 } 176 }
171 177
172 /* 178 /*
173 We position the web store entry all by its lonesome in the top of the rightmost 179 We position the web store entry all by its lonesome in the top of the rightmost
174 column when there is at least one full row of apps. Note that this is similar, 180 column when there is at least one full row of apps. Note that this is similar,
175 but different than its position during promo (html.apps-promo-visible), so we 181 but different than its position during promo (html.apps-promo-visible), so we
176 never set .loner while the promo is running. 182 never set .loner while the promo is running.
177 */ 183 */
178 .app[app-id=web-store-entry].loner { 184 .app.web-store-entry.loner {
179 position: absolute; 185 position: absolute;
180 left: 100%; 186 left: 100%;
181 top: 0; 187 top: 0;
182 } 188 }
183 189
184 html[dir=rtl] .app[app-id=web-store-entry].loner { 190 html[dir=rtl] .app.web-store-entry.loner {
185 right: 100%; 191 right: 100%;
186 } 192 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698