OLD | NEW |
1 <!-- | 1 <!-- |
2 @license | 2 @license |
3 Copyright (c) 2017 The Polymer Project Authors. All rights reserved. | 3 Copyright (c) 2017 The Polymer Project Authors. All rights reserved. |
4 This code may only be used under the BSD style license found at http://polymer.g
ithub.io/LICENSE.txt | 4 This code may only be used under the BSD style license found at http://polymer.g
ithub.io/LICENSE.txt |
5 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt | 5 The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt |
6 The complete set of contributors may be found at http://polymer.github.io/CONTRI
BUTORS.txt | 6 The complete set of contributors may be found at http://polymer.github.io/CONTRI
BUTORS.txt |
7 Code distributed by Google as part of the polymer project is also | 7 Code distributed by Google as part of the polymer project is also |
8 subject to an additional IP rights grant found at http://polymer.github.io/PATEN
TS.txt | 8 subject to an additional IP rights grant found at http://polymer.github.io/PATEN
TS.txt |
9 --> | 9 --> |
10 | 10 |
11 <link rel="import" href="../../polymer/polymer.html"> | 11 <link rel="import" href="../../polymer/polymer.html"> |
12 <link rel="import" href="../shadow.html"> | 12 <link rel="import" href="../shadow.html"> |
13 | 13 |
14 <!-- | 14 <!-- |
15 Material design: [Cards](https://www.google.com/design/spec/components/cards.htm
l) | 15 Material design: [Cards](https://www.google.com/design/spec/components/cards.htm
l) |
16 | 16 |
17 Shared styles that you can apply to an element to renders two shadows on top | 17 Shared styles that you can apply to an element to renders two shadows on top |
18 of each other,that create the effect of a lifted piece of paper. | 18 of each other,that create the effect of a lifted piece of paper. |
19 | 19 |
20 Example: | 20 Example: |
21 | 21 |
22 <custom-style> | 22 <custom-style> |
23 <style is="custom-style" include="paper-material"></style> | 23 <style is="custom-style" include="paper-material-styles"></style> |
24 </custom-style> | 24 </custom-style> |
25 | 25 |
26 <div class="paper-material elevation-1"> | 26 <div class="paper-material elevation-1"> |
27 ... content ... | 27 ... content ... |
28 </div> | 28 </div> |
29 | 29 |
30 @group Paper Elements | 30 @group Paper Elements |
31 @demo demo/index.html | 31 @demo demo/index.html |
32 --> | 32 --> |
33 | 33 |
34 <dom-module id="paper-material"> | 34 <dom-module id="paper-material-styles"> |
35 <template> | 35 <template> |
36 <style> | 36 <style> |
37 :host, html { | 37 :host, html { |
38 --paper-material: { | 38 --paper-material: { |
39 display: block; | 39 display: block; |
40 position: relative; | 40 position: relative; |
41 }; | 41 }; |
42 --paper-material-elevation-1: { | 42 --paper-material-elevation-1: { |
43 @apply --shadow-elevation-2dp; | 43 @apply --shadow-elevation-2dp; |
44 }; | 44 }; |
(...skipping 24 matching lines...) Expand all Loading... |
69 } | 69 } |
70 :host(.paper-material[elevation="4"]), .paper-material[elevation="4"] { | 70 :host(.paper-material[elevation="4"]), .paper-material[elevation="4"] { |
71 @apply --paper-material-elevation-4; | 71 @apply --paper-material-elevation-4; |
72 } | 72 } |
73 :host(.paper-material[elevation="5"]), .paper-material[elevation="5"] { | 73 :host(.paper-material[elevation="5"]), .paper-material[elevation="5"] { |
74 @apply --paper-material-elevation-5; | 74 @apply --paper-material-elevation-5; |
75 } | 75 } |
76 </style> | 76 </style> |
77 </template> | 77 </template> |
78 </dom-module> | 78 </dom-module> |
OLD | NEW |