Socket
Socket
Sign inDemoInstall

@polymer/paper-icon-button

Package Overview
Dependencies
14
Maintainers
12
Versions
33
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @polymer/paper-icon-button

A material design icon button


Version published
Weekly downloads
12K
decreased by-6.88%
Maintainers
12
Install size
2.05 MB
Created
Weekly downloads
 

Readme

Source

Published on NPM Build status Published on webcomponents.org

<paper-icon-button>

paper-icon-button is a button with an image placed at the center. When the user touches the button, a ripple effect emanates from the center of the button.

paper-icon-button does not include a default icon set. To use icons from the default set, include @polymer/iron-icons/iron-icons.js, and use the icon attribute to specify which icon from the icon set to use.

See: Documentation, Demo.

Usage

Installation

npm install --save @polymer/paper-icon-button

In an html file

<html>
  <head>
    <script type="module">
      import '@polymer/paper-icon-button/paper-icon-button.js';
      import '@polymer/iron-icons/iron-icons.js';
    </script>
  </head>
  <body>
    <paper-icon-button icon="favorite"></paper-icon-button>
  </body>
</html>

In a Polymer 3 element

import {PolymerElement, html} from '@polymer/polymer';
import '@polymer/paper-icon-button/paper-icon-button.js';
import '@polymer/iron-icons/iron-icons.js';

class SampleElement extends PolymerElement {
  static get template() {
    return html`
      <paper-icon-button icon="favorite"></paper-icon-button>
    `;
  }
}
customElements.define('sample-element', SampleElement);

Contributing

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

Installation

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

Running the demo locally

polymer serve --npm
open http://127.0.0.1:<port>/demo/

Running the tests

polymer test --npm

Keywords

FAQs

Last updated on 16 Jan 2019

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc