A material design container that looks like a lifted sheet of paper

Downloads in past


1953.0.15 years ago7 years agoMinified + gzip package size for @polymer/paper-material in KB


Published on NPM Build status Published on webcomponents.org


paper-material is a container that renders two shadows on top of each other to create the effect of a lifted piece of paper.
⚠️ As of the 2.0 release, this element is deprecated in favour of the shared styles in PolymerElements/paper-styles. Please see the implementation of PolymerElements/paper-button for an example.
See: Documentation, Demo.



npm install --save @polymer/paper-material

In an html file

    <script type="module">
      import '@polymer/paper-material/paper-material.js';
    <paper-material elevation="1">
      <div>Some content</div>

In a Polymer 3 element

import {PolymerElement, html} from '@polymer/polymer';
import '@polymer/paper-material/paper-material.js';

class SampleElement extends PolymerElement {
  static get template() {
    return html`
      <paper-material elevation="1">
        <div>Some content</div>
customElements.define('sample-element', SampleElement);


If you want to send a PR to this element, here are the instructions for running the tests and demo locally:


git clone https://github.com/PolymerElements/paper-material
cd paper-material
npm install
npm install -g polymer-cli

Running the demo locally

polymer serve --npm

Running the tests

polymer test --npm