Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 <link rel="import" href="chrome://resources/html/polymer.html"> | 1 <link rel="import" href="chrome://resources/html/polymer.html"> |
| 2 <link rel="import" href="chrome://resources/polymer/v1_0/iron-media-query/iron-m edia-query.html"> | 2 <link rel="import" href="chrome://resources/polymer/v1_0/iron-media-query/iron-m edia-query.html"> |
| 3 <link rel="import" href="chrome://resources/polymer/v1_0/paper-icon-button/paper -icon-button.html"> | 3 <link rel="import" href="chrome://resources/polymer/v1_0/paper-icon-button/paper -icon-button.html"> |
| 4 <link rel="import" href="chrome://resources/cr_elements/cr_toolbar/cr_toolbar_se arch_field.html"> | 4 <link rel="import" href="chrome://resources/cr_elements/cr_toolbar/cr_toolbar_se arch_field.html"> |
| 5 | 5 |
| 6 <dom-module id="cr-toolbar"> | 6 <dom-module id="cr-toolbar"> |
| 7 <template> | 7 <template> |
| 8 <style> | 8 <style> |
| 9 :host { | 9 :host { |
| 10 --cr-toolbar-field-width: 580px; | 10 --cr-toolbar-field-width: 580px; |
| 11 --cr-toolbar-height: 56px; | 11 --cr-toolbar-height: 56px; |
| 12 color: #fff; | 12 color: #fff; |
| 13 display: flex; | 13 display: flex; |
| 14 height: var(--cr-toolbar-height); | 14 height: var(--cr-toolbar-height); |
| 15 } | 15 } |
| 16 | 16 |
| 17 h1 { | 17 h1 { |
| 18 -webkit-margin-start: 6px; | 18 -webkit-margin-start: 6px; |
| 19 -webkit-padding-end: 2px; | |
| 19 flex: 1; | 20 flex: 1; |
| 20 font-size: 123%; | 21 font-size: 123%; |
| 21 font-weight: 400; | 22 font-weight: 400; |
| 22 text-overflow: ellipsis; | 23 text-overflow: ellipsis; |
| 23 overflow: hidden; | 24 overflow: hidden; |
| 24 white-space: nowrap; | 25 white-space: nowrap; |
| 25 } | 26 } |
| 26 | 27 |
| 27 #leftContent { | 28 #leftContent { |
| 28 -webkit-margin-start: 18px; | 29 -webkit-margin-start: 18px; |
| (...skipping 21 matching lines...) Expand all Loading... | |
| 50 | 51 |
| 51 :host([narrow_]) #centeredContent { | 52 :host([narrow_]) #centeredContent { |
| 52 -webkit-padding-end: var(--cr-toolbar-field-end-padding, 12px); | 53 -webkit-padding-end: var(--cr-toolbar-field-end-padding, 12px); |
| 53 } | 54 } |
| 54 | 55 |
| 55 :host(:not([narrow_])) h1 { | 56 :host(:not([narrow_])) h1 { |
| 56 @apply(--cr-toolbar-header-wide); | 57 @apply(--cr-toolbar-header-wide); |
| 57 } | 58 } |
| 58 | 59 |
| 59 :host(:not([narrow_])) #leftContent { | 60 :host(:not([narrow_])) #leftContent { |
| 60 max-width: calc((100% - var(--cr-toolbar-field-width) - 18px) / 2); | 61 max-width: calc((100% - var(--cr-toolbar-field-width)) / 2 - 18px); |
|
dpapad
2016/11/17 18:49:29
Can you add a comment explaining the rationale of
tsergeant
2016/11/18 00:03:06
Done. In the process, I realised I could change th
| |
| 61 @apply(--cr-toolbar-left-content-wide); | 62 @apply(--cr-toolbar-left-content-wide); |
| 62 } | 63 } |
| 63 | 64 |
| 64 :host(:not([narrow_])) #rightContent { | 65 :host(:not([narrow_])) #rightContent { |
| 65 @apply(--cr-toolbar-right-content-wide); | 66 @apply(--cr-toolbar-right-content-wide); |
| 66 } | 67 } |
| 67 | 68 |
| 68 :host([narrow_]) #centeredContent { | 69 :host([narrow_]) #centeredContent { |
| 69 justify-content: flex-end; | 70 justify-content: flex-end; |
| 70 } | 71 } |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 149 <iron-media-query query="(max-width: 900px)" query-matches="{{narrow_}}"> | 150 <iron-media-query query="(max-width: 900px)" query-matches="{{narrow_}}"> |
| 150 </iron-media-query> | 151 </iron-media-query> |
| 151 </div> | 152 </div> |
| 152 | 153 |
| 153 <div id="rightContent"> | 154 <div id="rightContent"> |
| 154 <content select=".more-actions"></content> | 155 <content select=".more-actions"></content> |
| 155 </div> | 156 </div> |
| 156 </template> | 157 </template> |
| 157 <script src="cr_toolbar.js"></script> | 158 <script src="cr_toolbar.js"></script> |
| 158 </dom-module> | 159 </dom-module> |
| OLD | NEW |