{"bugs":{"url":"https://github.com/material-components/material-components-web/issues"},"dist":{"shasum":"a96a96f1b3a40a4ed0d3c6d6c1d530f105a1e962","tarball":"https://registry.npmjs.org/@material/fab/-/fab-1.0.0-0.tgz","fileCount":9,"integrity":"sha512-H6/5pZrN09+jvgLyUbCbpCNw6OdluROImB+Kib1XAB1Ktp2ZHAHMsNHbGlKKl7qfxirKAeN+I/OEmbVpNhNapA==","signatures":[{"sig":"MEYCIQCX6BmlUO9uaqjpyLcrzv2y85EDqVBZNpxwp2kk5LETgQIhAJVJGqeB2AbQQ0uImT7ZpU/8jzOjDrUSC4BL/cZs3Y9V","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":141260,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJcdyRpCRA9TVsSAnZWagAAif8QAI0+uWFVF6h1Ly8e1EbG\n/rN2cqT0D/tV91frhqDR/CJRHw7M4pYbx0W2jkmOwXbIZhZZBsoPKdbLpegi\n3e6CC8+ndDnVuHzKikL/BQmiNIUZ6JqJozILQFtBPqDSIZKtgQqv5nlgUsa5\ndD1HUAko+bDG8RIov823w1ju7kWZxNARdyyfyiE/Lt4bzWwHiBzW16qtjr/V\nsk+PMVnZ7AU3fK0JGsNe+d4KzBv266Iy0Dqib+s/uLC9I+T2YsuyYaDNQ14Q\ngT9ZUR9HQkh0GmmxNqvh0Qx20ViScxDqYJakSpz0HaJ7V+quPxICdRtCJrwB\nNteLNa6i6DLybZmePIB4kYAVg3vAhQBOO+RMiW5irT1qMSDIx7XoORF2Oz2Y\np3qvt+by6dBb7EqvJPs1FxwvPP2PphJJgXUdU/s6F6/ndI8pHq4DhmKZaGrB\nfxp8NYNNho0/s6nxahJ0MlhoimHgaavAeXGvmiSKqH53QMYa1RRpKLTJIu5B\nm957pjloUAHKgTwvzh4GbsAvlSc07sOpCaIAtDFxpbWgudk7NPLJCnZfi4CM\nxGAzi3Aleo1FecVKxn49FBnzUGRddgyZqLzXpwEcMOtY9t4tJBw9tosYeoKY\nkR/qIMwDlgc/KFjQMG/gT62lsmbGVtvtcvYp13yfOH96nE+6XkWSFTVUNyUr\n4yMH\r\n=6S4s\r\n-----END PGP SIGNATURE-----\r\n"},"name":"@material/fab","readme":"<!--docs:\ntitle: \"Floating Action Button\"\nlayout: detail\nsection: components\nexcerpt: \"A floating action button represents the primary action in an application\"\niconId: button\npath: /catalog/buttons/floating-action-buttons/\n-->\n\n# Floating Action Button\n\n<!--<div class=\"article__asset\">\n  <a class=\"article__asset-link\"\n     href=\"https://material-components.github.io/material-components-web-catalog/#/component/fab\">\n    <img src=\"{{ site.rootpath }}/images/mdc_web_screenshots/fabs.png\" width=\"78\" alt=\"Floating action button screenshot\">\n  </a>\n</div>-->\n\nA floating action button represents the primary action in an application.\n\n## Design & API Documentation\n\n<ul class=\"icon-list\">\n  <li class=\"icon-list-item icon-list-item--spec\">\n    <a href=\"https://material.io/go/design-fab\">Material Design guidelines: Floating Action Button</a>\n  </li>\n  <li class=\"icon-list-item icon-list-item--link\">\n    <a href=\"https://material-components.github.io/material-components-web-catalog/#/component/fab\">Demo</a>\n  </li>\n</ul>\n\n## Installation\n\n```\nnpm install @material/fab\n```\n\n## Basic Usage\n\n### Load Material Icons\n\nWe recommend using [Material Icons](https://material.io/tools/icons/) from Google Fonts:\n\n```html\n<head>\n  <link rel=\"stylesheet\" href=\"https://fonts.googleapis.com/icon?family=Material+Icons\">\n</head>\n```\n\nHowever, you can also use SVG, [Font Awesome](https://fontawesome.com/), or any other icon library you wish.\n\n### HTML Structure\n\n```html\n<button class=\"mdc-fab\" aria-label=\"Favorite\">\n  <span class=\"mdc-fab__icon material-icons\">favorite</span>\n</button>\n```\n\n> _NOTE:_ The floating action button icon can be used with a `span`, `i`, `img`, or `svg` element.\n\n> _NOTE:_ IE 11 will not center the icon properly if there is a newline or space after the material icon text.\n\n### Styles\n\n```scss\n@import \"@material/fab/mdc-fab\";\n```\n\n### JavaScript Instantiation\n\nThe FAB will work without JavaScript, but you can enhance it to have a ripple effect by instantiating `MDCRipple` on the root element. See [MDC Ripple](../mdc-ripple) for details.\n\n```js\nimport {MDCRipple} from '@material/ripple';\n\nconst fabRipple = new MDCRipple(document.querySelector('.mdc-fab'));\n```\n\n> See [Importing the JS component](../../docs/importing-js.md) for more information on how to import JavaScript.\n\n## Variants\n\n### Extended FAB\n\n```html\n<button class=\"mdc-fab mdc-fab--extended\">\n  <span class=\"material-icons mdc-fab__icon\">add</span>\n  <span class=\"mdc-fab__label\">Create</span>\n</button>\n```\n\n> _NOTE:_ The extended FAB must contain label where as the icon is optional. The icon and label may be specified in whichever order is appropriate based on context.\n\n## Style Customization\n\n### CSS Classes\n\nCSS Class | Description\n--- | ---\n`mdc-fab` | Mandatory, for the button element\n`mdc-fab__icon` | Mandatory, for the icon element\n`mdc-fab__label` | Optional, for the text label. Applicable only for Extended FAB.\n`mdc-fab--mini` | Optional, modifies the FAB to a smaller size\n`mdc-fab--extended` | Optional, modifies the FAB to wider size which includes a text label.\n`mdc-fab--exited` | Optional, animates the FAB out of view.<br>When this class is removed, the FAB will return to view.\n\n> **A note about `:disabled`**, No disabled styles are defined for FABs. The FAB promotes action, and should not be displayed in a disabled state. If you want to present a FAB that does *not* perform an action, you should also present an explanation to the user.\n\n### Sass Mixins\n\n#### Basic Sass Mixins\n\nMDC FAB uses [MDC Theme](../mdc-theme)'s `secondary` color by default. Use the following mixins to customize it.\n\nMixin | Description\n--- | ---\n`mdc-fab-accessible($container-color)` | Changes the FAB's container color to the given color, and updates the FAB's ink and ripple color to meet accessibility standards.\n`mdc-fab-extended-fluid` | Makes the Extended FAB fluid to container, such as screen width or the layout grid. Exposed as a mixin to support use within `@media` queries.\n\n#### Advanced Sass Mixins\n\n> **A note about advanced mixins**, The following mixins are intended for advanced users. These mixins will override the color of the container, ink, or ripple. You can use all of them if you want to completely customize a FAB. Or you can use only one of them, e.g. if you only need to override the ripple color. **It is up to you to pick container, ink, and ripple colors that work together, and meet accessibility standards.**\n\nMixin | Description\n--- | ---\n`mdc-fab-container-color($color)` | Sets the container color to the given color\n`mdc-fab-icon-size($width, $height)` | Sets the icon `width`, `height`, and `font-size` properties to the specified `width` and `height`. `$height` is optional and will default to `$width` if omitted. The `font-size` will be set to the provided `$width` value.\n`mdc-fab-ink-color($color)` | Sets the ink color to the given color\n`mdc-fab-extended-padding($icon-padding, $label-padding)` | Sets the padding on both sides of the icon, and between the label and the edge of the FAB. In cases where there is no icon, `$label-padding` will apply to both sides.\n`mdc-fab-extended-label-padding($label-padding)` | Sets the label side padding for Extended FAB. Useful when styling an Extended FAB with no icon.\n`mdc-fab-shape-radius($radius, $rtl-reflexive)` | Sets rounded shape to only regular & mini FAB variants with given radius size. Set `$rtl-reflexive` to true to flip radius values in RTL context, defaults to false.\n`mdc-fab-extended-shape-radius($radius, $rtl-reflexive)` | Sets rounded shape to only Extended FAB variant with given radius size. Set `$rtl-reflexive` to true to flip radius values in RTL context, defaults to false.\n\nThe ripple effect for the FAB component is styled using [MDC Ripple](../mdc-ripple) mixins.\n\n#### Caveat: Edge and CSS Variables\n\nIn browsers that fully support CSS custom properties, the above mixins will work if you pass in a [MDC Theme](../mdc-theme) property (e.g. `primary`) as an argument. However, Edge does not fully support CSS custom properties. If you are using the `mdc-fab-container-color` mixin, you must pass in an actual color value for support in Edge.\n\n### Additional Information\n\n#### Positioning\n\nDevelopers must position MDC FAB as needed within their application's design.\n\n```html\n<!--\n  This will position the FAB in the bottom-right corner.\n  Modify to fit your design's requirements.\n-->\n<style>\n.app-fab--absolute {\n  position: fixed;\n  bottom: 1rem;\n  right: 1rem;\n}\n\n@media(min-width: 1024px) {\n   .app-fab--absolute {\n    bottom: 1.5rem;\n    right: 1.5rem;\n  }\n}\n</style>\n<button class=\"mdc-fab app-fab--absolute\" aria-label=\"Favorite\">\n  <span class=\"mdc-fab__icon material-icons\">favorite</span>\n</button>\n```\n","license":"MIT","_npmUser":{"name":"acdvorak","email":"acdvorak@gmail.com"},"homepage":"https://github.com/material-components/material-components-web#readme","keywords":["material components","material design","floating action button","fab"],"repository":{"url":"git+https://github.com/material-components/material-components-web.git","type":"git"},"_npmVersion":"6.8.0","description":"The Material Components for the web floating action button component","directories":{},"maintainers":[{"name":"abhiomkar","email":"abhiomkar@gmail.com"},{"name":"acdvorak","email":"acdvorak@gmail.com"},{"name":"aprigogin","email":"andrey.prigogin@gmail.com"},{"name":"azakus","email":"dfreedm2@gmail.com"},{"name":"bicknellr","email":"bicknellr@gmail.com"},{"name":"bonniez","email":"bonniez@google.com"},{"name":"bwobrien","email":"obrien.test@gmail.com"},{"name":"kfranqueiro","email":"kenneth.franqueiro@gmail.com"},{"name":"lynnjepsen","email":"lynnjepsen@google.com"},{"name":"material-admin","email":"lynnjepsen+npm@google.com"},{"name":"moog16","email":"mattgoo@gmail.com"},{"name":"patrickrodee","email":"prodee@google.com"},{"name":"williamernest","email":"williamernest@google.com"}],"_nodeVersion":"10.14.2","dependencies":{"@material/rtl":"^0.42.0","@material/shape":"^1.0.0-0","@material/theme":"^1.0.0-0","@material/ripple":"^1.0.0-0","@material/animation":"^1.0.0-0","@material/elevation":"^1.0.0-0","@material/typography":"^1.0.0-0"},"_hasShrinkwrap":false,"readmeFilename":"README.md","_npmOperationalInternal":{"tmp":"tmp/fab_1.0.0-0_1551311976851_0.4906790565806016","host":"s3://npm-registry-packages"},"_id":"@material/fab@1.0.0-0","version":"1.0.0-0"}