【发布时间】:2016-03-02 07:27:29
【问题描述】:
In this jsBin,我正在尝试将paper-fab 添加到我的元素中。
我希望看到与elevation 属性对应的阴影。但相反,我看不到阴影。所有高程似乎都有相同的阴影(隐含的 z 深度)。
是我的代码有问题还是元素有问题?
http://jsbin.com/corisahoqi/edit?html,输出<!doctype html>
<head>
<meta charset="utf-8">
<!---- >
<base href="https://polygit.org/components/">
<!---- >
Toggle below/above as backup when server is down
<!---->
<base href="https://polygit2.appspot.com/components/">
<!---->
<script src="webcomponentsjs/webcomponents-lite.min.js"></script>
<link href="polymer/polymer.html" rel="import">
<link href="paper-fab/paper-fab.html" rel="import">
<link href="iron-icons/iron-icons.html" rel="import">
</head>
<body>
<dom-module id="x-element">
<template>
<style>
paper-fab {
margin: 15px;
}
</style>
<paper-fab icon="add" elevation="5"></paper-fab>
<paper-fab icon="add" elevation="4"></paper-fab>
<paper-fab icon="add" elevation="3"></paper-fab>
<paper-fab icon="add" elevation="2"></paper-fab>
<paper-fab icon="add" elevation="1"></paper-fab>
</template>
<script>
(function(){
Polymer({
is: "x-element",
});
})();
</script>
</dom-module>
<x-element></x-element>
</body>
【问题讨论】:
标签: polymer polymer-1.0 paper-elements