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

Side by Side Diff: chrome/browser/resources/md_history/history_item.html

Issue 1641543002: MD History: Refactored design for displaying history information (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@second_patch
Patch Set: removed dodgy fix for end of history query: Created 4 years, 10 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="chrome://resources/polymer/v1_0/polymer/polymer.html"> 1 <link rel="import" href="chrome://resources/polymer/v1_0/polymer/polymer.html">
2 <link rel="import" href="chrome://resources/polymer/v1_0/iron-flex-layout/iron-f lex-layout.html">
2 <link rel="import" href="chrome://resources/polymer/v1_0/iron-icon/iron-icon.htm l"> 3 <link rel="import" href="chrome://resources/polymer/v1_0/iron-icon/iron-icon.htm l">
3 <link rel="import" href="chrome://resources/polymer/v1_0/iron-icons/iron-icons.h tml"> 4 <link rel="import" href="chrome://resources/polymer/v1_0/iron-icons/iron-icons.h tml">
4 <link rel="import" href="chrome://resources/polymer/v1_0/paper-button/paper-butt on.html"> 5 <link rel="import" href="chrome://resources/polymer/v1_0/paper-button/paper-butt on.html">
5 <link rel="import" href="chrome://resources/polymer/v1_0/paper-checkbox/paper-ch eckbox.html"> 6 <link rel="import" href="chrome://resources/polymer/v1_0/paper-checkbox/paper-ch eckbox.html">
6 <link rel="import" href="chrome://resources/polymer/v1_0/paper-icon-button/paper -icon-button.html"> 7 <link rel="import" href="chrome://resources/polymer/v1_0/paper-icon-button/paper -icon-button.html">
8 <link rel="import" href="chrome://resources/polymer/v1_0/paper-styles/shadow.htm l">
7 <link rel="import" href="chrome://resources/html/util.html"> 9 <link rel="import" href="chrome://resources/html/util.html">
8 10
9 <dom-module id="history-item"> 11 <dom-module id="history-item">
10 <template> 12 <template>
11 <style> 13 <style>
14 :host {
15 @apply(--layout-center);
16 @apply(--layout-vertical);
17 padding: 0 24px;
18 }
19
12 #main-container { 20 #main-container {
21 background: #fff;
22 max-width: 960px;
23 width: 100%;
24 }
25
26 :host([is-first-card]) #main-container {
27 margin-top: 20px;
28 }
29
30 #date-accessed {
31 display: none;
32 }
33
34 :host([is-first-card]) #date-accessed {
35 @apply(--layout-center);
36 @apply(--layout-horizontal);
37 -webkit-padding-start: 20px;
38 background: #fafafa;
39 border-bottom: 1px solid rgba(0, 0, 0, 0.14);
40 border-radius: 2px 2px 0 0;
41 color: #333;
42 font-size: 14px;
43 font-weight: 500;
44 height: 48px;
45 }
46
47 #item-container {
13 @apply(--layout-center); 48 @apply(--layout-center);
14 @apply(--layout-horizontal); 49 @apply(--layout-horizontal);
15 min-height: 40px; 50 min-height: 40px;
16 } 51 }
17 52
53 :host([is-first-card]) #item-container {
54 padding: 8px 0 0 0;
tsergeant 2016/02/02 05:58:00 If you use padding-top here...
yingran 2016/02/02 06:49:10 Done.
55 }
56
57 :host([is-last-card]) #item-container {
58 padding: 0 0 8px 0;
tsergeant 2016/02/02 05:58:00 And padding-bottom here...
yingran 2016/02/02 06:49:10 Done.
59 }
60
61 :host([is-first-card][is-last-card]) #item-container {
tsergeant 2016/02/02 05:58:00 Then can you get rid of this block?
yingran 2016/02/02 06:49:10 Done.
62 padding: 8px 0;
63 }
64
18 paper-checkbox { 65 paper-checkbox {
19 --paper-checkbox-checked-color: rgb(68, 136, 255); 66 --paper-checkbox-checked-color: rgb(68, 136, 255);
20 --paper-checkbox-size: 16px; 67 --paper-checkbox-size: 16px;
21 --paper-checkbox-unchecked-color: #969696; 68 --paper-checkbox-unchecked-color: #969696;
22 height: 16px; 69 height: 16px;
23 margin: 0 16px 0 20px; 70 margin: 0 16px 0 20px;
24 padding: 2px; 71 padding: 2px;
25 width: 16px; 72 width: 16px;
26 } 73 }
27 74
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 } 117 }
71 118
72 #bookmark { 119 #bookmark {
73 -webkit-margin-end: 10px; 120 -webkit-margin-end: 10px;
74 -webkit-margin-start: 20px; 121 -webkit-margin-start: 20px;
75 color: rgb(68, 136, 255); 122 color: rgb(68, 136, 255);
76 min-width: 16px; 123 min-width: 16px;
77 visibility: hidden; 124 visibility: hidden;
78 } 125 }
79 126
80 :host([starred]) #bookmark { 127 #time-gap-separator {
81 visibility: visible; 128 -webkit-border-start: 1px solid #888;
129 -webkit-margin-start: 77px;
130 height: 15px;
82 } 131 }
83 </style> 132 </style>
133
84 <div id="main-container"> 134 <div id="main-container">
85 <paper-checkbox id="checkbox" on-tap="onCheckboxSelected_" 135 <div id="date-accessed">[[historyDate]]</div>
tsergeant 2016/02/02 05:58:00 Consider using <div id="date-accessed" hidden$="{
yingran 2016/02/02 06:49:10 Acknowledged.
86 checked="{{selected}}"> 136 <div id="item-container">
87 </paper-checkbox> 137 <paper-checkbox id="checkbox" on-tap="checkboxSelected"
88 <span id="time">{{timeAccessed_}}</span> 138 checked="{{selected}}">
89 <div id="website-icon"></div> 139 </paper-checkbox>
90 <a href="{{websiteUrl_}}" id="title">{{websiteTitle_}}</a> 140 <span id="time">{{timeAccessed}}</span>
91 <span id="domain">{{websiteDomain_}}</span> 141 <div id="website-icon"></div>
92 <iron-icon icon="star" id="bookmark"></iron-icon> 142 <a href="{{websiteUrl}}" id="title">{{websiteTitle}}</a>
93 <paper-icon-button icon="more-vert" id="menu-button" 143 <span id="domain">{{websiteDomain}}</span>
94 on-tap="onMenuButtonTap_"> 144 <iron-icon icon="star" id="bookmark"></iron-icon>
95 </paper-icon-button> 145 <paper-icon-button icon="more-vert" id="menu-button" on-tap="openMenu">
146 </paper-icon-button>
147 </div>
148 <template is="dom-if" if="{{hasTimeGap}}">
149 <div id="time-gap-separator"></div>
150 </template>
96 </div> 151 </div>
97 </template> 152 </template>
98 <script src="chrome://history/history_item.js"></script> 153 <script src="chrome://history/history_item.js"></script>
99 </dom-module> 154 </dom-module>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698