{"bugs":{"url":"https://github.com/material-components/material-components-web/issues"},"dist":{"shasum":"9b5c5e19ee2b89c0fd6c8f89874f70d43e06b05b","tarball":"https://registry.npmjs.org/@material/tab-indicator/-/tab-indicator-9.0.0-canary.30fdfd06e.0.tgz","fileCount":38,"integrity":"sha512-2KqFjWNTXicQEEzB6SdyOCg/7n+cYsjz4nWWRIVRtdY0DRywteH+UEd3Vx6qNiHNOuzSZyIWuP1dMBBd0CO8Yw==","signatures":[{"sig":"MEYCIQCCZTmvR9rD8v5epi00F84f9FuR2nsxadeZV3Ubf06j+wIhAK2VTbwTG8zCWTaW7Uhr5N6jrp5iJJfNKyqDMLlTKQSH","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":171801,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJf2lrlCRA9TVsSAnZWagAAh/YQAJWuVOYH2rU3dAXXIJQG\nlM+rSXITeyJR1cactA9Yp1sI3xaabASD/U5/6Y2UavffMd7tO246bMPCyHuV\n/UErE/U6OAYiN5Yb1pqevUeanGg0u8NqM745kkfzZt1VZlKdb4T7s0Bi+VD8\n7U/ZqGpVTXBWdXym8H/G3eZO3m+gLdttjb/HfgbyPDCpMNjsTvBQm6OLUFtd\nRbCQsDrnkdIevbPmVbE0ifCLzx7WT5zdMbmLnCHIUNCl8bz4Uv3czyCKLgo+\n2p/ndEFOd6u+aJp7epc/COJ7OCxoxRA2fsVi2OqVzzdf8ewGzOhKT+7pK0ux\nHQwz/OzD63Mp201jlmgUd6W3EnrYcS2SHDwI/Qa7+8u7SAShqrl7fEW2l8hw\n0vK7Erf7KFoOymelwPBR2IMd64QE2W16dJJmYndBYBdO+epzY6G5C6QlSZBD\nsEOd+NjekOZWOupo5SRYw76M3CRKGsVa/lvfPtQNusJMxy+WqdX8Q45kmc+c\nFsiDgSwzM0u5SFpJ7K0ki+clni0ZwANUBf3IwkhJlkoRln5E9e7VR1XMdnGP\niPvnPrIUPU+TpXI9jDPWsYZirrhiZIbQnPXeaimH/GzCDUYIRde/UP1k9Myt\n9cis7m2GTwKxC742yzCMuYZOCGxM8T8dxO8wRudW5XXNW/sjex4xTQl8aIYS\nKtaX\r\n=6eVY\r\n-----END PGP SIGNATURE-----\r\n"},"main":"dist/mdc.tabIndicator.js","name":"@material/tab-indicator","types":"dist/mdc.tabIndicator.d.ts","module":"index.js","readme":"<!--docs:\ntitle: \"Tab Indicator\"\nlayout: detail\nsection: components\nexcerpt: \"A visual guide that shows which Tab is active.\"\niconId: tabs\npath: /catalog/tabs/indicator/\n-->\n\n# Tab Indicator\n\nA Tab Indicator is a visual guide that shows which Tab is active.\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-tabs#anatomy\">Material Design guidelines: Anatomy of Tabs</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/tabs\">Demo</a>\n  </li>\n</ul>\n\n## Installation\n\n```\nnpm install @material/tab-indicator\n```\n\n## Basic Usage\n\n### HTML Structure\n\n```html\n<span class=\"mdc-tab-indicator\">\n  <span class=\"mdc-tab-indicator__content\"></span>\n</span>\n```\n\n### Styles\n\n```scss\n@use \"@material/tab-indicator/mdc-tab-indicator\";\n```\n\n### JavaScript Instantiation\n\n```js\nimport {MDCTabIndicator} from '@material/tab-indicator';\n\nconst tabIndicator = new MDCTabIndicator(document.querySelector('.mdc-tab-indicator'));\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### Active Indicator\n\nAdd the `mdc-tab-indicator--active` class to the `mdc-tab-indicator` element to make the Tab Indicator active.\n\n### Indicator Types and Transitions\n\nThe Tab Indicator may be represented in one of two ways:\n\n* Underline, indicated by the `mdc-tab-indicator__content--underline` class\n* Icon, indicated by the `mdc-tab-indicator__content--icon` class\n\n> *NOTE*: One of these classes _must_ be applied to the Tab Indicator's content element.\n\nThe Tab Indicator may transition in one of two ways:\n\n* Slide, the default behavior\n* Fade, indicated by the `mdc-tab-indicator--fade` class\n\n#### Sliding Underline Indicator\n\n```html\n<span class=\"mdc-tab-indicator\">\n  <span class=\"mdc-tab-indicator__content mdc-tab-indicator__content--underline\"></span>\n</span>\n```\n\n#### Icon Indicators\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\nRemember to include `aria-hidden=\"true\"`, since the active indicator is already signified via the\n`aria-selected` attribute on the tab.\n\n##### Fading Icon Indicator\n\n```html\n<span class=\"mdc-tab-indicator mdc-tab-indicator--fade\">\n  <span class=\"mdc-tab-indicator__content mdc-tab-indicator__content--icon material-icons\" aria-hidden=\"true\">star</span>\n</span>\n```\n\n##### Sliding Icon Indicator\n\n```html\n<span class=\"mdc-tab-indicator\">\n  <span class=\"mdc-tab-indicator__content mdc-tab-indicator__content--icon material-icons\" aria-hidden=\"true\">star</span>\n</span>\n```\n\n## Style Customization\n\n### CSS Classes\n\nCSS Class | Description\n--- | ---\n`mdc-tab-indicator` | Mandatory. Contains the tab indicator content.\n`mdc-tab-indicator__content` | Mandatory. Denotes the tab indicator content.\n`mdc-tab-indicator--active` | Optional. Visually activates the indicator.\n`mdc-tab-indicator--fade` | Optional. Sets up the tab indicator to fade in on activation and fade out on deactivation.\n`mdc-tab-indicator__content--underline` | Optional. Denotes an underline tab indicator.\n`mdc-tab-indicator__content--icon` | Optional. Denotes an icon tab indicator.\n\n> *NOTE*: Exactly one of the `--underline` or `--icon` content modifier classes should be present.\n\n### Sass Mixins\n\nTo customize the tab indicator, use the following mixins.\n\nMixin | Description\n--- | ---\n`surface` | Mandatory. Must be applied to the parent element of the `mdc-tab-indicator`.\n`underline-color($color)` | Customizes the color of the underline.\n`icon-color($color)` | Customizes the color of the icon subelement.\n`underline-height($height)` | Customizes the height of the underline.\n`icon-height($height)` | Customizes the height of the icon subelement.\n`underline-top-corner-radius($radius)` | Customizes the top left and top right border radius of the underline child element.\n\n## `MDCTabIndicator` Methods\n\nMethod Signature | Description\n--- | ---\n`activate(previousIndicatorClientRect?: ClientRect) => void` | Activates the tab indicator.\n`deactivate() => void` | Deactivates the tab indicator.\n`computeContentClientRect() => ClientRect` | Returns the content element bounding client rect.\n\n## Usage within Web Frameworks\n\nIf you are using a JavaScript framework, such as React or Angular, you can create a Tab Indicator for your framework. Depending on your needs, you can use the _Simple Approach: Wrapping MDC Web Vanilla Components_, or the _Advanced Approach: Using Foundations and Adapters_. Please follow the instructions [here](../../docs/integrating-into-frameworks.md).\n\n### `MDCTabIndicatorAdapter`\n\nMethod Signature | Description\n--- | ---\n`addClass(className: string) => void` | Adds a class to the root element.\n`removeClass(className: string) => void` | Removes a class from the root element.\n`setContentStyleProperty(property: string, value: string) => void` | Sets the style property of the content element.\n`computeContentClientRect() => ClientRect` | Returns the content element's bounding client rect.\n\n### `MDCTabIndicatorFoundation`\n\nMethod Signature | Description\n--- | ---\n`handleTransitionEnd(evt: Event) => void` | Handles the logic for the `\"transitionend\"` event on the root element.\n`activate(previousIndicatorClientRect?: ClientRect) => void` | Activates the tab indicator.\n`deactivate() => void` | Deactivates the tab indicator.\n`computeContentClientRect() => ClientRect` | Returns the content element's bounding client rect.\n","gitHead":"f9c9fe091a06230b038ac8a71ccd652c7c662b96","license":"MIT","_npmUser":{"name":"abhiomkar","email":"abhiomkar@gmail.com"},"homepage":"https://github.com/material-components/material-components-web#readme","keywords":["material components","material design","tab","indicator"],"repository":{"url":"git+https://github.com/material-components/material-components-web.git","type":"git","directory":"packages/mdc-tab-indicator"},"_npmVersion":"lerna/3.20.2/node@v10.23.0+x64 (linux)","description":"The Material Components for the web tab indicator component","directories":{},"maintainers":[{"name":"abhiomkar","email":"abhiomkar@gmail.com"},{"name":"azakus","email":"dfreedm2@gmail.com"},{"name":"bicknellr","email":"bicknellr@gmail.com"},{"name":"material-admin","email":"aprigogin+npm@google.com"},{"name":"bwobrien","email":"obrien.test@gmail.com"},{"name":"lynnjepsen","email":"lynnjepsen@google.com"},{"name":"acdvorak","email":"acdvorak@gmail.com"},{"name":"kfranqueiro","email":"kenneth.franqueiro@gmail.com"},{"name":"aprigogin","email":"andrey.prigogin@gmail.com"},{"name":"patrickrodee","email":"prodee@google.com"},{"name":"bonniez","email":"bonniez@google.com"},{"name":"moog16","email":"mattgoo@gmail.com"},{"name":"williamernest","email":"williamernest@google.com"},{"name":"aomarks","email":"aomarks@gmail.com"},{"name":"emarquez","email":"emarquez@google.com"},{"name":"allanchen","email":"allanchen@google.com"},{"name":"esgonzalez","email":"esgonzalez@google.com"},{"name":"asyncliz","email":"asyncliz@gmail.com"},{"name":"candysonya","email":"wangchan518@gmail.com"},{"name":"ssuarez","email":"sayrisuarez@google.com"},{"name":"taylorv","email":"brian.t.vann@gmail.com"}],"sideEffects":false,"_nodeVersion":"10.23.0","dependencies":{"tslib":"^1.9.3","@material/base":"9.0.0-canary.30fdfd06e.0","@material/theme":"9.0.0-canary.30fdfd06e.0","@material/animation":"9.0.0-canary.30fdfd06e.0","@material/feature-targeting":"9.0.0-canary.30fdfd06e.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"readmeFilename":"README.md","_npmOperationalInternal":{"tmp":"tmp/tab-indicator_9.0.0-canary.30fdfd06e.0_1608145636918_0.7721748407245712","host":"s3://npm-registry-packages"},"_id":"@material/tab-indicator@9.0.0-canary.30fdfd06e.0","version":"9.0.0-canary.30fdfd06e.0"}