Options
All
  • Public
  • Public/Protected
  • All
Menu

Defines the shape of the adapter expected by the foundation. Implement this adapter for your framework of choice to delegate updates to the component in your framework of choice. See architecture documentation for more details. https://github.com/material-components/material-components-web/blob/master/docs/code/architecture.md

Hierarchy

  • MDCChipAdapter

Index

Methods

addClass

  • addClass(className: string): void

addClassToLeadingIcon

  • addClassToLeadingIcon(className: string): void

eventTargetHasClass

  • eventTargetHasClass(target: EventTarget | null, className: string): boolean
  • Parameters

    • target: EventTarget | null
    • className: string

    Returns boolean

    true if target has className, false otherwise.

getCheckmarkBoundingClientRect

  • getCheckmarkBoundingClientRect(): ClientRect | null
  • Returns ClientRect | null

    The bounding client rect of the checkmark element or null if it doesn't exist.

getComputedStyleValue

  • getComputedStyleValue(propertyName: string): string
  • Parameters

    • propertyName: string

    Returns string

    The computed property value of the given style property on the root element.

getRootBoundingClientRect

  • getRootBoundingClientRect(): ClientRect

hasClass

  • hasClass(className: string): boolean

hasLeadingIcon

  • hasLeadingIcon(): boolean

notifyInteraction

  • notifyInteraction(): void
  • Emits a custom "MDCChip:interaction" event denoting the chip has been interacted with (typically on click or keydown).

    Returns void

notifyRemoval

  • notifyRemoval(): void

notifySelection

  • notifySelection(selected: boolean): void
  • Emits a custom "MDCChip:selection" event denoting the chip has been selected or deselected.

    Parameters

    • selected: boolean

    Returns void

notifyTrailingIconInteraction

  • notifyTrailingIconInteraction(): void
  • Emits a custom "MDCChip:trailingIconInteraction" event denoting the trailing icon has been interacted with (typically on click or keydown).

    Returns void

removeClass

  • removeClass(className: string): void

removeClassFromLeadingIcon

  • removeClassFromLeadingIcon(className: string): void

setStyleProperty

  • setStyleProperty(propertyName: string, value: string): void
  • Sets the property value of the given style property on the root element.

    Parameters

    • propertyName: string
    • value: string

    Returns void

Generated using TypeDoc