index.html
4.1 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
<!DOCTYPE html>
<!--
Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
The complete set of contributors may be found at http://polymer.github.io/CONTRIBUTORS.txt
Code distributed by Google as part of the polymer project is also
subject to an additional IP rights grant found at http://polymer.github.io/PATENTS.txt
-->
<html>
<head>
<title>paper-header-panel demo</title>
<script src="../../webcomponentsjs/webcomponents.js"></script>
<link rel="import" href="../../paper-styles/paper-styles.html">
<link rel="import" href="../../paper-styles/demo-pages.html">
<link rel="import" href="../paper-header-panel.html">
<style is="custom-style">
body {
padding: 40px;
}
paper-header-panel {
float: left;
width: 240px;
height: 240px;
margin: 12px;
@apply(--shadow-elevation-2dp);
}
.paper-header {
height: 60px;
font-size: 16px;
line-height: 60px;
padding: 0 10px;
color: white;
transition: height 0.2s;
}
.paper-header.tall {
height: 120px;
}
.paper-header.medium-tall {
height: 100px;
line-height: 50px;
}
.content {
height: 2000px;
}
.cover {
margin: 60px;
}
.blue .paper-header {
background-color: var(--paper-light-blue-500);
}
.red .paper-header {
background-color: var(--paper-red-500);
}
.orange .paper-header {
background-color: var(--paper-amber-500);
}
.green .paper-header {
background-color: var(--paper-green-500);
}
.cyan .paper-header {
background-color: var(--paper-cyan-500);
}
.lime .paper-header {
background-color: var(--paper-lime-500);
}
.pink .paper-header {
background-color: var(--paper-pink-a200);
}
/* TODO: replace these with background: linear-gradient(white, var(...))
when custom properties allow it */
.blue .content {
background: linear-gradient(white, #b3e5fc);
}
.red .content {
background: linear-gradient(white, #ffcdd2);
}
.orange .content {
background: linear-gradient(white, #ffecb3);
}
.green .content {
background: linear-gradient(white, #c8e6c9);
}
.cyan .content {
background: linear-gradient(white, #b2ebf2);
}
.lime .content {
background: linear-gradient(white, #f0f4c3);
}
.pink .content {
background: linear-gradient(white, #f8bbd0);
}
</style>
</head>
<body>
<div class="layout wrap inline center-center">
<paper-header-panel class="blue">
<div class="paper-header">standard</div>
<div class="content"></div>
</paper-header-panel>
<paper-header-panel mode="seamed" class="red">
<div class="paper-header">seamed</div>
<div class="content"></div>
</paper-header-panel>
<paper-header-panel mode="scroll" class="orange">
<div class="paper-header">scroll</div>
<div class="content"></div>
</paper-header-panel>
<paper-header-panel mode="waterfall" class="green">
<div class="paper-header">waterfall</div>
<div class="content"></div>
</paper-header-panel>
<paper-header-panel mode="waterfall-tall" class="pink">
<div class="paper-header">waterfall-tall</div>
<div class="content"></div>
</paper-header-panel>
<paper-header-panel mode="waterfall-tall" tall-class="medium-tall" class="cyan">
<div class="paper-header">waterfall-tall<br>tall-class: medium-tall</div>
<div class="content"></div>
</paper-header-panel>
<paper-header-panel mode="cover" class="lime">
<div class="paper-header tall">cover</div>
<div class="content cover"></div>
</paper-header-panel>
</div>
</body>
</html>