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

Unified Diff: chrome/browser/resources/ntp4/new_tab.css

Issue 12038090: Layout the NTP footer with flexboxes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/ntp4/new_tab.css
diff --git a/chrome/browser/resources/ntp4/new_tab.css b/chrome/browser/resources/ntp4/new_tab.css
index 9c77147cbe5481f135aca2c52aeb9e068625e6ad..91d0821b39aca0156a68b35bf32fbb66b7195105 100644
--- a/chrome/browser/resources/ntp4/new_tab.css
+++ b/chrome/browser/resources/ntp4/new_tab.css
@@ -180,8 +180,10 @@ html[dir='rtl'] #attribution {
}
#footer-content {
- -webkit-box-align: center;
- display: -webkit-box;
+ -webkit-align-items: center;
+ -webkit-flex-direction: row;
Dan Beam 2013/01/31 20:22:11 this seems to be the default value (so probably no
dconnelly 2013/02/04 16:40:45 Done.
+ -webkit-justify-content: space-between;
Dan Beam 2013/01/31 20:22:11 why is -webkit-justify-content needed?
dconnelly 2013/02/01 14:34:14 Re: justify, .invisible, etc: I think explaining t
+ display: -webkit-flex;
height: 49px;
}
@@ -385,7 +387,10 @@ html[dir='rtl'] #footer.showing-trash-mode #trash.drag-target .lid {
z-index: 5;
}
+/* Footer buttons. ************************************************************/
+
#chrome-web-store-link {
+ -webkit-order: 2;
-webkit-padding-end: 12px;
/* Match transition delay of recently closed button. */
-webkit-transition-delay: 100ms;
@@ -405,6 +410,11 @@ html[dir='rtl'] #footer.showing-trash-mode #trash.drag-target .lid {
line-height: 49px;
}
+#chrome-web-store-link.invisible {
+ -webkit-order: -1;
+ visibility: hidden;
+}
+
#chrome-web-store-link:hover {
color: #666;
}
@@ -415,20 +425,20 @@ html[dir='rtl'] #chrome-web-store-title {
#vertical-separator {
background-color: rgb(178, 178, 178);
- display: none;
+ display: inline-block;
height: 20px;
margin: 0;
vertical-align: middle;
+ visibility: hidden;
width: 1px;
}
/* Show the separator only if one of the menus is visible. */
-.footer-menu-button:not([hidden]) ~ #vertical-separator {
- display: block;
+.footer-menu-button:not(.invisible) ~ #chrome-web-store-link > #vertical-separator {
Dan Beam 2013/01/31 20:22:11 80 col wrap, > isn't needed
dconnelly 2013/02/04 16:40:45 Done.
+ visibility: visible;
}
/* In trash mode, hide the menus and web store link. */
-#footer.showing-trash-mode #chrome-web-store-link,
#footer.showing-trash-mode .menu-container {
-webkit-transition-delay: 0;
opacity: 0;
@@ -436,13 +446,33 @@ html[dir='rtl'] #chrome-web-store-title {
}
#footer .menu-container {
- -webkit-box-align: center;
+ -webkit-align-items: center;
+ -webkit-flex-direction: row;
+ -webkit-justify-content: flex-end;
/* Put menus in a box so the order can easily be swapped. */
- display: -webkit-box;
+ display: -webkit-flex;
height: 100%;
margin: 0;
}
+#recently-closed-menu-button.invisible {
Dan Beam 2013/01/31 20:22:11 why did you bring back this whole .invisible busin
dconnelly 2013/02/01 14:34:14 The problem is that the button group has variable
+ -webkit-order: -1;
+ visibility: hidden;
+}
+
+#recently-closed-menu-button:not(.invisible) {
+ -webkit-order: 1;
+}
+
+#other-sessions-menu-button.invisible {
Dan Beam 2013/01/31 20:22:11 combine with selector above, i.e. #chrome-web-s
dconnelly 2013/02/04 16:40:45 Done.
+ -webkit-order: -1;
+ visibility: hidden;
+}
+
+#other-sessions-menu-button::not(.invisible) {
Dan Beam 2013/01/31 20:22:11 ::not() should be :not() (:: means psuedo-element,
dconnelly 2013/02/04 16:40:45 Done.
+ -webkit-order: 0;
+}
+
.other-sessions-promo-message {
display: none;
padding: 0;
« no previous file with comments | « no previous file | chrome/browser/resources/ntp4/new_tab.html » ('j') | chrome/browser/resources/ntp4/new_tab.html » ('J')

Powered by Google App Engine
This is Rietveld 408576698