How to use the @material/menu-surface/foundation.js function in @material/menu-surface

To help you get started, we’ve selected a few @material/menu-surface 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 / select / src / mwc-select-base.ts View on Github external
mwcMenu.position(menuElement, position);
      },
      setMaxHeight: (height) => {
        const menuElement = this.menuElement;

        if (!menuElement) {
          return;
        }

        mwcMenu.maxHeight(menuElement, height);
      },
    };

    this.mdcMenuSurfaceFoundation =
        new MDCMenuSurfaceFoundation(mdcMenuSurfaceAdapter);
    this.mdcMenuSurfaceFoundation.init();
  }