material-web/iconbutton/filled-tonal-icon-button.ts
Andrew Jakubowicz 38b1b69a9c fix(iconbutton)!: rename "lib" directory to "internal"
BREAKING CHANGE: Rename `@material/web/iconbutton/lib` to `@material/web/iconbutton/internal`. Prefer not using internal files.

PiperOrigin-RevId: 550579461
2023-07-24 09:10:22 -07:00

46 lines
1.2 KiB
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

/**
* @license
* Copyright 2022 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
import {customElement} from 'lit/decorators.js';
import {styles} from './internal/filled-tonal-styles.css.js';
import {IconButton} from './internal/icon-button.js';
import {styles as sharedStyles} from './internal/shared-styles.css.js';
declare global {
interface HTMLElementTagNameMap {
'md-filled-tonal-icon-button': MdFilledTonalIconButton;
}
}
/**
* @summary Icon buttons help people take supplementary actions with a single
* tap.
*
* @description
* __Emphasis:__ Low emphasis For optional or supplementary actions with the
* least amount of prominence.
*
* __Rationale:__ The most compact and unobtrusive type of button, icon buttons
* are used for optional supplementary actions such as "Bookmark" or "Star."
*
* __Example usages:__
* - Add to Favorites
* - Print
*/
@customElement('md-filled-tonal-icon-button')
export class MdFilledTonalIconButton extends IconButton {
static override styles = [sharedStyles, styles];
protected override getRenderClasses() {
return {
...super.getRenderClasses(),
'filled-tonal': true,
'toggle-filled-tonal': this.toggle,
};
}
}