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

Side by Side Diff: chrome/browser/resources/settings/settings_page_css.html

Issue 2054013002: [MD settings] advanced toggle; add scrollWhenReady (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review nits Created 4 years, 6 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
OLDNEW
1 <link rel="import" href="/settings_page/main_page_behavior.html"> 1 <link rel="import" href="/settings_page/main_page_behavior.html">
2 2
3 <dom-module id="settings-page-styles"> 3 <dom-module id="settings-page-styles">
4 <template> 4 <template>
5 <style include="main-page-styles"> 5 <style include="main-page-styles">
6 :host { 6 :host {
7 --settings-page-padding-top: 21px;
8 box-sizing: border-box; 7 box-sizing: border-box;
9 display: block; 8 display: block;
10 height: inherit; 9 height: inherit;
11 margin: 0 auto; 10 margin: 0 auto;
12 max-width: 960px; 11 max-width: 960px;
13 min-width: 622px; 12 min-width: 622px;
14 position: relative; 13 position: relative;
15 width: 96%; 14 width: 96%;
16 } 15 }
17 16
18 :host > div { 17 :host > div {
19 height: inherit; 18 height: inherit;
20 } 19 }
21 20
22 :host > div > * { 21 :host > div > * {
23 /* The margin and padding here are doing two things: make the total 22 /* The margin and padding here are doing two things: make the total
24 * separation 24px; and make scrollIntoView align the section header 23 * separation 24px; and make scrollIntoView align the section header
25 * with the top item in the side nav menu. Both things are desired 24 * with the top item in the side nav menu. Both things are desired
26 * by Alan (bettes@). */ 25 * by Alan (bettes@). */
27 margin-bottom: 3px; 26 margin-bottom: 3px;
28 /* TODO(michaelpg): This makes more sense as padding, but uses margin as
29 * a workaround for crbug.com/617287. Because margins collapse, add 3px
30 * to retain mostly the same spacing. */
31 margin-top: calc(var(--settings-page-padding-top) + 3px);
32 }
33
34 :host > div > :first-of-type {
35 /* TODO(michaelpg): This is offset because of the previous addition of
36 * 3px: crbug.com/617287. */
37 margin-top: var(--settings-page-padding-top);
38 }
39
40 .expanded.frozen {
41 /* TODO(michaelpg): This is zeroed out because of the previous
42 * replacement of margin with padding, above: crbug.com/617287. */
43 margin-top: 0; /* -var(--settings-page-padding-top); */
44 } 27 }
45 </style> 28 </style>
46 </template> 29 </template>
47 </dom-module> 30 </dom-module>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698