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

Side by Side Diff: third_party/polymer/components-chromium/paper-shadow/paper-shadow-extracted.js

Issue 1215543002: Remove Polymer 0.5. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix unit test Created 5 years, 5 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
(Empty)
1
2 Polymer('paper-shadow',{
3
4 publish: {
5
6 /**
7 * The z-depth of this shadow, from 0-5. Setting this property
8 * after element creation has no effect. Use `setZ()` instead.
9 *
10 * @attribute z
11 * @type number
12 * @default 1
13 */
14 z: 1,
15
16 /**
17 * Set this to true to animate the shadow when setting a new
18 * `z` value.
19 *
20 * @attribute animated
21 * @type boolean
22 * @default false
23 */
24 animated: false
25
26 },
27
28 /**
29 * Set the z-depth of the shadow. This should be used after element
30 * creation instead of setting the z property directly.
31 *
32 * @method setZ
33 * @param {Number} newZ
34 */
35 setZ: function(newZ) {
36 if (this.z !== newZ) {
37 this.$['shadow-bottom'].classList.remove('paper-shadow-bottom-z-' + this .z);
38 this.$['shadow-bottom'].classList.add('paper-shadow-bottom-z-' + newZ);
39 this.$['shadow-top'].classList.remove('paper-shadow-top-z-' + this.z);
40 this.$['shadow-top'].classList.add('paper-shadow-top-z-' + newZ);
41 this.z = newZ;
42 }
43 }
44
45 });
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698