How to use the @material/line-ripple/foundation.js.MDCLineRippleFoundation function in @material/line-ripple

To help you get started, we’ve selected a few @material/line-ripple examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github material-components / material-components-web-components / packages / line-ripple / src / mwc-line-ripple-directive.ts View on Github external
export const lineRipple = directive(() => (part: PropertyPart) => {
  const lastFoundation = partToFoundationMap.get(part);
  if (!lastFoundation) {
    const lineElement = part.committer.element as LineRipple;
    lineElement.classList.add('mdc-line-ripple');
    const adapter = createAdapter(lineElement);
    const foundation = new MDCLineRippleFoundation(adapter);
    foundation.init();
    part.setValue(foundation);
    partToFoundationMap.set(part, foundation);
  }
});
github material-components / material-components-web-components / packages / textfield / src / mwc-textfield-base-element.ts View on Github external
protected createLineRippleFoundation() {
    const adapter = this.getLineRippleAdapter();
    this._lineRippleFoundation = new MDCLineRippleFoundation(adapter);
  }